/*
Theme Name: zolotoy-gramofon.ru
Theme URI: https://zolotoy-gramofon.ru/
Author: Черных Юлия
Author URI: https://zolotoy-gramofon.ru/
Description: Блог ивент-организатора: кейсы, ошибки и лайфхаки. Винтажно-современная тема в стиле «закулисье и золотой граммофон».
Version: 1.1
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
Text Domain: zolotoy-gramofon
*/

/* ==========================================================================
   Базовые сбросы и переменные
   ========================================================================== */

:root {
    --color-bg: #121212;
    --color-text: #F5EFE6;
    --color-gold: #C5A059;
    --color-gold-dim: #9C7A3D;
    --color-terracotta: #C05A3B;
    --color-anthracite: #1E2426;
    --color-anthracite-dark: #161B1C;
    --shadow-card: 6px 8px 0 rgba(0, 0, 0, 0.45);
    --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
    --font-body: 'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background-color: var(--color-bg);
    background-image:
        radial-gradient(circle at 20% 0%, rgba(197, 160, 89, 0.04), transparent 60%),
        radial-gradient(circle at 80% 100%, rgba(192, 90, 59, 0.03), transparent 55%);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.65;
    min-height: 100vh;
}

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

a {
    color: var(--color-terracotta);
    text-decoration: none;
    transition: color 0.18s ease, border-color 0.18s ease;
}

a:hover, a:focus {
    color: var(--color-gold);
    text-decoration: underline;
    text-decoration-color: var(--color-gold);
    text-underline-offset: 3px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.25;
    margin: 1.4em 0 0.6em;
    color: var(--color-text);
    letter-spacing: 0.005em;
}

h1 { font-size: 2.1rem; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.15rem; }

p {
    margin: 0 0 1.1em;
}

ul, ol {
    margin: 0 0 1.1em;
    padding-left: 1.4em;
}

li { margin-bottom: 0.4em; }

blockquote {
    margin: 1.6em 0;
    padding: 1.2em 1.4em;
    background: var(--color-anthracite);
    border-left: 3px solid var(--color-gold);
    font-style: italic;
    color: #E8DFCD;
}

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

code, pre {
    font-family: 'JetBrains Mono', Consolas, Monaco, monospace;
    background: var(--color-anthracite-dark);
    color: var(--color-gold);
    border: 1px solid var(--color-gold-dim);
}

code { padding: 0.12em 0.4em; font-size: 0.92em; }

pre {
    padding: 1em 1.2em;
    overflow-x: auto;
    margin: 1.4em 0;
}

pre code { background: transparent; border: 0; padding: 0; }

hr {
    border: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-gold-dim), transparent);
    margin: 2.2em 0;
}

/* Таблицы */
table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--color-gold-dim);
    margin: 1.4em 0;
    font-size: 0.95em;
}
th, td {
    border: 1px solid var(--color-gold-dim);
    padding: 0.7em 0.9em;
    text-align: left;
}
th {
    background: var(--color-anthracite);
    color: var(--color-gold);
    font-family: var(--font-display);
    font-weight: 700;
}
tr:nth-child(even) td { background: rgba(30, 36, 38, 0.5); }

/* ==========================================================================
   Доступность
   ========================================================================== */

.screen-reader-text {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0,0,0,0);
    border: 0;
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--color-gold);
    color: var(--color-anthracite);
    padding: 0.5em 1em;
    z-index: 1000;
}
.skip-link:focus { top: 0; }

/* ==========================================================================
   Контейнер
   ========================================================================== */

.wrap {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 22px;
}

/* ==========================================================================
   Шапка / занавес
   ========================================================================== */

.site-header {
    background: linear-gradient(180deg, #0E0E0E 0%, #181818 100%);
    border-bottom: 1px solid rgba(156, 122, 61, 0.35);
    position: relative;
    overflow: hidden;
}

.site-header::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(180deg, rgba(156, 122, 61, 0.05) 0 1px, transparent 1px 14px);
    pointer-events: none;
    opacity: 0.5;
}

.curtain {
    text-align: center;
    padding: 38px 22px 22px;
    position: relative;
    z-index: 1;
    transition: max-height 0.5s ease, opacity 0.5s ease, padding 0.4s ease;
    max-height: 240px;
    overflow: hidden;
}

.curtain-title {
    margin: 0;
    font-family: var(--font-display);
    font-style: italic;
    font-weight: 700;
    font-size: clamp(1.6rem, 4vw, 2.6rem);
    letter-spacing: 0.04em;
    color: transparent;
    -webkit-text-stroke: 1px var(--color-gold);
    background: linear-gradient(180deg, var(--color-gold) 0%, #8C6A2E 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

.curtain-tagline {
    margin: 0.4em 0 0;
    color: rgba(245, 239, 230, 0.6);
    font-size: 0.95rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.is-scrolled .curtain {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
}

.header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 0;
    position: relative;
    z-index: 2;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--color-text);
    text-decoration: none;
    flex: 1 1 auto;
    min-width: 0;
}
.brand:hover, .brand:focus { color: var(--color-text); text-decoration: none; }

.brand-logo {
    width: 56px;
    height: 56px;
    object-fit: contain;
    flex-shrink: 0;
    display: block;
}

.brand-logo-svg {
    width: 56px;
    height: 56px;
    flex-shrink: 0;
    display: block;
}

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

.brand-title {
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.15rem;
    line-height: 1.15;
    font-weight: 700;
    color: var(--color-gold);
    overflow: hidden;
    text-overflow: ellipsis;
}

.brand-desc {
    margin: 3px 0 0;
    font-size: 0.8rem;
    color: rgba(245, 239, 230, 0.6);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* ==========================================================================
   Главная навигация
   ========================================================================== */

.main-nav {
    flex-shrink: 0;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 4px;
    margin: 0;
    padding: 0;
}

.main-nav li { margin: 0; }

.main-nav a {
    display: inline-block;
    padding: 8px 14px;
    color: var(--color-text);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    border-bottom: 2px solid transparent;
    text-decoration: none;
}

.main-nav a:hover,
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a {
    color: var(--color-gold);
    border-bottom-color: var(--color-gold);
    text-decoration: none;
}

/* Мобильное меню */
.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--color-gold-dim);
    color: var(--color-gold);
    padding: 8px 12px;
    font-size: 0.85rem;
    cursor: pointer;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.nav-toggle:hover { background: rgba(197, 160, 89, 0.1); }

.nav-toggle .needle-indicator {
    display: inline-block;
    width: 10px; height: 10px;
    border-radius: 50%;
    background: var(--color-gold);
    margin-right: 8px;
    vertical-align: middle;
    box-shadow: 0 0 6px rgba(197, 160, 89, 0.5);
}

@media (max-width: 760px) {
    .nav-toggle { display: inline-flex; align-items: center; }
    .main-nav ul {
        display: none;
        flex-direction: column;
        gap: 0;
        position: absolute;
        top: 100%;
        right: 22px;
        left: 22px;
        background: #181818;
        border: 1px solid var(--color-gold-dim);
        padding: 8px;
        z-index: 50;
    }
    .main-nav.is-open ul { display: flex; }
    .main-nav a {
        display: block;
        padding: 12px 14px;
        border-bottom: 1px solid rgba(156, 122, 61, 0.2);
    }
    .main-nav li:last-child a { border-bottom: 0; }
}

/* ==========================================================================
   Структура страницы
   ========================================================================== */

.site-main {
    padding: 36px 0 60px;
}

.layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 36px;
}

.layout--with-sidebar {
    grid-template-columns: minmax(0, 67fr) minmax(0, 27fr);
    gap: 6%;
}

.layout--narrow {
    max-width: 85%;
    margin: 0 auto;
}

@media (max-width: 960px) {
    .layout--with-sidebar { grid-template-columns: 1fr; }
    .layout--narrow { max-width: 100%; }
}

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

.breadcrumbs {
    margin: 0 0 22px;
    font-size: 0.85rem;
    color: rgba(245, 239, 230, 0.55);
    letter-spacing: 0.02em;
}

.breadcrumbs a {
    color: rgba(245, 239, 230, 0.7);
    text-decoration: none;
    border-bottom: 1px dotted rgba(156, 122, 61, 0.5);
}

.breadcrumbs a:hover { color: var(--color-gold); border-bottom-color: var(--color-gold); }

.breadcrumbs .sep {
    margin: 0 0.5em;
    color: var(--color-gold-dim);
}

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

.cards-list {
    display: grid;
    gap: 28px;
}

.card {
    display: flex;
    flex-direction: column;
    background: #1A1A1A;
    border: 1px solid rgba(156, 122, 61, 0.25);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    transform: rotate(-0.18deg);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    position: relative;
}

.card:nth-child(even) { transform: rotate(0.22deg); }

.card:hover {
    transform: rotate(0deg) translateY(-2px);
    box-shadow: 8px 10px 0 rgba(0, 0, 0, 0.55);
}

.card-thumb-wrap {
    position: relative;
    overflow: hidden;
}

.card-thumb-wrap a {
    display: block;
}

.card-thumb-wrap img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.card:hover .card-thumb-wrap img { transform: scale(1.04); }

.card-body {
    flex: 1;
    padding: 20px 22px 22px;
    display: flex;
    flex-direction: column;
}

.card-tag {
    display: inline-block;
    align-self: flex-start;
    background: var(--color-terracotta);
    color: #FFF8EE;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 4px 10px;
    margin-bottom: 12px;
}

.card-tag--gold { background: var(--color-gold); color: var(--color-anthracite); }
.card-tag--anthracite { background: var(--color-anthracite); color: var(--color-gold); border: 1px solid var(--color-gold-dim); }

.card-title {
    margin: 0 0 10px;
    font-size: 1.3rem;
    line-height: 1.25;
}

.card-title a {
    color: var(--color-text);
    text-decoration: none;
    border-bottom: 1px solid transparent;
}

.card-title a:hover {
    color: var(--color-gold);
    border-bottom-color: var(--color-gold);
    text-decoration: none;
}

.card-meta {
    font-size: 0.82rem;
    color: rgba(245, 239, 230, 0.55);
    margin-bottom: 12px;
    letter-spacing: 0.02em;
}

.card-meta a { color: rgba(245, 239, 230, 0.7); }

.card-excerpt {
    color: rgba(245, 239, 230, 0.85);
    font-size: 0.96rem;
    line-height: 1.6;
    flex: 1;
}

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

.card-more {
    margin-top: 14px;
    align-self: flex-start;
}

/* Горизонтальная карточка (используется на главной для последних записей) */
.card--row { flex-direction: row; }

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

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

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

@media (max-width: 600px) {
    .card--row { flex-direction: column; }
    .card--row .card-thumb-wrap {
        flex: none;
        width: 100%;
        position: static;
    }
    .card--row .card-thumb-wrap a {
        position: static;
    }
    .card--row .card-thumb-wrap img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }
}

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

.btn {
    display: inline-block;
    padding: 14px 28px;
    background: transparent;
    color: var(--color-gold);
    border: 0;
    border-top: 1px solid var(--color-gold);
    border-bottom: 1px solid var(--color-gold);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.92rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
    border-radius: 0;
}

.btn:hover, .btn:focus {
    background: var(--color-gold);
    color: var(--color-anthracite);
    text-decoration: none;
}

.btn--small {
    padding: 8px 16px;
    font-size: 0.78rem;
    letter-spacing: 0.12em;
}

.btn--ghost {
    background: transparent;
    color: var(--color-text);
    border-top-color: var(--color-gold-dim);
    border-bottom-color: var(--color-gold-dim);
}

.btn--ghost:hover { background: var(--color-gold-dim); color: var(--color-anthracite); }

/* Кнопка-машинка для комментариев */
.btn-typewriter {
    display: inline-block;
    background: transparent;
    border: 0;
    color: var(--color-gold);
    padding: 8px 0 12px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    position: relative;
    text-decoration: none;
}

.btn-typewriter::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 6px;
    background-image:
        linear-gradient(90deg, var(--color-gold) 50%, transparent 0),
        linear-gradient(90deg, var(--color-gold) 50%, transparent 0);
    background-size: 8px 1px;
    background-position: 0 0, 0 4px;
    background-repeat: repeat-x;
}

.btn-typewriter:hover { color: var(--color-text); }

/* ==========================================================================
   Главная страница — тематические блоки
   ========================================================================== */

.section {
    margin: 0 0 56px;
}

.section-title {
    font-size: 1.85rem;
    margin: 0 0 8px;
    color: var(--color-gold);
}

.section-lead {
    color: rgba(245, 239, 230, 0.75);
    font-size: 1.05rem;
    margin: 0 0 26px;
    max-width: 720px;
}

/* Рубрикатор: Кейсы / Ошибки / Лайфхаки */
.rubricator {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    border: 1px solid var(--color-gold-dim);
}

.rubricator-col {
    padding: 32px 24px;
    background: var(--color-anthracite);
    border-right: 1px solid var(--color-gold-dim);
    transition: flex-grow 0.4s ease, background 0.4s ease;
    position: relative;
    overflow: hidden;
}

.rubricator-col:last-child { border-right: 0; }
.rubricator-col:hover { background: #243036; }

.rubricator-icon {
    width: 64px; height: 64px;
    margin: 0 0 18px;
    display: block;
    color: var(--color-gold);
}

.rubricator-col h3 {
    margin: 0 0 10px;
    font-size: 1.4rem;
    color: var(--color-gold);
}

.rubricator-col p {
    margin: 0 0 14px;
    color: rgba(245, 239, 230, 0.8);
}

.rubricator-col-link {
    color: var(--color-terracotta);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-decoration: none;
    border-bottom: 1px solid var(--color-terracotta);
}

@media (max-width: 760px) {
    .rubricator { grid-template-columns: 1fr; }
    .rubricator-col {
        border-right: 0;
        border-bottom: 1px solid var(--color-gold-dim);
    }
    .rubricator-col:last-child { border-bottom: 0; }
}

/* Таймлайн «С черновика до сцены» */
.timeline {
    background: var(--color-anthracite);
    border: 1px solid var(--color-gold-dim);
    padding: 32px 24px;
}

.timeline-track {
    position: relative;
    margin: 26px 0 14px;
    padding: 22px 0;
}

.timeline-line {
    position: absolute;
    top: 50%; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--color-gold-dim), var(--color-gold), var(--color-gold-dim));
    transform: translateY(-50%);
}

.timeline-points {
    position: relative;
    display: flex;
    justify-content: space-between;
    list-style: none;
    margin: 0;
    padding: 0;
    z-index: 1;
}

.timeline-point {
    position: relative;
    margin: 0;
    flex: 1;
    text-align: center;
}

.timeline-point button {
    width: 22px; height: 22px;
    border-radius: 50%;
    border: 2px solid var(--color-gold);
    background: var(--color-bg);
    cursor: pointer;
    padding: 0;
    transition: background 0.2s ease, transform 0.2s ease;
    display: block;
    margin: 0 auto;
}

.timeline-point button:hover,
.timeline-point button[aria-expanded="true"] {
    background: var(--color-gold);
    transform: scale(1.18);
}

.timeline-point .point-label {
    display: block;
    margin-top: 12px;
    font-size: 0.85rem;
    color: rgba(245, 239, 230, 0.7);
    letter-spacing: 0.04em;
}

.timeline-detail {
    margin-top: 24px;
    background: var(--color-anthracite-dark);
    border-left: 3px solid var(--color-gold);
    padding: 18px 20px;
    color: rgba(245, 239, 230, 0.9);
}

.timeline-detail[hidden] { display: none !important; }

.timeline-detail h4 {
    margin: 0 0 8px;
    color: var(--color-gold);
    font-size: 1.05rem;
}

.timeline-detail p:last-child { margin-bottom: 0; }

@media (max-width: 760px) {
    .timeline-points { flex-direction: column; gap: 18px; }
    .timeline-line { display: none; }
    .timeline-point { text-align: left; display: flex; align-items: center; gap: 14px; }
    .timeline-point button { margin: 0; }
    .timeline-point .point-label { margin-top: 0; }
}

/* CTA-блок */
.cta-block {
    background: var(--color-anthracite);
    border: 1px solid var(--color-gold-dim);
    padding: 32px 28px;
    text-align: center;
}

.cta-block h2 { margin-top: 0; }

.cta-block p { color: rgba(245, 239, 230, 0.85); }

/* ==========================================================================
   Single / Page контент
   ========================================================================== */

.entry-header {
    margin-bottom: 28px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(156, 122, 61, 0.3);
}

.entry-title {
    margin: 0 0 12px;
    font-size: clamp(1.7rem, 3vw, 2.4rem);
}

.entry-meta {
    color: rgba(245, 239, 230, 0.6);
    font-size: 0.88rem;
    letter-spacing: 0.02em;
}

.entry-meta a { color: rgba(245, 239, 230, 0.8); }

.entry-thumb {
    margin: 0 0 28px;
    border: 1px solid rgba(156, 122, 61, 0.3);
}

.entry-thumb img { display: block; width: 100%; height: auto; }

.entry-content {
    font-size: 1.05rem;
    line-height: 1.75;
}

.entry-content img { display: block; margin: 1.4em auto; }

.entry-content figure { margin: 1.4em 0; }
.entry-content figcaption {
    text-align: center;
    color: rgba(245, 239, 230, 0.55);
    font-size: 0.85rem;
    margin-top: 0.4em;
    font-style: italic;
}

.entry-footer {
    margin-top: 32px;
    padding-top: 18px;
    border-top: 1px solid rgba(156, 122, 61, 0.3);
    color: rgba(245, 239, 230, 0.7);
    font-size: 0.92rem;
}

.entry-footer a { color: var(--color-gold); }

/* Прогресс-бар «Оркестровая яма» */
.read-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    z-index: 90;
    pointer-events: none;
}

.read-progress-bar {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--color-gold) 0%, var(--color-terracotta) 100%);
    box-shadow: 0 0 8px rgba(197, 160, 89, 0.5);
    transition: width 0.05s linear;
}

.read-progress::after {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: repeating-linear-gradient(
        90deg,
        transparent 0 60px,
        rgba(245, 239, 230, 0.15) 60px 61px
    );
    pointer-events: none;
}

/* Навигация по записям */
.post-nav {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin: 36px 0 0;
}

.post-nav a {
    flex: 1;
    padding: 14px 18px;
    border: 1px solid var(--color-gold-dim);
    color: var(--color-text);
    text-decoration: none;
    border-radius: 4px;
    background: transparent;
}

.post-nav a:hover {
    background: var(--color-gold);
    color: var(--color-anthracite);
    border-color: var(--color-gold);
}

.post-nav-label {
    display: block;
    font-size: 0.78rem;
    color: var(--color-gold);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.post-nav .next { text-align: right; }

@media (max-width: 600px) {
    .post-nav { flex-direction: column; }
    .post-nav .next { text-align: left; }
}

/* ==========================================================================
   Сайдбар
   ========================================================================== */

.sidebar {
    font-size: 0.96rem;
}

.widget {
    margin-bottom: 32px;
    padding-bottom: 22px;
    border-bottom: 1px dotted rgba(156, 122, 61, 0.4);
}

.widget:last-child { border-bottom: 0; }

.widget-title {
    margin: 0 0 14px;
    color: var(--color-gold);
    font-size: 1.05rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--color-gold-dim);
    padding-bottom: 8px;
}

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

.widget li {
    margin: 0 0 10px;
    padding-left: 14px;
    position: relative;
}

.widget li::before {
    content: "";
    position: absolute;
    top: 0.7em;
    left: 0;
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--color-gold);
}

.widget a {
    color: var(--color-text);
    border-bottom: 1px solid transparent;
}

.widget a:hover {
    color: var(--color-gold);
    border-bottom-color: var(--color-gold);
    text-decoration: none;
}

/* ==========================================================================
   Поиск
   ========================================================================== */

.search-form {
    display: flex;
    gap: 0;
    margin: 0 0 1em;
}

.search-form input[type="search"] {
    flex: 1;
    padding: 10px 14px;
    background: var(--color-anthracite);
    border: 1px solid var(--color-gold-dim);
    color: var(--color-text);
    font-family: inherit;
    font-size: 0.95rem;
}

.search-form input[type="search"]:focus {
    outline: 0;
    border-color: var(--color-gold);
}

.search-form button {
    padding: 10px 18px;
    background: var(--color-gold);
    color: var(--color-anthracite);
    border: 1px solid var(--color-gold);
    cursor: pointer;
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.85rem;
}

.search-form button:hover { background: var(--color-terracotta); border-color: var(--color-terracotta); color: #FFF8EE; }

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

.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin: 36px 0 0;
    flex-wrap: wrap;
}

.pagination a, .pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    border: 1px solid var(--color-gold-dim);
    color: var(--color-gold);
    text-decoration: none;
    font-family: var(--font-display);
    border-radius: 4px;
    background: transparent;
    transition: background 0.2s ease, color 0.2s ease;
}

.pagination a:hover,
.pagination .current {
    background: var(--color-gold);
    color: var(--color-anthracite);
    border-color: var(--color-gold);
    text-decoration: none;
}

.pagination .dots {
    border: 0;
    background: transparent;
    color: rgba(245, 239, 230, 0.5);
}

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

.comments-area {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(156, 122, 61, 0.3);
}

.comments-title, .comment-reply-title {
    margin: 0 0 22px;
    color: var(--color-gold);
}

.comment-list {
    list-style: none;
    padding: 0;
    margin: 0 0 32px;
}

.comment-list .children {
    list-style: none;
    padding-left: 24px;
    margin-top: 16px;
    border-left: 1px dotted rgba(156, 122, 61, 0.4);
}

.comment-body {
    background: var(--color-anthracite);
    border: 1px solid rgba(156, 122, 61, 0.25);
    padding: 18px 20px;
    margin: 0 0 16px;
}

.comment-author {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.comment-author img {
    width: 40px; height: 40px;
    border-radius: 50%;
    border: 1px solid var(--color-gold-dim);
}

.comment-author cite {
    font-style: normal;
    font-weight: 600;
    color: var(--color-gold);
}

.comment-meta {
    font-size: 0.8rem;
    color: rgba(245, 239, 230, 0.55);
    margin-left: auto;
}

.comment-content {
    font-size: 0.96rem;
    color: var(--color-text);
}

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

.comment-reply-link {
    display: inline-block;
    margin-top: 8px;
    color: var(--color-terracotta);
    font-size: 0.85rem;
    border-bottom: 1px dashed var(--color-terracotta);
    text-decoration: none;
}

.comment-form {
    background: var(--color-anthracite);
    padding: 22px 22px 18px;
    border: 1px solid rgba(156, 122, 61, 0.25);
}

.comment-form label {
    display: block;
    margin-bottom: 4px;
    font-size: 0.88rem;
    color: rgba(245, 239, 230, 0.8);
    letter-spacing: 0.02em;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 10px 12px;
    background: var(--color-anthracite-dark);
    border: 1px solid var(--color-gold-dim);
    color: var(--color-text);
    font-family: inherit;
    font-size: 0.95rem;
    margin-bottom: 14px;
}

.comment-form textarea { min-height: 130px; resize: vertical; }

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

.comment-form .form-submit { margin-top: 6px; }

.comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.comment-form-cookies-consent label { margin: 0; }

/* ==========================================================================
   404 — пустая сцена
   ========================================================================== */

.empty-stage {
    text-align: center;
    padding: 40px 20px 60px;
}

.empty-stage-art {
    margin: 0 auto 24px;
    width: 180px; height: 180px;
    color: var(--color-gold);
}

.empty-stage-title {
    font-size: 2.2rem;
    margin: 0 0 12px;
    color: var(--color-gold);
}

.empty-stage-lead {
    color: rgba(245, 239, 230, 0.8);
    font-size: 1.05rem;
    max-width: 520px;
    margin: 0 auto 28px;
}

.empty-stage-search {
    max-width: 420px;
    margin: 0 auto 28px;
}

.empty-stage-tips {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
    margin: 32px 0 0;
}

/* ==========================================================================
   Подвал — стол режиссёра
   ========================================================================== */

.site-footer {
    background: linear-gradient(180deg, #0E0E0E 0%, #131517 100%);
    border-top: 1px solid var(--color-gold-dim);
    padding: 48px 0 26px;
    margin-top: 60px;
    color: rgba(245, 239, 230, 0.85);
    position: relative;
}

.site-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 10% 20%, rgba(197, 160, 89, 0.04), transparent 25%),
        radial-gradient(circle at 80% 70%, rgba(192, 90, 59, 0.04), transparent 30%);
    pointer-events: none;
}

.footer-cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 36px;
    position: relative;
    z-index: 1;
}

@media (max-width: 760px) {
    .footer-cols { grid-template-columns: 1fr; gap: 26px; }
}

.footer-col {
    background: rgba(30, 36, 38, 0.55);
    border: 1px solid rgba(156, 122, 61, 0.25);
    padding: 22px 22px 18px;
    transform: rotate(-0.4deg);
    box-shadow: 4px 6px 0 rgba(0, 0, 0, 0.4);
}

.footer-col:nth-child(2) { transform: rotate(0.3deg); }
.footer-col:nth-child(3) { transform: rotate(-0.15deg); }

.footer-col .widget { border-bottom: 0; padding-bottom: 0; margin-bottom: 0; }

.footer-col .widget-title {
    color: var(--color-gold);
    border-bottom-color: var(--color-gold-dim);
}

.footer-credits {
    margin: 36px 0 0;
    padding: 16px 22px;
    border: 2px solid var(--color-gold-dim);
    text-align: center;
    font-family: var(--font-display);
    color: var(--color-gold);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-size: 0.85rem;
    background: rgba(197, 160, 89, 0.04);
    transform: rotate(-0.2deg);
    position: relative;
    z-index: 1;
}

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

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

.cookie-banner {
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 14px;
    z-index: 200;
    background: var(--color-anthracite);
    border: 1px solid var(--color-gold);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 18px;
    color: var(--color-text);
    font-size: 0.92rem;
    max-width: 760px;
    margin: 0 auto;
}

.cookie-banner p { margin: 0; flex: 1; }

.cookie-banner a { color: var(--color-gold); border-bottom: 1px dotted var(--color-gold); }

.cookie-banner .btn--small { flex-shrink: 0; }

@media (max-width: 600px) {
    .cookie-banner { flex-direction: column; align-items: stretch; text-align: left; }
}

/* ==========================================================================
   Мелкие утилиты
   ========================================================================== */

.alignleft { float: left; margin: 0.3em 1.4em 1em 0; }
.alignright { float: right; margin: 0.3em 0 1em 1.4em; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }

.wp-caption {
    max-width: 100%;
    margin-bottom: 1.2em;
}

.wp-caption-text {
    color: rgba(245, 239, 230, 0.55);
    font-size: 0.85rem;
    text-align: center;
    font-style: italic;
}

.sticky { /* зарезервировано WordPress */ }
.gallery-caption { /* зарезервировано WordPress */ }
.bypostauthor { /* зарезервировано WordPress */ }

/* Адаптивные правки */
@media (max-width: 600px) {
    body { font-size: 16px; }
    .site-main { padding: 24px 0 40px; }
    .section { margin-bottom: 40px; }
    .btn { width: 100%; text-align: center; }
}
