/* moraq-creative - Toolbox-style custom video player (home tablet) */

/* Shared toolbox player controls (home + future embeds) */
.blg-custom-video-player--toolbox .blg-gl-photo-video-speed-menu,
.blg-custom-video-player--toolbox .blg-gl-photo-video-quality-menu,
.blg-gl-photo-video-speed-menu.is-flyout-portal,
.blg-gl-photo-video-quality-menu.is-flyout-portal {
  pointer-events: auto;
  -webkit-overflow-scrolling: touch;
}

.blg-gl-photo-video-speed-menu,
.blg-gl-photo-video-quality-menu {
  list-style: none;
  margin: 0;
  padding: 6px;
  border-radius: 10px;
  background: #1f2430;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

.blg-gl-photo-video-speed-menu[hidden],
.blg-gl-photo-video-quality-menu[hidden] {
  display: none !important;
}

.blg-gl-photo-video-speed-menu li,
.blg-gl-photo-video-quality-menu li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.blg-gl-photo-video-speed-option,
.blg-gl-photo-video-quality-option {
  display: block;
  width: 100%;
  min-height: 44px;
  margin: 0;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.88);
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
}

.blg-gl-photo-video-speed-option:hover,
.blg-gl-photo-video-speed-option.is-active,
.blg-gl-photo-video-quality-option:hover,
.blg-gl-photo-video-quality-option.is-active {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.blg-custom-video-player--toolbox .blg-gl-photo-video-settings {
  display: none;
  flex-shrink: 0;
}

.blg-custom-video-player--toolbox .blg-gl-photo-video-settings-toggle {
  width: 36px;
  height: 36px;
  padding: 0;
  justify-content: center;
}

.blg-custom-video-player--toolbox.is-mobile-compact-controls .blg-gl-photo-video-speed,
.blg-custom-video-player--toolbox.is-mobile-compact-controls .blg-gl-photo-video-quality {
  display: none !important;
}

.blg-custom-video-player--toolbox.is-mobile-compact-controls .blg-gl-photo-video-settings {
  display: inline-flex;
  align-items: center;
}

.blg-custom-video-player--toolbox .blg-gl-photo-video-speed-toggle .blg-gl-photo-video-icon,
.blg-custom-video-player--toolbox .blg-gl-photo-video-quality-toggle .blg-gl-photo-video-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: 0.75;
}

.blg-gl-photo-video-icon--asset {
  filter: brightness(0) invert(1);
  opacity: 0.92;
}

/* Settings sheet portal */
.blg-gl-photo-video-settings-portal.is-settings-portal {
  position: fixed;
  inset: 0;
  z-index: 20120;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
}

.blg-gl-photo-video-settings-portal.is-settings-portal:not([hidden]) {
  pointer-events: auto;
}

.blg-gl-photo-video-settings-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  padding: 0;
  margin: 0;
  background: rgba(0, 0, 0, 0.42);
  cursor: pointer;
}

.blg-gl-photo-video-settings-sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: min(78vh, 520px);
  overflow: hidden;
  border-radius: 16px 16px 0 0;
  background: #fff;
  color: #111;
  box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.18);
}

.blg-gl-photo-video-settings-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 10px 16px 8px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.blg-gl-photo-video-settings-head--sub {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.blg-gl-photo-video-settings-grabber {
  display: block;
  width: 36px;
  height: 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.16);
}

.blg-gl-photo-video-settings-title {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.3;
}

.blg-gl-photo-video-settings-head--sub .blg-gl-photo-video-settings-title {
  flex: 1;
  text-align: center;
}

.blg-gl-photo-video-settings-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #111;
  cursor: pointer;
}

.blg-gl-photo-video-settings-back .blg-gl-photo-video-icon {
  transform: rotate(90deg);
}

.blg-gl-photo-video-settings-menu,
.blg-gl-photo-video-settings-picks {
  list-style: none;
  margin: 0;
  padding: 6px 0 12px;
}

.blg-gl-photo-video-settings-nav,
.blg-gl-photo-video-settings-pick {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  padding: 10px 16px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
}

.blg-gl-photo-video-settings-nav:active,
.blg-gl-photo-video-settings-pick:active {
  background: rgba(0, 0, 0, 0.04);
}

.blg-gl-photo-video-icon--settings-row {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  object-fit: contain;
}

.blg-gl-photo-video-settings-nav-text {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.blg-gl-photo-video-settings-nav-label {
  font-size: 0.9375rem;
  font-weight: 500;
}

.blg-gl-photo-video-settings-nav-value {
  font-size: 0.8125rem;
  color: rgba(0, 0, 0, 0.55);
}

.blg-gl-photo-video-settings-nav .blg-gl-photo-video-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: rgba(0, 0, 0, 0.45);
}

.blg-gl-photo-video-settings-pick-label {
  flex: 1;
  font-size: 0.9375rem;
}

.blg-gl-photo-video-settings-pick-check {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 2px solid rgba(0, 0, 0, 0.15);
}

.blg-gl-photo-video-settings-pick.is-active .blg-gl-photo-video-settings-pick-check {
  border-color: #0030de;
  background: #0030de;
  box-shadow: inset 0 0 0 3px #fff;
}

.blg-gl-photo-video-settings-panel[hidden] {
  display: none !important;
}

/* Home tablet - full bleed video */
.blg-gl-photo-video-frame--home {
  width: 100%;
  height: 100%;
  max-width: none;
  margin: 0;
}

.blg-custom-video-player--home {
  width: 100%;
  height: 100%;
  max-width: none;
  display: flex;
  flex-direction: column;
}

.blg-custom-video-player--home.blg-gl-photo-video-player,
.blg-custom-video-player--home .blg-gl-photo-video-player {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.blg-custom-video-player--home .blg-gl-photo-video-stage {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  padding: 0;
  border-radius: 0;
  overflow: hidden;
  background: transparent;
  display: flex;
  flex-direction: column;
  position: relative;
}

.blg-custom-video-player--home .blg-gl-photo-video {
  display: block;
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
  min-height: 0;
  max-width: none;
  max-height: none;
  margin: 0;
  aspect-ratio: unset;
  border-radius: 0;
  object-fit: cover;
  object-position: center;
  background: transparent;
}

.blg-custom-video-player--home video.blg-gl-photo-video::-webkit-media-controls,
.blg-custom-video-player--home video.blg-gl-photo-video::-webkit-media-controls-enclosure {
  display: none !important;
}

.blg-custom-video-player--home .blg-gl-photo-video-controls {
  flex-shrink: 0;
  border-radius: 0;
  overflow: visible;
  position: relative;
  z-index: 30;
  pointer-events: auto;
  width: 100%;
  padding: 10px 14px 14px;
  background: #15171c;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  box-sizing: border-box;
}

.blg-custom-video-player--home .blg-gl-photo-video-progress-wrap {
  margin-bottom: 12px;
}

.blg-custom-video-player--home .blg-gl-photo-video-progress {
  display: block;
  width: 100%;
  height: 4px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  appearance: none;
  cursor: pointer;
}

.blg-custom-video-player--home .blg-gl-photo-video-progress::-webkit-slider-thumb {
  appearance: none;
  width: 12px;
  height: 12px;
  margin-top: -4px;
  border-radius: 50%;
  background: #fff;
}

.blg-custom-video-player--home .blg-gl-photo-video-controls-row {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0;
  width: 100%;
  overflow: visible;
}

.blg-custom-video-player--home .blg-gl-photo-video-primary {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}

.blg-custom-video-player--home .blg-gl-photo-video-transport {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.blg-custom-video-player--home .blg-gl-photo-video-time {
  flex: 1 1 auto;
  min-width: 88px;
  padding: 0 8px;
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.2;
  color: rgba(255, 255, 255, 0.88);
  white-space: nowrap;
}

.blg-custom-video-player--home .blg-gl-photo-video-actions {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
}

.blg-custom-video-player--home .blg-gl-photo-video-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  touch-action: manipulation;
}

.blg-custom-video-player--home .blg-gl-photo-video-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.blg-custom-video-player--home .blg-gl-photo-video-icon {
  display: block;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.blg-custom-video-player--home .blg-gl-photo-video-icon--chevron {
  width: 14px;
  height: 14px;
  opacity: 0.75;
}

.blg-custom-video-player--home .blg-gl-photo-video-speed,
.blg-custom-video-player--home .blg-gl-photo-video-quality,
.blg-custom-video-player--home .blg-gl-photo-video-volume {
  position: relative;
}

.blg-custom-video-player--home .blg-gl-photo-video-speed-toggle,
.blg-custom-video-player--home .blg-gl-photo-video-quality-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  min-height: 36px;
  height: 36px;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.92);
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 12px;
  cursor: pointer;
  touch-action: manipulation;
}

.blg-custom-video-player--home .blg-gl-photo-video-speed-toggle:hover,
.blg-custom-video-player--home .blg-gl-photo-video-quality-toggle:hover {
  background: rgba(255, 255, 255, 0.08);
}

.blg-custom-video-player--home .blg-gl-photo-video-volume-popover {
  position: absolute;
  right: 0;
  bottom: calc(100% + 8px);
  z-index: 40;
  display: none;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(21, 23, 28, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.blg-custom-video-player--home .blg-gl-photo-video-volume.is-open .blg-gl-photo-video-volume-popover,
.blg-custom-video-player--home .blg-gl-photo-video-volume:hover .blg-gl-photo-video-volume-popover,
.blg-custom-video-player--home .blg-gl-photo-video-volume:focus-within .blg-gl-photo-video-volume-popover {
  display: block;
}

.blg-custom-video-player--home .blg-gl-photo-video-volume-slider {
  width: 120px;
  height: 4px;
  margin: 0;
  accent-color: #fff;
}

.blg-custom-video-player--home.is-poster-visible .blg-gl-photo-video {
  opacity: 0;
}

.blg-gl-photo-video-poster-hit {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  border: 0;
  background: #0a0a0a;
  cursor: pointer;
}

.blg-gl-photo-video-poster-hit[hidden] {
  display: none !important;
}

.blg-gl-photo-video-poster-hit--play-only {
  background: #0a0a0a;
}

.blg-custom-video-player--home .blg-gl-photo-video-poster-hit--play-only .blg-gl-photo-video-poster-play {
  background: rgba(0, 48, 222, 0.72);
  border-color: rgba(242, 241, 237, 0.95);
  box-shadow:
    0 0 0 6px rgba(0, 48, 222, 0.22),
    0 12px 32px rgba(0, 0, 0, 0.4);
}

/* Fullscreen - keep full frame visible on mobile portrait */
.blg-gl-photo-video-stage:fullscreen,
.blg-gl-photo-video-stage:-webkit-full-screen,
.blg-gl-photo-video-stage.is-fullscreen {
  display: flex;
  flex-direction: column;
  position: relative;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  max-height: 100vh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  border-radius: 0;
  overflow: hidden;
  background: #000;
  box-sizing: border-box;
}

.blg-gl-photo-video-stage:fullscreen .blg-gl-photo-video,
.blg-gl-photo-video-stage:-webkit-full-screen .blg-gl-photo-video,
.blg-gl-photo-video-stage.is-fullscreen .blg-gl-photo-video {
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain !important;
  object-position: center;
  background: #000;
}

.blg-gl-photo-video-stage:fullscreen .blg-gl-photo-video-poster-hit,
.blg-gl-photo-video-stage:-webkit-full-screen .blg-gl-photo-video-poster-hit,
.blg-gl-photo-video-stage.is-fullscreen .blg-gl-photo-video-poster-hit {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  z-index: 2;
}

.blg-gl-photo-video-stage:fullscreen .blg-gl-photo-video-poster-img,
.blg-gl-photo-video-stage:-webkit-full-screen .blg-gl-photo-video-poster-img,
.blg-gl-photo-video-stage.is-fullscreen .blg-gl-photo-video-poster-img {
  object-fit: contain;
  object-position: center;
}

.blg-gl-photo-video-stage:fullscreen .blg-gl-photo-video-poster-bg,
.blg-gl-photo-video-stage:-webkit-full-screen .blg-gl-photo-video-poster-bg,
.blg-gl-photo-video-stage.is-fullscreen .blg-gl-photo-video-poster-bg {
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

.blg-gl-photo-video-stage:fullscreen .blg-gl-photo-video-controls,
.blg-gl-photo-video-stage:-webkit-full-screen .blg-gl-photo-video-controls,
.blg-gl-photo-video-stage.is-fullscreen .blg-gl-photo-video-controls {
  position: relative;
  z-index: 3;
  flex: 0 0 auto;
  width: 100%;
  padding-bottom: max(14px, env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}

.blg-gl-photo-video-poster-img,
.blg-gl-photo-video-poster-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.blg-gl-photo-video-poster-img {
  object-fit: cover;
  object-position: center;
}

.blg-gl-photo-video-poster-bg {
  display: block;
  background-color: #0a0a0a;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.blg-gl-photo-video-poster-play {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(56px, 8vw, 88px);
  height: clamp(56px, 8vw, 88px);
  border-radius: 999px;
  background: rgba(10, 10, 10, 0.52);
  border: 2px solid rgba(242, 241, 237, 0.88);
  color: #f2f1ed;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  transition: transform 0.18s ease, background 0.18s ease;
}

.blg-gl-photo-video-poster-hit:hover .blg-gl-photo-video-poster-play,
.blg-gl-photo-video-poster-hit:focus-visible .blg-gl-photo-video-poster-play {
  transform: scale(1.05);
  background: rgba(0, 48, 222, 0.55);
}

.blg-gl-photo-video-poster-play .blg-gl-photo-video-icon {
  width: clamp(22px, 3.2vw, 32px);
  height: clamp(22px, 3.2vw, 32px);
  margin-left: 4px;
}

.mc-home-tablet__player {
  width: 100%;
  height: 100%;
  max-width: none;
}

.mc-home-tablet__stage:has(.mc-home-tablet__player) {
  padding: 0;
}

.mc-home-tablet__stage:has(.mc-home-tablet__player) .mc-home-tablet__img {
  display: none;
}

@media (max-width: 900px) {
  .blg-custom-video-player--home.is-mobile-compact-controls .blg-gl-photo-video-speed,
  .blg-custom-video-player--home.is-mobile-compact-controls .blg-gl-photo-video-quality {
    display: none;
  }

  .blg-custom-video-player--home.is-mobile-compact-controls .blg-gl-photo-video-settings {
    display: inline-flex;
  }
}

@media (max-width: 640px) {
  .blg-custom-video-player--home .blg-gl-photo-video-controls,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-controls {
    padding: 8px 10px 10px;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-progress-wrap,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-progress-wrap {
    margin-bottom: 8px;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-controls-row,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-controls-row {
    gap: 0;
    justify-content: space-between;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-primary,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-primary {
    flex: 0 1 auto;
    min-width: 0;
    gap: 0;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-time,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-time {
    display: none;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-speed-toggle span,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-speed-toggle span,
  .blg-custom-video-player--home .blg-gl-photo-video-quality-toggle span,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-quality-toggle span {
    display: none;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-speed-toggle,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-speed-toggle,
  .blg-custom-video-player--home .blg-gl-photo-video-quality-toggle,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-quality-toggle {
    width: 32px;
    min-width: 32px;
    padding: 0;
    justify-content: center;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-btn,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-btn,
  .blg-custom-video-player--home .blg-gl-photo-video-settings-toggle,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-settings-toggle {
    width: 32px;
    height: 32px;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-icon,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-icon {
    width: 20px;
    height: 20px;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-actions,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-actions {
    flex: 0 0 auto;
    gap: 0;
    margin-left: 0;
  }

  .blg-custom-video-player--home .blg-gl-photo-video-transport,
  .blg-custom-video-player--toolbox .blg-gl-photo-video-transport {
    gap: 0;
  }

  .mc-gl-video-player--live .blg-gl-photo-video-frame {
    border-radius: 0;
  }
}
