/* «Ретро онлайн» — основа страницы: токены, шрифты по ролям, каркас разделов, общие элементы.
   Числа — замеры teak.io (study/spec/layout.txt, 28.09.2026). Диапазоны те же, что у оригинала:
   ≥1440 (база) · 1200–1439.98 · 810–1199.98 · ≤809.98. Внутри диапазона кегли не меняются. */

/* ---------- Шрифты (роли) — блок @font-face вставляется из study/fonts/fonts.css ---------- */
/* @fonts:start */
/* Подбор и замеры шрифтов — .context/design-research/online/teak-replica/study/fonts/fonts.css (таблица в комментарии).
   Семейства teak заменены открытыми шрифтами с кириллицей (OFL, лицензии рядом с файлами); масштаб и вертикальные
   метрики teak вшиты в файлы, поэтому кегли и интерлиньяжи в CSS — ровно числа teak.
   ABC Solar Display Medium → RT Display (Inter Tight 600) · ABC Solar Semibold → RT Display Semibold (Inter Tight 650)
   Baste B Medium → RT Accent (Rubik 675) · Haffer Medium → RT Text (Inter 565) · Haffer SemiBold → RT Text SemiBold (Inter 650)
   Haffer Regular → RT Text Regular (Inter 415) · Haffer Mono Medium → RT Mono (Geist Mono 540) */
@font-face {
  font-family: "RT Display";
  src: url("../fonts/rt-display.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
  /* scale 96.3311% and teak "ABC Solar Display Medium" metrics (ascent 0.96 / descent 0.26 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 96%;
  descent-override: 26%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "RT Display Semibold";
  src: url("../fonts/rt-display-semibold.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
  /* scale 94.9907% and teak "ABC Solar Semibold" metrics (ascent 0.96 / descent 0.26 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 96%;
  descent-override: 26%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "RT Accent";
  src: url("../fonts/rt-accent.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
  /* scale 88.0282% and teak "Baste B Medium" metrics (ascent 1 / descent 0.2 / line gap 0.3 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 100%;
  descent-override: 20%;
  line-gap-override: 30%;
}
@font-face {
  font-family: "RT Text";
  src: url("../fonts/rt-text.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
  /* scale 94.0312% and teak "Haffer Medium" metrics (ascent 0.95 / descent 0.24 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 95%;
  descent-override: 24%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "RT Text SemiBold";
  src: url("../fonts/rt-text-semibold.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
  /* scale 97.0616% and teak "Haffer SemiBold" metrics (ascent 0.95 / descent 0.24 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 95%;
  descent-override: 24%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "RT Text Regular";
  src: url("../fonts/rt-text-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  /* scale 97.6633% and teak "Haffer Regular" metrics (ascent 0.95 / descent 0.24 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 95%;
  descent-override: 24%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "RT Mono";
  src: url("../fonts/rt-mono.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
  /* scale 100% and teak "Haffer Mono Medium" metrics (ascent 0.95 / descent 0.24 / line gap 0 em) are baked into the file;
     the overrides repeat the exact values for Chromium/Firefox (WebKit ignores them and uses the baked ones) */
  ascent-override: 95%;
  descent-override: 24%;
  line-gap-override: 0%;
}
/* @fonts:end */

/* ---------- Токены ---------- */
/* Палитра — доска v3 (07.10.2026), перекраска 14.10.2026: только 32 образца — бумага, чернила, бордо (главный, как у школы
   «Ретро»), золото, хвойный, дымчатый синий. Имена токенов прежние (от teak), значения новые; роль — в комментарии.
   Таблица решений и проверка: _build/palette.json, node _build/palette.mjs check. */
:root {
  --bg: #fbf9f5;          /* бумага: фон страниц, текст тёмных кнопок, тема браузера */
  --white: #ffffff;       /* белые панели: ярлыки, меню и шапка на планшете, поле телефона */
  --grid: #f3efe7;        /* клетка фона, карточка «Готовы начать учиться?», подложка фото */
  --line: #e7e0d3;        /* линии карточек и рамок */
  --line-2: #f3efe7;      /* рамки отзывов и карточки демо-доступа */
  --ink: #2a0f14;         /* чернила: заголовки, тёмные кнопки */
  --text: #544145;        /* основной текст */
  --muted: #766e70;       /* подписи, пункты меню, ссылки */
  --muted-15: rgba(118, 110, 112, 0.15);
  --ink-10: rgba(42, 15, 20, 0.1);   /* рамки белых карточек мини-экранов */
  --cta: #6b0f2b;         /* бордо: главная кнопка «Записаться» (.btn--light и первый экран) */
  --cta-ink: #fbf9f5;     /* текст на главной кнопке, 11,6:1 */
  --yellow: #efdbbe;      /* светлое золото: плашка под «Ретро»; текст тёмной кнопки в шапке при наведении */
  --yellow-2: #f8eddc;    /* светло-золотые карточки, строка документа по якорю; текст зелёной кнопки при наведении */
  --yellow-3: #efdbbe;    /* рамка светло-золотых карточек */
  --yellow-4: #f8eddc;    /* запас */
  --green-card: #e1efe7;  /* карточка «Бесплатный демо-доступ» */
  --green-cta: #41765a;   /* кнопка «Получить доступ» (текст 5:1), галочки в списках */
  --violet: #6b0f2b;      /* бордо: кнопка «Жду звонка», рамка фокуса сайта и админки */
  --violet-2: #9c4053;    /* «Жду звонка» при наведении, рамка поля телефона в фокусе */
  --violet-3: #fddfe3;    /* поле телефона в фокусе */
  --plum: #4c041b;        /* запас */
  --pink: #6b0f2b;        /* точка «Учителя» в админке (цвет раздела) */
  --pink-2: #c27b86;      /* подложка слова второго шага «Как начать» */
  --peach: #e5b6bc;       /* подложка слова первого шага, плашка второго отзыва */
  --lilac: #c1cfe1;       /* плашка третьего отзыва */
  --green: #79a48c;       /* точка на экране кабинета, запасной цвет точки в крошках */
  --mint: #b9d2c3;        /* подложка слова третьего шага, плашка первого отзыва */
  --sky: #c1cfe1;         /* запас */
  --sky-2: #e4ecf6;       /* запас */
  --ochre: #9c7228;       /* запас */

  --f-display: 'RT Display', system-ui, sans-serif;
  --f-display-sb: 'RT Display Semibold', 'RT Display', system-ui, sans-serif;
  --f-accent: 'RT Accent', 'RT Display', system-ui, sans-serif;
  --f-text: 'RT Text', system-ui, sans-serif;
  --f-text-sb: 'RT Text SemiBold', 'RT Text', system-ui, sans-serif;
  --f-text-reg: 'RT Text Regular', 'RT Text', system-ui, sans-serif;
  --vision-font: var(--f-text);   /* кнопка и панель «Версия для слабовидящих» — шрифтом сайта (sites/_shared/vision) */
  --f-mono: 'RT Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --ff: "blwf", "cv03", "cv04", "cv09", "cv11";
  --ff-mono: "blwf", "cv03", "cv04", "cv09", "cv11", "zero";

  --glow: 0 0 17px var(--bg), 0 0 17px var(--bg), 0 0 17px var(--bg), 0 0 17px var(--bg);

  /* Каркас */
  --pad: 156px;
  --col: 1130px;
  --page-top: 210px;
  --gap: 120px;

  /* Кегли по ролям (≥1440 и 1200–1439 совпадают, кроме цитаты отзыва) */
  --h1: 65px;
  --hl: 68px;
  --h2: 50px;
  --h2-feat: 50px;
  --ls-h2-feat: -0.01em;
  --card-t: 26px;
  --promo-t: 40px;
  --step-w: 56px;
  --quote: 38.08px;
  --body: 17px;
  --cta-hero: 24px;
  --stat: 20.96px;
}
@media (min-width: 1200px) and (max-width: 1439.98px) {
  :root { --pad: 128px; --quote: 30.4px; }
}
@media (min-width: 810px) and (max-width: 1199.98px) {
  :root {
    --pad: 64px; --page-top: 116px; --gap: 60px;
    --h1: 50px; --hl: 52px; --h2: 38px; --h2-feat: 38px; --card-t: 20.8px; --promo-t: 28.8px;
    --step-w: 44.8px; --quote: 20.8px; --body: 14px; --cta-hero: 16px; --stat: 18.4px;
  }
}
@media (max-width: 809.98px) {
  :root {
    --pad: 24px; --page-top: 116px; --gap: 60px;
    --h1: 34.784px; --hl: 38px; --h2: 34.784px; --h2-feat: 26px; --ls-h2-feat: -0.02em; --card-t: 20.8px;
    --promo-t: 24px; --step-w: 44.8px; --quote: 19.2px; --body: 14px; --cta-hero: 16px; --stat: 14.08px;
  }
}

/* ---------- Сброс ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
  overflow-x: clip;
  scroll-padding-top: 112px; /* шапка закреплена: 88 px на компьютере */
}
@media (max-width: 1199.98px) { html { scroll-padding-top: 80px; } /* полоса 56 px */ }
@supports not (overflow: clip) { html { overflow-x: hidden; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-text);
  font-size: var(--body);
  line-height: 1.4;
  font-weight: 500;
  font-feature-settings: var(--ff);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, h5, p, ul, ol, figure, blockquote { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; }
img, svg, video, canvas { display: block; max-width: none; }
input { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }

.vh {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: fixed; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; background: var(--ink); color: var(--bg);
  font-family: var(--f-mono); font-size: 14px; border-radius: 20px; transition: top .2s;
}
.skip:focus { top: 12px; }

/* ---------- Каркас страницы ---------- */
.page {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap);
  padding-top: var(--page-top);
  overflow: clip;
  background: var(--bg);
}
@supports not (overflow: clip) { .page { overflow: hidden; } }
.page__main {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap);
}
.sec {
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 0 var(--pad);
}
.sec > .wrap { flex: 1 0 0; min-width: 0; max-width: var(--col); position: relative; }

/* ---------- Роли текста ---------- */
.t-h1 { font-family: var(--f-display); font-weight: 500; font-size: var(--h1); line-height: 1; color: var(--ink); white-space: pre; }
.t-hl { font-family: var(--f-accent); font-weight: 500; font-size: var(--hl); line-height: 0.98; color: var(--ink); white-space: pre; }
.t-h2 { font-family: var(--f-display); font-weight: 500; font-size: var(--h2); line-height: 1.05; letter-spacing: -0.01em; color: var(--ink); text-wrap: balance; }
.t-card { font-family: var(--f-text-sb); font-weight: 400; font-size: var(--card-t); line-height: 1.1; letter-spacing: -0.01em; color: var(--ink); }
.t-promo { font-family: var(--f-accent); font-weight: 400; font-size: var(--promo-t); line-height: 0.98; color: var(--ink); }
.t-step { font-family: var(--f-accent); font-weight: 400; font-size: var(--step-w); line-height: 0.98; color: var(--ink); }
.t-quote { font-family: var(--f-display); font-weight: 400; font-size: var(--quote); line-height: 1.1; color: var(--ink); }
.t-body { font-family: var(--f-text); font-weight: 500; font-size: var(--body); line-height: 1.4; color: var(--text); text-wrap: balance; }
.t-cap { font-family: var(--f-mono); font-weight: 500; font-size: 13.6px; line-height: 1.1; letter-spacing: 0.04em; color: var(--muted); white-space: pre; font-feature-settings: var(--ff-mono); }
.t-btn { font-family: var(--f-mono); font-weight: 400; font-size: 14px; line-height: 1.1; letter-spacing: 0.03em; white-space: pre; }
.glow { text-shadow: var(--glow); }

/* ---------- Ярлык-вкладка над блоком (Eyebrow label) ---------- */
.tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 40px;
  background: var(--white);
  overflow: hidden;
}
.tab::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  border: 1px solid var(--line); border-bottom: 0;
}
@media (max-width: 809.98px) {
  .tab { padding: 12px 16px; }
}

/* ---------- Кнопки ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 40px;
  padding: 8px 20px;
  border-radius: 20px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--f-mono);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.1;
  letter-spacing: 0.03em;
  white-space: pre;
}
.btn--light { background: var(--cta); color: var(--cta-ink); }
.btn--green { background: var(--green-cta); color: var(--bg); }
.btn--sm { height: 30px; padding: 8px 10px; font-weight: 500; font-size: 12px; letter-spacing: 0.03em; }
.arr { position: relative; display: inline-block; width: 7px; height: 10px; flex: none; overflow: visible; }
.arr::before {
  content: ''; position: absolute; left: 0; top: 0; width: 7px; height: 10px; background: currentColor;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

/* Текстовая ссылка с линией (Log in, Learn more, See pricing, ссылки подвала) */
.ulink {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 2px 0;
  font-family: var(--f-mono);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.1;
  letter-spacing: 0.03em;
  color: var(--muted);
  white-space: pre;
}
.ulink__t { position: relative; display: inline-block; }
.ulink__t::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--text);
  transform: scaleX(0); transform-origin: 0 50%;
}
/* Ссылка-кнопка на сером фоне (Learn more в бенто) */
.boxlink {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 8px 9px;
  background: var(--line);
  color: var(--ink);
  font-family: var(--f-mono);
  font-weight: 400;
  font-size: 14px;
  line-height: 1;
  letter-spacing: 0.03em;
  white-space: pre;
}

/* ---------- Клетчатый фон (плитка 42, линия 1 px, линии проходят через центр блока) ---------- */
.gridbg {
  position: absolute;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(to right, transparent 20.5px, var(--grid) 20.5px, var(--grid) 21.5px, transparent 21.5px),
    linear-gradient(to bottom, transparent 20.5px, var(--grid) 20.5px, var(--grid) 21.5px, transparent 21.5px);
  background-size: 42px 42px;
  background-position: center center;
}

/* ---------- Появления (см. core.js: data-ap) ---------- */
html.js [data-ap]:not(.ap-in) {
  opacity: var(--ap-o, 1);
  translate: var(--ap-x, 0px) var(--ap-y, 0px);
  scale: var(--ap-s, 1);
  rotate: var(--ap-r, 0deg);
  animation: rt-ap-failsafe 0.01s linear 6s forwards;
}
html.js.rt-ready [data-ap]:not(.ap-in) { animation: none; }
@keyframes rt-ap-failsafe { to { opacity: 1; translate: 0 0; scale: 1; rotate: 0deg; } }

/* «Уменьшить движение» не учитывается: движение у всех всегда (решение владельца 15.11.2026) */

/* ---------- Ранний переход к якорю (15.11.2026) ----------
   Страница, открытая по ссылке с якорем (реклама: /#tarif, /tarify#oplata, /obuchenie#kurator…), до перехода не видна: класс rt-jump
   ставит скрипт в <head>, снимает скрипт в конце страницы (общий кусок подвала в index.html) сразу после перехода к разделу —
   не дожидаясь скриптов страницы. Начало главной поэтому не мелькает. Страховка — страница появится сама через 2,5 с. */
html.rt-jump body { visibility: hidden; animation: rt-jump-failsafe 0s linear 2.5s forwards; }
@keyframes rt-jump-failsafe { to { visibility: visible; } }

/* ---------- Строка «Записаться · Позвонить» после разделов, куда ведёт реклама (15.11.2026) ----------
   Главная — после отзывов; «Обучение» — после #urok, #attestaciya, #kurator, #oge; «Тарифы» — после #oplata. Разметка — метка
   <!--@live:actrow--> (_build/lib/blocks.mjs), номер — из панели. Пара как в шапке внутренних страниц: бордовая кнопка и ссылка с линией. */
.actrow { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.actrow .ulink { padding: 5px 0; color: var(--ink); white-space: normal; }
.actrow .ulink__t::after { background: currentColor; transform: scaleX(1); transition: opacity 0.25s ease-out; }
@media (hover: hover) and (pointer: fine) { .actrow .ulink:hover .ulink__t::after { opacity: 0.35; } }
.actrow__num { white-space: nowrap; }

/* ---------- Баннер cookie ----------
   Общий модуль «Ретро»: assets/css/consent.css и assets/js/consent.js — копии из sites/_shared/consent, их не правим (обновились там —
   скопировать заново). Вид — в языке сайта: белая панель с линией, как ярлыки и карточки; текст и кнопки-«пилюли» — RT Text
   (моноширинный кнопок сайта на телефоне не помещает «Только необходимые» в строку); «Принять все» — бордо, как «Записаться».
   Правила с html сильнее правил копии при любом порядке подключения. */
:root {
  --rc-bg: var(--white);
  --rc-fg: var(--text);
  --rc-accent: var(--cta);
  --rc-accent-fg: var(--cta-ink);
  --rc-font: var(--f-text);
  --rc-radius: 0px;
}
html .rc { font-weight: 500; font-feature-settings: var(--ff); border: 1px solid var(--line); box-shadow: 0 8px 32px rgba(42, 15, 20, 0.12); }
html .rc__t a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
html .rc__btn {
  min-height: 40px; border-radius: 20px; font-weight: 500; line-height: 1.2;
  transition: background-color 0.18s cubic-bezier(0.25, 0.1, 0.25, 1), border-color 0.18s cubic-bezier(0.25, 0.1, 0.25, 1);
}
html .rc__btn:not(.rc__btn--a) { color: var(--ink); }
@media (hover: hover) and (pointer: fine) {
  html .rc__btn--a:hover { background: var(--violet-2); border-color: var(--violet-2); }
  html .rc__btn:not(.rc__btn--a):hover { background: var(--grid); }
  html .rc__t a:hover { text-decoration-color: transparent; }
}
/* С 16.11.2026 баннер компактный (data-compact у consent.js в общем <head>): одна строка и две кнопки по 44 px, на телефоне 86 px
   вместо 138–158. Версия для слабовидящих: строка и кнопки — крупным кеглем режима (vision.css увеличивает баннер, а копия модуля
   ставит строке компактного вида 14 px — селектор с .rc сильнее её правил) */
html.vision-on .rc .rc__t, html.vision-on .rc .rc__btn { font-size: inherit; }
