/*
Theme Name: dds_lovetodoula.com
Theme URI: https://lovetodoula.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: ltdoula
*/

/* ---------- Шрифты (SIL OFL) ---------- */
@font-face { font-family: "Marck Script"; src: url("fonts/marck-script-cyrillic-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Marck Script"; src: url("fonts/marck-script-latin-400-normal.woff2") format("woff2"); font-weight: 400; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Lora"; src: url("fonts/lora-cyrillic-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Lora"; src: url("fonts/lora-latin-400-normal.woff2") format("woff2"); font-weight: 400; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Lora"; src: url("fonts/lora-cyrillic-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Lora"; src: url("fonts/lora-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Lora"; src: url("fonts/lora-cyrillic-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Lora"; src: url("fonts/lora-latin-600-normal.woff2") format("woff2"); font-weight: 600; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Lora"; src: url("fonts/lora-cyrillic-700-normal.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Lora"; src: url("fonts/lora-latin-700-normal.woff2") format("woff2"); font-weight: 700; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Caveat"; src: url("fonts/caveat-cyrillic-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Caveat"; src: url("fonts/caveat-latin-400-normal.woff2") format("woff2"); font-weight: 400; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Caveat"; src: url("fonts/caveat-cyrillic-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Caveat"; src: url("fonts/caveat-latin-600-normal.woff2") format("woff2"); font-weight: 600; 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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---------- Палитра ---------- */
:root {
    --paper: #F2E8D5;
    --sheet: #F8F1E2;
    --sheet-2: #EDE3CD;
    --side: #EADFC6;
    --ink: #22304A;
    --ink-2: #1B2740;
    --text: #2B2B2B;
    --muted: #8A7B66;
    --muted-dark: #6E604D;
    --coral: #D96C5B;
    --coral-dark: #BF5747;
    --sage: #7C9070;
    --sage-dark: #56694B;
    --mustard: #D6A84B;
    --pencil: #B9A98F;
    --tape: rgba(222, 205, 168, .78);
    --hand: "Marck Script", "Segoe Script", "Brush Script MT", cursive;
    --note: "Caveat", "Marck Script", "Segoe Print", cursive;
    --body: "Lora", "PT Serif", Georgia, "Times New Roman", serif;
    --wave: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='10' viewBox='0 0 40 10'%3E%3Cpath d='M0 5 Q5 1 10 5 T20 5 T30 5 T40 5' fill='none' stroke='%237C9070' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E");
}

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

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--body);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background-color: var(--paper);
    background-image:
        linear-gradient(rgba(185, 169, 143, .13) 1px, transparent 1px),
        linear-gradient(90deg, rgba(185, 169, 143, .13) 1px, transparent 1px),
        url("images/paper.jpg");
    background-size: 22px 22px, 22px 22px, 680px 220px;
}

h1, h2, h3, h4, h5, h6 { margin: 0 0 .6em; line-height: 1.25; color: var(--ink); overflow-wrap: break-word; hyphens: auto; }
p { margin: 0 0 1em; overflow-wrap: break-word; hyphens: auto; }
img { max-width: 100%; height: auto; }
a { color: var(--sage-dark); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; transition: color .2s ease; }
a:hover { color: var(--coral-dark); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--mustard); outline-offset: 2px; }
ul, ol { padding-left: 1.3em; }
figure { margin: 0; }

.screen-reader-text {
    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-to { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--mustard); color: var(--ink); padding: .6rem 1rem; }
.skip-to:focus { left: 1rem; top: 1rem; }

.shell { width: min(94%, 1320px); margin-inline: auto; }

/* ---------- Шапка ---------- */
.cover {
    background-color: var(--ink);
    background-image:
        repeating-linear-gradient(0deg, rgba(255, 255, 255, .025) 0 1px, transparent 1px 3px),
        repeating-linear-gradient(90deg, rgba(0, 0, 0, .06) 0 1px, transparent 1px 4px);
    color: var(--paper);
    padding: 1.4rem 0 1.6rem;
}
.cover-row { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: flex; align-items: center; gap: 1.2rem; text-decoration: none; color: var(--paper); min-width: 0; }
.brand:hover { color: var(--paper); }
.brand-mark { flex: 0 0 auto; display: block; }
.brand-house { display: block; width: 116px; height: auto; filter: drop-shadow(0 2px 0 rgba(0, 0, 0, .25)); }
.brand-logo { display: block; max-width: 116px; max-height: 110px; width: auto; height: auto; }
.brand-text { display: flex; flex-direction: column; min-width: 0; max-width: 560px; }
.brand-name {
    font-family: var(--hand);
    font-size: clamp(1.3rem, 2vw, 1.9rem);
    line-height: 1.15;
    color: #F6EEDC;
    overflow-wrap: break-word;
    display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.brand-tagline { margin-top: .45rem; font-size: .92rem; line-height: 1.45; color: #D7CCB5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

.main-nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem 1.8rem; }
.main-nav-list a {
    display: inline-block;
    color: #F2E8D5;
    text-decoration: none;
    font-size: 1.04rem;
    padding: .3rem 0 .35rem;
    border-bottom: 3px solid transparent;
    transition: border-color .2s ease, color .2s ease, transform .2s ease;
}
.main-nav-list a:hover { color: #FFFFFF; border-bottom-color: var(--mustard); transform: translateY(-1px); }
.main-nav-list .current-menu-item > a,
.main-nav-list .current_page_item > a { border-bottom-color: var(--sage); }

.nav-toggle {
    display: none;
    align-items: center; gap: .6rem;
    background: var(--paper); color: var(--ink);
    border: 0; padding: .55rem 1rem .6rem;
    font-family: var(--hand); font-size: 1.15rem; cursor: pointer;
    clip-path: polygon(0 6%, 12% 0, 30% 5%, 52% 0, 74% 4%, 100% 0, 98% 52%, 100% 100%, 76% 95%, 50% 100%, 24% 96%, 0 100%, 2% 50%);
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after { display: block; width: 20px; height: 2px; background: var(--ink); position: relative; content: ""; }
.nav-toggle-bars::before { position: absolute; top: -6px; }
.nav-toggle-bars::after { position: absolute; top: 6px; }

/* Полоса закладок */
.tab-strip {
    display: flex; align-items: flex-start; gap: 6px;
    height: 34px; overflow: hidden;
    padding-inline: 2.4%;
    background: linear-gradient(to bottom, var(--ink) 0 46%, transparent 46%);
}
.tab-strip span {
    flex: 1 1 0; min-width: 0; height: 30px; margin-top: 2px;
    background: var(--mustard);
    clip-path: polygon(2% 8%, 20% 0, 46% 6%, 70% 1%, 98% 5%, 100% 60%, 97% 100%, 74% 94%, 50% 100%, 26% 95%, 0 100%, 1% 48%);
    opacity: .92;
}
.tab-strip span:nth-child(3n+1) { background: #C99A44; flex-grow: 1.3; }
.tab-strip span:nth-child(3n+2) { background: #93A585; flex-grow: 1.1; }
.tab-strip span:nth-child(4n) { background: #E07A66; }
.tab-strip span:nth-child(5n) { background: #EFE3CB; flex-grow: 1.4; }
.tab-strip span:nth-child(7n) { background: #7C9070; flex-grow: .8; }
.tab-strip span:nth-child(odd) { margin-top: 5px; }

/* Дневник: кольца переплёта */
.journal { position: relative; overflow-x: clip; }
.journal::before {
    content: "";
    position: absolute; left: 4px; top: 0; bottom: 0; width: 18px;
    background: radial-gradient(circle at 9px 13px, transparent 3.5px, #8A7B66 3.6px 5px, transparent 5.2px) 0 0 / 18px 26px repeat-y;
    opacity: .75;
    pointer-events: none;
}

/* ---------- Общие элементы ---------- */
.hand-title {
    display: inline-block;
    font-family: var(--hand);
    font-weight: 400;
    font-size: clamp(2rem, 3.4vw, 3rem);
    line-height: 1.15;
    color: var(--ink);
    margin: 0 0 1.6rem;
    padding-bottom: .35em;
    background: var(--wave) left bottom / 40px 10px repeat-x;
    transform: rotate(-1deg);
    transform-origin: left center;
    hyphens: manual;
    overflow-wrap: normal;
}
.hand-title-page { font-size: clamp(1.9rem, 3vw, 2.7rem); }
.hand-title-small { font-size: clamp(1.6rem, 2.4vw, 2.1rem); }

.tape {
    position: absolute; z-index: 3;
    width: 92px; height: 30px;
    background: var(--tape);
    box-shadow: 0 1px 0 rgba(138, 123, 102, .18);
    clip-path: polygon(0 8%, 6% 0, 12% 10%, 18% 0, 82% 0, 88% 9%, 94% 0, 100% 10%, 100% 92%, 94% 100%, 88% 91%, 82% 100%, 18% 100%, 12% 90%, 6% 100%, 0 90%);
    pointer-events: none;
}
.tape-tl { top: -10px; left: -26px; transform: rotate(-38deg); }
.tape-tr { top: -10px; right: -26px; transform: rotate(36deg); }
.tape-bl { bottom: -8px; left: -24px; transform: rotate(32deg); }
.tape-br { bottom: -8px; right: -24px; transform: rotate(-34deg); }
.tape-top { top: -14px; left: 50%; transform: translateX(-50%) rotate(-2deg); width: 110px; }

.paper-btn {
    display: inline-block;
    background: var(--coral);
    color: #FFF7EC;
    font-family: var(--hand);
    font-size: 1.2rem;
    line-height: 1.2;
    text-decoration: none;
    padding: .5rem 1.4rem .6rem;
    border: 0;
    cursor: pointer;
    clip-path: polygon(0 6%, 9% 0, 23% 5%, 41% 0, 60% 6%, 79% 0, 100% 4%, 98% 30%, 100% 62%, 97% 100%, 78% 95%, 58% 100%, 37% 94%, 18% 100%, 0 96%, 2% 64%, 0 34%);
    transition: background-color .2s ease, transform .2s ease;
}
.paper-btn:hover { background: var(--coral-dark); color: #FFFFFF; transform: translate(-1px, -2px) rotate(-1deg); }
.paper-btn-small { font-size: 1.08rem; padding: .4rem 1.1rem .5rem; }

.empty-note { font-style: italic; color: var(--muted-dark); }

/* ---------- Главная ---------- */
.front-wrap { width: 85%; margin-inline: auto; padding: 2.6rem 0 3.4rem; }
.spread { position: relative; padding: 2.6rem 0 3rem; }
.spread + .spread,
.spread + .spread-pair,
.spread-pair .spread + .spread { border-top: 0; }
.spread + .spread::before,
.spread + .spread-pair::before {
    content: "";
    position: absolute; left: -4%; right: -4%; top: 0; height: 10px;
    background:
        linear-gradient(to bottom, rgba(185, 169, 143, .55), rgba(185, 169, 143, 0)),
        var(--sheet-2);
    clip-path: polygon(0 0, 100% 0, 100% 30%, 92% 60%, 78% 35%, 63% 70%, 48% 40%, 33% 75%, 18% 45%, 6% 70%, 0 40%);
    opacity: .7;
}
.spread-pair { position: relative; display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.3fr); gap: 3rem; padding-top: .4rem; }
.spread-pair .spread { padding-top: 2.6rem; }
.spread-pair .hand-title { font-size: clamp(1.8rem, 2.5vw, 2.5rem); }

/* Блок 1: карта района */
.district-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, .95fr);
    gap: 2.6rem;
    align-items: center;
}
.taped-photo {
    position: relative;
    background: #FBF6EA;
    padding: 14px;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .22), 0 8px 18px -12px rgba(43, 43, 43, .35);
}
.taped-photo img { display: block; width: 100%; height: auto; object-fit: cover; }
.taped-photo-map { transform: rotate(-1.4deg); }
.taped-photo-map img { aspect-ratio: 1000 / 638; }
.taped-photo-yard { transform: rotate(2.2deg); }
.taped-photo-yard img { aspect-ratio: 800 / 839; }

.district-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.25rem; }
.district-list li { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 1rem; align-items: start; }
.district-icon { display: block; width: 46px; height: 46px; }
.district-list h3 { font-size: 1.1rem; font-weight: 600; margin: 0 0 .2rem; color: var(--text); }
.district-list p { margin: 0; font-size: .97rem; line-height: 1.5; }

/* Блок 2: планировка */
.plan-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 3rem; align-items: start; }
.plan-sheet {
    position: relative;
    background-color: #EFE8D8;
    background-image: radial-gradient(ellipse at 30% 30%, rgba(255, 255, 255, .55), transparent 60%), radial-gradient(ellipse at 80% 90%, rgba(185, 169, 143, .28), transparent 55%);
    padding: 2.4rem 2rem;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .22);
    clip-path: polygon(0 1%, 18% 0, 46% 1.2%, 72% 0, 100% 1%, 99.5% 40%, 100% 99%, 70% 100%, 40% 99%, 12% 100%, 0 99%, .5% 55%);
}
.plan-sheet .tape-tr { top: 2px; right: auto; left: 46%; transform: rotate(-4deg); }
.plan-figure { width: 56%; margin-inline: auto; position: relative; z-index: 1; }
.plan-figure img { display: block; width: 100%; height: auto; aspect-ratio: 900 / 770; object-fit: cover; mix-blend-mode: multiply; }
.plan-label { position: absolute; z-index: 2; font-family: var(--note); font-size: 1.55rem; line-height: 1.1; color: var(--ink); max-width: 9.5em; }
.plan-label-tl { left: 4%; top: 8%; }
.plan-label-tr { right: 3%; top: 6%; text-align: right; }
.plan-label-bl { left: 4%; bottom: 10%; }
.plan-label-br { right: 4%; bottom: 8%; text-align: right; }
.plan-arrows { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; pointer-events: none; }
.plan-arrows path { fill: none; stroke: var(--ink); stroke-width: 1.3; stroke-linecap: round; vector-effect: non-scaling-stroke; opacity: .8; }

.plan-notes { display: grid; gap: 1.4rem; }
.torn-note {
    position: relative;
    background: var(--sheet);
    padding: 1.3rem 1.6rem 1.4rem;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .2);
    clip-path: polygon(0 4%, 8% 0, 21% 3%, 37% 0, 55% 4%, 73% 0, 89% 3%, 100% 0, 99% 50%, 100% 96%, 86% 100%, 68% 96%, 50% 100%, 31% 96%, 14% 100%, 0 96%, 1% 50%);
    transform: rotate(.6deg);
}
.torn-note-tilt { transform: rotate(-.8deg); margin-left: .6rem; }
.torn-note p { margin: .7rem 0 0; font-size: 1rem; line-height: 1.5; }
.note-tag {
    display: inline-block;
    font-family: var(--hand);
    font-size: 1.3rem;
    line-height: 1.2;
    padding: .2rem 1rem .3rem;
    transform: rotate(-2deg);
    clip-path: polygon(0 8%, 14% 0, 40% 6%, 66% 0, 100% 5%, 97% 50%, 100% 95%, 70% 100%, 38% 94%, 10% 100%, 0 92%, 3% 50%);
}
.note-tag-sage { background: var(--sage); color: #FAF4E6; }
.note-tag-mustard { background: var(--mustard); color: var(--ink); }
.note-tag-coral { background: var(--coral); color: #FFF7EC; }

/* Карточки записей */
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.4rem 2rem; }
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--sheet);
    padding: 14px 14px 0;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .22);
    transition: transform .25s ease;
}
.card::after {
    content: "";
    position: absolute; right: 0; bottom: 0;
    width: 28px; height: 28px;
    background: linear-gradient(315deg, var(--paper) 0 50%, #E2D4B7 50% 100%);
    box-shadow: -2px -2px 3px rgba(138, 123, 102, .18);
}
.card:nth-child(3n+1) { transform: rotate(-.7deg); }
.card:nth-child(3n+2) { transform: rotate(.6deg); }
.card:nth-child(3n) { transform: rotate(-.4deg); }
.card:hover { transform: rotate(0deg) translateY(-4px); }
.card-tape {
    position: absolute; z-index: 3; top: -13px; left: 50%;
    width: 96px; height: 28px;
    transform: translateX(-50%) rotate(-3deg);
    background: var(--tape);
    clip-path: polygon(0 10%, 5% 0, 10% 10%, 15% 0, 85% 0, 90% 10%, 95% 0, 100% 10%, 100% 90%, 95% 100%, 90% 90%, 85% 100%, 15% 100%, 10% 90%, 5% 100%, 0 90%);
}
.card-thumb { position: relative; overflow: hidden; background: var(--sheet-2); }
.card-thumb a { display: block; }
.card-thumb img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 7; object-fit: cover; filter: saturate(.92) sepia(.08); }
.card-body { flex: 1; display: flex; flex-direction: column; padding: 1.1rem .4rem 1.3rem; min-width: 0; }
.card-pin { align-self: flex-start; font-family: var(--hand); font-size: 1rem; background: var(--mustard); color: var(--ink); padding: .05rem .7rem .15rem; margin-bottom: .5rem; }
.card-title { font-size: 1.12rem; font-weight: 600; line-height: 1.35; margin: 0 0 .55rem; }
.card-title a { color: var(--text); text-decoration: none; }
.card-title a:hover { color: var(--coral-dark); }
.card-excerpt { font-size: .96rem; line-height: 1.55; margin-bottom: 1rem; }
.card-excerpt p { margin: 0 0 .5em; background: none; }
.card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.card-date { font-size: .86rem; color: var(--muted-dark); }

.latest-more { margin: 2.4rem 0 0; text-align: center; }

/* Блок 3: архив */
.archive-box { position: relative; container-type: inline-size; }
.archive-box img { display: block; width: 100%; height: auto; aspect-ratio: 900 / 642; object-fit: cover; mix-blend-mode: multiply; }
.archive-card {
    position: absolute;
    left: 25%; top: 27%; width: 63%;
    transform: rotate(-2.2deg);
    color: var(--ink);
}
.archive-card-list { list-style: none; margin: 0 0 .6em; padding: 0; }
.archive-card-list li { font-family: var(--hand); font-size: 6.2cqw; line-height: 1.22; }
.archive-card-list li::before { content: "•"; color: var(--sage); margin-right: .3em; }
.archive-card p { margin: 0; font-size: 3.15cqw; line-height: 1.42; color: var(--text); hyphens: manual; }

/* Блок 4: лента первого года */
.year-scroll { overflow-x: auto; overflow-y: hidden; padding: 18px 26px 18px 10px; margin: -18px -26px -18px -10px; }
.year-ribbon { position: relative; container-type: inline-size; transform: rotate(-.6deg); }
.year-ribbon img { display: block; width: 100%; height: auto; aspect-ratio: 1400 / 528; object-fit: cover; mix-blend-mode: multiply; }
.year-ribbon .tape-tr { top: -12px; right: -14px; }
.year-ribbon .tape-bl { bottom: -6px; left: -14px; }
.ribbon-month, .ribbon-mark { position: absolute; z-index: 2; transform: translate(-50%, -50%) rotate(-2.4deg); white-space: nowrap; }
.ribbon-month { font-size: 1.95cqw; color: var(--muted-dark); }
.ribbon-mark { font-family: var(--note); font-size: 2.9cqw; color: var(--sage-dark); }
.year-caption { margin: 1.4rem 0 0; font-size: .95rem; color: var(--muted-dark); max-width: 46em; }

/* ---------- Внутренние страницы ---------- */
.inner-wrap { padding: 1.8rem 0 4rem; }
.crumbs { font-size: .9rem; color: var(--muted-dark); margin: 0 0 1.8rem; padding-left: 1.2rem; }
.crumbs a { color: var(--sage-dark); }
.crumbs-sep { margin: 0 .35rem; color: var(--pencil); }
.crumbs-current { color: var(--text); }

.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; }
.layout-with-sidebar .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.page-head { margin-bottom: 2.2rem; }
.page-sub, .page-intro { color: var(--muted-dark); }

.entry-sheet {
    position: relative;
    background: var(--sheet);
    padding: 2.6rem 3rem 2.4rem;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .22);
    clip-path: polygon(0 .6%, 22% 0, 48% .5%, 76% 0, 100% .4%, 99.6% 50%, 100% 99.5%, 74% 100%, 46% 99.4%, 20% 100%, 0 99.5%, .4% 50%);
}
.entry-sheet .tape-top { top: 0; }
.entry-head { margin-bottom: 1.4rem; }
.entry-meta { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; font-size: .9rem; color: var(--muted-dark); }
.entry-cat a { color: var(--sage-dark); }
.entry-cover { margin: 0 0 1.8rem; background: #FBF6EA; padding: 12px; transform: rotate(-.5deg); box-shadow: 0 2px 0 rgba(138, 123, 102, .2); }
.entry-cover img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }

.entry-content { font-size: 1.04rem; line-height: 1.75; }
.entry-content > * { max-width: 100%; }
.entry-content h2 { font-family: var(--hand); font-weight: 400; font-size: 2rem; margin: 2rem 0 .8rem; }
.entry-content h3 { font-size: 1.3rem; margin: 1.8rem 0 .7rem; }
.entry-content h4 { font-size: 1.1rem; margin: 1.5rem 0 .6rem; }
.entry-content ul { list-style: none; padding-left: 1.4em; }
.entry-content ul li { position: relative; margin-bottom: .45em; }
.entry-content ul li::before { content: ""; position: absolute; left: -1.1em; top: .72em; width: .5em; height: .5em; background: var(--sage); transform: rotate(45deg); }
.entry-content ol li { margin-bottom: .45em; }
.entry-content ol li::marker { color: var(--coral-dark); font-weight: 600; }
.entry-content blockquote {
    margin: 1.8rem 0;
    padding: 1.2rem 1.6rem 1.2rem 1.8rem;
    background: #F1E6CC;
    border-left: 5px solid var(--mustard);
    font-style: italic;
    transform: rotate(-.4deg);
}
.entry-content blockquote p:last-child { margin-bottom: 0; }
.entry-content img { display: block; height: auto; }
.entry-content figure { margin: 1.6rem 0; }
.entry-content figcaption { font-size: .88rem; color: var(--muted-dark); margin-top: .5rem; font-style: italic; }
.entry-content table { width: 100%; border-collapse: collapse; margin: 1.6rem 0; font-size: .95rem; border: 1px solid var(--pencil); display: block; overflow-x: auto; }
.entry-content th, .entry-content td { border: 1px solid var(--pencil); padding: .6rem .8rem; text-align: left; vertical-align: top; }
.entry-content th { background: #EADFC6; color: var(--ink); font-weight: 600; }
.entry-content tr:nth-child(even) td { background: rgba(234, 223, 198, .35); }
.entry-content pre { overflow-x: auto; background: #EFE6D3; padding: 1rem; font-size: .9rem; }
.entry-content hr { border: 0; height: 10px; background: var(--wave) center / 40px 10px repeat-x; margin: 2rem 0; }
.page-links { margin-top: 1.4rem; display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }

.entry-tags { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .5rem; }
.entry-tags a { background: #EDE0C2; color: var(--ink); text-decoration: none; padding: .2rem .8rem; font-size: .88rem; }
.entry-tags a:hover { background: var(--mustard); }

.entry-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; margin: 2.4rem 0; }
.entry-nav a { display: block; background: var(--sheet); padding: 1rem 1.3rem; text-decoration: none; color: var(--text); box-shadow: 0 2px 0 rgba(138, 123, 102, .2); transition: transform .2s ease; }
.entry-nav a:hover { transform: translateY(-3px) rotate(-.5deg); }
.entry-nav span { display: block; font-family: var(--hand); font-size: 1.15rem; color: var(--coral-dark); margin-bottom: .2rem; }
.entry-nav-next { grid-column: 2; text-align: right; }

/* Сайдбар */
.sidebar {
    position: relative;
    min-width: 0;
    background-color: var(--side);
    background-image: repeating-linear-gradient(transparent 0 29px, rgba(185, 169, 143, .35) 29px 30px);
    padding: 2.2rem 1.6rem 1.6rem;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .22);
    color: var(--text);
}
.sidebar::before {
    content: ""; position: absolute; top: -12px; left: 50%; width: 100px; height: 28px;
    transform: translateX(-50%) rotate(2deg); background: var(--tape);
}
.sidebar .widget { margin-bottom: 2rem; }
.sidebar .widget:last-child { margin-bottom: 0; }
.sidebar .widget-title { font-family: var(--hand); font-weight: 400; font-size: 1.7rem; color: var(--ink); margin-bottom: .8rem; padding-bottom: .25em; background: var(--wave) left bottom / 32px 8px repeat-x; }
.sidebar ul { list-style: none; margin: 0; padding: 0; }
.sidebar li { padding: .45rem 0; border-bottom: 1px dashed var(--pencil); line-height: 1.45; }
.sidebar li:last-child { border-bottom: 0; }
.sidebar a { color: var(--sage-dark); text-decoration: none; }
.sidebar a:hover { color: var(--coral-dark); text-decoration: underline; }
.sidebar .post-date { display: block; font-size: .82rem; color: var(--muted-dark); }
.sidebar p, .sidebar .textwidget { color: var(--text); }

/* Пагинация */
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 3rem; }
.pager .page-numbers {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 2.6rem; padding: .4rem .8rem;
    background: var(--sheet);
    color: var(--ink);
    text-decoration: none;
    font-size: .98rem;
    box-shadow: 0 2px 0 rgba(138, 123, 102, .25);
    clip-path: polygon(0 6%, 30% 0, 70% 5%, 100% 0, 97% 50%, 100% 100%, 64% 95%, 30% 100%, 0 96%, 3% 50%);
    transition: background-color .2s ease, transform .2s ease;
}
.pager a.page-numbers:hover { background: var(--mustard); transform: translateY(-2px); }
.pager .page-numbers.current { background: var(--coral); color: #FFF7EC; font-weight: 600; }
.pager .page-numbers.dots { background: none; box-shadow: none; clip-path: none; min-width: auto; }
.pager .prev, .pager .next { font-family: var(--hand); font-size: 1.12rem; }

/* Поиск */
.search-slip { display: flex; gap: .6rem; margin: 1.2rem 0; max-width: 520px; }
.search-slip-field {
    flex: 1; min-width: 0;
    padding: .65rem .9rem;
    font: inherit; color: var(--text);
    background: #FFFBF2;
    border: 1px solid var(--pencil);
    border-radius: 0;
}
.search-slip-btn {
    font-family: var(--hand); font-size: 1.15rem;
    background: var(--sage); color: #FAF4E6;
    border: 0; padding: .5rem 1.3rem; cursor: pointer;
    clip-path: polygon(0 6%, 30% 0, 70% 5%, 100% 0, 97% 50%, 100% 100%, 64% 95%, 30% 100%, 0 96%, 3% 50%);
    transition: background-color .2s ease;
}
.search-slip-btn:hover { background: var(--sage-dark); }
.empty-sheet { background: var(--sheet); padding: 2rem 2.2rem; }

/* 404 */
.lost-sheet { text-align: center; }
.lost-code { font-family: var(--hand); font-size: clamp(4rem, 10vw, 7rem); line-height: 1; color: var(--coral); margin: .5rem 0 .2rem; }
.lost-sheet .hand-title { transform-origin: center; }
.lost-sheet .search-slip { margin-inline: auto; }
.lost-home { margin-top: 1.6rem; }

/* Комментарии */
.comments-sheet { margin-top: 3rem; background: var(--sheet); padding: 2.2rem 2.6rem; box-shadow: 0 2px 0 rgba(138, 123, 102, .2); }
.comment-list { list-style: none; margin: 0 0 2rem; padding: 0; }
.comment-list .children { list-style: none; padding-left: 2rem; border-left: 2px dashed var(--pencil); margin-left: .6rem; }
.note-comment-body { padding: 1rem 0; border-bottom: 1px dashed var(--pencil); }
.note-comment-head { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; margin-bottom: .5rem; }
.note-comment-head img { border-radius: 50%; display: block; }
.note-comment-author { font-weight: 600; color: var(--ink); }
.note-comment-date { font-size: .85rem; color: var(--muted-dark); }
.note-comment-wait { font-style: italic; color: var(--coral-dark); }
.note-comment-reply a { font-family: var(--hand); font-size: 1.1rem; color: var(--sage-dark); }
.comment-respond { margin-top: 1.4rem; }
.comment-reply-title { font-family: var(--hand); font-weight: 400; font-size: 1.8rem; }
.comment-reply-title small { font-family: var(--body); font-size: .9rem; margin-left: .8rem; }
.comment-form p { margin-bottom: 1rem; }
.comment-form label { display: block; font-size: .92rem; margin-bottom: .3rem; color: var(--muted-dark); }
.comment-form-cookies-consent label { display: inline; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
    width: 100%; padding: .65rem .8rem; font: inherit; color: var(--text);
    background: #FFFBF2; border: 1px solid var(--pencil); border-radius: 0;
}
.comment-form .submit {
    font-family: var(--hand); font-size: 1.25rem;
    background: var(--coral); color: #FFF7EC; border: 0; padding: .55rem 1.6rem .65rem; cursor: pointer;
    clip-path: polygon(0 6%, 9% 0, 23% 5%, 41% 0, 60% 6%, 79% 0, 100% 4%, 98% 30%, 100% 62%, 97% 100%, 78% 95%, 58% 100%, 37% 94%, 18% 100%, 0 96%, 2% 64%, 0 34%);
}
.comment-form .submit:hover { background: var(--coral-dark); }
.req { color: var(--coral-dark); }
.comments-closed { font-style: italic; color: var(--muted-dark); }

/* ---------- Подвал ---------- */
.back-cover {
    position: relative;
    background-color: var(--ink);
    background-image:
        repeating-linear-gradient(0deg, rgba(255, 255, 255, .025) 0 1px, transparent 1px 3px),
        repeating-linear-gradient(90deg, rgba(0, 0, 0, .06) 0 1px, transparent 1px 4px);
    color: #E5DAC4;
    padding: 3.6rem 0 1.8rem;
    margin-top: 0;
}
.sprig { position: absolute; display: block; pointer-events: none; }
.sprig-left { left: 1.4%; bottom: 4.6rem; width: 54px; height: auto; opacity: .7; }
.back-cover-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3.4rem; align-items: start; }
.back-sheet {
    position: relative;
    min-width: 0;
    background: var(--paper);
    color: var(--text);
    padding: 1.7rem 1.9rem 1.6rem;
    clip-path: polygon(0 3%, 12% 0, 30% 2.5%, 52% 0, 74% 3%, 100% 0, 99% 50%, 100% 97%, 80% 100%, 56% 97%, 34% 100%, 12% 97%, 0 100%, 1% 50%);
}
.back-sheet::before {
    content: ""; position: absolute; top: 0; left: 50%; width: 74px; height: 16px;
    transform: translateX(-50%); background: rgba(185, 169, 143, .7);
}
.sheet-flower { position: absolute; right: 12px; top: 14px; width: 34px; height: auto; opacity: .85; }
.back-sheet .widget { margin: 0; }
.back-sheet .widget + .widget { margin-top: 1.4rem; }
.back-sheet .widget-title { font-family: var(--hand); font-weight: 400; font-size: 1.95rem; line-height: 1.2; color: var(--ink); margin: 0 0 .5rem; padding-right: 2rem; }
.back-sheet p, .back-sheet .textwidget { color: var(--text); font-size: .97rem; line-height: 1.55; }
.back-sheet .textwidget p:last-child { margin-bottom: 0; }
.back-sheet a { color: var(--sage-dark); }
.back-sheet a:hover { color: var(--coral-dark); }
.back-sheet ul { list-style: none; margin: 0; padding: 0; }
.back-sheet li { position: relative; padding: .2rem 0 .2rem 1.1rem; line-height: 1.45; }
.back-sheet li::before { content: ""; position: absolute; left: 0; top: .82em; width: .38rem; height: .38rem; border-radius: 50%; background: var(--sage); }
.back-sheet-links a { text-underline-offset: 4px; }
.copyline {
    margin: 2.6rem 0 0;
    padding-top: 1.2rem;
    border-top: 1px solid rgba(214, 168, 75, .35);
    text-align: center;
    font-size: .92rem;
    color: #D7CCB5;
    padding-inline: 3rem;
}

/* ---------- Cookie-баннер ---------- */
.cookie-banner {
    position: fixed;
    z-index: 90;
    left: 1rem;
    bottom: 1rem;
    width: min(560px, calc(100% - 2rem));
    display: flex;
    align-items: center;
    gap: 1.2rem;
    background: var(--sheet);
    color: var(--text);
    padding: 1.1rem 1.4rem;
    border-top: 5px solid var(--mustard);
    box-shadow: 0 10px 30px -10px rgba(27, 39, 64, .55);
}
.cookie-banner-text { margin: 0; font-size: .92rem; line-height: 1.5; flex: 1; min-width: 0; }
.cookie-banner-btn {
    flex: 0 0 auto;
    font-family: var(--hand); font-size: 1.2rem;
    background: var(--coral); color: #FFF7EC; border: 0; padding: .45rem 1.3rem .55rem; cursor: pointer;
    clip-path: polygon(0 6%, 30% 0, 70% 5%, 100% 0, 97% 50%, 100% 100%, 64% 95%, 30% 100%, 0 96%, 3% 50%);
}
.cookie-banner-btn:hover { background: var(--coral-dark); }

/* ---------- WordPress ---------- */
.alignleft { float: left; margin: .4rem 1.5rem 1rem 0; }
.alignright { float: right; margin: .4rem 0 1rem 1.5rem; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.wp-caption-text { font-size: .88rem; color: var(--muted-dark); }
.sticky .card-title a { color: var(--ink); }
.bypostauthor > .note-comment-body .note-comment-author::after { content: " · автор"; font-weight: 400; color: var(--muted-dark); }

/* ---------- Адаптив ---------- */
@media (max-width: 1180px) {
    .district-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }
    .taped-photo-yard { grid-column: 1 / -1; width: 54%; justify-self: center; }
    .plan-label { font-size: 1.3rem; }
    .spread-pair { grid-template-columns: minmax(0, 1fr); gap: 0; }
    .spread-pair .spread { border-top: 0; }
    .archive-box { max-width: 560px; }
}

@media (max-width: 960px) {
    .cover-row { flex-wrap: wrap; }
    .nav-toggle { display: inline-flex; }
    .main-nav { flex-basis: 100%; display: none; }
    .main-nav.is-open { display: block; }
    .main-nav-list { flex-direction: column; gap: 0; padding-top: .8rem; border-top: 1px dashed rgba(185, 169, 143, .45); }
    .main-nav-list a { display: block; padding: .6rem 0; }
    .front-wrap { width: 92%; }
    .district-grid { grid-template-columns: minmax(0, 1fr); }
    .taped-photo-map { width: 92%; justify-self: center; }
    .taped-photo-yard { width: 70%; }
    .plan-grid { grid-template-columns: minmax(0, 1fr); }
    .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .layout-with-sidebar { grid-template-columns: minmax(0, 1fr); row-gap: 3rem; }
    .layout-single .content-area { width: 100%; }
    .back-cover-grid { grid-template-columns: minmax(0, 1fr); gap: 2.4rem; }
    .back-sheet { max-width: 560px; justify-self: center; width: 100%; }
    .journal::before { display: none; }
}

@media (max-width: 600px) {
    .cover { padding: 1rem 0 1.2rem; }
    .brand { gap: .8rem; }
    .brand-house { width: 72px; }
    .brand-logo { max-width: 72px; }
    .brand-tagline { font-size: .82rem; }
    .tab-strip { height: 24px; }
    .tab-strip span { height: 20px; }
    .front-wrap { padding-top: 1.8rem; }
    .spread { padding: 2rem 0 2.2rem; }
    .hand-title { font-size: 2rem; margin-bottom: 1.3rem; }
    .taped-photo { padding: 9px; }
    .taped-photo-map, .taped-photo-yard { width: 100%; }
    .tape { width: 70px; height: 24px; }
    .plan-sheet { padding: 1.6rem 1.2rem; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem 1rem; }
    .plan-figure { width: 100%; grid-column: 1 / -1; }
    .plan-label { position: static; font-size: 1.25rem; max-width: none; text-align: left; }
    .plan-label::before { content: "↳ "; color: var(--sage-dark); }
    .plan-arrows { display: none; }
    .torn-note { padding: 1.1rem 1.2rem 1.2rem; }
    .torn-note-tilt { margin-left: 0; }
    .card-grid, .layout-with-sidebar .card-grid { grid-template-columns: minmax(0, 1fr); gap: 2.2rem; }
    .year-ribbon { min-width: 620px; }
    .entry-sheet { padding: 2rem 1.3rem 1.8rem; }
    .comments-sheet { padding: 1.6rem 1.2rem; }
    .comment-list .children { padding-left: 1rem; }
    .entry-nav { grid-template-columns: minmax(0, 1fr); }
    .entry-nav-next { grid-column: auto; text-align: left; }
    .sidebar { padding: 2rem 1.3rem 1.4rem; }
    .back-sheet { padding: 1.5rem 1.4rem 1.4rem; }
    .crumbs { padding-left: 0; }
    .copyline { padding-inline: 0; }
    .sprig-left { display: none; }
    .search-slip { flex-direction: column; }
    .cookie-banner { flex-direction: column; align-items: flex-start; left: .6rem; bottom: .6rem; width: calc(100% - 1.2rem); padding: 1rem 1.1rem; }
    .alignleft, .alignright { float: none; margin: 1rem 0; }
}
