.abb-video-player {
  --abb-vp-accent: var(--dxp-color-brand-primary);
  --abb-vp-on-accent: #fff;
  --abb-vp-controls-bg: rgba(0, 0, 0, 0.55);
  --abb-vp-controls-fg: #fff;
  --abb-vp-track: rgba(255, 255, 255, 0.25);
  --abb-vp-focus: var(--dxp-color-brand-primary);

  position: relative;
  overflow: hidden;
  width: 100%;
  color: var(--abb-vp-controls-fg);
  border-radius: var(--dxp-style-radius-md);
  background: #000;
  font-family: inherit;
  aspect-ratio: 16 / 9;
}

  .abb-video-player:focus-within .abb-video-player__controls, .abb-video-player:hover .abb-video-player__controls, .abb-video-player[data-state="idle"] .abb-video-player__controls, .abb-video-player[data-state="paused"] .abb-video-player__controls {
    transform: translateY(0);
    opacity: 1;
  }

  .abb-video-player[data-state="playing"] .abb-video-player__controls {
    transform: translateY(0.5rem);
    opacity: 0;
  }

  .abb-video-player[data-state="playing"].is-active .abb-video-player__controls {
    transform: translateY(0);
    opacity: 1;
  }

  .abb-video-player[data-state="idle"] .abb-video-player__bigplay, .abb-video-player[data-state="paused"] .abb-video-player__bigplay {
    pointer-events: auto;
    opacity: 1;
  }

.abb-video-player__media {
  display: block;
  width: 100%;
  height: 100%;
  cursor: pointer;
  -o-object-fit: cover;
  object-fit: cover;
  background: #000;
}

.abb-video-player__bigplay {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 5rem;
  height: 5rem;
  margin: auto;
  cursor: pointer;
  transition: opacity 180ms ease, transform 180ms ease;
  pointer-events: none;
  opacity: 0;
  color: var(--abb-vp-on-accent);
  border: none;
  border-radius: 50%;
  background: var(--abb-vp-accent);
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.3);
  inset: 0;
}

.abb-video-player__bigplay svg {
    width: 2.25rem;
    height: 2.25rem;
    margin-left: 0.125rem;
  }

.abb-video-player__bigplay:hover {
    transform: scale(1.06);
  }

.abb-video-player__bigplay:focus-visible {
    outline: 0.125rem solid var(--abb-vp-focus);
    outline-offset: 0.1875rem;
  }

.abb-video-player__controls {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: center;
  padding: 0.625rem 0.875rem;
  transition: opacity 200ms ease, transform 200ms ease;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
  gap: 0.75rem;
}

.abb-video-player__btn {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  cursor: pointer;
  color: var(--abb-vp-controls-fg);
  border: none;
  border-radius: 0.25rem;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
}

.abb-video-player__btn svg {
    width: 1.375rem;
    height: 1.375rem;
  }

.abb-video-player__btn:hover {
    color: var(--abb-vp-accent);
  }

.abb-video-player__btn:focus-visible {
    outline: 0.125rem solid var(--abb-vp-focus);
    outline-offset: 0.125rem;
  }

.abb-video-player__icon {
  display: none;
}

.abb-video-player[data-state="idle"] .abb-video-player__icon--play, .abb-video-player[data-state="paused"] .abb-video-player__icon--play, .abb-video-player[data-state="ended"] .abb-video-player__icon--play, .abb-video-player[data-state="playing"] .abb-video-player__icon--pause {
  display: block;
}

.abb-video-player:not([data-muted]) .abb-video-player__icon--volume, .abb-video-player[data-muted] .abb-video-player__icon--muted, .abb-video-player:not([data-fullscreen]) .abb-video-player__icon--enter-fs, .abb-video-player[data-fullscreen] .abb-video-player__icon--exit-fs {
  display: block;
}

.abb-video-player__progress {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  height: 1.25rem;
}

.abb-video-player__progress-track {
  position: absolute;
  top: 50%;
  right: 0;
  left: 0;
  overflow: hidden;
  height: 0.25rem;
  transform: translateY(-50%);
  pointer-events: none;
  border-radius: 0.125rem;
  background: var(--abb-vp-track);
}

.abb-video-player__progress-fill {
  width: 0%;
  height: 100%;
  transition: width 80ms linear;
  background: var(--abb-vp-accent);
}

.abb-video-player__scrubber {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 1.25rem;
  margin: 0;
  cursor: pointer;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
}

.abb-video-player__scrubber::-webkit-slider-runnable-track {
    height: 1.25rem;
    background: transparent;
  }

.abb-video-player__scrubber::-moz-range-track {
    height: 1.25rem;
    background: transparent;
  }

.abb-video-player__scrubber::-webkit-slider-thumb {
    width: 0.875rem;
    height: 0.875rem;
    margin-top: 0.1875rem;
    cursor: pointer;
    border: 0.125rem solid #fff;
    border-radius: 50%;
    background: var(--abb-vp-accent);
    -webkit-appearance: none;
    appearance: none;
  }

.abb-video-player__scrubber::-moz-range-thumb {
    width: 0.875rem;
    height: 0.875rem;
    cursor: pointer;
    border: 0.125rem solid #fff;
    border-radius: 50%;
    background: var(--abb-vp-accent);
  }

.abb-video-player__scrubber:focus-visible {
    border-radius: 0.125rem;
    outline: 0.125rem solid var(--abb-vp-focus);
    outline-offset: 0.25rem;
  }

.abb-video-player__time {
  flex: 0 0 auto;
  white-space: nowrap;
  opacity: 0.9;
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.abb-video-player:-webkit-full-screen {
  aspect-ratio: auto;
  width: 100vw;
  height: 100vh;
  border-radius: 0;
}

.abb-video-player:fullscreen {
  aspect-ratio: auto;
  width: 100vw;
  height: 100vh;
  border-radius: 0;
}
