/*
Theme Name: dds_rokada-spb.ru
Theme URI: https://rokada-spb.ru/
Author: Алексей Захаров
Description: Тема для информационного сайта о встроенной мебели: гид по материалам, замеру, проектированию и монтажу.
Version: 1.1
Requires at least: 6.0
Requires PHP: 8.0
Text Domain: rkmeb
*/

/* ============================================================
   1. Переменные и базовые сбросы
   ============================================================ */

:root {
    --bg-main: #F4F8FB;
    --bg-alt: #E6F0F5;
    --bg-card: #FFFFFF;
    --bg-deep: #1A2E3A;
    --line: #D0E2ED;
    --ink: #1C2A33;
    --accent: #0077A3;
    --accent-dark: #005C82;
    --sand: #D4A373;
    --muted: #7A8F9E;
    --radius: 8px;
    --shell: 1180px;
    --font-head: "Jost", "Inter", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", "Open Sans", "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    background-color: var(--bg-main);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='48' viewBox='0 0 160 48'%3E%3Cpath d='M0 24c20-14 40-14 60 0s40 14 60 0 40-14 60 0' fill='none' stroke='%230077A3' stroke-opacity='0.07' stroke-width='1'/%3E%3Cpath d='M0 40c20-14 40-14 60 0s40 14 60 0 40-14 60 0' fill='none' stroke='%230077A3' stroke-opacity='0.05' stroke-width='1'/%3E%3C/svg%3E");
    background-repeat: repeat;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
}

p {
    margin: 0 0 1.1em;
}

a {
    color: var(--accent);
    text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-head);
    color: var(--ink);
    line-height: 1.22;
    margin: 0 0 0.7em;
    font-weight: 700;
}

h1 { font-size: 2.4rem; letter-spacing: 0.02em; font-weight: 800; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.12rem; }

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

.is-front .shell {
    width: min(85%, 1260px);
}

.site-main {
    display: block;
    min-height: 40vh;
}

.page-shell {
    padding: 2.2rem 0 3.5rem;
}

/* ============================================================
   2. Текстовые ссылки — анимированное подчёркивание
   ============================================================ */

.entry-content a,
.page-intro a,
.widget a,
.card-excerpt a {
    position: relative;
    color: var(--accent);
}

.entry-content a::after,
.page-intro a::after,
.card-excerpt a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 1px;
    background: var(--sand);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.25s ease;
}

.entry-content a:hover::after,
.page-intro a:hover::after,
.card-excerpt a:hover::after {
    transform: scaleX(1);
}

/* ============================================================
   3. Кнопки
   ============================================================ */

.btn {
    display: inline-block;
    padding: 0.72rem 1.5rem;
    border-radius: 6px;
    font-family: var(--font-head);
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.btn-solid {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.btn-solid:hover,
.btn-solid:focus {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    color: #fff;
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    color: var(--accent);
    border-color: var(--accent);
}

.btn-ghost:hover,
.btn-ghost:focus {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    color: #fff;
    transform: translateY(-1px);
}

/* ============================================================
   4. Шапка
   ============================================================ */

.site-top {
    background: var(--bg-deep);
    color: #fff;
    position: relative;
    z-index: 5;
}

.is-front .site-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(26, 46, 58, 0.62) 0%, rgba(26, 46, 58, 0.28) 60%, rgba(26, 46, 58, 0) 100%);
}

.top-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.1rem 0;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    color: #fff;
    min-width: 0;
    max-width: 620px;
}

.brand-mark {
    flex: 0 0 auto;
    color: var(--sand);
    display: block;
    line-height: 0;
}

.brand-logo {
    display: block;
    max-height: 56px;
    width: auto;
}

.brand-text {
    min-width: 0;
    display: block;
}

.brand-name {
    display: block;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.02rem;
    letter-spacing: 0.02em;
    line-height: 1.3;
    color: #fff;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.brand-desc {
    display: block;
    font-size: 0.79rem;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.72);
    margin-top: 0.2rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.nav-toggle {
    display: none;
    align-items: center;
    gap: 0.45rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 6px;
    color: #fff;
    padding: 0.55rem 0.85rem;
    cursor: pointer;
    font-family: var(--font-head);
    font-size: 0.95rem;
}

.nav-toggle-bar {
    display: block;
    width: 18px;
    height: 2px;
    background: #fff;
    margin: 3px 0;
}

.nav-toggle-label {
    margin-left: 0.35rem;
}

.nav-list {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.nav-list li {
    margin: 0;
}

.nav-list a {
    display: block;
    padding: 0.5rem 0.9rem;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-family: var(--font-head);
    font-size: 0.98rem;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.nav-list a:hover,
.nav-list a:focus,
.nav-list .current-menu-item > a {
    background: rgba(255, 255, 255, 0.22);
    transform: translateY(-1px);
}

/* ============================================================
   5. Hero
   ============================================================ */

.hero {
    position: relative;
    overflow: hidden;
    padding: 11rem 0 7.5rem;
    color: #fff;
    background: var(--bg-deep);
}

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    z-index: 0;
}

.hero-veil {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgba(10, 26, 36, 0.52) 0%, rgba(10, 26, 36, 0.40) 55%, rgba(26, 46, 58, 0.62) 100%);
}

.hero-inner {
    position: relative;
    z-index: 2;
    max-width: 780px;
    margin-inline: auto;
}

.hero-title {
    color: #fff;
    font-size: 3.5rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    margin-bottom: 0.6em;
    text-wrap: balance;
}

.hero-sub {
    font-size: 1.14rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 46em;
    margin-bottom: 1.8rem;
}

.hero-actions {
    margin: 0;
}

.hero-wave {
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    width: 100%;
    height: 70px;
    display: block;
    z-index: 2;
}

/* ============================================================
   6. Секции главной
   ============================================================ */

.front-section {
    position: relative;
    padding: 4rem 0;
    overflow: hidden;
}

.fs-steps,
.fs-facts {
    background-color: var(--bg-alt);
    background-image: linear-gradient(180deg, #E6F0F5 0%, #F1F7FA 100%);
}

.fs-facts {
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='54' viewBox='0 0 180 54'%3E%3Cpath d='M0 28c22-16 45-16 67 0s45 16 67 0 45-16 67 0' fill='none' stroke='%230077A3' stroke-opacity='0.09' stroke-width='1.2'/%3E%3C/svg%3E"),
        linear-gradient(180deg, #E6F0F5 0%, #F1F7FA 100%);
    background-repeat: repeat, no-repeat;
}

.fs-steps::after,
.fs-map::after {
    content: "";
    position: absolute;
    right: -80px;
    bottom: -120px;
    width: 460px;
    height: 460px;
    opacity: 0.03;
    pointer-events: none;
    background-repeat: no-repeat;
    background-size: contain;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Ccircle cx='100' cy='100' r='92' fill='none' stroke='%231A2E3A' stroke-width='4'/%3E%3Ccircle cx='100' cy='100' r='68' fill='none' stroke='%231A2E3A' stroke-width='2'/%3E%3Cpath d='M100 24 118 100 100 176 82 100Z' fill='%231A2E3A'/%3E%3Cpath d='M24 100 100 82 176 100 100 118Z' fill='none' stroke='%231A2E3A' stroke-width='3'/%3E%3C/svg%3E");
}

.section-title {
    position: relative;
    font-size: 1.9rem;
    margin-left: 0.3rem;
    margin-bottom: 1.4rem;
}

.section-title::before {
    content: "";
    display: block;
    width: 33%;
    max-width: 130px;
    height: 2px;
    background: var(--accent);
    margin-bottom: 0.5rem;
}

.section-lead {
    max-width: 62ch;
    color: #33495a;
    margin-bottom: 2.2rem;
}

.section-more {
    margin: 2rem 0 0;
}

.soft-divider {
    width: 60%;
    height: 1px;
    background: var(--line);
    margin: 0 auto;
}

/* --- Блок 2: шаги --- */

.steps-chain {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.6rem;
}

.step-item {
    position: relative;
    min-width: 0;
    padding: 0 0.4rem;
}

.step-item::after {
    content: "";
    position: absolute;
    top: 34px;
    left: calc(50% + 44px);
    right: calc(-50% + 44px);
    border-top: 2px dashed var(--line);
}

.steps-chain .step-item:last-child::after {
    display: none;
}

.step-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 1.5px solid var(--accent);
    color: var(--accent);
    font-family: var(--font-head);
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
    background: #fff;
    margin-bottom: 1rem;
}

.step-title {
    font-size: 1.16rem;
    margin-bottom: 0.4rem;
}

.step-text {
    color: #3a5163;
    font-size: 0.97rem;
    margin: 0;
}

/* --- Блок 3: статистика --- */

.facts-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    background: rgba(255, 255, 255, 0.55);
    border-radius: var(--radius);
    padding: 2rem 1.6rem;
}

.fact {
    min-width: 0;
    text-align: center;
    padding: 0.4rem 1.1rem;
    border-right: 1px solid var(--line);
}

.facts-row .fact:last-child {
    border-right: none;
}

.fact-num {
    display: block;
    font-family: var(--font-head);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1.1;
}

.fact-label {
    display: block;
    margin-top: 0.4rem;
    color: var(--muted);
    font-size: 0.94rem;
    line-height: 1.4;
}

/* --- Блок 4: карта тем --- */

.map-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.4rem;
}

.map-tile {
    position: relative;
    display: block;
    min-width: 0;
    background: #fff;
    border-radius: 12px;
    padding: 1.7rem 1.4rem 1.5rem;
    color: var(--ink);
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 50, 80, 0.06);
    transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.map-tile::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--sand) 100%);
    transition: background 0.25s ease;
}

.map-tile:hover,
.map-tile:focus {
    box-shadow: 0 8px 20px rgba(0, 80, 120, 0.1);
    transform: translateY(-3px);
}

.map-tile:hover::before,
.map-tile:focus::before {
    background: var(--sand);
}

.tile-icon {
    display: block;
    color: var(--accent);
    line-height: 0;
    margin-bottom: 0.9rem;
}

.tile-name {
    display: block;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 0.35rem;
}

.tile-note {
    display: block;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.5;
}

/* ============================================================
   7. Раскладки внутренних страниц
   ============================================================ */

.layout-single {
    display: block;
    width: 85%;
    margin-left: auto;
    margin-right: auto;
}

.layout-with-sidebar {
    display: grid;
    grid-template-columns: minmax(0, 67fr) minmax(0, 27fr);
    gap: 3rem;
    align-items: start;
}

.content-area {
    min-width: 0;
}

.page-head {
    margin-bottom: 2rem;
}

.page-title {
    font-size: 2.3rem;
    margin-bottom: 0.5em;
}

.page-title::after,
.entry-title::after {
    content: "";
    display: block;
    width: 33%;
    max-width: 140px;
    height: 2px;
    background: var(--accent);
    margin-top: 0.5rem;
}

.page-intro {
    color: #33495a;
}

.empty-note {
    background: #fff;
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    padding: 1.4rem 1.6rem;
    color: var(--muted);
}

/* ============================================================
   8. Хлебные крошки
   ============================================================ */

.crumbs {
    font-size: 0.9rem;
    color: var(--muted);
    margin-bottom: 1.6rem;
    line-height: 1.6;
}

.crumbs a {
    color: var(--accent);
}

.crumbs a:hover {
    color: var(--accent-dark);
}

.crumbs .sep {
    color: var(--line);
    margin: 0 0.25rem;
}

/* ============================================================
   9. Карточки записей
   ============================================================ */

.cards-flow {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.6rem;
}

.card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    box-shadow: 0 4px 12px rgba(0, 50, 80, 0.06);
    overflow: hidden;
    transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--sand) 100%);
    z-index: 2;
}

.card:hover {
    box-shadow: 0 8px 20px rgba(0, 80, 120, 0.1);
    transform: translateY(-3px);
    border-bottom-color: var(--accent);
}

.card-thumb-wrap {
    flex: 0 0 280px;
    position: relative;
    overflow: hidden;
    min-height: 180px;
}

.card-thumb-wrap a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.card-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-body {
    flex: 1;
    min-width: 0;
    padding: 1.5rem 1.6rem 1.3rem;
}

.card-title {
    font-size: 1.28rem;
    margin-bottom: 0.5rem;
}

.card-title a {
    color: var(--ink);
}

.card-title a:hover {
    color: var(--accent);
}

.card-excerpt {
    color: #3a5163;
    font-size: 0.98rem;
}

.card-excerpt p {
    margin: 0 0 0.5em;
    background: none;
}

.card-more {
    margin: 0.9rem 0 0;
}

.read-link {
    font-family: var(--font-head);
    font-weight: 600;
    color: var(--accent);
}

.read-link:hover {
    color: var(--accent-dark);
}

@media (min-width: 601px) {
    .card {
        flex-direction: row;
    }
}

/* Мета-таблички */

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.8rem;
}

.chip {
    display: inline-block;
    background: var(--bg-alt);
    border-radius: 2px;
    padding: 0.18rem 0.55rem;
    font-family: var(--font-head);
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    font-variant-caps: small-caps;
    text-transform: lowercase;
    color: var(--muted);
}

.chip-link {
    color: var(--accent);
}

.chip-link:hover {
    background: var(--accent);
    color: #fff;
}

/* ============================================================
   10. Запись и страница
   ============================================================ */

.entry {
    background: #fff;
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    box-shadow: 0 4px 12px rgba(0, 50, 80, 0.06);
    padding: 2.2rem 2.4rem 2rem;
    position: relative;
    overflow: hidden;
}

.entry::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--sand) 100%);
}

.entry-title {
    font-size: 2.2rem;
}

.entry-cover {
    margin: 0 0 1.6rem;
}

.entry-cover img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: var(--radius);
}

.entry-content h2 {
    margin-top: 1.8em;
}

.entry-content h3 {
    margin-top: 1.5em;
}

.entry-content ul,
.entry-content ol {
    padding-left: 0;
    margin: 0 0 1.2em;
}

.entry-content ul {
    list-style: none;
}

.entry-content ul li {
    position: relative;
    padding-left: 1.8em;
    margin-bottom: 0.5em;
}

.entry-content ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 18px;
    height: 12px;
    background-repeat: no-repeat;
    background-size: contain;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 16'%3E%3Cpath d='M1 12c5 0 6-9 11-9 4 0 5 6 1 6s-5-6-1-6c5 0 6 9 11 9' fill='none' stroke='%230077A3' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
}

.entry-content ol {
    padding-left: 1.4em;
}

.entry-content ol li {
    margin-bottom: 0.5em;
}

.entry-content blockquote {
    margin: 1.6em 0;
    padding: 1.5rem 1.8rem;
    background: linear-gradient(135deg, #0077A3 0%, #1A4B62 100%);
    border-radius: var(--radius);
    color: #fff;
    font-size: 1.08rem;
}

.entry-content blockquote p:last-child {
    margin-bottom: 0;
}

.entry-content img {
    border-radius: var(--radius);
    display: block;
}

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.4em 0;
    border: 1px solid var(--line);
}

.entry-content th,
.entry-content td {
    border: 1px solid var(--line);
    padding: 0.6rem 0.8rem;
    text-align: left;
}

.entry-content th {
    background: var(--bg-alt);
    font-family: var(--font-head);
}

.entry-content code,
.entry-content pre {
    background: var(--bg-alt);
    border-radius: 4px;
}

.entry-content pre {
    padding: 1rem 1.2rem;
    overflow-x: auto;
}

.entry-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 1.6rem;
}

.page-links {
    margin-top: 1.4rem;
    font-family: var(--font-head);
}

.entry-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    margin-top: 1.6rem;
}

.entry-nav-link {
    flex: 1 1 45%;
    min-width: 0;
    background: #fff;
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    padding: 0.9rem 1.2rem;
    font-family: var(--font-head);
    font-size: 0.98rem;
    color: var(--ink);
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.entry-nav-link:hover {
    border-bottom-color: var(--accent);
    transform: translateY(-1px);
    color: var(--accent);
}

.entry-nav-link.next {
    text-align: right;
}

/* ============================================================
   11. Сайдбар и виджеты
   ============================================================ */

.sidebar {
    min-width: 0;
}

.sidebar .widget {
    background: #FFFFFF;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.4rem 1.5rem;
    margin-bottom: 1.4rem;
    color: var(--ink);
    position: relative;
    overflow: hidden;
}

.sidebar .widget::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--sand) 100%);
}

.widget-title {
    font-size: 1.1rem;
    margin-bottom: 0.9rem;
}

.sidebar .widget-title {
    color: var(--ink);
}

.sidebar .widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar .widget li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--line);
    line-height: 1.45;
}

.sidebar .widget li:last-child {
    border-bottom: none;
}

.sidebar .widget a {
    color: var(--accent);
}

.sidebar .widget a:hover {
    color: var(--accent-dark);
}

.sidebar .widget .post-date {
    display: block;
    color: var(--muted);
    font-size: 0.82rem;
    font-family: var(--font-head);
}

/* ============================================================
   12. Пагинация
   ============================================================ */

.pager {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 2.2rem;
}

.pager .page-numbers {
    display: inline-block;
    min-width: 44px;
    text-align: center;
    padding: 0.55rem 0.9rem;
    border: 1.5px solid var(--line);
    border-radius: 6px;
    background: #fff;
    color: var(--accent);
    font-family: var(--font-head);
    font-size: 0.98rem;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.pager a.page-numbers:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    color: #fff;
    transform: translateY(-1px);
}

.pager .page-numbers.current {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.pager .page-numbers.dots {
    border-color: transparent;
    background: transparent;
    color: var(--muted);
}

/* ============================================================
   13. Форма поиска и комментарии
   ============================================================ */

.search-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.6rem;
}

.search-label {
    display: block;
    flex: 1 1 220px;
    min-width: 0;
}

.search-label-text {
    display: block;
    font-family: var(--font-head);
    font-size: 0.85rem;
    color: var(--muted);
    margin-bottom: 0.3rem;
}

.search-field {
    width: 100%;
    padding: 0.65rem 0.9rem;
    border: 1.5px solid var(--line);
    border-radius: 6px;
    background: #fff;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1rem;
}

.search-field:focus {
    outline: none;
    border-color: var(--accent);
}

.notfound-tools {
    margin-top: 1.8rem;
    background: #fff;
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    padding: 1.6rem 1.8rem;
}

.notfound-home {
    margin: 1.2rem 0 0;
}

.comments-block {
    margin-top: 2.4rem;
    background: #fff;
    border-radius: var(--radius);
    border-bottom: 2px solid var(--line);
    box-shadow: 0 4px 12px rgba(0, 50, 80, 0.06);
    padding: 1.9rem 2rem;
}

.comments-title {
    font-size: 1.35rem;
}

.comment-list,
.comment-list .children {
    list-style: none;
    margin: 0;
    padding: 0;
}

.comment-list .children {
    margin-left: 1.4rem;
    border-left: 2px solid var(--line);
    padding-left: 1.2rem;
}

.comment-item {
    margin-bottom: 1.2rem;
}

.comment-inner {
    background: var(--bg-main);
    border-radius: var(--radius);
    padding: 1rem 1.2rem;
}

.comment-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.comment-author {
    font-family: var(--font-head);
    font-weight: 700;
}

.comment-actions {
    font-family: var(--font-head);
    font-size: 0.92rem;
}

.comment-respond {
    margin-top: 1.6rem;
}

.comment-form label {
    display: block;
    font-family: var(--font-head);
    font-size: 0.9rem;
    color: var(--muted);
    margin-bottom: 0.3rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 0.65rem 0.9rem;
    border: 1.5px solid var(--line);
    border-radius: 6px;
    background: #fff;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1rem;
}

.comment-form textarea:focus,
.comment-form input:focus {
    outline: none;
    border-color: var(--accent);
}

.comment-form p {
    margin-bottom: 1rem;
}

.comment-form .submit {
    background: var(--accent);
    color: #fff;
    border: 1.5px solid var(--accent);
    border-radius: 6px;
    padding: 0.72rem 1.5rem;
    font-family: var(--font-head);
    font-weight: 600;
    cursor: pointer;
}

.comment-form .submit:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    transform: translateY(-1px);
}

/* ============================================================
   14. Подвал
   ============================================================ */

.site-bottom {
    background: var(--bg-deep);
    color: #D6E4EC;
    padding: 3.2rem 0 1.8rem;
    margin-top: 3rem;
}

.foot-cols {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.4rem;
}

.foot-col {
    min-width: 0;
}

.site-bottom .widget {
    color: #D6E4EC;
    font-size: 0.96rem;
}

.site-bottom .widget-title {
    color: #FFFFFF;
    font-size: 1.05rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.site-bottom .widget-title::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 46px;
    height: 2px;
    background: var(--sand);
}

.site-bottom .widget a {
    color: #A8D3E8;
}

.site-bottom .widget a:hover {
    color: var(--sand);
}

.site-bottom .widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-bottom .widget li {
    padding: 0.38rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-bottom .widget li:last-child {
    border-bottom: none;
}

.site-bottom .widget .post-date {
    display: block;
    color: #8FA9B8;
    font-size: 0.82rem;
}

.foot-line {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.8rem;
    align-items: center;
    margin-top: 2.4rem;
    padding-top: 1.4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.copyright,
.foot-mail {
    margin: 0;
    font-size: 0.9rem;
    color: #9FB8C6;
}

.foot-mail a {
    color: #A8D3E8;
}

.foot-mail a:hover {
    color: var(--sand);
}

/* ============================================================
   15. Cookie-баннер
   ============================================================ */

.cookie-banner[hidden] {
    display: none !important;
}

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    padding: 1rem 1.6rem;
    background: var(--bg-deep);
    color: #D6E4EC;
    border-top: 3px solid var(--sand);
}

.cookie-text {
    margin: 0;
    font-size: 0.92rem;
    max-width: 70ch;
}

/* ============================================================
   16. Адаптив
   ============================================================ */

@media (max-width: 960px) {
    body {
        font-size: 16px;
    }

    .is-front .shell {
        width: min(92%, var(--shell));
    }

    .nav-toggle {
        display: flex;
    }

    .primary-nav {
        display: none;
        flex: 1 1 100%;
        width: 100%;
    }

    .primary-nav.is-open {
        display: block;
        background: var(--bg-deep);
        border-radius: var(--radius);
        padding: 0.8rem;
        margin-top: 0.6rem;
    }

    .nav-list {
        flex-direction: column;
        align-items: stretch;
        gap: 0.35rem;
    }

    .hero {
        padding: 9rem 0 6rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .layout-with-sidebar {
        grid-template-columns: minmax(0, 1fr);
        gap: 2.2rem;
    }

    .layout-single {
        width: 100%;
    }

    .steps-chain,
    .map-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .step-item::after {
        display: none;
    }

    .facts-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 1.6rem;
    }

    .facts-row .fact:nth-child(2n) {
        border-right: none;
    }

    .foot-cols {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.8rem;
    }
}

@media (max-width: 600px) {
    .front-section {
        padding: 2.8rem 0;
    }

    .hero {
        padding: 8rem 0 4.5rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-sub {
        font-size: 1rem;
    }

    .page-title,
    .entry-title {
        font-size: 1.75rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .entry {
        padding: 1.5rem 1.3rem;
    }

    .comments-block {
        padding: 1.4rem 1.2rem;
    }

    .facts-row {
        grid-template-columns: minmax(0, 1fr);
        padding: 1.6rem 1.4rem;
    }

    .fact {
        border-right: none;
        border-bottom: 1px solid var(--line);
        padding-bottom: 1.1rem;
    }

    .facts-row .fact:last-child {
        border-bottom: none;
        padding-bottom: 0.4rem;
    }

    .steps-chain,
    .map-grid,
    .foot-cols {
        grid-template-columns: minmax(0, 1fr);
    }

    .entry-content blockquote {
        padding: 1.2rem 1.2rem;
    }

    .map-tile {
        padding: 1.4rem 1.3rem;
    }

    .notfound-tools {
        padding: 1.3rem 1.2rem;
    }

    .cookie-banner {
        padding: 1rem 1.2rem;
        gap: 0.8rem;
    }

    .card-thumb-wrap {
        flex: none;
        width: 100%;
        position: static;
        min-height: 0;
    }

    .card-thumb-wrap a {
        position: static;
    }

    .card-thumb-wrap img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    .card-body {
        padding: 1.2rem 1.2rem 1.1rem;
    }

    .entry-nav-link {
        flex: 1 1 100%;
    }

    .entry-nav-link.next {
        text-align: left;
    }
}
