.player-target {
  font-family: system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  overscroll-behavior: none;
  position: relative;
}

.player-container {
  --layer-video: 1;
  --layer-error: 4;
  --layer-controls: 5;

  font-family: system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  height: 100%;
  inset: 0;
  overflow: hidden;
  position: absolute;
  width: 100%;

  --color-highlight: #3784eb;
  --color-error: #FFF;

  &--rotated {
    height: 100vw;
    margin-top: -100vw;
    object-fit: cover;
    position: absolute;
    transform: rotate(90deg);
    transform-origin: bottom left;
    visibility: visible;
    width: 100vh;
    z-index: 4;
  }
}

.spinner-container {
  align-items: center;
  display: flex;
  height: 100%;
  inset: 0;
  justify-content: center;
  position: absolute;
  width: 100%;

  .spinner {
    height: 50px;
    width: 50px;
  }
}

.cast-indicator-container {
  align-items: center;
  display: flex;
  inset: 0;
  justify-content: center;
  position: absolute;
  z-index: var(--layer-title);

  svg {
    color: #FFF;
    height: 50px;
    width: 50px;
  }
}


.controls {
  z-index: var(--layer-controls);
}

.video {
  background: transparent;
  height: 100%;
  object-fit: contain;
  width: 100%;
  z-index: var(--layer-video);
}

.poster {
  height: 100%;
  left: 0;
  object-fit: cover;
  object-position: center;
  position: absolute;
  top: 0;
  user-select: none;
  width: 100%;
}

.error-message {
  align-items: center;
  color: var(--color-error);
  display: flex;
  flex-direction: column;
  gap: 30px;
  height: 100%;
  justify-content: center;
  left: 0;
  position: absolute;
  text-align: center;
  top: 0;
  width: 100%;
  z-index: var(--layer-error);

  &__message {
    font-size: 24px;
    font-weight: 300;
  }

  &__copy-debug-button {
    align-items: center;
    background-color: var(--color-error);
    border: 1px solid var(--color-error);
    border-radius: 5px;
    color: #000;
    display: flex;
    gap: 10px;
    height: 45px;
    opacity: 0.9;
    padding: 10px 20px;
    transition: opacity 0.15s ease;

    &:hover {
      opacity: 1;
      transition: opacity 0.35s ease;
    }
  }

  &__icon {
    height: 18px;
    width: 18px;
  }
}

.overlay {
  pointer-events: none;
  position: absolute;
  z-index: 1000;
}

:global(.__eluvio-player--size-md),
:global(.__eluvio-player--size-sm) {
  .error-message {
    font-size: 16px;
  }

  .spinner {
    border-width: 3px;
    height: 30px;
    width: 30px;
  }
}
