/*
Theme Name: dds_tatiana-fokina-blog.ru
Author: Юлия Кузьмина
Description: Тема для информационного сайта о фронтенд-разработке и веб-доступности.
Version: 1.1
Requires at least: 6.0
Requires PHP: 8.0
Text Domain: a11yfok
*/

:root {
    --bg: #F4F2F9;
    --bg-alt: #EBE5F5;
    --paper: #FFFFFF;
    --dark: #1A1528;
    --dark-soft: #2D2640;
    --ink: #2A1F3D;
    --accent: #7C5CBF;
    --accent-2: #A78BDB;
    --muted: #8C7A9E;
    --line: #D9D0E8;
    --shadow-soft: 0 10px 30px rgba(42, 31, 61, .08);
    --shadow-lift: 0 18px 40px rgba(124, 92, 191, .20);
    --radius: 12px;
    --font-head: "Manrope", "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: "Roboto", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    margin: 0;
    overflow-x: hidden;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.72;
    background-color: var(--bg);
    background-image: radial-gradient(circle, rgba(124, 92, 191, .16) 1px, transparent 1.2px);
    background-size: 22px 22px;
}

body::before,
body::after {
    content: "";
    position: fixed;
    z-index: -1;
    pointer-events: none;
    border-radius: 50%;
    filter: blur(90px);
}

body::before {
    width: 420px;
    height: 420px;
    top: -140px;
    right: -120px;
    background: rgba(167, 139, 219, .45);
}

body::after {
    width: 480px;
    height: 480px;
    bottom: -180px;
    left: -160px;
    background: rgba(124, 92, 191, .22);
}

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

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

h1 { font-size: 3.5rem; }
h2 { font-size: 2.1rem; }
h3 { font-size: 1.45rem; }
h4 { font-size: 1.2rem; }

p { margin: 0 0 1.15em; }

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

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

.wide-inner {
    width: min(85%, 1180px);
    margin-inline: auto;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--accent);
    color: #fff;
    padding: .7rem 1.2rem;
    z-index: 999;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ---------------------------------------------------------------- Шапка */

.site-head {
    background: rgba(255, 255, 255, .74);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}

.head-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: .9rem;
    min-width: 0;
    text-decoration: none;
    color: var(--ink);
}

.brand-logo,
.brand-mark {
    flex: 0 0 auto;
    display: block;
    width: 52px;
    height: 52px;
    border-radius: 10px;
}

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

.brand-name {
    display: block;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.05rem;
    line-height: 1.3;
    color: var(--ink);
}

.brand-desc {
    display: block;
    font-size: .8rem;
    color: var(--muted);
    line-height: 1.4;
    margin-top: .2rem;
}

.nav-toggle {
    display: none;
    border: 1px solid var(--accent);
    background: transparent;
    color: var(--accent);
    border-radius: 8px;
    padding: .55rem .9rem;
    font: inherit;
    font-size: .92rem;
    cursor: pointer;
}

.main-nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 1.6rem;
    margin: 0;
    padding: 0;
}

.main-nav a {
    position: relative;
    text-decoration: none;
    color: var(--ink);
    font-weight: 600;
    font-size: .97rem;
    padding-bottom: 4px;
}

.main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: 0;
    background: var(--accent);
    transition: width .3s ease;
}

.main-nav a:hover::after,
.main-nav .current-menu-item > a::after { width: 100%; }
.main-nav .current-menu-item > a { color: var(--accent); }

/* ------------------------------------------------------------ Раскладка */

.site-main { padding: 2.6rem 0 3.4rem; }
.front-main { padding: 0 0 3rem; }

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

.layout-single .content-area {
    width: 85%;
    margin-left: auto;
    margin-right: auto;
    min-width: 0;
}

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

.sidebar {
    min-width: 0;
    background: rgba(255, 255, 255, .6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--radius);
    padding: 1.6rem 1.5rem;
    box-shadow: var(--shadow-soft);
}

/* ------------------------------------------------------- Хлебные крошки */

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

.crumbs a {
    color: var(--accent);
    text-decoration: none;
}
.crumbs a:hover { text-decoration: underline; }
.crumbs-sep { color: var(--line); margin: 0 .25rem; }

/* -------------------------------------------------- Заголовки и кнопки */

.sec-title {
    position: relative;
    padding-left: 1.7rem;
    margin: 0 0 1.9rem;
}

.sec-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: .55em;
    width: 13px;
    height: 13px;
    border-radius: 3px;
    background: var(--accent);
}

.sec-title::after {
    content: "";
    display: block;
    width: 46%;
    max-width: 260px;
    height: 3px;
    margin-top: .75rem;
    border-radius: 3px;
    background: var(--accent);
}

.sec-title.on-dark { color: #fff; }
.sec-title.on-dark::before,
.sec-title.on-dark::after { background: var(--accent-2); }

.btn {
    display: inline-block;
    padding: .85rem 1.7rem;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    font-size: .98rem;
    text-decoration: none;
    border: 1px solid var(--accent);
    box-shadow: 0 8px 18px rgba(124, 92, 191, .28), inset 0 1px 0 rgba(255, 255, 255, .25);
    transition: transform .25s ease, background-color .25s ease, box-shadow .25s ease;
}

.btn:hover,
.btn:focus {
    background: var(--accent-2);
    border-color: var(--accent-2);
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(124, 92, 191, .34);
}

.btn-ghost {
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    box-shadow: none;
}

.btn-ghost:hover,
.btn-ghost:focus {
    background: transparent;
    color: var(--accent-2);
    border-color: var(--accent-2);
    box-shadow: 0 10px 22px rgba(124, 92, 191, .22);
}

.btn-light {
    background: var(--accent-2);
    border-color: var(--accent-2);
    color: var(--dark);
}
.btn-light:hover { background: #fff; border-color: #fff; color: var(--dark); }

/* ------------------------------------------------------------ Карточки */

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

.card {
    display: flex;
    flex-direction: column;
    background: var(--paper);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: transform .28s ease, box-shadow .28s ease, background-color .28s ease;
    min-width: 0;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lift);
    background: var(--bg-alt);
}

.card-thumb {
    display: block;
    width: 100%;
}

.card-thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.card-thumb-empty {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #A78BDB 0%, #7C5CBF 55%, #3C4E8F 100%);
}

.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 1.3rem 1.4rem 1.5rem;
    min-width: 0;
}

.card-title {
    font-size: 1.18rem;
    margin: 0 0 .55rem;
}

.card-title a {
    color: var(--ink);
    text-decoration: none;
}
.card-title a:hover { color: var(--accent); }

.card-excerpt {
    color: #4a3d5f;
    font-size: .96rem;
    margin-bottom: 1rem;
}

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

.card-more { margin-top: auto; }

.card-more a {
    display: inline-block;
    color: var(--accent);
    font-weight: 600;
    font-size: .92rem;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color .25s ease, color .25s ease;
}
.card-more a:hover { color: var(--accent-2); border-color: var(--accent-2); }

.post-meta {
    font-size: .82rem;
    color: var(--muted);
    margin-bottom: .6rem;
}
.post-meta a { color: var(--muted); text-decoration: none; }
.post-meta a:hover { color: var(--accent); }
.meta-sep { margin: 0 .3rem; }

/* Горизонтальная карточка ленты */

.card-row {
    flex-direction: row;
    margin-bottom: 1.6rem;
}

.card-thumb-wrap {
    flex: 0 0 300px;
    position: relative;
    overflow: hidden;
    min-height: 210px;
    background: linear-gradient(135deg, #A78BDB 0%, #7C5CBF 55%, #3C4E8F 100%);
}

.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;
}

/* ---------------------------------------------------------- Пагинация */

.pager {
    display: flex;
    flex-wrap: wrap;
    gap: .55rem;
    margin-top: 2.4rem;
}

.pager .page-numbers {
    display: inline-block;
    padding: .55rem 1rem;
    border-radius: 8px;
    background: var(--paper);
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
    font-size: .95rem;
    box-shadow: var(--shadow-soft);
    transition: transform .22s ease, background-color .22s ease, color .22s ease;
}

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

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

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

/* ----------------------------------------------------- Главная: секции */

.front-section { padding: 4.2rem 0; }
.front-section.alt-bg { background: var(--bg-alt); }
.front-section.dark-bg { background: var(--dark-soft); color: #efeaf7; }

.wave-bottom { position: relative; }

.wave-bottom::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 20'%3E%3Cpath d='M0 12 Q30 0 60 12 T120 12 V20 H0 Z' fill='%23D9D0E8'/%3E%3C/svg%3E");
    background-repeat: repeat-x;
    background-size: 120px 20px;
    pointer-events: none;
}

.sec-lead {
    max-width: 720px;
    color: #4a3d5f;
    margin-bottom: 2.2rem;
}

/* Hero */

.hero {
    background: linear-gradient(125deg, #2D2640 0%, #4B3A82 42%, #7C5CBF 72%, #3C4E8F 100%);
    padding: 4.6rem 0 4.9rem;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    gap: 2.8rem;
    align-items: center;
}

.hero h1 {
    color: #fff;
    margin-bottom: 1.1rem;
}

.hero-sub {
    font-size: 1.1rem;
    color: #E4DCF5;
    max-width: 620px;
    margin-bottom: 1.9rem;
}

.hero-tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    padding: 0;
    margin: 0 0 1.9rem;
}

.hero-tags li {
    font-size: .85rem;
    padding: .35rem .85rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .24);
    color: #EDE7F8;
}

.hero-art { min-width: 0; }
.hero-art svg { display: block; width: 100%; height: auto; }

/* Таймлайн */

.tl { position: relative; margin-top: 2.6rem; }

.tl::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    margin-left: -1px;
    background: var(--accent);
    opacity: .35;
}

.tl-item {
    position: relative;
    width: 50%;
    padding: 0 2.6rem 2.2rem 0;
    min-width: 0;
}

.tl-item:nth-child(even) {
    margin-left: 50%;
    padding: 0 0 2.2rem 2.6rem;
}

.tl-item::before {
    content: "";
    position: absolute;
    top: .55rem;
    right: -8px;
    width: 15px;
    height: 15px;
    border-radius: 4px;
    background: var(--accent);
    box-shadow: 0 0 0 5px rgba(124, 92, 191, .16);
}

.tl-item:nth-child(even)::before {
    right: auto;
    left: -8px;
}

.tl-card {
    background: var(--paper);
    border-radius: var(--radius);
    padding: 1.4rem 1.5rem;
    box-shadow: var(--shadow-soft);
    transition: transform .26s ease, box-shadow .26s ease;
}

.tl-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }

.tl-step {
    display: inline-block;
    font-family: var(--font-head);
    font-size: .78rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: .4rem;
}

.tl-card h3 { font-size: 1.2rem; margin-bottom: .45rem; }
.tl-card p { margin: 0; font-size: .95rem; color: #4a3d5f; }

/* Статистика */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.8rem;
    margin-top: 2.4rem;
}

.stat-cell { min-width: 0; }

.stat-num {
    display: block;
    font-family: var(--font-head);
    font-size: 3.1rem;
    font-weight: 800;
    line-height: 1.05;
    color: #fff;
}

.stat-label {
    display: block;
    margin-top: .5rem;
    color: var(--accent-2);
    font-size: .95rem;
}

.dark-bg .sec-lead { color: #C9BEDF; }

/* Карта тем */

.topic-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 2.2rem;
}

.topic-tile {
    display: block;
    min-width: 0;
    background: var(--paper);
    border-radius: var(--radius);
    padding: 1.6rem 1.5rem;
    text-decoration: none;
    color: var(--ink);
    box-shadow: var(--shadow-soft);
    transition: transform .26s ease, box-shadow .26s ease, background-color .26s ease;
}

.topic-tile:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lift);
    background: var(--bg-alt);
}

.topic-tile svg {
    display: block;
    width: 42px;
    height: 42px;
    margin-bottom: .9rem;
}

.topic-tile h3 { font-size: 1.12rem; margin-bottom: .4rem; }
.topic-tile p { margin: 0; font-size: .92rem; color: var(--muted); }

/* Блок последних записей */

.latest-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.latest-head .sec-title { margin-bottom: 1.2rem; }

/* -------------------------------------------------------- Контент поста */

.entry-head { margin-bottom: 1.6rem; }
.entry-title { font-size: 2.5rem; margin-bottom: .6rem; }

.entry-thumb {
    display: block;
    width: 100%;
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 1.8rem;
    box-shadow: var(--shadow-soft);
}

.entry-thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 8;
    object-fit: cover;
}

.entry-content { font-size: 1.03rem; }

.entry-content h2 { font-size: 1.75rem; margin: 2rem 0 .8rem; }
.entry-content h3 { font-size: 1.35rem; margin: 1.7rem 0 .7rem; }

.entry-content a {
    color: var(--accent);
    text-decoration: none;
    background-image: linear-gradient(var(--accent), var(--accent));
    background-repeat: no-repeat;
    background-size: 0 2px;
    background-position: 0 100%;
    transition: background-size .3s ease;
}

.entry-content a:hover { background-size: 100% 2px; }

.entry-content ul,
.entry-content ol { padding-left: 1.4rem; }

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

.entry-content ul li {
    position: relative;
    padding-left: 1.6rem;
    margin-bottom: .5rem;
}

.entry-content ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .62em;
    width: 9px;
    height: 9px;
    border-radius: 2px;
    background: var(--accent);
}

.entry-content ol li { margin-bottom: .5rem; }

.entry-content blockquote {
    margin: 1.8rem 0;
    padding: 1.4rem 1.6rem;
    background: var(--bg-alt);
    border-left: 4px solid var(--accent);
    border-radius: 10px;
    color: var(--ink);
}

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

.entry-content img { border-radius: 10px; display: block; }

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.6rem 0;
    background: var(--paper);
    border: 1px solid var(--line);
}

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

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

.entry-content pre {
    background: var(--dark-soft);
    color: #EDE7F8;
    padding: 1.2rem;
    border-radius: 10px;
    overflow-x: auto;
    min-width: 0;
}

.entry-content code { font-size: .93em; }

.entry-footer {
    margin-top: 2rem;
    padding-top: 1.2rem;
    border-top: 1px solid var(--line);
    font-size: .92rem;
    color: var(--muted);
}

.entry-footer a { color: var(--accent); text-decoration: none; }
.entry-footer a:hover { text-decoration: underline; }

.page-title-block { margin-bottom: 1.8rem; }

/* --------------------------------------------------------- Комментарии */

.comments-area {
    margin-top: 2.8rem;
    background: var(--paper);
    border-radius: var(--radius);
    padding: 1.8rem 1.7rem;
    box-shadow: var(--shadow-soft);
}

.comments-title { font-size: 1.5rem; margin-bottom: 1.3rem; }

.comment-list {
    list-style: none;
    margin: 0 0 1.8rem;
    padding: 0;
}

.comment-list ol.children {
    list-style: none;
    margin: 1rem 0 0;
    padding-left: 1.4rem;
    border-left: 2px solid var(--line);
}

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

.comment-head {
    display: flex;
    align-items: baseline;
    gap: .8rem;
    flex-wrap: wrap;
    margin-bottom: .4rem;
}

.comment-author { font-family: var(--font-head); font-weight: 700; }
.comment-author a { color: var(--ink); text-decoration: none; }
.comment-date { font-size: .82rem; color: var(--muted); }
.comment-text p { margin-bottom: .6em; }
.comment-hold { font-size: .88rem; color: var(--muted); }
.comment-actions a { color: var(--accent); font-size: .9rem; text-decoration: none; }
.comment-actions a:hover { text-decoration: underline; }

.comment-respond { margin-top: 1.4rem; }
.comment-reply-title { font-size: 1.25rem; }

.comment-form label {
    display: block;
    font-size: .9rem;
    font-weight: 600;
    margin-bottom: .3rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: .7rem .9rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    font: inherit;
    font-size: .96rem;
    background: var(--bg);
    color: var(--ink);
}

.comment-form textarea { min-height: 150px; }

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

.comment-form .submit {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: .8rem 1.6rem;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(124, 92, 191, .28);
    transition: transform .25s ease, background-color .25s ease;
}

.comment-form .submit:hover { background: var(--accent-2); transform: translateY(-2px); }

/* -------------------------------------------------------------- Поиск */

.vh {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.page-links {
    margin-top: 1.3rem;
    font-size: .92rem;
    color: var(--muted);
}

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

.search-form {
    display: flex;
    gap: .6rem;
    min-width: 0;
}

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

.search-form .search-field {
    flex: 1;
    min-width: 0;
    padding: .7rem .9rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    font: inherit;
    font-size: .95rem;
    background: var(--paper);
    color: var(--ink);
}

.search-form .search-submit {
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    padding: .7rem 1.2rem;
    cursor: pointer;
    transition: background-color .25s ease;
}

.search-form .search-submit:hover { background: var(--accent-2); }

/* ------------------------------------------------------------ Виджеты */

.widget { margin-bottom: 1.8rem; }
.widget:last-child { margin-bottom: 0; }

.widget-title {
    position: relative;
    font-size: 1.05rem;
    padding-left: 1.1rem;
    margin-bottom: .9rem;
}

.widget-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: .5em;
    width: 8px;
    height: 8px;
    border-radius: 2px;
    background: var(--accent);
}

.sidebar .widget,
.sidebar .widget p,
.sidebar .widget li { color: var(--ink); }

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

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

.sidebar .widget li {
    padding: .5rem 0;
    border-bottom: 1px solid var(--line);
    font-size: .95rem;
}

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

.sidebar .widget a {
    color: var(--ink);
    text-decoration: none;
}

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

.sidebar .widget .post-date {
    display: block;
    font-size: .8rem;
    color: var(--muted);
    margin-top: .15rem;
}

/* --------------------------------------------------------------- Подвал */

.site-foot {
    background: var(--dark);
    color: #D6CDE8;
    padding: 3.2rem 0 1.8rem;
    margin-top: 3rem;
}

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

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

.site-foot .widget-title {
    color: #FFFFFF;
    font-size: 1.05rem;
}

.site-foot .widget-title::before { background: var(--accent-2); }

.site-foot .widget,
.site-foot .widget p,
.site-foot .widget li,
.site-foot .widget span { color: #D6CDE8; }

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

.site-foot .widget li {
    padding: .42rem 0;
    font-size: .95rem;
    border-bottom: 1px solid rgba(214, 205, 232, .12);
}

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

.site-foot .widget a {
    color: #D6CDE8;
    text-decoration: none;
    transition: color .22s ease;
}

.site-foot .widget a:hover { color: var(--accent-2); }

.site-foot .widget .post-date { color: #9C8FB4; font-size: .8rem; display: block; }

.foot-bottom {
    margin-top: 2.6rem;
    padding-top: 1.3rem;
    border-top: 1px solid rgba(214, 205, 232, .16);
    font-size: .88rem;
    color: #9C8FB4;
}

/* ------------------------------------------------------- Cookie-баннер */

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

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.2rem;
    flex-wrap: wrap;
    padding: 1.1rem 1.6rem;
    background: rgba(26, 21, 40, .96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #E6DFF3;
    font-size: .92rem;
    box-shadow: 0 -8px 26px rgba(26, 21, 40, .28);
}

.cookie-banner p { margin: 0; min-width: 0; }
.cookie-banner a { color: var(--accent-2); }

.cookie-accept {
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    padding: .6rem 1.4rem;
    cursor: pointer;
    transition: background-color .25s ease, transform .25s ease;
}

.cookie-accept:hover { background: var(--accent-2); transform: translateY(-2px); }

/* --------------------------------------------------------------- 404 */

.err-block {
    background: var(--paper);
    border-radius: var(--radius);
    padding: 2.4rem 2.2rem;
    box-shadow: var(--shadow-soft);
    width: 85%;
    margin-left: auto;
    margin-right: auto;
}

.err-code {
    font-family: var(--font-head);
    font-size: 4.4rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    margin-bottom: .6rem;
}

.err-block .search-form { margin: 1.4rem 0; max-width: 460px; }

/* ------------------------------------------------------------ Адаптив */

@media (max-width: 960px) {
    h1 { font-size: 2.6rem; }
    h2 { font-size: 1.8rem; }

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

    .layout-single .content-area { width: 100%; }
    .wide-inner { width: min(92%, 1180px); }
    .err-block { width: 100%; }

    .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .topic-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; }

    .hero-inner { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
    .hero-art { max-width: 420px; }

    .nav-toggle { display: inline-block; }

    .main-nav {
        flex: 1 0 100%;
        display: none;
    }

    .main-nav.is-open { display: block; }

    .main-nav ul {
        flex-direction: column;
        gap: .1rem;
        padding-top: .8rem;
    }

    .main-nav li { border-bottom: 1px solid var(--line); }
    .main-nav a { display: block; padding: .7rem 0; }
    .main-nav a::after { display: none; }

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

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

    h1 { font-size: 2.1rem; }
    h2 { font-size: 1.55rem; }

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

    .front-section { padding: 3rem 0; }
    .hero { padding: 3.2rem 0 3.4rem; }

    .card-grid { grid-template-columns: minmax(0, 1fr); }
    .topic-grid { grid-template-columns: minmax(0, 1fr); }
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

    .stat-num { font-size: 2.4rem; }

    .card-row { flex-direction: column; }

    .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;
    }

    .tl::before { left: 7px; }

    .tl-item,
    .tl-item:nth-child(even) {
        width: 100%;
        margin-left: 0;
        padding: 0 0 1.8rem 2.2rem;
    }

    .tl-item::before,
    .tl-item:nth-child(even)::before {
        left: 0;
        right: auto;
    }

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

    .comments-area { padding: 1.4rem 1.2rem; }
    .err-block { padding: 1.6rem 1.4rem; }
    .sidebar { padding: 1.3rem 1.2rem; }
    .cookie-banner { padding: 1rem 1.2rem; }
}
