/*
Theme Name: dds_therevgarden.com
Theme URI: https://therevgarden.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: revgarden
*/

/* ---------- Шрифты ---------- */
@font-face { font-family: "Oswald"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/oswald-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: "Oswald"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/oswald-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Oswald"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/oswald-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: "Oswald"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/oswald-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "PT Serif"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/pt-serif-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: "PT Serif"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/pt-serif-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "PT Serif"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/pt-serif-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: "PT Serif"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/pt-serif-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "PT Serif"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/pt-serif-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: "PT Serif"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/pt-serif-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "PT Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/pt-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: "PT Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/pt-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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---------- Переменные ---------- */
:root {
    --paper: #E8DFCB;
    --paper-light: #EFE8D8;
    --paper-deep: #DDD2BA;
    --ink: #221C14;
    --muted: #6E6450;
    --earth: #2F3B2A;
    --grass: #6B7C3F;
    --rust: #C2542A;
    --chalk: #8FA3A8;
    --grid: #C9BEA4;
    --contour: #D6C9AE;
    --soil: #241E17;
    --foot-text: #E8DFCB;
    --foot-muted: #B9AE95;
    --f-head: "Oswald", "Arial Narrow", "Roboto Condensed", Impact, sans-serif;
    --f-text: "PT Serif", Georgia, "Times New Roman", serif;
    --f-mono: "PT Mono", "Courier New", Courier, monospace;
}

/* ---------- Управление [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%; }
body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--f-text);
    font-size: 17px;
    line-height: 1.6;
    color: var(--ink);
    background-color: var(--paper);
    background-image:
        url("images/contours.svg"),
        linear-gradient(rgba(201, 190, 164, .55) 1px, transparent 1px),
        linear-gradient(90deg, rgba(201, 190, 164, .55) 1px, transparent 1px),
        linear-gradient(rgba(201, 190, 164, .22) 1px, transparent 1px),
        linear-gradient(90deg, rgba(201, 190, 164, .22) 1px, transparent 1px);
    background-size: 1400px 1600px, 40px 40px, 40px 40px, 8px 8px, 8px 8px;
    background-repeat: repeat-y, repeat, repeat, repeat, repeat;
    background-position: center top, 0 0, 0 0, 0 0, 0 0;
}
p { margin: 0 0 1em; }
h1, h2, h3, h4, h5, h6 { margin: 1.4em 0 .5em; line-height: 1.15; overflow-wrap: break-word; hyphens: auto; }
p, li, dd, td, th, figcaption, blockquote { overflow-wrap: break-word; hyphens: auto; }
img { max-width: 100%; height: auto; }
a {
    color: var(--earth);
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
    transition: color .15s ease;
}
a:hover, a:focus-visible { color: var(--rust); }
:focus-visible { outline: 3px solid var(--rust); outline-offset: 2px; }
button, input, textarea, select { font: inherit; color: inherit; }
.sr-only {
    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-link {
    position: absolute; left: 1rem; top: -60px; z-index: 100;
    background: var(--ink); color: var(--paper); padding: .5rem 1rem; font-family: var(--f-mono);
}
.skip-link:focus { top: 1rem; color: var(--paper); }

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

/* ---------- Кнопка-штамп ---------- */
.stamp-btn {
    display: inline-block;
    padding: .45rem 1rem .4rem;
    border: 3px solid var(--ink);
    background: transparent;
    color: var(--ink);
    font-family: var(--f-head);
    font-weight: 700;
    font-size: .95rem;
    line-height: 1.2;
    letter-spacing: .05em;
    text-transform: uppercase;
    text-decoration: none;
    text-align: center;
    border-radius: 0;
    cursor: pointer;
    transition: background-color .12s, color .12s, transform .12s, box-shadow .12s;
}
.stamp-btn:hover, .stamp-btn:focus-visible {
    background: var(--ink);
    color: var(--paper);
    transform: translate(-2px, -2px);
    box-shadow: 3px 3px 0 var(--rust);
}
.stamp-btn--sm { font-size: .82rem; padding: .32rem .7rem .28rem; }

/* ---------- Шапка ---------- */
.masthead { background: var(--earth); color: var(--paper); }
.masthead-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem 2.5rem;
    padding: 1.4rem 0;
    flex-wrap: wrap;
}
.brand {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    text-decoration: none;
    color: var(--paper);
    flex: 1 1 520px;
    min-width: 0;
}
.brand:hover, .brand:focus-visible { color: var(--paper); }
.brand-mark { flex: 0 0 auto; display: block; color: var(--paper); }
.brand-logo { display: block; width: 96px; height: 96px; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; gap: .35rem; min-width: 0; }
.brand-name {
    font-family: var(--f-head);
    font-weight: 700;
    text-transform: uppercase;
    font-size: clamp(1.05rem, 1.7vw, 1.45rem);
    line-height: 1.12;
    letter-spacing: .01em;
    overflow-wrap: break-word;
    hyphens: manual;
}
.brand-desc {
    font-size: .88rem;
    line-height: 1.4;
    color: #CFC6AE;
    max-width: 62ch;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.topnav-list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; flex-wrap: wrap; }
.topnav-list li { position: relative; }
.topnav-list li + li { border-left: 1px solid rgba(232, 223, 203, .28); }
.topnav-list a {
    display: block;
    padding: .35rem 1.1rem;
    color: var(--paper);
    font-family: var(--f-head);
    font-weight: 700;
    font-size: 1.12rem;
    letter-spacing: .02em;
    text-decoration: none;
}
.topnav-list a:hover, .topnav-list a:focus-visible { color: #F0A27F; }
.topnav-list .current-menu-item > a,
.topnav-list .current_page_item > a {
    text-decoration: underline;
    text-decoration-color: var(--rust);
    text-decoration-thickness: 3px;
    text-underline-offset: 6px;
}
.nav-toggle {
    display: none;
    align-items: center;
    gap: .6rem;
    padding: .45rem .8rem;
    background: transparent;
    color: var(--paper);
    border: 2px solid var(--paper);
    font-family: var(--f-head);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    cursor: pointer;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    display: block; width: 20px; height: 2px; background: currentColor; position: relative;
}
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }
.mm-strip {
    height: 16px;
    background-color: var(--paper);
    background-image:
        linear-gradient(90deg, rgba(34, 28, 20, .35) 1px, transparent 1px),
        linear-gradient(90deg, rgba(34, 28, 20, .18) 1px, transparent 1px);
    background-size: 40px 100%, 8px 60%;
    background-repeat: repeat-x, repeat-x;
    border-bottom: 3px solid var(--ink);
}

/* ---------- Хлебные крошки ---------- */
.crumbs {
    margin: 1.6rem 0 1rem;
    font-family: var(--f-mono);
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--muted);
}
.crumbs a { color: var(--earth); text-decoration-thickness: 1px; }
.crumbs-sep { margin: 0 .35rem; color: var(--rust); }
.crumbs-current { color: var(--ink); }

/* ---------- Заголовки разделов ---------- */
.fb-title {
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    margin: 0 0 1.6rem;
    font-family: var(--f-head);
    font-weight: 700;
    text-transform: uppercase;
    font-size: clamp(2rem, 4.6vw, 3.4rem);
    line-height: .98;
    letter-spacing: -.005em;
    color: var(--earth);
}
.fb-title > span { min-width: 0; overflow-wrap: break-word; hyphens: manual; }
.fb-title::after {
    content: "";
    flex: 1 1 60px;
    min-width: 40px;
    height: 0;
    margin-bottom: .32em;
    border-bottom: 3px solid var(--ink);
    transform: rotate(-.3deg);
}

/* ---------- Главная: журнал ---------- */
.fieldbook { width: 85%; margin-inline: auto; padding: 1.4rem 0 3rem; }
.fb-block { position: relative; padding: 2.4rem 0 2.6rem; }
.fb-block + .fb-block::before {
    content: "";
    position: absolute;
    top: 0; left: -1%; right: -1%;
    height: 4px;
    background: repeating-linear-gradient(90deg, var(--ink) 0 140px, rgba(34, 28, 20, .55) 140px 146px, var(--ink) 146px 310px, rgba(34, 28, 20, .75) 310px 318px);
    opacity: .75;
    transform: rotate(-.35deg);
    border-radius: 2px;
}

/* Блок 1 — слои */
.strata-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 320px);
    gap: 2.5rem;
    align-items: start;
}
.strata-fig {
    margin: 0;
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr) 76px;
    align-items: stretch;
}
.strata-labels { position: relative; min-width: 0; }
.strata-lab {
    position: absolute;
    left: 0;
    right: -34px;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: .4rem;
    font-family: var(--f-mono);
    font-size: .74rem;
    text-transform: uppercase;
    letter-spacing: .03em;
    color: var(--ink);
    z-index: 2;
}
.strata-lab::after {
    content: "";
    flex: 1;
    min-width: 20px;
    border-top: 1.5px solid var(--ink);
}
.strata-pic { min-width: 0; border: 2px solid var(--ink); background: var(--paper-light); }
.strata-pic img { display: block; width: 100%; height: auto; aspect-ratio: 1306 / 610; object-fit: cover; }
.strata-scale {
    position: relative;
    margin-left: 14px;
    border-left: 2px solid var(--ink);
    background-image: linear-gradient(var(--ink) 1px, transparent 1px);
    background-size: 8px 10%;
    background-repeat: repeat-y;
    background-position: left top;
}
.strata-scale span {
    position: absolute;
    left: -2px;
    transform: translateY(-50%);
    font-family: var(--f-mono);
    font-size: .78rem;
    white-space: nowrap;
    padding-left: 18px;
}
.strata-scale span::before {
    content: "";
    position: absolute;
    left: 0; top: 50%;
    width: 14px;
    border-top: 2px solid var(--ink);
}
.strata-note {
    position: relative;
    padding: .2rem 0 .4rem 1.6rem;
    border-left: 2px solid var(--ink);
    min-width: 0;
}
.strata-note p { font-size: 1rem; }
.stamp {
    display: inline-block;
    margin-top: .6rem;
    padding: .4rem 1rem .35rem;
    border: 3px solid var(--rust);
    outline: 1.5px solid var(--rust);
    outline-offset: 3px;
    color: var(--rust);
    font-family: var(--f-head);
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    transform: rotate(-5deg);
    opacity: .92;
    background-image: radial-gradient(circle at 20% 40%, rgba(232, 223, 203, .55) 0 2px, transparent 3px), radial-gradient(circle at 70% 70%, rgba(232, 223, 203, .45) 0 1.5px, transparent 2.5px);
    background-size: 23px 17px, 31px 19px;
}

/* Блок 2 — культуры */
.crops-row {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 2.8rem;
}
.crop { position: relative; min-width: 0; text-align: center; }
.crop:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 30%;
    right: -2.45rem;
    width: 2rem;
    height: 14px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 14'%3E%3Cpath d='M1 7.5 C9 6.5 18 8 30 7 M24 2 L30.5 7 L24 12' fill='none' stroke='%23221C14' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.crop-cell {
    margin: 0;
    padding: 6px;
    border: 2px solid var(--ink);
    background: var(--paper-light);
}
.crop-cell img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
.crop-name {
    margin: .9rem 0 .1rem;
    font-family: var(--f-head);
    font-weight: 700;
    font-size: 1.25rem;
    text-transform: uppercase;
    letter-spacing: .03em;
}
.crop-term {
    margin: 0;
    font-family: var(--f-mono);
    font-size: .76rem;
    text-transform: uppercase;
    color: var(--muted);
}
.crops-note {
    margin: 1.8rem 0 0;
    padding-top: .9rem;
    border-top: 1px dashed var(--muted);
    font-family: var(--f-mono);
    font-size: .82rem;
    color: var(--muted);
    max-width: 80ch;
}

/* Блок записей — полоса с наклонными краями */
.fb-latest { padding-left: 0; padding-right: 0; }
.fb-latest::after {
    content: "";
    position: absolute;
    inset: .8rem -1.5% .4rem;
    z-index: -1;
    background: rgba(107, 124, 63, .09);
    clip-path: polygon(0 20px, 100% 0, 100% calc(100% - 20px), 0 100%);
}
.latest-more { margin: 2rem 0 0; text-align: right; }
.empty-note {
    padding: 1.4rem 1.6rem;
    border: 2px dashed var(--muted);
    background: var(--paper-light);
    font-family: var(--f-mono);
    font-size: .9rem;
}
.empty-note p:last-child { margin-bottom: 0; }

/* ---------- Карточки ---------- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2.6rem 2rem;
    padding-top: 1rem;
}
.cards-grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--paper-light);
    border: 2px solid var(--ink);
    border-top: 14px solid var(--grass);
    box-shadow: 5px 5px 0 rgba(34, 28, 20, .16);
    transition: transform .14s ease, box-shadow .14s ease;
}
.card:hover { transform: translate(-3px, -3px); box-shadow: 8px 8px 0 rgba(34, 28, 20, .22); }
.card-clip {
    position: absolute;
    top: -30px;
    left: 26px;
    width: 22px;
    height: 58px;
    z-index: 3;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 58'%3E%3Cpath d='M7 40 V9 a4 4 0 0 1 8 0 V47 a6 6 0 0 1 -12 0 V14' fill='none' stroke='%236E6450' stroke-width='2.2' stroke-linecap='round'/%3E%3Cpath d='M7 40 V9 a4 4 0 0 1 8 0 V47 a6 6 0 0 1 -12 0 V14' fill='none' stroke='%23EFE8D8' stroke-width='.7' stroke-linecap='round' transform='translate(-.6 -.4)'/%3E%3C/svg%3E") center / contain no-repeat;
}
.card-thumb { padding: 1rem 1rem 0; }
.card-thumb a { display: block; border: 1px solid var(--grid); background: var(--paper); text-decoration: none; }
.card-thumb img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.card-nothumb {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 16 / 10;
    color: var(--muted);
    background-image:
        linear-gradient(rgba(201, 190, 164, .6) 1px, transparent 1px),
        linear-gradient(90deg, rgba(201, 190, 164, .6) 1px, transparent 1px);
    background-size: 16px 16px;
}
.card-nothumb svg { display: block; width: 46%; height: auto; }
.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 1rem 1.15rem 1.15rem;
    background-image: repeating-linear-gradient(transparent 0 27px, rgba(201, 190, 164, .55) 27px 28px);
    background-position: 0 6px;
}
.card-title { margin: 0 0 .55rem; font-family: var(--f-text); font-weight: 700; font-size: 1.2rem; line-height: 1.3; }
.card-title a { color: var(--ink); text-decoration: none; }
.card-title a:hover, .card-title a:focus-visible { color: var(--rust); text-decoration: underline; text-decoration-thickness: 2px; }
.card-excerpt { flex: 1; font-size: .96rem; line-height: 1.55; color: #3A3226; }
.card-excerpt p { margin: 0 0 .5em; background: none; }
.card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .8rem;
    margin-top: .9rem;
}
.card-date { font-family: var(--f-mono); font-size: .8rem; text-transform: uppercase; color: var(--muted); }

/* Блок 3 — дневник сезона */
.season-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px;
    gap: 2rem;
    align-items: start;
}
.season-main { min-width: 0; }
.season-cal {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    border: 2px solid var(--ink);
    border-bottom: 0;
    background: rgba(239, 232, 216, .7);
}
.season-cell { min-width: 0; border-right: 1px solid var(--ink); }
.season-cell:nth-child(8n) { border-right: 0; }
.season-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .35rem;
    height: 100%;
    padding: 0 .4rem .8rem;
    color: var(--ink);
    text-decoration: none;
    text-align: center;
    transition: background-color .15s;
}
.season-link:hover, .season-link:focus-visible { background: rgba(107, 124, 63, .14); color: var(--ink); }
.season-link.is-active { background: rgba(107, 124, 63, .2); }
.season-month {
    align-self: stretch;
    padding: .45rem 0 .4rem;
    border-bottom: 1px solid var(--ink);
    font-family: var(--f-mono);
    font-size: .74rem;
    text-transform: uppercase;
    letter-spacing: .03em;
}
.season-task { font-style: italic; font-size: .95rem; line-height: 1.25; min-height: 2.5em; display: flex; align-items: center; }
.season-ico { display: block; width: 44px; height: 44px; color: var(--earth); }
.season-log { border: 2px solid var(--ink); background: rgba(239, 232, 216, .55); }
.season-entry { border-top: 1px solid var(--grid); }
.season-entry:first-child { border-top: 1px solid var(--ink); }
.season-entry summary {
    cursor: pointer;
    list-style: none;
    padding: .55rem 1rem .5rem 2.2rem;
    position: relative;
    font-size: .98rem;
}
.season-entry summary::-webkit-details-marker { display: none; }
.season-entry summary::before {
    content: "›";
    position: absolute;
    left: 1rem;
    top: .45rem;
    font-family: var(--f-mono);
    font-weight: 700;
    color: var(--rust);
    transition: transform .15s;
}
.season-entry[open] summary::before { transform: rotate(90deg); }
.season-entry[open] summary { font-weight: 700; }
.season-entry p { margin: 0; padding: 0 1.2rem 1rem 2.2rem; font-size: .96rem; max-width: 85ch; }
.season-thermo { text-align: center; color: var(--ink); }
.season-thermo-cap { margin: 0 0 .6rem; font-size: .92rem; line-height: 1.25; font-weight: 700; }
.season-thermo svg { display: block; width: 90px; height: auto; margin-inline: auto; }

/* Блок 4 — хозяйство */
.farm-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 300px);
    gap: 2.4rem;
    align-items: center;
}
.farm-plan { position: relative; margin: 0; min-width: 0; }
.farm-plan img { display: block; width: 100%; height: auto; aspect-ratio: 1940 / 536; object-fit: contain; }
.farm-pin {
    position: absolute;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--ink);
    border-radius: 50%;
    background: var(--paper-light);
    font-family: var(--f-mono);
    font-weight: 700;
    font-size: .85rem;
    color: var(--ink);
    box-shadow: 2px 2px 0 rgba(34, 28, 20, .25);
}
.farm-legend {
    list-style: none;
    counter-reset: farm;
    margin: 0;
    padding: .4rem 0 .4rem 1.6rem;
    border-left: 2px solid var(--ink);
}
.farm-legend li {
    counter-increment: farm;
    position: relative;
    padding: .3rem 0 .45rem 2.4rem;
    font-size: .95rem;
    line-height: 1.35;
}
.farm-legend li + li { border-top: 1px dashed var(--grid); }
.farm-legend li::before {
    content: counter(farm);
    position: absolute;
    left: 0; top: .3rem;
    width: 26px; height: 26px;
    border: 2px solid var(--ink);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--f-mono);
    font-weight: 700;
    font-size: .8rem;
}
.farm-legend strong { display: block; font-weight: 700; }
.farm-legend span { display: block; font-family: var(--f-mono); font-size: .76rem; color: var(--muted); }

/* ---------- Внутренние страницы ---------- */
.layout-with-sidebar {
    display: grid;
    grid-template-columns: minmax(0, 67fr) minmax(0, 27fr);
    gap: 0 6%;
    align-items: start;
    padding-bottom: 3.5rem;
}
.layout-single { display: block; padding-bottom: 3.5rem; }
.layout-single > .content-area { width: 85%; margin-left: auto; margin-right: auto; }
.layout-with-sidebar > .content-area { min-width: 0; }
.page-head { margin-bottom: 1rem; }
.page-head .fb-title { margin-bottom: .8rem; }
.page-sub { font-family: var(--f-mono); font-size: .9rem; color: var(--muted); }

.entry {
    background: rgba(239, 232, 216, .78);
    border: 2px solid var(--ink);
    border-top: 14px solid var(--grass);
    padding: 2rem 2.4rem 2.2rem;
    box-shadow: 6px 6px 0 rgba(34, 28, 20, .14);
}
.entry-title {
    margin: 0 0 .6rem;
    font-family: var(--f-head);
    font-weight: 700;
    text-transform: uppercase;
    font-size: clamp(1.8rem, 3.6vw, 2.8rem);
    line-height: 1.05;
    color: var(--earth);
}
.entry-meta {
    display: flex; flex-wrap: wrap; gap: .4rem 1.2rem;
    margin: 0 0 1.4rem;
    padding-bottom: .9rem;
    border-bottom: 2px solid var(--ink);
    font-family: var(--f-mono);
    font-size: .8rem;
    text-transform: uppercase;
    color: var(--muted);
}
.entry-cats a { margin-right: .6rem; color: var(--earth); text-decoration-thickness: 1px; }
.entry-cover { margin: 0 0 1.6rem; border: 1px solid var(--grid); }
.entry-cover img { display: block; width: 100%; height: auto; }
.entry-tags { margin: 1.6rem 0 0; display: flex; flex-wrap: wrap; gap: .5rem; font-family: var(--f-mono); font-size: .82rem; }
.entry-tags a { padding: .15rem .5rem; border: 1.5px solid var(--ink); text-decoration: none; color: var(--ink); }
.entry-tags a:hover { background: var(--ink); color: var(--paper); }

.entry-content { font-size: 1.04rem; }
.entry-content > *:first-child { margin-top: 0; }
.entry-content h2, .entry-content h3, .entry-content h4 { font-family: var(--f-head); font-weight: 700; color: var(--earth); text-transform: uppercase; letter-spacing: .01em; }
.entry-content h2 { font-size: 1.8rem; padding-bottom: .25rem; border-bottom: 2px solid var(--ink); }
.entry-content h3 { font-size: 1.4rem; }
.entry-content h4 { font-size: 1.15rem; }
.entry-content ul, .entry-content ol { margin: 0 0 1.1em; padding-left: 1.6em; }
.entry-content li { margin-bottom: .35em; }
.entry-content ul li::marker { color: var(--rust); }
.entry-content ol li::marker { font-family: var(--f-mono); color: var(--rust); }
.entry-content blockquote {
    margin: 1.6em 0;
    padding: 1.1rem 1.4rem 1.1rem 1.6rem;
    background: var(--paper-deep);
    border-left: 6px solid var(--grass);
    font-style: italic;
}
.entry-content blockquote p:last-child { margin-bottom: 0; }
.entry-content table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .95rem; border: 2px solid var(--ink); }
.entry-content th, .entry-content td { border: 1px solid var(--ink); padding: .5rem .7rem; text-align: left; vertical-align: top; }
.entry-content th { background: var(--paper-deep); font-family: var(--f-mono); font-size: .82rem; text-transform: uppercase; font-weight: 400; }
.entry-content figure { margin: 1.6em 0; }
.entry-content figcaption { font-family: var(--f-mono); font-size: .8rem; color: var(--muted); margin-top: .4rem; }
.entry-content pre { overflow-x: auto; padding: 1rem; background: var(--paper-deep); border: 1px solid var(--grid); font-family: var(--f-mono); font-size: .88rem; }
.entry-content code { font-family: var(--f-mono); font-size: .9em; }
.entry-content hr { border: 0; border-top: 3px solid var(--ink); margin: 2em 0; }
.page-links { margin-top: 1.4rem; font-family: var(--f-mono); }
.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; }

/* ---------- Пагинация ---------- */
.pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    margin: 2.6rem 0 0;
}
.pager .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.6rem;
    padding: .4rem .7rem;
    border: 2px solid var(--ink);
    background: var(--paper-light);
    color: var(--ink);
    font-family: var(--f-mono);
    font-size: .9rem;
    text-decoration: none;
}
.pager a.page-numbers:hover, .pager a.page-numbers:focus-visible { background: var(--ink); color: var(--paper); }
.pager .page-numbers.current { background: var(--earth); border-color: var(--earth); color: var(--paper); }
.pager .page-numbers.dots { border: 0; background: none; min-width: 0; }

/* ---------- Сайдбар ---------- */
.sidebar {
    min-width: 0;
    background: var(--paper-deep);
    border: 2px solid var(--ink);
    padding: 1.5rem 1.4rem;
    color: var(--ink);
    position: relative;
}
.sidebar::before {
    content: "";
    position: absolute;
    top: -2px; left: -2px; right: -2px;
    height: 8px;
    background: var(--rust);
}
.sidebar .widget + .widget { margin-top: 1.8rem; }
.sidebar .widget-title {
    margin: 0 0 .8rem;
    padding-bottom: .35rem;
    border-bottom: 2px solid var(--ink);
    font-family: var(--f-head);
    font-weight: 700;
    font-size: 1.3rem;
    text-transform: uppercase;
    color: var(--earth);
}
.sidebar ul { list-style: none; margin: 0; padding: 0; }
.sidebar li { padding: .5rem 0; border-bottom: 1px dashed var(--muted); line-height: 1.35; }
.sidebar li:last-child { border-bottom: 0; }
.sidebar a { color: var(--ink); text-decoration-thickness: 1px; }
.sidebar a:hover, .sidebar a:focus-visible { color: var(--rust); }
.sidebar .post-date { display: block; font-family: var(--f-mono); font-size: .76rem; color: var(--muted); }
.sidebar p, .sidebar .textwidget { color: var(--ink); }

/* ---------- Поиск ---------- */
.seek { display: flex; gap: .5rem; margin: 1rem 0 1.4rem; max-width: 560px; }
.seek-field {
    flex: 1;
    min-width: 0;
    padding: .55rem .8rem;
    border: 2px solid var(--ink);
    background: var(--paper-light);
    border-radius: 0;
    font-family: var(--f-mono);
    font-size: .92rem;
}
.seek-field:focus { outline: 3px solid var(--rust); outline-offset: 0; }

/* ---------- 404 ---------- */
.notfound { padding: 1.5rem 0 1rem; }
.notfound-code {
    margin: 0;
    font-family: var(--f-head);
    font-weight: 700;
    font-size: clamp(5rem, 16vw, 10rem);
    line-height: .9;
    color: transparent;
    -webkit-text-stroke: 3px var(--rust);
}

/* ---------- Комментарии ---------- */
.notes { margin-top: 2.6rem; }
.notes-title, .comment-reply-title {
    font-family: var(--f-head);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 1.6rem;
    color: var(--earth);
    margin: 0 0 1rem;
}
.notes-list, .notes-list .children { list-style: none; margin: 0; padding: 0; }
.notes-list .children { margin-left: 2rem; }
.note-body {
    margin-bottom: 1rem;
    padding: 1rem 1.2rem;
    background: var(--paper-light);
    border: 2px solid var(--ink);
    border-left: 6px solid var(--grass);
}
.note-head { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; margin-bottom: .5rem; }
.note-head img { display: block; border-radius: 0; border: 1px solid var(--grid); }
.note-author { font-weight: 700; }
.note-date { font-family: var(--f-mono); font-size: .78rem; color: var(--muted); }
.note-moderation { font-family: var(--f-mono); font-size: .82rem; color: var(--rust); }
.note-text p:last-child { margin-bottom: .4rem; }
.note-reply a { font-family: var(--f-mono); font-size: .8rem; text-transform: uppercase; }
.notes-closed { font-family: var(--f-mono); color: var(--muted); }
.comment-respond {
    margin-top: 1.6rem;
    padding: 1.4rem 1.6rem;
    background: rgba(239, 232, 216, .8);
    border: 2px dashed var(--ink);
}
.comment-respond label { display: block; margin-bottom: .25rem; font-family: var(--f-mono); font-size: .82rem; text-transform: uppercase; }
.comment-respond input[type="text"],
.comment-respond input[type="email"],
.comment-respond input[type="url"],
.comment-respond textarea {
    width: 100%;
    padding: .55rem .7rem;
    border: 2px solid var(--ink);
    background: var(--paper-light);
    border-radius: 0;
}
.comment-respond .comment-form-cookies-consent label { display: inline; text-transform: none; font-size: .82rem; }
.comment-notes, .logged-in-as, .must-log-in { font-family: var(--f-mono); font-size: .82rem; color: var(--muted); }
.comment-reply-title small { margin-left: .8rem; font-family: var(--f-mono); font-size: .75rem; }
.comment-navigation .nav-links { display: flex; justify-content: space-between; gap: 1rem; font-family: var(--f-mono); font-size: .85rem; margin: 1rem 0; }

/* ---------- Подвал ---------- */
.sitefoot { background: var(--soil); color: var(--foot-text); margin-top: 1rem; border-top: 4px solid var(--ink); }
.sitefoot-cols {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    padding: 2.6rem 0 2rem;
}
.sitefoot-col { min-width: 0; padding: 0 2rem; }
.sitefoot-col + .sitefoot-col { border-left: 1px solid rgba(232, 223, 203, .22); }
.sitefoot-col:first-child { padding-left: 0; }
.sitefoot .widget-title {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin: 0 0 .8rem;
    font-family: var(--f-head);
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--foot-text);
}
.sitefoot .widget-title::after { content: ""; width: 28px; border-top: 1px solid var(--foot-muted); }
.sitefoot .widget, .sitefoot p, .sitefoot .textwidget { color: var(--foot-text); font-size: .95rem; line-height: 1.5; }
.sitefoot a { color: var(--foot-text); text-decoration-thickness: 1px; }
.sitefoot a:hover, .sitefoot a:focus-visible { color: #F0A27F; }
.sitefoot ul { list-style: none; margin: 0; padding: 0; }
.sitefoot li { padding: .18rem 0; }
.sitefoot .menu a { text-decoration: none; }
.sitefoot .menu a::before { content: "› "; font-family: var(--f-mono); color: var(--foot-muted); }
.sitefoot .menu a:hover { text-decoration: underline; }
.sitefoot-copy {
    padding: 1rem 0 1.4rem;
    border-top: 1px solid rgba(232, 223, 203, .18);
    text-align: center;
}
.sitefoot-copy p {
    margin: 0;
    font-family: var(--f-mono);
    font-size: .8rem;
    letter-spacing: .05em;
    color: var(--foot-muted);
}

/* ---------- Cookie-баннер ---------- */
.cookie-banner {
    position: fixed;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 90;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    max-width: 760px;
    margin-inline: auto;
    padding: 1rem 1.3rem;
    background: var(--paper-light);
    border: 2px solid var(--ink);
    border-top: 10px solid var(--grass);
    box-shadow: 6px 6px 0 rgba(34, 28, 20, .3);
    color: var(--ink);
}
.cookie-text { margin: 0; flex: 1; min-width: 0; font-size: .9rem; line-height: 1.45; }
.cookie-accept { flex: 0 0 auto; }

/* ---------- Адаптив ---------- */
@media (max-width: 1180px) {
    .crops-row { gap: 2rem; }
    .crop:not(:last-child)::after { right: -1.85rem; width: 1.6rem; }
    .season-cal { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .season-cell:nth-child(4n) { border-right: 0; }
    .season-cell { border-bottom: 1px solid var(--ink); }
}

@media (max-width: 960px) {
    .masthead-inner { padding: 1rem 0; }
    .brand { flex-basis: calc(100% - 130px); }
    .brand-logo { width: 72px; height: 72px; }
    .nav-toggle { display: inline-flex; }
    .topnav { display: none; width: 100%; }
    .topnav.is-open { display: block; }
    .topnav-list { flex-direction: column; align-items: stretch; border-top: 1px solid rgba(232, 223, 203, .28); }
    .topnav-list li + li { border-left: 0; border-top: 1px solid rgba(232, 223, 203, .18); }
    .topnav-list a { padding: .7rem 0; }

    .fieldbook { width: 92%; }
    .strata-grid { grid-template-columns: minmax(0, 1fr); }
    .strata-note { border-left: 0; border-top: 2px solid var(--ink); padding: 1.2rem 0 0; }
    .crops-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .crop::after { display: none; }
    .cards-grid--three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .season-grid { grid-template-columns: minmax(0, 1fr); }
    .season-thermo { display: none; }
    .farm-grid { grid-template-columns: minmax(0, 1fr); }
    .farm-legend { border-left: 0; border-top: 2px solid var(--ink); padding: 1rem 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.6rem; }
    .farm-legend li + li { border-top: 0; }

    .layout-with-sidebar { grid-template-columns: minmax(0, 1fr); gap: 2.4rem; }
    .layout-single > .content-area { width: 100%; }
    .sitefoot-cols { grid-template-columns: minmax(0, 1fr); gap: 1.8rem; }
    .sitefoot-col, .sitefoot-col:first-child { padding: 0; }
    .sitefoot-col + .sitefoot-col { border-left: 0; border-top: 1px solid rgba(232, 223, 203, .22); padding-top: 1.6rem; }
}

@media (max-width: 600px) {
    body { font-size: 16px; }
    .brand { gap: .8rem; flex-basis: 100%; }
    .brand-logo { width: 58px; height: 58px; }
    .brand-desc { -webkit-line-clamp: 2; font-size: .8rem; }
    .fieldbook { width: 92%; padding-top: .6rem; }
    .fb-block { padding: 2rem 0; }
    .fb-title { font-size: clamp(1.7rem, 8vw, 2.2rem); gap: .6rem; }
    .strata-fig { grid-template-columns: 96px minmax(0, 1fr) 54px; }
    .strata-lab { font-size: .6rem; right: -18px; }
    .strata-scale { margin-left: 8px; }
    .strata-scale span { font-size: .66rem; padding-left: 12px; }
    .strata-scale span::before { width: 9px; }
    .stamp { font-size: 1.05rem; }
    .crops-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem 1rem; }
    .crop-name { font-size: 1.05rem; }
    .cards-grid, .cards-grid--three { grid-template-columns: minmax(0, 1fr); gap: 2.6rem; }
    .season-cal { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .season-cell:nth-child(4n) { border-right: 1px solid var(--ink); }
    .season-cell:nth-child(2n) { border-right: 0; }
    .season-entry summary { padding-left: 2rem; }
    .season-entry p { padding: 0 1rem 1rem 2rem; }
    .farm-pin { width: 22px; height: 22px; font-size: .68rem; border-width: 1.5px; }
    .farm-legend { grid-template-columns: minmax(0, 1fr); }
    .entry { padding: 1.4rem 1.2rem 1.6rem; }
    .notes-list .children { margin-left: 1rem; }
    .comment-respond { padding: 1.1rem 1rem; }
    .sidebar { padding: 1.3rem 1.1rem; }
    .cookie-banner { flex-direction: column; align-items: stretch; left: .6rem; right: .6rem; bottom: .6rem; padding: .9rem 1rem; }
    .seek { flex-direction: column; }
}
