:root {
    color-scheme: light;
    --bg: #f4f6fb;
    --bg-soft: #eef2f9;
    --surface: #ffffff;
    --surface-2: #f7f9fd;
    --surface-3: #eef3fa;
    --header-bg: rgba(255, 255, 255, 0.86);
    --border: #e3e9f2;
    --border-strong: #cbd5e1;
    --text: #0f1b2d;
    --text-soft: #334155;
    --muted: #64748b;
    --muted-2: #94a3b8;
    --accent: #1d5fd1;
    --accent-strong: #1648a4;
    --accent-soft: #eaf1fe;
    --accent-line: #c9dbfa;
    --green: #0d9488;
    --green-soft: #e6f7f3;
    --red: #dc2626;
    --red-soft: #fef2f2;
    --orange: #d97706;
    --orange-soft: #fff7ed;
    --blue: #0284c7;
    --blue-soft: #eff8ff;
    --violet: #7c3aed;
    --violet-soft: #f5f3ff;
    --shadow-sm: 0 1px 2px rgba(15, 27, 45, 0.04);
    --shadow: 0 1px 2px rgba(15, 27, 45, 0.05), 0 16px 34px -24px rgba(15, 27, 45, 0.25);
    --radius: 16px;
    --radius-sm: 10px;
    --radius-xs: 7px;
    --container: 1200px;
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

[data-theme="dark"] {
    color-scheme: dark;
    --bg: #0a111d;
    --bg-soft: #0d1625;
    --surface: #111b2b;
    --surface-2: #0e1726;
    --surface-3: #172337;
    --header-bg: rgba(10, 17, 29, 0.86);
    --border: #1e2b40;
    --border-strong: #31415a;
    --text: #e5edf8;
    --text-soft: #c7d3e3;
    --muted: #94a5bc;
    --muted-2: #6b7d95;
    --accent: #6ea8ff;
    --accent-strong: #9cc2ff;
    --accent-soft: rgba(110, 168, 255, 0.12);
    --accent-line: #28446e;
    --green: #2dd4bf;
    --green-soft: rgba(45, 212, 191, 0.11);
    --red: #f87171;
    --red-soft: rgba(248, 113, 113, 0.11);
    --orange: #fbbf24;
    --orange-soft: rgba(251, 191, 36, 0.11);
    --blue: #38bdf8;
    --blue-soft: rgba(56, 189, 248, 0.1);
    --violet: #a78bfa;
    --violet-soft: rgba(167, 139, 250, 0.11);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.2);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.25), 0 20px 40px -28px rgba(0, 0, 0, 0.8);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

[hidden] {
    display: none !important;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
}

img {
    max-width: 100%;
    display: block;
}

h1,
h2,
h3,
p,
ul,
ol,
figure {
    margin: 0;
}

ul,
ol {
    padding: 0;
    list-style: none;
}

code,
pre {
    font-family: var(--mono);
}

::selection {
    background: var(--accent);
    color: #fff;
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 4px;
}

.container {
    width: min(var(--container), calc(100% - 48px));
    margin-inline: auto;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    top: 10px;
    left: 10px;
    z-index: 1000;
    padding: 10px 16px;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    transform: translateY(-160%);
    transition: transform 0.15s ease;
}

.skip-link:focus {
    transform: translateY(0);
}

/* Header */
.site-header,
.admin-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--header-bg);
    border-bottom: 1px solid var(--border);
    backdrop-filter: saturate(150%) blur(14px);
    -webkit-backdrop-filter: saturate(150%) blur(14px);
}

.header-inner {
    min-height: 70px;
    display: flex;
    align-items: center;
    gap: 26px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    flex: 0 0 auto;
}

.brand-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    color: var(--accent);
    background: var(--accent-soft);
    border: 1px solid var(--accent-line);
}

.brand-mark svg {
    width: 25px;
    height: 25px;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 18px;
    letter-spacing: -0.02em;
    font-weight: 760;
}

.brand-text small {
    font-size: 10px;
    color: var(--muted);
    letter-spacing: 0.18em;
    font-weight: 600;
    margin-top: 3px;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1 1 auto;
}

.main-nav a {
    position: relative;
    padding: 8px 13px;
    border-radius: 8px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 560;
    transition: color 0.15s ease, background 0.15s ease;
}

.main-nav a:hover {
    color: var(--text);
    background: var(--surface-2);
}

.main-nav a.active {
    color: var(--accent);
    background: var(--accent-soft);
    font-weight: 650;
}

.header-search {
    position: relative;
    display: flex;
    align-items: center;
    width: 258px;
    flex: 0 0 auto;
}

.header-search svg {
    position: absolute;
    left: 12px;
    width: 17px;
    height: 17px;
    color: var(--muted-2);
    pointer-events: none;
}

.header-search input {
    width: 100%;
    height: 38px;
    padding: 0 12px 0 37px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface-2);
    font-size: 13px;
    transition: border 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.header-search input::placeholder {
    color: var(--muted-2);
}

.header-search input:focus {
    outline: none;
    background: var(--surface);
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.theme-toggle {
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
    color: var(--muted);
    transition: color 0.15s ease, border 0.15s ease, background 0.15s ease;
}

.theme-toggle:hover {
    color: var(--accent);
    border-color: var(--accent-line);
    background: var(--accent-soft);
}

.theme-toggle svg {
    width: 18px;
    height: 18px;
}

.icon-sun {
    display: none;
}

.icon-moon {
    display: block;
}

[data-theme="dark"] .icon-sun {
    display: block;
}

[data-theme="dark"] .icon-moon {
    display: none;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 40px;
    padding: 9px 18px;
    border: 1px solid transparent;
    border-radius: 9px;
    font-size: 14px;
    font-weight: 620;
    line-height: 1.2;
    cursor: pointer;
    transition: transform 0.12s ease, background 0.15s ease, border 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 6px 16px -10px var(--accent);
}

.btn-primary:hover {
    background: var(--accent-strong);
    border-color: var(--accent-strong);
}

[data-theme="dark"] .btn-primary {
    color: #071326;
}

.btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
}

.btn-ghost {
    background: var(--surface);
    border-color: var(--border);
    color: var(--text-soft);
}

.btn-ghost:hover {
    border-color: var(--border-strong);
    background: var(--surface-2);
}

.btn-small {
    min-height: 32px;
    padding: 6px 12px;
    font-size: 12.5px;
    border-radius: 7px;
    background: var(--surface-2);
    border: 1px solid var(--border);
}

.btn-block {
    width: 100%;
}

/* Hero */
.hero {
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background:
        radial-gradient(900px 360px at 88% -20%, rgba(29, 95, 209, 0.13), transparent 65%),
        radial-gradient(720px 300px at 8% 120%, rgba(13, 148, 136, 0.09), transparent 65%),
        var(--surface);
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.35;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: radial-gradient(ellipse at 70% 20%, #000 0%, transparent 68%);
    -webkit-mask-image: radial-gradient(ellipse at 70% 20%, #000 0%, transparent 68%);
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 56px;
    padding: 58px 0 54px;
}

.hero-copy {
    max-width: 610px;
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 4px var(--green-soft);
    animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 4px var(--green-soft); }
    50% { box-shadow: 0 0 0 7px transparent; }
}

.hero h1 {
    margin: 16px 0 16px;
    font-size: clamp(34px, 4.2vw, 50px);
    line-height: 1.13;
    letter-spacing: -0.045em;
    font-weight: 780;
}

.hero h1 span {
    color: var(--accent);
}

.hero-lead {
    max-width: 570px;
    color: var(--muted);
    font-size: 15.5px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 10px;
    margin-top: 28px;
    flex-wrap: wrap;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(140px, 1fr));
    gap: 12px;
    width: 390px;
    flex: 0 0 auto;
}

.stat-card {
    position: relative;
    padding: 18px 18px 17px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 13px;
    box-shadow: var(--shadow-sm);
    min-height: 104px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.stat-card::before {
    content: "";
    position: absolute;
    left: 18px;
    top: 0;
    width: 26px;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
}

.stat-blue::before { background: var(--blue); }
.stat-green::before { background: var(--green); }
.stat-slate::before { background: var(--muted-2); }

.stat-label {
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
}

.stat-value {
    font-size: 30px;
    line-height: 1;
    font-weight: 760;
    letter-spacing: -0.035em;
    font-variant-numeric: tabular-nums;
}

.stat-value small {
    margin-left: 3px;
    font-size: 11px;
    color: var(--muted-2);
    font-weight: 560;
    letter-spacing: 0;
}

.stat-accent .stat-value { color: var(--accent); }
.stat-blue .stat-value { color: var(--blue); }
.stat-green .stat-value { color: var(--green); }

/* Home layout */
.home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 38px;
    padding: 42px 0 68px;
    align-items: start;
}

.section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.section-kicker {
    color: var(--accent);
    font-size: 10px;
    font-weight: 750;
    letter-spacing: 0.19em;
    margin-bottom: 4px;
}

.section-head h2,
.panel-head h2 {
    font-size: 20px;
    line-height: 1.3;
    letter-spacing: -0.02em;
    font-weight: 720;
}

.text-link {
    color: var(--muted);
    font-size: 13px;
    font-weight: 560;
    white-space: nowrap;
    transition: color 0.15s ease;
}

.text-link:hover {
    color: var(--accent);
}

.article-list {
    display: grid;
    gap: 13px;
}

.article-card {
    display: flex;
    gap: 18px;
    padding: 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    transition: border 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.article-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
    transform: translateY(-1px);
}

.card-thumb {
    flex: 0 0 154px;
    width: 154px;
    height: 104px;
    border-radius: 10px;
    overflow: hidden;
    background: var(--surface-3);
    border: 1px solid var(--border);
}

.card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .card-thumb img {
    transform: scale(1.03);
}

.card-content {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

.card-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.badge {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 7px;
    border-radius: 5px;
    font-size: 11px;
    font-weight: 680;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.sev-critical { color: var(--red); background: var(--red-soft); }
.sev-high { color: var(--orange); background: var(--orange-soft); }
.sev-medium { color: #a16207; background: #fef9c3; }
.sev-low { color: var(--blue); background: var(--blue-soft); }
[data-theme="dark"] .sev-medium { color: var(--orange); background: var(--orange-soft); }

.cat-vuln { color: var(--red); background: var(--red-soft); }
.cat-incident { color: var(--violet); background: var(--violet-soft); }
.cat-intel { color: var(--orange); background: var(--orange-soft); }
.cat-research { color: var(--blue); background: var(--blue-soft); }
.cat-news { color: var(--muted); background: var(--surface-3); }

.trans-badge {
    color: var(--green);
    background: var(--green-soft);
    border: 1px solid rgba(13, 148, 136, 0.25);
    font-weight: 700;
}

.cvss {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 6px;
    border-radius: 5px;
    border: 1px solid var(--border);
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10.5px;
    font-weight: 600;
}

.card-title {
    margin: 8px 0 6px;
    font-size: 17.5px;
    line-height: 1.48;
    letter-spacing: -0.012em;
    font-weight: 680;
}

.card-title a {
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.15s ease;
}

.card-title a:hover {
    color: var(--accent);
}

.card-summary {
    overflow-wrap: anywhere;
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
    margin-top: auto;
    padding-top: 10px;
    color: var(--muted-2);
    font-size: 11.5px;
}

.meta-source {
    color: var(--muted);
    font-weight: 600;
}

.meta-dot {
    color: var(--muted-2);
}

.meta-cve {
    padding: 1px 6px;
    border-radius: 4px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10px;
}

.meta-hot {
    color: var(--accent);
    font-weight: 650;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 16px;
}

.panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.panel-head h2 {
    font-size: 16px;
}

.panel-head a {
    color: var(--muted);
    font-size: 12px;
    font-weight: 560;
}

.panel-head a:hover {
    color: var(--accent);
}

.panel-count {
    display: inline-grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 6px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 11px;
    font-weight: 650;
}

.panel-empty {
    color: var(--muted-2);
    font-size: 12.5px;
    padding: 8px 0;
}

.rank-list {
    display: grid;
}

.rank-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.rank-item:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.rank-item:first-child {
    padding-top: 2px;
}

.rank-num {
    flex: 0 0 22px;
    height: 22px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: var(--surface-2);
    color: var(--muted-2);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    margin-top: 1px;
}

.rank-1 { color: #fff; background: #dc2626; }
.rank-2 { color: #fff; background: #ea580c; }
.rank-3 { color: #fff; background: #d97706; }

.rank-main {
    min-width: 0;
    flex: 1;
}

.rank-main a {
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12.8px;
    line-height: 1.55;
    font-weight: 580;
}

.rank-main a:hover {
    color: var(--accent);
}

.rank-meta {
    display: block;
    margin-top: 3px;
    color: var(--muted-2);
    font-size: 10.5px;
}

.rank-score {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    margin-top: 2px;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 9px;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: var(--surface-2);
    color: var(--text-soft);
    font-size: 11.5px;
    line-height: 1.5;
    transition: color 0.15s ease, border 0.15s ease, background 0.15s ease;
}

.tag span {
    color: var(--muted-2);
    font-size: 10px;
}

.tag:hover,
.tag.active {
    color: var(--accent);
    border-color: var(--accent-line);
    background: var(--accent-soft);
}

.cve-list {
    display: grid;
    gap: 2px;
}

.cve-list li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.cve-list li:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.cve-list a {
    min-width: 0;
    flex: 1;
}

.cve-code {
    display: block;
    color: var(--accent);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 650;
    margin-bottom: 2px;
}

.cve-title {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.5;
}

.cve-title:hover {
    color: var(--accent);
}

.sev-dot {
    width: 7px;
    height: 7px;
    flex: 0 0 7px;
    margin-top: 5px;
    border-radius: 50%;
    background: var(--muted-2);
}

.sev-dot.sev-critical { background: var(--red); }
.sev-dot.sev-high { background: var(--orange); }
.sev-dot.sev-medium { background: #d97706; }
.sev-dot.sev-low { background: var(--blue); }

.source-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.source-pill {
    padding: 3px 8px;
    border-radius: 5px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--muted);
    font-size: 10.5px;
}

/* Page head */
.page-head {
    background:
        radial-gradient(700px 240px at 82% -60%, var(--accent-soft), transparent 70%),
        var(--surface);
    border-bottom: 1px solid var(--border);
}

.page-head-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;
    padding: 42px 0 36px;
}

.page-head h1 {
    margin: 8px 0 8px;
    font-size: clamp(28px, 3.2vw, 38px);
    line-height: 1.2;
    letter-spacing: -0.035em;
    font-weight: 760;
}

.page-lead {
    max-width: 720px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.75;
}

/* Archive */
.archive-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 286px;
    gap: 34px;
    padding: 30px 0 68px;
    align-items: start;
}

.category-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 14px;
}

.category-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 12px;
    border-radius: 8px;
    border: 1px solid transparent;
    color: var(--muted);
    font-size: 13px;
    font-weight: 580;
    transition: color 0.15s ease, background 0.15s ease, border 0.15s ease;
}

.category-tab span {
    min-width: 17px;
    padding: 0 4px;
    border-radius: 4px;
    background: var(--surface-2);
    color: var(--muted-2);
    font-family: var(--mono);
    font-size: 9.5px;
    text-align: center;
}

.category-tab:hover {
    color: var(--text);
    background: var(--surface);
    border-color: var(--border);
}

.category-tab.active {
    color: var(--accent);
    background: var(--accent-soft);
    border-color: var(--accent-line);
    font-weight: 650;
}

.category-tab.active span {
    color: var(--accent);
    background: var(--surface);
}

.filter-bar {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    padding: 13px;
    margin-bottom: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
}

.filter-bar > label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 10.5px;
    color: var(--muted);
    font-weight: 650;
}

.filter-search {
    position: relative;
    flex: 1 1 240px;
    min-width: 200px;
}

.filter-search svg {
    position: absolute;
    left: 10px;
    bottom: 10px;
    width: 16px;
    height: 16px;
    color: var(--muted-2);
}

.filter-bar input[type="search"],
.filter-bar select {
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: var(--surface-2);
    color: var(--text);
    font-size: 12.5px;
}

.filter-bar input[type="search"] {
    width: 100%;
    padding: 0 10px 0 33px;
}

.filter-bar select {
    min-width: 112px;
    padding: 0 26px 0 9px;
}

.filter-bar input:focus,
.filter-bar select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.filter-bar .btn {
    min-height: 36px;
    padding: 7px 16px;
    font-size: 13px;
}

.filter-reset {
    align-self: center;
    color: var(--muted);
    font-size: 12px;
    padding: 0 4px;
}

.filter-reset:hover {
    color: var(--accent);
}

.active-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
    color: var(--muted-2);
    font-size: 11.5px;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    border-radius: 5px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-soft);
    font-size: 11px;
}

.filter-chip span {
    color: var(--muted-2);
}

.filter-chip:hover {
    border-color: var(--accent-line);
    color: var(--accent);
}

.archive-list {
    margin-bottom: 22px;
}

.archive-side {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 16px;
}

.month-list {
    display: grid;
}

.month-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 8px;
    border-radius: 6px;
    color: var(--muted);
    font-size: 12.5px;
}

.month-list a em {
    font-style: normal;
    color: var(--muted-2);
    font-family: var(--mono);
    font-size: 10px;
}

.month-list a:hover,
.month-list a.active {
    color: var(--accent);
    background: var(--accent-soft);
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 26px;
}

.page-btn {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: var(--surface);
    color: var(--muted);
    font-size: 12px;
    font-weight: 560;
}

a.page-btn:hover {
    color: var(--accent);
    border-color: var(--accent-line);
}

.page-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    font-weight: 650;
}

[data-theme="dark"] .page-btn.active {
    color: #071326;
}

.page-btn.disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.page-info {
    margin-left: 8px;
    color: var(--muted-2);
    font-size: 11px;
}

/* Hot page */
.period-tabs {
    display: inline-flex;
    padding: 3px;
    gap: 2px;
    border-radius: 9px;
    background: var(--surface-2);
    border: 1px solid var(--border);
}

.period-tabs a {
    padding: 6px 14px;
    border-radius: 6px;
    color: var(--muted);
    font-size: 12.5px;
    font-weight: 580;
}

.period-tabs a.active {
    background: var(--surface);
    color: var(--accent);
    box-shadow: var(--shadow-sm);
    font-weight: 650;
}

.hot-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    padding: 24px 2px 18px;
    color: var(--muted);
    font-size: 12.5px;
}

.hot-summary strong {
    color: var(--text);
    font-family: var(--mono);
    font-size: 14px;
}

.hot-list-full {
    display: grid;
    gap: 11px;
    padding-bottom: 64px;
}

.hot-row {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) 104px;
    gap: 18px;
    align-items: center;
    padding: 20px 22px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
    transition: border 0.16s ease, box-shadow 0.16s ease;
}

.hot-row:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
}

.hot-rank {
    font-family: var(--mono);
    font-size: 24px;
    font-weight: 700;
    color: var(--muted-2);
    text-align: center;
    letter-spacing: -0.05em;
}

.top-three .hot-rank {
    font-size: 27px;
}

.top-1 { border-color: rgba(220, 38, 38, 0.35); }
.top-1 .hot-rank { color: #dc2626; }
.top-2 { border-color: rgba(234, 88, 12, 0.3); }
.top-2 .hot-rank { color: #ea580c; }
.top-3 { border-color: rgba(217, 119, 6, 0.28); }
.top-3 .hot-rank { color: #d97706; }

.hot-body {
    min-width: 0;
}

.hot-title {
    overflow-wrap: anywhere;
    margin: 6px 0 5px;
    font-size: 18px;
    line-height: 1.45;
    font-weight: 680;
    letter-spacing: -0.015em;
}

.hot-title a:hover {
    color: var(--accent);
}

.hot-excerpt {
    overflow-wrap: anywhere;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hot-meter {
    text-align: right;
}

.hot-value {
    display: block;
    color: var(--accent);
    font-family: var(--mono);
    font-size: 26px;
    line-height: 1.1;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.hot-label {
    display: block;
    color: var(--muted-2);
    font-size: 9px;
    letter-spacing: 0.12em;
    margin-top: 1px;
}

.hot-bar {
    display: block;
    height: 3px;
    margin-top: 8px;
    border-radius: 3px;
    background: var(--surface-3);
    overflow: hidden;
}

.hot-bar i {
    display: block;
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--accent), var(--green));
}

/* Article */
.article-container {
    width: min(880px, calc(100% - 48px));
    padding: 30px 0 68px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    color: var(--muted-2);
    font-size: 11.5px;
}

.breadcrumb a:hover {
    color: var(--accent);
}

.breadcrumb-current {
    color: var(--muted);
}

.article {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 42px 46px 36px;
    box-shadow: var(--shadow-sm);
}

.article-header h1 {
    margin: 14px 0 14px;
    font-size: clamp(27px, 3.6vw, 36px);
    line-height: 1.35;
    letter-spacing: -0.035em;
    font-weight: 760;
}

.article-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted-2);
    font-size: 12px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--border);
}

.original-title {
    margin-top: 10px;
    color: var(--muted);
    font-size: 12.5px;
    line-height: 1.6;
}

.translate-note {
    margin-top: 7px;
    padding: 9px 12px;
    border-radius: 7px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--muted);
    font-size: 12px;
    line-height: 1.65;
}

.article-cover {
    margin: 26px 0 4px;
    border-radius: 13px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--surface-3);
}

.article-cover img {
    width: 100%;
    max-height: 430px;
    object-fit: cover;
}

.prose {
    padding-top: 22px;
    color: var(--text-soft);
    font-size: 16px;
    line-height: 1.88;
    overflow-wrap: break-word;
}

.prose > *:first-child {
    margin-top: 0;
}

.prose p {
    margin: 0 0 1.05em;
}

.prose h2,
.prose h3,
.prose h4 {
    color: var(--text);
    line-height: 1.4;
    letter-spacing: -0.02em;
    margin: 1.7em 0 0.7em;
    font-weight: 720;
}

.prose h2 { font-size: 23px; }
.prose h3 { font-size: 19px; }
.prose h4 { font-size: 16px; }

.prose h2::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 0.85em;
    margin-right: 9px;
    border-radius: 2px;
    background: var(--accent);
    vertical-align: -0.06em;
}

.prose a {
    color: var(--accent);
    text-decoration: underline;
    text-decoration-color: var(--accent-line);
    text-underline-offset: 3px;
}

.prose a:hover {
    text-decoration-color: var(--accent);
}

.prose ul,
.prose ol {
    margin: 0 0 1.1em;
    padding-left: 1.5em;
    list-style: revert;
}

.prose li {
    margin: 0.35em 0;
}

.prose blockquote {
    margin: 0 0 1.3em;
    padding: 14px 18px;
    border-left: 3px solid var(--accent);
    background: var(--accent-soft);
    border-radius: 0 8px 8px 0;
    color: var(--text-soft);
}

.prose blockquote p:last-child {
    margin-bottom: 0;
}

.prose code {
    padding: 2px 5px;
    border-radius: 4px;
    background: var(--surface-3);
    border: 1px solid var(--border);
    font-size: 0.86em;
}

.prose pre {
    margin: 0 0 1.3em;
    padding: 16px 18px;
    overflow-x: auto;
    border-radius: 10px;
    background: #0d1726;
    border: 1px solid #1e2b40;
    color: #d7e2f1;
    font-size: 13px;
    line-height: 1.65;
}

.prose pre code {
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font-size: inherit;
}

.prose img {
    margin: 1.2em auto;
    border-radius: 10px;
    border: 1px solid var(--border);
    height: auto;
}

.prose hr {
    border: 0;
    border-top: 1px solid var(--border);
    margin: 2em 0;
}

.prose table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 1.3em;
    font-size: 14px;
}

.prose th,
.prose td {
    padding: 8px 10px;
    border: 1px solid var(--border);
    text-align: left;
}

.prose th {
    background: var(--surface-2);
    font-weight: 650;
    color: var(--text);
}

.prose strong {
    color: var(--text);
    font-weight: 680;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.article-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 24px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
}

.article-source {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 11px;
    color: var(--muted-2);
}

.article-source strong {
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 620;
}

.related-section {
    margin-top: 34px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.related-grid .article-card {
    flex-direction: column;
    gap: 12px;
}

.related-grid .card-thumb {
    width: 100%;
    height: 128px;
    flex-basis: auto;
}

.related-grid .card-title {
    font-size: 15px;
}

/* Empty & error */
.empty-state {
    padding: 56px 28px;
    text-align: center;
    background: var(--surface);
    border: 1px dashed var(--border-strong);
    border-radius: var(--radius);
}

.empty-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 12px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    background: var(--accent-soft);
    color: var(--accent);
}

.empty-icon svg {
    width: 34px;
    height: 34px;
}

.empty-state h3 {
    font-size: 17px;
    margin-bottom: 6px;
}

.empty-state p {
    color: var(--muted);
    font-size: 13px;
    margin-bottom: 18px;
}

.error-page {
    padding: 80px 0;
}

.error-card {
    max-width: 520px;
    margin: 0 auto;
    padding: 46px;
    text-align: center;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.error-code {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 54px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: -0.06em;
}

.error-card h1 {
    margin: 12px 0 8px;
    font-size: 24px;
}

.error-card p {
    color: var(--muted);
    font-size: 14px;
}

.error-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 24px;
}

/* Footer */
.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 0;
    color: var(--muted-2);
    font-size: 11.5px;
}

.footer-about {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.footer-about strong {
    color: var(--text);
    font-size: 13px;
}

.footer-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    white-space: nowrap;
}

.footer-meta a:hover {
    color: var(--accent);
}

/* Forms */
input[type="text"],
input[type="url"],
input[type="password"],
input[type="number"],
input[type="search"],
select,
textarea {
    width: 100%;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 18px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.field > span {
    color: var(--text-soft);
    font-size: 12px;
    font-weight: 620;
}

.field > span em {
    color: var(--red);
    font-style: normal;
    font-size: 10px;
    font-weight: 600;
    margin-left: 3px;
}

.field input,
.field select,
.field textarea {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-2);
    padding: 9px 11px;
    font-size: 13px;
    line-height: 1.5;
    transition: border 0.15s ease, box-shadow 0.15s ease;
}

.field textarea {
    resize: vertical;
    font-family: var(--mono);
    font-size: 12px;
    line-height: 1.55;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.field small {
    color: var(--muted-2);
    font-size: 10.5px;
    line-height: 1.5;
}

.field-wide {
    grid-column: 1 / -1;
}

.field-check {
    flex-direction: row;
    align-items: flex-start;
    flex-wrap: wrap;
    padding-top: 2px;
}

.field-check input {
    width: 16px;
    height: 16px;
    margin: 2px 0 0;
    accent-color: var(--accent);
}

.field-check > span {
    flex: 1;
    min-width: 100px;
}

.field-check small {
    flex-basis: 100%;
    padding-left: 24px;
}

/* Admin */
.admin-body {
    background: var(--bg);
}

.admin-header-inner {
    min-height: 62px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand-compact .brand-mark {
    width: 32px;
    height: 32px;
    border-radius: 9px;
}

.brand-compact .brand-mark svg {
    width: 21px;
    height: 21px;
}

.brand-compact .brand-text strong {
    font-size: 16px;
}

.brand-compact .brand-text small {
    font-size: 9px;
    letter-spacing: 0.12em;
}

.admin-nav {
    display: flex;
    align-items: center;
    gap: 3px;
    flex: 1;
}

.admin-nav a {
    padding: 6px 12px;
    border-radius: 7px;
    color: var(--muted);
    font-size: 12.5px;
    font-weight: 560;
}

.admin-nav a:hover {
    color: var(--text);
    background: var(--surface-2);
}

.admin-nav a.active {
    color: var(--accent);
    background: var(--accent-soft);
    font-weight: 650;
}

.admin-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-link {
    border: 0;
    background: none;
    padding: 4px 2px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 560;
}

.admin-link:hover {
    color: var(--accent);
}

.logout-form {
    margin: 0;
}

.logout-form .admin-link {
    color: var(--muted);
}

.admin-main {
    padding: 34px 0 64px;
}

.admin-page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 22px;
}

.admin-page-head h1 {
    margin: 8px 0 5px;
    font-size: 30px;
    line-height: 1.2;
    letter-spacing: -0.035em;
    font-weight: 750;
}

.admin-page-head .page-lead {
    font-size: 13px;
}

.crawl-trigger-form {
    flex: 0 0 auto;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.admin-stat {
    padding: 16px 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.admin-stat span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

.admin-stat strong {
    color: var(--text);
    font-size: 25px;
    line-height: 1.15;
    font-weight: 740;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
}

.admin-stat strong small {
    color: var(--muted-2);
    font-size: 12px;
    font-weight: 500;
}

.crawl-panel {
    margin-bottom: 18px;
}

.crawl-overview {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.crawl-line {
    padding: 11px 13px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-2);
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.crawl-line span {
    color: var(--muted-2);
    font-size: 10px;
}

.crawl-line strong {
    color: var(--text-soft);
    font-size: 12.5px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crawl-counters {
    display: flex;
    gap: 22px;
    padding: 10px 2px 14px;
}

.crawl-counters div {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.crawl-counters strong {
    font-family: var(--mono);
    font-size: 20px;
    color: var(--accent);
    font-weight: 700;
}

.crawl-counters span {
    color: var(--muted);
    font-size: 10.5px;
}

.crawl-log-wrap {
    border: 1px solid var(--border);
    border-radius: 9px;
    overflow: hidden;
}

.crawl-log-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 11px;
    background: var(--surface-2);
    border-bottom: 1px solid var(--border);
    color: var(--muted-2);
    font-size: 10px;
}

.log-tail {
    margin: 0;
    padding: 12px;
    max-height: 190px;
    overflow: auto;
    background: #0d1726;
    color: #bcd0e8;
    font-family: var(--mono);
    font-size: 11px;
    line-height: 1.65;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    height: 21px;
    padding: 0 8px;
    border-radius: 5px;
    font-size: 10.5px;
    font-weight: 650;
    white-space: nowrap;
}

.status-running { color: var(--blue); background: var(--blue-soft); }
.status-ok { color: var(--green); background: var(--green-soft); }
.status-error { color: var(--red); background: var(--red-soft); }
.status-idle { color: var(--muted); background: var(--surface-3); }

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: 10px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px;
}

.data-table th {
    padding: 9px 13px;
    background: var(--surface-2);
    border-bottom: 1px solid var(--border);
    color: var(--muted-2);
    font-size: 10px;
    font-weight: 700;
    text-align: left;
    white-space: nowrap;
    letter-spacing: 0.04em;
}

.data-table td {
    padding: 11px 13px;
    border-bottom: 1px solid var(--border);
    color: var(--text-soft);
    vertical-align: top;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr:hover {
    background: var(--surface-2);
}

.data-table td strong {
    color: var(--text);
    font-weight: 620;
}

.data-table a {
    color: var(--text-soft);
}

.data-table a:hover {
    color: var(--accent);
}

.table-sub {
    color: var(--muted-2);
    font-family: var(--mono);
    font-size: 9.5px;
    margin-top: 2px;
}

.table-error {
    max-width: 240px;
    margin-top: 3px;
    color: var(--red);
    font-size: 9.5px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 9px;
    flex-wrap: wrap;
    white-space: nowrap;
}

.table-actions form {
    margin: 0;
}

.table-actions a,
.table-actions button {
    border: 0;
    background: none;
    padding: 0;
    color: var(--accent);
    font-size: 11.5px;
}

.table-actions button:hover,
.table-actions a:hover {
    text-decoration: underline;
}

.table-actions .danger-link {
    color: var(--red);
}

.danger-link {
    color: var(--red);
}

.url-cell {
    max-width: 280px;
}

.url-cell a {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--muted);
}

.sources-table td {
    vertical-align: middle;
}

.notice {
    margin-bottom: 18px;
    padding: 12px 15px;
    border-radius: 9px;
    border: 1px solid;
    font-size: 12.5px;
    line-height: 1.7;
}

.notice code {
    padding: 1px 4px;
    border-radius: 3px;
    background: rgba(0, 0, 0, 0.07);
    font-family: var(--mono);
}

.notice a {
    text-decoration: underline;
    font-weight: 600;
}

.notice-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

.notice-error {
    color: var(--red);
    background: var(--red-soft);
    border-color: rgba(220, 38, 38, 0.25);
}

.notice ul {
    margin: 0;
    padding-left: 18px;
    list-style: disc;
}

[data-theme="dark"] .notice-warning {
    color: var(--orange);
    background: var(--orange-soft);
    border-color: rgba(251, 191, 36, 0.25);
}

.flash-stack {
    display: grid;
    gap: 8px;
    margin-bottom: 16px;
}

.flash {
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid;
    font-size: 12.5px;
    line-height: 1.6;
}

.flash-success {
    color: #065f46;
    background: #ecfdf5;
    border-color: #a7f3d0;
}

.flash-error {
    color: var(--red);
    background: var(--red-soft);
    border-color: rgba(220, 38, 38, 0.25);
}

.flash-info {
    color: var(--blue);
    background: var(--blue-soft);
    border-color: rgba(2, 132, 199, 0.2);
}

[data-theme="dark"] .flash-success {
    color: var(--green);
    background: var(--green-soft);
    border-color: rgba(45, 212, 191, 0.25);
}

.admin-form {
    padding: 0;
    margin-bottom: 18px;
    overflow: hidden;
}

.form-section {
    padding: 22px 24px;
    border-bottom: 1px solid var(--border);
}

.form-section:last-of-type {
    border-bottom: 0;
}

.form-section h2 {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 14px;
}

.form-help {
    color: var(--muted);
    font-size: 11.5px;
    margin: -6px 0 14px;
}

.form-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 24px;
    background: var(--surface-2);
    border-top: 1px solid var(--border);
}

.info-panel {
    font-size: 12.5px;
    color: var(--muted);
}

.info-panel p {
    margin-bottom: 10px;
}

.info-panel .muted {
    color: var(--muted-2);
    font-size: 11px;
}

.code-block {
    margin: 0 0 14px;
    padding: 9px 12px;
    border-radius: 7px;
    background: var(--surface-3);
    border: 1px solid var(--border);
    color: var(--text-soft);
    font-family: var(--mono);
    font-size: 11.5px;
    overflow-x: auto;
}

.admin-note {
    margin-top: 14px;
    color: var(--muted-2);
    font-size: 11.5px;
}

/* Login */
.login-body {
    display: grid;
    place-items: center;
    min-height: 100vh;
    background:
        radial-gradient(800px 400px at 50% -10%, var(--accent-soft), transparent 70%),
        var(--bg);
}

.login-wrap {
    width: min(420px, calc(100% - 32px));
    padding: 24px 0;
}

.login-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 32px;
    box-shadow: var(--shadow);
}

.login-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 24px;
}

.login-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--accent);
    background: var(--accent-soft);
    border: 1px solid var(--accent-line);
}

.login-mark svg {
    width: 27px;
    height: 27px;
}

.login-brand div {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.login-brand strong {
    font-size: 16px;
    font-weight: 720;
}

.login-brand span {
    color: var(--muted);
    font-size: 10.5px;
}

.login-card h1 {
    font-size: 24px;
    letter-spacing: -0.03em;
    margin-bottom: 4px;
}

.login-lead {
    color: var(--muted);
    font-size: 12.5px;
    margin-bottom: 20px;
}

.login-form {
    display: grid;
    gap: 8px;
}

.login-form label {
    color: var(--text-soft);
    font-size: 11.5px;
    font-weight: 600;
}

.login-form input {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-2);
    padding: 10px 12px;
    font-size: 14px;
    margin-bottom: 6px;
}

.login-form input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.login-hint {
    margin-top: 16px;
    color: var(--muted-2);
    font-size: 10.5px;
    line-height: 1.6;
}

.login-hint code {
    padding: 1px 4px;
    border-radius: 3px;
    background: var(--surface-3);
    font-family: var(--mono);
}

.login-footer {
    text-align: center;
    margin-top: 16px;
    color: var(--muted-2);
    font-size: 11.5px;
}

.login-footer a:hover {
    color: var(--accent);
}

/* Responsive */
@media (max-width: 1080px) {
    .home-grid {
        grid-template-columns: minmax(0, 1fr) 320px;
        gap: 28px;
    }
    .hero-stats {
        width: 340px;
    }
    .header-search {
        width: 220px;
    }
    .archive-layout {
        grid-template-columns: minmax(0, 1fr) 250px;
        gap: 24px;
    }
}

@media (max-width: 900px) {
    .header-inner {
        flex-wrap: wrap;
        gap: 10px 14px;
        padding: 12px 0;
        min-height: 0;
    }
    .main-nav {
        order: 3;
        flex: 1 1 auto;
    }
    .header-search {
        order: 4;
        width: 100%;
        flex: 1 1 100%;
    }
    .brand {
        margin-right: auto;
    }
    .hero-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 30px;
        padding: 42px 0;
    }
    .hero-stats {
        width: 100%;
        max-width: 520px;
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    .stat-card {
        min-height: 92px;
        padding: 14px;
    }
    .stat-value {
        font-size: 25px;
    }
    .home-grid,
    .archive-layout {
        grid-template-columns: minmax(0, 1fr);
    }
    .sidebar,
    .archive-side {
        position: static;
    }
    .sidebar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .archive-side {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .admin-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .crawl-overview {
        grid-template-columns: 1fr;
    }
    .related-grid {
        grid-template-columns: 1fr;
    }
    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

@media (max-width: 680px) {
    .container {
        width: calc(100% - 30px);
    }
    .main-nav {
        order: 3;
        flex: 1 1 100%;
        width: 100%;
        overflow-x: auto;
        scrollbar-width: none;
    }
    .header-search {
        order: 4;
        flex: 1 1 100%;
        width: 100%;
    }
    .theme-toggle {
        margin-left: auto;
    }
    .main-nav::-webkit-scrollbar {
        display: none;
    }
    .main-nav a {
        white-space: nowrap;
        padding: 7px 11px;
    }
    .hero h1 {
        font-size: 34px;
    }
    .hero-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .article-card {
        padding: 14px;
        gap: 13px;
    }
    .card-thumb {
        width: 104px;
        height: 79px;
        flex-basis: 104px;
    }
    .card-title {
        font-size: 15.5px;
        margin-top: 6px;
    }
    .card-summary {
        -webkit-line-clamp: 2;
        font-size: 12.5px;
    }
    .card-meta {
        padding-top: 7px;
    }
    .sidebar,
    .archive-side {
        grid-template-columns: 1fr;
    }
    .page-head-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        padding: 30px 0 26px;
    }
    .filter-bar > label:not(.filter-search) {
        flex: 1 1 40%;
    }
    .filter-bar select {
        width: 100%;
    }
    .filter-bar .btn {
        flex: 1 1 100%;
    }
    .hot-row {
        grid-template-columns: 34px minmax(0, 1fr);
        gap: 12px;
        padding: 16px;
    }
    .hot-meter {
        grid-column: 2;
        display: flex;
        align-items: center;
        gap: 8px;
        text-align: left;
    }
    .hot-value {
        font-size: 18px;
    }
    .hot-label {
        margin: 0;
    }
    .hot-bar {
        flex: 1;
        margin: 0;
    }
    .article {
        padding: 26px 20px 24px;
        border-radius: 15px;
    }
    .article-header h1 {
        font-size: 26px;
    }
    .prose {
        font-size: 15px;
    }
    .prose pre {
        padding: 13px;
        font-size: 12px;
    }
    .article-footer {
        flex-direction: column;
        align-items: flex-start;
    }
    .admin-header-inner {
        flex-wrap: wrap;
        padding: 10px 0;
        gap: 8px;
    }
    .admin-nav {
        order: 3;
        flex-basis: 100%;
        overflow-x: auto;
    }
    .admin-page-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
    .admin-stats {
        grid-template-columns: 1fr 1fr;
    }
    .form-grid {
        grid-template-columns: 1fr;
    }
    .form-section {
        padding: 18px;
    }
    .form-actions {
        padding: 14px 18px;
    }
    .crawl-counters {
        gap: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}
