/* ============================================================
   Радар ВРВ — оформление
   Светлая тема, обновлённая: системные шрифты, мягкие тени,
   аккуратные скругления, современные отступы.
   ============================================================ */

:root {
    --bg:          #f6f7fa;
    --surface:     #ffffff;
    --surface-2:   #f1f3f8;
    --line:        #e4e8f0;
    --line-strong: #d3d9e6;

    --text:        #171c26;
    --text-2:      #5b6577;
    --muted:       #8b95a8;

    --accent:      #2f62e8;
    --accent-soft: #eaf0ff;
    --accent-dark: #2450c9;

    --good:        #12a86e;
    --warn:        #e08a15;
    --bad:         #dc4b52;

    --radius:      14px;
    --radius-sm:   10px;
    --radius-lg:   20px;

    --shadow-xs:   0 1px 2px rgba(19, 26, 43, .05);
    --shadow-sm:   0 1px 3px rgba(19, 26, 43, .06), 0 1px 2px rgba(19, 26, 43, .04);
    --shadow-md:   0 4px 16px rgba(19, 26, 43, .07), 0 1px 3px rgba(19, 26, 43, .04);
    --shadow-lg:   0 12px 32px rgba(19, 26, 43, .10);

    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
            "Inter", "Noto Sans", Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; }

h1, h2, h3, h4 { line-height: 1.25; letter-spacing: -.015em; font-weight: 650; }
h1 { font-size: clamp(1.55rem, 1.1rem + 1.8vw, 2.15rem); }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.05rem; }

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

.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--text-2); font-size: .93rem; }

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

.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 100;
    background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: #fff; }

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 4px;
}

/* ---------------------------------------------------------- Шапка */
.header {
    background: rgba(255,255,255,.86);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 50;
}

.header .container {
    display: flex; justify-content: space-between; align-items: center;
    gap: 16px; min-height: 62px;
}

.brand-link { display: flex; align-items: center; gap: 11px; color: var(--text); }
.brand-link:hover { color: var(--text); }

.brand-mark {
    width: 11px; height: 11px; border-radius: 50%;
    background: var(--bad); flex: none;
    box-shadow: 0 0 0 4px rgba(220, 75, 82, .16);
    animation: brandPulse 2.6s ease-in-out infinite;
}
@keyframes brandPulse {
    0%, 100% { box-shadow: 0 0 0 4px rgba(220, 75, 82, .16); }
    50%      { box-shadow: 0 0 0 8px rgba(220, 75, 82, .05); }
}

.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-name { font-weight: 700; font-size: 1.1rem; letter-spacing: -.02em; }
.brand-sub  { font-size: .72rem; color: var(--muted); letter-spacing: .01em; }

.nav { display: flex; gap: 4px; }
.nav a {
    color: var(--text-2); font-size: .93rem; font-weight: 500;
    padding: 7px 13px; border-radius: 8px;
    transition: background .15s, color .15s;
}
.nav a:hover { background: var(--surface-2); color: var(--text); }
.nav a.is-active { background: var(--accent-soft); color: var(--accent); }

/* ---------------------------------------------------------- Hero */
.hero {
    margin: 22px 0 30px;
    padding: 34px 34px 30px;
    border-radius: var(--radius-lg);
    background:
        radial-gradient(900px 320px at 12% -10%, rgba(47,98,232,.14), transparent 60%),
        radial-gradient(700px 300px at 92% 110%, rgba(220,75,82,.10), transparent 60%),
        linear-gradient(180deg, #ffffff, #f9fafd);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    display: flex; flex-wrap: wrap; gap: 26px;
    align-items: flex-end; justify-content: space-between;
}

.hero-body { max-width: 620px; }
.hero h1 { margin: 12px 0 8px; }
.hero p { color: var(--text-2); font-size: 1.02rem; }

.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--surface); border: 1px solid var(--line);
    color: var(--text-2); font-size: .8rem; font-weight: 500;
    padding: 5px 12px 5px 9px; border-radius: 100px;
    box-shadow: var(--shadow-xs);
}

.pulse {
    width: 7px; height: 7px; border-radius: 50%; background: var(--good);
    box-shadow: 0 0 0 3px rgba(18,168,110,.18);
    animation: brandPulse 2.4s ease-in-out infinite;
}

.hero-stats { display: flex; gap: 30px; flex-wrap: wrap; }
.hero-stat { display: flex; flex-direction: column; }
.hero-stat-num {
    font-size: 1.85rem; font-weight: 700; letter-spacing: -.03em;
    font-variant-numeric: tabular-nums; line-height: 1.1;
}
.hero-stat-label { font-size: .78rem; color: var(--muted); }

/* ---------------------------------------------------------- Заголовки блоков */
.page-head { margin: 20px 0 22px; }
.page-head-row {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 16px; flex-wrap: wrap;
}
.page-head h1 { margin-bottom: 4px; }

.section-head {
    display: flex; align-items: center; justify-content: space-between;
    gap: 14px; margin: 34px 0 14px; flex-wrap: wrap;
}
.section-head h2 { font-size: 1.22rem; }
.link-more { font-size: .9rem; font-weight: 500; }

/* ---------------------------------------------------------- Панель инструментов */
.toolbar {
    display: flex; gap: 12px; flex-wrap: wrap; align-items: center;
    margin-bottom: 18px;
}

.search-wrap { position: relative; flex: 1 1 280px; max-width: 420px; }
.search-icon {
    position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
    color: var(--muted); pointer-events: none;
}
.search-input {
    width: 100%; font-family: inherit; font-size: .94rem; color: var(--text);
    background: var(--surface); border: 1px solid var(--line);
    border-radius: 100px; padding: 10px 38px 10px 38px;
    box-shadow: var(--shadow-xs); transition: border-color .15s, box-shadow .15s;
}
.search-input::placeholder { color: var(--muted); }
.search-input:focus {
    outline: none; border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(47,98,232,.12);
}
.search-input::-webkit-search-cancel-button { display: none; }

.search-clear {
    position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
    width: 24px; height: 24px; border: none; background: var(--surface-2);
    color: var(--text-2); border-radius: 50%; cursor: pointer;
    font-size: 16px; line-height: 1; display: grid; place-items: center;
}
.search-clear:hover { background: var(--line); }

.filters { display: flex; gap: 7px; flex-wrap: wrap; }

.chip {
    --chip-color: var(--accent);
    font-family: inherit; font-size: .86rem; font-weight: 500;
    color: var(--text-2); background: var(--surface);
    border: 1px solid var(--line); border-radius: 100px;
    padding: 7px 14px; cursor: pointer;
    transition: all .15s; white-space: nowrap;
}
.chip:hover { border-color: var(--line-strong); color: var(--text); }
.chip.is-active {
    background: var(--chip-color); border-color: var(--chip-color);
    color: #fff; box-shadow: var(--shadow-xs);
}

.select {
    font-family: inherit; font-size: .9rem; color: var(--text);
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-sm); padding: 8px 12px; cursor: pointer;
}

/* ---------------------------------------------------------- Автообновление */
.live-controls { display: flex; align-items: center; gap: 10px; }

.live-dot {
    width: 8px; height: 8px; border-radius: 50%; background: var(--good);
    box-shadow: 0 0 0 3px rgba(18,168,110,.16);
    transition: background .2s, box-shadow .2s;
}
.live-dot.is-off { background: var(--muted); box-shadow: 0 0 0 3px rgba(139,149,168,.14); }
.live-dot.is-loading { animation: brandPulse 1s ease-in-out infinite; }

.switch { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; user-select: none; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch-track {
    width: 38px; height: 21px; border-radius: 100px; background: var(--line-strong);
    position: relative; transition: background .18s; flex: none;
}
.switch-track::after {
    content: ""; position: absolute; top: 2.5px; left: 2.5px;
    width: 16px; height: 16px; border-radius: 50%; background: #fff;
    box-shadow: var(--shadow-xs); transition: transform .18s;
}
.switch input:checked + .switch-track { background: var(--good); }
.switch input:checked + .switch-track::after { transform: translateX(17px); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch-label { font-size: .87rem; color: var(--text-2); }

.new-banner { margin-bottom: 16px; }
.new-banner button {
    width: 100%; font-family: inherit; font-size: .93rem; font-weight: 600;
    color: var(--accent); background: var(--accent-soft);
    border: 1px solid rgba(47,98,232,.22); border-radius: var(--radius-sm);
    padding: 11px; cursor: pointer; transition: background .15s;
}
.new-banner button:hover { background: #dfe8ff; }
.new-count {
    display: inline-block; background: var(--accent); color: #fff;
    border-radius: 100px; padding: 1px 9px; margin-right: 6px;
    font-variant-numeric: tabular-nums;
}

/* ---------------------------------------------------------- Сетки */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 14px;
}

.regions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 11px;
}

.cities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(255px, 1fr));
    gap: 14px;
}

/* ---------------------------------------------------------- Карточки событий */
.post-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 17px 15px;
    box-shadow: var(--shadow-xs);
    display: flex; flex-direction: column; gap: 9px;
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.post-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--line-strong);
}
.post-card.is-new { animation: cardIn .45s ease both; }
@keyframes cardIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: none; }
}

.post-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }

.post-category {
    --cat-color: var(--accent);
    display: inline-flex; align-items: center; gap: 6px;
    font-size: .74rem; font-weight: 650; letter-spacing: .02em;
    color: var(--cat-color); background: color-mix(in srgb, var(--cat-color) 11%, #fff);
    border: 1px solid color-mix(in srgb, var(--cat-color) 26%, #fff);
    padding: 3px 11px; border-radius: 100px;
    text-transform: uppercase; white-space: nowrap;
}
/* Запасной вариант для браузеров без color-mix */
@supports not (color: color-mix(in srgb, red 50%, blue)) {
    .post-category { color: #fff; background: var(--cat-color); border-color: var(--cat-color); }
}

.post-title { font-size: 1.02rem; font-weight: 620; }
.post-title a { color: var(--text); }
.post-title a:hover { color: var(--accent); }

.post-meta {
    display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
    font-size: .84rem; color: var(--text-2); margin-top: auto; padding-top: 3px;
}
.post-meta .city, .post-meta .location { font-weight: 550; color: var(--text-2); }
.post-meta .city:hover, .post-meta .location:hover { color: var(--accent); }
.post-meta .date { color: var(--muted); font-variant-numeric: tabular-nums; }
.post-meta .source { color: var(--muted); font-size: .8rem; }

.status {
    font-size: .73rem; font-weight: 600; padding: 2px 9px;
    border-radius: 100px; white-space: nowrap;
}
.status-confirmed   { background: rgba(18,168,110,.11);  color: #0d7d53; }
.status-unconfirmed { background: rgba(224,138,21,.13);  color: #a86209; }
.status-refuted     { background: rgba(220,75,82,.11);   color: #b8323a; }

/* Кнопка «в избранное» */
.fav-btn {
    border: none; background: transparent; color: var(--muted);
    cursor: pointer; padding: 3px; border-radius: 7px; line-height: 0;
    transition: color .15s, background .15s, transform .15s;
    flex: none;
}
.fav-btn:hover { color: var(--warn); background: var(--surface-2); }
.fav-btn.is-fav { color: var(--warn); }
.fav-btn.is-fav svg { fill: currentColor; }
.fav-btn.just-added { transform: scale(1.22); }

.fav-btn-wide {
    display: inline-flex; align-items: center; gap: 7px;
}
.fav-btn-wide.is-fav { color: var(--warn); border-color: rgba(224,138,21,.35); background: rgba(224,138,21,.07); }
.fav-btn-wide.is-fav svg { fill: currentColor; }

/* ---------------------------------------------------------- Регионы и города */
.region-card {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-sm); padding: 14px 16px;
    box-shadow: var(--shadow-xs); color: var(--text);
    font-weight: 550; font-size: .96rem;
    transition: transform .15s, box-shadow .15s, border-color .15s, color .15s;
}
.region-card:hover {
    transform: translateY(-1px); box-shadow: var(--shadow-sm);
    border-color: var(--accent); color: var(--accent);
}
.region-arrow { color: var(--muted); transition: transform .15s; }
.region-card:hover .region-arrow { color: var(--accent); transform: translateX(3px); }

.city-card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 16px 17px;
    box-shadow: var(--shadow-xs);
    display: flex; flex-direction: column; gap: 10px;
    transition: transform .16s, box-shadow .16s, border-color .16s;
}
.city-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.city-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.city-card h3 a { color: var(--text); }
.city-card h3 a:hover { color: var(--accent); }

.city-stats { display: flex; gap: 7px; flex-wrap: wrap; }
.pill {
    font-size: .79rem; color: var(--text-2);
    background: var(--surface-2); border-radius: 100px; padding: 3px 10px;
}
.pill b { font-variant-numeric: tabular-nums; color: var(--text); font-weight: 620; }
.pill-hot { background: rgba(220,75,82,.09); color: #b8323a; }
.pill-hot b { color: #b8323a; }

.city-last { font-size: .79rem; color: var(--muted); }

/* Результаты живого поиска по городам */
.city-results {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); box-shadow: var(--shadow-sm);
    padding: 6px; margin-bottom: 18px; max-height: 340px; overflow-y: auto;
}
.city-result {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 9px 12px; border-radius: var(--radius-sm); color: var(--text);
}
.city-result:hover { background: var(--surface-2); color: var(--text); }
.city-result-name { font-weight: 550; }
.city-result-region { font-size: .8rem; color: var(--muted); }
.city-result-count { font-size: .79rem; color: var(--muted); white-space: nowrap; }

/* ---------------------------------------------------------- Избранное */
.favorites { margin-top: 26px; }
.favorites-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 11px;
}
.fav-card {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    background: linear-gradient(180deg, #fffdf7, var(--surface));
    border: 1px solid rgba(224,138,21,.28);
    border-radius: var(--radius-sm); padding: 12px 14px;
    color: var(--text); box-shadow: var(--shadow-xs);
    transition: transform .15s, box-shadow .15s;
}
.fav-card:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); color: var(--text); }
.fav-card-name { font-weight: 600; font-size: .95rem; }
.fav-card-region { font-size: .77rem; color: var(--muted); }
.fav-remove {
    border: none; background: transparent; color: var(--muted); cursor: pointer;
    font-size: 17px; line-height: 1; padding: 2px 5px; border-radius: 6px; flex: none;
}
.fav-remove:hover { background: rgba(220,75,82,.1); color: var(--bad); }

/* ---------------------------------------------------------- Хлебные крошки */
.breadcrumbs {
    display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
    margin: 18px 0 6px; font-size: .85rem; color: var(--text-2);
}
.breadcrumbs a { color: var(--text-2); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs .sep { color: var(--line-strong); }
.breadcrumbs span:not(.sep) { color: var(--muted); }

/* ---------------------------------------------------------- Статистика города */
.stats-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px; margin: 20px 0;
}
.stat-card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 17px 18px;
    box-shadow: var(--shadow-xs);
    display: flex; flex-direction: column; gap: 2px;
}
.stat-number {
    font-size: 1.75rem; font-weight: 700; letter-spacing: -.03em;
    font-variant-numeric: tabular-nums; line-height: 1.15;
}
.stat-label { font-size: .8rem; color: var(--muted); }

.city-map {
    height: 320px; margin: 22px 0; border-radius: var(--radius);
    overflow: hidden; border: 1px solid var(--line); background: var(--surface-2);
}

/* ---------------------------------------------------------- Список событий */
.posts-list { display: flex; flex-direction: column; gap: 10px; }

.post-item {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 15px 17px;
    box-shadow: var(--shadow-xs);
    display: flex; flex-direction: column; gap: 7px;
    transition: border-color .15s, box-shadow .15s;
}
.post-item:hover { border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.post-item .post-category { align-self: flex-start; }
.post-item h3 { font-size: 1rem; font-weight: 600; }
.post-item h3 a { color: var(--text); }
.post-item h3 a:hover { color: var(--accent); }
.post-item .post-meta { margin-top: 0; }

/* ---------------------------------------------------------- Страница события */
.post-detail {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 30px 32px;
    box-shadow: var(--shadow-sm); margin: 18px 0 12px;
}
.post-header { border-bottom: 1px solid var(--line); padding-bottom: 20px; margin-bottom: 22px; }
.post-header .post-category { margin-bottom: 12px; }
.post-header h1 { margin-bottom: 12px; }
.post-actions { display: flex; gap: 9px; margin-top: 16px; flex-wrap: wrap; }

.post-content { font-size: 1.02rem; }

.alert-box {
    background: linear-gradient(180deg, #fffaf0, #fffdf8);
    border: 1px solid rgba(224,138,21,.28);
    border-left: 3px solid var(--warn);
    border-radius: var(--radius-sm);
    padding: 18px 20px; margin-bottom: 22px;
}
.alert-box h2 {
    font-size: .78rem; text-transform: uppercase; letter-spacing: .07em;
    color: #a86209; margin-bottom: 8px; font-weight: 650;
}
.alert-box p { color: var(--text); line-height: 1.65; }

.monitoring-links {
    background: var(--surface-2); border-radius: var(--radius-sm);
    padding: 18px 20px; margin-bottom: 22px;
}
.monitoring-links h2 { font-size: 1.02rem; margin-bottom: 8px; }
.monitoring-links p { color: var(--text-2); font-size: .94rem; margin-bottom: 10px; }
.monitoring-links ul { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.monitoring-links li a { font-size: .94rem; font-weight: 500; }
.monitoring-links li a::before { content: "→ "; color: var(--muted); }

.post-details {
    background: var(--surface-2); padding: 17px 20px;
    border-radius: var(--radius-sm);
    display: flex; flex-direction: column; gap: 9px;
}
.detail-item { font-size: .92rem; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.detail-item strong { color: var(--text-2); font-weight: 550; }

.similar-posts { margin-top: 12px; }

/* ---------------------------------------------------------- Ссылки города */
.links-container { margin: 22px 0; }
.links-container h2 { font-size: 1.05rem; margin-bottom: 12px; }

.links-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 11px;
}

.link-card {
    display: flex; align-items: center; gap: 12px;
    padding: 13px 15px; background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--radius-sm);
    color: var(--text); box-shadow: var(--shadow-xs);
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.link-card:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); border-color: var(--line-strong); color: var(--text); }
.link-icon { color: var(--accent); line-height: 0; flex: none; }
.telegram-link .link-icon { color: #229ED9; }
.link-content { display: flex; flex-direction: column; min-width: 0; }
.link-title { font-weight: 600; font-size: .9rem; }
.link-url { font-size: .78rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; }

.source-links { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.source-link {
    display: inline-flex; align-items: center; gap: 5px;
    color: var(--text-2); font-size: .88rem;
    padding: 3px 8px; border-radius: 7px; transition: background .15s, color .15s;
}
.source-link:hover { background: var(--surface-2); color: var(--accent); }
.telegram-source:hover { color: #229ED9; }
.link-separator { color: var(--line-strong); }

/* ---------------------------------------------------------- Кнопки */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    font-family: inherit; font-size: .92rem; font-weight: 550;
    color: var(--text); background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--radius-sm);
    padding: 9px 16px; cursor: pointer; box-shadow: var(--shadow-xs);
    transition: all .15s;
}
.btn:hover { border-color: var(--line-strong); box-shadow: var(--shadow-sm); color: var(--text); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: none; color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-2); box-shadow: none; }
.btn-sm { font-size: .86rem; padding: 7px 13px; }
.btn.is-disabled { opacity: .45; pointer-events: none; }

/* ---------------------------------------------------------- Пагинация */
.pagination {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    margin: 26px 0 6px;
}
.page-info { font-size: .9rem; color: var(--muted); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------- Пустые состояния */
.empty-state {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 48px 24px;
    text-align: center; box-shadow: var(--shadow-xs); margin: 20px 0;
}
.empty-icon {
    font-size: 2.4rem; font-weight: 700; color: var(--line-strong);
    letter-spacing: -.04em; margin-bottom: 10px;
}
.empty-state h1 { margin-bottom: 8px; }
.empty-state p { color: var(--text-2); }
.empty-actions { display: flex; gap: 10px; justify-content: center; margin-top: 20px; flex-wrap: wrap; }

.no-results {
    text-align: center; color: var(--muted); padding: 34px 0; font-size: .95rem;
}

/* ---------------------------------------------------------- Наверх и уведомление */
.to-top {
    position: fixed; right: 20px; bottom: 20px; z-index: 40;
    width: 42px; height: 42px; border-radius: 50%;
    background: var(--surface); border: 1px solid var(--line);
    color: var(--text-2); font-size: 17px; cursor: pointer;
    box-shadow: var(--shadow-md);
    display: grid; place-items: center;
    transition: transform .15s, color .15s;
}
.to-top:hover { transform: translateY(-2px); color: var(--accent); }

.toast {
    position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(12px);
    background: var(--text); color: #fff; font-size: .9rem;
    padding: 11px 20px; border-radius: 100px; box-shadow: var(--shadow-lg);
    z-index: 60; opacity: 0; transition: opacity .2s, transform .2s;
    pointer-events: none; max-width: calc(100vw - 40px);
}
.toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------------------------------------------------------- Подвал */
.footer {
    background: var(--surface); border-top: 1px solid var(--line);
    margin-top: 56px; padding: 34px 0 22px;
}
.footer-inner {
    display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 28px;
    padding-bottom: 24px; border-bottom: 1px solid var(--line);
}
.footer-col { display: flex; flex-direction: column; gap: 7px; }
.footer-col strong { font-size: 1rem; }
.footer-col a { color: var(--text-2); font-size: .9rem; }
.footer-col a:hover { color: var(--accent); }
.footer-col .muted { font-size: .85rem; max-width: 400px; }
.footer-bottom { padding-top: 18px; }
.footer-bottom p { font-size: .82rem; color: var(--muted); text-align: center; }

/* ---------------------------------------------------------- Адаптив */
@media (max-width: 900px) {
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .footer-col:first-child { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
    body { font-size: 15.5px; }
    .container { padding: 0 16px; }

    .header .container { min-height: 56px; gap: 10px; }
    .brand-sub { display: none; }
    .nav a { padding: 6px 10px; font-size: .88rem; }

    .hero { padding: 24px 20px 22px; margin: 16px 0 24px; gap: 20px; }
    .hero-stats { gap: 22px; width: 100%; }
    .hero-stat-num { font-size: 1.5rem; }

    .posts-grid, .regions-grid, .cities-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }

    .post-detail { padding: 22px 18px; border-radius: var(--radius); }
    .section-head { margin: 26px 0 12px; }

    .toolbar { gap: 10px; }
    .search-wrap { max-width: 100%; }
    .filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
    .filters::-webkit-scrollbar { display: none; }

    .to-top { right: 14px; bottom: 14px; }
}

@media (max-width: 420px) {
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .footer-inner { grid-template-columns: 1fr; }
}

@media print {
    .header, .footer, .to-top, .toolbar, .live-controls, .post-actions, .new-banner { display: none !important; }
    body { background: #fff; }
    .post-detail { box-shadow: none; border: none; padding: 0; }
}
