/*
Theme Name: dds_theundergroundeconomythebook.com
Theme URI: https://theundergroundeconomythebook.com/
Author: Дмитрий Савельев
Description: Тема для аналитического ресурса об экономике города и стоимости недвижимости: тёмный кадастровый план, бумажные блоки-выписки, сигнальный оранжевый акцент.
Version: 1.1
Requires at least: 6.0
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ugecon
*/

/* ---------- Шрифты ---------- */
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/jetbrains-mono-cyrillic-400-normal.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/jetbrains-mono-latin-400-normal.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: "JetBrains Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/jetbrains-mono-cyrillic-500-normal.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/jetbrains-mono-latin-500-normal.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: "JetBrains Mono"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/jetbrains-mono-cyrillic-700-normal.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/jetbrains-mono-latin-700-normal.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: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/ibm-plex-sans-cyrillic-400-normal.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/ibm-plex-sans-latin-400-normal.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: "IBM Plex Sans"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/ibm-plex-sans-cyrillic-400-italic.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/ibm-plex-sans-latin-400-italic.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: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/ibm-plex-sans-cyrillic-600-normal.woff2") format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/ibm-plex-sans-latin-600-normal.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 {
    --bg: #0E1626;
    --bg-deep: #0A111E;
    --bg-panel: #111B2C;
    --bg-side: #132036;
    --grid: #2C4A6E;
    --frame: #33557D;
    --frame-soft: #24405F;
    --paper: #E8E0CF;
    --paper-light: #F1EADC;
    --paper-line: #B7AA90;
    --accent: #F26B21;
    --accent-dark: #C9520F;
    --lime: #B8D94A;
    --text: #EDF2F7;
    --text-soft: #C7D2DE;
    --muted: #8FA3B8;
    --ink: #1A2233;
    --ink-muted: #5A6473;
    --layer-land: #D28F5B;
    --layer-infra: #C3C2B0;
    --layer-reg: #8D9BA4;
    --layer-aggl: #B8D94A;
    --layer-build: #5A7397;
    --rent-1: #F9DEC1;
    --rent-2: #FBD1A9;
    --rent-3: #F9B77B;
    --rent-4: #F89449;
    --rent-5: #E96A1B;
    --mono: "JetBrains Mono", "IBM Plex Mono", "Consolas", "Courier New", monospace;
    --sans: "IBM Plex Sans", "Segoe UI", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

/* ---------- Скрытые элементы (до основных стилей) ---------- */
.cookie-banner[hidden] { display: none !important; }

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--mono);
    font-size: 15px;
    line-height: 1.6;
    color: var(--text);
    background-color: var(--bg);
    background-image:
        linear-gradient(rgba(44, 74, 110, 0.28) 1px, transparent 1px),
        linear-gradient(90deg, rgba(44, 74, 110, 0.28) 1px, transparent 1px),
        linear-gradient(rgba(44, 74, 110, 0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(44, 74, 110, 0.12) 1px, transparent 1px);
    background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px;
    background-position: -1px -1px;
}
img { max-width: 100%; height: auto; }
a { color: var(--text); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; transition: color .15s ease; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3, h4, h5, h6 { font-family: var(--mono); font-weight: 500; line-height: 1.2; margin: 1.6em 0 .6em; letter-spacing: -0.01em; overflow-wrap: break-word; hyphens: auto; }
p { margin: 0 0 1em; overflow-wrap: break-word; hyphens: auto; }
ul, ol { margin: 0 0 1em; padding-inline-start: 1.4em; }
table { width: 100%; border-collapse: collapse; margin: 1.4em 0; border: 1px solid var(--frame); font-size: .92em; }
th, td { border: 1px solid var(--frame); padding: .6em .8em; text-align: start; vertical-align: top; }
th { background: var(--bg-side); font-weight: 500; }
blockquote { margin: 1.6em 0; padding: 1.1em 1.4em; background: var(--bg-panel); border: 1px solid var(--frame-soft); border-inline-start: 4px solid var(--accent); }
blockquote p:last-child { margin-bottom: 0; }
code, kbd, pre { font-family: var(--mono); font-size: .92em; }
pre { overflow-x: auto; background: var(--bg-deep); border: 1px solid var(--frame-soft); padding: 1em 1.2em; }
hr { border: 0; border-top: 1px solid var(--frame); margin: 2em 0; }
.screen-reader-text { 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-link { position: absolute; inset-inline-start: 1rem; top: -100px; z-index: 100; background: var(--accent); color: var(--bg); padding: .6rem 1rem; text-decoration: none; }
.skip-link:focus { top: 1rem; }

/* ---------- Контейнер ---------- */
.shell { width: min(92%, 1240px); margin-inline: auto; }
@media (min-width: 961px) {
    .shell { width: min(85%, 1240px); }
}

/* ---------- Кнопки ---------- */
.btn-frame {
    display: inline-block;
    font-family: var(--mono);
    font-size: .88rem;
    font-weight: 500;
    line-height: 1.3;
    color: var(--accent);
    background: transparent;
    border: 2px solid var(--accent);
    border-radius: 0;
    padding: .55rem 1.2rem;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s ease, color .15s ease, transform .15s ease;
}
.btn-frame:hover { background: var(--accent); color: var(--bg); transform: translate(-2px, -2px); box-shadow: 3px 3px 0 var(--lime); }
.btn-small { font-size: .78rem; padding: .4rem .95rem; }

/* ---------- Шапка ---------- */
.topbar { background: var(--bg-deep); border-bottom: 3px solid var(--accent); position: relative; z-index: 5; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem 2.5rem; padding: 1.3rem 0; flex-wrap: wrap; }
.brand { display: flex; align-items: flex-start; gap: 1.1rem; text-decoration: none; color: var(--text); flex: 1 1 520px; min-width: 0; max-width: 820px; }
.brand:hover { color: var(--text); }
.brand-mark { flex: 0 0 72px; width: 72px; height: 72px; display: block; }
.brand-svg, .brand-logo { width: 72px; height: 72px; display: block; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; gap: .35rem; min-width: 0; }
.brand-name { font-size: 1.05rem; font-weight: 500; line-height: 1.32; letter-spacing: .01em; overflow-wrap: break-word; hyphens: auto; }
.brand-desc { font-size: .74rem; line-height: 1.5; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.site-nav { flex: 0 1 auto; }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; }
.nav-list a { display: inline-block; font-size: .9rem; color: var(--text); text-decoration: none; padding: .25rem 0; border-bottom: 2px solid transparent; }
.nav-list a:hover { color: var(--accent); }
.nav-list .current-menu-item > a, .nav-list .current_page_item > a { color: var(--accent); border-bottom-color: var(--accent); }
.nav-toggle { display: none; align-items: center; gap: .6rem; font-family: var(--mono); font-size: .85rem; color: var(--text); background: transparent; border: 2px solid var(--frame); padding: .5rem .9rem; cursor: pointer; }
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after { display: block; width: 18px; height: 2px; background: var(--accent); position: relative; }
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; inset-inline-start: 0; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }

/* ---------- Первый экран ---------- */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--frame-soft); }
.hero-inner { position: relative; z-index: 2; min-height: 430px; display: flex; align-items: center; padding: 3.5rem 0; }
.hero-text { width: 52%; min-width: 0; }
.hero-title { font-size: clamp(2.6rem, 6.2vw, 5.6rem); font-weight: 500; line-height: 1.02; letter-spacing: -0.035em; color: var(--paper); margin: 0 0 1.6rem; max-width: 11ch; text-shadow: 0 2px 0 rgba(10, 17, 30, .6); }
.hero-lead { font-size: 1.12rem; line-height: 1.55; color: var(--text); max-width: 40ch; margin: 0; }
.hero-lead::before { content: ""; display: block; width: 64px; height: 3px; background: var(--accent); margin-bottom: 1.1rem; }
.hero-visual { position: absolute; z-index: 1; top: 0; bottom: 0; inset-inline-end: 0; width: 60%; }
.hero-visual img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 30%); mask-image: linear-gradient(90deg, transparent 0, #000 30%); }

/* ---------- Главная: общие блоки ---------- */
.front-flow { padding: 2.6rem 0 3.5rem; display: flex; flex-direction: column; gap: 2.4rem; }
.front-flow > * { min-width: 0; }
.block-title { font-size: clamp(1.45rem, 2.4vw, 2rem); font-weight: 500; letter-spacing: -0.01em; margin: 0 0 .5rem; }
.block-lead { font-size: .85rem; line-height: 1.55; margin: 0; max-width: 72ch; }
.fs-block { position: relative; }

/* Блок 1 — анатомия цены */
.fs-anatomy { background: rgba(14, 22, 38, .92); border: 2px solid var(--frame); padding: 1.6rem 1.9rem 1.8rem; }
.fs-anatomy .block-title { color: var(--paper); }
.fs-anatomy .block-lead { color: var(--muted); }
.anatomy-head { margin-bottom: 1.4rem; }
.anatomy-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 300px); gap: 2rem; align-items: center; }
.anatomy-chart { display: grid; grid-template-columns: 44px minmax(0, 1fr); height: 250px; min-width: 0; }
.anatomy-scale { display: flex; flex-direction: column; justify-content: space-between; font-size: .72rem; color: var(--text-soft); border-inline-end: 1px solid var(--text-soft); padding-inline-end: .55rem; text-align: end; line-height: 1; background: repeating-linear-gradient(180deg, var(--text-soft) 0 1px, transparent 1px 12.5%) right top / 6px 100% no-repeat; }
.anatomy-bars { display: flex; flex-direction: column; gap: 3px; min-width: 0; padding-inline-start: 3px; }
.layer { flex-basis: 0; min-height: 22px; display: flex; align-items: center; justify-content: center; font-size: .82rem; font-weight: 500; color: var(--ink); border: 1px solid rgba(237, 242, 247, .55); }
.layer span { background: rgba(241, 234, 220, .55); padding: 0 .4rem; line-height: 1.25; }
.layer-land { background-color: var(--layer-land); background-image: repeating-linear-gradient(135deg, rgba(255, 255, 255, .09) 0 2px, transparent 2px 7px); }
.layer-infra { background-color: var(--layer-infra); }
.layer-reg { background-color: var(--layer-reg); }
.layer-aggl { background-color: var(--layer-aggl); background-image: repeating-linear-gradient(135deg, rgba(26, 34, 51, .16) 0 2px, transparent 2px 6px); }
.layer-build { background-color: var(--layer-build); background-image: repeating-linear-gradient(135deg, rgba(237, 242, 247, .16) 0 2px, transparent 2px 6px); }
.anatomy-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .7rem; }
.anatomy-legend li { display: grid; grid-template-columns: 30px minmax(0, 1fr); column-gap: .8rem; align-items: center; }
.swatch { grid-row: span 2; width: 30px; height: 30px; display: block; border: 1px solid rgba(237, 242, 247, .5); }
.legend-name { font-size: 1rem; color: var(--text); line-height: 1.2; }
.legend-note { font-size: .72rem; color: var(--muted); line-height: 1.3; }

/* Блок 2 — карта ренты */
.fs-rentmap { background: var(--paper); color: var(--ink); padding: 1.5rem 1.9rem 1.9rem; border: 1px solid var(--paper-line); box-shadow: inset 0 0 0 6px var(--paper), inset 0 0 0 7px rgba(90, 100, 115, .18); }
.fs-rentmap .block-title { color: var(--ink); }
.fs-rentmap .block-lead { color: var(--ink-muted); }
.rentmap-head { margin-bottom: 1.2rem; }
.rentmap-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 200px); gap: 1.6rem; align-items: end; }
.rentmap-figure { margin: 0; min-width: 0; }
.rentmap-figure img { display: block; width: 100%; height: auto; aspect-ratio: 2114 / 816; object-fit: cover; }
.rentmap-legend ul { list-style: none; margin: 0 0 .9rem; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.rentmap-legend li { display: flex; align-items: center; gap: .7rem; font-size: .78rem; color: var(--ink); line-height: 1.25; }
.rent-swatch { flex: 0 0 32px; width: 32px; height: 32px; border: 1px solid #8C7A60; display: block; }
.rent-1 { background: var(--rent-1); }
.rent-2 { background: var(--rent-2); }
.rent-3 { background: var(--rent-3); }
.rent-4 { background: var(--rent-4); }
.rent-5 { background: var(--rent-5); }
.rentmap-note { font-size: .8rem; color: var(--ink); margin: 0; padding-top: .7rem; border-top: 1px dashed var(--ink-muted); }

/* Последние разборы */
.latest-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.latest-head .block-title { color: var(--paper); }
.latest-all { font-size: .85rem; color: var(--accent); }
.latest-all:hover { color: var(--lime); }

/* ---------- Карточки ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 1.6rem; }
.card-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; background: var(--bg-panel); border: 2px solid var(--frame); padding: .9rem; transition: border-color .15s ease, transform .15s ease; }
.card:hover { border-color: var(--accent); transform: translateY(-3px); }
.card-thumb { position: relative; border: 1px solid #3E5F88; overflow: hidden; background: var(--bg-deep); }
.card-thumb a { display: block; }
.card-thumb img { display: block; width: 100%; height: auto; aspect-ratio: 780 / 426; object-fit: cover; transition: transform .3s ease; }
.card:hover .card-thumb img { transform: scale(1.04); }
.card-pin { position: absolute; top: .5rem; inset-inline-start: .5rem; background: var(--accent); color: var(--bg); font-size: .7rem; font-weight: 700; padding: .15rem .5rem; }
.card-body { flex: 1; display: flex; flex-direction: column; min-width: 0; padding: 1rem .2rem .1rem; }
.card-title { font-size: 1.12rem; font-weight: 500; line-height: 1.3; margin: 0 0 .55rem; }
.card-title a { color: var(--paper); text-decoration: none; }
.card-title a:hover { color: var(--accent); }
.card-excerpt { font-size: .84rem; line-height: 1.55; color: var(--text-soft); margin-bottom: .8rem; }
.card-excerpt p { margin: 0 0 0.5em; background: none; }
.card-excerpt a { color: var(--text-soft); }
.card-foot { margin-top: auto; display: flex; flex-direction: column; align-items: flex-start; gap: .7rem; }
.card-date { font-size: .74rem; color: var(--muted); }

/* ---------- Нижний ряд главной ---------- */
.front-duo { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: 2rem; align-items: stretch; }
.front-duo > * { min-width: 0; }

/* Блок 3 — пять фактов */
.fs-facts { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 190px); gap: 1.4rem; align-items: center; background: rgba(14, 22, 38, .94); border: 2px solid var(--frame); padding: 1.2rem 1.4rem 1.2rem 0; }
.facts-table { min-width: 0; }
.facts-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); border-bottom: 1px solid var(--frame); }
.facts-row:last-child { border-bottom: 0; }
.facts-num { display: flex; align-items: center; justify-content: center; font-size: 2.2rem; font-weight: 500; color: var(--accent); line-height: 1; border-inline-end: 2px solid var(--frame); padding: .9rem 0; }
.facts-cell { padding: .75rem 0 .75rem 1.2rem; min-width: 0; }
.facts-row-head .block-title { color: var(--paper); font-size: clamp(1.3rem, 2vw, 1.7rem); margin-bottom: .45rem; }
.facts-text { font-size: .84rem; line-height: 1.5; color: var(--text-soft); margin: 0; }
.facts-rings { margin: 0; text-align: center; }
.facts-rings img { display: block; width: 100%; max-width: 190px; height: auto; aspect-ratio: 1 / 1; margin: 0 auto .6rem; border-radius: 50%; }
.facts-rings figcaption { font-size: .7rem; line-height: 1.4; color: var(--muted); }

/* Блок 4 — словарь */
.fs-glossary { display: flex; flex-direction: column; background: var(--paper); color: var(--ink); padding: 1.6rem 1.6rem 1.8rem; border: 1px solid var(--paper-line); }
.fs-glossary .block-title { color: var(--ink); font-size: clamp(1.5rem, 2.4vw, 2rem); margin-bottom: 1.1rem; }
.glossary-grid { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: .9rem; margin: 0; }
.term-card { display: flex; flex-direction: column; background: var(--paper-light); border: 2px solid #4A4F5A; border-radius: 4px; padding: 1rem 1rem 1.1rem; min-width: 0; transition: transform .15s ease, box-shadow .15s ease; }
.term-card:hover { transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--accent); }
.term-card dt { font-size: .96rem; letter-spacing: -0.02em; font-weight: 500; color: var(--ink); line-height: 1.25; margin-bottom: .5rem; overflow-wrap: break-word; hyphens: manual; padding-bottom: .45rem; border-bottom: 1px dashed var(--paper-line); }
.term-card dd { margin: 0; font-size: .82rem; line-height: 1.45; color: var(--ink-muted); }

/* ---------- Внутренние страницы ---------- */
.page-wrap { padding: 1.6rem 0 3.5rem; }
.crumbs { font-size: .78rem; color: var(--muted); margin-bottom: 1.6rem; line-height: 1.5; overflow-wrap: break-word; }
.crumbs a { color: var(--text-soft); }
.crumbs a:hover { color: var(--accent); }
.crumbs-sep { color: var(--accent); margin: 0 .35rem; }
.layout-with-sidebar { display: grid; grid-template-columns: minmax(0, 67fr) minmax(0, 27fr); column-gap: 6%; align-items: start; }
.layout-single { display: block; }
.layout-single .content-area { width: 85%; margin-left: auto; margin-right: auto; }
.content-area { min-width: 0; }
.page-head { margin-bottom: 1.8rem; padding-bottom: 1.2rem; border-bottom: 1px solid var(--frame); position: relative; }
.page-head::after { content: ""; position: absolute; inset-inline-start: 0; bottom: -2px; width: 96px; height: 3px; background: var(--accent); }
.page-title { font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 500; line-height: 1.12; letter-spacing: -0.025em; color: var(--paper); margin: 0 0 .6rem; }
.page-intro { color: var(--text-soft); font-size: .92rem; }
.entry-meta { font-size: .8rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.entry-meta a { color: var(--lime); }
.meta-sep { color: var(--accent); }
.entry-cover { margin: 0 0 1.8rem; border: 1px solid var(--frame); }
.entry-cover img { display: block; width: 100%; height: auto; }
.entry-content { font-family: var(--sans); font-size: 1.06rem; line-height: 1.75; color: var(--text-soft); }
.entry-content h2, .entry-content h3, .entry-content h4 { color: var(--paper); }
.entry-content h2 { font-size: 1.6rem; }
.entry-content h2::before { content: ""; display: inline-block; width: 12px; height: 12px; background: var(--accent); margin-inline-end: .6rem; vertical-align: .12em; }
.entry-content h3 { font-size: 1.25rem; }
.entry-content a { color: var(--lime); }
.entry-content a:hover { color: var(--accent); }
.entry-content ul li::marker { color: var(--accent); }
.entry-content ol li::marker { color: var(--accent); font-family: var(--mono); }
.entry-content img { display: block; }
.entry-content figure { margin: 1.6em 0; }
.entry-content figcaption { font-family: var(--mono); font-size: .76rem; color: var(--muted); margin-top: .5rem; }
.entry-content blockquote { font-style: italic; color: var(--text); }
.entry-tags { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2rem; }
.entry-tags a { font-size: .78rem; color: var(--text-soft); border: 1px solid var(--frame); padding: .25rem .6rem; text-decoration: none; }
.entry-tags a:hover { border-color: var(--accent); color: var(--accent); }
.post-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 2.4rem; }
.post-step { display: flex; flex-direction: column; gap: .3rem; padding: 1rem 1.2rem; border: 2px solid var(--frame); background: var(--bg-panel); text-decoration: none; color: var(--paper); font-size: .9rem; min-width: 0; }
.post-step span { font-size: .72rem; color: var(--accent); }
.post-step:hover { border-color: var(--accent); }
.post-step-next { text-align: end; grid-column: 2; }
.empty-note { color: var(--muted); font-size: .92rem; }
.empty-box { background: var(--bg-panel); border: 2px solid var(--frame); padding: 1.4rem 1.6rem; }

/* ---------- Сайдбар ---------- */
.sidebar { background: var(--bg-side); border: 2px solid var(--frame); padding: 1.4rem 1.4rem 1.2rem; color: var(--text-soft); min-width: 0; }
.sidebar .widget { margin-bottom: 1.8rem; }
.sidebar .widget:last-child { margin-bottom: 0; }
.sidebar .widget-title { font-size: 1.05rem; color: var(--paper); margin: 0 0 .9rem; padding-bottom: .5rem; border-bottom: 2px solid var(--accent); }
.sidebar ul { list-style: none; margin: 0; padding: 0; }
.sidebar li { padding: .55rem 0; border-bottom: 1px dashed var(--frame); font-size: .85rem; line-height: 1.45; }
.sidebar li:last-child { border-bottom: 0; }
.sidebar a { color: var(--text); text-decoration: none; }
.sidebar a:hover { color: var(--accent); text-decoration: underline; }
.sidebar .post-date { display: block; font-size: .72rem; color: var(--muted); }
.sidebar p { font-size: .86rem; color: var(--text-soft); }

/* ---------- Пагинация ---------- */
.pager { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: 2.4rem; align-items: center; }
.pager .page-numbers, .pager > a, .pager > span { display: inline-flex; align-items: center; justify-content: center; min-width: 2.5rem; padding: .45rem .75rem; font-family: var(--mono); font-size: .85rem; color: var(--text); background: var(--bg-panel); border: 2px solid var(--frame); text-decoration: none; line-height: 1.2; }
.pager a.page-numbers:hover, .pager > a:hover { border-color: var(--accent); color: var(--accent); }
.pager .page-numbers.current, .pager > span.current { background: var(--accent); border-color: var(--accent); color: var(--bg); font-weight: 700; }
.pager .page-numbers.dots { background: none; border-color: transparent; color: var(--muted); min-width: auto; }

/* ---------- Поиск ---------- */
.search-form { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1.2rem 0; }
.search-field { flex: 1 1 220px; min-width: 0; font-family: var(--mono); font-size: .9rem; color: var(--text); background: var(--bg-deep); border: 2px solid var(--frame); border-radius: 0; padding: .6rem .8rem; }
.search-field::placeholder { color: var(--muted); }
.search-field:focus { border-color: var(--accent); outline: none; }

/* ---------- 404 ---------- */
.notfound { max-width: 720px; padding: 1rem 0 2rem; }
.notfound-code { font-size: clamp(5rem, 16vw, 10rem); font-weight: 700; line-height: 1; margin: 0 0 .5rem; color: transparent; -webkit-text-stroke: 2px var(--accent); letter-spacing: -0.04em; }
.notfound-text { color: var(--text-soft); max-width: 56ch; }

/* ---------- Комментарии ---------- */
.notes { margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--frame); }
.notes-title, .comment-reply-title { font-size: 1.35rem; color: var(--paper); margin: 0 0 1.2rem; }
.notes-list, .notes-list .children { list-style: none; margin: 0; padding: 0; }
.notes-list .children { padding-inline-start: 1.6rem; border-inline-start: 2px solid var(--frame-soft); margin-top: 1rem; }
.note-item { margin-bottom: 1rem; }
.note-body { background: var(--bg-panel); border: 1px solid var(--frame); padding: 1rem 1.2rem; }
.note-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; margin-bottom: .5rem; }
.note-author { font-weight: 500; color: var(--paper); }
.note-date { font-size: .74rem; color: var(--muted); }
.note-wait { font-size: .8rem; color: var(--lime); }
.note-text { font-family: var(--sans); font-size: .95rem; color: var(--text-soft); }
.note-reply a { font-size: .78rem; color: var(--accent); }
.comment-respond { margin-top: 2rem; background: var(--bg-panel); border: 2px solid var(--frame); padding: 1.4rem 1.6rem; }
.comment-reply-title small { margin-inline-start: .8rem; font-size: .75rem; }
.form-row { margin: 0 0 1rem; display: flex; flex-direction: column; gap: .35rem; }
.form-row label { font-size: .8rem; color: var(--text-soft); }
.form-row input[type="text"], .form-row input[type="email"], .form-row input[type="url"], .form-row textarea { width: 100%; font-family: var(--mono); font-size: .9rem; color: var(--text); background: var(--bg-deep); border: 2px solid var(--frame); border-radius: 0; padding: .6rem .8rem; }
.form-row input:focus, .form-row textarea:focus { border-color: var(--accent); outline: none; }
.form-check { flex-direction: row; align-items: flex-start; gap: .6rem; }
.form-check input { margin-top: .3rem; accent-color: var(--accent); }
.form-note { font-size: .78rem; color: var(--muted); }
.form-submit { margin: 0; }
.comments-pagination, .comment-navigation { margin: 1rem 0; font-size: .85rem; }

/* ---------- Подвал ---------- */
.sitefoot { background-color: var(--bg-deep); background-image: linear-gradient(rgba(44, 74, 110, .16) 1px, transparent 1px), linear-gradient(90deg, rgba(44, 74, 110, .16) 1px, transparent 1px); background-size: 48px 48px; border-top: 2px solid var(--frame); color: var(--text-soft); }
.sitefoot-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.4rem; padding: 2.6rem 0 2.2rem; }
.sitefoot-col { min-width: 0; }
.sitefoot .widget { margin-bottom: 1.4rem; }
.sitefoot .widget:last-child { margin-bottom: 0; }
.sitefoot .widget-title { font-size: 1.3rem; font-weight: 500; color: var(--paper); margin: 0 0 .8rem; }
.sitefoot p, .sitefoot .textwidget { font-size: .88rem; line-height: 1.6; color: var(--text-soft); }
.sitefoot ul { list-style: none; margin: 0; padding: 0; }
.sitefoot li { margin-bottom: .35rem; }
.sitefoot a { color: var(--text); font-size: .9rem; }
.sitefoot a:hover { color: var(--accent); }
.sitefoot-copy { border-top: 1px solid var(--frame-soft); padding: 1rem 0; font-size: .74rem; color: var(--muted); text-align: center; }

/* ---------- Cookie-баннер ---------- */
.cookie-banner { position: fixed; z-index: 50; bottom: 1rem; inset-inline-start: 1rem; inset-inline-end: 1rem; max-width: 720px; margin-inline: auto; display: flex; align-items: center; gap: 1rem 1.4rem; flex-wrap: wrap; background: var(--bg-deep); border: 2px solid var(--accent); box-shadow: 6px 6px 0 rgba(242, 107, 33, .25); padding: 1rem 1.3rem; color: var(--text-soft); }
.cookie-text { flex: 1 1 320px; margin: 0; font-size: .8rem; line-height: 1.5; }

/* ---------- Gutenberg-выравнивания ---------- */
.alignleft { float: left; margin: .3em 1.4em 1em 0; }
.alignright { float: right; margin: .3em 0 1em 1.4em; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.wp-caption-text, .wp-element-caption { font-family: var(--mono); font-size: .76rem; color: var(--muted); }
.sticky { position: relative; }

/* ---------- Адаптив ---------- */
@media (max-width: 1100px) {
    .front-duo { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 960px) {
    .topbar-inner { flex-wrap: nowrap; }
    .brand { flex: 1 1 auto; }
    .nav-toggle { display: inline-flex; flex: 0 0 auto; }
    .site-nav { position: absolute; top: 100%; inset-inline-start: 0; inset-inline-end: 0; background: var(--bg-deep); border-bottom: 3px solid var(--accent); display: none; }
    .site-nav.is-open { display: block; }
    .nav-list { flex-direction: column; gap: 0; width: min(92%, 1240px); margin-inline: auto; padding: .6rem 0 1rem; }
    .nav-list a { display: block; padding: .7rem 0; border-bottom: 1px solid var(--frame-soft); }
    .nav-list .current-menu-item > a { border-bottom-color: var(--accent); }
    .hero-inner { min-height: 0; padding: 2.6rem 0 0; }
    .hero-text { width: 100%; }
    .hero-visual { position: relative; width: 100%; height: auto; margin-top: 1.4rem; }
    .hero-visual img { height: auto; aspect-ratio: 1496 / 836; -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 22%); mask-image: linear-gradient(180deg, transparent 0, #000 22%); }
    .anatomy-grid { grid-template-columns: minmax(0, 1fr); }
    .anatomy-legend { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem 1.2rem; }
    .rentmap-grid { grid-template-columns: minmax(0, 1fr); }
    .rentmap-legend ul { flex-direction: row; flex-wrap: wrap; gap: .6rem 1rem; }
    .card-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .layout-with-sidebar { grid-template-columns: minmax(0, 1fr); row-gap: 2.4rem; }
    .layout-single .content-area { width: 100%; }
    .sitefoot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .glossary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
    body { font-size: 14px; }
    .brand-mark { flex-basis: 52px; width: 52px; height: 52px; }
    .brand-svg, .brand-logo { width: 52px; height: 52px; }
    .brand-name { font-size: .86rem; }
    .brand-desc { display: none; }
    .nav-toggle-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .hero-title { font-size: clamp(2.3rem, 11vw, 3.2rem); }
    .hero-lead { font-size: 1rem; }
    .front-flow { gap: 1.8rem; padding-top: 1.8rem; }
    .fs-anatomy { padding: 1.2rem 1.1rem 1.3rem; }
    .anatomy-chart { height: 220px; grid-template-columns: 36px minmax(0, 1fr); }
    .anatomy-legend { grid-template-columns: minmax(0, 1fr); }
    .fs-rentmap { padding: 1.2rem 1.1rem 1.4rem; }
    .card-grid-3 { grid-template-columns: minmax(0, 1fr); }
    .fs-facts { grid-template-columns: minmax(0, 1fr); padding: .6rem 1rem 1.2rem 0; }
    .facts-row { grid-template-columns: 64px minmax(0, 1fr); }
    .facts-num { font-size: 1.6rem; }
    .facts-cell { padding-inline-start: .9rem; }
    .facts-rings { padding-inline-start: 1rem; }
    .fs-glossary { padding: 1.2rem 1.1rem 1.4rem; }
    .glossary-grid { grid-template-columns: minmax(0, 1fr); grid-auto-rows: auto; }
    .sitefoot-cols { grid-template-columns: minmax(0, 1fr); gap: 1.8rem; }
    .post-steps { grid-template-columns: minmax(0, 1fr); }
    .post-step-next { grid-column: auto; }
    .sidebar { padding: 1.1rem; }
    .comment-respond { padding: 1.1rem; }
    .cookie-banner { bottom: .6rem; inset-inline-start: .6rem; inset-inline-end: .6rem; padding: .9rem 1rem; }
}
