/* prokol.kz — тема kz-engine. Правила — DESIGN.md: светлая тема, Geologica, четыре цвета разделов, «разрез грунта». */

@font-face { font-family: "Geologica"; src: url("fonts/geologica-cyrillic-ext.woff2") format("woff2-variations"), url("fonts/geologica-cyrillic-ext.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F; }
@font-face { font-family: "Geologica"; src: url("fonts/geologica-cyrillic.woff2") format("woff2-variations"), url("fonts/geologica-cyrillic.woff2") format("woff2"); font-weight: 100 900; 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: "Geologica"; src: url("fonts/geologica-latin.woff2") format("woff2-variations"), url("fonts/geologica-latin.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; 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; }

/* ---------- токены: hex для старых браузеров, OKLCH — где поддерживается ---------- */
:root {
  color-scheme: light;
  --paper: #f8f5f1; --paper-2: #f1ede6; --line: #d5cec6;
  --ink: #1a2430; --ink-2: #4b535f; --link: #005193;
  --c-docs: #e2832d; --c-docs-ink: #9b4805;
  --c-water: #297ab6; --c-water-ink: #085b97;
  --c-ground: #97724d; --c-ground-ink: #754e2e;
  --c-walls: #3f8066; --c-walls-ink: #1b6047;
  --c: var(--ink-2); --c-ink: var(--ink-2);
  --font: "Geologica", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 74rem;
  --gutter: clamp(16px, 4vw, 40px);
  --measure: 68ch;
  --radius: 10px;
  --ease: cubic-bezier(.2, 0, 0, 1);
}
@supports (color: oklch(0 0 0)) {
  :root {
    --paper: oklch(.972 .006 80); --paper-2: oklch(.946 .010 80); --line: oklch(.855 .014 75);
    --ink: oklch(.255 .028 255); --ink-2: oklch(.44 .022 255); --link: oklch(.43 .13 250);
    --c-docs: oklch(.70 .15 58); --c-docs-ink: oklch(.50 .13 50);
    --c-water: oklch(.56 .12 245); --c-water-ink: oklch(.46 .12 248);
    --c-ground: oklch(.58 .07 65); --c-ground-ink: oklch(.46 .07 60);
    --c-walls: oklch(.55 .08 165); --c-walls-ink: oklch(.44 .08 165);
  }
}
[data-cat="docs"] { --c: var(--c-docs); --c-ink: var(--c-docs-ink); }
[data-cat="water"] { --c: var(--c-water); --c-ink: var(--c-water-ink); }
[data-cat="ground"] { --c: var(--c-ground); --c-ink: var(--c-ground-ink); }
[data-cat="walls"] { --c: var(--c-walls); --c-ink: var(--c-walls-ink); }

/* ---------- основа ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: 1.0625rem; font-weight: 380; line-height: 1.65;
  font-variation-settings: "SHRP" 0; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}
@media (min-width: 900px) { body { font-size: 1.125rem; } }
img, svg { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-weight: 740; font-variation-settings: "SHRP" 60; letter-spacing: -.02em; line-height: 1.15; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2rem, 1.45rem + 2.4vw, 3.25rem); font-weight: 760; }
h2 { font-size: clamp(1.5rem, 1.3rem + .9vw, 1.875rem); }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }
p { margin: 0; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: .18em; transition: color 150ms var(--ease), text-decoration-color 150ms var(--ease); }
:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; border-radius: 3px; }
strong { font-weight: 640; }
small { font-size: .875rem; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 10; padding: 8px 14px; background: var(--ink); color: var(--paper); border-radius: 6px; text-decoration: none; }
.skip:focus { top: 8px; }

/* подпись-метка: прописные, 600, трекинг */
.kicker, .meta, .toc-h, .passport dt, .site-foot h2, .adjacent small, .entry-kick .no, .plot figcaption {
  font-size: .8125rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; line-height: 1.4;
}
.kicker { display: inline-flex; align-items: center; gap: .5em; color: var(--c-ink); text-decoration: none; }
.kicker::before, .site-head .nav a[data-cat]::before, .foot-grid a[data-cat]::before, .hub h2::before, .term-head[data-cat] h1::before, .oops a[data-cat]::before {
  content: ""; flex: none; width: .7em; height: .7em; border-radius: 2px; background: var(--c);
}
.meta { color: var(--ink-2); font-weight: 560; }

/* ---------- полоса «разрез грунта» ---------- */
.strata {
  height: 12px;
  background: linear-gradient(to bottom, #8c6a4a 0 2px, #b89470 2px 5px, #d6bf96 5px 7px, #dccba6 7px 9px, #a8836a 9px 12px);
}

/* ---------- шапка ---------- */
.site-head { background: var(--paper); }
.head-row { display: flex; align-items: center; gap: 16px; min-height: 72px; padding-block: 12px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; min-width: 0; }
.brand-mark { width: 40px; height: 40px; flex: none; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-size: 1.25rem; font-weight: 780; font-variation-settings: "SHRP" 60; letter-spacing: -.02em; line-height: 1.1; }
.brand-tag { font-size: .8125rem; color: var(--ink-2); line-height: 1.3; }
.head-search { position: relative; margin-left: auto; width: min(22rem, 34vw); }
.head-search input, .find input {
  width: 100%; min-height: 44px; padding: 8px 14px; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px;
}
.head-search input { padding-left: 40px; }
.head-search svg { position: absolute; left: 12px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--ink-2); pointer-events: none; }
.head-search input:focus, .find input:focus { outline: 2px solid var(--link); outline-offset: 0; border-color: transparent; }
input::placeholder { color: var(--ink-2); opacity: 1; }
.nav-btn {
  display: none; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; margin-left: auto;
  font: inherit; font-size: 1rem; font-weight: 600; color: var(--ink); background: var(--paper-2);
  border: 1px solid var(--line); border-radius: 8px; cursor: pointer; transition: transform 120ms var(--ease);
}
.nav-btn svg { width: 20px; height: 20px; }
.nav-btn:active, .find button:active { transform: scale(.97); }
.nav { border-top: 1px solid var(--line); }
.nav ul { display: flex; flex-wrap: wrap; gap: 4px 28px; margin: 0; padding: 0; list-style: none; }
.nav a { display: inline-flex; align-items: center; gap: .55em; min-height: 48px; color: var(--ink); font-weight: 560; text-decoration: none; }
.nav li.on > a, .nav a[aria-current] { text-decoration: underline; text-decoration-color: var(--c); text-decoration-thickness: 3px; text-underline-offset: .45em; }
.find.nav-search { display: none; }   /* .find ниже задаёт display: flex — нужна большая специфичность */

@media (max-width: 759px) {
  .brand-tag, .head-search { display: none; }
  .nav-btn { display: inline-flex; }
  .nav .wrap { padding-block: 8px 16px; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav li + li { border-top: 1px solid var(--line); }
  .find.nav-search { display: flex; margin-bottom: 8px; }
  .js .nav[data-open="false"] { display: none; }
}
@media (min-width: 760px) { .nav-btn { display: none; } }

/* ---------- формы поиска ---------- */
.find { display: flex; gap: 8px; max-width: 34rem; }
.find button {
  flex: none; min-height: 44px; padding: 8px 18px; font: inherit; font-size: 1rem; font-weight: 600;
  color: var(--paper); background: var(--ink); border: 0; border-radius: 8px; cursor: pointer; transition: transform 120ms var(--ease);
}

/* ---------- главная ---------- */
.hero { padding-block: clamp(32px, 4vw, 48px) clamp(24px, 3vw, 32px); }
.hero h1 { max-width: 24ch; }
.lead { margin-top: 20px; max-width: 60ch; font-size: clamp(1.125rem, 1.05rem + .35vw, 1.3125rem); color: var(--ink-2); line-height: 1.55; }
.plot { margin: 0 0 clamp(64px, 9vw, 112px); }
.plot-scroll { overflow-x: auto; overscroll-behavior-x: contain; background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius); -webkit-overflow-scrolling: touch; }
.plot-svg { display: block; width: 100%; min-width: 760px; font-family: var(--font); }
.plot-label text, .plot-svg text { font-family: var(--font); font-weight: 500; }
.plot figcaption { margin-top: 12px; color: var(--ink-2); text-transform: none; letter-spacing: 0; font-weight: 500; font-size: .875rem; }
.plot-hint { display: none; font-weight: 600; }
@media (max-width: 809px) { .plot-hint { display: inline; } }   /* разрез 760 px + поля: уже этого — прокрутка */
.pin circle { fill: var(--c-ink); stroke: var(--paper); stroke-width: 3; transition: fill 150ms var(--ease); }
.pin text { fill: var(--paper); font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; pointer-events: none; }
.pin { transform-box: fill-box; transform-origin: center; transition: transform 150ms var(--ease); }
.pin:focus-visible { outline: none; }
.pin:focus-visible circle { stroke: var(--ink); stroke-width: 4; }
.hubs { display: grid; gap: clamp(48px, 6vw, 72px) clamp(32px, 5vw, 64px); }
@media (min-width: 900px) { .hubs { grid-template-columns: 1fr 1fr; } }
.hub h2 { display: flex; align-items: center; gap: 12px; font-size: clamp(1.375rem, 1.25rem + .5vw, 1.625rem); }
.hub h2::before { width: 14px; height: 14px; }
.hub h2 a { color: var(--ink); text-decoration: none; }
.hub-desc { margin-top: 8px; color: var(--ink-2); }
.nums { margin: 20px 0 0; padding: 0; list-style: none; border-bottom: 1px solid var(--line); }
.nums li { border-top: 1px solid var(--line); }
.nums a { display: grid; grid-template-columns: 2.25rem 1fr; gap: 14px; align-items: baseline; padding: 12px 0; color: var(--ink); text-decoration: none; }
.no {
  display: inline-grid; place-items: center; min-width: 2rem; height: 2rem; padding: 0 6px; border-radius: 6px;
  background: var(--c-ink); color: var(--paper); font-size: .9375rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1;
}
.nums .no { transform: translateY(.1em); }
.how { margin-top: clamp(80px, 10vw, 128px); padding-top: 32px; border-top: 1px solid var(--line); }
.how ul { display: grid; gap: 24px; margin: 24px 0 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .how ul { grid-template-columns: repeat(3, 1fr); gap: 40px; } }
.how strong { display: block; margin-bottom: 6px; font-size: 1.125rem; font-weight: 700; }
.how li { color: var(--ink-2); }
.how li strong { color: var(--ink); }

/* ---------- крошки, заголовки списков ---------- */
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0; padding: 24px 0 0; list-style: none; font-size: .875rem; color: var(--ink-2); }
.crumbs li + li::before { content: "/"; margin: 0 .55em; color: var(--line); }
.crumbs a { color: var(--ink-2); }
.term-head { padding-block: 24px 8px; max-width: var(--measure); }
.term-head[data-cat] h1 { display: flex; align-items: baseline; gap: 14px; }
.term-head[data-cat] h1::before { width: 18px; height: 18px; transform: translateY(-.08em); }
.term-head p { margin-top: 12px; color: var(--ink-2); }
.term-page { font-size: .875rem; }
.term-intro { margin-top: 24px; }
.term-empty { margin-top: 24px; color: var(--ink-2); }

/* ---------- строки статей ---------- */
.term-list { margin: 32px 0 0; padding: 0; list-style: none; border-bottom: 1px solid var(--line); }
.row { display: grid; grid-template-columns: 1fr; gap: 6px 16px; padding: 20px 0; border-top: 1px solid var(--line); }
.row:has(> .no) { grid-template-columns: 2.25rem 1fr; }
.row.has-photo { grid-template-columns: 1fr minmax(84px, 8rem); }
.row.has-photo:has(> .no) { grid-template-columns: 2.25rem 1fr minmax(84px, 8rem); }
.row > .no { margin-top: 2px; }
.row-body { min-width: 0; }
.row .kicker { margin-bottom: 4px; }
.story-title { display: block; color: var(--ink); font-size: clamp(1.1875rem, 1.1rem + .4vw, 1.375rem); font-weight: 700; line-height: 1.3; text-decoration: none; text-wrap: pretty; }
.ex { margin-top: 6px; color: var(--ink-2); max-width: var(--measure); font-size: 1rem; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.row .meta { margin-top: 8px; }
.row .photo { display: block; align-self: start; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: var(--paper-2); }
.row .photo img { width: 100%; height: 100%; object-fit: cover; }
.photo-empty { display: block; width: 100%; height: 100%; }

/* ---------- статья ---------- */
.entry-head { padding-block: 24px 0; max-width: 52rem; }
.entry-kick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-bottom: 16px; }
.entry-kick .no { height: auto; min-height: 1.9rem; padding: 4px 10px; font-size: .8125rem; }
.passport { display: flex; flex-wrap: wrap; margin: 28px 0 0; border: 1px solid var(--line); border-radius: 8px; background: var(--paper-2); }
.passport > div { flex: 1 1 9rem; padding: 10px 16px; border-left: 1px solid var(--line); margin-left: -1px; }
.passport > div:first-child { border-left: 0; margin-left: 0; }
.passport dt { color: var(--ink-2); font-size: .75rem; }
.passport dd { margin: 2px 0 0; font-weight: 600; font-variant-numeric: tabular-nums; }
@media (max-width: 479px) {   /* три ячейки одной строкой, как основная надпись, а не 2 + 1 */
  .passport { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .passport > div { padding: 8px 10px; }
  .passport dt { font-size: .6875rem; }
  .passport dd { font-size: .9375rem; }
}
.entry-cover { margin: 32px 0 0; max-width: 52rem; }
.entry-cover .photo { overflow: hidden; border-radius: var(--radius); background: var(--paper-2); }
.entry-cover img { display: block; width: 100%; }
.entry-grid { display: grid; gap: 32px; margin-top: 40px; }
.entry-main { min-width: 0; }
.toc-side { display: none; }
@media (min-width: 1080px) {
  .entry-grid { grid-template-columns: 15rem minmax(0, var(--measure)); gap: 56px; }
  .entry-grid.no-toc { grid-template-columns: minmax(0, var(--measure)); }
  .toc-side { display: block; position: sticky; top: 24px; max-height: calc(100vh - 48px); overflow: auto; }
  .toc-inline { display: none; }
}
.toc ol { margin: 10px 0 0; padding: 0; list-style: none; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a { display: grid; grid-template-columns: 1.6rem 1fr; padding: 6px 0; color: var(--ink-2); font-size: .9375rem; line-height: 1.4; text-decoration: none; }
.toc a::before { content: counter(toc); font-variant-numeric: tabular-nums; color: var(--ink-2); font-weight: 600; }
.toc-h { color: var(--ink-2); }
.toc-inline { margin-bottom: 32px; padding: 4px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper-2); }
.toc-inline summary { min-height: 44px; display: flex; align-items: center; font-weight: 600; cursor: pointer; }
.toc-inline ol { padding-bottom: 12px; }

/* текст статьи */
.prose { max-width: var(--measure); }
.prose > * + * { margin-top: 1em; }
.prose h2 { margin-top: 2.2em; scroll-margin-top: 16px; }
.prose h3 { margin-top: 1.8em; }
.prose h4 { margin-top: 1.5em; }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: .6em; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.prose hr { margin-block: 2.5em; border: 0; height: 12px; background: linear-gradient(to bottom, #8c6a4a 0 2px, #b89470 2px 5px, #d6bf96 5px 7px, #dccba6 7px 9px, #a8836a 9px 12px); border-radius: 2px; }
.prose blockquote { margin-inline: 0; padding: 16px 20px; background: var(--paper-2); border-radius: 8px; }
.prose figure { margin-inline: 0; }
.prose figure img { display: block; border-radius: 8px; border: 1px solid var(--line); background: var(--paper); }
.prose figcaption { margin-top: 8px; font-size: .875rem; color: var(--ink-2); }
.prose img { height: auto; }
/* схема (pk_wrap_figures): ссылка на файл; на телефоне — 960 px в своей прокрутке, подписи ~12 px вместо ~4 */
.prose .fig-wide { display: block; cursor: zoom-in; }
.fig-hint { display: none; }
@media (max-width: 759px) {
  .prose .fig-wide { overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
  .prose .fig-wide img { width: 960px; max-width: none; border: 0; border-radius: 0; }
  .fig-hint { display: block; margin-top: 8px; font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
}
/* таблица шире колонки: тень у края, за которым ещё есть столбцы (фон local прячет тень у крайнего положения) */
.prose .table {
  overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: 8px;
  background:
    linear-gradient(to right, var(--paper) 30%, transparent) left center / 32px 100% no-repeat local,
    linear-gradient(to left, var(--paper) 30%, transparent) right center / 32px 100% no-repeat local,
    radial-gradient(farthest-side at 0 50%, rgb(31 42 55 / .3), transparent) left center / 16px 100% no-repeat scroll,
    radial-gradient(farthest-side at 100% 50%, rgb(31 42 55 / .3), transparent) right center / 16px 100% no-repeat scroll,
    var(--paper);
}
.prose table { width: 100%; border-collapse: collapse; font-size: .9375rem; font-variant-numeric: tabular-nums; line-height: 1.45; }
.prose th, .prose td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.prose th { background: var(--paper-2); font-weight: 640; }
.prose tr:last-child td { border-bottom: 0; }
.page-prose { margin-top: 32px; }

/* источники и соседи */
.sources { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); max-width: var(--measure); }
.sources h2 { font-size: 1.375rem; }
.sources ol { margin: 16px 0 0; padding-left: 1.6em; font-size: .9375rem; line-height: 1.5; }
.sources li { padding-left: .2em; }
.sources li + li { margin-top: 10px; }
.sources li::marker { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.sources a { font-weight: 600; }
.sources span { color: var(--ink); }
.sources small { display: block; color: var(--ink-2); font-size: .8125rem; }
.sources-note { margin-top: 20px; font-size: .9375rem; color: var(--ink-2); }
.adjacent { display: grid; gap: 12px; margin-top: 48px; max-width: var(--measure); }
@media (min-width: 640px) { .adjacent { grid-template-columns: 1fr 1fr; } .adj-next { grid-column: 2; text-align: right; } }
.adjacent a { display: block; padding: 14px 16px; color: var(--ink); text-decoration: none; border: 1px solid var(--line); border-radius: 8px; transition: border-color 150ms var(--ease); }
.adjacent small { display: block; color: var(--ink-2); margin-bottom: 4px; }
.adjacent span { font-weight: 600; line-height: 1.35; }
.more { margin-top: clamp(64px, 8vw, 96px); }
.band-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.band-head h2 { font-size: clamp(1.375rem, 1.25rem + .5vw, 1.625rem); }
.more .term-list { margin-top: 20px; }

/* ---------- пагинация, 404, страницы ---------- */
.pager { display: flex; flex-wrap: wrap; gap: 8px; margin: 32px 0 0; padding: 0; list-style: none; }
.pager a, .pager span { display: inline-grid; place-items: center; min-width: 44px; min-height: 44px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); text-decoration: none; font-variant-numeric: tabular-nums; }
.pager [aria-current] { background: var(--ink); border-color: var(--ink); color: var(--paper); font-weight: 600; }
.pager .gap { border-color: transparent; }
.oops { padding-block: clamp(40px, 7vw, 80px) 0; max-width: 44rem; }
.oops > * + * { margin-top: 20px; }
.oops p { color: var(--ink-2); }
.oops h2 { font-size: 1.25rem; margin-top: 32px; }
.oops ul { margin: 12px 0 0; padding: 0; list-style: none; }
.oops nav ul { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 24px; }
.oops nav a { display: inline-flex; align-items: center; gap: .5em; min-height: 44px; font-weight: 560; color: var(--ink); }
.suggest li + li { margin-top: 6px; }
.oops-search { padding-top: 24px; }
.find + .term-list, .term-head + .find { margin-top: 24px; }
.subpages { margin: 32px 0 0; padding: 0; list-style: none; border-bottom: 1px solid var(--line); }
.subpages a { display: block; padding: 14px 0; border-top: 1px solid var(--line); font-weight: 600; }
.ad-slot { margin-block: 32px; min-height: 280px; }
.ad-slot::before { content: "Реклама"; display: block; margin-bottom: 6px; color: var(--ink-2); font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.ad-slot ins { display: block; }
@media (min-width: 760px) { .ad-slot { min-height: 120px; } }

/* ---------- подвал ---------- */
.site-foot { margin-top: clamp(80px, 10vw, 128px); background: var(--paper-2); }
.foot-grid { display: grid; gap: 32px; padding-block: 40px 32px; }
@media (min-width: 900px) { .foot-grid { grid-template-columns: 2fr 1fr 1fr; gap: 56px; } }
.foot-about p { margin-top: 14px; max-width: 46ch; color: var(--ink-2); font-size: .9375rem; }
.foot-about .foot-note { font-size: .875rem; }
.site-foot h2 { color: var(--ink-2); letter-spacing: .06em; font-variation-settings: "SHRP" 0; }
.site-foot ul { margin: 12px 0 0; padding: 0; list-style: none; }
.site-foot nav a { display: inline-flex; align-items: center; gap: .55em; min-height: 40px; color: var(--ink); text-decoration: none; font-size: .9375rem; }
.foot-base { padding-block: 16px 24px; border-top: 1px solid var(--line); font-size: .875rem; color: var(--ink-2); }

/* ---------- наведение — только мышь ---------- */
@media (hover: hover) and (pointer: fine) {
  a:hover { color: var(--ink); }
  .story-title:hover, .nums a:hover .t, .hub h2 a:hover, .site-foot nav a:hover, .nav a:hover { color: var(--link); }
  .nums a:hover .t, .story-title:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .18em; }
  .kicker:hover { color: var(--ink); }
  .adjacent a:hover { border-color: var(--ink-2); }
  .pager a:hover { border-color: var(--ink-2); }
  .toc a:hover { color: var(--ink); }
  .pin:hover { transform: scale(1.12); }
  .pin:hover circle { fill: var(--ink); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; }
  .pin:hover, .nav-btn:active, .find button:active { transform: none; }
}

@media print {
  .site-head .nav, .head-search, .nav-btn, .strata, .site-foot, .adjacent, .more, .toc { display: none !important; }
  body { background: none; font-size: 11pt; }
  .entry-grid { display: block; }
  .sources a::after { content: " (" attr(href) ")"; font-weight: 400; word-break: break-all; }
}
