/* Остров Пыха — общий стиль сайта: страница для родителей (/) и документы (/privacy.html, /consent.html, /about.html).
   Стиль «книжка 1960-х», как в приложении: бумага, ink-линии, плоские краски, прямые углы, жёсткие смещённые тени.
   Шрифты — свои (fonts/, SIL OFL 1.1), без запросов к Google.

   Документы подключают только этот файл; их разметка описана в разделе «документы» ниже.
   Метка для незаполненного: <span class="req">[РЕКВИЗИТЫ ОПЕРАТОРА]</span> — заметная жёлтая плашка. */

@font-face {
  font-family: "Golos Text"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("fonts/golos-text-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Golos Text"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("fonts/golos-text-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Yeseva One"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("fonts/yeseva-one-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Yeseva One"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("fonts/yeseva-one-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --paper: #f3ecd8;
  --paper-deep: #e9dfc3;
  --sheet: #fffaf0;
  --ink: #22304a;
  --ink-soft: #4b5670;
  --pyh: #5b9a38;
  --pyh-dark: #3e7322;
  --tomato: #bf3b26;   /* было #d2452f: мелкий жирный текст («скоро», «0+», подписи листовки) давал 4,36:1, нужно 4,5 */
  --ochre: #d6992b;
  --ochre-pale: #f1d58f;
  --ultra: #2b4596;
  --ultra-deep: #1f3473;
  --line: rgba(34, 48, 74, .22);

  --f-text: "Golos Text", "PT Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-title: "Yeseva One", "PT Serif", Georgia, serif;

  --wrap: 1200px;
  --gut: 24px;
  --hard: 6px 6px 0 var(--ink);
  --hard-sm: 4px 4px 0 var(--ink);

  /* бумажное зерно: шум, а не градиент */
  --grain: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .13  0 0 0 0 .19  0 0 0 0 .29  0 0 0 .07 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 16px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background-color: var(--paper);
  background-image: var(--grain);
  color: var(--ink);
  font-family: var(--f-text);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.55;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ultra); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--tomato); }
:focus-visible { outline: 3px solid var(--tomato); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--f-title); font-weight: 400; line-height: 1.08; margin: 0; letter-spacing: .005em; overflow-wrap: break-word; hyphens: auto; }
p { margin: 0 0 .8em; }
p:last-child { margin-bottom: 0; }
b, strong { font-weight: 700; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gut)); margin: 0 auto; padding: 0 var(--gut); }
.skip { position: absolute; left: 8px; top: -60px; background: var(--ink); color: var(--paper); padding: 10px 14px; z-index: 10; }
.skip:focus { top: 8px; }

/* метка незаполненного — должна бросаться в глаза */
.req { background: #ffe14a; color: var(--ink); outline: 2px dashed var(--tomato); outline-offset: 1px; padding: 0 4px; font-weight: 700; }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--pyh); color: #fff; text-decoration: none;
  font-family: var(--f-title); font-size: 22px; line-height: 1;
  border: 3px solid var(--ink); border-radius: 0;
  padding: 16px 26px; min-height: 56px;
  box-shadow: var(--hard);
  transition: transform .08s, box-shadow .08s;
}
.btn:hover { color: #fff; background: var(--pyh-dark); }
.btn:active { transform: translate(4px, 4px); box-shadow: 2px 2px 0 var(--ink); }
.btn-big { font-size: 28px; padding: 20px 34px; min-height: 72px; }
.btn-small { font-size: 18px; padding: 10px 16px; min-height: 46px; box-shadow: var(--hard-sm); }
.btn-small:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }

.link-arrow { font-weight: 700; color: var(--ink); }
.link-arrow::after { content: " →"; }

/* возрастной знак: штамп */
.age-mark {
  display: inline-grid; place-items: center;
  width: 46px; height: 46px; border-radius: 50%;
  border: 2.5px solid var(--tomato); box-shadow: inset 0 0 0 3px var(--paper), inset 0 0 0 4.5px var(--tomato);
  color: var(--tomato); font-weight: 700; font-size: 15px; letter-spacing: -.02em;
  transform: rotate(-8deg); flex: none;
}

/* ---------- шапка ---------- */
.site-head { border-bottom: 3px double var(--ink); }
.site-head-row { display: flex; align-items: center; gap: 22px; min-height: 76px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--f-title); font-size: 26px; line-height: 1; margin-right: auto; }
.brand img { width: 48px; height: 48px; object-fit: contain; }
.brand:hover { color: var(--ink); }
.site-nav { display: flex; gap: 22px; }
.site-nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 16px; padding: 6px 0; border-bottom: 2px solid transparent; }
.site-nav a:hover { border-bottom-color: var(--tomato); color: var(--ink); }

/* ---------- обложка ---------- */
.hero { padding: 56px 0 72px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 56px; align-items: center; }
.kicker { font-size: 15px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--tomato); margin-bottom: 18px; }
.hero h1 { font-size: clamp(42px, 5.4vw, 76px); margin-bottom: 26px; }
.lead { font-size: 21px; line-height: 1.5; max-width: 34em; margin-bottom: 30px; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; margin-bottom: 30px; }
.hero-facts { list-style: none; margin: 0; padding: 14px 0 0; border-top: 1.5px solid var(--ink); display: flex; flex-wrap: wrap; gap: 6px 22px; font-weight: 700; font-size: 16px; }
.hero-facts li { display: flex; align-items: center; gap: 8px; }
.hero-facts li::before { content: ""; width: 9px; height: 9px; background: var(--tomato); flex: none; }

/* вклеенная иллюстрация: поля бумаги, ink-рамка, жёсткая тень, полоска скотча */
.plate { margin: 0; position: relative; background: var(--sheet); padding: 12px 12px 10px; border: 2px solid var(--ink); box-shadow: 10px 10px 0 var(--ultra); }
.hero-plate { transform: rotate(1.3deg); margin-right: 6px; }
.plate img { width: 100%; border: 1.5px solid var(--ink); }
.plate figcaption { font-size: 14px; color: var(--ink-soft); padding-top: 8px; }
.plate figcaption::before { content: "Рис. 1. "; font-weight: 700; color: var(--ink); }
.hero-plate::before {
  content: ""; position: absolute; top: -16px; left: 38%; width: 120px; height: 32px;
  background: rgba(214, 153, 43, .55); border-left: 1px dashed rgba(34, 48, 74, .25); border-right: 1px dashed rgba(34, 48, 74, .25);
  transform: rotate(-4deg);
}

/* ---------- главы ---------- */
.chapter { padding: 72px 0; border-top: 1.5px solid var(--ink); }
.chapter-head { display: flex; align-items: baseline; gap: 22px; margin-bottom: 40px; flex-wrap: wrap; }
.chapter-no { margin: 0; font-size: 15px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--tomato); }
.chapter h2 { font-size: clamp(36px, 4.2vw, 58px); }

/* Что это */
.what-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; align-items: end; margin-bottom: 56px; }
.what-text { font-size: 20px; max-width: 30em; }
/* рост Пыха: рамки-окошки растущего размера; край рисунка совпадает с рамкой */
.growth { list-style: none; margin: 0; padding: 0; display: flex; align-items: flex-end; justify-content: flex-end; gap: 16px; }
.growth li { display: grid; justify-items: start; gap: 8px; flex: none; }
.growth img { height: var(--h); width: auto; max-width: none; background: var(--sheet); border: 2px solid var(--ink); box-shadow: var(--hard-sm); box-sizing: content-box; }
.growth li:nth-child(1) { --h: 104px; }
.growth li:nth-child(2) { --h: 132px; }
.growth li:nth-child(3) { --h: 176px; }
.growth li:nth-child(4) { --h: 220px; }
.growth li:nth-child(2) img { box-shadow: 4px 4px 0 var(--ochre); }
.growth li:nth-child(3) img { box-shadow: 4px 4px 0 var(--pyh); }
.growth li:nth-child(4) img { box-shadow: 4px 4px 0 var(--tomato); }
.growth span { font-size: 14px; font-weight: 700; padding-top: 2px; }

/* оглавление: страница содержания со сносками-точками */
.contents { background: var(--sheet); border: 2px solid var(--ink); box-shadow: var(--hard); padding: 30px 36px 28px; max-width: 900px; margin-left: 8%; position: relative; }
.contents h3 { font-size: 30px; margin-bottom: 18px; text-align: center; }
.toc { list-style: none; margin: 0 0 18px; padding: 0; }
.toc li { display: grid; grid-template-columns: auto minmax(20px, 1fr) auto; align-items: baseline; column-gap: 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.toc-name { font-family: var(--f-title); font-size: 24px; }
.toc-dots { border-bottom: 2.5px dotted var(--ink); transform: translateY(-6px); }
.toc-num { font-weight: 700; color: var(--pyh-dark); white-space: nowrap; }
.toc-about { grid-column: 1 / -1; font-size: 16px; color: var(--ink-soft); }
.toc .is-soon .toc-name { color: var(--ink-soft); }
.toc .is-soon .toc-num { color: var(--tomato); text-transform: lowercase; }
.toc-note { font-size: 16px; color: var(--ink-soft); }

/* Как устроен день: страница тетради — красное поле, синие линейки */
.day-grid { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: 48px; align-items: start; }
.notebook {
  list-style: none; margin: 0; padding: 0 28px 32px 0;
  background-color: var(--sheet); background-position: 0 -7px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8' height='32'><rect y='31' width='8' height='1' fill='rgb(43,69,150)' fill-opacity='.2'/></svg>");
  border: 2px solid var(--ink); box-shadow: var(--hard);
  position: relative;
}
.notebook::before { content: ""; position: absolute; top: 0; bottom: 0; left: 168px; border-left: 2px solid rgba(210, 69, 47, .7); }
/* всё внутри тетради — кратно линейке 32px, чтобы строки лежали на линиях */
.notebook li { display: grid; grid-template-columns: 168px minmax(0, 1fr); gap: 0; padding: 32px 0 0; line-height: 32px; }
.nb-when { font-family: var(--f-title); font-size: 21px; color: var(--tomato); padding: 0 18px 0 24px; line-height: 32px; }
.nb-what { padding-left: 26px; }
.nb-what h3 { font-size: 27px; line-height: 32px; margin: 0; }
.nb-what p { margin: 0; }

.note {
  background: var(--ochre-pale); border: 2px solid var(--ink); padding: 30px 26px 24px;
  transform: rotate(-2deg); margin-top: 40px; position: relative; box-shadow: 6px 6px 0 var(--tomato);
}
.note::before { content: ""; position: absolute; top: -14px; left: 50%; width: 90px; height: 28px; margin-left: -45px; background: rgba(255, 250, 240, .75); border: 1px solid rgba(34, 48, 74, .2); transform: rotate(3deg); }
.note-label { font-size: 15px; font-weight: 700; color: var(--ink-soft); border-bottom: 1.5px solid var(--ink); padding-bottom: 8px; }
.note-text { font-size: 18px; line-height: 1.5; }

/* Чем отличается: плоская ультрамариновая полоса */
.chapter-blue { background-color: var(--ultra); background-image: var(--grain); color: var(--paper); border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink); }
.chapter-blue .chapter-no { color: var(--ochre-pale); }
.diff { list-style: none; margin: 0; padding: 0; counter-reset: d; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 64px; }
.diff li { counter-increment: d; position: relative; padding: 26px 0 28px 74px; border-top: 1.5px solid rgba(243, 236, 216, .45); }
.diff li::before { content: counter(d); position: absolute; left: 0; top: 18px; font-family: var(--f-title); font-size: 56px; line-height: 1; color: var(--ochre); }
.diff h3 { font-size: 26px; margin-bottom: 10px; color: #fff; }
.diff p { color: var(--paper); max-width: 34em; }
.diff-wide { grid-column: 1 / -1; padding-right: 330px !important; min-height: 220px; }
.diff-hero { position: absolute; bottom: 0; object-fit: contain; }
.diff-sova { right: 150px; width: 140px; }
.diff-kot { right: 0; width: 140px; }

/* Как поставить: два листка-инструкции разной ширины */
.install { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 40px 48px; align-items: start; }
.leaflet { background: var(--sheet); border: 2px solid var(--ink); padding: 26px 30px 24px; box-shadow: var(--hard); }
.leaflet-android { margin-top: 48px; box-shadow: 6px 6px 0 var(--pyh); }
.leaflet h3 { font-size: 34px; margin-bottom: 14px; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.leaflet h3 span { font-family: var(--f-text); font-weight: 700; font-size: 15px; letter-spacing: .06em; text-transform: uppercase; color: var(--tomato); }
.leaflet ol { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.leaflet li { counter-increment: s; position: relative; padding: 10px 0 10px 50px; border-top: 1px solid var(--line); }
.leaflet li::before { content: counter(s); position: absolute; left: 0; top: 9px; width: 34px; height: 34px; display: grid; place-items: center; border: 2px solid var(--ink); font-weight: 700; font-size: 16px; background: var(--paper); }
.ui-ico { display: inline-block; width: 28px; height: 28px; vertical-align: -7px; padding: 3px; border: 1.5px solid var(--ink); background: var(--paper); fill: currentColor; margin: 0 2px; }
.install-after { grid-column: 1 / -1; font-size: 19px; max-width: 46em; border-left: 6px solid var(--pyh); padding: 4px 0 4px 20px; margin: 0; }

/* Сколько стоит: билет с корешком */
.free-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: 24px 56px; align-items: center; }
.free-grid .chapter-head { margin-bottom: 0; align-self: start; }
.ticket { display: grid; grid-template-columns: minmax(0, 1fr) 120px; background: var(--sheet); border: 2.5px solid var(--ink); box-shadow: 8px 8px 0 var(--tomato); transform: rotate(-1deg); max-width: 640px; }
.ticket-main { padding: 26px 30px; }
.ticket-label { font-size: 14px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 4px; }
.ticket-big { font-family: var(--f-title); font-size: clamp(44px, 5vw, 66px); line-height: 1; color: var(--pyh-dark); margin-bottom: 16px; }
.ticket ul { margin: 0; padding: 0 0 0 20px; font-size: 18px; }
.ticket li { margin-bottom: 4px; }
.ticket-stub { border-left: 3px dashed var(--ink); background: var(--ochre); display: grid; place-items: center; }
.ticket-stub span { font-family: var(--f-title); font-size: 40px; color: var(--ink); transform: rotate(-90deg); }
.free-later { grid-column: 2; max-width: 36em; color: var(--ink-soft); margin: 10px 0 0; }

/* Данные */
.chapter-data { background-color: var(--paper-deep); background-image: var(--grain); }
.data-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px 56px; }
.chapter-data h2 { font-size: clamp(30px, 3.4vw, 44px); }
.data-text { font-size: 19px; max-width: 38em; }
.doc-links { list-style: none; margin: 22px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 28px; font-weight: 700; }

/* Финал */
.finale { border-top: 3px double var(--ink); padding: 48px 0 0; overflow: hidden; }
.finale-row { display: flex; align-items: flex-end; gap: 40px; justify-content: center; }
.finale-pyh { width: 170px; flex: none; }
.finale-row > div { padding-bottom: 56px; }
.finale-title { font-family: var(--f-title); font-size: clamp(34px, 4vw, 52px); line-height: 1.05; margin-bottom: 24px; }

/* ---------- подвал ---------- */
.site-foot { background: var(--ink); color: var(--paper); padding: 44px 0 52px; font-size: 15px; line-height: 1.55; }
.site-foot a { color: var(--paper); }
.site-foot a:hover { color: var(--ochre-pale); }
.foot-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 4fr); gap: 28px 40px; }
.foot-brand { display: flex; align-items: center; gap: 14px; font-family: var(--f-title); font-size: 26px; margin-bottom: 14px; }
.site-foot .age-mark { border-color: var(--ochre); color: var(--ochre); box-shadow: inset 0 0 0 3px var(--ink), inset 0 0 0 4.5px var(--ochre); }
.foot-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.foot-op p { margin-bottom: 8px; }

/* ---------- документы: /privacy.html, /consent.html, /about.html ----------
   Разметка документов: <div class="doc"> <nav class="top">ссылки</nav> <main>h1, .meta, .lead, h2, p, ul, ol, table, .box</main> <footer>…</footer> </div>;
   незаполненное — <mark class="todo">[РЕКВИЗИТЫ ОПЕРАТОРА]</mark>, возрастной знак — <span class="age">0+</span>. */
.doc { max-width: calc(820px + 2 * var(--gut)); margin: 0 auto; padding: 0 var(--gut) 72px; }
.doc nav.top { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px; padding: 18px 0 14px; margin-bottom: 40px; border-bottom: 3px double var(--ink); font-weight: 600; font-size: 16px; }
.doc nav.top a { color: var(--ink); text-decoration: none; border-bottom: 2px solid transparent; padding: 4px 0; }
.doc nav.top a:hover { border-bottom-color: var(--tomato); }
.doc nav.top a:first-child { font-family: var(--f-title); font-weight: 400; font-size: 24px; flex-basis: 100%; }
.doc nav.top a[aria-current="page"] { border-bottom-color: var(--ink); }
.doc main { font-size: 18px; }
.doc h1 { font-size: clamp(34px, 5vw, 54px); margin: 0 0 16px; }
.doc h2 { font-size: clamp(25px, 3vw, 32px); margin: 48px 0 14px; padding-top: 18px; border-top: 1.5px solid var(--ink); }
.doc h3 { font-size: 22px; margin: 28px 0 10px; }
.doc .meta { color: var(--ink-soft); font-size: 15px; margin-bottom: 18px; }
.doc .lead { font-size: 20px; line-height: 1.5; max-width: none; margin: 0 0 28px; }
.doc ul, .doc ol { padding-left: 26px; margin: 0 0 1em; }
.doc li { margin-bottom: 8px; }
.doc li::marker { color: var(--tomato); font-weight: 700; }
.doc .box, .doc blockquote { margin: 24px 0; padding: 20px 24px; background: var(--sheet); border: 2px solid var(--ink); box-shadow: var(--hard-sm); }
.doc table { width: 100%; border-collapse: collapse; margin: 18px 0 26px; font-size: 16px; background: var(--sheet); border: 2px solid var(--ink); box-shadow: var(--hard-sm); }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 14px; border: 1px solid var(--line); overflow-wrap: anywhere; }
.doc th { font-weight: 700; background: var(--paper-deep); border-bottom: 2px solid var(--ink); }
.doc td:first-child { font-weight: 700; width: 38%; }
mark.todo { background: #ffe14a; color: var(--ink); outline: 2px dashed var(--tomato); outline-offset: 1px; padding: 0 4px; font-weight: 700; }
.age {
  display: inline-grid; place-items: center; vertical-align: middle;
  width: 1.9em; height: 1.9em; border-radius: 50%; margin-left: .25em;
  border: 2px solid var(--tomato); color: var(--tomato);
  font-family: var(--f-text); font-weight: 700; font-size: 15px; line-height: 1; letter-spacing: -.02em;
  transform: rotate(-8deg);
}
.doc h1 .age { font-size: 18px; vertical-align: .35em; }
.doc footer { margin-top: 64px; padding-top: 18px; border-top: 3px double var(--ink); font-size: 15px; color: var(--ink-soft); }
.doc footer p { margin-bottom: 8px; }

/* ---------- планшет ---------- */
@media (max-width: 1240px) {
  .site-nav { gap: 16px; }
  .hero-grid { gap: 40px; }
  .diff { column-gap: 44px; }
  .diff-wide { padding-right: 300px !important; }
}
@media (max-width: 1040px) {
  .site-nav { display: none; }
  .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .what-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .growth { max-width: 640px; }
  .contents { margin-left: 0; }
  .day-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .note { max-width: 520px; margin: 10px 0 0 auto; }
  .free-grid { grid-template-columns: minmax(0, 1fr); }
  .free-later { grid-column: 1; }
  .data-grid { grid-template-columns: minmax(0, 1fr); }
  .foot-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .foot-main { grid-column: 1 / -1; }
}

/* ---------- телефон ---------- */
@media (max-width: 760px) {
  :root { --gut: 16px; --hard: 5px 5px 0 var(--ink); }
  body { font-size: 17px; }
  .site-head-row { gap: 12px; min-height: 64px; }
  .brand { font-size: 21px; gap: 8px; }
  .brand img { width: 38px; height: 38px; }
  .site-head .age-mark { width: 38px; height: 38px; font-size: 13px; }
  .btn-small { font-size: 15px; padding: 8px 10px; min-height: 42px; }

  .hero { padding: 32px 0 48px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .hero h1 { font-size: 40px; margin-bottom: 18px; }
  .lead { font-size: 18px; margin-bottom: 24px; }
  .btn-big { font-size: 24px; padding: 18px 24px; min-height: 64px; width: 100%; max-width: 360px; }
  .hero-plate { transform: rotate(1deg); margin-right: 8px; box-shadow: 7px 7px 0 var(--ultra); padding: 8px 8px 8px; }
  .hero-plate::before { width: 90px; height: 26px; top: -13px; }

  .chapter { padding: 52px 0; }
  .chapter-head { gap: 6px 14px; margin-bottom: 28px; flex-direction: column; }
  .chapter h2 { font-size: 36px; }
  .what-text { font-size: 18px; }
  .growth { gap: 6px; justify-content: flex-start; }
  .growth img { border-width: 1.5px; box-shadow: 3px 3px 0 var(--ink); }
  .growth li:nth-child(1) { --h: 58px; }
  .growth li:nth-child(2) { --h: 76px; }
  .growth li:nth-child(3) { --h: 100px; }
  .growth li:nth-child(4) { --h: 122px; }
  .growth li:nth-child(2) img { box-shadow: 3px 3px 0 var(--ochre); }
  .growth li:nth-child(3) img { box-shadow: 3px 3px 0 var(--pyh); }
  .growth li:nth-child(4) img { box-shadow: 3px 3px 0 var(--tomato); }
  .growth span { font-size: 13px; }

  .contents { padding: 22px 18px 20px; margin-right: 5px; }
  .contents h3 { font-size: 26px; }
  .toc li { grid-template-columns: minmax(0, 1fr) auto; }
  .toc-dots { display: none; }
  .toc-name { font-size: 21px; }
  .toc-num { font-size: 15px; }

  .notebook { padding: 0 14px 32px 0; margin-right: 5px; }
  .notebook::before { left: 14px; }
  .notebook li { grid-template-columns: minmax(0, 1fr); padding: 32px 0 0 30px; }
  .nb-when { padding: 0; font-size: 18px; }
  .nb-what { padding-left: 0; }
  .nb-what h3 { font-size: 24px; }
  .note { margin: 10px 10px 0 4px; padding: 26px 20px 20px; }

  .diff { grid-template-columns: minmax(0, 1fr); }
  .diff li { padding: 22px 0 24px 56px; }
  .diff li::before { font-size: 44px; }
  .diff h3 { font-size: 23px; }
  .diff-wide { padding-right: 0 !important; padding-bottom: 170px !important; min-height: 0; }
  .diff-sova { right: auto; left: 56px; width: 112px; }
  .diff-kot { right: auto; left: 180px; width: 112px; }

  .install { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .leaflet { padding: 20px 18px 18px; margin-right: 5px; }
  .leaflet-android { margin-top: 0; }
  .leaflet h3 { font-size: 28px; }
  .leaflet li { padding-left: 46px; }
  .install-after { font-size: 17px; }

  .ticket { grid-template-columns: minmax(0, 1fr) 64px; transform: none; margin-right: 8px; box-shadow: 6px 6px 0 var(--tomato); }
  .ticket-main { padding: 20px 18px; }
  .ticket-big { font-size: 42px; }
  .ticket ul { font-size: 17px; }
  .ticket-stub span { font-size: 28px; }

  .doc-links { flex-direction: column; gap: 10px; }
  .finale { padding-top: 36px; }
  .finale-row { gap: 16px; }
  .finale-pyh { width: 96px; }
  .finale-row > div { padding-bottom: 32px; }
  .finale-title { font-size: 30px; margin-bottom: 18px; }
  .finale .btn-big { width: auto; font-size: 24px; padding: 16px 16px; }   /* 24 px — крупный текст: белый на зелёном 3,43:1 проходит (нужно 3) */

  .foot-grid { grid-template-columns: minmax(0, 1fr); }
  .doc nav.top { margin-bottom: 28px; font-size: 15px; gap: 4px 16px; }
  .doc nav.top a:first-child { font-size: 21px; }
  .doc main { font-size: 17px; }
  .doc h1 { font-size: clamp(27px, 8vw, 34px); }
  .doc .box, .doc blockquote { padding: 16px 16px; margin-right: 4px; }
  .doc table { font-size: 15px; }
  .doc th, .doc td { padding: 8px 10px; }
}
@media (max-width: 520px) {
  .site-head .btn-small { display: none; }
}

/* знак 0+ в верхней навигации документов */
.doc nav.top { position: relative; }
.doc nav.top .age { position: absolute; right: 0; top: 14px; margin: 0; font-size: 15px; }
