/* UONO — ai.uono.ru landing preview. Visual system follows live uono.ru; see DESIGN-REFERENCE.md */

@font-face { font-family: "Loos Wide"; src: url("assets/LoosWide-Bold.woff") format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Geist"; src: url("assets/Geist-Regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Geist"; src: url("assets/Geist-Medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Geist"; src: url("assets/Geist-SemiBold.woff") format("woff"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Geist"; src: url("assets/Geist-Bold.woff") format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("assets/JetBrainsMono-Bold.woff") format("woff"); font-weight: 700; font-display: swap; }

:root {
  --ink: #002200;
  --ink-soft: #2E4A2E;
  --ink-muted: #4A6450;
  --mint: #3CE4AD;
  --mint-footer: #6FE1CF;
  --blue: #3794FE;          /* decorative lines, underlines */
  --blue-text: #1F6FD6;     /* text and filled badges with white text (≥4.5:1) */
  --green-text: #0B7A57;    /* darker brand #12A77A for text contrast */
  --violet-text: #6A4BE8;
  --cyan: #E3FBFF;
  --cyan-soft: #F1FCFF;
  --line: #E3EFF3;
  --error: #B42318;

  --display: "Loos Wide", "Golos Text", "Geist", system-ui, sans-serif;
  --sans: "Geist", "Golos Text", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --gutter: clamp(24px, 5.14vw, 74px);   /* 74px at 1440 → 1292px content */
  --section: clamp(60px, 8.33vw, 120px);
  --header-h: 80px;
  --radius: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 400 17px/1.5 var(--sans);
  color: var(--ink);
  background: #fff;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, h4, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }
section[id] { scroll-margin-top: calc(var(--header-h) + 8px); }

:focus-visible { outline: 3px solid var(--blue-text); outline-offset: 3px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  padding: 12px 16px; background: var(--ink); color: #fff; border-radius: 4px;
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Type ---------- */
.h1 { font: 700 clamp(44px, 8vw, 116px)/0.98 var(--display); overflow-wrap: break-word; }
.h2 { font: 700 clamp(34px, 5.25vw, 76px)/1 var(--display); overflow-wrap: break-word; }
.h3 { font: 700 20px/1.25 var(--sans); }
.lead { font-size: 20px; line-height: 1.45; }
.pending { color: var(--ink-muted); font-style: italic; }

/* Filled label plate (live: blue tags "ЗРЕНИЕ", white "7-9 ЛЕТ") */
.badge {
  display: inline-block; padding: 8px 12px; border-radius: 2px;
  background: var(--blue-text); color: #fff;
  font: 700 14px/1.2 var(--mono); letter-spacing: 0.02em; text-transform: uppercase;
}
.badge--mint { background: var(--mint); color: var(--ink); }
.badge--accent { background: var(--accent); }
.num {
  display: inline-block; padding: 6px 10px; border-radius: 2px;
  background: var(--blue-text); color: #fff;
  font: 700 16px/1 var(--mono);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 60px; padding: 0 32px;
  background: var(--mint); color: var(--ink);
  border: 0; border-radius: 4px; cursor: pointer;
  font: 700 clamp(17px, 1.55vw, 22px)/1.1 var(--mono); letter-spacing: 0.02em; text-transform: uppercase;
  text-decoration: none; text-align: center;
  transition: background-color .15s ease, color .15s ease;
}
/* Live hover: brand blue #3794FE + white. White on #3794FE is 3.2:1, so it is used only while the
   label is large text (bold ≥ 18.66px); smaller labels hover to #1F6FD6 (5.1:1). */
.btn:hover { background: var(--blue-text); color: #fff; }
@media (min-width: 1204px) { .btn:hover { background: var(--blue); } }          /* .btn label ≥ 18.66px */
@media (min-width: 830px) { .btn--lg:hover { background: var(--blue); } }       /* .btn--lg label ≥ 18.66px */
.btn--sm:hover { background: var(--blue-text); }
.btn--lg { min-height: 72px; padding: 0 24px; font-size: clamp(18px, 2.25vw, 32px); }
.btn--sm { min-height: 44px; padding: 0 18px; font-size: 15px; }
.btn--full { width: 100%; }

/* ---------- Header ---------- */
.header { position: sticky; top: 0; z-index: 50; background: #fff; }
.header__inner { display: flex; align-items: center; gap: 16px; min-height: var(--header-h); }
.header__logo { display: inline-flex; align-items: center; min-height: 44px; }
.header__logo img { width: 128px; }
.preview-tag {
  margin-right: auto; padding: 4px 8px; border-radius: 2px;
  background: #FFF1C2; font: 700 11px/1.3 var(--mono); letter-spacing: 0.04em; text-transform: uppercase;
}
.nav { display: flex; align-items: center; gap: 20px; }
.nav__list { display: flex; gap: 4px; }
.nav__list a, .nav__phone {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px;
  font-weight: 500; font-size: 16px; text-decoration: none;
  text-underline-offset: 6px; text-decoration-thickness: 2px;
}
.nav__list a:hover, .nav__phone:hover { color: var(--blue-text); text-decoration: underline; }
.nav__phone { font-weight: 600; white-space: nowrap; }
.burger { display: none; }

/* ---------- Hero ---------- */
.hero { padding: 16px 0 var(--section); }
/* Stepped "Union" backdrop (live Union3.svg): tall right tab + full-width lower band, both #E3FBFF. */
.hero__stage {
  position: relative; isolation: isolate;
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); grid-template-rows: auto 1fr;
}
.hero__stage::before, .hero__stage::after {
  content: ""; z-index: -1; background: var(--cyan); border-radius: var(--radius);
}
.hero__stage::before { grid-column: 2; grid-row: 1 / 3; }
.hero__stage::after { grid-column: 1 / 3; grid-row: 2; }
.hero__title { grid-column: 1; grid-row: 1; padding: 8px 24px 36px 0; }
/* Offer fills the band row (so the notch sits on the band's top edge) and pins its text to the bottom */
.hero__offer {
  position: relative; grid-column: 1; grid-row: 2;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-end;
  padding: 40px 32px 48px 48px;
}
/* Rounded inner notch where the band meets the tab (Union3.svg r=10 → 16px here) */
.hero__offer::before {
  content: ""; position: absolute; right: 0; top: -16px; width: 16px; height: 16px;
  background: radial-gradient(circle at 0 0, transparent 15.5px, var(--cyan) 16px);
}
.nowrap { white-space: nowrap; }
.hero__lead { margin-top: 20px; max-width: 560px; font-size: clamp(17px, 1.5vw, 22px); line-height: 1.35; }
/* Art column is in normal flow: it contributes its own height, so nothing depends on text row heights. */
.hero__art {
  grid-column: 2; grid-row: 1 / 3; position: relative;
  display: flex; align-items: flex-end; justify-content: center;
  padding: 120px 8px 24px;   /* top space = logo (28 + 110) minus the frame's own transparent top */
}
.hero__logo { position: absolute; top: 28px; right: 28px; z-index: 1; width: clamp(64px, 7.6vw, 110px); }
/* Frame = painted box of pixel-hero.png (620×570) incl. its soft halo: x 40–600, y 15–475 → 560×460.
   Egg top ≈ y 78, platform x ≈ 80–556, lower glow ends ≈ y 445, so the frame only trims empty margins.
   The img is scaled/offset against the FRAME width only — independent of text row heights. */
.hero__figure { width: 100%; max-width: 640px; aspect-ratio: 560 / 460; overflow: hidden; }
.hero__pixel {
  width: 110.714%;            /* 620 / 560 */
  max-width: none;
  margin: -2.679% 0 0 -7.143%; /* 15 / 560 top, 40 / 560 left (% margins resolve against width) */
}
.hero__actions {
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: 16px 28px; align-items: center;
  margin-top: 16px;
}
.hero__meta { font: 700 14px/1.3 var(--mono); text-transform: uppercase; color: var(--ink-muted); }
.hero__motto { margin-top: 6px; font-size: 17px; line-height: 1.4; }

/* ---------- Facts ---------- */
.facts { padding-bottom: var(--section); }
.facts__list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.fact {
  display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
  min-height: 170px; padding: 28px; border-radius: var(--radius);
}
.fact__num { font: 700 clamp(28px, 2.8vw, 40px)/1 var(--display); }
.fact__label { font-weight: 500; font-size: 17px; }
.fact--blue, .tab--t1 { background: radial-gradient(120% 90% at 50% 75%, #3794FE 0%, #62ACFF 55%, #A9D4FF 100%); }
.fact--mint, .tab--t2 { background: radial-gradient(120% 90% at 50% 75%, #3CE4AD 0%, #6CEBC4 55%, #B8F5E2 100%); }
.fact--purple, .tab--t3 { background: radial-gradient(120% 90% at 50% 75%, #9375FF 0%, #A993FF 55%, #D3CAFF 100%); }

/* ---------- Sections ---------- */
.section { padding: var(--section) 0; }
.section--flush { padding-top: 0; }
.section__head {
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px 64px; align-items: end;
  margin-bottom: 48px;
}
.section__head .lead { justify-self: end; max-width: 620px; }
.section__title { margin-bottom: 48px; }

/* Big white inset plate (live "Что это такое" / "Как это устроено") */
.plate { padding: 32px 36px; background: #fff; border-radius: var(--radius); }
.plate--lead { max-width: 1070px; margin-top: 40px; font-size: clamp(17px, 1.5vw, 21px); line-height: 1.45; }
.plate__text { margin-top: 16px; font-size: 19px; line-height: 1.45; }

.cards { display: grid; gap: 16px; margin-top: 16px; }
.cards--3 { grid-template-columns: repeat(3, 1fr); margin-top: 0; }
.cards--4 { grid-template-columns: repeat(4, 1fr); }
.cards--5 { grid-template-columns: repeat(5, 1fr); }
.card { padding: 28px; background: #fff; border-radius: var(--radius); }
.card .num { margin-bottom: 20px; }
.card .h3 { margin-bottom: 10px; }
.card p { color: var(--ink-soft); font-size: 16px; }
.card--cyan { background: var(--cyan); padding: 36px; }
.card--cyan p { font-size: 17px; }
.card__title { margin-bottom: 16px; font: 700 clamp(22px, 1.8vw, 26px)/1.15 var(--display); color: var(--blue-text); }

.section--about { background: var(--cyan) url("assets/background-about.svg") no-repeat right top / auto 100%; }
.section--about .plate--lead { margin-bottom: 24px; }

/* ---------- Programs: tabs ---------- */
.tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 32px; }
.tab {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end;
  min-height: 300px; padding: 28px; border: 0; border-radius: var(--radius);
  color: var(--ink); text-align: left; cursor: pointer;
  transition: box-shadow .15s ease;
}
.tab__digit { position: absolute; left: 24px; top: 24px; width: auto; height: 150px; pointer-events: none; }
.tab__icon { position: absolute; right: 36px; top: 96px; width: 112px; pointer-events: none; }
.tab__badge {
  position: absolute; top: 28px; right: 28px; padding: 12px 14px; border-radius: 2px;
  background: #fff; font: 700 18px/1 var(--mono); text-transform: uppercase;
}
.tab__name { position: relative; max-width: 78%; font: 600 21px/1.25 var(--sans); }
.tab:hover { box-shadow: 0 0 0 3px #fff, 0 0 0 5px rgba(0, 34, 0, .35); }
.tab[aria-selected="true"] { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--ink); }
.tab[aria-selected="true"] .tab__badge::before { content: "✓ "; content: "✓ " / ""; }
.tab:focus-visible { outline-offset: 9px; }

/* ---------- Programs: panel ---------- */
.track--t1 { --accent: var(--blue-text); }
.track--t2 { --accent: var(--green-text); }
.track--t3 { --accent: var(--violet-text); }
.track { padding: 48px; background: var(--cyan); border-radius: var(--radius); }
.track__intro { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: start; }
.track__tool { margin-top: 16px; color: var(--ink-soft); }
.track__title { margin-top: 12px; font: 700 clamp(28px, 3vw, 44px)/1.08 var(--display); overflow-wrap: break-word; }
.track__desc { margin-top: 16px; font-size: 18px; line-height: 1.5; color: var(--ink-soft); }
.trial { padding: 28px; background: #fff; border-radius: var(--radius); }
.trial__title { margin: 16px 0 8px; font: 700 21px/1.25 var(--sans); }
.trial p:last-child { color: var(--ink-soft); }

.months { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 40px; }
.months li { display: flex; flex-direction: column; gap: 6px; padding: 20px; background: #fff; border-radius: 12px; }
.months__n { font: 700 13px/1.6 var(--mono); text-transform: uppercase; color: var(--ink-muted); }
.months__n span { margin-right: 6px; padding: 3px 8px; border-radius: 2px; background: var(--accent); color: #fff; }
.months__t { font-weight: 700; font-size: 18px; line-height: 1.3; }
.months__r { font-size: 15px; line-height: 1.45; color: var(--ink-soft); }

.track__outcome {
  display: flex; align-items: center; justify-content: space-between; gap: 16px 40px; flex-wrap: wrap;
  margin-top: 16px; padding: 16px 16px 16px 28px; background: #fff; border-radius: var(--radius);
}
.track__outcome p { font-size: 18px; max-width: 640px; }

/* ---------- Lesson (mint) ---------- */
.section--mint { background: var(--mint) url("assets/background-mint.svg") no-repeat center / cover; }
.lesson__panels { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
/* Drop gets its own grid column; text + CTA never share space with it. */
.plate--parent { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; align-items: end; }
.plate--parent .btn { margin-top: 28px; }
/* The drop's hard-cut bottom/right edges sit flush on the card's bottom/right edge:
   negative margins cancel the plate padding (32px 36px ≥768; the drop is hidden below 768). */
.plate__drop {
  width: 200px; max-width: none; aspect-ratio: 4 / 3; object-fit: cover; object-position: right bottom;
  justify-self: end; margin: 0 -36px -32px 0; border-radius: 0 0 var(--radius) 0;
}
/* Hidden where the card is too narrow for text + 200px art: phones and the 1024–1199 two-card row */
@media (max-width: 767px), (min-width: 1024px) and (max-width: 1199px) {
  .plate__drop { display: none; }
}

/* ---------- Projects: illustrative first-lesson demos ---------- */
.method { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; }
.method__step {
  display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; align-items: center;
  padding: 20px 24px; background: var(--cyan); border-radius: var(--radius);
}
.method__step strong { font: 700 clamp(18px, 1.5vw, 22px)/1.2 var(--display); }
.method__step span:last-child { grid-column: 1 / -1; color: var(--ink-soft); font-size: 16px; }
.demos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.demo {
  display: flex; flex-direction: column; overflow: hidden;
  background: #fff; border: 2px solid var(--line); border-radius: var(--radius);
}
.demo--t1 { --accent: var(--blue-text); }
.demo--t2 { --accent: var(--green-text); }
.demo--t3 { --accent: var(--violet-text); }
.demo__art { position: relative; margin: 0; }
.demo__svg { display: block; width: 100%; height: auto; font-family: var(--sans); }
.demo__pin circle { fill: var(--ink); stroke: #fff; stroke-width: 2; }
.demo__pin text { fill: #fff; font: 700 12px var(--mono); text-anchor: middle; }
.demo__ui { fill: var(--ink); font-size: 10px; font-weight: 600; }
.demo__ui--muted { fill: var(--ink-muted); font-weight: 500; font-size: 9px; }
.demo__ui--title { font-size: 12px; font-weight: 700; }
.demo__ui--btn { fill: #fff; text-anchor: middle; }
/* Caption stays readable text for everyone: it is the honest "illustration" disclaimer */
.demo__cap { padding: 10px 20px 0; font-size: 13px; line-height: 1.4; color: var(--ink-muted); }
.demo__body { display: flex; flex-direction: column; flex: 1; padding: 16px 24px 24px; }
.demo__labels { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.demo__labels .badge { background: var(--accent); }
.demo__tag {
  padding: 7px 10px; border: 1.5px dashed var(--accent); border-radius: 2px;
  font: 700 12px/1.2 var(--mono); text-transform: uppercase; color: var(--accent);
}
.demo__title { margin-top: 14px; font: 700 clamp(20px, 1.7vw, 24px)/1.15 var(--display); }
.demo__steps { display: grid; gap: 10px; margin: 16px 0 24px; }
.demo__steps div { padding-left: 12px; border-left: 3px solid var(--line); }
.demo__steps div:nth-child(3) { border-left-color: var(--accent); }
.demo__steps dt { font: 700 12px/1.4 var(--mono); text-transform: uppercase; color: var(--accent); }
.demo__steps dd { margin: 2px 0 0; font-size: 15px; line-height: 1.45; color: var(--ink-soft); }
.demo__cta { margin-top: auto; }
/* ≥1024 the three cards share 9 content-sized rows (art, caption, labels, title, 4 steps, CTA),
   so matching parts start at the same height. Stacked cards below keep their own flex flow;
   browsers without subgrid keep it too. Gaps become margins so every row stays content-sized. */
@supports (grid-template-rows: subgrid) {
  @media (min-width: 1024px) {
    .demos { row-gap: 0; }
    .demo, .demo__art, .demo__body, .demo__steps { display: grid; grid-template-rows: subgrid; row-gap: 0; }
    .demo { grid-row: span 9; }
    .demo__art { grid-row: span 2; }
    .demo__body { grid-row: span 7; }
    .demo__steps { grid-row: span 4; }
    .demo__steps div + div { margin-top: 10px; }
  }
}

/* ---------- Learning: how regular study works ---------- */
.learn-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.learn-fact {
  display: flex; flex-direction: column; gap: 6px; padding: 24px;
  background: var(--cyan); border-radius: var(--radius); color: var(--ink-soft);
}
.learn-fact__num { font: 700 clamp(22px, 2.2vw, 32px)/1.1 var(--display); color: var(--blue-text); }
.learn__subtitle { margin: 48px 0 0; font: 700 clamp(22px, 2.2vw, 32px)/1.15 var(--display); }
.learn__month .card { background: var(--cyan); }
.learn__panels { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.plate--cyan { background: var(--cyan); }
.plate--cyan .btn { margin-top: 24px; }
.path { counter-reset: path; display: grid; gap: 14px; margin-top: 20px; }
.path li { counter-increment: path; position: relative; padding-left: 44px; font-size: 17px; }
.path li::before {
  content: counter(path); position: absolute; left: 0; top: -2px;
  width: 30px; height: 30px; display: grid; place-items: center;
  background: var(--blue-text); color: #fff; border-radius: 2px; font: 700 15px/1 var(--mono);
}
.checklist { display: grid; gap: 12px; margin-top: 20px; }
.checklist li { position: relative; padding-left: 32px; font-size: 17px; }
.checklist li::before { content: "✓"; content: "✓" / ""; position: absolute; left: 4px; top: 0; font-weight: 700; color: var(--green-text); }

/* ---------- Quest (space) ---------- */
.quest {
  overflow: hidden; padding-top: var(--section);
  background: #4DA2FF url("assets/background-space.png") no-repeat center / cover;
}
.quest__inner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px; align-items: end; }
.quest__panel {
  margin-bottom: var(--section); padding: 44px;
  background: linear-gradient(180deg, #fff 0%, var(--cyan) 100%); border-radius: var(--radius);
}
.quest__title { margin: 20px 0 16px; font: 700 clamp(26px, 2.7vw, 40px)/1.1 var(--display); color: var(--blue-text); }
.quest__text { font-size: 18px; max-width: 520px; }
.quest .btn { margin-top: 28px; }
.quest__pixel { justify-self: center; width: 100%; max-width: 560px; margin-bottom: -8px; }

/* ---------- FAQ ---------- */
.faq__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 40px; }
.faq__art { flex: none; width: clamp(64px, 6.6vw, 96px); }
.faq__list { display: grid; gap: 12px; max-width: 1180px; }
.faq__list details { background: var(--cyan); border-radius: 14px; }
.faq__list summary {
  display: grid; grid-template-columns: 28px 1fr; gap: 20px; align-items: center;
  min-height: 72px; padding: 18px 28px; border-radius: 14px; cursor: pointer; list-style: none;
  font: 700 clamp(16px, 1.7vw, 24px)/1.3 var(--sans);
}
.faq__list summary::-webkit-details-marker { display: none; }
.faq__list summary::before {
  content: ""; width: 28px; height: 28px; border: 2px solid var(--ink); border-radius: 50%;
  background:
    linear-gradient(var(--ink), var(--ink)) center / 12px 2px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 2px 12px no-repeat;
}
.faq__list details[open] summary::before {
  background:
    linear-gradient(var(--ink), var(--ink)) center / 12px 2px no-repeat;
}
.faq__list summary:hover { color: var(--blue-text); }
.faq__list details p { padding: 0 28px 24px 76px; font-size: 17px; color: var(--ink-soft); max-width: 900px; }

/* ---------- Signup ---------- */
.signup {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.95fr); column-gap: 48px; row-gap: 20px;
  grid-template-areas: "title art" "lead art" "form art";
  grid-template-rows: auto auto 1fr;
}
.signup__title { grid-area: title; font: 700 clamp(30px, 3.35vw, 48px)/1.05 var(--display); }
.signup__lead { grid-area: lead; font-size: 20px; line-height: 1.4; }
.signup__art { grid-area: art; justify-self: end; width: 100%; max-width: 560px; border-radius: var(--radius); }
.preview-note {
  margin-top: 16px; padding: 12px 16px; background: #FFF7DC; border-radius: 12px;
  font-size: 15px; line-height: 1.4;
}
.form { grid-area: form; display: grid; gap: 16px; align-content: start; }
.form__fields { display: grid; gap: 16px; min-width: 0; margin: 0; padding: 0; border: 0; }
.form__fields:disabled { opacity: .6; }
.form .preview-note { margin-top: 0; }
.form__plate {
  display: grid; gap: 8px; padding: 12px 28px 28px;
  background: linear-gradient(135deg, var(--cyan) 0%, var(--cyan-soft) 100%); border-radius: var(--radius);
}
.field { display: grid; gap: 2px; padding-top: 16px; }
.field label { font-weight: 600; font-size: 14px; color: var(--blue-text); }
.field input:not([type="checkbox"]), .field select {
  width: 100%; min-height: 48px; padding: 8px 0;
  background: transparent; border: 0; border-bottom: 1.5px solid var(--blue); border-radius: 0;
  font-weight: 500; font-size: 18px; color: var(--ink); outline: none;
  -webkit-appearance: none; appearance: none;
}
.field select {
  cursor: pointer; padding-right: 28px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none'%3E%3Cpath d='M1 1l6 6 6-6' stroke='%231F6FD6' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 4px center;
}
.field input:not([type="checkbox"]):focus-visible, .field select:focus-visible {
  border-bottom-color: var(--blue-text); box-shadow: 0 2px 0 var(--blue-text);
}
.field input::placeholder { color: #4F7690; opacity: 1; }

/* Branded age dropdown (app.js enhances select#f-age; the native select is the fallback) */
.select { position: relative; }
.select__trigger {
  display: block; width: 100%; min-height: 48px; padding: 8px 32px 8px 0; text-align: left; cursor: pointer;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none'%3E%3Cpath d='M1 1l6 6 6-6' stroke='%231F6FD6' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 4px center;
  border: 0; border-bottom: 1.5px solid var(--blue); border-radius: 0;
  font-weight: 500; font-size: 18px; color: var(--ink); outline: none;
}
.select__trigger[aria-expanded="true"] {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none'%3E%3Cpath d='M1 8l6-6 6 6' stroke='%231F6FD6' stroke-width='2'/%3E%3C/svg%3E");
}
.select__trigger.is-placeholder { color: #4F7690; }
.select__trigger:focus-visible { border-bottom-color: var(--blue-text); box-shadow: 0 2px 0 var(--blue-text); }
.select__list {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 5;
  display: grid; gap: 2px; margin: 0; padding: 6px;
  background: #fff; border: 1.5px solid var(--blue); border-radius: 12px; outline: none;
}
.select__option {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 44px; padding: 8px 12px; border-radius: 8px; cursor: pointer;
  font-weight: 500; font-size: 17px; color: var(--ink);
}
.select__option.is-active { background: var(--cyan); }
.select__list:focus .select__option.is-active { box-shadow: inset 0 0 0 2px var(--blue-text); }
.select__option[aria-selected="true"] { font-weight: 700; color: var(--green-text); }
.select__option[aria-selected="true"]::after { content: "✓"; content: "✓" / ""; font-weight: 700; }
.field [aria-invalid="true"] { border-bottom-color: var(--error) !important; }
.field__error { margin-top: 4px; color: var(--error); font-size: 14px; }
.field__note { font-size: 13px; color: var(--ink-muted); }

.field--check { grid-template-columns: 44px 1fr; column-gap: 4px; align-items: center; padding-top: 12px; }
.field--check input { width: 22px; height: 22px; margin: 11px; accent-color: var(--blue-text); cursor: pointer; }
.field--check label { padding: 10px 0; font-size: 15px; line-height: 1.35; cursor: pointer; }
.field--check .field__note, .field--check .field__error { grid-column: 2; }

.form__status:empty { display: none; }
.form__status { padding: 16px; border-radius: 12px; background: #DDF8EE; font-weight: 600; }
.form__status.is-error { background: #FDECEA; color: var(--error); }

/* ---------- Footer (mint + footer-art drop) ----------
   One composition at every width: contacts/socials top-left, logo top-right,
   legal bottom-left, drop art bottom-right touching the footer's bottom edge.
   Below 768 the legal block takes its own full-width row; nothing else moves. */
.footer { padding-top: clamp(48px, 5.5vw, 80px); background: var(--mint-footer); }
.footer__inner {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 32px; row-gap: 32px;
  grid-template-areas: "reach logo" "legal art";
}
.footer__reach { grid-area: reach; }
.footer__logo { grid-area: logo; align-self: start; justify-self: end; display: block; }
.footer__logo img { width: clamp(64px, 8vw, 112px); }
.footer__legal { grid-area: legal; align-self: end; padding-bottom: 40px; }
/* footer-art.png 1167×696: soft glow top-left, drop at the bottom-right edge (intentional crop) */
.footer__art {
  grid-area: art; align-self: end; justify-self: end; width: clamp(240px, 33vw, 480px); pointer-events: none;
  /* The PNG's glow is opaque at its right edge; fade the last 8% (drop body ends ≈ 89.5%) to remove the seam */
  -webkit-mask-image: linear-gradient(to right, #000 92%, transparent 100%);
  mask-image: linear-gradient(to right, #000 92%, transparent 100%);
}
.footer__contacts, .footer__social { display: flex; flex-wrap: wrap; gap: 12px; }
.footer__social { margin-top: 12px; }
.chip {
  display: inline-flex; flex-wrap: wrap; align-items: center; column-gap: 0.6em;
  min-height: 52px; padding: 8px 16px;
  background: #fff; border-radius: 2px; text-decoration: none;
  font: 700 18px/1.25 var(--mono); text-transform: uppercase;
}
.social {
  display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px;
  background: #fff; border-radius: 2px;
}
.social img { width: 32px; height: 32px; }
.chip:hover, .social:hover { background: var(--cyan); }
.footer__docs { display: flex; flex-wrap: wrap; gap: 4px 32px; font-weight: 600; font-size: 15px; }
.footer__docs li { display: flex; align-items: center; min-height: 44px; }
.footer__docs a, .footer__bottom a { text-underline-offset: 4px; }
.footer .pending { color: var(--ink); }
.footer__bottom { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 32px; margin-top: 8px; font-weight: 600; font-size: 15px; }
.footer__bottom a { display: inline-flex; align-items: center; min-height: 44px; }

/* ================= ≤1199 ================= */
@media (max-width: 1199px) {
  .cards--4 { grid-template-columns: repeat(2, 1fr); }
  .cards--5 { grid-template-columns: repeat(3, 1fr); }
  .learn-facts { grid-template-columns: repeat(2, 1fr); }
  .nav__phone { display: none; }
  .nav { gap: 8px; }
  .nav__list a { padding: 0 8px; }
  .track { padding: 36px; }
  .quest__panel { padding: 36px; }
}

/* ================= ≤1023: burger ================= */
@media (max-width: 1023px) {
  .burger {
    display: inline-flex; align-items: center; justify-content: center;
    width: 56px; height: 48px; padding: 0; background: none; border: 0; cursor: pointer;
  }
  .burger__lines { display: grid; gap: 8px; width: 40px; }
  .burger__lines span { display: block; height: 3px; background: var(--ink); border-radius: 1px; transition: transform .15s ease, opacity .15s ease; }
  /* Open state: thin 2px X like live */
  .burger[aria-expanded="true"] .burger__lines span { height: 2px; }
  .burger[aria-expanded="true"] .burger__lines span:nth-child(1) { transform: translateY(10px) rotate(45deg); }
  .burger[aria-expanded="true"] .burger__lines span:nth-child(2) { opacity: 0; }
  .burger[aria-expanded="true"] .burger__lines span:nth-child(3) { transform: translateY(-10px) rotate(-45deg); }

  /* Live mobile menu: white full-screen panel under the header, plain left-aligned links */
  .nav {
    position: fixed; inset: var(--header-h) 0 0 0; overflow-y: auto;
    display: none; flex-direction: column; align-items: flex-start; gap: 0;
    padding: 8px var(--gutter) 32px; background: #fff;
  }
  .nav.is-open { display: flex; }
  .nav__list { flex-direction: column; gap: 0; }
  .nav__list a { min-height: 44px; padding: 0; font-weight: 500; font-size: 18px; }
  .nav__phone { display: inline-flex; margin-top: 20px; padding: 0; font-weight: 500; font-size: 16px; }
  .nav .btn { width: auto; margin-top: 12px; }

  .tab { min-height: 240px; padding: 20px; }
  .tab__digit { height: 110px; left: 16px; top: 16px; }
  .tab__icon { width: 76px; right: 20px; top: 84px; }
  .tab__badge { top: 20px; right: 20px; padding: 8px 10px; font-size: 14px; }
  .tab__name { max-width: none; font-size: 17px; }

  .section__head { grid-template-columns: 1fr; }
  .section__head .lead { justify-self: start; }
  .track__intro { grid-template-columns: 1fr; gap: 24px; }
  .months { grid-template-columns: repeat(2, 1fr); }
  .lesson__panels, .learn__panels { grid-template-columns: 1fr; }
  .demos { grid-template-columns: 1fr; max-width: 640px; }
  .method { grid-template-columns: 1fr; }
  .quest__inner { grid-template-columns: 1fr; }
  .quest__panel { margin-bottom: 0; }
  .quest__pixel { max-width: 380px; }

  /* Tablet hero: same two-column stage, tighter paddings (logo is 64px here) */
  .hero__offer { padding: 32px 24px 36px 32px; }
  .hero__art { padding: 96px 8px 20px; }

  /* Tablet signup: intro + capped art on top, full-width form below */
  .signup {
    grid-template-columns: minmax(0, 1fr) minmax(0, 300px); column-gap: 32px;
    grid-template-areas: "title art" "lead art" "form form";
    grid-template-rows: auto 1fr auto;
  }
  .signup__art { max-width: 300px; align-self: start; }
  .form { margin-top: 12px; }
}
@media (max-width: 1023px) {
  /* Without JS the menu stays visible instead of hiding behind a dead burger */
  html:not(.js) .burger { display: none; }
  html:not(.js) .nav { position: static; display: flex; padding: 0 0 16px; border: 0; }
  html:not(.js) .header__inner { flex-wrap: wrap; }
  html:not(.js) .header { position: static; }
}

/* ================= <768: phones ================= */
@media (max-width: 767px) {
  :root { --header-h: 81px; }
  body { font-size: 16px; }
  .header__inner { padding-top: 12px; padding-bottom: 12px; }
  .header__logo img { width: 64px; }
  .lead { font-size: 17px; }

  .btn, .btn--lg { width: 100%; min-height: 48px; padding: 0 16px; font-size: 16px; }

  /* Phone hero: heading → band with full-width offer, then the whole egg below it.
     The band spans rows 2–3; the right 42% tab rises 28px above it (stepped Union look). */
  .hero { padding-top: 8px; }
  .hero__stage { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto auto; }
  .hero__stage::before { grid-column: 1; grid-row: 2 / 4; justify-self: end; width: 42%; margin-top: -28px; }
  .hero__stage::after { grid-column: 1; grid-row: 2 / 4; }
  /* bottom padding > the 28px step so the tab never reaches the heading text */
  .hero__title { grid-column: 1; padding: 4px 0 40px; }
  .hero__offer { grid-column: 1; grid-row: 2; padding: 24px 20px 8px; }
  .hero__offer::before { right: 42%; }
  .hero__lead { margin-top: 12px; font-size: 16px; }
  .hero .badge { font-size: 12px; padding: 6px 8px; }
  .hero__art { grid-column: 1; grid-row: 3; padding: 0 20px 16px; }
  .hero__figure { max-width: 400px; }
  .hero__logo { display: none; }
  .hero__actions { grid-template-columns: 1fr; margin-top: 16px; }
  .hero__motto { font-size: 16px; }

  .facts__list { grid-template-columns: 1fr; gap: 8px; }
  /* Row layout: start-aligned (the desktop column's justify-content:flex-end would push it right) */
  .fact { min-height: 0; flex-direction: row; flex-wrap: wrap; justify-content: flex-start; align-items: baseline; gap: 4px 12px; padding: 18px 20px; }
  .fact__num { flex: 0 0 auto; font-size: 24px; }
  .fact__label { flex: 1 1 12em; min-width: 0; font-size: 15px; }

  .section__head, .section__title { margin-bottom: 28px; }
  .plate { padding: 20px; }
  .plate--lead { margin-top: 24px; font-size: 16px; }
  .plate__text { font-size: 16px; }
  .cards--3, .cards--4, .cards--5, .learn-facts { grid-template-columns: 1fr; }
  .learn-fact { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; padding: 16px 20px; }
  .learn__subtitle { margin-top: 32px; }
  .method__step { padding: 16px 20px; }
  .demo__body { padding: 14px 20px 20px; }
  .path li, .checklist li { font-size: 16px; }
  .card, .card--cyan { padding: 20px; }
  .card .num { margin-bottom: 12px; }
  .section--about { background-size: auto 420px; }

  .tabs { grid-template-columns: 1fr; gap: 16px; }
  .tab { min-height: 180px; padding: 24px; }
  .tab__digit { display: none; }
  .tab__badge { left: 24px; right: auto; top: 24px; }
  .tab__icon { width: 72px; top: 20px; right: 20px; }
  .tab__name { font-size: 18px; max-width: 80%; }

  .track { padding: 20px 16px; }
  .track__desc { font-size: 16px; }
  .trial { padding: 20px; }
  .months { grid-template-columns: 1fr; gap: 8px; margin-top: 24px; }
  .months li { padding: 14px 16px; gap: 4px; }
  .months__t { font-size: 16px; }
  .months__r { font-size: 14px; }
  .track__outcome { padding: 16px; }
  .track__outcome p { font-size: 16px; }

  .quest__panel { padding: 24px 20px; }
  .quest__text { font-size: 16px; }
  .quest__pixel { max-width: 260px; }

  .faq__head { margin-bottom: 24px; }
  .faq__list summary { grid-template-columns: 26px 1fr; gap: 16px; min-height: 56px; padding: 14px 16px; }
  .faq__list summary::before { width: 26px; height: 26px; }
  .faq__list details p { padding: 0 16px 18px 58px; font-size: 15px; }

  .signup {
    grid-template-columns: minmax(0, 1fr) minmax(0, 160px); column-gap: 16px;
    grid-template-areas: "title title" "lead art" "form form";
    grid-template-rows: auto;
  }
  .signup__lead { font-size: 16px; align-self: center; }
  .signup__art { max-width: 160px; align-self: center; }
  .form { margin-top: 4px; }
  .form__plate { padding: 4px 20px 20px; }

  /* Footer: same corners; legal gets a full-width row, art stays bottom-right */
  .footer__inner { row-gap: 24px; grid-template-areas: "reach logo" "legal legal" "art art"; }
  .footer__legal { padding-bottom: 0; }
  .chip { min-height: 44px; padding: 6px 12px; font-size: 14px; }
  .social { width: 44px; height: 44px; }
  .social img { width: 28px; height: 28px; }
  .footer__docs { flex-direction: column; gap: 0; font-size: 14px; }
  .footer__bottom { font-size: 14px; }
}

/* Small phones: stack the signup intro so the lead keeps a readable line length */
@media (max-width: 479px) {
  .signup { grid-template-columns: minmax(0, 1fr); grid-template-areas: "title" "lead" "art" "form"; }
  .signup__art { max-width: 240px; justify-self: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  /* pixel-drop.webp is animated; hide it rather than autoplay */
  .plate__drop { display: none; }
}
