/*
 * Copyright 2017 The Chromium Authors. All rights reserved.
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

:host {
  position: absolute !important; /* stylelint-disable-line declaration-no-important */
  inset: 0;
  overflow: hidden;
  contain: strict;
  background-color: transparent;
}

:host-context(.dimmed-pane) {
  background-color: var(--color-background-opacity-50);
}

:host-context(.no-pointer-events) {
  pointer-events: none;
}

.widget {
  display: flex;
  background-color: transparent;
  pointer-events: auto;
  flex: none;
}

.no-pointer-events {
  pointer-events: none;
}

.arrow {
  /* stylelint-disable-next-line custom-property-pattern */
  background-image: var(--image-file-popoverArrows);
  width: 19px;
  height: 19px;
}

.arrow-top {
  background-position: 0 76px;
  margin-top: -19px;
  margin-left: -9px;
}

.arrow-bottom {
  background-position: 0 57px;
  margin-left: -9px;
}

.arrow-left {
  background-position: 0 38px;
  margin-left: -19px;
  margin-top: -9px;
}

.arrow-right {
  background-position: 0 19px;
  margin-top: -9px;
}

.arrow-none {
  display: none;
}

:host-context(.theme-with-dark-background) .arrow {
  filter: invert(80%);
}
