/* The film: the frame on the demos page, and the large player (scripts/reel.js). Everything in the frame is sized from the
   frame's own width (cqw), so it keeps the same proportions at every window size. The picture (logo exactly in the middle,
   behind the play button) sits behind it all. */
.dmo-reel-frame { --reel-out: cubic-bezier(.23, 1, .32, 1); }
.reel-open { container-type: inline-size; position: relative; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: #080908; color: #fff; font: inherit; cursor: pointer; border-radius: inherit; overflow: hidden; }
.reel-open:focus-visible { outline: 2px solid #fff; outline-offset: -6px; }
.reel-open .reel-art { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; transition: transform .7s var(--reel-out); }
.reel-tag, .reel-go { position: absolute; display: flex; align-items: center; border-radius: 999px; -webkit-backdrop-filter: blur(18px) saturate(1.2); backdrop-filter: blur(18px) saturate(1.2); }

/* top left: play sign | VIDEO */
.reel-tag { left: 4.5cqw; top: 4.5cqw; height: max(38px, 4.1cqw); gap: max(13px, 1.4cqw); padding: 0 max(18px, 1.9cqw) 0 max(20px, 2.1cqw); background: rgba(255, 255, 255, .18); color: rgba(255, 255, 255, .82); line-height: 1; transition: background-color .25s ease, opacity .4s ease .08s, translate .5s var(--reel-out) .08s; }
.reel-tag svg { width: max(10px, .95cqw); height: auto; aspect-ratio: 1; }
.reel-tag i { width: 1px; height: 36%; background: rgba(255, 255, 255, .28); }
.reel-tag b { font-size: max(11px, 1.08cqw); font-weight: 600; letter-spacing: .035em; text-transform: uppercase; }

/* the middle play button: a wider pill of the same gray, with a large soft-cornered triangle */
.reel-go { left: 50%; top: 50%; translate: -50% -50%; justify-content: center; width: max(87.4px, 9.12cqw); height: max(60.8px, 6.365cqw); background: rgba(74, 74, 74, .92); box-shadow: 0 0 0 1px rgba(255, 255, 255, .14) inset, 0 18px 44px -12px rgba(0, 0, 0, .7); transition: transform .35s var(--reel-out), background-color .25s ease, opacity .4s ease, scale .5s var(--reel-out); }
.reel-go svg { width: 34%; height: auto; aspect-ratio: 1; margin-left: 2%; }

/* bottom left: the wordmark, white; its middle is as far from the bottom edge as the top pill's middle is from the top */
.reel-open .reel-word { position: absolute; left: 4.6cqw; bottom: 5.6cqw; width: max(112px, 14cqw); height: auto; max-width: none; filter: brightness(0) invert(1); transition: opacity .4s ease .12s, translate .5s var(--reel-out) .12s; }

/* a click: the play button swells and dissolves, the pill drifts up and the wordmark down, then the player grows out of the
   clean frame. On closing they settle back in, one after the other (the delays above). */
.dmo-reel-frame.is-playing .reel-go { opacity: 0; scale: 1.35; transition: opacity .2s ease, scale .32s var(--reel-out); }
.dmo-reel-frame.is-playing .reel-tag { opacity: 0; translate: 0 -10px; transition: opacity .18s ease, translate .26s var(--reel-out); }
.dmo-reel-frame.is-playing .reel-word { opacity: 0; translate: 0 10px; transition: opacity .18s ease, translate .26s var(--reel-out); }

@media (hover: hover) and (pointer: fine) {
  .reel-open:hover .reel-art { transform: scale(1.018); }
  .reel-open:hover .reel-go { transform: scale(1.08); background: rgba(92, 92, 92, .95); }
  .reel-open:hover .reel-tag { background: rgba(255, 255, 255, .24); }
}
.reel-open:focus-visible .reel-go { background: rgba(92, 92, 92, .95); }
.reel-open:active .reel-go { transform: scale(.96); transition-duration: .12s; }

/* the player sits under the circle cursor (z-index 10001) and over everything else */
.reel-lb { position: fixed; inset: 0; z-index: 10000; display: grid; place-items: center; }
.reel-lb[hidden], .reel-lb [hidden] { display: none !important; }
.reel-back { position: absolute; inset: 0; background: #0b0a09; opacity: 0; transition: opacity .32s ease; }
.reel-lb.is-in .reel-back { opacity: 1; transition-delay: .12s; }
.reel-box { position: relative; width: min(1480px, 92vw, calc((100vh - 150px) * 16 / 9)); width: min(1480px, 92vw, calc((100dvh - 150px) * 16 / 9)); min-width: min(320px, 92vw); aspect-ratio: 16 / 9; transform-origin: 0 0; background: #000; border-radius: 18px; overflow: hidden; box-shadow: 0 60px 120px -40px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .08); opacity: 0; transition: opacity .22s ease; }
.reel-lb.is-in .reel-box { opacity: 1; transition-delay: .17s; }
.reel-stage { position: relative; width: 100%; height: 100%; overflow: hidden; transform-origin: 0 0; }
.reel-video { display: block; width: 100%; height: 100%; max-width: none; max-height: none; object-fit: contain; background: #000; }

.reel-lb button { display: inline-grid; place-items: center; padding: 0; border: 0; background: none; color: #fff; cursor: pointer; font: inherit; }
.reel-lb svg { width: 20px; height: 20px; }
.reel-lb .reel-bar button, .reel-lb .reel-cta, .reel-lb .reel-unmute { transition: transform .16s cubic-bezier(.23, 1, .32, 1), background-color .2s ease; }
.reel-lb .reel-bar button:active { transform: scale(.9); }
.reel-lb .reel-x svg { transition: transform .3s cubic-bezier(.23, 1, .32, 1); }
.reel-lb .reel-x:hover svg { transform: rotate(90deg); }
.reel-lb .reel-x:active { transform: scale(.9); }
.reel-lb .reel-unmute:active { transform: scale(.97); }
.reel-lb button:focus-visible, .reel-lb input:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.reel-lb .reel-x { position: absolute; top: 18px; right: 22px; z-index: 2; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .12); opacity: 0; transition: opacity .3s ease, background-color .2s ease, transform .16s cubic-bezier(.23, 1, .32, 1); }
.reel-lb.is-in .reel-x { opacity: 1; transition-delay: .3s, 0s, 0s; }
.reel-lb .reel-x:hover { background: rgba(255, 255, 255, .24); }
.reel-lb .reel-big { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 84px; height: 84px; border-radius: 50%; background: rgba(255, 255, 255, .95); color: #141311; box-shadow: 0 20px 50px -12px rgba(0, 0, 0, .6); }
.reel-lb .reel-big svg { width: 32px; height: 32px; }
.reel-lb .reel-unmute { position: absolute; left: 50%; top: 18px; translate: -50% 0; display: inline-flex; align-items: center; gap: 9px; padding: 11px 18px; border-radius: 999px; background: #fff; color: #141311; font-size: 14px; font-weight: 600; }

.reel-spin { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .25); border-top-color: #fff; visibility: hidden; pointer-events: none; }
.reel-box.is-waiting .reel-spin { visibility: visible; animation: reel-spin .8s linear infinite; }
@keyframes reel-spin { to { transform: rotate(360deg); } }

/* the "did not load" message */
.reel-card { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; padding: 24px 24px 76px; text-align: center; background: rgba(8, 7, 6, .9); color: #fff; }
.reel-card p { margin: 0; max-width: 32em; font-size: 16px; line-height: 1.5; color: #fff; }
.reel-card > div { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.reel-lb .reel-cta { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border-radius: 999px; background: #fff; color: #141311; font-size: 14px; font-weight: 600; line-height: 1.2; white-space: nowrap; }
.reel-lb .reel-cta.is-quiet { background: rgba(255, 255, 255, .14); color: #fff; }
.reel-lb .reel-cta svg { width: 16px; height: 16px; transition: transform .3s cubic-bezier(.23, 1, .32, 1); }

/* the end of the film: a small bar rises above the controls; nothing is darkened, the last picture stays in view */
.reel-done { position: absolute; left: 50%; bottom: 64px; translate: -50% 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; width: max-content; max-width: calc(100% - 24px); padding: 7px; border-radius: 30px; background: rgba(24, 21, 20, .76); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 22px 44px -18px rgba(0, 0, 0, .8); color: #fff; animation: reel-rise .5s cubic-bezier(.23, 1, .32, 1) .1s backwards; }
.reel-done-t { padding: 0 8px 0 14px; font-size: 14px; font-weight: 600; letter-spacing: -0.01em; white-space: nowrap; }
.reel-done > * { animation: reel-in .4s cubic-bezier(.23, 1, .32, 1) backwards; }
.reel-done > :nth-child(1) { animation-delay: .2s; }
.reel-done > :nth-child(2) { animation-delay: .26s; }
.reel-done > :nth-child(3) { animation-delay: .32s; }
@keyframes reel-rise { from { opacity: 0; translate: -50% 18px; scale: .96; } }
@keyframes reel-in { from { opacity: 0; translate: 0 8px; } }
@media (hover: hover) and (pointer: fine) {
  .reel-lb .reel-cta:hover { transform: translateY(-2px); }
  .reel-lb .reel-book:hover svg { transform: translateX(4px); }
  .reel-lb .reel-cta.is-quiet:hover { background: rgba(255, 255, 255, .24); }
  .reel-lb .reel-again:hover svg { transform: rotate(-360deg); transition-duration: .6s; }
}
.reel-lb .reel-cta:active { transform: scale(.97); }

/* controls: along the bottom, out of the way a moment after the mouse rests */
.reel-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 10px; padding: 34px 14px 10px; background: linear-gradient(to top, rgba(0, 0, 0, .72), rgba(0, 0, 0, 0)); color: #fff; transition: opacity .3s ease, transform .3s ease; }
.reel-box.is-idle .reel-bar { opacity: 0; transform: translateY(8px); pointer-events: none; }
.reel-lb .reel-bar button { width: 38px; height: 38px; flex: none; border-radius: 50%; }
.reel-lb .reel-bar button:hover { background: rgba(255, 255, 255, .16); }
.reel-t { flex: none; min-width: 34px; font-size: 13px; font-variant-numeric: tabular-nums; text-align: center; }
.reel-lb input[type="range"] { -webkit-appearance: none; appearance: none; height: 18px; margin: 0; padding: 0; border: 0; background: transparent; cursor: pointer; }
.reel-seek { flex: 1; min-width: 60px; }
.reel-vol { width: 84px; flex: none; }
.reel-lb input[type="range"]::-webkit-slider-runnable-track { height: 4px; border-radius: 4px; background: linear-gradient(to right, #fff var(--p, 0%), rgba(255, 255, 255, .45) var(--p, 0%), rgba(255, 255, 255, .45) var(--b, 0%), rgba(255, 255, 255, .2) var(--b, 0%)); }
.reel-lb input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 13px; height: 13px; margin-top: -4.5px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 1px 6px rgba(0, 0, 0, .5); }
.reel-lb input[type="range"]::-moz-range-track { height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .25); }
.reel-lb input[type="range"]::-moz-range-progress { height: 4px; border-radius: 4px; background: #fff; }
.reel-lb input[type="range"]::-moz-range-thumb { width: 13px; height: 13px; border: 0; border-radius: 50%; background: #fff; }

/* full screen: the circle cursor cannot follow in there, so the normal arrow comes back (and hides while resting) */
.reel-box:fullscreen { width: 100%; height: 100%; border-radius: 0; aspect-ratio: auto; transition: none; background: #0b0a09; }
.reel-box:fullscreen::backdrop { background: #0b0a09; }
.reel-box:fullscreen .reel-video { background: transparent; }
.reel-lb.is-morph .reel-bar, .reel-lb.is-morph .reel-x { opacity: 0; transition: none; }
/* first frames of full screen: the picture stays where it was on the monitor (reel.js, hold) */
.reel-box.is-hold:fullscreen .reel-stage { position: absolute; left: var(--hold-x); top: var(--hold-y); width: var(--hold-w); height: calc(var(--hold-w) * 9 / 16); border-radius: 18px; }
.reel-box.is-hold:-webkit-full-screen .reel-stage { position: absolute; left: var(--hold-x); top: var(--hold-y); width: var(--hold-w); height: calc(var(--hold-w) * 9 / 16); border-radius: 18px; }
.reel-box:-webkit-full-screen { width: 100%; height: 100%; border-radius: 0; aspect-ratio: auto; }
html.has-circle-cursor .reel-box:fullscreen, html.has-circle-cursor .reel-box:fullscreen * { cursor: default !important; }
html.has-circle-cursor .reel-box.is-idle:fullscreen, html.has-circle-cursor .reel-box.is-idle:fullscreen * { cursor: none !important; }

@media (max-width: 760px) { .reel-vol, .reel-t.reel-dur, .reel-done-t { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .reel-back, .reel-box, .reel-bar, .reel-x, .reel-open .reel-art, .reel-tag, .reel-go, .reel-open .reel-word, .dmo-reel-frame.is-playing span, .dmo-reel-frame.is-playing img, .reel-lb button, .reel-lb svg { transition: none !important; }
  .reel-done, .reel-done > * { animation: none !important; }
}
