/* ============================================================
   Лендинг — вертикальный scroll-snap сторителлинг.
   5 секций: герой → что это → игры → направление → старт.
   ============================================================ */

#landing {
  position: relative;
}
body.snap {
  scroll-snap-type: y proximity;
}
.snap-sec {
  position: relative;
  min-height: 100vh;
  scroll-snap-align: start;
  display: flex;
  align-items: center;
  padding: clamp(70px, 10vh, 120px) 0 90px;
  overflow: hidden;
}

/* --- Верхняя мини-панель лендинга --- */
.l-top {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-topbar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--pad-page);
  transition: background var(--dur-2) var(--ease), border-color var(--dur-2);
  border-bottom: 1px solid transparent;
}
.l-top.scrolled {
  background: rgba(5, 7, 12, 0.72);
  border-bottom-color: var(--hairline);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.l-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.l-brand img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  clip-path: circle(50%);
  box-shadow: 0 0 0 1px var(--stroke);
}
.l-brand b {
  font-weight: 700;
  font-size: var(--fs-sm);
  letter-spacing: 0.02em;
}
.l-brand span {
  display: block;
  font-size: var(--fs-xs);
  color: var(--text-faint);
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
}

/* --- Прогресс скролла (сверху) --- */
.l-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: var(--grad-gold);
  z-index: calc(var(--z-topbar) + 1);
  box-shadow: var(--glow-gold);
  transition: width 0.1s linear;
}

/* --- Точки-навигация (справа) --- */
.l-dots {
  position: fixed;
  right: 26px;
  top: 50%;
  transform: translateY(-50%);
  z-index: var(--z-topbar);
  display: grid;
  gap: 14px;
}
.l-dots button {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1px solid var(--stroke-strong);
  background: transparent;
  cursor: pointer;
  padding: 0;
  transition: all var(--dur-2) var(--ease);
}
.l-dots button.active {
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: var(--glow-gold);
  transform: scale(1.25);
}

/* --- Подсказка «листай вниз» --- */
.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 34px;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 8px;
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.scroll-hint .mouse {
  width: 24px;
  height: 38px;
  border: 2px solid var(--stroke-strong);
  border-radius: 14px;
  position: relative;
}
.scroll-hint .mouse::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 7px;
  width: 4px;
  height: 7px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--gold);
  animation: wheel 1.5s var(--ease) infinite;
}
@keyframes wheel {
  0% {
    opacity: 0;
    transform: translateY(0);
  }
  40% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ============== Секция 1 — Герой ============== */
.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(30px, 5vw, 80px);
  align-items: center;
  width: 100%;
}
.hero-copy {
  max-width: 620px;
}
.hero h1 {
  font-size: var(--fs-hero);
  font-weight: 800;
  margin: 20px 0 18px;
}
.hero h1 em {
  font-style: italic;
  color: var(--gold);
}
.hero-lead {
  font-size: var(--fs-lead);
  color: var(--text-dim);
  max-width: 48ch;
}
.hero-cta {
  display: flex;
  gap: 14px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.hero-meta {
  display: flex;
  gap: 26px;
  margin-top: 34px;
  flex-wrap: wrap;
}
.hero-meta .m {
  display: grid;
}
.hero-meta .m b {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  color: var(--text);
  line-height: 1;
}
.hero-meta .m span {
  font-size: var(--fs-xs);
  color: var(--text-faint);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-top: 6px;
}

/* Орбита-логотип */
.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 440px;
}
/* Круг режет контейнер (не img) — стабильно в fullscreen Chrome */
.hero-orb-wrap {
  width: clamp(240px, 27vw, 380px);
  height: clamp(240px, 27vw, 380px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
  clip-path: circle(50% at 50% 50%);
  -webkit-clip-path: circle(50% at 50% 50%);
  box-shadow: var(--glow-gold), 0 24px 70px rgba(0, 0, 0, 0.45);
  animation: orbFloat 8s ease-in-out infinite;
  position: relative;
  z-index: 2;
}
.hero-orb {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}
@keyframes orbFloat {
  0%,
  100% {
    transform: translateY(-9px) scale(1);
  }
  50% {
    transform: translateY(9px) scale(1.012);
  }
}
.orb-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--stroke);
  pointer-events: none;
  will-change: transform;
}
.orb-ring.r1 {
  width: clamp(300px, 34vw, 460px);
  height: clamp(300px, 34vw, 460px);
  border-style: dashed;
  animation: spin 42s linear infinite;
}
.orb-ring.r2 {
  width: clamp(370px, 42vw, 560px);
  height: clamp(370px, 42vw, 560px);
  border-color: var(--hairline);
  animation: spin 70s linear infinite reverse;
}
.orb-ring .sat {
  position: absolute;
  top: -7px;
  left: 50%;
  width: 14px;
  height: 14px;
  margin-left: -7px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: var(--glow-cyan);
}
.orb-glow {
  position: absolute;
  width: 70%;
  height: 70%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(232, 195, 106, 0.3), transparent 60%);
  filter: blur(40px);
  z-index: 1;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ============== Секция 2 — Что это ============== */
.sec-head {
  max-width: 720px;
  margin-bottom: clamp(32px, 5vh, 60px);
}
.sec-head h2 {
  font-size: var(--fs-h1);
  margin: 16px 0 14px;
}
.sec-head p {
  color: var(--text-dim);
  font-size: var(--fs-lead);
}
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  width: 100%;
}
.step {
  padding: 30px 26px;
  border-radius: var(--r-lg);
  position: relative;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2);
}
.step:hover {
  transform: translateY(-6px);
  border-color: var(--stroke-strong);
}
.step .num {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  color: var(--gold);
  letter-spacing: 0.2em;
}
.step h3 {
  font-size: var(--fs-h3);
  margin: 14px 0 10px;
  font-family: var(--font-ui);
  font-weight: 700;
}
.step p {
  color: var(--text-dim);
  font-size: var(--fs-body);
}
.step .ic {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: var(--r-md);
  background: var(--gold-soft);
  color: var(--gold);
  margin-bottom: 18px;
}
.step .ic svg {
  width: 28px;
  height: 28px;
}

/* ============== Секция 3 — Игры ============== */
.games-wrap {
  width: 100%;
}
.game-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}
.game-grid .gc {
  grid-column: span 3;
}
/* 4+4+3: последний ряд из трёх карточек на всю ширину */
.game-grid .gc:nth-child(n + 9) {
  grid-column: span 4;
}
.gc {
  position: relative;
  padding: 24px;
  border-radius: var(--r-md);
  background: var(--glass);
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2),
    box-shadow var(--dur-2);
  cursor: pointer;
  text-align: left;
  color: inherit;
  width: 100%;
  font: inherit;
}
.gc .gc-more {
  margin-top: 12px;
  font-size: var(--fs-xs);
  font-family: var(--font-mono);
  letter-spacing: 0.06em;
  color: var(--gold);
  opacity: 0.75;
}
.gc::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    260px 180px at var(--mx, 50%) var(--my, 0%),
    rgba(232, 195, 106, 0.14),
    transparent 60%
  );
  opacity: 0;
  transition: opacity var(--dur-2) var(--ease);
}
.gc:hover {
  border-color: var(--stroke-strong);
  box-shadow: var(--sh-md);
}
.gc:hover::before {
  opacity: 1;
}
.gc .gc-num {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  color: var(--text-faint);
  letter-spacing: 0.2em;
}
.gc .gc-ic {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  color: var(--gold);
  background: var(--gold-soft);
  margin: 14px 0 16px;
}
.gc .gc-ic svg {
  width: 26px;
  height: 26px;
}
.gc h3 {
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: var(--fs-h3);
  margin-bottom: 6px;
}
.gc p {
  color: var(--text-dim);
  font-size: var(--fs-sm);
}

/* ============== Секция 4 — Направление ============== */
.dir {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: center;
  width: 100%;
}
.dir-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.stat {
  padding: 26px 24px;
  border-radius: var(--r-md);
  text-align: left;
}
.stat b {
  font-family: var(--font-display);
  font-size: clamp(30px, 3.4vw, 48px);
  display: block;
  line-height: 1;
  color: var(--gold);
}
.stat span {
  color: var(--text-dim);
  font-size: var(--fs-sm);
  margin-top: 8px;
  display: block;
}
.dir-list {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}
.dir-list li {
  list-style: none;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  color: var(--text-dim);
}
.dir-list .tick {
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ok-soft);
  color: var(--ok);
}
.dir-list .tick svg {
  width: 14px;
  height: 14px;
}

/* ============== Секция 5 — Финал / старт ============== */
.finale {
  width: 100%;
  display: grid;
  place-items: center;
  text-align: center;
}
.finale-card {
  max-width: 720px;
  padding: clamp(36px, 5vw, 64px);
  border-radius: var(--r-xl);
  position: relative;
  overflow: hidden;
}
.finale h2 {
  font-size: var(--fs-h1);
  margin: 18px 0 14px;
}
.finale p {
  color: var(--text-dim);
  font-size: var(--fs-lead);
  max-width: 46ch;
  margin: 0 auto;
}
.finale .hero-cta {
  justify-content: center;
}
.admissions {
  margin-top: 34px;
  padding-top: 26px;
  border-top: 1px solid var(--hairline);
  display: flex;
  gap: 30px;
  justify-content: center;
  flex-wrap: wrap;
}
.admissions a {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}
.admissions a:hover {
  color: var(--gold);
}
.admissions svg {
  width: 18px;
  height: 18px;
  color: var(--gold);
}

/* Действия в шапке лендинга (Пропустить + Начать) */
.l-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
#topStart {
  opacity: 0;
  transform: translateX(10px);
  pointer-events: none;
  transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease);
}
#topStart.in {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (max-width: 900px) {
  .hero,
  .dir {
    grid-template-columns: 1fr;
  }
  .hero-visual {
    order: -1;
    min-height: 320px;
  }
  .steps {
    grid-template-columns: 1fr 1fr;
  }
  .game-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .game-grid .gc,
  .game-grid .gc:nth-child(n + 9) {
    grid-column: auto;
  }
  .l-dots {
    display: none;
  }
}
@media (max-width: 560px) {
  .game-grid {
    grid-template-columns: 1fr;
  }
}
