/* Лендинг «Траектории». Источник истины — макеты docs/landing/html:
   desktop-1440.html (≥1024 px) и mobile-390.html (≤767 px). Между ними,
   768–1023 px, — промежуточная раскладка: сетки в две колонки, панели друг
   под другом. Токены бренда — tokens/tokens.css, здесь только оттенки из
   макета, которых там ещё нет. Тема одна, светлая: макет светлый целиком. */

:root {
  --color-step: #DCCFFF;             /* ступени на лиловом */
  --color-violet-400: #7D4DFF;       /* ступени на фиолетовом, середина медали */
  --color-violet-300: #8F63FF;
  --color-violet-200: #D6C8FF;
  --color-cyan-soft: #DDF7FB;        /* бирюзовая карточка цифр */
  --color-cyan-ink: #0B5F6B;
  --color-cyan-deco: #B8EEF5;
  --color-pink-deco: #FFC6DB;
  --color-pink-300: #FF8DBE;
  --color-yellow-deco: #FFE3A3;
  --color-yellow: #FFC94D;
  --color-on-brand-muted: #E8E0FF;   /* вторичный текст на фиолетовом */
  --color-on-night: #F1EEFA;         /* текст на тёмном */
  --color-on-night-muted: #CFC9E3;   /* вторичный текст на тёмном */
  --color-ink-on-lilac: #3A3450;     /* текст на лиловом */
  --color-night-floor: #2A2148;      /* тёмная панель помощника */
  --color-night-badge: #2A1F52;
  --color-night-accent: #A68BFF;
  --color-line-soft: #DCD8E8;        /* разделители на серой карточке */
  --color-brand-hover: #4F14D9;

  --shadow-float: 0 12px 32px -8px rgba(42, 26, 122, 0.25);
  --shadow-float-night: 0 12px 32px -8px rgba(0, 0, 0, 0.4);
  --shadow-phone: drop-shadow(0 20px 32px rgba(42, 26, 122, 0.25));
  --shadow-phone-lg: drop-shadow(0 24px 40px rgba(42, 26, 122, 0.28));
  --shadow-phone-night: drop-shadow(0 20px 32px rgba(0, 0, 0, 0.4));
  --shadow-deco: drop-shadow(0 16px 24px rgba(42, 26, 122, 0.22));

  --gutter: clamp(24px, 5.5556vw, 80px);
  --header-h: 88px;
  color-scheme: light;
}

@media (max-width: 767px) {
  :root { --gutter: 20px; --header-h: 68px; }
}

/* --- основа --- */

[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--color-surface);
  color: var(--color-ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; }
a { color: var(--color-brand); text-decoration: none; }
button { font-family: inherit; }
h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
a:focus-visible, button:focus-visible { outline: none; box-shadow: var(--focus-ring); }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

.wrap {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(1280px + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Что видно в какой раскладке. Тексты макетов для телефона и десктопа
   местами разные — обе версии лежат в разметке, видна одна. */
@media (max-width: 767px) { .d-only { display: none !important; } }
@media (min-width: 768px) { .m-only { display: none !important; } }
@media (max-width: 1023px) { .wide-only { display: none !important; } }
@media (min-width: 1024px) { .narrow-only { display: none !important; } }

.skip {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 20;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--color-surface-raised);
  color: var(--color-ink);
  font-weight: 600;
}
.skip:focus { top: 12px; }

/* Экраны в панелях «Трекер» и «Помощник» сменяют друг друга: класс alt на
   <body> ставит main.js каждые 3,5 с. */
.swap-a, .swap-b { transition: opacity .6s ease; }
.swap-b { opacity: 0; }
.alt .swap-a { opacity: 0; }
.alt .swap-b { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .swap-a, .swap-b { transition: none; }
}

/* --- кнопки и плашки --- */

.btn {
  box-sizing: border-box;
  height: 48px;
  padding: 0 20px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn--brand { background: var(--color-brand); color: var(--color-on-brand); }
.btn--brand:hover { background: var(--color-brand-hover); color: var(--color-on-brand); }
.btn--ghost { background: var(--color-surface-raised); border: 1px solid var(--color-line); color: var(--color-ink); }
.btn--ghost:hover { border-color: var(--color-brand-tint); color: var(--color-ink); }
.btn--white { background: var(--color-surface-raised); color: var(--color-ink); }
.btn--white:hover { background: var(--color-brand-soft); }
.btn--lg { height: 56px; padding: 0 28px; font-size: 16px; }

.pill {
  padding: 7px 14px;
  border-radius: var(--radius-full);
  background: var(--color-brand-soft);
  color: var(--color-brand);
  font-size: 14px;
  font-weight: 600;
}

.badge {
  position: relative;
  align-self: flex-start;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
}
.badge--white { background: var(--color-surface-raised); color: var(--color-brand); }
.badge--lilac { background: var(--color-brand-soft); color: var(--color-brand); }
.badge--night { background: var(--color-night-badge); color: var(--color-night-accent); }

.tag { padding: 3px 9px; border-radius: var(--radius-full); font-size: 12px; font-weight: 600; }
.tag--green { background: var(--color-green-soft); color: var(--color-green-ink); }
.tag--brand { background: var(--color-brand-soft); color: var(--color-brand); }
.tag--fact { border-radius: var(--radius-sm); background: var(--color-green-soft); color: var(--color-green-ink); }
.tag--nodata { border-radius: var(--radius-sm); background: var(--color-amber-soft); color: var(--color-amber-ink); }

.sq { width: 10px; height: 10px; flex-shrink: 0; margin-top: 7px; background: var(--color-brand); }

/* --- заголовки --- */

/* Крупные заголовки плавно растут от макета телефона (390) до десктопа (1440). */
.hero__title, .h2, .cta__title, .h3 { font-family: var(--font-display); font-weight: 600; }
.hero__title {
  font-size: clamp(32px, 20.1143px + 3.04762vw, 64px);
  line-height: clamp(37px, 25.4857px + 2.95238vw, 68px);
  letter-spacing: -0.025em;
}
.h2 {
  font-size: clamp(25px, 19.4286px + 1.42857vw, 40px);
  line-height: clamp(31px, 24.6857px + 1.61905vw, 48px);
  letter-spacing: -0.02em;
}
.lead { font-size: 19px; line-height: 30px; color: var(--color-ink-muted); }

/* --- шапка --- */

.top {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--color-surface);
  transition: box-shadow .2s ease;
}
.top[data-scrolled] { box-shadow: 0 1px 0 var(--color-line); }
.top__bar { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; }
.top__logo { display: flex; }
.top__logo img { height: 40px; width: auto; }
.top__nav { display: flex; gap: 36px; align-items: center; }
.top__nav a { color: var(--color-ink); font-size: 15px; font-weight: 600; }
.top__nav a:hover { color: var(--color-brand); }
.top__actions { display: flex; gap: 10px; align-items: center; }
.top__cta { padding: 0 22px; }

.burger {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-line);
  background: var(--color-surface-raised);
  color: var(--color-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.burger[aria-expanded="true"] { border-color: var(--color-brand); color: var(--color-brand); }

.menu {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  top: calc(var(--header-h) - 4px);
  padding: 8px;
  border-radius: var(--radius-lg);
  background: var(--color-surface-raised);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
}
.menu a {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  color: var(--color-ink);
  font-size: 16px;
  font-weight: 600;
}
.menu a:hover { background: var(--color-brand-soft); }

/* Шапка сжимается раньше, чем ломается: вторичная кнопка уходит первой. */
@media (min-width: 1024px) and (max-width: 1199px) {
  .top__how { display: none; }
}

/* --- разделы --- */

.sec { display: flex; flex-direction: column; scroll-margin-top: calc(var(--header-h) - 48px); }
.sec__head { display: flex; flex-direction: column; gap: 14px; max-width: 900px; }

/* --- первый экран --- */

.hero { padding-top: 40px; display: flex; flex-direction: column; align-items: center; gap: 48px; scroll-margin-top: var(--header-h); }
.hero__text { width: 100%; max-width: 1000px; display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.hero__lead { max-width: 720px; font-size: 19px; line-height: 30px; color: var(--color-ink-muted); }
.hero__cta { display: flex; gap: 12px; padding-top: 6px; }

.stage { position: relative; overflow: hidden; width: 100%; background: var(--color-brand-soft); }
.stage > * { position: absolute; }

/* Десктопная сцена нарисована на 1280×560 и целиком масштабируется с шириной:
   --u — один пиксель макета. На 1440 и шире --u = 1px. */
.stage--wide {
  container-type: inline-size;
  aspect-ratio: 1280 / 560;
  border-radius: 40px;
  --u: calc(100cqw / 1280);
}
.stage__deco { left: 0; top: 0; width: 100%; height: 100%; }
.w-chat, .w-home { width: calc(250 * var(--u)); height: auto; filter: var(--shadow-phone-lg); }
.w-chat { left: calc(378 * var(--u)); top: calc(64 * var(--u)); }
.w-home { left: calc(652 * var(--u)); top: calc(104 * var(--u)); }
.w-medal {
  left: calc(150 * var(--u));
  top: calc(58 * var(--u));
  width: calc(120 * var(--u));
  height: calc(150 * var(--u));
  transform: rotate(-10deg);
  filter: var(--shadow-deco);
}
.w-cap {
  left: calc(180 * var(--u));
  top: calc(396 * var(--u));
  width: calc(150 * var(--u));
  height: calc(110 * var(--u));
  transform: rotate(8deg);
  filter: var(--shadow-deco);
}
.w-cal {
  left: calc(1010 * var(--u));
  top: calc(52 * var(--u));
  width: calc(120 * var(--u));
  height: calc(124 * var(--u));
  transform: rotate(9deg);
  filter: var(--shadow-deco);
}

.plate { box-sizing: border-box; background: var(--color-surface-raised); display: flex; text-align: left; }
.plate__ico { flex-shrink: 0; background: var(--color-pink-soft); color: var(--color-pink-ink); display: flex; align-items: center; justify-content: center; }
.plate__txt { display: flex; flex-direction: column; }
.plate__txt > span { color: var(--color-ink-muted); }
.plate--perk { flex-direction: column; }
.plate__cap { font-weight: 600; color: var(--color-ink-muted); }
.plate__row { display: flex; justify-content: space-between; align-items: center; font-weight: 600; }

.w-soon {
  left: calc(100 * var(--u));
  top: calc(268 * var(--u));
  width: calc(236 * var(--u));
  padding: calc(14 * var(--u)) calc(16 * var(--u));
  border-radius: calc(18 * var(--u));
  box-shadow: 0 calc(12 * var(--u)) calc(32 * var(--u)) calc(-8 * var(--u)) rgba(42, 26, 122, 0.25);
  gap: calc(12 * var(--u));
  align-items: center;
  transform: rotate(-3deg);
}
.w-soon .plate__ico { width: calc(40 * var(--u)); height: calc(40 * var(--u)); border-radius: calc(12 * var(--u)); }
.w-soon .plate__ico svg { width: calc(20 * var(--u)); height: calc(20 * var(--u)); }
.w-soon .plate__txt { gap: calc(2 * var(--u)); }
.w-soon b { font-size: calc(14 * var(--u)); line-height: calc(18 * var(--u)); }
.w-soon .plate__txt > span { font-size: calc(13 * var(--u)); line-height: calc(17 * var(--u)); }

.w-perk {
  left: calc(944 * var(--u));
  top: calc(236 * var(--u));
  width: calc(250 * var(--u));
  padding: calc(14 * var(--u)) calc(16 * var(--u));
  border-radius: calc(18 * var(--u));
  box-shadow: 0 calc(12 * var(--u)) calc(32 * var(--u)) calc(-8 * var(--u)) rgba(42, 26, 122, 0.25);
  gap: calc(10 * var(--u));
  transform: rotate(3deg);
}
.w-perk .plate__cap { font-size: calc(12 * var(--u)); line-height: calc(16 * var(--u)); }
.w-perk .plate__row { font-size: calc(14 * var(--u)); }
.w-perk .tag { padding: calc(3 * var(--u)) calc(9 * var(--u)); font-size: calc(12 * var(--u)); }

/* Сцена телефона нарисована на 350×440; на планшете та же композиция
   держится центра, ступени — углов. */
.stage--narrow { height: 440px; border-radius: 32px; margin-top: 8px; }
.n-steps-l { left: 0; bottom: 0; width: 120px; height: 100px; }
.n-steps-r { right: 0; bottom: 0; width: 100px; height: 100px; }
.n-dot { width: 10px; height: 10px; }
.n-dot--cyan { left: calc(50% - 139px); top: 48px; background: var(--color-cyan); }
.n-dot--brand { left: calc(50% + 129px); top: 60px; background: var(--color-brand); }
.n-medal {
  left: calc(50% - 175px);
  top: 0;
  width: 72px;
  height: 90px;
  transform-origin: 0 0;
  transform: rotate(-10deg);
  filter: drop-shadow(0 12px 18px rgba(42, 26, 122, 0.22));
}
.n-chat { left: calc(50% - 105px); top: 40px; width: 210px; height: auto; filter: drop-shadow(0 20px 32px rgba(42, 26, 122, 0.28)); }
.n-perk, .n-soon { border-radius: 14px; box-shadow: 0 12px 28px -8px rgba(42, 26, 122, 0.28); }
.n-perk { left: min(calc(50% + 19px), calc(100% - 156px)); top: 104px; width: 152px; padding: 10px 12px; gap: 7px; transform: rotate(3deg); }
.n-perk .plate__cap { font-size: 10px; line-height: 13px; }
.n-perk .plate__row { font-size: 12px; }
.n-perk .tag { padding: 2px 7px; font-size: 10px; }
.n-soon { left: max(-6px, calc(50% - 181px)); top: 94px; width: 166px; padding: 9px 10px; gap: 8px; align-items: center; transform: rotate(-3deg); }
.n-soon .plate__ico { width: 30px; height: 30px; border-radius: 10px; }
.n-soon .plate__ico svg { width: 16px; height: 16px; }
.n-soon .plate__txt { gap: 1px; }
.n-soon b { font-size: 12px; line-height: 15px; }
.n-soon .plate__txt > span { font-size: 11px; line-height: 14px; }

/* --- проблема --- */

.sec--problem { padding-top: 112px; gap: 36px; }
.problem__title { max-width: 1040px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.stat {
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  min-height: 250px;
  padding: 28px;
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  gap: 10px;
  container-type: inline-size;
}
.stat--violet { background: var(--color-brand-soft); --label: var(--color-brand); }
.stat--cyan { background: var(--color-cyan-soft); --label: var(--color-cyan-ink); }
.stat--pink { background: var(--color-pink-soft); --label: var(--color-pink-ink); }
.stat--amber { background: var(--color-amber-soft); --label: var(--color-amber-ink); }
.stat__label { font-size: 14px; font-weight: 600; color: var(--label); }
/* «50→35» — самое длинное число: на узких десктопах кегль уменьшается,
   чтобы число не обрезалось краем карточки. */
.stat__num {
  font-family: var(--font-display);
  font-size: min(64px, calc(24.5cqw + 4.9px));
  line-height: 64px;
  font-weight: 700;
  letter-spacing: -0.03em;
  white-space: nowrap;
}
.stat__text { font-size: 16px; line-height: 24px; }
.stat__deco { position: absolute; right: 0; top: 0; width: 48px; height: 48px; }

.verdict {
  border-radius: var(--radius-xl);
  padding: 32px 40px;
  background: var(--color-ink);
  color: var(--color-on-night);
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
}
.verdict__text { max-width: 860px; font-size: 21px; line-height: 32px; }
.verdict__btn { height: 52px; padding: 0 24px; gap: 8px; flex-shrink: 0; }
.sources { font-size: 13px; line-height: 18px; color: var(--color-ink-muted); }

/* --- ролик ---
   Раздела нет в макете. Сцена — как у первого экрана: лиловая панель,
   ступени по краям, квадраты-конфетти; видео в скруглённой рамке. Без
   скрипта у видео контролы браузера, со скриптом поверх постера плашка
   «Смотреть ролик», её показывает main.js. */

.sec--film { padding-top: 112px; gap: 36px; }
.film {
  position: relative;
  overflow: hidden;
  border-radius: 40px;
  padding: clamp(40px, 3.8889vw, 56px) clamp(64px, 8.3333vw, 120px);
  background: var(--color-brand-soft);
}
.film__steps { position: absolute; bottom: 0; width: clamp(180px, 22.2222vw, 320px); height: auto; }
.film__steps--l { left: 0; }
.film__steps--r { right: 0; }
.film__dot { position: absolute; width: 14px; height: 14px; }
.film__dot--cyan { left: 3.2%; top: 12%; background: var(--color-cyan); }
.film__dot--pink { right: 3.4%; top: 22%; width: 10px; height: 10px; background: var(--color-pink); }
.film__dot--brand { right: 5.2%; top: 44%; width: 12px; height: 12px; background: var(--color-brand); }
.film__screen { position: relative; border-radius: 24px; box-shadow: var(--shadow-float); }
.film__video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: var(--color-ink);
  object-fit: cover;
}
.film__play {
  position: absolute;
  inset: 0;
  padding: 0;
  border: 0;
  border-radius: 24px;
  background: transparent;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background-color .2s ease;
}
.film__pill {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  height: 72px;
  padding: 0 28px 0 12px;
  border-radius: var(--radius-full);
  background: var(--color-surface-raised);
  color: var(--color-ink);
  font-size: 17px;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  transition: transform .25s cubic-bezier(.2, .7, .2, 1);
}
.film__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--color-brand);
  color: var(--color-on-brand);
  transition: transform .25s cubic-bezier(.2, .7, .2, 1);
}
.film__icon svg { margin-left: 2px; } /* треугольник визуально по центру круга */
.film__time { color: var(--color-ink-muted); font-variant-numeric: tabular-nums; }
.film__play:active .film__pill { transform: scale(.97); }
@media (hover: hover) {
  .film__play:hover { background: rgba(23, 20, 42, .06); }
  .film__play:hover .film__pill { transform: translateY(-2px); }
  .film__play:hover .film__icon { transform: scale(1.06); }
}
/* Пересказ ролика — только для скринридера (aria-describedby у видео), на экране его нет */
.film__about {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  .film__play, .film__pill, .film__icon { transition: none; }
}

/* --- шаги --- */

.sec--start { padding-top: 112px; gap: 36px; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.step {
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  height: 640px;
  padding: 32px;
  border-radius: var(--radius-xl);
  background: var(--color-surface-raised);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.step__num { align-self: flex-start; padding: 5px 12px; border-radius: var(--radius-full); font-size: 13px; font-weight: 600; }
.step__num--1 { background: var(--color-brand); color: var(--color-on-brand); }
.step__num--2 { background: var(--color-cyan); color: var(--color-ink); }
.step__num--3 { background: var(--color-pink); color: var(--color-on-brand); }
.step__title { font-size: 22px; line-height: 28px; font-weight: 700; }
.step__text { font-size: 16px; line-height: 24px; color: var(--color-ink-muted); }
.step__btn { align-self: flex-start; height: 44px; padding: 0 18px; margin-top: 4px; }
.step__floor { position: absolute; left: 0; right: 0; bottom: 0; height: 330px; }
.step__shot { position: absolute; left: calc(50% - 123.667px); top: 286px; width: 240px; height: auto; filter: var(--shadow-phone); }

.floor--violet { background: var(--color-brand-soft); }
.floor--cyan { background: var(--color-cyan-soft); }
.floor--pink { background: var(--color-pink-soft); }
.floor--night { background: var(--color-night-floor); }

/* --- возможности --- */

.sec--features { padding-top: 96px; gap: 28px; }

.perk {
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  min-height: 440px;
  padding: 48px;
  border-radius: 32px;
  background: var(--color-brand-soft);
}
.perk__steps { position: absolute; right: 0; bottom: 0; width: 400px; height: 240px; }
/* Колонка текста сужается раньше, чем наедет на телефон (левый край — 60,156 %). */
.perk__text { position: relative; width: min(560px, calc(60.156% - 30.25px)); display: flex; flex-direction: column; gap: 14px; }
.perk__title { font-size: 26px; line-height: 32px; }
.perk__lead { font-size: 18px; line-height: 28px; color: var(--color-ink-on-lilac); }
.perk__list { display: flex; flex-direction: column; gap: 12px; padding-top: 4px; }
.perk__list li { display: flex; gap: 12px; align-items: flex-start; font-size: 17px; line-height: 25px; }
.perk__shot { position: absolute; left: 60.156%; top: 40px; width: 240px; height: auto; filter: var(--shadow-phone-lg); }

.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.panel {
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  height: 520px;
  padding: 40px;
  border-radius: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.panel--light { background: var(--color-surface-raised); }
.panel--night { background: var(--color-ink); color: var(--color-on-night); }
.panel__title { font-size: 24px; line-height: 30px; }
.panel__text { font-size: 17px; line-height: 26px; color: var(--color-ink-muted); }
.panel--night .panel__text { color: var(--color-on-night-muted); }
/* Сцена с телефоном и цветной подложкой идёт сразу под текстом: если текст
   на узкой панели переносится на лишнюю строку, сцена уезжает ниже, а не
   наезжает на него. Сцена во всю ширину панели, телефон и плашки держатся
   её центра — на 630 px ровно как в макете. */
.panel__stage { position: relative; flex: none; height: 0; margin: 11px -40px 0; }
.panel__floor { position: absolute; left: 0; right: 0; top: 22px; height: 600px; }
.panel__shot { position: absolute; left: calc(50% - 111px); top: 0; width: 250px; height: auto; filter: var(--shadow-phone); }
.panel--night .panel__shot { filter: var(--shadow-phone-night); }

.float {
  position: absolute;
  box-sizing: border-box;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: var(--color-surface-raised);
  color: var(--color-ink);
  box-shadow: var(--shadow-float);
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
}
.float--deadline { left: max(16px, calc(50% - 255px)); top: 52px; transform: rotate(-5deg); }
.float--calendar { left: max(16px, calc(50% - 275px)); top: 52px; transform: rotate(-5deg); }
.float__dot { width: 10px; height: 10px; border-radius: var(--radius-full); background: var(--color-pink); }
.float--answer { left: min(calc(50% + 105px), calc(100% - 210px)); top: 22px; transform: rotate(5deg); box-shadow: var(--shadow-float-night); }

/* --- для кого --- */

.sec--roles { padding-top: 112px; gap: 36px; }
.roles__title { max-width: 1000px; }
.roles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.role {
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  min-height: 400px;
  padding: 32px;
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.role--student { background: var(--color-brand); color: var(--color-on-brand); }
.role--parent { background: var(--color-surface-raised); }
.role--teacher { background: var(--color-surface-tint); }
.role__icon { position: absolute; right: 28px; top: 28px; width: 96px; height: 96px; }
.role__title { font-size: 28px; line-height: 34px; }
.role__lead { width: 220px; font-size: 16px; line-height: 24px; color: var(--color-ink-muted); }
.role--student .role__lead { color: var(--color-on-brand-muted); }
.role__list { margin-top: 12px; display: flex; flex-direction: column; gap: 12px; font-size: 16px; line-height: 24px; }
.role__list li { display: flex; gap: 12px; align-items: flex-start; }
.role--student .sq { background: var(--color-cyan); }
.role--teacher .sq { background: var(--color-ink-muted); }
.role__btn { margin-top: auto; align-self: flex-start; background: var(--color-surface-raised); color: var(--color-brand); }
.role__btn:hover { background: var(--color-brand-soft); color: var(--color-brand); }
.role--parent .role__btn { background: var(--color-brand-soft); }
.role--parent .role__btn:hover { background: var(--color-brand-tint); }
.soon {
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  color: var(--color-ink-muted);
  font-size: 12px;
  font-weight: 600;
}

/* Узкие карточки (планшет и десктоп до 1280): иконка меньше и не заходит
   на текст. Через медиа, а не container query: внутри контейнера Chrome
   при загрузке проигрывает переход фона кнопки. */
@media (min-width: 768px) and (max-width: 1279px) {
  .role__icon { right: 20px; top: 20px; width: 64px; height: 64px; }
  .role__lead { width: auto; max-width: calc(100% - 64px); }
}

/* --- сравнение --- */

.sec--compare { padding-top: 96px; gap: 28px; }
.sec--compare .sec__head { gap: 16px; }
.versus { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.vs { position: relative; overflow: hidden; padding: 32px 40px; border-radius: 32px; display: flex; flex-direction: column; }
.vs--catalog { background: var(--color-surface-tint); --mark-bg: var(--color-surface-raised); --mark-ink: var(--color-ink-muted); --row-line: var(--color-line-soft); }
.vs--ours { background: var(--color-brand); color: var(--color-on-brand); --mark-bg: var(--color-cyan); --mark-ink: var(--color-ink); --row-line: rgba(255, 255, 255, 0.2); }
.vs__deco { position: absolute; right: 0; top: 0; width: 90px; height: 90px; }
.vs__title { position: relative; margin-bottom: 6px; font-size: 20px; line-height: 26px; }
.vs--catalog .vs__title { color: var(--color-ink-muted); }
.vs__list li { display: flex; gap: 16px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--row-line); font-size: 17px; line-height: 1.35; }
.vs__list li:last-child { border-bottom: 0; }
.vs--catalog li { color: var(--color-ink-muted); }
.vs--ours li { font-weight: 500; }
.vs__mark {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: var(--radius-full);
  background: var(--mark-bg);
  color: var(--mark-ink);
  display: flex;
  align-items: center;
  justify-content: center;
}
.vs__mark svg { width: 14px; height: 14px; }

/* --- вузы --- */

.sec--trust { padding-top: 112px; gap: 36px; }
.unis { display: flex; flex-wrap: wrap; gap: 12px; }
.uni { padding: 14px 20px; border-radius: 16px; background: var(--color-surface-raised); display: flex; flex-direction: column; gap: 2px; }
.uni b { font-size: 17px; }
.uni span { font-size: 13px; color: var(--color-ink-muted); }

/* --- вопросы --- */

.sec--faq { padding-top: 112px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px; }
.faq__head { display: flex; flex-direction: column; gap: 16px; }
.faq__hint { font-size: 16px; line-height: 24px; color: var(--color-ink-muted); }
.faq { grid-column: span 2; padding: 8px 32px; border-radius: var(--radius-xl); background: var(--color-surface-raised); }
.faq__item { border-bottom: 1px solid var(--color-line); }
.faq__q {
  width: 100%;
  min-height: 72px;
  padding: 20px 0;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  text-align: left;
  cursor: pointer;
  color: var(--color-ink);
  font-size: 18px;
  line-height: 26px;
  font-weight: 600;
}
.faq__sign {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: var(--radius-full);
  background: var(--color-brand-soft);
  color: var(--color-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  line-height: 20px;
  font-weight: 600;
}
.faq__q:hover .faq__sign { background: var(--color-brand-tint); }
.faq__a { padding: 0 56px 24px 0; font-size: 16px; line-height: 25px; color: var(--color-ink-muted); }

/* --- призыв --- */

.sec--cta { padding-top: 112px; padding-bottom: 96px; }
.cta {
  position: relative;
  overflow: hidden;
  padding: 64px;
  border-radius: 40px;
  background: var(--color-brand);
  color: var(--color-on-brand);
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.cta__steps { position: absolute; right: 0; bottom: 0; width: 420px; height: 280px; }
.cta__medal {
  position: absolute;
  left: 64.0625%;
  top: 40px;
  width: 120px;
  height: 150px;
  transform: rotate(12deg);
  filter: drop-shadow(0 16px 24px rgba(0, 0, 0, 0.25));
}
.cta__title {
  position: relative;
  max-width: min(680px, 60%);
  font-size: clamp(26px, 19.3143px + 1.71429vw, 44px);
  line-height: clamp(31px, 23.9429px + 1.80952vw, 50px);
  letter-spacing: -0.02em;
}
.cta__text { position: relative; max-width: min(620px, 54%); font-size: 19px; line-height: 30px; color: var(--color-on-brand-muted); }
.cta__btn { position: relative; align-self: flex-start; margin-top: 8px; color: var(--color-brand); }
.cta__btn:hover { color: var(--color-brand); }

/* --- подвал --- */

.foot { background: var(--color-surface-raised); color: var(--color-ink); border-top: 1px solid var(--color-line); }
.foot__in { padding-top: 64px; padding-bottom: 48px; display: flex; flex-direction: column; gap: 40px; }
.foot__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; }
.foot__about { width: 420px; display: flex; flex-direction: column; gap: 16px; }
.foot__logo { height: 40px; width: auto; align-self: flex-start; }
.foot__about p { font-size: 15px; line-height: 22px; color: var(--color-ink-muted); }
.foot__cols { display: flex; gap: 80px; }
.foot__col { display: flex; flex-direction: column; gap: 12px; }
.foot__cap { font-size: 13px; font-weight: 600; color: var(--color-ink-muted); }
.foot__col a { color: var(--color-ink); font-size: 15px; }
.foot__col a:hover { color: var(--color-brand); }
.foot__note { padding-top: 24px; border-top: 1px solid var(--color-line); font-size: 13px; line-height: 20px; color: var(--color-ink-muted); }

/* ================= 768–1023: планшет ================= */

@media (min-width: 768px) and (max-width: 1023px) {
  .hero { gap: 40px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps, .roles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step:last-child:nth-child(odd), .role:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .role:last-child:nth-child(odd) { min-height: 0; }
  .duo { grid-template-columns: minmax(0, 1fr); }
  .sec--faq { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .faq { grid-column: auto; }
  .foot__top { flex-wrap: wrap; }
  .film { border-radius: 32px; }
}

/* ================= ≤767: телефон ================= */

@media (max-width: 767px) {
  .top__logo img { height: 32px; }
  .top__actions { gap: 8px; }
  .top__cta { height: 44px; padding: 0 16px; font-size: 14px; }

  .hero { padding-top: 20px; gap: 16px; }
  .hero__text { gap: 16px; }
  .pill { padding: 6px 12px; font-size: 13px; }
  .hero__lead { font-size: 16px; line-height: 25px; }
  .hero__cta { width: 100%; flex-direction: column; gap: 10px; padding-top: 4px; }
  .hero__cta .btn { justify-content: center; }

  .lead { font-size: 15px; line-height: 23px; }
  .sec__head .lead { margin-bottom: 4px; }

  .sec--problem { padding-top: 64px; gap: 18px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stat { min-height: 0; padding: 18px; border-radius: 22px; gap: 6px; container-type: normal; }
  .stat__label { font-size: 12px; }
  .stat__num { font-size: 40px; line-height: 44px; letter-spacing: normal; }
  .stat__num--long { font-size: 30px; }
  .stat__text { font-size: 14px; line-height: 20px; }
  .verdict { padding: 22px; border-radius: 22px; flex-direction: column; align-items: stretch; gap: 14px; }
  .verdict__text { font-size: 17px; line-height: 26px; }
  .sources { font-size: 12px; line-height: 17px; }

  .sec--film { padding-top: 64px; gap: 14px; }
  .film { padding: 10px; border-radius: 24px; }
  .film__steps, .film__dot { display: none; }
  .film__screen, .film__video, .film__play { border-radius: 16px; }
  .film__pill { height: 56px; gap: 10px; padding: 0 20px 0 8px; font-size: 15px; }
  .film__icon { width: 40px; height: 40px; }
  .film__icon svg { width: 18px; height: 18px; }

  .sec--start { padding-top: 64px; gap: 14px; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .step { height: 440px; padding: 24px; border-radius: 24px; gap: 10px; }
  .step__num { font-size: 12px; }
  .step__title { font-size: 20px; line-height: 26px; }
  .step__text { font-size: 15px; line-height: 22px; }
  .step__floor { height: 250px; }
  .step__shot { left: calc(50% - 100px); top: 186px; width: 200px; filter: drop-shadow(0 16px 28px rgba(42, 26, 122, 0.25)); }

  .sec--features { padding-top: 48px; gap: 14px; scroll-margin-top: 36px; }
  .perk { height: 640px; min-height: 0; padding: 24px; border-radius: 28px; }
  .perk__text { width: auto; gap: 10px; }
  .badge { font-size: 12px; }
  .perk__title, .panel__title { font-size: 21px; line-height: 27px; }
  .perk__lead { font-size: 15px; line-height: 22px; }
  .perk__shot { left: calc(50% - 100px); top: 244px; width: 200px; filter: drop-shadow(0 16px 28px rgba(42, 26, 122, 0.25)); }
  .duo { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .panel { height: 600px; padding: 24px; border-radius: 28px; gap: 10px; }
  .panel__text { font-size: 15px; line-height: 22px; }
  .panel__floor { top: auto; bottom: 0; height: 330px; }
  .panel__stage { position: static; margin: 0; }
  .panel__shot { left: calc(50% - 100px); top: 224px; width: 200px; filter: drop-shadow(0 16px 28px rgba(42, 26, 122, 0.25)); }
  .panel--night .panel__shot { filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.4)); }

  .sec--roles { padding-top: 64px; gap: 14px; }
  .roles__title { margin-bottom: 4px; }
  .roles { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .role { min-height: 0; padding: 24px; border-radius: 24px; gap: 12px; }
  .role--teacher { gap: 10px; }
  .role__icon { right: 18px; top: 18px; width: 60px; height: 60px; }
  .role__title { font-size: 23px; line-height: 28px; }
  .role__lead { font-size: 15px; line-height: 22px; }
  .role__lead--wide { width: auto; }
  .role__list { margin-top: 0; gap: 8px; font-size: 15px; line-height: 22px; }
  .role__list li { gap: 10px; }
  .role__list .sq { width: 9px; height: 9px; margin-top: 6px; }

  .sec--compare { padding-top: 48px; padding-bottom: 48px; gap: 14px; }
  .sec--compare .sec__head { gap: 14px; }
  .versus { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .vs { padding: 24px; border-radius: 28px; }
  .vs__deco { width: 72px; height: 72px; }
  .vs__title { font-size: 19px; line-height: 25px; }
  .vs__list li { padding: 14px 0; font-size: 16px; }
  .vs__mark { width: 32px; height: 32px; }
  .vs__mark svg { width: 18px; height: 18px; }

  .sec--trust { padding-top: 48px; gap: 14px; }
  .sec--trust .h2 { margin-bottom: 4px; }
  .unis { gap: 8px; }
  .uni { padding: 10px 14px; border-radius: 14px; }
  .uni b { font-size: 15px; font-weight: 700; }

  .sec--faq { padding-top: 64px; grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .faq { grid-column: auto; padding: 4px 20px; border-radius: 24px; }
  .faq__q { min-height: 60px; padding: 14px 0; gap: 14px; font-size: 16px; line-height: 22px; }
  .faq__sign { width: 30px; height: 30px; font-size: 18px; line-height: 18px; }
  .faq__a { padding: 0 6px 16px 0; font-size: 15px; line-height: 22px; }

  .sec--cta { padding-top: 64px; padding-bottom: 56px; }
  .cta { padding: 26px 24px 120px; border-radius: 28px; gap: 12px; }
  .cta__steps { width: 240px; height: 96px; }
  .cta__title, .cta__text { max-width: none; }
  .cta__text { font-size: 15px; line-height: 23px; }
  .cta__btn { align-self: stretch; height: 52px; margin-top: 6px; justify-content: center; }

  .foot__in { padding-top: 44px; padding-bottom: 36px; gap: 28px; }
  .foot__top { flex-direction: column; gap: 28px; }
  .foot__about { width: auto; gap: 12px; }
  .foot__logo { height: 32px; }
  .foot__about p { font-size: 14px; line-height: 21px; }
  .foot__cols { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
  .foot__col { gap: 10px; }
  .foot__note { padding-top: 18px; font-size: 12px; line-height: 18px; }
}

/* Самые узкие телефоны: шапка не упирается в край. */
@media (max-width: 374px) {
  .top__bar { gap: 8px; }
  .top__logo img { height: 28px; }
  .top__cta { padding: 0 12px; }
}
