/* Вариант 8 — «Кино». Референс: титр документального фильма — огромная дата широким жирным гротеском
   тёплого молочного цвета поверх вечернего неба, под ней место разреженными прописными, чёрные кинополосы.
   Таймлайн внизу похож на полосу просмотра видео. */

:root {
  --wide: "Unbounded", "Arial Black", sans-serif;
  --sans: "Montserrat", system-ui, sans-serif;
  --cream: #ece4d8;
  --band: clamp(56px, 9vh, 96px);
  --swap-out: 420ms;
}
html, body { background: #000; }
body { font-family: var(--sans); color: var(--cream); }

.frame { position: fixed; z-index: 1; left: 0; right: 0; top: calc(var(--band) + var(--sat)); bottom: calc(var(--band) + var(--sab)); overflow: hidden; transition: top .8s var(--ease), bottom .8s var(--ease); }
body.is-sky .frame { top: var(--sat); bottom: var(--sab); }
.dim { position: absolute; inset: 0; z-index: 2; pointer-events: none; background: radial-gradient(90% 70% at 50% 50%, rgba(0, 0, 0, .18), rgba(0, 0, 0, .42)); transition: opacity .6s; }
body.is-sky .dim { opacity: 0; }

/* ——— полосы ——— */
.bar { position: fixed; z-index: 30; left: 0; right: 0; height: var(--band); display: flex; align-items: center; gap: 20px; padding: 0 calc(clamp(16px, 3vw, 48px) + var(--sar)) 0 calc(clamp(16px, 3vw, 48px) + var(--sal)); background: #000; }
.bar--top { top: 0; height: calc(var(--band) + var(--sat)); padding-top: var(--sat); justify-content: space-between; }
.bar--bottom { bottom: 0; height: calc(var(--band) + var(--sab)); padding-bottom: var(--sab); }
.brand { font: 600 12.5px/1 var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--cream); }
.bar-right { display: flex; gap: 24px; }
.bar-right button { font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: rgba(236, 228, 216, .7); }
.bar-right button:hover, .bar-right button[aria-pressed="true"] { color: var(--cream); }
.tc { flex: none; font: 500 12px/1 var(--sans); letter-spacing: .12em; font-variant-numeric: tabular-nums; color: rgba(236, 228, 216, .7); }

/* ——— экраны ——— */
.screen {
  position: fixed; z-index: 10; left: 0; right: 0; top: calc(var(--band) + var(--sat)); bottom: calc(var(--band) + var(--sab));
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  padding: 4vh clamp(16px, 5vw, 80px) 3vh;
}
.title-card { display: flex; flex-direction: column; align-items: center; text-align: center; gap: clamp(10px, 2.4vh, 26px); width: 100%; margin: auto 0; }
.hero {
  margin: 0; width: 100%;
  font: 800 clamp(34px, 9vw, 180px)/.98 var(--wide); letter-spacing: -.02em; text-transform: uppercase; color: var(--cream);
  text-shadow: 0 4px 50px rgba(0, 0, 0, .35); text-wrap: balance;
}
.hero [data-fit-line] { display: inline-block; white-space: nowrap; }
.place { margin: 0; font: 600 clamp(14px, 1.7vw, 30px)/1.25 var(--sans); letter-spacing: .3em; padding-left: .3em; text-transform: uppercase; color: var(--cream); text-shadow: 0 2px 20px rgba(0, 0, 0, .5); }
button.place:hover { color: #fff; }
.example { margin: 0; font: 500 11.5px/1.2 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: rgba(236, 228, 216, .7); }
.subs { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; max-width: 760px; }
.subs-line { margin: 0; font: 500 clamp(16px, 1.5vw, 22px)/1.4 var(--sans); color: var(--cream); text-shadow: 0 1px 12px rgba(0, 0, 0, .7), 0 0 2px rgba(0, 0, 0, .6); }
.subs-note { margin: 0; font: 400 clamp(14px, 1.15vw, 17px)/1.5 var(--sans); color: rgba(236, 228, 216, .88); text-shadow: 0 1px 12px rgba(0, 0, 0, .7); max-width: 52ch; }
.play { display: inline-flex; align-items: center; gap: 14px; margin-top: 10px; height: 52px; padding: 0 26px 0 18px; border-radius: 999px; background: var(--cream); color: #0d0b09; font: 600 14px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; }
.play i { width: 0; height: 0; border-left: 12px solid currentColor; border-top: 8px solid transparent; border-bottom: 8px solid transparent; margin-left: 4px; }
.play--again i { width: 14px; height: 14px; border: 2px solid currentColor; border-radius: 50%; border-right-color: transparent; margin: 0; }
.play:hover { background: #fff; }
.hero--finale { font-size: clamp(26px, 5vw, 90px); line-height: 1.04; }

/* положение текста: титр можно поднять или опустить */
body[data-ty="top"] .scene .title-card { margin: 0 0 auto; }
body[data-ty="bottom"] .scene .title-card { margin: auto 0 4vh; }
body[data-tx="left"] .scene .title-card { align-items: flex-start; text-align: left; }
body[data-tx="right"] .scene .title-card { align-items: flex-end; text-align: right; }

[data-swap].is-out { filter: blur(12px); transform: scale(1.03); }

/* ——— таймлайн как полоса просмотра ——— */
.tl { flex: 1; min-width: 0; }
.tl-line { display: none; }
.tl-track { gap: 0; }
.tl-dot { flex: 1 0 auto; display: flex; align-items: center; gap: 10px; min-height: 44px; padding-right: 20px; color: rgba(236, 228, 216, .9); }
.tl-dot::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 3px; margin-top: -1.5px; border-radius: 2px; background: #e5483a; }
.tl-dot.is-active::before { background: linear-gradient(90deg, #e5483a 0 22%, rgba(236, 228, 216, .22) 22%); }
.tl-dot.is-active ~ .tl-dot::before { background: rgba(236, 228, 216, .22); }
.tl.is-past .tl-dot::before { background: #e5483a; }
.tl-pin { position: relative; z-index: 1; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--cream); transition: transform .3s var(--ease); }
.tl-dot.is-active .tl-pin { background: #e5483a; transform: scale(1.5); }
.tl-label { position: relative; z-index: 1; padding: 3px 8px 3px 4px; background: #000; font: 500 11.5px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
.tl-date { margin-right: 6px; opacity: .7; }
.tl-dot.is-active ~ .tl-dot { color: rgba(236, 228, 216, .55); }
.credit { flex: none; margin: 0; max-width: 28ch; text-align: right; }
.credit button { font: 400 10.5px/1.25 var(--sans); color: rgba(236, 228, 216, .5); letter-spacing: .03em; text-align: right; }
body[data-mode="intro"] .tl { visibility: hidden; }

/* ——— панели ——— */
.panel {
  left: 8px; right: 8px; bottom: calc(8px + var(--sab));
  max-height: calc(100svh - 80px - var(--sat)); overflow: auto; overscroll-behavior: contain;
  padding: 22px 22px 20px; background: #0e0d0c; color: var(--cream); font: 400 15px/1.5 var(--sans);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .9), inset 0 0 0 1px rgba(236, 228, 216, .1);
}
.panel-close { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; font: 300 28px/1 var(--sans); color: var(--cream); }
.panel-kick { margin: 0 44px 10px 0; font: 600 11px/1.2 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: #e5483a; }
.panel-title { margin: 0 44px 10px 0; font: 800 24px/1.05 var(--wide); text-transform: uppercase; letter-spacing: -.01em; }
.panel-lead { margin: 0 0 4px; font-weight: 600; }
.panel-small { margin: 0 0 12px; color: rgba(236, 228, 216, .65); font-size: 14px; }
.panel-list { display: grid; grid-template-columns: 112px 1fr; gap: 7px 12px; margin: 12px 0 16px; font-size: 14px; }
.panel-list dt { color: rgba(236, 228, 216, .5); font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; padding-top: 2px; }
.panel-list dd { margin: 0; }
.panel-link { font: 600 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--cream); text-decoration: none; border-bottom: 2px solid #e5483a; padding-bottom: 5px; }
.panel--where { text-align: center; }
.panel--where canvas { width: min(240px, 64vw); margin: 4px auto 10px; --globe-bg: #1a1714; --globe-ink: rgba(236, 228, 216, .92); --globe-line: rgba(236, 228, 216, .14); --globe-accent: #e5483a; }
.panel--where .panel-title { margin: 8px 0 4px; }
.panel-coords { font-size: 12.5px; margin-bottom: 0; }
@media (min-width: 760px) {
  .panel { left: auto; right: 24px; top: calc(var(--band) + 18px + var(--sat)); bottom: auto; width: 420px; }
  .panel--where { width: 340px; }
}

@media (max-width: 640px) {
  :root { --band: 64px; }
  .brand { font-size: 10.5px; letter-spacing: .14em; max-width: 9em; line-height: 1.3; text-align: left; }
  .bar-right { gap: 14px; }
  .bar-right button { font-size: 11.5px; letter-spacing: .08em; }
  .credit { display: none; }
  .tc { font-size: 11px; }
  .place { letter-spacing: .22em; }
  .screen { padding-top: 3vh; }
}
@media (max-height: 520px) {
  :root { --band: 44px; }
  .subs-note { display: none; }
  .play { height: 42px; margin-top: 4px; }
  .credit { display: none; }
}
