/* ============================================
   AI-агенты — Лендинг
   Cosmic premium aesthetic
   ============================================ */

:root {
  --bg-0: #05060f;
  --bg-1: #0a0c1f;
  --bg-2: #0f1230;
  --bg-3: #161a3d;
  --ink: #f5e9d3;
  --ink-dim: rgba(245, 233, 211, 0.62);
  --ink-faint: rgba(245, 233, 211, 0.28);
  --gold: #e9b574;
  --gold-warm: #f0c789;
  --gold-deep: #b8884a;
  --star: #c8d4ff;
  --cool: #7a8cff;
  --line: rgba(245, 233, 211, 0.12);
  --line-strong: rgba(245, 233, 211, 0.22);

  --display: 'Unbounded', 'Manrope', system-ui, sans-serif;
  --body: 'Manrope', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;

  --maxw: 1240px;

  --pad-s: 20px;
  --pad-m: 24px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--bg-0);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(122, 140, 255, 0.08), transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(233, 181, 116, 0.06), transparent 60%),
    var(--bg-0);
  min-height: 100vh;
}

img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
a { color: inherit; text-decoration: none; }

/* ============================================
   Persistent star field (whole page) */
.starfield {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.starfield::before,
.starfield::after {
  content: '';
  position: absolute;
  inset: -50%;
  background-image:
    radial-gradient(1px 1px at 20% 30%, rgba(255, 255, 255, 0.9), transparent),
    radial-gradient(1px 1px at 70% 50%, rgba(200, 212, 255, 0.7), transparent),
    radial-gradient(1.5px 1.5px at 40% 70%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 85% 20%, rgba(233, 181, 116, 0.5), transparent),
    radial-gradient(1px 1px at 15% 85%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(2px 2px at 55% 15%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 90% 90%, rgba(200, 212, 255, 0.5), transparent),
    radial-gradient(1px 1px at 30% 60%, rgba(255, 255, 255, 0.4), transparent);
  background-size: 600px 600px, 800px 800px, 500px 500px, 700px 700px, 900px 900px, 1000px 1000px, 600px 600px, 750px 750px;
  background-repeat: repeat;
  animation: drift 240s linear infinite;
}
.starfield::after {
  background-size: 400px 400px, 350px 350px, 500px 500px, 450px 450px;
  background-image:
    radial-gradient(1px 1px at 25% 25%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 75% 65%, rgba(200, 212, 255, 0.4), transparent),
    radial-gradient(1px 1px at 50% 90%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 10% 50%, rgba(255, 255, 255, 0.3), transparent);
  animation: drift 360s linear infinite reverse;
  opacity: 0.6;
}

@keyframes drift {
  from { transform: translate(0, 0); }
  to { transform: translate(-200px, -300px); }
}

/* ============================================
   Container */
.wrap {
  position: relative;
  z-index: 1;
}

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: var(--pad-s);
  padding-right: var(--pad-s);
}

@media (min-width: 720px) {
  .container { padding-left: 40px; padding-right: 40px; }
}

/* ============================================
   Reveal-on-scroll */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.reveal.in {
  opacity: 1;
  transform: none;
}
.reveal.delay-1 { transition-delay: 0.1s; }
.reveal.delay-2 { transition-delay: 0.2s; }
.reveal.delay-3 { transition-delay: 0.3s; }
.reveal.delay-4 { transition-delay: 0.4s; }
.reveal.delay-5 { transition-delay: 0.5s; }

/* ============================================
   Type primitives */
.eyebrow {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 12px;
  color: var(--gold);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: '';
  width: 24px;
  height: 1px;
  background: currentColor;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.h-display {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(34px, 8vw, 64px);
  line-height: 1.04;
  letter-spacing: -0.025em;
}

.h-section {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(30px, 6vw, 52px);
  line-height: 1.06;
  letter-spacing: -0.02em;
}

.h-card {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(22px, 4vw, 28px);
  line-height: 1.15;
  letter-spacing: -0.015em;
}

.lede {
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.55;
  color: var(--ink-dim);
}

.gold { color: var(--gold); }
.cool-tone { color: var(--cool); }

/* ============================================
   Sections base */
section {
  position: relative;
  padding: 56px 0;
}

@media (min-width: 720px) {
  section { padding: 80px 0; }
}
@media (min-width: 1080px) {
  section { padding: 96px 0; }
}

/* ============================================
   HERO */
.hero {
  min-height: 100svh;
  min-height: 100vh;
  padding: 0;
  overflow: hidden;
  display: flex;
  align-items: stretch;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url('assets/bg-cosmos.jpg') center / cover no-repeat;
  z-index: 0;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 50% 60%, transparent 0%, rgba(5, 6, 15, 0.4) 60%, var(--bg-0) 100%),
    linear-gradient(180deg, rgba(5, 6, 15, 0.5) 0%, transparent 30%, transparent 70%, var(--bg-0) 100%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  flex-direction: column;
}

.hero-top {
  padding: 16px var(--pad-s);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  background: linear-gradient(180deg, rgba(5, 6, 15, 0.55), rgba(5, 6, 15, 0.15));
}

.brand {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}
.brand-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 12px var(--gold);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.hero-meta {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-faint);
  text-align: right;
}

.hero-stage {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 16px var(--pad-s) 24px;
}

@media (min-width: 720px) {
  .hero-stage {
    justify-content: space-between;
    gap: 16px;
    padding: 24px var(--pad-s) 32px;
  }
}

@media (max-width: 719px) {
  .hero { min-height: auto; }
  .hero-headline { margin-bottom: 0; }
  .character-wrap { margin-top: -8px; }
}

.hero-headline {
  position: relative;
  z-index: 3;
  text-align: center;
  max-width: 920px;
  margin: 0 auto;
  padding: 0;
  width: 100%;
}

.hero-headline h1 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(22px, 6.2vw, 70px);
  line-height: 1.08;
  letter-spacing: -0.025em;
  color: var(--ink);
  text-shadow: 0 4px 60px rgba(5, 6, 15, 0.8);
  word-break: break-word;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.hero-headline h1 .accent {
  color: var(--gold);
  font-style: italic;
  font-weight: 300;
}

.hero-headline h1 .author {
  display: inline;
  position: relative;
}

.character-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 520px;
  margin: 0 auto -10px;
  display: flex;
  justify-content: center;
  pointer-events: none;
}

.character-halo {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.character-halo::before {
  content: '';
  width: 90%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233, 181, 116, 0.25) 0%, rgba(233, 181, 116, 0.08) 35%, transparent 65%);
  filter: blur(20px);
  animation: haloPulse 6s ease-in-out infinite;
}

@keyframes haloPulse {
  0%, 100% { transform: scale(1); opacity: 0.9; }
  50% { transform: scale(1.08); opacity: 1; }
}

.character {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 24px 60px rgba(0, 0, 0, 0.55));
  animation: levitate 7s ease-in-out infinite;
  transform-origin: center bottom;
}

@keyframes levitate {
  0%, 100% { transform: translateY(0) rotate(-0.5deg); }
  25%     { transform: translateY(-14px) rotate(0.3deg); }
  50%     { transform: translateY(-26px) rotate(0.6deg); }
  75%     { transform: translateY(-14px) rotate(-0.2deg); }
}

/* Hero entrance: ambient zoom + halo bloom on load */
@keyframes heroEnter {
  from { opacity: 0; transform: scale(1.06); filter: blur(8px); }
  to   { opacity: 1; transform: scale(1); filter: blur(0); }
}
.character {
  animation: heroEnter 1.6s cubic-bezier(0.2, 0.8, 0.2, 1) both, levitate 7s ease-in-out infinite 1.6s;
}

/* Orbital rings around character */
.orbit-rings {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 1;
}
.orbit {
  position: absolute;
  border: 1px solid rgba(233, 181, 116, 0.18);
  border-radius: 50%;
  animation: orbitSpin 30s linear infinite;
}
.orbit-1 { width: 70%; aspect-ratio: 1; border-color: rgba(233, 181, 116, 0.22); }
.orbit-2 { width: 95%; aspect-ratio: 1; border-color: rgba(233, 181, 116, 0.12); animation-duration: 45s; animation-direction: reverse; }
.orbit-3 { width: 120%; aspect-ratio: 1; border-color: rgba(122, 140, 255, 0.08); animation-duration: 60s; }
@keyframes orbitSpin {
  from { transform: rotate(0); }
  to   { transform: rotate(360deg); }
}
.orbit::before {
  content: '';
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 16px var(--gold);
  top: -4px;
  left: 50%;
  transform: translateX(-50%);
}
.orbit-2::before { background: var(--cool); box-shadow: 0 0 16px var(--cool); width: 6px; height: 6px; left: 80%; }
.orbit-3::before { background: var(--gold-warm); width: 5px; height: 5px; left: 25%; opacity: 0.7; }

/* Headline word-by-word reveal */
.hero-headline h1 .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(28px);
  filter: blur(6px);
  animation: wordIn 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
@keyframes wordIn {
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

/* Shooting star occasional */
.shooting-star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.3);
  animation: shoot 7s linear infinite;
  opacity: 0;
}
.shooting-star::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 0;
  width: 80px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.8));
  transform: translateY(-50%);
}
@keyframes shoot {
  0%   { opacity: 0; transform: translate(0, 0); }
  3%   { opacity: 1; }
  10%  { opacity: 0; transform: translate(-220px, 140px); }
  100% { opacity: 0; transform: translate(-220px, 140px); }
}
.shooting-star.s1 { top: 18%; right: 10%; animation-delay: 2s; }
.shooting-star.s2 { top: 35%; right: 30%; animation-delay: 9s; }

/* small twinkles around character */
.twinkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.twinkle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--gold);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--gold);
  animation: twinkle 3s ease-in-out infinite;
  opacity: 0;
}
@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(0.5); }
  50%      { opacity: 1; transform: scale(1.2); }
}

.scroll-cue {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--ink-faint);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 4;
}
.scroll-cue::after {
  content: '';
  width: 1px;
  height: 36px;
  background: linear-gradient(180deg, var(--ink-faint), transparent);
  animation: scrollDown 2s ease-in-out infinite;
}
@keyframes scrollDown {
  0% { transform: scaleY(0.2); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  100% { transform: scaleY(0.2); transform-origin: bottom; }
}

@media (min-width: 720px) {
  .hero-top { padding: 32px 40px; }
  .character-wrap { max-width: 680px; margin-bottom: -20px; }
  .hero-stage { padding-bottom: 80px; }
}
@media (min-width: 1080px) {
  .character-wrap { max-width: 780px; }
}

/* Desktop: текст слева, персонаж справа */
@media (min-width: 1024px) {
  .hero-stage {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
    padding: 40px 48px 100px;
    max-width: var(--maxw);
    margin: 0 auto;
    width: 100%;
  }
  .hero-headline {
    flex: 1 1 52%;
    text-align: left;
    margin: 0;
    max-width: none;
  }
  .hero-headline h1 {
    font-size: clamp(40px, 3.6vw, 60px);
    line-height: 1.08;
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: manual;
    text-shadow: 0 4px 60px rgba(5, 6, 15, 0.8);
  }
  .hero-headline h1 .word { margin-right: 0.22em; }
  .character-wrap {
    flex: 0 0 auto;
    width: 44%;
    max-width: 520px;
    margin: 0;
  }
  .scroll-cue {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
  }
}

@media (min-width: 1280px) {
  .hero-stage { gap: 64px; padding: 48px 64px 120px; }
  .hero-headline h1 { font-size: clamp(48px, 3.4vw, 60px); }
  .character-wrap { max-width: 580px; }
}

@media (min-width: 1600px) {
  .hero-headline h1 { font-size: 60px; }
  .character-wrap { max-width: 600px; }
}
@media (min-width: 1920px) {
  .hero-stage { max-width: 1440px; }
  .hero-headline h1 { font-size: 64px; }
}

/* ============================================
   BLOCK 2 — Origin (film strip narrative) */
.origin {
  background: linear-gradient(180deg, var(--bg-0) 0%, var(--bg-1) 100%);
  position: relative;
  overflow: hidden;
}
.origin::before {
  content: '';
  position: absolute;
  top: 8%;
  right: -10%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233, 181, 116, 0.08), transparent 60%);
  pointer-events: none;
  filter: blur(20px);
}

.origin-grid {
  display: grid;
  gap: 40px;
  margin-bottom: 56px;
  align-items: start;
}
@media (min-width: 960px) {
  .origin-grid {
    grid-template-columns: 1fr 1.15fr;
    gap: 64px;
    align-items: center;
  }
}

.origin-intro .eyebrow { margin-bottom: 14px; }
.origin-intro h2 { margin-bottom: 22px; }
.origin-intro h2 .gold { font-style: italic; font-weight: 300; }
.origin-lede { margin-bottom: 32px; max-width: 520px; }

.origin-meta {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  padding: 14px 22px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(8px);
}
.om-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.om-num {
  font-family: var(--display);
  font-weight: 400;
  font-size: 28px;
  line-height: 1;
  color: var(--gold);
  letter-spacing: -0.02em;
}
.om-lab {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--ink-dim);
}
.om-sep {
  width: 1px;
  height: 18px;
  background: var(--line);
}

/* Film strip — three frames overlapping in a staircase */
.origin-film {
  position: relative;
  display: grid;
  gap: 14px;
  min-height: 480px;
}
@media (min-width: 720px) {
  .origin-film {
    min-height: 620px;
  }
}

.film-frame {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-2);
  border: 1px solid var(--line);
  box-shadow:
    0 30px 80px -20px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(245, 233, 211, 0.04);
  opacity: 0;
  transform: translateY(40px) scale(0.94);
  transition: transform 1s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 1s, box-shadow 0.4s, border-color 0.4s;
  will-change: transform;
}
.film-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.05);
}
.film-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 50%, rgba(5, 6, 15, 0.85) 100%);
  pointer-events: none;
}

/* Mobile: stacked aspect-square cards */
.film-frame {
  aspect-ratio: 4/3;
}
.ff1 { aspect-ratio: 4/5; }
.ff2 { aspect-ratio: 1/1; }
.ff3 { aspect-ratio: 4/3; }

/* Desktop: overlapping staircase */
@media (min-width: 720px) {
  .origin-film { display: block; height: 620px; }
  .film-frame {
    position: absolute;
  }
  .ff1 {
    top: 0;
    left: 0;
    width: 52%;
    height: 70%;
    aspect-ratio: auto;
    transform: translateY(40px) rotate(-2deg) scale(0.94);
    z-index: 3;
  }
  .ff2 {
    top: 12%;
    right: 0;
    width: 48%;
    height: 56%;
    aspect-ratio: auto;
    transform: translateY(40px) rotate(1.5deg) scale(0.94);
    z-index: 2;
  }
  .ff3 {
    bottom: 0;
    left: 22%;
    width: 60%;
    height: 50%;
    aspect-ratio: auto;
    transform: translateY(40px) rotate(-1deg) scale(0.94);
    z-index: 4;
  }
}

.origin-film.in .ff1 {
  opacity: 1;
  transform: translateY(0) rotate(0deg) scale(1);
  transition-delay: 0.1s;
}
.origin-film.in .ff2 {
  opacity: 1;
  transform: translateY(0) rotate(0deg) scale(1);
  transition-delay: 0.3s;
}
.origin-film.in .ff3 {
  opacity: 1;
  transform: translateY(0) rotate(0deg) scale(1);
  transition-delay: 0.5s;
}

@media (min-width: 720px) {
  .origin-film.in .ff1 { transform: translateY(0) rotate(-2deg) scale(1); }
  .origin-film.in .ff2 { transform: translateY(0) rotate(1.5deg) scale(1); }
  .origin-film.in .ff3 { transform: translateY(0) rotate(-1deg) scale(1); }
}

@media (min-width: 720px) {
  .film-frame:hover {
    border-color: rgba(233, 181, 116, 0.4);
    box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(233, 181, 116, 0.3);
  }
}

/* Cinema-style corner brackets */
.film-corner {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 1px solid rgba(233, 181, 116, 0.7);
  z-index: 5;
  pointer-events: none;
}
.film-corner-tl { top: 8px; left: 8px; border-right: 0; border-bottom: 0; }
.film-corner-tr { top: 8px; right: 8px; border-left: 0; border-bottom: 0; }
.film-corner-bl { bottom: 8px; left: 8px; border-right: 0; border-top: 0; }
.film-corner-br { bottom: 8px; right: 8px; border-left: 0; border-top: 0; }

.film-meta {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  background: rgba(5, 6, 15, 0.75);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(245, 233, 211, 0.12);
  border-radius: 999px;
  z-index: 6;
  white-space: nowrap;
}
.fm-tag {
  font-family: var(--mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
}
.fm-loc {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  color: var(--ink);
}

.film-overlay-num {
  position: absolute;
  bottom: 12px;
  right: 16px;
  font-family: var(--display);
  font-weight: 300;
  font-size: 64px;
  line-height: 1;
  color: rgba(245, 233, 211, 0.18);
  letter-spacing: -0.05em;
  z-index: 5;
  mix-blend-mode: screen;
}

.film-trajectory {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 1.4s ease 0.8s;
  display: none;
}
@media (min-width: 720px) {
  .film-trajectory { display: block; }
}
.origin-film.in .film-trajectory { opacity: 1; }
.ftraj {
  stroke-dasharray: 3 5;
  animation: dashSlide 24s linear infinite;
}
@keyframes dashSlide {
  to { stroke-dashoffset: -200; }
}

/* Quote card */
.origin-quote {
  position: relative;
  max-width: 760px;
  margin: 0 auto 56px;
  padding: 36px 28px 32px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(ellipse at top right, rgba(233, 181, 116, 0.08), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  text-align: left;
}
.oq-mark {
  font-family: var(--display);
  font-weight: 300;
  font-size: 80px;
  line-height: 0.7;
  color: var(--gold);
  position: absolute;
  top: 14px;
  left: 24px;
  opacity: 0.6;
}
.origin-quote p {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(18px, 2.4vw, 24px);
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--ink);
  padding-left: 56px;
  margin-bottom: 16px;
}
.oq-author {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  padding-left: 56px;
}

/* Origin points — step layout */
.origin-points {
  display: grid;
  gap: 14px;
  max-width: 960px;
  margin: 0 auto;
}
@media (min-width: 720px) {
  .origin-points {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    position: relative;
  }
  .origin-points::before { content: none; }
}

.point {
  position: relative;
  padding: 24px 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  z-index: 1;
  overflow: hidden;
  transition: border-color 0.4s, transform 0.4s;
}
.point:hover {
  border-color: rgba(233, 181, 116, 0.3);
  transform: translateY(-2px);
}
.point-step {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.point .num {
  font-family: var(--display);
  font-weight: 300;
  font-size: 38px;
  line-height: 1;
  color: var(--gold);
  letter-spacing: -0.03em;
}
.step-arrow {
  font-family: var(--display);
  font-size: 22px;
  color: var(--ink-faint);
  transition: color 0.3s, transform 0.3s;
}
.gold-arrow {
  color: var(--gold);
  font-size: 28px;
}
.point:hover .step-arrow {
  color: var(--gold);
  transform: translateX(4px);
}
.point p {
  font-size: 16px;
  color: var(--ink);
  line-height: 1.4;
}
.point::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 30%;
  height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
}

.section-head {
  text-align: center;
  margin-bottom: 40px;
}
.section-head .eyebrow { margin-bottom: 14px; }
@media (min-width: 720px) {
  .section-head { margin-bottom: 56px; }
}

/* (legacy collage / photo / point rules replaced by film-strip layout above) */

/* ============================================
   BLOCK 3 — Для кого */
.audience {
  background: var(--bg-1);
  position: relative;
  overflow: hidden;
}
.audience::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  border: 1px solid var(--line);
  top: -200px;
  right: -200px;
  pointer-events: none;
}
.audience::after {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  border: 1px solid var(--line);
  bottom: -120px;
  left: -120px;
  pointer-events: none;
}

.audience .container { position: relative; z-index: 1; }

.audience-list {
  display: grid;
  gap: 20px;
  margin-bottom: 40px;
}
@media (min-width: 720px) {
  .audience-list { grid-template-columns: repeat(3, 1fr); gap: 24px; }
}

.aud-card {
  padding: 34px 26px 32px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  position: relative;
  overflow: hidden;
  transition: transform 0.5s, border-color 0.5s;
}
.aud-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
}

.aud-card .ellipsis {
  font-family: var(--display);
  font-weight: 300;
  font-style: italic;
  font-size: 38px;
  color: var(--gold);
  display: block;
  margin-bottom: 14px;
  line-height: 0.6;
}

.aud-card p {
  font-size: 17px;
  line-height: 1.45;
}
.aud-card .lead {
  font-family: var(--display);
  font-weight: 500;
  font-size: 22px;
  color: var(--ink);
  margin-bottom: 8px;
  display: block;
  letter-spacing: -0.01em;
}

.audience-close {
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
  padding: 36px 24px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(18px, 3vw, 26px);
  line-height: 1.35;
  letter-spacing: -0.01em;
}
.audience-close .gold { font-style: italic; font-weight: 300; }

/* ============================================
   BLOCK 4 — Программа */
.program {
  background: linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  position: relative;
}

.program-cols {
  display: grid;
  gap: 22px;
  margin-bottom: 64px;
}
@media (min-width: 880px) {
  .program-cols { grid-template-columns: 1fr 1fr; gap: 28px; }
}

.col {
  padding: 32px 24px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse at top right, rgba(233, 181, 116, 0.08), transparent 50%),
    linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  position: relative;
  overflow: hidden;
}
.col-2 {
  background:
    radial-gradient(ellipse at top left, rgba(122, 140, 255, 0.08), transparent 50%),
    linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
}
.col-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.col-head .tag {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
}
.col-2 .col-head .tag { color: var(--cool); }

.col h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(22px, 3vw, 28px);
  letter-spacing: -0.015em;
  line-height: 1.15;
}
.col-head { display: block; }
.col-head .tag { display: block; margin-bottom: 8px; }

.col ul {
  list-style: none;
  display: grid;
  gap: 14px;
}
.col li {
  position: relative;
  padding-left: 28px;
  font-size: 16px;
  line-height: 1.45;
}
.col li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 14px;
  height: 1px;
  background: var(--gold);
}
.col-2 li::before { background: var(--cool); }

/* Schedule */
.schedule-head {
  text-align: center;
  margin-bottom: 48px;
}

.schedule {
  position: relative;
  display: grid;
  gap: 20px;
}

@media (min-width: 880px) {
  .schedule { gap: 24px; }
}

.day {
  position: relative;
  border-radius: 22px;
  border: 1px solid var(--line);
  padding: 28px 24px 26px;
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  display: grid;
  gap: 14px;
  transition: border-color 0.4s, transform 0.4s;
}
.day:hover {
  border-color: rgba(233, 181, 116, 0.3);
  transform: translateY(-2px);
}

.day-meta {
  display: flex;
  align-items: center;
  gap: 14px;
}
.day-num {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.day-num .planet {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  position: relative;
  background: radial-gradient(circle at 30% 30%, var(--gold-warm), var(--gold-deep));
  box-shadow: 0 0 16px rgba(233, 181, 116, 0.5);
  flex-shrink: 0;
}
.day:nth-child(2) .day-num .planet { background: radial-gradient(circle at 30% 30%, #c8d4ff, #5e6ec8); box-shadow: 0 0 16px rgba(122, 140, 255, 0.5); }
.day:nth-child(3) .day-num .planet { background: radial-gradient(circle at 30% 30%, #f5b28a, #a35a3a); }
.day:nth-child(4) .day-num .planet { background: radial-gradient(circle at 30% 30%, #b5dfd4, #4f8a7c); }
.day:nth-child(5) .day-num .planet { background: radial-gradient(circle at 30% 30%, #e9b574, #b8884a); }
.day:nth-child(6) .day-num .planet { background: radial-gradient(circle at 30% 30%, #ffd596, #cf7d2e); box-shadow: 0 0 24px rgba(255, 200, 130, 0.7); }

.day h4 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(20px, 3vw, 26px);
  letter-spacing: -0.015em;
  line-height: 1.18;
  color: var(--ink);
}

.day p {
  font-size: 16px;
  color: var(--ink-dim);
  line-height: 1.5;
}

.day .outcome {
  margin-top: 8px;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(233, 181, 116, 0.06);
  border: 1px solid rgba(233, 181, 116, 0.18);
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--ink);
}
.day .outcome .label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  display: block;
  margin-bottom: 4px;
}

@media (min-width: 880px) {
  .day { padding: 32px 32px 30px; grid-template-columns: 220px 1fr; align-items: start; gap: 28px; }
  .day-meta { flex-direction: column; align-items: flex-start; gap: 12px; padding-top: 4px; }
  .day-content { display: grid; gap: 14px; }
}

.day-list {
  list-style: none;
  margin: 4px 0 2px;
  padding: 0;
  display: grid;
  gap: 8px;
}
.day-list li {
  position: relative;
  padding-left: 20px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-dim);
}
.day-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 8px;
  height: 1px;
  background: rgba(233, 181, 116, 0.7);
}

/* ============================================
   BLOCK 5 — Не нужно быть технарём */
.not-techie {
  background: var(--bg-0);
  position: relative;
  overflow: hidden;
}
.not-techie .character-mini {
  position: absolute;
  width: 220px;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.18;
  filter: drop-shadow(0 12px 30px rgba(0,0,0,0.5));
  pointer-events: none;
}
@media (min-width: 720px) {
  .not-techie .character-mini { width: 360px; right: -60px; opacity: 0.22; }
}

.not-techie .container { position: relative; z-index: 1; }

.tech-grid {
  display: grid;
  gap: 22px;
  margin-top: 48px;
}
@media (min-width: 720px) {
  .tech-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}

.tech-card {
  padding: 28px 24px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
}
.tech-card h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 22px;
  margin-bottom: 20px;
  letter-spacing: -0.015em;
}
.tech-card.no h3 { color: var(--ink-dim); }
.tech-card.yes h3 { color: var(--gold); }

.tech-card ul { list-style: none; display: grid; gap: 12px; }
.tech-card li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 16px;
  line-height: 1.4;
}
.tech-card.no li { color: var(--ink-dim); }
.tech-card.no .icon {
  width: 22px; height: 22px; flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  position: relative;
  margin-top: 1px;
}
.tech-card.no .icon::before, .tech-card.no .icon::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 1px;
  background: var(--ink-dim);
  top: 50%;
  left: 50%;
  transform-origin: center;
}
.tech-card.no .icon::before { transform: translate(-50%, -50%) rotate(45deg); }
.tech-card.no .icon::after { transform: translate(-50%, -50%) rotate(-45deg); }

.tech-card.yes .icon {
  width: 22px; height: 22px; flex-shrink: 0;
  border-radius: 50%;
  background: rgba(233, 181, 116, 0.18);
  border: 1px solid var(--gold);
  position: relative;
  margin-top: 1px;
}
.tech-card.yes .icon::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 10px;
  border-right: 1.5px solid var(--gold);
  border-bottom: 1.5px solid var(--gold);
  transform: translate(-55%, -65%) rotate(45deg);
}

.tech-headline-block {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.tech-headline-block .lede { margin-top: 18px; }

/* ============================================
   BLOCK 6 — P.S. */
.ps {
  background: var(--bg-0);
  padding-top: 0;
}
.ps-card {
  position: relative;
  max-width: 880px;
  margin: 0 auto;
  padding: 48px 28px;
  border-radius: 28px;
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse at center, rgba(233, 181, 116, 0.06), transparent 70%),
    linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0));
  overflow: hidden;
  text-align: center;
}
.ps-card::before {
  content: 'P.S.';
  position: absolute;
  top: 24px;
  left: 28px;
  font-family: var(--display);
  font-weight: 300;
  font-style: italic;
  font-size: 18px;
  color: var(--gold);
  letter-spacing: -0.01em;
}
.ps-timer {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--ink-faint);
  display: inline-flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 24px;
}
.ps-timer .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); animation: pulse 1.6s ease-in-out infinite; }
.ps h2 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 22px;
}
.ps p {
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.55;
  color: var(--ink-dim);
  max-width: 640px;
  margin: 0 auto;
}

@media (min-width: 720px) {
  .ps-card { padding: 72px 56px; }
}

/* ============================================
   BLOCK 7 — Цена */
.price {
  background: linear-gradient(180deg, var(--bg-0) 0%, #0c0e26 50%, var(--bg-0) 100%);
  position: relative;
  overflow: hidden;
}
.price::before {
  content: '';
  position: absolute;
  width: 800px;
  height: 800px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233, 181, 116, 0.12), transparent 60%);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  filter: blur(40px);
}

.price-card {
  position: relative;
  z-index: 1;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
  padding: 24px 24px;
}

.price-old-block {
  margin-bottom: 28px;
}
.price-old {
  display: inline-block;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(38px, 8vw, 64px);
  color: rgba(245, 233, 211, 0.55);
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  position: relative;
  line-height: 1;
}
.price-old::after {
  content: '';
  position: absolute;
  left: -8%;
  right: -8%;
  top: 52%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold) 20%, var(--gold) 80%, transparent);
  transform: rotate(-6deg);
  border-radius: 2px;
}
.price-old-note {
  display: block;
  font-size: clamp(14px, 2vw, 17px);
  color: var(--ink-dim);
  font-style: italic;
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: -0.005em;
  max-width: 460px;
  margin: 0 auto;
}
.price-old-note-mono {
  display: none;
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--ink-faint);
  text-decoration: none;
  margin-top: 0;
  margin-bottom: 20px;
}

.price-current {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(56px, 14vw, 128px);
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(180deg, var(--gold-warm) 0%, var(--gold) 50%, var(--gold-deep) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 8px 0 16px;
  position: relative;
}
.price-current sup {
  font-size: 0.4em;
  font-weight: 300;
  vertical-align: super;
  margin-left: 0.1em;
  -webkit-text-fill-color: var(--gold);
}

.price-stream {
  font-family: var(--mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 36px;
  display: block;
}

.price-meta {
  display: grid;
  gap: 18px;
  max-width: 520px;
  margin: 0 auto;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.price-meta .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  font-size: 16px;
  text-align: left;
}
.price-meta .row .k {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--ink-faint);
}
.price-meta .row .v { color: var(--ink); font-weight: 500; }

/* ============================================
   BLOCK 8 — Final CTA */
.cta {
  background: var(--bg-0);
  padding: 80px 0 96px;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 70% at 50% 90%, rgba(233, 181, 116, 0.18), transparent 60%);
  pointer-events: none;
}
.cta-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}
.cta h2 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(32px, 6vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin-bottom: 14px;
}
.cta h2 .accent { color: var(--gold); font-style: italic; font-weight: 300; }

.cta-sub {
  font-size: clamp(15px, 2vw, 18px);
  color: var(--ink-dim);
  margin-bottom: 44px;
}

.btn-launch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 22px 44px;
  font-family: var(--display);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #1a1305;
  background: linear-gradient(180deg, var(--gold-warm), var(--gold));
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(255, 220, 170, 0.4) inset,
    0 0 60px rgba(233, 181, 116, 0.5),
    0 20px 60px -10px rgba(233, 181, 116, 0.6);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.3s;
  overflow: hidden;
}
.btn-launch:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 0 0 1px rgba(255, 220, 170, 0.5) inset,
    0 0 80px rgba(233, 181, 116, 0.7),
    0 28px 70px -10px rgba(233, 181, 116, 0.8);
}
.btn-launch:active { transform: translateY(0) scale(0.99); }

.btn-launch .rocket {
  display: inline-block;
  width: 22px;
  height: 22px;
  position: relative;
  transform: rotate(-45deg);
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.btn-launch:hover .rocket { transform: rotate(-45deg) translate(4px, -4px); }

.cta-trail {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 2px;
  height: 80px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, var(--gold), transparent);
  opacity: 0.4;
}

/* ============================================
   FOOTER */
footer {
  border-top: 1px solid var(--line);
  background: #03040a;
  padding: 40px 0 56px;
  font-size: 13px;
  color: var(--ink-faint);
  position: relative;
  z-index: 1;
}
footer .container {
  display: grid;
  gap: 24px;
}

.foot-info {
  display: grid;
  gap: 6px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.05em;
}
.foot-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.foot-links a {
  color: var(--ink-dim);
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 0.3s, border-color 0.3s;
}
.foot-links a:hover { color: var(--gold); border-color: var(--gold); }

@media (min-width: 720px) {
  footer .container { grid-template-columns: 1fr auto; align-items: end; }
}

/* ============================================
   Selection */
::selection {
  background: rgba(233, 181, 116, 0.4);
  color: var(--ink);
}

/* ============================================
   Hero — word-by-word headline spacing */
.hero-headline h1 .word {
  margin-right: 0.16em;
}
.hero-headline h1 .word:last-child {
  margin-right: 0;
}
@media (max-width: 480px) {
  .hero-headline h1 .word { margin-right: 0.12em; }
}

/* (block 2 enhancement legacy rules removed; new film-strip block lives above) */

/* ============================================
   BLOCK 4 — 3-col program grid */
@media (min-width: 880px) {
  .program-cols-3 { grid-template-columns: 1fr 1fr 1fr; gap: 20px; }
}
.col-3 {
  background:
    radial-gradient(ellipse at top right, rgba(233, 181, 116, 0.10), transparent 50%),
    linear-gradient(180deg, rgba(233, 181, 116, 0.04), rgba(255,255,255,0));
  border-color: rgba(233, 181, 116, 0.22);
  position: relative;
}
.col-3::after {
  content: '';
  position: absolute;
  top: -1px;
  left: 8%;
  right: 8%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}
.col-3 .col-head .tag { color: var(--gold-warm); }
.col-3 li::before { background: var(--gold-warm); width: 16px; }
.col-3 li {
  font-weight: 500;
}

/* On mobile / narrow, allow 3-col to stack like the 2-col grid */
@media (max-width: 879px) {
  .program-cols-3 { grid-template-columns: 1fr; }
}


/* ============================================
   Modals — Договор-оферта / Политика
   ============================================ */
body.modal-locked { overflow: hidden; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 48px);
  opacity: 0;
  transition: opacity .22s ease;
}
.modal.is-open { opacity: 1; }
.modal[hidden] { display: none; }

.modal-backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 50% 30%, rgba(122, 140, 255, 0.12), transparent 65%),
    rgba(5, 6, 15, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.modal-window {
  position: relative;
  z-index: 1;
  width: min(760px, 100%);
  max-height: min(86vh, 920px);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  box-shadow:
    0 30px 80px -20px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(233, 181, 116, 0.08) inset;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: translateY(12px) scale(0.98);
  transition: transform .24s ease;
}
.modal.is-open .modal-window { transform: translateY(0) scale(1); }

.modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 22px;
  line-height: 1;
  color: var(--ink-dim);
  background: rgba(245, 233, 211, 0.06);
  transition: background .15s ease, color .15s ease, transform .15s ease;
  z-index: 2;
}
.modal-close:hover { background: rgba(233, 181, 116, 0.18); color: var(--gold); transform: scale(1.05); }

.modal-body {
  padding: clamp(28px, 4vw, 44px);
  padding-right: clamp(28px, 4vw, 56px);
  overflow-y: auto;
  color: var(--ink-dim);
  font-size: 15px;
  line-height: 1.65;
  scrollbar-width: thin;
  scrollbar-color: rgba(233, 181, 116, 0.25) transparent;
}
.modal-body::-webkit-scrollbar { width: 8px; }
.modal-body::-webkit-scrollbar-thumb { background: rgba(233, 181, 116, 0.25); border-radius: 4px; }
.modal-body::-webkit-scrollbar-track { background: transparent; }

.modal-body h2 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(22px, 3vw, 30px);
  color: var(--ink);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.modal-body h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: 16px;
  color: var(--gold);
  margin-top: 22px;
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}
.modal-body p { margin-bottom: 10px; }
.modal-body p:last-child { margin-bottom: 0; }
.modal-body a { color: var(--gold-warm); border-bottom: 1px solid rgba(233, 181, 116, 0.3); }
.modal-body a:hover { color: var(--gold); border-bottom-color: var(--gold); }

.modal-meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-faint);
  margin-bottom: 18px !important;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

@media (max-width: 600px) {
  .modal { padding: 0; }
  .modal-window {
    width: 100%;
    max-height: 100vh;
    height: 100vh;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
}

/* ============================================
   Reduced motion
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
  .word { opacity: 1 !important; transform: none !important; }
}

/* Не разрывать предлог + следующее слово */
.hero-headline h1 .nobr {
  white-space: nowrap;
  display: inline-block;
}

.day-duration {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  white-space: nowrap;
}
