/* ===== 剑灵情报站 — 竹林清风 · 视觉重构 ===== */
/* Frontend Design Pro 设计规范：
   - OKLCH 色彩空间（感知均匀）
   - 个性字体配对：DM Sans + Noto Serif SC
   - 8px 基础间距系统 + 65ch 内容宽度
   - 带色调中性色（不要纯灰）
   - 暗色模式背景 #0f0f0f 附近，不纯黑
*/

/* ===== 亮色模式 ===== */
:root, [data-theme="light"] {
    /* 主色调 — 竹青色系 OKLCH */
    --green-hue:      140;
    --green:          oklch(0.62 0.12 var(--green-hue));
    --green-dim:      oklch(0.50 0.10 var(--green-hue));
    --green-pale:     oklch(0.85 0.06 var(--green-hue));
    --green-bg:       oklch(0.95 0.03 var(--green-hue));

    /* 暖色点缀 */
    --gold:           oklch(0.72 0.13 85);
    --gold-dim:       oklch(0.62 0.10 85);
    --rose:           oklch(0.65 0.08 20);
    --rose-pale:      oklch(0.88 0.04 20);

    /* 中性色 — 暖调灰（warm gray）*/
    --bg:             oklch(0.97 0.01 85);
    --bg-alt:         oklch(0.94 0.01 85);
    --surface:        oklch(0.99 0.005 85);
    --surface-hover:  oklch(0.96 0.01 85);
    --border:         oklch(0.88 0.01 85 / 0.6);
    --border-hover:   oklch(0.78 0.02 85 / 0.6);

    /* 文本 — 暖黑色系 */
    --text:           oklch(0.22 0.01 85);
    --text-dim:       oklch(0.45 0.01 85);
    --text-muted:     oklch(0.60 0.01 85);

    /* 导航 */
    --nav-bg:         oklch(0.97 0.01 85 / 0);
    --nav-bg-scrolled: oklch(0.96 0.01 85 / 0.88);

    /* 阴影 */
    --shadow-sm:      0 1px 3px oklch(0 0 0 / 0.06);
    --shadow-md:      0 4px 12px oklch(0 0 0 / 0.08);
    --shadow-lg:      0 12px 40px oklch(0 0 0 / 0.10);
    --shadow-glow:    0 0 20px var(--green-pale);

    /* 圆角 */
    --radius-sm:      6px;
    --radius:         10px;
    --radius-lg:      18px;
    --radius-xl:      24px;

    /* 字体比例 (Major Third 1.25) */
    --text-xs:        0.75rem;   /* 12px */
    --text-sm:        0.8125rem; /* 13px */
    --text-base:      0.9375rem; /* 15px */
    --text-lg:        1.125rem;  /* 18px */
    --text-xl:        1.375rem;  /* 22px */
    --text-2xl:       1.75rem;   /* 28px */

    /* 间距系统 (8px base) */
    --space-1:        4px;
    --space-2:        8px;
    --space-3:        12px;
    --space-4:        16px;
    --space-5:        24px;
    --space-6:        32px;
    --space-8:        48px;

    /* 行高 */
    --leading-body:   1.65;
    --leading-heading: 1.3;
    --leading-tight:  1.15;

    /* 语义色 */
    --success:        oklch(0.62 0.15 145);
    --warning:        oklch(0.72 0.15 85);
    --error:          oklch(0.55 0.18 30);
    --info:           oklch(0.55 0.15 250);

    /* z-index 规范 */
    --z-base:         0;
    --z-dropdown:     100;
    --z-sticky:       200;
    --z-overlay:      300;
    --z-modal:        400;
    --z-toast:        500;

    /* 动画时长 */
    --duration-fast:  150ms;
    --duration-base:  250ms;
    --duration-slow:  400ms;

    /* 骨架屏 */
    --skeleton:       linear-gradient(90deg, oklch(0.92 0.01 85) 25%, oklch(0.88 0.02 85) 50%, oklch(0.92 0.01 85) 75%);

    /* Hero 渐变覆盖 */
    --hero-overlay:   linear-gradient(180deg, oklch(0.97 0.01 85 / 0) 0%, oklch(0.94 0.01 85) 100%);
}

/* ===== 暗色模式 ===== */
[data-theme="dark"] {
    --green:          #6bc840;
    --green-dim:      #8ae060;
    --green-pale:     #2a4a28;
    --green-bg:       rgba(107,200,64,0.08);

    --gold:           #d8b838;
    --gold-dim:       #b89820;
    --rose:           #8a6060;
    --rose-pale:      #2a1a1a;

    --bg:             #0f1a12;
    --bg-alt:         #1a2a1e;
    --surface:        #1e2a1c;
    --surface-hover:  #243222;
    --border:         rgba(107, 200, 64, 0.15);
    --border-hover:   rgba(107, 200, 64, 0.3);

    --text:           #d4e0d0;
    --text-dim:       #a0b8a0;
    --text-muted:     #708870;

    --nav-bg:         rgba(15, 26, 18, 0);
    --nav-bg-scrolled: rgba(15, 26, 18, 0.92);

    --shadow-sm:      0 1px 3px rgba(0, 0, 0, 0.25);
    --shadow-md:      0 4px 12px rgba(0, 0, 0, 0.35);
    --shadow-lg:      0 12px 40px rgba(0, 0, 0, 0.45);
    --shadow-glow:    0 0 20px rgba(107,200,64,0.15);

    --skeleton:       linear-gradient(90deg, rgba(107,200,64,0.06) 25%, rgba(107,200,64,0.12) 50%, rgba(107,200,64,0.06) 75%);

    --success:        #4ade80;
    --warning:        #fbbf24;
    --error:          #f87171;
    --info:           #60a5fa;

    --z-base:         0;
    --z-dropdown:     100;
    --z-sticky:       200;
    --z-overlay:      300;
    --z-modal:        400;
    --z-toast:        500;

    --duration-fast:  150ms;
    --duration-base:  250ms;
    --duration-slow:  400ms;

    --hero-overlay:   linear-gradient(180deg, rgba(15,26,18,0) 0%, #0f1a12 100%);
}

/* ===== Reset & Base ===== */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior:smooth; -webkit-font-smoothing: antialiased; }

/* 焦点指示 — WCAG 2.4.7 */
:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
    border-radius: 4px;
}
:focus:not(:focus-visible) {
    outline: none;
}

/* 运动安全 — WCAG 2.3.3 */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

body {
    font-family: 'DM Sans', 'Noto Serif SC', 'Source Han Serif SC', serif;
    background: var(--bg);
    color: var(--text);
    line-height: var(--leading-body);
    font-size: var(--text-base);
    letter-spacing: 0.01em;
    min-height: 100vh;
    transition: background 0.5s ease, color 0.3s ease;
}

/* 流体排版 — 随视口缩放 */
h1 { font-size: clamp(1.5rem, 1.2rem + 2vw, 2.8rem); }
h2 { font-size: clamp(1.2rem, 1rem + 1.5vw, 1.8rem); }
h3 { font-size: clamp(1rem, 0.9rem + 0.8vw, 1.3rem); }

[data-theme="dark"] body {
    background: linear-gradient(180deg, #0f1a12 0%, #1a2a1e 50%, #1e261c 100%);
    background-attachment: fixed;
}

/* 背景纹理 — 点阵 + 几何叠加 */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: 
        radial-gradient(rgba(0,0,0,0.03) 1px, transparent 1px),
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%235aa038' fill-opacity='0.06'%3E%3Cpolygon points='30 0 60 30 30 60 0 30'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    background-size: 24px 24px, 60px 60px;
    pointer-events: none;
    z-index: 0;
}
[data-theme="dark"] body::before {
    background-image: 
        radial-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%236bc840' fill-opacity='0.04'%3E%3Cpolygon points='30 0 60 30 30 60 0 30'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    background-size: 24px 24px, 60px 60px;
}

.container { max-width: 1200px; margin:0 auto; padding:0 28px; }

/* 跳过导航 — 仅键盘可见 */
.skip-link {
    position: fixed; top: -100%; left: 50%; z-index: 999;
    transform: translateX(-50%);
    background: var(--green); color: #fff;
    padding: 8px 24px; border-radius: 0 0 8px 8px;
    font-size: 0.85rem; font-weight: 600;
    text-decoration: none;
    transition: top 0.2s;
}
.skip-link:focus {
    top: 0;
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed; top:0; left:0; right:0; z-index:100;
    background: var(--nav-bg);
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    border-bottom: 1px solid transparent;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.navbar.scrolled {
    background: var(--nav-bg-scrolled);
    border-bottom-color: var(--border);
}

.nav-inner {
    display: flex; align-items: center;
    height: 64px; gap: 20px;
}

.logo {
    display: flex; align-items: center; gap: 10px;
    margin-right: auto;
    position: relative;
}
.logo-icon { font-size: 1.35rem; }
.logo-text {
    font-size: 1.05rem; font-weight: 700;
    color: var(--green-dim);
    letter-spacing: 0.03em;
}
.logo-badge {
    font-size: 0.5rem; font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 3px;
    padding: 2px 8px;
    border: 1px solid var(--border);
    border-radius: 4px;
    text-transform: uppercase;
}

/* 搜索框 */
.search-box { flex: 0 1 220px; position: relative; }
.search-box input {
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 7px 34px 7px 16px;
    color: var(--text);
    font-size: 0.8rem;
    outline: none;
    font-family: inherit;
    transition: all 0.25s ease;
}
.search-box input:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px var(--green-pale);
}
.search-box input::placeholder { color: var(--text-muted); }
.search-box .search-icon {
    position: absolute; right: 12px; top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
    font-size: 0.85rem;
}
.search-results {
    display: none; position: absolute;
    top: calc(100% + 6px); left: 0; right: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    z-index: 50;
    max-height: 340px; overflow-y: auto;
    box-shadow: var(--shadow-lg);
}
.search-results.visible { display: block; }
.search-results .result-item {
    padding: 10px 14px; cursor: pointer;
    border-bottom: 1px solid var(--border);
    transition: background 0.15s;
}
.search-results .result-item:last-child { border-bottom: none; }
.search-results .result-item:hover { background: var(--green-bg); }
.search-results .result-title { font-size: 0.82rem; font-weight: 500; }
.search-results .result-cat { font-size: 0.7rem; color: var(--text-dim); margin-top: 2px; }

/* 导航链接 */
.nav-links { display: flex; gap: 6px; list-style: none; }
.nav-icon-link {
    display: flex; flex-direction: column; align-items: center; gap: 2px;
    padding: 6px 16px;
    border-radius: 14px;
    text-decoration: none;
    background: var(--surface);
    border: 1px solid var(--border);
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    min-width: 52px;
}
.nav-icon-link:hover {
    transform: translateY(-2px);
    border-color: var(--green);
    box-shadow: var(--shadow-glow);
}
.nav-icon { font-size: 1.6rem; line-height: 1; }
.nav-label { font-size: 0.6rem; color: var(--text-dim); font-weight: 500; }

/* 主题切换 */
.theme-toggle {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 5px 14px;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    color: var(--text-dim);
    transition: all 0.25s;
    display: flex; align-items: center; gap: 6px;
    flex-shrink: 0;
}
.theme-toggle:hover {
    border-color: var(--green);
    color: var(--green-dim);
    background: var(--green-bg);
}
.theme-toggle .label { font-size: 0.68rem; font-weight: 500; }

/* ===== Hero 区 ===== */
.hero-section {
    position: relative;
    min-height: 60vh;
    display: flex; align-items: center;
    padding: 80px 0 32px;
    overflow: hidden;
}
.hero-bg-layer {
    position: absolute; inset: 0; z-index: 0;
    overflow: hidden;
    background:
        radial-gradient(ellipse at 70% 20%, var(--green-pale) 0%, transparent 50%),
        radial-gradient(ellipse at 30% 80%, var(--gold-dim) 0%, transparent 40%);
}
[data-theme="dark"] .hero-bg-layer {
    background:
        radial-gradient(ellipse at 70% 20%, rgba(107,200,64,0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 30% 80%, rgba(216,184,56,0.05) 0%, transparent 40%);
}
.hero-bg-layer::before {
    content: '';
    position: absolute; inset: -30px;
    background: url('/images/hero_light.jpg') center center / cover no-repeat;
    opacity: 0.2;
    animation: heroPan 35s ease-in-out infinite alternate;
    filter: saturate(0.8) contrast(1.1);
    mix-blend-mode: overlay;
}
.webp .hero-bg-layer::before {
    background: url('/images/hero_light.webp') center center / cover no-repeat;
}
[data-theme="dark"] .hero-bg-layer::before {
    opacity: 0.1;
    filter: saturate(0.5) contrast(0.9) brightness(0.5);
    mix-blend-mode: screen;
}
.hero-bg-layer::after {
    content: '';
    position: absolute; inset: 0;
    background: var(--hero-overlay);
}

@keyframes heroPan {
    0%   { transform: scale(1) translate(0, 0); }
    100% { transform: scale(1.06) translate(-18px, -10px); }
}

.hero-inner { position: relative; z-index: 1; width: 100%; }

/* 版本选择卡片 */
.hero-versions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 10px;
}
.version-card {
    padding: 14px 18px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    display: flex; align-items: center; gap: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    position: relative;
    overflow: hidden;
    opacity: 0; transform: translateY(16px);
    animation: fadeSlideUp 0.5s ease forwards;
}
.version-card:nth-child(1) { animation-delay: 0.1s; }
.version-card:nth-child(2) { animation-delay: 0.2s; }
.version-card:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.version-card::after {
    content: '';
    position: absolute; bottom: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--green), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}
.version-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.version-card:hover::after { opacity: 1; }
.version-card:active {
    transform: translateY(-1px) scale(0.98);
}
.version-card.active {
    border-color: var(--green);
    background: var(--green-bg);
}
.version-card.active::after { opacity: 1; }

.ver-icon { font-size: 1.3rem; flex-shrink: 0; }
.ver-name { font-weight: 600; font-size: 0.88rem; color: var(--text); }
.ver-sub { color: var(--text-dim); font-size: 0.68rem; display: block; margin-top: 1px; }

/* Hero 置顶视频卡片 */
.hero-featured-video {
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
    background: linear-gradient(135deg, oklch(0.15 0.02 250), oklch(0.12 0.02 220));
    position: relative;
    min-height: 140px;
    display: flex; align-items: center;
    padding: 24px 32px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: var(--shadow-md);
}
.hero-featured-video:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}
[data-theme="dark"] .hero-featured-video {
    background: linear-gradient(135deg, oklch(0.12 0.02 250 / 0.8), oklch(0.08 0.02 220 / 0.8));
}

/* ===== 特色卡片 ===== */
.features-section { position: relative; z-index: 1; margin: -20px 0 40px; }
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}
.feature-card {
    padding: 22px 18px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    position: relative;
    overflow: hidden;
}
.feature-card::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0;
    height: 3px;
    opacity: 0;
    transition: opacity 0.3s;
}
.feature-card:nth-child(1)::before { background: linear-gradient(90deg, var(--green), var(--green-pale)); }
.feature-card:nth-child(2)::before { background: linear-gradient(90deg, var(--gold), var(--gold-dim)); }
.feature-card:nth-child(3)::before { background: linear-gradient(90deg, var(--rose), var(--rose-pale)); }
.feature-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-hover);
    box-shadow: var(--shadow-md);
}
.feature-card:hover::before { opacity: 1; }
.feature-card:active {
    transform: translateY(-2px) scale(0.97);
}

.feature-icon {
    font-size: 1.8rem;
    margin-bottom: 8px;
    display: block;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.feature-card:hover .feature-icon { transform: scale(1.2) rotate(-5deg); }
.feature-title { font-weight: 600; font-size: 0.95rem; margin-bottom: 4px; color: var(--text); }
.feature-desc { color: var(--text-dim); font-size: 0.82rem; }

/* ===== 文章列表 ===== */
.news-section { position: relative; z-index: 1; padding: 0 0 50px; }
.section-header {
    display: flex; justify-content: space-between; align-items: flex-end;
    margin-bottom: 22px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--green-pale);
}
.section-title-news {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--green-dim);
    position: relative;
    padding-left: 16px;
}
.section-title-news::before {
    content: '';
    position: absolute; left: 0; top: 4px; bottom: 4px;
    width: 3px;
    background: var(--green);
    border-radius: 2px;
}
.news-count { color: var(--text-muted); font-size: 0.88rem; font-weight: 500; white-space: nowrap; }

/* 查看全部 */
.view-all {
    grid-column: 1 / -1;
    text-align: center;
    padding: 16px 0 8px;
}
.view-all-link {
    display: inline-block;
    padding: 8px 24px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}
.view-all-link:hover {
    background: var(--green-bg);
    border-color: var(--green);
    color: var(--green);
}

/* 分类筛选标签 */
.filter-tags {
    display: flex; gap: 6px; flex-wrap: wrap;
    margin-right: 12px;
}
.filter-tag {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 100px;
    font-size: 0.72rem;
    font-weight: 500;
    cursor: pointer;
    color: var(--text-dim);
    background: var(--surface);
    border: 1px solid var(--border);
    transition: all 0.2s;
    user-select: none;
}
.filter-tag:hover {
    border-color: var(--green);
    color: var(--green-dim);
}
.filter-tag.active {
    background: var(--green);
    color: #fff;
    border-color: var(--green);
}
@media (max-width: 768px) {
    .section-header { flex-wrap: wrap; }
    .section-header-extra { width: 100%; margin-top: 8px; }
    .filter-tags { margin-right: 0; }
    .filter-tag { font-size: 0.68rem; padding: 4px 10px; }
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* 文章卡片 */
.news-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: var(--shadow-sm);
    opacity: 0; transform: translateY(24px);
}
.news-card.visible {
    opacity: 1; transform: translateY(0);
}
/* 交错入场 — elite-frontend-design 模式 */
.news-card:nth-child(1) { transition-delay: 0ms; }
.news-card:nth-child(2) { transition-delay: 60ms; }
.news-card:nth-child(3) { transition-delay: 120ms; }
.news-card:nth-child(4) { transition-delay: 180ms; }
.news-card:nth-child(5) { transition-delay: 240ms; }
.news-card:nth-child(6) { transition-delay: 300ms; }

.news-card:hover {
    transform: translateY(-6px);
    border-color: var(--green-pale);
    box-shadow: var(--shadow-md);
}
/* 按下状态 */
.news-card:active {
    transform: translateY(-2px) scale(0.98);
    transition-duration: 0.1s;
}

.card-image {
    height: 170px;
    background-size: cover;
    background-position: center;
    position: relative;
}
.card-image::after {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(transparent 40%, var(--surface));
}
.card-badge {
    position: absolute; top: 12px; left: 12px;
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: 600;
    z-index: 1;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.card-badge.badge-公告 { background: var(--green); color: #fff; }
.card-badge.badge-攻略 { background: var(--gold); color: oklch(0.2 0.02 85); }
.card-badge.badge-实时科技 { background: linear-gradient(135deg, #1e88e5, #0d47a1); color: #fff; }
.card-badge.badge-活动 { background: var(--rose); color: #fff; }
.card-badge.badge-职业 { background: oklch(0.55 0.08 220); color: #fff; }
.card-badge.badge-AI资讯 { background: linear-gradient(135deg, oklch(0.50 0.15 290), oklch(0.60 0.12 310)); color: #fff; }

.card-body {
    padding: 16px 20px 18px;
    position: relative;
}
/* 分类颜色标记 — 左侧竖条 */
.card-body::before {
    content: '';
    position: absolute; left: 0; top: 18px; bottom: 18px; width: 3px;
    border-radius: 0 2px 2px 0;
}
.news-card[data-cat="公告"] .card-body::before { background: var(--green); }
.news-card[data-cat="攻略"] .card-body::before { background: var(--gold); }
.news-card[data-cat="活动"] .card-body::before { background: var(--rose); }
.news-card[data-cat="职业"] .card-body::before { background: oklch(0.55 0.08 220); }
.news-card[data-cat="AI资讯"] .card-body::before { background: linear-gradient(135deg, oklch(0.50 0.15 290), oklch(0.60 0.12 310)); }

.card-title {
    font-size: 1.02rem;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.45;
    color: var(--text);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-summary {
    color: var(--text-dim);
    font-size: 0.84rem;
    line-height: 1.6;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-footer {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* ===== 骨架屏 ===== */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.skeleton-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.skeleton-card .skeleton-img { height: 170px; background: var(--skeleton); background-size: 200% 100%; animation: shimmer 1.5s ease-in-out infinite; }
.skeleton-card .skeleton-body { padding: 16px 20px 18px; }
.skeleton-card .skeleton-line { height: 14px; margin-bottom: 10px; background: var(--skeleton); background-size: 200% 100%; animation: shimmer 1.5s ease-in-out infinite; border-radius: 4px; }
.skeleton-card .skeleton-line:last-child { width: 60%; }
.skeleton-card .skeleton-line-sm { height: 10px; width: 30%; margin-top: 12px; background: var(--skeleton); background-size: 200% 100%; animation: shimmer 1.5s ease-in-out infinite; border-radius: 4px; }

/* ===== 文章详情页（独立页面） ===== */
.article-page { padding: 100px 0 40px; max-width: 760px; margin: 0 auto; }
.article-page .article-title { font-size: 1.8rem; margin-bottom: 12px; line-height: 1.4; color: var(--text); }
.article-page .article-meta { color: var(--text-dim); font-size: 0.92rem; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
.article-page .back-link { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 18px; color: var(--text-dim); font-size: 0.88rem; text-decoration: none; transition: color 0.2s; }
.article-page .back-link:hover { color: var(--green-dim); }

/* ===== 阅读进度条 ===== */
.reading-progress {
    position: fixed; top: 0; left: 0; height: 3px;
    background: linear-gradient(90deg, var(--green), var(--gold));
    z-index: 200; width: 0%;
    transition: width 0.1s linear;
}

/* ===== 返回顶部 ===== */
.back-to-top {
    position: fixed; bottom: 32px; right: 32px; z-index: 99;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-dim);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: translateY(20px); pointer-events: none;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: var(--shadow-md);
}
.back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { border-color: var(--green); color: var(--green-dim); transform: translateY(-2px); }

/* ===== 评论区 ===== */
.comment-section { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--border); }
.comment-title { font-weight: 600; margin-bottom: 12px; color: var(--green-dim); font-size: 1rem; }
.comment-form { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.comment-form input, .comment-form textarea {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 9px 14px;
    color: var(--text);
    font-size: 0.88rem;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.comment-form input:focus, .comment-form textarea:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px var(--green-pale);
}
.comment-form input { flex: 0 0 100px; }
.comment-form textarea { flex: 1; min-width: 160px; resize: vertical; min-height: 38px; }
.comment-form button {
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    background: var(--green);
    border: none;
    color: #fff;
    font-size: 0.88rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}
.comment-form button:hover { background: var(--green-dim); transform: translateY(-1px); }
.comment-form button:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.comment-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    animation: fadeUp 0.3s ease;
}
.comment-author { font-weight: 600; font-size: 0.88rem; color: var(--green-dim); }
.comment-time { color: var(--text-muted); font-size: 0.7rem; margin-left: 8px; }
.comment-text { margin-top: 4px; font-size: 0.88rem; color: var(--text-dim); line-height: 1.6; }
.comment-empty { color: var(--text-muted); font-size: 0.82rem; padding: 16px 0; text-align: center; }

/* ===== 相关文章 ===== */
.related-section { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--border); display: none; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.related-card {
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}
.related-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-hover);
}
.related-img { height: 100px; background-size: cover; background-position: center; }
.related-info { padding: 10px 12px; }
.related-title { font-size: 0.82rem; font-weight: 600; color: var(--text); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.related-meta { font-size: 0.7rem; color: var(--text-muted); margin-top: 4px; }

/* ===== 底部 ===== */
.footer {
    position: relative; z-index: 1;
    border-top: 1px solid var(--border);
    padding: 32px 0 20px;
    margin-top: 40px;
    background: var(--bg-alt);
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 28px; margin-bottom: 16px; }
.footer-logo { font-weight: 700; font-size: 0.92rem; color: var(--green-dim); margin-bottom: 4px; }
.footer-desc { color: var(--text-dim); font-size: 0.76rem; line-height: 1.6; }
.footer-links { display: flex; flex-direction: column; gap: 6px; }
.footer-links a {
    color: var(--text-dim);
    font-size: 0.76rem;
    text-decoration: none;
    transition: color 0.2s;
    padding: 2px 0;
}
.footer-links a:hover { color: var(--green-dim); padding-left: 4px; }
.footer-xhp { text-align: right; color: var(--text-muted); font-size: 0.72rem; }
.footer-bottom { padding-top: 14px; border-top: 1px solid var(--border); text-align: center; color: var(--text-muted); font-size: 0.68rem; }

/* ===== 弹窗（首页文章详情） ===== */
.modal-overlay {
    position: fixed; inset: 0; z-index: 200;
    background: oklch(0 0 0 / 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none; align-items: center; justify-content: center;
    padding: 20px;
}
.modal-overlay.active { display: flex; }
.modal-content {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    max-width: 720px; width: 100%;
    max-height: 90vh; overflow-y: auto;
    position: relative;
    animation: modalIn 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: var(--shadow-lg);
}
@keyframes modalIn {
    from { opacity: 0; transform: translateY(30px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-close {
    position: sticky; top: 14px; float: right;
    margin: 14px 14px 0 0;
    width: 32px; height: 32px; border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-dim);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.25s;
    z-index: 5;
    display: flex; align-items: center; justify-content: center;
}
.modal-close:hover {
    border-color: var(--green);
    color: var(--green-dim);
    background: var(--green-bg);
}
.modal-scroll { padding: 20px 28px 28px; }
.modal-scroll .article-title { font-size: 1.4rem; font-weight: 700; margin-bottom: 10px; line-height: 1.4; }
.modal-scroll .article-meta { color: var(--text-dim); font-size: 0.85rem; margin-bottom: 16px; margin-top: 6px; }
.modal-scroll .article-content {
    line-height: 1.9;
    font-size: 0.95rem;
    white-space: pre-wrap;
    color: var(--text);
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 16px;
}

/* ===== 加载 & 动画 ===== */
.loading { text-align: center; padding: 50px; }
.spinner {
    display: inline-block;
    width: 24px; height: 24px;
    border: 2px solid var(--border);
    border-top-color: var(--green);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 10px;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

/* ===== 响应式 ===== */
/* 平板 */
@media (max-width: 1024px) {
    .container { padding: 0 20px; }
    .news-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
    .hero-versions { gap: 10px; }
    .version-card { padding: 12px 14px; }
}

/* 手机大屏 */
@media (max-width: 768px) {
    .container { padding: 0 14px; }

    .nav-links { order: 4; overflow-x: auto; width: 100%; gap: 4px; padding: 6px 0; }
    .nav-icon-link {
        padding: 8px 20px;
        min-width: 48px;
        min-height: 44px;
        justify-content: center;
    }
    .nav-icon { font-size: 1.4rem; }
    .nav-label { font-size: 0.6rem; }
    .theme-toggle .label { display: none; }
    .theme-toggle {
        padding: 8px 16px;
        min-height: 44px;
    }
    .search-box { order: 3; flex: 0 0 100%; margin-top: 6px; }
    .search-box input {
        font-size: 16px !important;
        padding: 10px 36px 10px 16px;
        min-height: 44px;
    }
    .feature-card {
        padding: 16px;
        min-height: 44px;
    }
    .version-card {
        padding: 12px 14px;
        min-height: 44px;
    }

    .hero-section { min-height: auto; padding: 70px 0 16px; }
    .hero-versions { grid-template-columns: 1fr; gap: 6px; }
    .version-card { padding: 10px 12px; }
    .version-card .ver-icon { font-size: 1.1rem; }

    .features-section { margin: -12px 0 24px; }
    .features-grid { grid-template-columns: 1fr; gap: 8px; }
    .feature-card { padding: 14px; }

    .news-section { padding: 0 0 32px; }
    .news-grid { grid-template-columns: 1fr; gap: 12px; }
    .card-image { height: 140px; }

    .card-title { font-size: var(--text-base); }
    .card-summary { font-size: var(--text-sm); }

    .section-title-news { font-size: 1.15rem; }
    .news-count { font-size: var(--text-sm); }

    .article-page { padding: 75px 14px 20px; }
    .article-page .article-title { font-size: 1.4rem; }

    .modal-scroll { padding: 14px; }
    .modal-scroll .article-title { font-size: 1.2rem; }
    .modal-scroll .article-content { font-size: 0.9rem; }

    .back-to-top { bottom: 16px; right: 16px; width: 44px; height: 44px; font-size: 1.1rem; }

    .footer-grid { grid-template-columns: 1fr; text-align: center; gap: 12px; }
    .footer-xhp { text-align: center; }
}

/* 手机小屏 */
@media (max-width: 480px) {
    .container { padding: 0 12px; }
    .hero-featured-video { flex-direction: column; padding: 16px 20px; min-height: auto; text-align: center; }
    .hero-featured-video > div:last-child { margin-left: 0; margin-top: 12px; }
    .card-image { height: 120px; }
    .version-card .ver-sub { font-size: 0.6rem; }
}
