/* ============================================================
   TRICHODE — дизайн-система
   Палитра снята с рекламных креативов: холодный серый фон, бордо
   и один холодный акцент. Настроение — аптека и протокол, не спа.
   Меняешь переменную — меняется весь сайт.
   ============================================================ */

/* ---------- Шрифты ----------
   Локальные woff2 с посубсетной разбивкой. unicode-range нужен, чтобы
   браузер тянул кириллический файл только когда на странице есть кириллица,
   и не грузил латинский набор ради одного «Copper Tripeptide-1». */
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-cyrillic-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2122, U+2191, U+2193, U+2212;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-cyrillic-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2122, U+2191, U+2193, U+2212;
}
@font-face {
  font-family: 'Inter Tight';
  src: url('../fonts/inter-tight-cyrillic-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter Tight';
  src: url('../fonts/inter-tight-latin-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2122, U+2191, U+2193, U+2212;
}
@font-face {
  font-family: 'Inter Tight';
  src: url('../fonts/inter-tight-cyrillic-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Inter Tight';
  src: url('../fonts/inter-tight-latin-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2122, U+2191, U+2193, U+2212;
}

/* ---------- Токены ---------- */
:root {
  /* Палитра снята с упаковки: воздушный голубой, белый, красный акцент. */
  --bg:            #E9F2F9;
  --bg-soft:       #FFFFFF;
  --surface:       #FFFFFF;
  --ink:           #17293A;   /* основной текст */
  --ink-2:         #8C1622;   /* тёмный акцент, фон акцентных секций */
  --muted:         #47596B;   /* приглушённый текст, проверен на AA */
  --accent:        #CE2B33;   /* главный акцент и кнопки */
  --accent-soft:   #5B8FB8;   /* голубой деталей */
  --line:          #CBDCE8;
  --line-soft:     #DFEAF2;
  --on-dark:       #FFFFFF;
  --on-dark-muted: #E7D2D5;
  --danger:        #B01F27;

  /* Поп-ап удержания приносит свою разметку и свои стили из js/core.js, а
     цвета берёт отсюда. Без --panel окно осталось бы на запасном тёмном фоне
     ядра, а текст в нём — нашим тёмно-синим --ink: читать было бы нечего. */
  --panel:      var(--surface);   /* полотно окна */
  --bg-3:       var(--surface);   /* поля ввода в окне */
  --accent-ink: var(--on-dark);   /* подпись на красной кнопке */
  --radius-sm:  var(--radius);
  --good:       var(--ink);       /* «принято»: своего зелёного у сайта нет */
  --bad:        var(--danger);

  --font:      'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-head: 'Inter Tight', 'Inter', system-ui, sans-serif;

  --wrap: 1200px;
  --gut: 20px;
  --u: 8px;                    /* вертикальный ритм, всё кратно ему */
  --radius: 4px;
  --radius-lg: 8px;

  --step-0: 1.0625rem;         /* 17px — базовый кегль на мобильном */
  --step-1: 1.25rem;
  --step-2: 1.5rem;
  --step-3: 1.9rem;
  --step-4: 2.4rem;

  --shadow: 0 1px 2px rgba(95, 11, 20, .06), 0 12px 32px rgba(95, 11, 20, .10);
  --focus: 0 0 0 3px rgba(95, 11, 20, .30);
}

@media (min-width: 768px) {
  :root { --step-0: 1.125rem; --step-3: 2.3rem; --step-4: 3.2rem; --gut: 32px; }
}
@media (min-width: 1200px) {
  :root { --step-4: 3.9rem; }
}

/* ---------- База ---------- */
/* Атрибут hidden сильнее любого display из компонента: без этого правила
   .booked с display:inline-flex продолжает показывать блок, который скрыт. */
[hidden] { display: none !important; }

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

img, picture, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: none;
  box-shadow: var(--focus);
  border-radius: var(--radius);
}

/* Плотнее, чем у соседнего проекта: интерлиньяж заголовков ужат,
   апрош отрицательный. Строка должна читаться как строка инструкции. */
h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.05;
  margin: 0 0 calc(var(--u) * 2);
  letter-spacing: -.015em;
}
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); font-weight: 600; letter-spacing: -.01em; }
p  { margin: 0 0 calc(var(--u) * 2); }
p:last-child { margin-bottom: 0; }

/* Цифры всегда моноширинные: цена, объём, дозировка — это таблица,
   а не текст, и прыгающая ширина знака её разваливает. */
.card__price, .tier__price, .saving__row, .card__vol, .quiz__count {
  font-variant-numeric: tabular-nums;
}

/* Прописные с разрежением — фирменный приём линейки.
   Трекинг обязателен: у Inter Tight в капитель заложен плотный апрош,
   без разрежения прописные слипаются в полосу. */
.eyebrow {
  font-family: var(--font-head);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 calc(var(--u) * 2);
}
.lead { font-size: var(--step-1); line-height: 1.45; color: var(--ink-2); }
.muted { color: var(--muted); }
.small { font-size: .9375rem; }
.tiny  { font-size: .875rem; line-height: 1.5; }
.nowrap { white-space: nowrap; }

/* ---------- Раскладка ---------- */
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }

.section { padding-block: calc(var(--u) * 6); }
@media (min-width: 768px) { .section { padding-block: calc(var(--u) * 11); } }
.section--soft { background: var(--bg-soft); }
.section--ink  { background: var(--ink-2); color: var(--on-dark); }
.section--ink .eyebrow, .section--ink .muted { color: var(--on-dark-muted); }
.section--ink .lead { color: var(--on-dark); }

.section__head { max-width: 42rem; margin-bottom: calc(var(--u) * 5); }
.section__head--wide { max-width: 56rem; }

.grid { display: grid; gap: calc(var(--u) * 3); }
@media (min-width: 768px)  { .grid--2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px)  { .grid--3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .grid--4 { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Кнопки ---------- */
.btn {
  --btn-bg: var(--accent);
  --btn-fg: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px;
  padding: 14px 30px;
  background: var(--btn-bg); color: var(--btn-fg);
  font-family: var(--font-head); font-weight: 600; font-size: 1.0625rem;
  text-decoration: none; text-align: center;
  border: 1px solid var(--btn-bg); border-radius: var(--radius);
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease, transform .12s ease;
}
.btn:hover { --btn-bg: var(--ink-2); }
.btn:active { transform: translateY(1px); }
.btn--ghost { --btn-bg: transparent; --btn-fg: var(--accent); border-color: var(--accent); }
.btn--ghost:hover { --btn-bg: rgba(206,43,51,.08); --btn-fg: var(--ink); border-color: var(--ink); }
.btn--light { --btn-bg: #fff; --btn-fg: var(--ink); border-color: #fff; }
.btn--light:hover { --btn-bg: var(--accent-soft); --btn-fg: var(--ink); border-color: var(--accent-soft); }
.btn--wide { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Шапка ---------- */
.header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header__in { display: flex; align-items: center; justify-content: space-between; gap: var(--u); min-height: 64px; }
.logo {
  flex: none;
  font-family: var(--font-head); font-weight: 700; font-size: 1.1rem;
  letter-spacing: .16em; text-transform: uppercase; text-decoration: none;
}
.logo b { font-weight: 700; color: var(--ink-2); }

/* Навигация видна на всех ширинах. На узком экране это горизонтальная
   лента: ссылки не исчезают при прокрутке страницы, а сама лента прокручивается
   внутри себя и не растягивает страницу по ширине. */
.header__nav {
  display: flex; flex: 1 1 auto; min-width: 0;
  gap: calc(var(--u) * 2);
  overflow-x: auto; overscroll-behavior-x: contain;
  scrollbar-width: none; -ms-overflow-style: none;
  padding-block: 4px;
}
.header__nav::-webkit-scrollbar { display: none; }
.header__nav a { font-size: .875rem; text-decoration: none; color: var(--muted); white-space: nowrap; }
.header__nav a:hover { color: var(--ink); }
/* Срез у правого края показывает, что лента прокручивается дальше */
@media (max-width: 899px) {
  .header__nav {
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent 100%);
    mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent 100%);
  }
}
@media (min-width: 900px) {
  .header__nav { flex: 0 1 auto; gap: calc(var(--u) * 3); overflow: visible; }
  .header__nav a { font-size: .95rem; }
}
.header__cta { display: none; }
@media (min-width: 700px) { .header__cta { flex: none; display: inline-flex; min-height: 44px; padding: 8px 18px; font-size: .95rem; } }

/* Строка про оплату рядом с кнопкой в шапке. Порог совпадает с кнопкой:
   иначе на промежуточных ширинах кнопка брони есть, а строки рядом нет. */
.header__pay { display: none; font-size: .8125rem; color: var(--muted); white-space: nowrap; }
@media (min-width: 700px) { .header__pay { display: inline; } }

/* ---------- Первый экран ----------
   На узком экране первый экран считается по нижней кромке второй кнопки:
   строка-факт, цена и обе кнопки обязаны попадать в 390×844 вместе с
   адресной строкой браузера. Поэтому здесь всё плотнее, чем в остальных
   секциях, а заголовок и подзаголовок на мобильном мельче. */
.hero { position: relative; padding-block: calc(var(--u) * 3) calc(var(--u) * 6); }
@media (min-width: 900px) { .hero { padding-block: calc(var(--u) * 9) calc(var(--u) * 11); } }
.hero__grid { display: grid; gap: calc(var(--u) * 4); align-items: center; }
@media (min-width: 900px) { .hero__grid { grid-template-columns: 1.05fr .95fr; gap: calc(var(--u) * 6); } }
.hero h1 { max-width: 17ch; font-size: clamp(1.85rem, 8.2vw, 2.4rem); margin-bottom: calc(var(--u) * 1.5); }
@media (min-width: 768px) { .hero h1 { font-size: var(--step-4); margin-bottom: calc(var(--u) * 2); } }
.hero__sub { font-size: 1.0625rem; line-height: 1.4; color: var(--ink-2); max-width: 34rem; margin-bottom: calc(var(--u) * 2); }
@media (min-width: 768px) { .hero__sub { font-size: var(--step-1); line-height: 1.45; margin-bottom: calc(var(--u) * 4); } }
.hero__actions { display: flex; flex-direction: column; gap: var(--u); align-items: stretch; }
@media (min-width: 560px) { .hero__actions { flex-direction: row; align-items: center; } }
.hero__actions .btn { min-height: 52px; }
@media (min-width: 768px) { .hero__actions .btn { min-height: 56px; } }
.hero__note { font-size: .875rem; color: var(--muted); margin-top: var(--u); }
@media (min-width: 768px) { .hero__note { font-size: .9375rem; margin-top: calc(var(--u) * 2); } }
.hero__media img { width: 100%; border-radius: var(--radius-lg); }

/* Строка-факт первого экрана. Сравнение живёт в секции #compare, а на узком
   экране ссылка на неё в шапке скрыта — поэтому вход в разбор стоит прямо
   здесь. Кегль 14px: на 390px строка укладывается в две строки и не сдвигает
   цену с кнопками за нижнюю кромку экрана. */
.hero__fact {
  max-width: 34rem;
  margin-bottom: calc(var(--u) * 2);
  padding: 10px 12px;
  background: var(--surface);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: .875rem; line-height: 1.45; color: var(--ink-2);
}
.hero__fact b { font-weight: 500; color: var(--ink); }
.hero__fact a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
@media (min-width: 768px) { .hero__fact { padding: 12px 16px; font-size: .9375rem; } }

/* ---------- Карточки ---------- */
.card {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.card__media { background: #fff; }
.card__media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.card__body { display: flex; flex-direction: column; flex: 1; padding: calc(var(--u) * 3); }
.card__step {
  font-family: var(--font-head); font-size: .75rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase; color: var(--ink-2);
  margin-bottom: var(--u);
}
.card__vol { font-size: .9375rem; color: var(--muted); margin-bottom: calc(var(--u) * 2); }
.card__list { list-style: none; margin: 0 0 calc(var(--u) * 3); padding: 0; display: grid; gap: var(--u); }
.card__list li { font-size: .9375rem; padding-left: 18px; position: relative; line-height: 1.45; }
.card__list li::before {
  content: ''; position: absolute; left: 0; top: .58em;
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
}
.card__list b { font-weight: 600; }
/* Первый уровень карточки — не длиннее короткого абзаца: шаг, название,
   объём, одна строка сути и цена. Всё остальное живёт под кнопкой «Подробнее». */
.card__lead { font-size: .9375rem; line-height: 1.5; color: var(--ink-2); margin-bottom: calc(var(--u) * 2); }
.card__more { margin-bottom: calc(var(--u) * 2); border-top: 1px solid var(--line-soft); }
.card__more summary {
  cursor: pointer; list-style: none; padding: calc(var(--u) * 1.5) 0;
  font-size: .9375rem; font-weight: 500;
  display: flex; justify-content: space-between; align-items: center; gap: var(--u);
}
.card__more summary::-webkit-details-marker { display: none; }
.card__more summary::after { content: '+'; font-size: 1.2rem; line-height: 1; color: var(--muted); }
.card__more[open] summary::after { content: '−'; }
.card__more-body { padding-bottom: calc(var(--u) * 2); }
.card__more-body .card__list { margin-bottom: calc(var(--u) * 2); }

.card__foot { margin-top: auto; padding-top: calc(var(--u) * 2); border-top: 1px solid var(--line-soft); }
.card__price { font-family: var(--font-head); font-size: var(--step-2); font-weight: 700; line-height: 1.1; }
.card__price span { font-family: var(--font); font-size: .875rem; font-weight: 400; color: var(--muted); }

/* Раскрывающийся состав */
.inci { margin-top: calc(var(--u) * 2); border-top: 1px solid var(--line-soft); }
.inci summary {
  cursor: pointer; list-style: none; padding: calc(var(--u) * 1.5) 0;
  font-size: .9375rem; font-weight: 500; display: flex; justify-content: space-between; align-items: center; gap: var(--u);
}
.inci summary::-webkit-details-marker { display: none; }
.inci summary::after { content: '+'; font-size: 1.2rem; line-height: 1; color: var(--muted); }
.inci[open] summary::after { content: '−'; }
.inci__body { padding-bottom: calc(var(--u) * 2); font-size: .8125rem; line-height: 1.55; color: var(--muted); }

/* ---------- Шаги протокола ---------- */
.steps { counter-reset: step; display: grid; gap: calc(var(--u) * 3); }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step {
  counter-increment: step;
  padding: calc(var(--u) * 3);
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius-lg);
}
.section--ink .step { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.16); }
.step::before {
  content: counter(step);
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; margin-bottom: calc(var(--u) * 2);
  font-family: var(--font-head); font-weight: 700; font-size: .95rem;
  background: var(--ink); color: #fff; border-radius: 50%;
}
.section--ink .step::before { background: #fff; color: var(--ink-2); }

/* Кадр над блоком «почему втроём»: композиция из трёх упаковок.
   Отдельный класс нужен, потому что пропорция здесь горизонтальная,
   а не 4:5, как в карточках товара. */
.steps__media {
  margin-bottom: calc(var(--u) * 4);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.steps__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

/* ---------- Тарифы ---------- */
.tiers { display: grid; gap: calc(var(--u) * 3); align-items: start; }
@media (min-width: 900px) { .tiers { grid-template-columns: repeat(3, 1fr); } }
.tier {
  position: relative; display: flex; flex-direction: column;
  padding: calc(var(--u) * 3);
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius-lg);
}
.tier--best { border: 2px solid var(--accent); box-shadow: var(--shadow); }
@media (min-width: 900px) { .tier--best { margin-block: calc(var(--u) * -2); padding-block: calc(var(--u) * 5); } }
.tier__badge {
  position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%);
  padding: 5px 14px; white-space: nowrap;
  background: var(--ink); color: #fff; border-radius: 999px;
  font-family: var(--font-head); font-size: .72rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
}
.tier__name { font-family: var(--font-head); font-size: var(--step-1); font-weight: 700; margin-bottom: var(--u); }
/* Цена — самый крупный знак в блоке: тест меряет готовность к цене,
   и прятать её в общий кегль незачем. */
.tier__price { font-family: var(--font-head); font-size: var(--step-4); font-weight: 700; line-height: .95; margin-bottom: calc(var(--u) * 1.5); letter-spacing: -.02em; }
.tier__unit { font-size: .9375rem; color: var(--muted); margin-bottom: calc(var(--u) * 2); }
.tier__list { list-style: none; margin: 0 0 calc(var(--u) * 3); padding: 0; display: grid; gap: var(--u); font-size: .9375rem; }
.tier__list li { padding-left: 20px; position: relative; line-height: 1.45; }
.tier__list li::before {
  content: ''; position: absolute; left: 2px; top: .42em;
  width: 9px; height: 5px; border-left: 2px solid var(--ink-2); border-bottom: 2px solid var(--ink-2);
  transform: rotate(-45deg);
}
.tier__list li.is-off { color: var(--muted); }
.tier__list li.is-off::before { border-color: var(--muted); transform: none; border-left: 0; width: 9px; height: 0; top: .8em; }
.tier__cta { margin-top: auto; }

/* Выгода комплекта: сравнение внутри ассортимента, а не скидка с прошлой цены */
.saving {
  margin-top: calc(var(--u) * 4);
  padding: calc(var(--u) * 3);
  background: var(--ink); color: var(--on-dark); border-radius: var(--radius-lg);
}
.saving__row { font-family: var(--font-head); font-size: var(--step-2); font-weight: 700; line-height: 1.2; }
.saving__note { margin-top: var(--u); color: var(--on-dark-muted); font-size: .9375rem; }

/* ---------- Процесс ---------- */
.flow { display: grid; gap: calc(var(--u) * 3); counter-reset: flow; }
@media (min-width: 1000px) { .flow { grid-template-columns: repeat(4, 1fr); } }
.flow__item { counter-increment: flow; padding-top: calc(var(--u) * 2); border-top: 2px solid var(--ink); }
.flow__item::before {
  content: counter(flow) ' / 4';
  display: block; margin-bottom: var(--u);
  font-family: var(--font-head); font-size: .78rem; font-weight: 600;
  letter-spacing: .16em; color: var(--muted);
}

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 0; max-width: 52rem; }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: flex-start; gap: calc(var(--u) * 2);
  padding: calc(var(--u) * 2.5) 0;
  font-family: var(--font-head); font-size: var(--step-1); font-weight: 600; line-height: 1.25;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: ''; flex: 0 0 auto; margin-top: .45em;
  width: 12px; height: 12px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(45deg); transition: transform .18s ease;
}
.faq__item[open] summary::after { transform: rotate(-135deg); }
.faq__body { padding-bottom: calc(var(--u) * 3); max-width: 46rem; color: var(--ink-2); }

/* ---------- Формы ---------- */
.form { display: grid; gap: calc(var(--u) * 2); max-width: 34rem; }
.field { display: grid; gap: 6px; }
.field label { font-size: .9375rem; font-weight: 500; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
}
.field input:focus, .field select:focus { border-color: var(--ink); }
/* Ошибка на бордовом сайте не читается одним цветом: весь интерфейс и так
   красный. Поэтому к цвету добавлены двойная рамка и полужирная подпись.

   Негодное поле ядро помечает aria-invalid, класса .field--error оно не
   ставит и ставить не будет: у шести сайтов он называется по-разному. Прежнее
   правило остаётся рядом, пока у части посетителей в кэше живёт прежний
   js/app.js, — он вешает класс, а атрибута не знает. */
.field--error input,
.field input[aria-invalid="true"],
.field select[aria-invalid="true"] { border-color: var(--danger); border-width: 2px; }
/* Отметка согласия — не в .field, рамке взяться неоткуда: обводим саму
   клетку, иначе на отказ «без согласия» человек видит только строку внизу. */
.check input[aria-invalid="true"] { outline: 2px solid var(--danger); outline-offset: 2px; }
.field__err { font-size: .8125rem; font-weight: 500; color: var(--danger); min-height: 1em; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.check { display: flex; gap: 12px; align-items: flex-start; font-size: .875rem; line-height: 1.5; color: var(--ink-2); }
.check input { flex: 0 0 auto; width: 20px; height: 20px; min-height: 0; margin-top: 2px; accent-color: var(--ink); }
.check a { color: inherit; }

/* Блок ответа виден всегда: ядро только пишет в него текст и вешает is-ok
   или is-err. Спрятанный по классу узел означал бы, что на отказ человек
   видит пустоту и жмёт кнопку ещё раз. */
.form__status { font-size: .9375rem; min-height: 1.5em; }
.form__status.is-err { color: var(--danger); font-weight: 500; }
.form__status.is-ok { color: var(--ink); font-weight: 500; }

/* ---------- Квиз ---------- */
.quiz-teaser {
  display: grid; gap: calc(var(--u) * 3); align-items: center;
  padding: calc(var(--u) * 4);
  background: var(--ink); color: var(--on-dark); border-radius: var(--radius-lg);
}
@media (min-width: 900px) { .quiz-teaser { grid-template-columns: 1.4fr .6fr; padding: calc(var(--u) * 6); } }
.quiz-teaser h2 { color: #fff; }

.quiz {
  position: fixed; inset: 0; z-index: 90;
  display: none; flex-direction: column;
  background: var(--bg);
}
.quiz.is-open { display: flex; }
body.is-locked { overflow: hidden; }

.quiz__bar { flex: 0 0 auto; border-bottom: 1px solid var(--line); background: var(--bg); }
.quiz__bar-in { display: flex; align-items: center; gap: calc(var(--u) * 2); min-height: 60px; }
.quiz__progress { flex: 1; height: 4px; background: var(--line); border-radius: 999px; overflow: hidden; }
.quiz__progress i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .28s ease; }
.quiz__count { font-family: var(--font-head); font-size: .875rem; font-weight: 600; color: var(--muted); white-space: nowrap; }
.quiz__close {
  flex: 0 0 auto; width: 40px; height: 40px; padding: 0;
  background: none; border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer;
  font-size: 1.1rem; line-height: 1;
}
.quiz__body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding-block: calc(var(--u) * 4) calc(var(--u) * 8); }
.quiz__q { max-width: 44rem; margin-inline: auto; }
.quiz__q h2 { font-size: var(--step-3); margin-bottom: calc(var(--u) * 4); }
.quiz__opts { display: grid; gap: calc(var(--u) * 1.5); }
.quiz__opt {
  display: flex; align-items: center; gap: calc(var(--u) * 2);
  width: 100%; min-height: 68px; padding: 16px 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  font-size: var(--step-0); text-align: left; cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.quiz__opt:hover { border-color: var(--ink); }
.quiz__opt.is-on { border-color: var(--ink); border-width: 2px; background: #fff; }
.quiz__opt i {
  flex: 0 0 auto; width: 22px; height: 22px; border: 1px solid var(--line); border-radius: 50%;
}
.quiz__opt.is-on i { border: 6px solid var(--ink); }
.quiz__back {
  margin-top: calc(var(--u) * 4); background: none; border: 0; padding: 8px 0; cursor: pointer;
  font-size: .9375rem; color: var(--muted); text-decoration: underline; text-underline-offset: 3px;
}

/* ---------- Результат ---------- */
.result__sum {
  padding: calc(var(--u) * 3);
  background: var(--ink); color: var(--on-dark);
  border-radius: var(--radius-lg);
  font-family: var(--font-head); font-size: var(--step-2); font-weight: 600; line-height: 1.25;
}
.result__sum b { color: var(--accent); font-weight: 600; }

/* ---------- Липкая кнопка на мобильном ---------- */
.sticky {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  padding: 10px var(--gut) calc(10px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  transform: translateY(110%); transition: transform .22s ease;
}
.sticky.is-on { transform: translateY(0); }
.sticky .btn { min-height: 52px; padding-inline: 16px; }
.sticky .pay-note { justify-content: center; margin-top: 6px; font-size: .8125rem; }
@media (min-width: 900px) { .sticky { display: none; } }
/* Пока панель видна, добавляем отступ снизу, иначе она накрывает подвал и форму.
   Высота полосы измерена в браузере: 101,5px на 320, 360, 390, 414 и 768px —
   рамка 1 + отступ 10 + кнопка 56,3 + 6 + строка «Оплата сейчас не требуется»
   18,2 + отступ 10. Отступ 132px оставляет запас в 30px; безопасная зона
   iPhone добавляется поверх. */
body.has-sticky { padding-bottom: calc(var(--sticky-h, 132px) + var(--cookie-h, 0px) + env(safe-area-inset-bottom)); }
@media (min-width: 900px) { body.has-sticky { padding-bottom: 0; } }

/* ---------- Подвал ---------- */
.footer { background: var(--ink); color: var(--on-dark); padding-block: calc(var(--u) * 6); }
.footer a { color: var(--on-dark); text-underline-offset: 3px; }
.footer__grid { display: grid; gap: calc(var(--u) * 4); }
@media (min-width: 800px) { .footer__grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.footer__links { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--u); font-size: .9375rem; }
.footer__legal { margin-top: calc(var(--u) * 5); padding-top: calc(var(--u) * 3); border-top: 1px solid rgba(255,255,255,.18); font-size: .8125rem; color: var(--on-dark-muted); }
.footer__legal p { margin-bottom: var(--u); }

/* ---------- Cookie ---------- */
.cookie {
  position: fixed; left: var(--gut); right: var(--gut); bottom: var(--gut); z-index: 60;
  display: none; gap: calc(var(--u) * 2); align-items: center; flex-wrap: wrap;
  max-width: 46rem; padding: calc(var(--u) * 2);
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  font-size: .875rem;
}
.cookie.is-on { display: flex; }
.cookie p { margin: 0; flex: 1 1 16rem; }
.cookie .btn { min-height: 44px; padding: 8px 20px; font-size: .9375rem; }

/* ---------- Прочее ---------- */
.note {
  padding: calc(var(--u) * 2) calc(var(--u) * 2.5);
  background: var(--surface); border-left: 3px solid var(--accent); border-radius: var(--radius);
  font-size: .9375rem;
}
.legal-note { font-size: .9375rem; color: var(--muted); }

/* «Не является лекарственным средством».
   Кегль задан классом, а не инлайновым стилем, и считается от основного
   текста: требование — не мельче базового минус 2 пункта. На мобильном
   база 17px, значит здесь 15px; на десктопе база 18px, значит 16px.
   Правило класса перебивает наследование и в подвале, где текст 13px. */
.not-drug {
  font-size: calc(var(--step-0) - 2px);
  line-height: 1.45;
  font-weight: 500;
  color: var(--ink-2);
  margin: var(--u) 0 0;
}
.section--ink .not-drug,
.footer .not-drug,
.saving .not-drug { color: var(--on-dark); }
.tier .not-drug { margin-bottom: calc(var(--u) * 2); }

.deadline {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
  font-size: .9375rem;
}
.deadline::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ink-2); }

.prose { max-width: 46rem; }
.prose h2 { font-size: var(--step-2); margin-top: calc(var(--u) * 6); }
.prose h3 { margin-top: calc(var(--u) * 4); }
.prose ul, .prose ol { margin: 0 0 calc(var(--u) * 2); padding-left: 22px; display: grid; gap: 6px; }
.prose table { width: 100%; border-collapse: collapse; margin-bottom: calc(var(--u) * 3); font-size: .9375rem; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border: 1px solid var(--line); vertical-align: top; }
/* Широкая таблица прокручивается внутри себя. min-width: 0 обязателен: без него
   ячейка колонки сетки раздувается до min-content таблицы и уводит всю страницу
   в горизонтальную прокрутку на узком экране. */
.table-scroll { overflow-x: auto; min-width: 0; }
.grid > *, .anchor > * { min-width: 0; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  padding: 12px 20px; background: var(--ink); color: #fff;
}
.skip-link:focus { left: 0; }


/* ============================================================
   Продающие блоки: гарантия, дефицит, враг, доказательства
   ============================================================ */

/* Обещание бренда в первом экране: цена и кнопка обязаны быть видны
   без прокрутки, поэтому цена вынесена прямо под заголовок. */
.hero__price {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 16px;
  margin-bottom: calc(var(--u) * 2);
}
.hero__price b {
  font-family: var(--font-head); font-size: var(--step-3); font-weight: 700; line-height: 1;
}
.hero__price s { text-decoration: none; color: var(--muted); font-size: .95rem; }
.hero__price em { font-style: normal; color: var(--muted); font-size: .95rem; }

/* Гарантия — самый недооценённый рычаг на дорогом чеке у незнакомого бренда */
.promise {
  display: grid; gap: calc(var(--u) * 2);
  padding: calc(var(--u) * 4);
  border: 2px solid var(--ink); border-radius: var(--radius-lg);
  background: var(--surface);
}
@media (min-width: 800px) { .promise { grid-template-columns: auto 1fr; align-items: center; gap: calc(var(--u) * 4); } }
.promise__num {
  font-family: var(--font-head); font-size: clamp(3rem, 9vw, 5rem); font-weight: 700;
  line-height: .9; letter-spacing: -.02em;
}
.promise__num span { display: block; font-size: 1rem; letter-spacing: .16em; text-transform: uppercase; }
.promise h2 { margin-bottom: var(--u); }

/* Срок и тираж — настоящие, поэтому им место в зоне решения, а не в подвале */
.limits { display: grid; gap: calc(var(--u) * 2); }
@media (min-width: 700px) { .limits { grid-template-columns: repeat(3, 1fr); } }
.limit {
  padding: calc(var(--u) * 3);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.limit b {
  display: block; margin-bottom: 6px;
  font-family: var(--font-head); font-size: var(--step-2); font-weight: 700; line-height: 1.1;
}
.limit span { color: var(--muted); font-size: .9375rem; }

/* Противник: против него цена читается как разумная */
.enemy { display: grid; gap: calc(var(--u) * 3); }
@media (min-width: 900px) { .enemy { grid-template-columns: repeat(3, 1fr); } }
.enemy__item { padding-top: calc(var(--u) * 2); border-top: 2px solid currentColor; }
.enemy__item h3 { margin-bottom: var(--u); }

/* Сноска на исследование прямо в карточке товара */
.ref {
  display: inline-block; margin-top: var(--u);
  font-size: .8125rem; color: var(--muted);
  text-decoration: underline; text-underline-offset: 3px;
}
.study {
  padding: calc(var(--u) * 3);
  border-left: 3px solid var(--accent);
  background: var(--surface);
}
.study h3 { margin-bottom: var(--u); }
.study__meta { font-size: .875rem; color: var(--muted); margin-bottom: calc(var(--u) * 2); }
.study__design { display: grid; gap: 6px; margin: 0 0 calc(var(--u) * 2); padding: 0; list-style: none; font-size: .9375rem; }
.study__design li { padding-left: 18px; position: relative; }
.study__design li::before { content: ''; position: absolute; left: 0; top: .6em; width: 8px; height: 2px; background: var(--muted); }

/* Живое число броней. Скрыто, пока сервер не разрешит показ. */
.booked {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px;
  font-size: .9375rem;
}
.booked b { font-family: var(--font-head); }

/* Разбор цены и сравнение с альтернативой в жизни покупателя */
.anchor { display: grid; gap: calc(var(--u) * 2); }
@media (min-width: 800px) { .anchor { grid-template-columns: repeat(2, 1fr); } }
.anchor__row {
  display: flex; justify-content: space-between; align-items: baseline; gap: var(--u);
  padding: calc(var(--u) * 1.5) 0; border-bottom: 1px solid var(--line);
}
.anchor__row b { font-family: var(--font-head); white-space: nowrap; }


/* ============================================================
   Аптечность: данные таблицей, дозирование словами
   ============================================================ */

/* Таблица данных вне .prose. Аптека показывает цифры таблицей,
   а не постановочной фотографией: так быстрее сверять. */
.dtable {
  width: 100%; border-collapse: collapse;
  font-size: .9375rem; font-variant-numeric: tabular-nums;
  background: var(--surface);
}
.dtable th, .dtable td {
  text-align: left; padding: 10px 12px;
  border: 1px solid var(--line); vertical-align: top;
}
.dtable th { font-family: var(--font-head); font-weight: 600; }
.section--ink .dtable { background: rgba(255,255,255,.06); }
.section--ink .dtable th, .section--ink .dtable td { border-color: rgba(255,255,255,.2); }

/* Язык дозирования на карточке: «два нажатия утром и вечером»,
   а не «наносите по мере необходимости». */
.card__dose {
  margin-bottom: calc(var(--u) * 2);
  padding: calc(var(--u) * 1.5) calc(var(--u) * 2);
  background: #fff; border: 1px solid var(--line-soft); border-radius: var(--radius);
  font-size: .9375rem; line-height: 1.45;
}
.card__dose b {
  display: block; margin-bottom: 4px;
  font-family: var(--font-head); font-size: .72rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase; color: var(--muted);
}

/* Состав открыт прямо в карточке, а не спрятан под раскрывашку:
   открытый состав на видном месте сам по себе сигнал. */
.inci-open {
  margin-top: calc(var(--u) * 2); padding-top: calc(var(--u) * 2);
  border-top: 1px solid var(--line-soft);
  font-size: .8125rem; line-height: 1.55; color: var(--muted);
}
.inci-open b {
  display: block; margin-bottom: 6px; color: var(--ink);
  font-family: var(--font-head); font-size: .72rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
}

/* Сцены вместо прилагательных: что человек замечает и когда именно */
.scene { display: grid; gap: calc(var(--u) * 3); }
@media (min-width: 700px) { .scene { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .scene { grid-template-columns: repeat(3, 1fr); } }
.scene__item { padding-left: calc(var(--u) * 2.5); border-left: 2px solid var(--accent); }
.scene__item h3 { margin-bottom: var(--u); }

/* Разница в цене — самая сильная цифра на странице, и набрана она соответственно */
.saving__row--big { font-size: clamp(1.6rem, 5.4vw, 2.6rem); line-height: 1.1; }

/* Точка входа в заявку между блоками */
.cta-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: calc(var(--u) * 2);
  margin-top: calc(var(--u) * 4);
}
.section--ink .cta-row .small { color: var(--on-dark-muted); }
.cta-row .small { color: var(--muted); }

/* Строка рядом с кнопкой брони. Формулировка одна на весь сайт. */
.pay-note {
  display: flex; align-items: center; gap: 8px;
  margin: var(--u) 0 0;
  font-size: .875rem; line-height: 1.4; color: var(--muted);
}
.pay-note::before {
  content: ''; flex: none;
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
}
.section--ink .pay-note, .footer .pay-note { color: var(--on-dark-muted); }
.tier__cta .pay-note { justify-content: center; }

/* Изображение между текстовыми блоками */
.band { margin-bottom: calc(var(--u) * 5); border-radius: var(--radius-lg); overflow: hidden; }
.band img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
@media (min-width: 900px) { .band img { aspect-ratio: 5 / 2; } }
.band--wide img { aspect-ratio: 16 / 9; }
@media (min-width: 900px) { .band--wide img { aspect-ratio: 21 / 9; } }
.media { border-radius: var(--radius-lg); overflow: hidden; }
.media img { width: 100%; }

/* Отступ под липкой полосой держит подвал, а не body: подвал идёт последним,
   и без этого его нижние строки — реквизиты и дисклеймер — уходят под кнопку. */
body.has-sticky .footer { padding-bottom: calc(var(--sticky-h, 108px) + var(--cookie-h, 0px) + env(safe-area-inset-bottom) + 8px); }
@media (min-width: 900px) { body.has-sticky .footer { padding-bottom: calc(var(--u) * 6); } }

/* Раскрываемая глубина: цифры, дизайн исследования и полный состав.
   В основном тексте остаётся понятная суть, здесь — проверка для тех, кто хочет. */
.deep { margin-top: calc(var(--u) * 4); border-top: 1px solid var(--line); }
.deep summary {
  display: flex; justify-content: space-between; align-items: center; gap: var(--u);
  padding: calc(var(--u) * 2) 0; cursor: pointer; font-family: var(--font-head);
  font-weight: 700; list-style: none;
}
.deep summary::-webkit-details-marker { display: none; }
.deep summary::after { content: '+'; font-size: 1.4rem; line-height: 1; }
.deep[open] summary::after { content: '−'; }
.deep__body { padding-bottom: calc(var(--u) * 3); font-size: .9375rem; line-height: 1.6; }
.deep__body > * + * { margin-top: calc(var(--u) * 2); }
.section--ink .deep { border-color: rgba(255,255,255,.18); }

/* Как кофеин доходит до фолликула: три шага вместо таблицы с CONSORT. */
.mech { display: grid; gap: calc(var(--u) * 3); margin-top: calc(var(--u) * 4); }
@media (min-width: 760px) { .mech { grid-template-columns: repeat(3, 1fr); } }
.mech__step {
  padding: calc(var(--u) * 3);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface);
}
.mech__ico {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.25rem; height: 2.25rem; margin-bottom: var(--u);
  border-radius: 50%; background: var(--accent); color: #fff;
  font-family: var(--font-head); font-weight: 700;
}
.mech__step h3 { margin-bottom: var(--u); }

/* Сцена тридцатого дня: связный рассказ вместо шести обрубленных плашек. */
.scene--prose { display: block; max-width: 46rem; }
.scene--prose p + p { margin-top: calc(var(--u) * 2); }
.scene--prose p { font-size: 1.0625rem; line-height: 1.7; }

/* ---------- Мобильная раскладка троек ----------
   Три карточки в столбик — это три экрана прокрутки на пустом месте.
   Вбок с прилипанием: край следующей карточки виден и сам подсказывает жест.
   Прокрутка живёт внутри ленты, страница вбок не едет. */
@media (max-width: 699px) {
  .grid--3, .tiers, .enemy, .steps, .flow, .mech {
    grid-auto-flow: column;
    grid-auto-columns: 84%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gut);
    margin-inline: calc(var(--gut) * -1);
    padding-inline: var(--gut);
    padding-bottom: calc(var(--u) * 1.5);
    scrollbar-width: thin;
  }
  .grid--3 > *, .tiers > *, .enemy > *, .steps > *, .flow > *, .mech > * {
    scroll-snap-align: start;
    min-width: 0;
  }

  /* Кадр в карточке товара занимал две трети её высоты. */
  .card__media img { aspect-ratio: 4 / 3; object-fit: cover; }

  /* Вертикальный ритм секций на телефоне плотнее: на 390 px воздуха
     хватает и при меньших полях, а экономия набегает на всей странице. */
  .section { padding-block: calc(var(--u) * 4.5); }
}

/* Ленту видно как ленту: тонкая дорожка вместо системной полосы. */
@media (max-width: 699px) {
  .grid--3, .tiers, .enemy, .steps, .flow, .mech { scrollbar-color: var(--line) transparent; }
  .grid--3::-webkit-scrollbar, .tiers::-webkit-scrollbar, .enemy::-webkit-scrollbar, .steps::-webkit-scrollbar, .flow::-webkit-scrollbar, .mech::-webkit-scrollbar { height: 3px; }
  .grid--3::-webkit-scrollbar-thumb, .tiers::-webkit-scrollbar-thumb, .enemy::-webkit-scrollbar-thumb, .steps::-webkit-scrollbar-thumb, .flow::-webkit-scrollbar-thumb, .mech::-webkit-scrollbar-thumb { background: var(--line); border-radius: 2px; }
}

/* ---------- Кадры и ритм на телефоне ---------- */
@media (max-width: 699px) {
  /* Вертикальные кадры 2:3 съедали по две трети экрана каждый. */
  .hero__media img { aspect-ratio: 5 / 4; object-fit: cover; object-position: center 30%%; }
  .media-figure img { aspect-ratio: 4 / 3; object-fit: cover; }
  .band img { aspect-ratio: 16 / 9; object-fit: cover; }

  /* Плашки срока и тиража тоже листаются вбок. */
  .limits {
    grid-auto-flow: column;
    grid-auto-columns: 78%%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gut);
    margin-inline: calc(var(--gut) * -1);
    padding-inline: var(--gut);
  }
  .limits > * { scroll-snap-align: start; min-width: 0; }

  /* Шапка секции: заголовок и подводка ближе к содержимому. */
  .section__head { margin-bottom: calc(var(--u) * 2.5); }
  .section { padding-block: calc(var(--u) * 4); }
}

/* ---------- Типографика на телефоне ----------
   На 390 px заголовок в 2,3rem уходит в четыре строки и съедает четверть
   экрана раньше, чем начинается текст. Ступень ниже, строка плотнее. */
@media (max-width: 699px) {
  h1 { font-size: 2rem; line-height: 1.12; }
  h2 { font-size: 1.5rem; line-height: 1.18; }
  h3 { font-size: 1.0625rem; }
  .lead { font-size: 1rem; line-height: 1.5; }
  .hero__sub { font-size: 1rem; line-height: 1.5; }
}

@media (max-width: 699px) {
  /* Первый экран должен помещаться в экран, а не в полтора. */
  .hero { padding-block: calc(var(--u) * 3) calc(var(--u) * 4); }
  .hero__grid { gap: calc(var(--u) * 2); }
  .hero__note, .hero__fact { font-size: .8125rem; }
}

/* ---------- Зона решения на телефоне ----------
   Цена, гарантия и тираж стоят рядом и вместе занимали три с половиной экрана.
   Смысл и цифры на месте, ужимается только воздух вокруг них. */
@media (max-width: 699px) {
  .promise { padding: calc(var(--u) * 2.5); gap: var(--u); }
  .promise__num { font-size: 2.5rem; }
  .promise__num span { font-size: .8125rem; letter-spacing: .1em; }
  .limit b { font-size: 1.0625rem; }
  .limit span { font-size: .875rem; line-height: 1.45; }
  .saving__note { font-size: .8125rem; }
  .mt-lg { margin-top: calc(var(--u) * 3) !important; }
}
.mt-lg { margin-top: 48px; }

/* Тираж и срок: три плашки в ряд мелким кеглем вместо ленты.
   Дефицит остаётся в зоне решения и виден целиком без прокрутки. */
@media (max-width: 699px) {
  .limits {
    grid-auto-flow: row;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--u);
    overflow: visible;
    margin-inline: 0;
    padding-inline: 0;
  }
  .limit { padding: calc(var(--u) * 1.5); }
  .limit b { font-size: .9375rem; display: block; margin-bottom: 4px; }
  .limit span { font-size: .75rem; line-height: 1.35; }
  .section { padding-block: calc(var(--u) * 3.25); }
}

/* ---------- Мобильное меню ----------
   На 390 px навигация уезжала за правый край, и часть разделов была недоступна.
   Бургер отдаёт те же ссылки списком, поверх страницы, с возвратом фокуса. */
.burger {
  display: none; flex-direction: column; justify-content: center; gap: 4px;
  width: 44px; height: 44px; padding: 0 10px; margin-inline-start: auto;
  background: none; border: 0; cursor: pointer;
}
.burger span {
  display: block; height: 2px; border-radius: 2px; background: currentColor;
  transition: transform .18s ease, opacity .18s ease;
}
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 899px) {
  .burger { display: flex; }
  .header__nav {
    position: fixed; inset: 64px 0 auto 0; z-index: 45;
    display: none; flex-direction: column; gap: 0;
    max-height: calc(100dvh - 64px); overflow-y: auto;
    padding: var(--gut) var(--gut) calc(var(--gut) * 1.5);
    background: var(--bg); border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 40px rgba(0,0,0,.18);
  }
  .header__nav.is-open { display: flex; }
  .header__nav a {
    padding: 14px 0; font-size: 1rem; color: var(--ink);
    border-bottom: 1px solid var(--line-soft);
  }
  .header__nav a:last-child { border-bottom: 0; }
}

/* ---------- Наверх ----------
   Появляется после двух экранов и садится над липкой полосой, а не на неё. */
.to-top {
  position: fixed; right: var(--gut); z-index: 48;
  bottom: calc(var(--sticky-h, 0px) + var(--cookie-h, 0px) + 12px + env(safe-area-inset-bottom));
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--bg); color: var(--ink);
  border: 1px solid var(--line); box-shadow: var(--shadow);
  cursor: pointer; transition: bottom .22s ease, opacity .18s ease;
}
.to-top[hidden] { display: none; }

/* ---------- Cookie ----------
   Была плашкой поверх липкой кнопки: сообщение закрывало главное действие.
   Теперь это нижняя полоса, а кнопка брони поднимается ровно на её высоту. */
/* Полоса во всю ширину на любом экране: карточкой посередине она накрывала
   карточки товаров и тарифы. Пока полоса видна, страница получает нижний
   отступ на её высоту, поэтому низ содержимого под неё не уходит. */
.cookie {
  left: 0; right: 0; bottom: 0; max-width: none;
  border-radius: 0; border-inline: 0; border-bottom: 0;
  padding: calc(var(--u) * 1.5) var(--gut) calc(var(--u) * 1.5 + env(safe-area-inset-bottom));
  gap: var(--u); font-size: .8125rem;
  justify-content: center;
}
.cookie p { flex: 0 1 44rem; margin: 0; }
.cookie .btn { min-height: 40px; padding: 6px 18px; font-size: .875rem; }
body.has-cookie { padding-bottom: calc(var(--cookie-h, 0px) + env(safe-area-inset-bottom)); }
body.has-cookie .sticky { bottom: var(--cookie-h, 0px); }
@media (min-width: 900px) { .cookie { font-size: .875rem; } }

/* ---------- Появление секций ----------
   Класс ставится скриптом, поэтому без JS содержимое видно сразу. */
.js-reveal .reveal { opacity: 0; transform: translateY(14px); }
.js-reveal .reveal.is-in {
  opacity: 1; transform: none;
  transition: opacity .5s ease, transform .5s ease;
}
@media (prefers-reduced-motion: reduce) {
  .js-reveal .reveal { opacity: 1; transform: none; transition: none; }
}

/* Нижний отступ подвала на телефоне складывается из его собственного поля и
   высоты обеих нижних полос. Собственное поле снизу убираем, иначе под текстом
   остаётся лишняя пустота высотой в треть экрана. */
@media (max-width: 899px) {
  body.has-sticky .footer { padding-bottom: calc(var(--sticky-h, 108px) + var(--cookie-h, 0px) + env(safe-area-inset-bottom)); }
}

/* ---------- Display-шрифт ----------
   Заголовки и цифры набираются им, текст остаётся прежним гротеском:
   пара из двух разных гарнитур, а не одна в двух жирностях. */
@font-face {
  font-family: 'Bitter';
  src: url('../fonts/bitter-cyrillic-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Bitter';
  src: url('../fonts/bitter-latin-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2122, U+2191, U+2193, U+2212;
}

/* ============================================================
   Дизайн-система: роли шрифтов, шкала, воздух, карточки, цифры
   ============================================================ */
:root {
  --font-display: 'Bitter', Georgia, 'Times New Roman', serif;
  --u-space-s: 64px;    /* воздух между секциями на телефоне */
  --u-space-l: 112px;   /* воздух между секциями на десктопе */
}

/* Заголовки и продающие цифры — display. Текст — прежняя гарнитура. */
h1, h2, h3, .tier__price, .card__price, .promise__num, .saving__row,
.hero__price b, .anchor__row b, .limit b, .mech__ico, .tier__badge {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -.02em;
}
h1 { font-size: clamp(2.1rem, 8vw, 4.4rem); line-height: 1.04; }
h2 { font-size: clamp(1.6rem, 4.6vw, 2.75rem); line-height: 1.1; }
h3 { font-size: clamp(1.06rem, 2vw, 1.4rem); line-height: 1.25; letter-spacing: -.01em; }
body { font-size: 18px; line-height: 1.6; }
.lead { font-size: clamp(1.06rem, 2.2vw, 1.3rem); line-height: 1.5; }

/* Числа продают, когда набраны как заголовки, а не как сноски. */
.tier--best .tier__price { font-size: clamp(2.6rem, 9vw, 5.2rem); line-height: .95; }
.tier__price { font-size: clamp(1.9rem, 5vw, 2.6rem); line-height: 1; }
.hero__price b { font-size: clamp(2.2rem, 7vw, 3.4rem); line-height: 1; }
.saving__row { font-size: clamp(1.15rem, 3vw, 1.9rem); line-height: 1.25; }
.saving__row b, .saving__row--big { font-size: 1.15em; }
.promise__num { font-size: clamp(2.8rem, 8vw, 4.6rem); }
.limit b { font-size: clamp(1.05rem, 2.4vw, 1.5rem); }

/* Воздух. Между секциями — крупный шаг, внутри — сетка кратно восьми. */
.section { padding-block: var(--u-space-s); }
@media (min-width: 900px) { .section { padding-block: var(--u-space-l); } }
.section__head { margin-bottom: calc(var(--u) * 4); }
@media (min-width: 900px) { .section__head { margin-bottom: calc(var(--u) * 6); } }

/* Карточка: кадр сверху во всю ширину, пропорция 4:5. */
.card { border-radius: 14px; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,.08); }
.card__media { margin: 0; }
.card__media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; display: block; }
.card__body { padding: calc(var(--u) * 3); }

/* Спойлер состава — текстовая ссылка, а не строка с плюсом в рамке. */
.inci, .card__more, .deep { border: 0; }
.inci > summary, .card__more > summary, .deep > summary {
  display: inline; padding: 0; border: 0; background: none;
  font-family: inherit; font-weight: 500; font-size: .9375rem;
  text-decoration: underline; text-underline-offset: 4px; cursor: pointer;
  list-style: none;
}
.inci > summary::after, .card__more > summary::after, .deep > summary::after { content: ' →'; }
.inci[open] > summary::after, .card__more[open] > summary::after, .deep[open] > summary::after { content: ' ↑'; }
.inci > summary::-webkit-details-marker,
.card__more > summary::-webkit-details-marker,
.deep > summary::-webkit-details-marker { display: none; }

/* Кнопки: одна залитая на зону, вторая контурная. */
.btn { min-height: 54px; padding: 14px 26px; border-radius: 10px; font-size: 1.0625rem; }
.btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* Крупный кадр между блоками: не меньше половины экрана высотой. */
.shot { margin-block: 0; }
.shot img {
  width: 100%; display: block; object-fit: cover;
  height: clamp(320px, 52vh, 560px);
}
.shot--tall img { height: clamp(380px, 72vh, 760px); }
.shot figcaption {
  padding: calc(var(--u) * 1.5) var(--gut);
  font-size: .875rem; color: var(--muted);
}

/* ---------- Подпись бренда: тридцать делений ---------- */
.days { display: flex; gap: 3px; align-items: flex-end; margin-top: calc(var(--u) * 1.5); }
.days i {
  display: block; flex: 1 1 auto; height: 14px;
  background: var(--accent-soft); border-radius: 1px;
}
.days i:nth-child(10n) { height: 22px; background: var(--accent); }
.days__cap { margin-top: 6px; font-size: .75rem; color: var(--muted); }
.section--ink .days i { background: rgba(255,255,255,.35); }
.section--ink .days i:nth-child(10n) { background: #fff; }

/* Крупный кадр на телефоне ниже: на 390 px половина экрана — это уже много,
   а страница и без того длинная. На десктопе кадр остаётся крупным. */
@media (max-width: 699px) {
  .shot img { height: 240px; }
  .shot--tall img { height: 300px; }
  .shot figcaption { padding-block: var(--u); font-size: .8125rem; }
  :root { --u-space-s: 52px; }
  .section__head { margin-bottom: calc(var(--u) * 2.5); }
  .card__body { padding: calc(var(--u) * 2.5); }
}

/* Бордо — акцент, а не полотно. Тёмная врезка остаётся одна, на схеме курса,
   и та с воздухом по краям: сплошная стена спорит с воздушной упаковкой. */
.section--ink {
  background: var(--ink-2);
  border-radius: 20px;
  margin-inline: var(--gut);
}
@media (min-width: 900px) { .section--ink { margin-inline: calc(var(--gut) * 2); } }
.section--soft .enemy__item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: calc(var(--u) * 3);
}

/* ---------- Кадр на своей подложке ----------
   У рендеров собственный фон студии. Врезка получает ту же геометрию, что и
   секция, и мягкую тень: край перестаёт читаться наклейкой поверх страницы. */
.hero__media picture, .hero__media img { border-radius: 18px; }
.hero__media img { box-shadow: 0 24px 60px rgba(0,0,0,.16); }
.shot img { border-radius: 0; }
@media (min-width: 900px) {
  .shot { padding-inline: calc(var(--gut) * 2); }
  .shot img { border-radius: 20px; }
}

/* Первый экран: строка-факт становится плашкой, её видно раньше всего. */
.hero__fact {
  display: inline-block;
  padding: calc(var(--u) * 1.5) calc(var(--u) * 2.5);
  background: #fff; border-left: 4px solid var(--accent);
  border-radius: 0 12px 12px 0;
  box-shadow: 0 8px 26px rgba(23,41,58,.10);
  font-size: 1rem;
}
.hero__fact b { display: block; font-family: var(--font-display); font-size: 1.15rem; }
@media (min-width: 900px) {
  .hero__grid { grid-template-columns: 1.05fr 1fr; align-items: center; gap: calc(var(--u) * 7); }
  .hero h1 { font-size: clamp(2.3rem, 3.4vw, 3.3rem); max-width: 16ch; }
}

/* Подпись под делениями живёт в тёмной врезке: приглушённый цвет для светлого
   фона там нечитаем. */
.section--ink .days__cap, .section--ink .scale__cap { color: var(--on-dark-muted); }

/* ---------- Правки по замечаниям коллег ----------
   Главное: товар больше не обрезается. Пропорция кадра под продукт задавалась
   жёстко, и на первом экране срезало почти половину высоты флакона. */
.hero__media img { aspect-ratio: auto; object-fit: contain; }
.card__media img { aspect-ratio: auto; object-fit: contain; background: transparent; }

/* Врезки идут во всю ширину экрана и работают разделителями блоков:
   раньше на странице встречалось две разные ширины кадров. */
.shot { padding-inline: 0; margin-inline: calc(50% - 50vw); width: 100vw; }
.shot img { border-radius: 0; width: 100%; }
@media (min-width: 900px) { .shot img { border-radius: 0; } }

/* Подпись вписана в кадр, а не висит под ним отдельной строкой. */
.shot { position: relative; }
.shot figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: calc(var(--u) * 2) var(--gut);
  background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.55) 60%);
  color: #fff; font-size: .875rem;
}

/* Внутри лент строки плотнее — просили уменьшить межстрочное. */
@media (max-width: 699px) {
  .card__body p, .tier__list li, .enemy__item p, .facet p, .step p { line-height: 1.45; }
  .grid--3, .tiers, .enemy, .facets, .steps, .flow, .mech { grid-auto-columns: 80%; }
}

/* Главное действие — заливкой. Подбор — контуром: на первом экране залитой
   была кнопка подбора, и бронь визуально проигрывала второстепенному сценарию. */
.hero__actions .btn:first-child {
  --btn-bg: transparent; --btn-fg: var(--accent); border-color: var(--accent);
}
.hero__actions .btn:first-child:hover { --btn-bg: rgba(206,43,51,.08); }
.hero__actions .btn[data-tier] {
  --btn-bg: var(--accent); --btn-fg: #fff; border-color: var(--accent); order: -1;
}
.hero__actions .btn[data-tier]:hover { --btn-bg: var(--ink-2); border-color: var(--ink-2); }

/* ---------- Правки по скриншотам ----------
   Бейдж выделенного тарифа стоял поверх верхней границы карточки и разрезал
   её рамку. Теперь он внутри, отдельной строкой над названием. */
.tier--best { padding-top: calc(var(--u) * 3); }
.tier__badge {
  position: static; transform: none; display: inline-block;
  margin-bottom: calc(var(--u) * 1.5);
}

/* Тираж и срок: три колонки на 390 px оставляли по одному слову в строке.
   Возвращаем ленту с прокруткой — плашка читается целиком. */
@media (max-width: 699px) {
  .limits {
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: 78%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gut);
    margin-inline: calc(var(--gut) * -1);
    padding-inline: var(--gut);
    gap: calc(var(--u) * 1.5);
  }
  .limits > * { scroll-snap-align: start; min-width: 0; }
  .limit b { font-size: 1.0625rem; }
  .limit span { font-size: .8125rem; line-height: 1.45; }
}

/* Воздух вокруг раскрываемых блоков: заголовок следующего блока прилипал
   к спойлеру, а блок гарантии — к разбору цены. */
.deep { margin-block: calc(var(--u) * 3); }
.deep + *, .inci--wide + * { margin-top: calc(var(--u) * 4); }
.section__head + .specs, .specs + * { margin-top: calc(var(--u) * 3); }

/* Кадры продуктов на страницах доказательной базы стояли в узких врезках
   и обрезались на 63 % высоты: флакон был виден наполовину. Пропорция снята. */
.band--tall img { aspect-ratio: auto; object-fit: contain; height: auto; }
@media (max-width: 699px) {
  .band--tall img { aspect-ratio: auto; height: auto; }
  .band img { aspect-ratio: auto; height: auto; object-fit: contain; }
}

/* Строка под липкой кнопкой стояла на полупрозрачной полосе и давала 2,57. */
.sticky .cta-note, .sticky .pay-note { color: var(--ink); }

/* ---------- Вертикальный ритм внутри секций ----------
   Все соседние блоки внутри .wrap разделены одним шагом. Раньше зазор
   набирался случайно из отступов отдельных элементов: где-то 0, где-то 40. */
.section .wrap > * + * { margin-top: calc(var(--u) * 3); }
.section .wrap > .section__head + * { margin-top: calc(var(--u) * 3); }
.section .wrap > .promise,
.section .wrap > .limits,
.section .wrap > .anchor,
.section .wrap > .saving,
.section .wrap > .specs,
.section .wrap > .deep { margin-top: calc(var(--u) * 5); }
/* Заголовок нового смыслового блока получает больше воздуха сверху. */
.section .wrap > h3,
.section .wrap > .section__head:not(:first-child) { margin-top: calc(var(--u) * 6); }
/* Жёстко вписанные отступы больше не нужны: ритм задан шкалой. */
.mt-lg { margin-top: calc(var(--u) * 5) !important; }
@media (max-width: 699px) {
  .section .wrap > * + * { margin-top: calc(var(--u) * 2.5); }
  .section .wrap > h3,
  .section .wrap > .section__head:not(:first-child) { margin-top: calc(var(--u) * 4.5); }
  .mt-lg { margin-top: calc(var(--u) * 4) !important; }
}

/* Собственные отступы прямых детей секции гасим: шаг задаёт только шкала.
   Иначе к 24 px шкалы прибавлялись 16, 20 или 32 px от самих блоков. */
.section .wrap > * { margin-bottom: 0; }
/* Гасим только нижние отступы: верхние задаёт шкала, и обнулять их нельзя —
   иначе блоки снова встают вплотную. */
.section .wrap > .band,
.section .wrap > .cta-block,
.section .wrap > .cta-row,
.section .wrap > .deadline,
.section .wrap > .note,
.section .wrap > p,
.section .wrap > h3 { margin-bottom: 0; }
.section .wrap > * + .band { margin-top: calc(var(--u) * 5); }

/* Отступ под нижними полосами учитывался дважды — на body и на подвале, —
   и под реквизитами оставалось 256 px пустоты. Оставляем один источник. */
body.has-cookie { padding-bottom: 0; }

/* Плашка согласия занимала 135 px из-за длинного текста в три строки.
   Текст короче, строка одна — пустоты под подвалом меньше на 70 px. */
.cookie { padding-block: calc(var(--u) * 1.25); font-size: .8125rem; }
.cookie p { margin: 0; }
@media (max-width: 699px) {
  .cookie { flex-wrap: nowrap; gap: var(--u); align-items: center; }
  .cookie p { flex: 1 1 auto; font-size: .75rem; line-height: 1.35; }
  .cookie .btn { flex: 0 0 auto; min-height: 36px; padding: 5px 14px; font-size: .8125rem; }
}
