/* Zarina The Fit: дизайн-система, версия 2
   Шрифты: Golos Text (заголовки 800, текст 400-600), Bona Nova курсив (только акцент: прямая речь, девиз).
   Цвет: глубокая слива для больших секций, лайм для кнопок и ярлыков, светлая бумага для чтения.

   ОГЛАВЛЕНИЕ КОМПОНЕНТОВ
   Каркас      .wrap (1120), .wrap-narrow (760), .section, .section-head (h2 + p),
               .split (заголовок слева, текст справа на десктопе)
   Текст       .lead, .gap-top, .small, .muted, .voice (прямая речь Зарины, курсив), .text-link, .visually-hidden
   Цвет        .tint-pelvic | .tint-iron | .tint-weight | .tint-cabbage | .tint-sage | .tint-lilac
               задают пару «фон + текст» (--tint, --tint-ink) и пару «акцент» (--pop, --pop-ink).
               Цветные поверхности: .product-hero, .course-card, .price-box.is-tinted, .buy-strip, .section.tint-*
               Класс .tint-* на <main> красит .buy-strip и закреплённую кнопку в цвет продукта.
   Кнопки      .btn + .btn-primary | .btn-ghost, .btn-block
   Ярлыки      .sticker (наклонная пилюля), .badge-free, .chips (ряд пилюль: состав, темы)
   Цифры       .stats > li > b + span (крупные цифры из состава)
   Шапка       .site-header > .logo, .site-nav, .site-account
   Подвал      .site-footer > .footer-motto, .footer-links
   Главная     .hero > .hero-inner > .hero-copy + .hero-visual (.hero-portrait, .sticker) + .topics
   Карточки    .course-grid > .course-card (+ .tint-*, .is-wide)
                 внутри: .sticker, h3 > a, .course-card-meta, p, .course-card-foot > .price-inline + .more
               .free-band (яркая секция) > .guide-grid > .guide-card > .guide-cover + div (.badge-free, h3 > a, p, .more)
               .offer-list > .offer (строки услуг: h3 > a, p, .offer-price > small)
   Продукт     .product-hero (+ .tint-*) > .product-hero-inner > div + .price-box (+ .stats)
               .product-kind (ярлык над h1), .episodes (карточки выпусков с длительностью)
   Цена        .price (+ small), .buy-row, .buy-strip, .price-box (+ .is-tinted): .price-label, .price,
               .price-includes, .btn, .price-note; .buy-bar (закреплённая кнопка на телефоне, создаёт app.js)
   Списки      .inside-list (li > h3 + p), .numbered (ol: li > h3 + .numbered-meta + p)
   Оговорки    .caution (с h3), .footnote

   Окно оплаты, кабинет и страница курса живут в css/shop.css и берут токены отсюда. */

:root {
  /* цвет: постоянные значения */
  --c-ink: #2a1027;
  --c-ink-2: #5d4a5a;
  --c-ink-3: #6f5d6c;
  --c-line: rgba(42, 16, 39, 0.16);
  --bg: #f7f2f4;
  --surface: #ffffff;
  --soft: #f0e4ee;
  --plum: #45173f;
  --plum-dark: #32102e;
  --beet: #9c1d54;
  --green: #1c4a36;
  --lime: #d5f25c;
  --lime-ink: #1a2a0c;
  --sage: #d8eab8;
  --lilac: #eab4e4;
  --free: var(--lime);
  --free-ink: var(--lime-ink);
  --caution-bg: #fdeecb;
  --ok: #1c4a36;
  --error: #a3261f;
  --overlay: rgba(42, 16, 39, 0.6);

  /* цвет: значения, которые цветные поверхности переопределяют для своих потомков */
  --ink: var(--c-ink);
  --ink-2: var(--c-ink-2);
  --ink-3: var(--c-ink-3);
  --line: var(--c-line);
  --btn: var(--plum);
  --btn-ink: #fff;
  --focus: var(--plum);
  --stat: var(--plum);
  --tint: var(--plum);
  --tint-ink: #fff;
  --pop: var(--lime);
  --pop-ink: var(--lime-ink);

  /* шрифт */
  --font-display: "Golos Text", "Arial Black", system-ui, sans-serif;
  --font-text: "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-accent: "Bona Nova", Georgia, "Times New Roman", serif;

  /* форма и размер */
  --radius-s: 10px;
  --radius-m: 18px;
  --radius-l: 28px;
  --radius-pill: 999px;
  --wrap: 1120px;
  --pad: clamp(20px, 5vw, 40px);
  --shadow-pop: 0 24px 64px rgba(42, 16, 39, 0.28);

  /* движение */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1); /* нижний лист и закреплённая кнопка */
  --dur-fast: 140ms;
  --dur: 220ms;
}

.tint-pelvic { --tint: var(--plum); --tint-ink: #fff; --pop: var(--lime); --pop-ink: var(--lime-ink); }
.tint-iron { --tint: var(--beet); --tint-ink: #fff; --pop: var(--lime); --pop-ink: var(--lime-ink); }
.tint-weight { --tint: var(--green); --tint-ink: #fff; --pop: var(--lime); --pop-ink: var(--lime-ink); }
.tint-cabbage { --tint: var(--lime); --tint-ink: var(--lime-ink); --pop: var(--plum); --pop-ink: #fff; }
.tint-sage { --tint: var(--sage); --tint-ink: #14301f; --pop: var(--green); --pop-ink: #fff; }
.tint-lilac { --tint: var(--lilac); --tint-ink: var(--plum-dark); --pop: var(--plum); --pop-ink: #fff; }

/* Цветная поверхность: фон --tint, всё внутри перекрашивается под него */
.site-header, .site-footer, .hero, .product-hero, header.page-head, .course-card, .price-box.is-tinted, .buy-strip, .buy-bar, .section[class*="tint-"], .free-band {
  --ink: var(--tint-ink);
  --ink-2: color-mix(in srgb, var(--tint-ink) 82%, var(--tint));
  --ink-3: color-mix(in srgb, var(--tint-ink) 82%, var(--tint));
  --line: color-mix(in srgb, var(--tint-ink) 24%, transparent);
  --btn: var(--pop);
  --btn-ink: var(--pop-ink);
  --focus: var(--pop);
  --stat: var(--pop);
  background: var(--tint);
  color: var(--ink);
}
/* Плашка: то же наоборот (фон --pop). Блок цены в первом экране и блок цены внутри цветной секции */
.product-hero .price-box, .section[class*="tint-"] .price-box.is-tinted:not([class*="tint-"]) {
  --ink: var(--pop-ink);
  --ink-2: color-mix(in srgb, var(--pop-ink) 82%, var(--pop));
  --ink-3: color-mix(in srgb, var(--pop-ink) 82%, var(--pop));
  --line: color-mix(in srgb, var(--pop-ink) 24%, transparent);
  --btn: var(--tint);
  --btn-ink: var(--tint-ink);
  --focus: var(--tint);
  --stat: var(--tint);
  background: var(--pop);
  color: var(--ink);
}
/* Белая поверхность внутри цветной: возвращает обычные цвета */
.guide-card, .inside-list li, .episodes li, .caution, .shop, .notice {
  --ink: var(--c-ink);
  --ink-2: var(--c-ink-2);
  --ink-3: var(--c-ink-3);
  --line: var(--c-line);
  --btn: var(--plum);
  --btn-ink: #fff;
  --focus: var(--plum);
  --stat: var(--plum);
  color: var(--ink);
}
/* цвет на всю ширину окна без лишней обёртки */
.site-header, .product-hero, header.page-head { box-shadow: 0 0 0 100vmax var(--tint); clip-path: inset(0 -100vmax); }
.site-header { margin-bottom: -1px; } /* следующий блок перекрывает волосяную щель при дробной высоте шапки */

/* База */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.55 var(--font-text);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 800; line-height: 1.02; letter-spacing: -0.025em; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 8vw, 5rem); line-height: 0.96; letter-spacing: -0.035em; }
h2 { font-size: clamp(2rem, 5.4vw, 3.5rem); }
h3 { font-size: 1.375rem; line-height: 1.15; letter-spacing: -0.015em; font-weight: 700; }
p { max-width: 62ch; text-wrap: pretty; }
p + p { margin-top: 0.8em; }
a { color: inherit; }
[id] { scroll-margin-top: 24px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
/* телефон: без задержки двойного касания; долгое нажатие не выделяет подпись кнопки */
a, button, label { touch-action: manipulation; }
button, .btn, .more, .logo, .site-nav a, .site-account, .chips a, a.sticker { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }

.wrap { width: 100%; max-width: calc(var(--wrap) + var(--pad) * 2); margin-inline: auto; padding-inline: max(var(--pad), env(safe-area-inset-left), env(safe-area-inset-right)); }
.wrap-narrow { max-width: calc(760px + var(--pad) * 2); }
.section { padding-block: clamp(40px, 6vw, 72px); }
.section + .section { padding-top: 0; }
.section[class*="tint-"], .free-band, .section[class*="tint-"] + .section, .free-band + .section { padding-block: clamp(48px, 7vw, 88px); }
.section-head { margin-bottom: clamp(24px, 4vw, 40px); }
.section-head p { margin-top: 12px; color: var(--ink-2); }
.section-head .sticker, .section-head .product-kind { margin: 0 0 16px; color: var(--pop-ink); }
.split { display: grid; gap: 20px 48px; }
.split > * { min-width: 0; }
/* секции на бумаге отделяет жирная линия: страница читается как список разделов */
.section + .section:not([class*="tint-"]) > .split::before { content: ""; grid-column: 1 / -1; height: 2px; margin-bottom: clamp(4px, 2vw, 20px); background: var(--ink); }
.section[class*="tint-"] + .section > .split::before, .free-band + .section > .split::before { content: none; }

.lead { font-size: clamp(1.1875rem, 2.6vw, 1.4375rem); line-height: 1.38; font-weight: 500; }
.small { font-size: 0.875rem; line-height: 1.5; }
.muted { color: var(--ink-2); }
.voice { max-width: 26ch; padding-left: 20px; border-left: 4px solid var(--pop); font: italic 400 clamp(1.5rem, 3.6vw, 2.125rem)/1.22 var(--font-accent); }
.voice + p { margin-top: 20px; }
.text-link { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; text-decoration-color: color-mix(in srgb, currentColor 45%, transparent); transition: text-decoration-color var(--dur) ease; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Кнопки */
.btn {
  display: inline-block; min-height: 56px; padding: 15px 28px; /* не flex: стрелка ↗ остаётся в строке с последним словом */
  border: 2px solid transparent; border-radius: var(--radius-pill);
  font: 600 1.0625rem/22px var(--font-text); text-decoration: none; text-align: center;
  cursor: pointer;
  transition: background-color var(--dur) ease, border-color var(--dur) ease, transform var(--dur-fast) var(--ease-out);
}
.btn-primary { background: var(--btn); color: var(--btn-ink); }
.btn-ghost { background: transparent; color: var(--ink); border-color: color-mix(in srgb, var(--ink) 40%, transparent); }
.btn-block { width: 100%; }
/* стрелка у кнопок, которые уводят в Instagram; пустой alt, чтобы её не читал скринридер */
.btn[target="_blank"]::after { content: "\00a0↗"; content: "\00a0↗" / ""; }
.btn:disabled { opacity: 0.5; cursor: default; }

/* Ярлыки */
.sticker, .product-kind, .badge-free {
  display: inline-block; width: fit-content; padding: 7px 14px; border-radius: var(--radius-pill);
  background: var(--pop); color: var(--pop-ink);
  font: 600 0.875rem/1.2 var(--font-text); letter-spacing: 0; white-space: nowrap;
  transform: rotate(-3deg);
}
.sticker.is-white { background: #fff; color: var(--plum-dark); }
.sticker.is-lilac { background: var(--lilac); color: var(--plum-dark); }
.product-kind { margin-bottom: 20px; }
.product-kind:has(.badge-free) { padding: 0; background: none; transform: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.chips li, .chips a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 16px; border: 1.5px solid color-mix(in srgb, var(--ink) 45%, transparent); border-radius: var(--radius-pill); font: 500 0.9375rem/1.2 var(--font-text); }
.chips li:has(a) { padding: 0; border: 0; }
.chips a { min-height: 44px; text-decoration: none; transition: background-color var(--dur) ease, color var(--dur) ease, border-color var(--dur) ease, transform var(--dur-fast) var(--ease-out); }

/* Крупные цифры из состава */
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 24px; margin: 0; padding: 0; list-style: none; }
.stats li { display: grid; align-content: start; gap: 8px; padding-top: 16px; border-top: 2px solid var(--line); }
.stats b { font: 800 clamp(3.25rem, 13vw, 5.5rem)/0.86 var(--font-display); letter-spacing: -0.04em; color: var(--stat); font-variant-numeric: lining-nums; white-space: nowrap; }
.stats b small { font-size: 0.42em; letter-spacing: -0.02em; }
.stats span { font-size: 0.9375rem; line-height: 1.35; color: var(--ink-2); }

/* Шапка */
.site-header { display: flex; flex-wrap: wrap; align-items: center; gap: 0 28px; padding-block: 8px; --tint: var(--plum); --tint-ink: #fff; --pop: var(--lime); --pop-ink: var(--lime-ink); }
.logo { display: inline-block; margin-right: auto; padding-block: 8px; font: 800 1.375rem/1.75rem var(--font-display); letter-spacing: -0.03em; color: var(--ink); text-decoration: none; }
.site-nav { display: flex; gap: 24px; order: 3; width: 100%; }
.site-nav a, .site-account { font-size: 0.9375rem; font-weight: 500; color: var(--ink-2); text-decoration: none; transition: color var(--dur) ease; }
.site-nav a { padding-block: 11px; }
.site-account { order: 2; padding: 9.5px 18px; /* вместе с рамкой 44 px */ border: 1.5px solid color-mix(in srgb, var(--ink) 45%, transparent); border-radius: var(--radius-pill); color: var(--ink); transition: background-color var(--dur) ease, color var(--dur) ease, border-color var(--dur) ease, transform var(--dur-fast) var(--ease-out); }

/* Подвал */
.site-footer { padding-block: 48px calc(48px + env(safe-area-inset-bottom)); --tint: var(--plum); --tint-ink: #fff; --pop: var(--lime); --pop-ink: var(--lime-ink); }
.site-footer .wrap { display: grid; gap: 24px; }
.site-footer .logo { font-size: clamp(2rem, 7vw, 3rem); line-height: 1; }
.footer-motto { margin-top: 4px; font: italic 400 1.375rem/1.3 var(--font-accent); color: var(--pop); }
.footer-links { display: grid; justify-items: start; font-size: 0.9375rem; }
.footer-links a { padding-block: 12px; color: var(--ink-2); text-decoration: none; transition: color var(--dur) ease; }

/* Первый экран главной */
.hero { overflow: hidden; }
.hero-inner { display: grid; gap: 32px 48px; align-items: center; padding-block: clamp(24px, 4vw, 40px) clamp(32px, 5vw, 56px); }
.hero-copy { min-width: 0; container-type: inline-size; }
/* размер от ширины колонки: «Оздоровление» всегда помещается в строку */
.hero h1 { font-size: clamp(2.25rem, 13.4cqi, 5.5rem); line-height: 0.94; }
.hero-text { margin-top: 20px; max-width: 30ch; font-size: clamp(1.125rem, 2.4vw, 1.3125rem); line-height: 1.4; color: var(--ink-2); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-visual { position: relative; width: min(84%, 440px); margin-inline: auto; }
/* круг: нижняя половина режет фигуру, голова и плечо выходят за форму сверху */
.hero-portrait { position: relative; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 0 0 50% 50% / 0 0 37.5% 37.5%; }
.hero-portrait::before { content: ""; position: absolute; inset: 25% 0 0; border-radius: 50%; background: var(--pop); }
.hero-portrait picture { display: contents; }
.hero-portrait img { position: relative; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.hero-visual .sticker { position: absolute; z-index: 1; font-size: clamp(0.875rem, 2.4vw, 1.0625rem); }
.hero-visual .sticker.is-lilac { left: -8%; top: 46%; transform: rotate(-8deg); font: italic 400 clamp(1.125rem, 3vw, 1.5rem)/1.2 var(--font-accent); padding: 8px 18px; }
.hero-visual a.sticker { right: -6%; bottom: 13%; transform: rotate(5deg); text-decoration: none; padding: 12px 18px; }
.topics { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding-top: 20px; border-top: 2px solid var(--line); }
.topics p { font-size: 0.9375rem; color: var(--ink-2); }

/* Карточки курсов: обложки */
.course-grid { display: grid; gap: 16px; }
.course-card {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 12px;
  min-height: 300px; padding: 24px; overflow: hidden; border-radius: var(--radius-l);
  container-type: inline-size; isolation: isolate;
  transition: transform var(--dur) var(--ease-out);
}
/* круг в углу обложки, тот же мотив, что и у портрета */
.course-card::before { content: ""; position: absolute; z-index: -1; right: -22%; top: -30%; width: 70%; aspect-ratio: 1; border-radius: 50%; background: color-mix(in srgb, var(--tint) 86%, var(--tint-ink)); pointer-events: none; }
.course-card.is-wide > div:first-child { display: grid; justify-items: start; gap: 12px; }
.course-card-meta { font-weight: 600; line-height: 1.3; }
.course-card h3 { margin-top: 8px; font-size: clamp(1.5rem, 12.5cqi, 3rem); /* «Железодефицит» помещается в строку при любой ширине карточки */ font-weight: 800; line-height: 0.96; letter-spacing: -0.035em; }
.course-card p:not(.course-card-meta) { font-size: 0.9375rem; line-height: 1.45; color: var(--ink-2); }
.course-card h3 a, .guide-card h3 a, .offer h3 a { color: inherit; text-decoration: none; }
.course-card h3 a::after, .guide-card h3 a::after, .offer h3 a::after { content: ""; position: absolute; inset: 0; }
.course-card h3 a:focus-visible, .guide-card h3 a:focus-visible, .offer h3 a:focus-visible { outline: none; }
.course-card:has(a:focus-visible), .guide-card:has(a:focus-visible), .offer:has(a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.course-card:has(a:focus-visible) { outline-color: var(--c-ink); } /* обводка снаружи карточки, на бумаге */
.course-card-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; align-self: stretch; margin-top: auto; padding-top: 20px; }
.price-inline { font: 800 1.75rem/1 var(--font-display); letter-spacing: -0.03em; white-space: nowrap; }
.more { display: inline-flex; align-items: center; min-height: 44px; padding: 0 20px; border-radius: var(--radius-pill); background: var(--btn); color: var(--btn-ink); font: 600 0.9375rem/1.2 var(--font-text); white-space: nowrap; transition: background-color var(--dur) ease; }

/* Бесплатные гайды: яркая секция */
.free-band { --tint: var(--lilac); --tint-ink: var(--plum-dark); --pop: var(--plum); --pop-ink: #fff; }
.guide-grid { display: grid; gap: 16px; }
.guide-card { position: relative; display: grid; gap: 24px; align-content: start; padding: 24px; border-radius: var(--radius-l); background: var(--surface); transition: transform var(--dur) var(--ease-out); }
.guide-card > div { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; min-width: 0; }
.guide-card h3 { font-size: clamp(1.625rem, 4vw, 2rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.guide-card p { color: var(--ink-2); }
.guide-card .more { margin-top: auto; }
.guide-card .badge-free { background: var(--lime); color: var(--lime-ink); }
/* нарисованная обложка гайда */
.guide-cover {
  position: relative; display: flex; flex-direction: column; gap: 10px; overflow: hidden;
  width: 164px; aspect-ratio: 3 / 4; margin: 4px 0 8px 8px; padding: 16px 12px 14px 24px;
  border-radius: 4px 14px 14px 4px; background: var(--cover, var(--plum)); color: #fff;
  box-shadow: 8px 8px 0 color-mix(in srgb, var(--cover, var(--plum)) 22%, transparent);
  transform: rotate(-4deg);
}
.guide-cover::before { content: ""; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: rgba(255, 255, 255, 0.28); }
.guide-cover::after { content: ""; position: absolute; right: -30%; bottom: -24%; width: 80%; aspect-ratio: 1; border-radius: 50%; background: var(--lime); }
.guide-cover b { position: relative; order: 1; font: 800 1.125rem/1 var(--font-display); letter-spacing: -0.03em; }
.guide-cover small { position: relative; z-index: 1; font: italic 400 0.8125rem/1.2 var(--font-accent); }
.guide-cover.is-green { --cover: var(--green); }
.badge-free { transform: rotate(-3deg); }

/* Строки услуг и мероприятий */
.offer-list { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--ink); }
.offer { position: relative; display: grid; gap: 12px 40px; padding-block: 24px; border-bottom: 1px solid var(--line); transition: opacity var(--dur-fast) ease; }
.offer h3 { font-size: clamp(1.625rem, 4vw, 2rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.02; text-decoration: underline transparent 2px; text-underline-offset: 5px; transition: text-decoration-color var(--dur) ease; }
.offer p { margin-top: 8px; color: var(--ink-2); }
.offer-price { margin: 0; font: 800 1.75rem/1.05 var(--font-display); letter-spacing: -0.03em; white-space: nowrap; }
.offer-price small { display: block; margin-top: 6px; font: 400 0.875rem/1.3 var(--font-text); letter-spacing: 0; color: var(--ink-2); white-space: normal; }

/* Страница продукта */
.product-hero-inner { display: grid; gap: 32px; padding-block: clamp(28px, 5vw, 56px) clamp(32px, 6vw, 64px); }
.product-hero-inner > * { min-width: 0; }
/* размер от ширины колонки: самое длинное слово («Железодефицит») помещается в строку на любом экране */
.product-hero-inner > :first-child { container-type: inline-size; }
.product-hero h1 { font-size: clamp(2.125rem, 12.4cqi, 5.75rem); line-height: 0.94; }
.product-hero .lead { margin-top: 20px; max-width: 28ch; }
.product-hero .lead + p { margin-top: 12px; max-width: 44ch; color: var(--ink-2); }
.product-hero .chips { margin-top: 24px; }
.product-hero .stats { grid-column: 1 / -1; }

/* Выпуски подкаста: длительность крупно */
.episodes { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; counter-reset: n; }
.episodes li { display: grid; align-content: start; gap: 8px; padding: 24px; border-radius: var(--radius-l); background: var(--surface); counter-increment: n; }
.episodes li::before { content: "Выпуск " counter(n); font: 600 0.875rem/1.2 var(--font-text); color: var(--ink-3); }
.episodes b { font: 800 clamp(2.75rem, 9vw, 4rem)/0.9 var(--font-display); letter-spacing: -0.04em; color: var(--beet); white-space: nowrap; }
.episodes b small { font-size: 0.42em; letter-spacing: -0.02em; }
.episodes h3 { margin-top: 8px; }
.episodes p { font-size: 0.9375rem; color: var(--ink-2); }

/* Цена */
.price { font: 800 2.75rem/0.95 var(--font-display); letter-spacing: -0.04em; white-space: nowrap; }
.price small { display: block; margin-top: 10px; font: 500 0.9375rem/1.3 var(--font-text); letter-spacing: 0; color: var(--ink-2); }
.buy-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.wrap > .buy-strip { margin-top: 0; }
.buy-strip { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; align-items: center; margin-top: 32px; padding: 24px; border-radius: var(--radius-l); }
.buy-strip h3 { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.03em; }
.buy-strip h3 + p { margin-top: 4px; font-size: 0.9375rem; color: var(--ink-2); }
.buy-strip .price { font-size: 2.25rem; }
.price-box > * { margin: 0; } /* отступы даёт gap, общий p + p здесь лишний */
.price-box { display: grid; gap: 20px; padding: 24px; border-radius: var(--radius-l); background: var(--surface); container-type: inline-size; }
.product-hero .price-box .price { font-size: clamp(2.5rem, 17cqi, 4.75rem); }
.price-box.is-tinted { padding: clamp(24px, 6vw, 56px); }
.price-box.is-tinted .price { font-size: clamp(2.75rem, 18cqi, 6.5rem); }
.price-box h2 { font-size: clamp(2rem, 9cqi, 3.25rem); }
.price-label { font-size: 0.9375rem; font-weight: 600; }
.price-includes { margin: 0; padding: 0; list-style: none; font-weight: 500; }
.price-includes li { padding-block: 10px; border-top: 1px solid var(--line); }
.price-includes li:last-child { border-bottom: 1px solid var(--line); }
.price-note { font-size: 0.875rem; line-height: 1.5; color: var(--ink-2); }
.guide-soon { padding: 16px 20px; border: 1px dashed color-mix(in srgb, var(--ink) 30%, transparent); border-radius: var(--radius-m); background: var(--soft); color: var(--ink-2); font-size: 0.9375rem; line-height: 1.4; text-align: center; } /* гайд ещё не загружен */

/* Закреплённая кнопка покупки на телефоне (создаёт app.js; прячется, пока видна обычная кнопка или подвал) */
.buy-bar {
  position: fixed; inset: auto 0 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px var(--pad) calc(10px + env(safe-area-inset-bottom));
  box-shadow: 0 -8px 24px rgba(42, 16, 39, 0.18);
  transform: translateY(110%); visibility: hidden;
  transition: transform 200ms var(--ease-out), visibility 0s 200ms;
}
.buy-bar.is-on { transform: none; visibility: visible; transition: transform 380ms var(--ease-drawer); }
.buy-bar p { display: grid; min-width: 0; font: 800 1.25rem/1.1 var(--font-display); letter-spacing: -0.03em; white-space: nowrap; }
.buy-bar p span { overflow: hidden; font: 500 0.8125rem/1.3 var(--font-text); letter-spacing: 0; color: var(--ink-2); text-overflow: ellipsis; }
.buy-bar .btn { flex: none; min-height: 48px; padding: 11px 24px; }

/* Что внутри */
.inside-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.inside-list li { padding: 20px 24px; border-radius: var(--radius-m); background: var(--surface); }
.inside-list h3, .numbered h3 { font-size: 1.25rem; }
.inside-list p, .numbered p { margin-top: 6px; color: var(--ink-2); }
.numbered p:not(.numbered-meta) + p { margin-top: 8px; }
.numbered { margin: 0; padding: 0; list-style: none; counter-reset: n; border-top: 2px solid var(--ink); }
.numbered li { position: relative; padding: 24px 0 24px 72px; border-bottom: 1px solid var(--line); counter-increment: n; }
.numbered li::before { content: counter(n); position: absolute; left: 0; top: 14px; font: 800 3.25rem/1 var(--font-display); letter-spacing: -0.04em; color: var(--stat); }
.numbered-meta { display: inline-block; margin-top: 8px; padding: 4px 12px; border-radius: var(--radius-pill); background: var(--lime); color: var(--lime-ink); font-size: 0.875rem; font-weight: 600; }
.numbered p.numbered-meta { color: var(--lime-ink); }

/* Оговорки */
.caution { padding: 24px; border-radius: var(--radius-m); background: var(--caution-bg); }
.caution h3 { margin-bottom: 8px; font-size: 1.125rem; }
.footnote { margin-top: 20px; font-size: 0.875rem; line-height: 1.5; color: var(--ink-2); }

/* после компонентов, чтобы перебивал их margin */
.gap-top { margin-top: 32px; }

/* Телефон */
@media (max-width: 719.98px) {
  .site-header { position: sticky; top: 0; z-index: 4; padding-block: max(2px, env(safe-area-inset-top)) 0; }

  .product-hero-inner { padding-top: 24px; }
  .product-kind { margin-bottom: 14px; }
  .product-hero .lead { margin-top: 14px; }
  .product-hero .price-box { gap: 14px; padding: 20px; }

  /* «Быстро к теме»: одна строка с прокруткой от края до края; обрезанная пилюля показывает, что ряд продолжается */
  .topics { display: block; min-width: 0; }
  .topics p { margin-bottom: 8px; }
  .topics .chips, .episodes { overflow-x: auto; margin-inline: calc(-1 * var(--pad)); padding-inline: var(--pad); scroll-padding-inline: var(--pad); scrollbar-width: none; overscroll-behavior-x: contain; }
  .topics .chips::-webkit-scrollbar, .episodes::-webkit-scrollbar { display: none; }
  .topics .chips { flex-wrap: nowrap; }
  .topics .chips li { flex: none; }
  /* выпуски подкаста листаются вбок, следующая карточка выглядывает */
  .episodes { grid-auto-flow: column; grid-auto-columns: min(84%, 320px); scroll-snap-type: x mandatory; }
  .episodes li { scroll-snap-align: start; }
}
@media (max-width: 899.98px) {
  /* Продукт в одну колонку: цена и кнопка встают сразу под заголовком и строкой пользы, подробности и пилюли ниже.
     Так покупка видна в первом экране встроенного браузера. Обёртка текста растворяется, поэтому контейнер для cqi переезжает выше */
  .product-hero-inner { gap: 0; container-type: inline-size; }
  .product-hero-inner > :first-child { display: contents; }
  .product-hero-inner > :first-child > * { min-width: 0; }
  .product-hero .price-box { order: 1; margin-top: 24px; }
  .product-hero .lead + p, .product-hero .chips { order: 2; margin-top: 24px; }
  .product-hero .lead + p + .chips { margin-top: 20px; }
  .product-hero .stats { order: 3; margin-top: 32px; }
}
@media (max-width: 559.98px) {
  /* обложка гайда уменьшается и встаёт справа от названия: рядом с ней не остаётся пустого места */
  .guide-card { grid-template-columns: 1fr auto; gap: 14px 16px; align-items: center; }
  .guide-card > div:not(.guide-cover) { display: contents; }
  .guide-card h3 { grid-area: 1 / 1; font-size: clamp(1.375rem, 6.4vw, 1.625rem); }
  .guide-card p, .guide-card .more { grid-column: 1 / -1; }
  .guide-card .more { justify-self: start; }
  .guide-cover { grid-area: 1 / 2; width: 104px; gap: 6px; margin: 0 8px 6px 0; padding: 10px 8px 9px 15px; border-radius: 3px 9px 9px 3px; box-shadow: 5px 5px 0 color-mix(in srgb, var(--cover, var(--plum)) 22%, transparent); }
  .guide-cover::before { left: 6px; }
  .guide-cover b { font-size: 0.72rem; }
  .guide-cover small { font-size: 0.5625rem; }
}

/* Десктоп */
@media (min-width: 560px) {
  .guide-card { grid-template-columns: auto 1fr; align-items: stretch; }
  .stats { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
}
@media (min-width: 720px) {
  .site-header { padding-block: 14px; }
  .site-nav a { padding-block: 12px; }
  .site-nav { order: 0; width: auto; gap: 32px; }
  .site-account { order: 0; }
  .site-footer .wrap { grid-template-columns: 1fr auto; align-items: end; }
  .offer { grid-template-columns: 1fr auto; align-items: center; }
  .offer-price { min-width: 11rem; text-align: right; }
  .buy-strip { padding: 24px 32px; }
  .episodes { grid-template-columns: repeat(3, 1fr); }
  .buy-bar { display: none; }
}
@media (min-width: 900px) {
  .hero-inner { grid-template-columns: 1.25fr 0.75fr; }
  .hero-visual { width: 100%; }
  .topics { grid-column: 1 / -1; }
  .course-grid { grid-template-columns: repeat(3, 1fr); }
  .course-card { min-height: 440px; padding: 28px; }
  .course-card.is-wide { grid-column: 1 / -1; min-height: 0; flex-direction: row; align-items: flex-end; justify-content: space-between; gap: 48px; }
  .course-card.is-wide::before { right: 18%; top: -90%; width: 34%; }
  .course-card.is-wide h3 { font-size: 3.5rem; }
  .course-card.is-wide .course-card-foot { flex: none; flex-direction: column; align-items: flex-end; align-self: auto; margin-top: 0; padding-top: 0; }
  .course-card.is-wide .price-inline { font-size: 2.75rem; }
  .guide-grid { grid-template-columns: 1fr 1fr; }
  .guide-card { padding: 32px; }
  .split { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .split h2 { font-size: clamp(1.875rem, 3.5vw, 2.75rem); }
  .wrap:not(.split) > .section-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 16px 48px; align-items: end; }
  .wrap:not(.split) > .section-head > .sticker { grid-column: 1 / -1; margin-bottom: 0; }
  .wrap:not(.split) > .section-head p { margin-top: 0; }
  .product-hero-inner { grid-template-columns: 1.2fr 0.8fr; align-items: end; gap: 40px 48px; }
}

/* Наведение: только там, где есть мышь */
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover, .course-card:hover .more, .guide-card:hover .more { background: color-mix(in srgb, var(--btn) 86%, var(--btn-ink)); }
  .btn-ghost:hover, .chips a:hover, .site-account:hover { background: color-mix(in srgb, var(--ink) 14%, transparent); border-color: var(--ink); }
  .site-nav a:hover, .footer-links a:hover { color: var(--ink); }
  .text-link:hover { text-decoration-color: currentColor; }
  .offer:has(a):hover h3 { text-decoration-color: currentColor; }
  .course-card:hover { transform: translateY(-4px); }
}

/* Нажатие: отклик сразу под пальцем, на телефоне он вместо наведения. После блока наведения, чтобы перебивать его */
.btn:active, .chips a:active, .site-account:active { transform: scale(0.97); }
.btn-primary:active, .course-card:active .more, .guide-card:active .more { background: color-mix(in srgb, var(--btn) 78%, var(--btn-ink)); }
.btn-ghost:active, .chips a:active, .site-account:active { background: color-mix(in srgb, var(--ink) 22%, transparent); }
.course-card:active, .guide-card:active { transform: scale(0.98); transition-duration: var(--dur-fast); }
.offer:has(a):active { opacity: 0.6; }
.site-nav a:active, .footer-links a:active { color: var(--ink); }

/* Появление при прокрутке: класс ставит app.js только блокам ниже экрана, без скрипта всё видно сразу */
.rv { opacity: 0; }
@media print { .rv { opacity: 1; } }

@media (prefers-reduced-motion: no-preference) {
  /* смена страниц: мягкое проявление там, где браузер умеет */
  @view-transition { navigation: auto; }
  ::view-transition-group(root) { animation-duration: 200ms; }

  /* Первый экран: один раз при загрузке, последняя задержка 180 мс. translate и scale не трогают наклон ярлыков */
  @keyframes rise { from { opacity: 0; translate: 0 12px; } }
  @keyframes pop { from { opacity: 0; scale: 0.9; } }
  .hero-copy > *, .hero-portrait, .product-hero-inner > :first-child > *, .product-hero .price-box, .product-hero .stats, .page-head > * { animation: rise 500ms var(--ease-out) backwards; }
  :is(.hero-copy, .product-hero-inner > :first-child, .page-head) > :nth-child(2) { animation-delay: 50ms; }
  :is(.hero-copy, .product-hero-inner > :first-child, .page-head) > :nth-child(n+3) { animation-delay: 100ms; }
  .hero-portrait, .product-hero .price-box { animation-delay: 120ms; }
  .product-hero .stats { animation-delay: 180ms; }
  .hero-portrait::before { animation: pop 600ms var(--ease-out) 120ms backwards; }
  .hero-visual .sticker { animation: pop 300ms var(--ease-out) 260ms backwards; }
  .hero-visual a.sticker { animation-delay: 320ms; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:active, .chips a:active, .site-account:active, .course-card:active, .guide-card:active, .course-card:hover { transform: none; }
  .course-card, .guide-card, .buy-bar, .buy-bar.is-on, .site-header { transition: none; }
}
