/* Fullscreen showreel (player.js). The reel element itself grows from its framed clip to the viewport. */
.reel.is-open {
  position: fixed; inset: 0; z-index: 70; cursor: default;
  clip-path: inset(var(--ot) var(--or) var(--ob) var(--ol) round var(--orad));
  transition: clip-path .95s var(--ease);
}
.reel.is-open.is-full { clip-path: inset(0 0 0 0 round 0px); }
.player-open .hero__sticky { z-index: 70; }
.player-open .nav { opacity: 0; pointer-events: none; }
.player-idle .reel.is-open { cursor: none; }

.player-ui {
  position: fixed; inset: 0; z-index: 80; pointer-events: none; color: var(--white);
  opacity: 0; transition: opacity .5s var(--ease);
}
.player-ui.is-on { opacity: 1; transition-delay: .45s; }
.player-ui.is-on.is-idle { opacity: 0; transition-delay: 0s; }
/* a soft neutral scrim so the controls read over bright frames */
.player-ui::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 200px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
}

.player-close, .player-bar { pointer-events: auto; }
.player-close {
  position: absolute; top: 28px; right: var(--gutter);
  font-size: 15px; border-bottom: 1px solid currentColor; padding-bottom: 2px;
}
.player-bar {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: 32px;
  display: grid; grid-template-columns: auto auto 1fr auto auto; align-items: center; gap: 24px;
  font-size: 15px; font-variant-numeric: tabular-nums;
}
.player-btn {
  --led: var(--white); --led-floor: 0.25;
  display: inline-flex; align-items: center; gap: 10px; min-width: 4.5em; font-size: 15px;
}
.player-time { color: rgba(255, 255, 255, 0.72); }

/* scrub: a hairline with the same blue playhead as the process timeline */
.player-scrub { position: relative; height: 24px; cursor: pointer; touch-action: none; }
.player-scrub::before {
  content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: rgba(255, 255, 255, 0.28);
}
.player-fill {
  position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--white);
  transform-origin: left; transform: scaleX(var(--pct, 0));
}
.player-head {
  position: absolute; top: 50%; left: calc(var(--pct, 0) * 100%);
  width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--accent);
  transition: transform .2s var(--ease);
}
.player-scrub:hover .player-head { transform: scale(1.4); }
.player-close:focus-visible, .player-btn:focus-visible, .player-scrub:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

@media (max-width: 860px) {
  .player-bar { grid-template-columns: auto 1fr auto; gap: 16px; bottom: 24px; }
  .player-time { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .reel.is-open { transition: none; }
}

/* ---------- volume: a glass column rises over the sound button (volume.js) ---------- */
.vol { position: relative; display: inline-flex; }
.vol__pop {
  position: absolute; left: 50%; bottom: 100%; padding-bottom: 14px; /* the gap is part of the hover area */
  transform: translateX(-50%); pointer-events: none;
}
.vol__glass {
  display: grid; justify-items: center; gap: 12px; width: 52px; padding: 14px 0 18px; border-radius: 999px;
  background: linear-gradient(180deg, rgba(40, 40, 46, 0.62), rgba(14, 14, 16, 0.5));
  -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), inset 0 0 0 1px rgba(255, 255, 255, 0.1), 0 12px 30px rgba(0, 0, 0, 0.35);
  opacity: 0; transform: translateY(10px) scaleY(0.6); transform-origin: 50% 100%;
  transition: opacity .3s var(--ease), transform .55s var(--ease);
}
.vol:hover .vol__pop, .vol:focus-within .vol__pop, .vol.is-dragging .vol__pop { pointer-events: auto; }
.vol:hover .vol__glass, .vol:focus-within .vol__glass, .vol.is-dragging .vol__glass { opacity: 1; transform: none; }
.vol__num { font-size: 12px; color: rgba(255, 255, 255, 0.75); font-variant-numeric: tabular-nums; }
/* the track: a hairline, white fill from the bottom, the same blue head as the scrub bar */
.vol__track { position: relative; width: 24px; height: 120px; cursor: pointer; touch-action: none; }
.vol__track::before {
  content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; margin-left: -1px; border-radius: 2px;
  background: rgba(255, 255, 255, 0.25);
}
.vol__fill {
  position: absolute; left: 50%; bottom: 0; width: 2px; margin-left: -1px; border-radius: 2px;
  height: calc(var(--v, 0) * 100%); background: var(--white);
}
.vol__head {
  position: absolute; left: 50%; bottom: calc(var(--v, 0) * 100%); width: 12px; height: 12px; margin: 0 0 -6px -6px;
  border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(47, 91, 255, 0.25);
  transition: transform .2s var(--ease);
}
.vol__track:hover .vol__head, .vol.is-dragging .vol__head { transform: scale(1.25); }
.vol__track:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) {
  .vol__glass, .vol__head { transition: none; }
}
