/**
 * PD社区 · 活力拼豆 2.0 — 高级感设计系统
 * 玻璃拟态 · 渐变网格 · 多层光影 · 弹性动效 · 深色模式
 * 保留全部既有 class/id 语义，仅升级观感与新增组件。
 */

/* ========== 设计 Tokens ========== */
:root {
    /* —— 品牌主色：珊瑚 —— */
    --primary: #f0604f;
    --primary-dark: #b74234;
    --primary-light: #f6b3a7;
    --primary-ultra-light: #ffe9e5;
    --primary-grad: linear-gradient(135deg, #ff836c 0%, #f0604f 55%, #e25344 100%);
    --primary-grad-soft: linear-gradient(135deg, rgba(240,96,79,.12), rgba(240,180,41,.10));

    /* —— 辅助色：青绿（拼豆/手作） —— */
    --accent: #109c8b;
    --accent-dark: #0c7f71;
    --accent-light: #dff4f0;
    --accent-grad: linear-gradient(135deg, #18b7a3, #109c8b);

    /* 拼豆彩色板（标签/头像/装饰） */
    --bead-pink: #ef7c8e;
    --bead-yellow: #f0b429;
    --bead-green: #109c8b;
    --bead-purple: #7a6bf0;
    --bead-cyan: #4aa8b8;
    --bead-orange: #f08a3d;
    --bead-red: #e25344;
    --bead-blue: #4b8fd6;

    /* 语义色 */
    --success: #0c7f71;
    --success-light: #dff4f0;
    --danger: #c2412f;
    --danger-light: #fbe9e5;
    --warning: #8a6410;
    --warning-light: #fef3d7;
    --info: #2f6fb2;
    --info-light: #e8f1fa;

    /* 背景与表面：暖纸底 */
    --bg-body: #faf6ef;
    --bg-card: #ffffff;
    --bg-card-hover: #fbf7f0;
    --bg-nav: rgba(250, 246, 239, 0.82);
    --bg-muted: #f3ece0;
    --bg-glass: rgba(255, 255, 255, 0.78);
    --bg-elevated: #ffffff;

    /* 文字：墨色系 */
    --text-primary: #221e19;
    --text-secondary: #4a4238;
    --text-muted: #756a5c;

    /* 边框 */
    --border-color: #e9e0d1;
    --border-light: #f0e9dd;

    /* 多层光影（暖调） */
    --shadow-sm: 0 1px 2px rgba(45,35,20,.05), 0 8px 22px -16px rgba(45,35,20,.18);
    --shadow-md: 0 2px 6px rgba(45,35,20,.05), 0 18px 40px -24px rgba(45,35,20,.28);
    --shadow-lg: 0 8px 18px rgba(45,35,20,.06), 0 32px 60px -30px rgba(45,35,20,.32);
    --shadow-xl: 0 18px 38px rgba(45,35,20,.08), 0 48px 90px -40px rgba(45,35,20,.40);
    --shadow-primary: 0 10px 24px -10px rgba(224,82,60,.55);
    --shadow-accent: 0 10px 24px -10px rgba(16,156,139,.45);
    --shadow-glow: 0 0 0 4px rgba(240,96,79,.14);

    /* 圆角 */
    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 26px;
    --radius-2xl: 32px;
    --radius-full: 9999px;

    /* 间距 */
    --space-xs: .5rem; --space-sm: .75rem; --space-md: 1rem; --space-lg: 1.5rem; --space-xl: 2.5rem;

    /* 过渡 */
    --transition-fast: 160ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 280ms cubic-bezier(0.22, 1, 0.36, 1);
    --transition-slow: 450ms cubic-bezier(0.22, 1, 0.36, 1);
    --transition-bounce: 380ms cubic-bezier(0.34, 1.56, 0.64, 1);
    --transition-spring: 500ms cubic-bezier(0.22, 1, 0.36, 1);

    /* 玻璃 */
    --glass-blur: blur(18px) saturate(160%);
    --glass-bg: rgba(255, 255, 255, 0.78);
    --glass-border: rgba(233, 224, 209, 0.9);

    /* 字体 */
    --font-sans: 'Manrope', 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
}

/* ========== 深色模式：暖夜墨色 ========== */
[data-theme="dark"] {
    --primary: #ff8d74;
    --primary-dark: #f0604f;
    --primary-light: #ffb4a2;
    --primary-ultra-light: rgba(255, 141, 116, 0.12);
    --primary-grad: linear-gradient(135deg, #ff9a82, #f0604f 60%, #d94b3b);
    --primary-grad-soft: linear-gradient(135deg, rgba(255,141,116,.10), rgba(61,201,182,.08));

    --accent: #3dc9b6;
    --accent-dark: #2aa999;
    --accent-light: rgba(61, 201, 182, 0.14);
    --accent-grad: linear-gradient(135deg, #4dd9c6, #2aa999);

    --bg-body: #15110d;
    --bg-card: #201b15;
    --bg-card-hover: #272117;
    --bg-nav: rgba(21, 17, 13, 0.82);
    --bg-muted: #2b241b;
    --bg-glass: rgba(32, 27, 21, 0.78);
    --bg-elevated: #241e18;

    --text-primary: #f6f0e6;
    --text-secondary: #cfc3b2;
    --text-muted: #9c8e7a;

    --border-color: #3b3328;
    --border-light: #302920;

    --shadow-sm: 0 1px 2px rgba(0,0,0,.32), 0 8px 22px -16px rgba(0,0,0,.5);
    --shadow-md: 0 4px 14px -2px rgba(0,0,0,.42);
    --shadow-lg: 0 14px 32px -10px rgba(0,0,0,.55);
    --shadow-xl: 0 28px 56px -20px rgba(0,0,0,.65);
    --shadow-primary: 0 10px 24px -10px rgba(255, 141, 116, 0.35);
    --shadow-accent: 0 10px 24px -10px rgba(61, 201, 182, 0.32);
    --shadow-glow: 0 0 0 4px rgba(255, 141, 116, 0.16);

    --glass-bg: rgba(32, 27, 21, 0.78);
    --glass-border: rgba(255, 255, 255, 0.08);

    --success: #3dc9b6;
    --success-light: rgba(61, 201, 182, 0.14);
    --danger: #ff9b8b;
    --danger-light: rgba(255, 123, 107, 0.14);
    --warning: #f0b429;
    --warning-light: rgba(240, 180, 41, 0.14);
    --info: #7bb6ea;
    --info-light: rgba(91, 160, 220, 0.14);
}

/* ========== 全局 ========== */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
[x-cloak] { display: none !important; }

body {
    background: var(--bg-body);
    background-image:
        radial-gradient(circle at 12% 8%, rgba(8, 145, 178, 0.10) 0%, transparent 42%),
        radial-gradient(circle at 88% 92%, rgba(234, 88, 12, 0.08) 0%, transparent 42%),
        radial-gradient(circle at 50% 50%, rgba(168, 85, 247, 0.04) 0%, transparent 60%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--transition-base), color var(--transition-base);
}

/* 噪点纹理叠层（高级感细节） */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: .035;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
main, nav, footer, .announcement-bar { position: relative; z-index: 1; }

/* 顶部彩色渐变条 */
.top-bar {
    height: 4px;
    background: linear-gradient(90deg, #0891b2, #06b6d4, #10b981, #eab308, #f59e0b, #ec4899, #0891b2);
    background-size: 200% 100%;
    animation: gradient-flow 10s linear infinite;
}
@keyframes gradient-flow {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

a { color: var(--primary); transition: var(--transition-fast); }
a:hover { color: var(--primary-dark); }
::selection { background: rgba(8, 145, 178, 0.20); color: var(--text-primary); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 9999px; border: 2px solid var(--bg-body); }
::-webkit-scrollbar-thumb:hover { background: var(--primary-light); }

/* ========== 文字渐变 ========== */
.text-gradient, .text-gradient-primary {
    background: var(--primary-grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}
.text-gradient-warm {
    background: var(--accent-grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ========== 导航栏（玻璃拟态） ========== */
.navbar {
    background: var(--bg-nav) !important;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.65rem 0;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
}
.navbar-brand {
    font-weight: 800;
    font-size: 1.5rem;
    background: var(--primary-grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
    display: inline-flex; align-items: center; gap: 0.5rem;
    transition: var(--transition-bounce);
}
.navbar-brand i {
    font-size: 1.3rem;
    -webkit-text-fill-color: var(--primary); color: var(--primary);
}
.navbar-brand:hover { transform: scale(1.04); }

.navbar .nav-link {
    color: var(--text-secondary) !important;
    font-weight: 700; font-size: 0.95rem;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius-full);
    transition: var(--transition-fast);
    position: relative;
}
.navbar .nav-link:hover { color: var(--primary) !important; background: var(--primary-ultra-light); }
.navbar .nav-link.active { color: var(--primary) !important; background: var(--primary-ultra-light); }

.navbar .dropdown-menu {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    background: var(--bg-elevated);
    margin-top: 0.5rem !important;
    animation: drop-in 0.25s var(--transition-spring);
}
@keyframes drop-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
.navbar .dropdown-item {
    border-radius: var(--radius-sm);
    padding: 0.5rem 0.85rem;
    font-weight: 600; color: var(--text-primary);
    transition: var(--transition-fast);
}
.navbar .dropdown-item:hover { background: var(--primary-ultra-light); color: var(--primary-dark); }
.navbar .dropdown-divider { border-color: var(--border-color); }
.navbar-toggler { border: none; padding: 0.4rem 0.6rem; }
.navbar-toggler:focus { box-shadow: none; }

/* 主题切换按钮 */
.theme-toggle-btn {
    width: 38px; height: 38px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: var(--radius-full);
    background: var(--bg-muted);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    cursor: pointer; transition: var(--transition-fast);
    flex-shrink: 0;
}
.theme-toggle-btn:hover { color: var(--primary); background: var(--primary-ultra-light); border-color: var(--primary-light); transform: rotate(15deg); }

/* 通知下拉面板 */
.notif-dropdown {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    background: var(--bg-elevated);
    min-width: 340px;
    padding: 0.5rem;
    animation: drop-in 0.25s var(--transition-spring);
}

/* ========== 按钮 ========== */
.btn {
    border-radius: var(--radius-md);
    font-weight: 700;
    padding: 0.5rem 1.15rem;
    transition: var(--transition-base);
    border: none;
    letter-spacing: 0.01em;
    position: relative; overflow: hidden;
}
.btn-sm { border-radius: var(--radius-sm); padding: 0.3rem 0.8rem; font-size: 0.82rem; }
.btn:focus { box-shadow: var(--shadow-glow); }
.btn::after { /* 微光扫过 */
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.25) 50%, transparent 70%);
    transform: translateX(-120%);
    transition: transform 0.6s ease;
}
.btn:hover::after { transform: translateX(120%); }

.btn-primary {
    background: var(--primary-grad);
    color: #fff;
    box-shadow: var(--shadow-primary);
}
.btn-primary:hover {
    background: linear-gradient(135deg, #0e7490, #0891b2, #059669);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 14px 28px -8px rgba(8, 145, 178, 0.5);
}
.btn-primary:active { transform: translateY(0); }

.btn-outline-secondary {
    background: var(--bg-card);
    color: var(--text-secondary);
    border: 1.5px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}
.btn-outline-secondary:hover {
    background: var(--primary-ultra-light);
    color: var(--primary-dark);
    border-color: var(--primary-light);
    transform: translateY(-2px);
}
.btn-outline-light { border: 1.5px solid rgba(255,255,255,0.5); color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,0.15); color: #fff; }

.btn-approve { background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff; box-shadow: 0 8px 18px -6px rgba(34,197,94,0.45); }
.btn-approve:hover { background: linear-gradient(135deg, #16a34a, #15803d); color:#fff; transform: translateY(-2px); }
.btn-reject { background: linear-gradient(135deg, #f43f5e, #dc2626); color: #fff; box-shadow: 0 8px 18px -6px rgba(244,63,94,0.45); }
.btn-reject:hover { background: linear-gradient(135deg, #dc2626, #b91c1c); color:#fff; transform: translateY(-2px); }

.btn-group { border-radius: var(--radius-full); }
.btn-group .btn { border-radius: 0; }
.btn-group .btn::after { display: none; }
.btn-group .btn:first-child { border-top-left-radius: var(--radius-full); border-bottom-left-radius: var(--radius-full); }
.btn-group .btn:last-child { border-top-right-radius: var(--radius-full); border-bottom-right-radius: var(--radius-full); }

.bookmark-btn.active {
    background: var(--accent-light) !important;
    color: var(--accent) !important;
    border-color: var(--accent) !important;
}

/* 关注按钮 */
.follow-btn.following { background: var(--bg-muted); color: var(--text-secondary); border: 1.5px solid var(--border-color); }
.follow-btn:not(.following) { background: var(--primary-grad); color: #fff; box-shadow: var(--shadow-primary); }
.follow-btn:hover { transform: translateY(-2px); }

/* 点赞动画 */
.like-animate { animation: heart-pop 450ms cubic-bezier(0.34, 1.56, 0.64, 1); }
@keyframes heart-pop {
    0% { transform: scale(1); }
    40% { transform: scale(1.28); }
    70% { transform: scale(0.92); }
    100% { transform: scale(1); }
}

/* ========== 表单 ========== */
.form-control, .form-select {
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border-color);
    padding: 0.6rem 1rem;
    font-weight: 600; color: var(--text-primary);
    background: var(--bg-card);
    transition: var(--transition-fast);
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: var(--shadow-glow);
}
.form-control::placeholder { color: var(--text-muted); font-weight: 500; }
.form-label { font-weight: 700; color: var(--text-primary); margin-bottom: 0.4rem; }
.form-text { color: var(--text-muted); font-weight: 500; }
.input-group-text {
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border-color);
    background: var(--bg-muted); color: var(--text-secondary);
    font-weight: 700;
}
.input-group .form-control { border-radius: var(--radius-md); }
.input-group:not(.has-validation) > .form-control:not(:last-child) { border-top-right-radius: var(--radius-md); border-bottom-right-radius: var(--radius-md); }

/* ========== 卡片基础 ========== */
.card {
    background: var(--bg-card);
    border: none;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: var(--transition-base);
    color: var(--text-primary);
}

/* ========== 公告栏 ========== */
.announcement-bar {
    background: linear-gradient(135deg, var(--warning-light), rgba(255,251,235,.6));
    border-bottom: 1px solid rgba(245, 158, 11, 0.2);
    padding: 0.5rem 0;
    overflow: hidden;
}
.ann-item {
    display: inline-flex; align-items: center;
    font-weight: 700; font-size: 0.88rem;
    color: var(--text-primary); white-space: nowrap;
}
.ann-badge {
    display: inline-block;
    background: var(--accent-grad);
    color: #fff; font-size: 0.68rem; font-weight: 800;
    padding: 0.15rem 0.55rem;
    border-radius: var(--radius-full);
    margin-right: 0.5rem; letter-spacing: 0.05em;
}

/* ========== Hero 区 ========== */
.hero {
    position: relative;
    border-radius: var(--radius-2xl);
    padding: 2.5rem 2rem;
    margin-bottom: 1.5rem;
    background: var(--primary-grad);
    overflow: hidden;
    box-shadow: var(--shadow-primary);
    color: #fff;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(255,255,255,0.22), transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255,255,255,0.12), transparent 55%);
    pointer-events: none;
}
/* 拼豆点阵装饰 */
.hero::after {
    content: ''; position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.18) 1.5px, transparent 1.5px);
    background-size: 22px 22px;
    opacity: .5; pointer-events: none;
    mask-image: linear-gradient(90deg, transparent, #000 40%);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 40%);
}
.hero > * { position: relative; z-index: 1; }
.hero h1 { font-weight: 800; font-size: clamp(1.8rem, 4vw, 2.6rem); letter-spacing: -0.02em; }
.hero p { font-weight: 600; opacity: .92; margin-bottom: 1.25rem; }
.hero .hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.hero .btn-primary { background: rgba(255,255,255,0.95); color: var(--primary-dark); box-shadow: var(--shadow-lg); }
.hero .btn-outline-light { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.4); }

/* ========== 页面标题区 ========== */
.page-header {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-light);
}
.page-header h2, .page-header h3, .page-header h4 { font-weight: 800; letter-spacing: -0.02em; }
.page-header p { color: var(--text-secondary); font-weight: 600; }

/* ========== 搜索框 ========== */
.search-box { position: relative; display: flex; align-items: center; }
.search-icon { position: absolute; left: 0.9rem; color: var(--text-muted); font-size: 0.85rem; pointer-events: none; z-index: 2; }
.search-box .form-control { padding-left: 2.3rem; border-radius: var(--radius-full); min-width: 200px; }

/* ========== 标签筛选 ========== */
.tag-filter {
    display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem;
    background: var(--bg-card);
    padding: 1rem 1.25rem;
    border-radius: var(--radius-lg);
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
}
.filter-label { font-weight: 800; color: var(--text-secondary); font-size: 0.88rem; margin-right: 0.25rem; }

/* ========== 彩色标签徽章 ========== */
.badge-grid {
    display: inline-flex; align-items: center; gap: 0.3rem;
    padding: 0.25rem 0.7rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem; font-weight: 800;
    background: var(--primary-ultra-light);
    color: var(--primary-dark);
    border: 1px solid transparent;
    transition: var(--transition-fast);
    line-height: 1.4;
}
.badge-grid:nth-child(6n+1) { background: #fce7f3; color: #be185d; }
.badge-grid:nth-child(6n+2) { background: #fef3c7; color: #b45309; }
.badge-grid:nth-child(6n+3) { background: #d1fae5; color: #047857; }
.badge-grid:nth-child(6n+4) { background: #ede9fe; color: #6d28d9; }
.badge-grid:nth-child(6n+5) { background: #cffafe; color: #0e7490; }
.badge-grid:nth-child(6n+6) { background: #ffedd5; color: #c2410c; }
[data-theme="dark"] .badge-grid { background: rgba(255,255,255,0.06) !important; color: var(--text-primary) !important; border-color: var(--border-color); }
[data-theme="dark"] .badge-grid:nth-child(6n+1) { color: #f9a8d4 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+2) { color: #fcd34d !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+3) { color: #6ee7b7 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+4) { color: #c4b5fd !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+5) { color: #67e8f9 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+6) { color: #fdba74 !important; }
a:hover .badge-grid { transform: translateY(-2px) scale(1.05); }
.badge-light { background: rgba(255,255,255,0.85) !important; color: var(--primary) !important; }

/* ========== 画廊网格 ========== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* ========== 作品卡片 ========== */
.gallery-grid .card, .card.hover-lift {
    overflow: hidden;
    border: 1px solid var(--border-light);
    position: relative;
}
.card.hover-lift::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0;
    height: 4px;
    background: var(--primary-grad);
    opacity: 0;
    transition: var(--transition-base);
    z-index: 2;
}
.card.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-light);
}
.card.hover-lift:hover::before { opacity: 1; }

.card-image-wrapper {
    overflow: hidden;
    background: var(--bg-muted);
    position: relative;
}
.card-image-wrapper img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}
.card.hover-lift:hover .card-image-wrapper img { transform: scale(1.1); }

.card-placeholder {
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-grad);
    color: rgba(255,255,255,0.6);
    font-size: 3rem;
}

.card-body { padding: 1.1rem 1.2rem; }
.card-title { font-weight: 800; color: var(--text-primary); font-size: 0.98rem; margin-bottom: 0.4rem; letter-spacing: -0.01em; }
.card-meta { font-size: 0.8rem; color: var(--text-secondary); font-weight: 600; }
.card-meta a { color: var(--text-secondary); }
.card-meta a:hover { color: var(--primary); }
.card-actions { display: flex; gap: 0.5rem; margin-top: 0.75rem; }
.media-bg { background: linear-gradient(135deg, var(--primary-ultra-light), var(--bg-muted)); }

/* ========== 热门侧栏 ========== */
.trending-rail {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-light);
}
.trending-rail h6 { font-weight: 800; }
.trending-item { display: flex; gap: .75rem; align-items: center; padding: .6rem 0; border-bottom: 1px dashed var(--border-color); transition: var(--transition-fast); }
.trending-item:last-child { border-bottom: none; }
.trending-item:hover { transform: translateX(4px); }
.trending-rank {
    width: 28px; height: 28px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-sm); font-weight: 800; font-size: .8rem;
    background: var(--bg-muted); color: var(--text-secondary);
}
.trending-rank.top1 { background: var(--accent-grad); color:#fff; }
.trending-rank.top2 { background: linear-gradient(135deg,#94a3b8,#64748b); color:#fff; }
.trending-rank.top3 { background: linear-gradient(135deg,#f59e0b,#d97706); color:#fff; }
.trending-thumb { width: 52px; height: 52px; border-radius: var(--radius-sm); object-fit: cover; background: var(--bg-muted); flex-shrink: 0; }
.trending-thumb-ph { width: 52px; height: 52px; border-radius: var(--radius-sm); background: var(--primary-grad); flex-shrink: 0; display:flex; align-items:center; justify-content:center; color: rgba(255,255,255,.7); }
.trending-info { min-width: 0; }
.trending-title { font-weight: 700; font-size: .9rem; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trending-meta { font-size: .75rem; color: var(--text-muted); font-weight: 600; }

/* ========== 加载更多 ========== */
.load-more-wrap { text-align: center; margin: 2rem 0; }
.btn-load-more {
    background: var(--bg-card); color: var(--text-secondary);
    border: 1.5px dashed var(--border-color);
    border-radius: var(--radius-full);
    padding: .65rem 2rem; font-weight: 700; cursor: pointer;
    transition: var(--transition-base);
}
.btn-load-more:hover:not(:disabled) { color: var(--primary); border-color: var(--primary-light); background: var(--primary-ultra-light); transform: translateY(-2px); }
.load-more-end { color: var(--text-muted); font-weight: 600; font-size: .9rem; }

/* ========== 空状态 ========== */
.empty-state {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--text-muted);
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
}
.empty-state > i {
    font-size: 4rem;
    background: var(--primary-grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.7;
}
.empty-state h5 { font-weight: 800; color: var(--text-secondary); }

/* ========== 提示框 ========== */
.alert {
    border: none;
    border-radius: var(--radius-md);
    padding: 0.9rem 1.2rem;
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}
.alert-success { background: var(--success-light); color: var(--success); }
.alert-info { background: var(--info-light); color: var(--info); }
.alert-warning { background: var(--warning-light); color: var(--warning); }
.alert-danger { background: var(--danger-light); color: var(--danger); }
.alert-dismissible .btn-close { filter: invert(0.5); }

/* ========== 分页 ========== */
.pagination { gap: 0.35rem; }
.page-item .page-link {
    border: none; border-radius: var(--radius-sm);
    min-width: 38px; text-align: center; font-weight: 700;
    color: var(--text-secondary);
    background: var(--bg-card);
    box-shadow: var(--shadow-sm);
    transition: var(--transition-fast);
}
.page-item .page-link:hover { background: var(--primary-ultra-light); color: var(--primary); transform: translateY(-2px); }
.page-item.active .page-link { background: var(--primary-grad); color: #fff; box-shadow: var(--shadow-primary); }
.page-item.disabled .page-link { opacity: 0.45; background: var(--bg-muted); }

/* ========== 头像 ========== */
.avatar, .avatar-circle {
    width: 64px; height: 64px;
    border-radius: var(--radius-full);
    background: var(--primary-grad);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.8rem; font-weight: 800;
    box-shadow: var(--shadow-primary);
    text-transform: uppercase;
}
.avatar-circle { width: 48px; height: 48px; font-size: 1.4rem; }

/* ========== 统计 ========== */
.stats-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem;
    text-align: center;
}
.stat-item { padding: 0.5rem 0.25rem; }
.stat-value {
    font-size: 1.5rem; font-weight: 800;
    background: var(--primary-grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
}
.stat-label { font-size: 0.72rem; color: var(--text-muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-top: 0.15rem; }
.stat-card {
    background: var(--bg-card); border-radius: var(--radius-lg);
    padding: 1.25rem; box-shadow: var(--shadow-md);
    transition: var(--transition-base);
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

/* ========== 状态标签 ========== */
.status-badge {
    display: inline-flex; align-items: center; gap: 0.3rem;
    padding: 0.25rem 0.75rem; border-radius: var(--radius-full);
    font-size: 0.75rem; font-weight: 800;
}
.status-badge.pending { background: var(--warning-light); color: var(--warning); }
.status-badge.approved { background: var(--success-light); color: var(--success); }
.status-badge.rejected { background: var(--danger-light); color: var(--danger); }
.announcement-status-badge { font-weight: 800; }
.announcement-status-badge.published { color: var(--success); }
.announcement-status-badge.draft { color: var(--text-muted); }

/* ========== 等级徽章 ========== */
.level-badge {
    display: inline-flex; align-items: center; gap: .35rem;
    padding: .2rem .7rem; border-radius: var(--radius-full);
    font-size: .72rem; font-weight: 800;
    color: #fff;
    background: var(--accent-grad);
    box-shadow: 0 4px 12px -4px rgba(0,0,0,.25);
}
.level-badge .lv-num { background: rgba(255,255,255,.25); border-radius: var(--radius-full); padding: 0 .35rem; font-size: .62rem; }
.level-progress { height: 8px; border-radius: var(--radius-full); background: var(--bg-muted); overflow: hidden; }
.level-progress > span { display: block; height: 100%; background: var(--primary-grad); border-radius: var(--radius-full); transition: width 1s var(--transition-spring); }
.level-card {
    background: var(--bg-card); border-radius: var(--radius-lg);
    padding: 1.25rem; box-shadow: var(--shadow-md); border: 1px solid var(--border-light);
}
.level-card .level-badge { font-size: .9rem; padding: .35rem 1rem; }

/* ========== 作品详情页 ========== */
.post-header { margin-bottom: 1rem; }
.post-title { font-weight: 800; letter-spacing: -0.02em; color: var(--text-primary); }
.post-meta {
    display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem;
    font-size: 0.85rem; color: var(--text-secondary); font-weight: 600; margin-top: 0.5rem;
}
.post-meta a { color: var(--text-secondary); }
.post-meta a:hover { color: var(--primary); }
.post-meta-divider { color: var(--text-muted); opacity: 0.6; }

/* 粘性操作栏 */
.sticky-action-bar {
    position: sticky; top: 70px; z-index: 20;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: .6rem .8rem;
    box-shadow: var(--shadow-md);
    display: flex; gap: .5rem; align-items: center; flex-wrap: wrap;
}

/* ========== 用户卡片 ========== */
.user-card { text-align: center; background: var(--bg-card); }
.user-card .avatar { margin: 0 auto 0.75rem; }
.username { font-weight: 800; color: var(--text-primary); margin-bottom: 0.15rem; }
.user-card .role, .role {
    display: inline-block; font-size: 0.72rem; font-weight: 700;
    color: var(--text-muted); background: var(--bg-muted);
    padding: 0.15rem 0.6rem; border-radius: var(--radius-full);
}

/* ========== 信息卡片 ========== */
.info-card {
    background: var(--bg-card); border-radius: var(--radius-lg);
    padding: 1.5rem; box-shadow: var(--shadow-md); border: 1px solid var(--border-light);
}
.info-row { display: flex; justify-content: space-between; align-items: center; padding: 0.55rem 0; border-bottom: 1px dashed var(--border-color); }
.info-row:last-child { border-bottom: none; }
.info-label { color: var(--text-muted); font-weight: 600; font-size: 0.85rem; }
.info-value { color: var(--text-primary); font-weight: 700; font-size: 0.85rem; }

/* ========== 评论区 ========== */
.comment-card {
    background: var(--bg-muted);
    border-radius: var(--radius-md);
    padding: 0.85rem 1.1rem;
    margin-bottom: 0.6rem;
    transition: var(--transition-fast);
}
.comment-card:hover { background: var(--primary-ultra-light); }
.comment-meta { font-size: 0.8rem; color: var(--text-muted); font-weight: 600; margin-bottom: 0.3rem; }
.comment-body { color: var(--text-primary); font-weight: 500; line-height: 1.6; word-break: break-word; }
.comment-delete-btn { color: var(--text-muted); cursor: pointer; transition: var(--transition-fast); }
.comment-delete-btn:hover { color: var(--danger); }

/* ========== 分享页 / 登录注册 ========== */
.share-card, .auth-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-light);
    position: relative; overflow: hidden;
}
.share-card::before, .auth-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0;
    height: 6px; background: var(--primary-grad);
}
.share-header, .auth-card .text-center { text-align: center; margin-bottom: 1.75rem; }
.share-icon, .auth-icon {
    width: 72px; height: 72px; margin: 0 auto 1rem;
    border-radius: var(--radius-full);
    background: var(--primary-grad);
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem; box-shadow: var(--shadow-primary);
}
.share-title, .auth-title { font-weight: 800; color: var(--text-primary); letter-spacing: -0.02em; }
.share-subtitle, .auth-subtitle { color: var(--text-secondary); font-weight: 600; }
.auth-card { max-width: 460px; margin: 1rem auto; }
.auth-split-brand {
    background: var(--primary-grad); color: #fff;
    border-radius: var(--radius-xl); padding: 2rem;
    display: flex; flex-direction: column; justify-content: center;
    position: relative; overflow: hidden;
}
.auth-split-brand::after {
    content: ''; position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.2) 1.5px, transparent 1.5px);
    background-size: 22px 22px; opacity: .5; pointer-events: none;
}

/* ========== 导入预览 ========== */
.import-preview {
    background: var(--primary-ultra-light);
    border-radius: var(--radius-md);
    padding: 1rem; border: 1px dashed var(--primary-light);
}
.import-preview-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.import-preview-title { font-weight: 800; color: var(--primary-dark); }
.grid-data {
    background: #0f172a; color: #67e8f9;
    border-radius: var(--radius-sm);
    padding: 0.75rem; overflow: auto;
    font-size: 0.78rem; line-height: 1.5; max-height: 200px;
}

/* ========== 个人主页 ========== */
.profile-header {
    background: var(--primary-grad); color: #fff;
    border-radius: var(--radius-lg); padding: 2rem;
    box-shadow: var(--shadow-primary);
    text-align: center; position: relative; overflow: hidden;
}
.profile-header::after {
    content: ''; position: absolute; inset: 0;
    background:
        radial-gradient(circle at 30% 20%, rgba(255,255,255,0.18), transparent 60%),
        radial-gradient(rgba(255,255,255,0.12) 1.5px, transparent 1.5px);
    background-size: auto, 22px 22px;
    pointer-events: none;
}
.profile-header > * { position: relative; z-index: 1; }
.profile-avatar {
    width: 96px; height: 96px; border-radius: var(--radius-full);
    background: rgba(255,255,255,0.25);
    border: 4px solid rgba(255,255,255,0.5);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 2.5rem; font-weight: 800; margin-bottom: 0.75rem;
    overflow: hidden;
}
.profile-name { font-weight: 800; font-size: 1.5rem; margin-bottom: 0.25rem; }
.profile-bio { opacity: 0.9; font-weight: 600; max-width: 480px; margin: 0.5rem auto 0; }
.profile-joined { opacity: 0.85; font-size: 0.85rem; font-weight: 600; margin-top: 0.5rem; }

/* ========== 拼豆网格查看器 ========== */
.grid-viewer { background: var(--bg-card); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); border: 1px solid var(--border-light); overflow: hidden; }
.gv-toolbar {
    display: flex; align-items: center; gap: .5rem; flex-wrap: wrap;
    padding: .75rem 1rem; background: var(--bg-muted);
    border-bottom: 1px solid var(--border-light);
}
.gv-toolbar .gv-title { font-weight: 800; color: var(--text-primary); margin-right: auto; }
.gv-seg { display: inline-flex; background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-full); padding: 2px; }
.gv-seg button {
    border: none; background: transparent; color: var(--text-secondary);
    font-weight: 700; font-size: .8rem; padding: .3rem .8rem;
    border-radius: var(--radius-full); cursor: pointer; transition: var(--transition-fast);
}
.gv-seg button.active { background: var(--primary-grad); color: #fff; box-shadow: var(--shadow-primary); }
.gv-icon-btn {
    width: 34px; height: 34px; border-radius: var(--radius-sm);
    border: 1px solid var(--border-color); background: var(--bg-card);
    color: var(--text-secondary); cursor: pointer; transition: var(--transition-fast);
    display: inline-flex; align-items: center; justify-content: center;
}
.gv-icon-btn:hover { color: var(--primary); border-color: var(--primary-light); background: var(--primary-ultra-light); }
.gv-stage {
    background:
        linear-gradient(45deg, var(--bg-muted) 25%, transparent 25%),
        linear-gradient(-45deg, var(--bg-muted) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, var(--bg-muted) 75%),
        linear-gradient(-45deg, transparent 75%, var(--bg-muted) 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0;
    background-color: var(--bg-card);
    overflow: auto; padding: 1.5rem;
    max-height: 560px;
    display: flex; justify-content: center; align-items: flex-start;
}
.bead-grid-scroll { overflow: auto; max-width: 100%; }
.bead-grid { display: grid; gap: 2px; }
.bead-cell {
    width: var(--cell-size, 36px); height: var(--cell-size, 36px);
    display: flex; align-items: center; justify-content: center;
    border-radius: 4px; cursor: pointer;
    background: var(--cell-color, var(--bg-muted));
    color: rgba(255,255,255,.95);
    font-size: calc(var(--cell-size, 36px) * 0.42);
    font-weight: 800;
    text-shadow: 0 1px 2px rgba(0,0,0,.35);
    transition: transform .15s ease, box-shadow .15s ease;
    user-select: none;
}
.bead-cell:hover { transform: scale(1.15); z-index: 2; box-shadow: var(--shadow-md); }
.bead-cell.is-hl { outline: 3px solid var(--accent); outline-offset: 1px; z-index: 3; }
.bead-cell.dim { opacity: .2; }
/* 字符模式：浅色底 + 深字 */
.gv-char .bead-cell { background: #fff; color: var(--text-primary); text-shadow: none; box-shadow: inset 0 0 0 1px var(--border-color); }
.gv-char .bead-cell::before { content: ''; position: absolute; }
[data-theme="dark"] .gv-char .bead-cell { background: var(--bg-muted); }
.gv-char .bead-cell.is-hl { background: var(--primary-ultra-light); }
/* 色块模式：不显示字 */
.gv-color .bead-cell span { display: none; }
/* 空白格：透出舞台的透明棋盘，不画成一颗豆 */
.bead-cell.is-empty {
    background: transparent !important;
    box-shadow: inset 0 0 0 1px var(--border-light);
    cursor: default;
}
.bead-cell.is-empty span { display: none; }
.bead-cell.is-empty:hover { transform: none; box-shadow: inset 0 0 0 1px var(--border-color); }

/* 混合模式：默认即色块+字（默认样式已含） */

.gv-stats {
    border-top: 1px solid var(--border-light);
    padding: 1rem; background: var(--bg-card);
}
.gv-stats-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .6rem; }
.gv-stats-head .gv-stats-title { font-weight: 800; color: var(--text-primary); }
.gv-stats-head .gv-stats-meta { font-size: .78rem; color: var(--text-muted); font-weight: 600; }
.gv-bead-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: .4rem; max-height: 240px; overflow: auto; }
.gv-bead-item {
    display: flex; align-items: center; gap: .5rem;
    padding: .35rem .55rem; border-radius: var(--radius-sm);
    background: var(--bg-muted); cursor: pointer;
    transition: var(--transition-fast); font-size: .8rem; font-weight: 600;
}
.gv-bead-item:hover { background: var(--primary-ultra-light); }
.gv-bead-item.active { background: var(--accent-light); color: var(--accent-dark); }
.gv-bead-swatch { width: 16px; height: 16px; border-radius: 4px; flex-shrink: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); }
.gv-bead-char { font-weight: 800; min-width: 1.2em; text-align: center; }
.gv-bead-count { margin-left: auto; color: var(--text-muted); }
.gv-empty { padding: 3rem 1rem; text-align: center; color: var(--text-muted); }

/* ========== 相关推荐 ========== */
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }

/* ========== Modal ========== */
.modal-content { border: none; border-radius: var(--radius-lg); box-shadow: var(--shadow-xl); overflow: hidden; background: var(--bg-elevated); color: var(--text-primary); }
.modal-header { background: var(--bg-muted); border-bottom: 1px solid var(--border-color); padding: 1.1rem 1.5rem; }
.modal-title { font-weight: 800; }
.modal-body { padding: 1.5rem; }
.modal-footer { border-top: 1px solid var(--border-color); padding: 1rem 1.5rem; }
.modal-backdrop.show { opacity: .55; }

/* 分享弹窗 */
.share-modal-row { display: flex; gap: .5rem; align-items: center; }
.share-modal-row input { flex: 1; }
.share-quick { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: 1rem; }
.share-quick a {
    width: 44px; height: 44px; border-radius: var(--radius-md);
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 1.1rem; transition: var(--transition-base);
}

/* ========== Toast ========== */
.pd-toast-wrap { position: fixed; top: 20px; right: 20px; z-index: 9999; display: flex; flex-direction: column; gap: .5rem; }
.pd-toast {
    background: var(--bg-elevated); color: var(--text-primary);
    padding: .75rem 1.1rem; border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg); border: 1px solid var(--border-color);
    font-weight: 600; font-size: .9rem;
    transform: translateX(120%); opacity: 0;
    transition: transform .3s var(--transition-spring), opacity .3s;
    border-left: 4px solid var(--primary);
}
.pd-toast.show { transform: translateX(0); opacity: 1; }
.pd-toast-success { border-left-color: var(--success); }
.pd-toast-danger { border-left-color: var(--danger); }

/* ========== 管理面板 ========== */
.admin-page-header {
    background: var(--bg-card); border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem; box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem; border: 1px solid var(--border-light);
}
.admin-sidebar .nav-link {
    border-radius: var(--radius-md); color: var(--text-secondary);
    font-weight: 700; padding: 0.6rem 1rem; margin-bottom: 0.25rem;
    transition: var(--transition-fast);
}
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active { background: var(--primary-ultra-light); color: var(--primary-dark); }

/* ========== 表格 ========== */
.table { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); color: var(--text-primary); }
.table thead th {
    background: var(--bg-muted); color: var(--text-secondary);
    font-weight: 800; text-transform: uppercase; font-size: 0.78rem;
    letter-spacing: 0.05em; border: none; padding: 0.85rem 1rem;
}
.table tbody td { padding: 0.85rem 1rem; border-color: var(--border-light); vertical-align: middle; font-weight: 600; }
.table tbody tr { transition: var(--transition-fast); background: var(--bg-card); }
.table tbody tr:hover { background: var(--primary-ultra-light); }
.table-dark thead th { background: var(--primary-dark); color: #fff; }
.admin-table, .log-table { background: var(--bg-card); border-radius: var(--radius-lg); overflow: hidden; }
.tag-cell { font-weight: 800; }
.action-btn { padding: 0.25rem 0.6rem; border-radius: var(--radius-sm); font-size: 0.78rem; font-weight: 700; }

/* ========== 审核卡片 ========== */
.review-card {
    background: var(--bg-card); border-radius: var(--radius-lg);
    padding: 1.25rem; box-shadow: var(--shadow-md);
    border: 1px solid var(--border-light); transition: var(--transition-base); margin-bottom: 1rem;
}
.review-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.review-title { font-weight: 800; color: var(--text-primary); margin-bottom: 0.25rem; }
.review-desc { color: var(--text-secondary); font-weight: 500; font-size: 0.88rem; }
.review-meta { display: flex; flex-wrap: wrap; gap: 1rem; font-size: 0.8rem; color: var(--text-muted); font-weight: 600; margin: 0.5rem 0; }
.review-meta-item { display: inline-flex; align-items: center; gap: 0.3rem; }
.review-actions { display: flex; gap: 0.5rem; margin-top: 0.75rem; }
.review-thumbnail, .review-thumb-placeholder { border-radius: var(--radius-md); overflow: hidden; background: var(--bg-muted); margin-bottom: 0.75rem; }
.review-thumb-placeholder { height: 140px; display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 2rem; background: var(--primary-grad); color: rgba(255,255,255,0.6); }
.review-reject-reason, .review-reviewed-at { font-size: 0.82rem; font-weight: 600; color: var(--text-secondary); margin-top: 0.4rem; }

/* ========== 通知项 ========== */
.notification-list { }
.notification-item { border-left: 3px solid transparent; transition: all var(--transition-fast); background: var(--bg-card); }
.notification-item.unread { border-left-color: var(--primary); background: var(--primary-ultra-light); }
.notification-item:hover { box-shadow: var(--shadow-sm); }
.notif-icon { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; background: var(--bg-muted); border-radius: 50%; flex-shrink: 0; font-size: 1rem; }
.notification-item.unread .notif-icon { background: var(--primary-ultra-light); }
.unread-dot { display: inline-block; width: 8px; height: 8px; background: var(--primary); border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.mark-read-btn { color: var(--primary); background: var(--primary-ultra-light); border: 1px solid var(--primary-light); }
.mark-read-btn:hover { background: var(--primary); color: #fff; }

/* ========== 动画 ========== */
.fade-in { animation: fade-in-up 0.5s cubic-bezier(0.4, 0, 0.2, 1) both; }
@keyframes fade-in-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

.skeleton {
    background: linear-gradient(90deg, var(--bg-muted) 25%, var(--border-light) 50%, var(--bg-muted) 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.4s ease infinite;
    border-radius: var(--radius-sm);
}
@keyframes skeleton-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.spinner-border { color: var(--primary); }

/* 管理仪表盘统计卡（flex 布局，兼容原内联） */
.stat-card.pending-alert { border: 2px solid rgba(245,158,11,0.3); animation: pulse-border 2s infinite; }
@keyframes pulse-border { 0%,100% { border-color: rgba(245,158,11,0.3); } 50% { border-color: rgba(245,158,11,0.6); } }
.stat-icon { width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-md); font-size: 1.25rem; flex-shrink: 0; }
.stat-content { flex: 1; min-width: 0; }
.stat-trend { font-size: 0.75rem; margin-top: 2px; }
.chart-wrap { position: relative; height: 220px; }

/* ========== 工具类补丁 ========== */
.bg-card { background: var(--bg-card) !important; }
.bg-light { background: var(--bg-muted) !important; }
.opacity-50 { opacity: 0.55; }
.shadow-sm { box-shadow: var(--shadow-sm) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.border-color { border-color: var(--border-color) !important; }
.text-danger { color: var(--danger) !important; }
footer a:hover { color: var(--primary) !important; }

/* ========== 响应式 ========== */
@media (max-width: 768px) {
    .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }
    .share-card, .auth-card { padding: 1.75rem 1.25rem; }
    .page-header { padding: 1.1rem; }
    .navbar-brand { font-size: 1.25rem; }
    .stat-value { font-size: 1.25rem; }
    .hero { padding: 1.75rem 1.25rem; }
    .sticky-action-bar { top: 64px; }
    .gv-stats-head { flex-direction: column; align-items: flex-start; gap: .25rem; }
}
@media (max-width: 480px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
    .stats-grid { gap: 0.25rem; }
    .related-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ========== 减少动效偏好 ========== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
    html { scroll-behavior: auto; }
}

/* ==========================================================================
   PD社区 · 手作工坊 3.0 — 与拼豆工作室编辑器统一的视觉层
   暖纸底 · 墨色文字 · 珊瑚主色 · 青绿辅色 · 深色墨板
   ========================================================================== */

:root { color-scheme: light; }
[data-theme="dark"] { color-scheme: dark; }

/* ---------- 全局底纹 ---------- */
body {
    font-family: var(--font-sans);
    overflow-x: hidden;
    background-color: var(--bg-body);
    background-image:
        radial-gradient(1100px 620px at 94% -6%, rgba(240, 96, 79, 0.09), transparent 62%),
        radial-gradient(900px 560px at -10% 2%, rgba(16, 156, 139, 0.08), transparent 58%),
        radial-gradient(820px 520px at 52% 112%, rgba(240, 180, 41, 0.07), transparent 62%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.7;
}

body::before {
    background-image: radial-gradient(rgba(45, 35, 20, 0.07) 1px, transparent 1.2px);
    background-size: 24px 24px;
    opacity: 0.5;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 86%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 86%);
}

[data-theme="dark"] body {
    background-image:
        radial-gradient(900px 560px at 94% -6%, rgba(255, 141, 116, 0.08), transparent 62%),
        radial-gradient(820px 520px at -8% 4%, rgba(61, 201, 182, 0.06), transparent 58%),
        radial-gradient(700px 500px at 52% 112%, rgba(240, 180, 41, 0.05), transparent 62%);
}

[data-theme="dark"] body::before {
    background-image: radial-gradient(rgba(255, 244, 226, 0.08) 1px, transparent 1.2px);
}

::selection { background: rgba(240, 96, 79, 0.22); color: var(--text-primary); }
a { color: var(--primary); }
a:hover { color: var(--primary-dark); }
h1, h2, h3, h4, h5, h6 { letter-spacing: -0.025em; }

::-webkit-scrollbar-thumb { border: 3px solid var(--bg-body); background: var(--border-color); background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); background-clip: content-box; }

.skip-link {
    position: fixed;
    top: -60px;
    left: 16px;
    z-index: 2000;
    padding: 10px 16px;
    border-radius: 0 0 12px 12px;
    background: var(--ink, #221e19);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    transition: top 0.2s;
}
.skip-link:focus { top: 0; color: #fff; }

/* ---------- 顶部渐变条 ---------- */
.top-bar {
    height: 3px;
    background: linear-gradient(90deg, #f0604f, #f0b429 36%, #109c8b 68%, #7a6bf0 100%);
    background-size: 200% 100%;
    animation: gradient-flow 14s linear infinite;
}

/* ---------- 导航 ---------- */
.navbar {
    padding: 0.65rem 0;
    background: var(--bg-nav) !important;
    border-bottom: 1px solid var(--border-color);
    box-shadow: none;
}

.navbar .container { max-width: 1320px; }

.navbar-brand {
    gap: 11px;
    padding: 0;
    font-size: 1rem;
    background: none !important;
    -webkit-text-fill-color: currentColor;
    color: var(--text-primary) !important;
    letter-spacing: 0;
}
.navbar-brand:hover { transform: none; }
.navbar-brand i { display: none; }

.brand-mark {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    border-radius: 13px;
    background: linear-gradient(145deg, #302a23, #17130f);
    box-shadow: 0 10px 20px -10px rgba(34, 30, 25, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.14);
    transition: transform 0.35s var(--transition-spring);
}
.navbar-brand:hover .brand-mark { transform: rotate(-6deg) scale(1.04); }

.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 16px; font-weight: 800; letter-spacing: -0.01em; color: var(--text-primary); }
.brand-text span {
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.navbar .nav-link {
    color: var(--text-secondary) !important;
    font-size: 13px;
    font-weight: 700;
    padding: 0.48rem 0.9rem !important;
    border-radius: 999px;
    transition: color 0.2s, background 0.2s;
}
.navbar .nav-link:hover { color: var(--text-primary) !important; background: rgba(45, 35, 20, 0.05); }
.navbar .nav-link.active {
    color: var(--primary-dark) !important;
    background: var(--primary-ultra-light);
    box-shadow: inset 0 0 0 1px rgba(240, 96, 79, 0.12);
}
.navbar .nav-link.nav-link-tool {
    margin-left: 2px;
    color: var(--accent-dark) !important;
}
.navbar .nav-link.nav-link-tool:hover { background: var(--accent-light); }

.navbar-toggler {
    border: 1px solid var(--border-color) !important;
    border-radius: 11px;
    padding: 0.35rem 0.55rem;
    background: var(--bg-card);
}
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath stroke='%23756a5c' stroke-width='2.4' stroke-linecap='round' d='M5 9h20M5 15h20M5 21h20'/%3E%3C/svg%3E");
}
[data-theme="dark"] .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath stroke='%23cfc3b2' stroke-width='2.4' stroke-linecap='round' d='M5 9h20M5 15h20M5 21h20'/%3E%3C/svg%3E");
}

.theme-toggle-btn {
    width: 36px;
    height: 36px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}
.theme-toggle-btn:hover {
    color: var(--primary);
    background: var(--primary-ultra-light);
    border-color: rgba(240, 96, 79, 0.25);
    transform: rotate(12deg);
}

.navbar .dropdown-menu,
.notif-dropdown {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--bg-elevated);
    box-shadow: var(--shadow-lg);
    padding: 0.45rem;
}
.navbar .dropdown-item { border-radius: 10px; font-weight: 600; font-size: 0.88rem; }
.navbar .dropdown-item:hover { background: var(--primary-ultra-light); color: var(--primary-dark); }
.navbar .dropdown-divider { border-color: var(--border-color); }
.notif-dropdown { min-width: 340px; }

/* ---------- 按钮 ---------- */
.btn {
    border-radius: 14px;
    padding: 0.55rem 1.15rem;
    font-weight: 700;
    font-size: 0.88rem;
    border: 1px solid transparent;
    overflow: visible;
    transition: transform 0.22s var(--transition-base), box-shadow 0.22s var(--transition-base),
        background 0.22s, border-color 0.22s, color 0.22s;
}
.btn::after { display: none; }
.btn:active { transform: translateY(1px) scale(0.995); }
.btn-sm { border-radius: 11px; padding: 0.35rem 0.8rem; font-size: 0.8rem; }
.btn-lg { border-radius: 16px; padding: 0.78rem 1.5rem; font-size: 0.95rem; }

.btn-primary {
    color: #fff;
    background: var(--primary-grad);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.24) inset, var(--shadow-primary);
}
.btn-primary:hover, .btn-primary:focus {
    color: #fff;
    background: linear-gradient(135deg, #ff927b, #f0604f 55%, #d94b3b);
    transform: translateY(-1.5px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.28) inset, 0 16px 30px -12px rgba(224, 82, 60, 0.7);
}
.btn-primary:disabled, .btn-primary.disabled { opacity: 0.5; box-shadow: none; }

.btn-outline-secondary {
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}
.btn-outline-secondary:hover {
    color: var(--text-primary);
    background: var(--bg-card-hover);
    border-color: var(--text-muted);
    transform: translateY(-1px);
}
.btn-outline-light {
    color: #fff;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.btn-outline-light:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-1px);
}
.btn-danger {
    color: #fff;
    background: linear-gradient(135deg, #e25344, #b74234);
    border: 0;
    box-shadow: 0 10px 22px -12px rgba(183, 66, 52, 0.6);
}
.btn-danger:hover { color: #fff; background: linear-gradient(135deg, #f0604f, #c2412f); }
.btn-outline-danger { color: var(--danger); border: 1px solid rgba(194, 65, 47, 0.3); background: transparent; }
.btn-outline-danger:hover { color: #fff; background: var(--danger); border-color: var(--danger); }

.btn-approve { background: linear-gradient(135deg, #18b7a3, #0c7f71); box-shadow: 0 8px 18px -8px rgba(12, 127, 113, 0.5); }
.btn-reject { background: linear-gradient(135deg, #e25344, #b74234); box-shadow: 0 8px 18px -8px rgba(183, 66, 52, 0.5); }
.btn-approve:hover, .btn-reject:hover { transform: translateY(-1px); }

.btn-group { border-radius: 999px; }
.btn-group .btn { border-radius: 0; }
.btn-group .btn:first-child { border-top-left-radius: 999px; border-bottom-left-radius: 999px; }
.btn-group .btn:last-child { border-top-right-radius: 999px; border-bottom-right-radius: 999px; }
.btn-group .btn + .btn { border-left: 1px solid var(--border-color); }

.follow-btn:not(.following) { background: var(--primary-grad); color: #fff; box-shadow: var(--shadow-primary); }
.follow-btn.following { background: var(--bg-muted); color: var(--text-secondary); border: 1px solid var(--border-color); }

/* ---------- 表单 ---------- */
.form-control, .form-select {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background-color: var(--bg-card);
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.6rem 0.9rem;
    box-shadow: inset 0 1px 2px rgba(45, 35, 20, 0.03);
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    background-color: var(--bg-card);
    color: var(--text-primary);
    box-shadow: 0 0 0 4px rgba(240, 96, 79, 0.12);
}
.form-control::placeholder { color: var(--text-muted); font-weight: 500; opacity: 0.85; }
.form-control[type="file"] { padding: 0.32rem 0.5rem; }
.form-control[type="file"]::file-selector-button {
    margin-right: 0.6rem;
    padding: 0.38rem 0.8rem;
    border: 0;
    border-radius: 9px;
    background: var(--bg-muted);
    color: var(--text-secondary);
    font-weight: 700;
    font-size: 0.8rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.form-control[type="file"]::file-selector-button:hover { background: var(--primary-ultra-light); color: var(--primary-dark); }

.file-picker {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    max-width: 270px;
    padding: 0.28rem 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-card);
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.file-picker:hover { border-color: var(--text-muted); background: var(--bg-card-hover); }
.file-picker:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(240, 96, 79, 0.12); }
.file-picker input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}
.file-picker-btn {
    flex-shrink: 0;
    padding: 0.34rem 0.7rem;
    border-radius: 9px;
    background: var(--primary-ultra-light);
    color: var(--primary-dark);
    font-size: 0.78rem;
    font-weight: 800;
}
.file-picker-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
}
.form-label { font-weight: 700; color: var(--text-primary); font-size: 0.9rem; }
.form-text { color: var(--text-muted) !important; font-weight: 500; }
.input-group-text {
    background: var(--bg-muted);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    border-radius: 12px;
    font-weight: 700;
}
.input-group .form-control { border-radius: 12px; }
.input-group > .form-control:not(:first-child) { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.input-group > .form-control:not(:last-child) { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.form-check-input { border-color: var(--border-color); background-color: var(--bg-card); }
.form-check-input:checked { background-color: var(--primary); border-color: var(--primary); }
.form-check-input:focus { box-shadow: 0 0 0 4px rgba(240, 96, 79, 0.12); border-color: var(--primary); }
.form-select:disabled, .form-control:disabled { background: var(--bg-muted); color: var(--text-muted); opacity: 0.8; }

.search-box .form-control {
    height: 42px;
    border-radius: 999px;
    padding-left: 2.4rem;
    background: var(--bg-card);
}
.search-box .search-icon { color: var(--text-muted); font-size: 0.82rem; }

/* ---------- 卡片 ---------- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    color: var(--text-primary);
}
.card-body { padding: 1rem 1.1rem 1.15rem; }
.card-title { font-size: 0.98rem; font-weight: 800; letter-spacing: -0.015em; color: var(--text-primary); margin-bottom: 0.35rem; }
.card-meta { font-size: 0.78rem; color: var(--text-muted); font-weight: 600; }
.card-meta a { color: var(--text-muted); }
.card-meta a:hover { color: var(--primary-dark); }
.card.hover-lift { overflow: hidden; }
.card.hover-lift::before {
    height: 3px;
    background: linear-gradient(90deg, var(--primary), #f0b429 55%, var(--accent));
}
.card.hover-lift:hover {
    transform: translateY(-4px);
    border-color: var(--border-color);
    box-shadow: var(--shadow-lg);
}
.card.hover-lift:hover .card-image-wrapper img { transform: scale(1.06); }
.card-image-wrapper { background: var(--bg-muted); }
.card-placeholder {
    background: linear-gradient(150deg, #f7efe3, #efe4d2);
    color: #b3a190;
}
[data-theme="dark"] .card-placeholder { background: linear-gradient(150deg, #2b241b, #201b15); color: #6f6252; }
.media-bg { background: var(--bg-muted); }

.gallery-grid { grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 1.25rem; }
.gallery-card { display: flex; flex-direction: column; }
.gallery-card .card-body { display: flex; flex-direction: column; flex: 1; }
.gallery-cover { display: block; overflow: hidden; }
.gallery-title-link { color: inherit; text-decoration: none; }
.gallery-title-link:hover .card-title { color: var(--primary-dark); }
.card-editor-link { margin-top: auto; font-size: 0.78rem; }
.card-desc { opacity: 0.85; }

/* ---------- 页面标题 / 筛选 ---------- */
.page-header {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1.35rem 1.5rem;
    box-shadow: var(--shadow-sm);
}
.page-header h2, .page-header h3 { font-size: 1.4rem; }
.page-header p { color: var(--text-muted); font-weight: 500; }
.page-header .text-gradient-primary { background: var(--primary-grad); -webkit-background-clip: text; background-clip: text; }

.tag-filter {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 0.8rem 1rem;
    box-shadow: var(--shadow-sm);
    gap: 0.45rem;
}
.filter-label { color: var(--text-muted); font-size: 0.8rem; }
.tag-filter .btn { border-radius: 999px; }

/* ---------- 徽章 / 状态 ---------- */
.badge-grid {
    background: var(--primary-ultra-light);
    color: var(--primary-dark);
    border: 1px solid rgba(240, 96, 79, 0.1);
    font-weight: 800;
}
.badge-grid:nth-child(6n+1) { background: #ffe9e5; color: #b74234; }
.badge-grid:nth-child(6n+2) { background: #fef3d7; color: #8a6410; }
.badge-grid:nth-child(6n+3) { background: #dff4f0; color: #0c7f71; }
.badge-grid:nth-child(6n+4) { background: #ece9fe; color: #5b4ed0; }
.badge-grid:nth-child(6n+5) { background: #e8f1fa; color: #2f6fb2; }
.badge-grid:nth-child(6n+6) { background: #fbe9e5; color: #c2412f; }
[data-theme="dark"] .badge-grid { background: rgba(255, 255, 255, 0.06) !important; color: var(--text-primary) !important; border-color: var(--border-color); }
[data-theme="dark"] .badge-grid:nth-child(6n+1) { color: #ff9b8b !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+2) { color: #f0b429 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+3) { color: #3dc9b6 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+4) { color: #b7adf8 !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+5) { color: #7bb6ea !important; }
[data-theme="dark"] .badge-grid:nth-child(6n+6) { color: #ffb0a3 !important; }
.badge { font-weight: 700; border-radius: 999px; }
.status-badge { font-weight: 800; font-size: 0.72rem; padding: 0.25rem 0.7rem; }
.status-badge.pending { background: var(--warning-light); color: var(--warning); }
.status-badge.approved { background: var(--success-light); color: var(--success); }
.status-badge.rejected { background: var(--danger-light); color: var(--danger); }

.level-badge { background: var(--accent-grad); box-shadow: 0 6px 16px -8px rgba(16, 156, 139, 0.5); }
.level-progress { background: var(--bg-muted); }
.level-progress > span { background: linear-gradient(90deg, var(--primary), #f0b429); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    isolation: isolate;
    padding: clamp(2rem, 4.2vw, 3.4rem);
    margin-bottom: 1.75rem;
    border-radius: var(--radius-2xl);
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: linear-gradient(155deg, #35302a 0%, #221e19 46%, #14110d 100%);
    box-shadow: 0 2px 0 rgba(255, 255, 255, 0.07) inset, 0 44px 80px -44px rgba(34, 30, 25, 0.7);
    color: #fff;
    overflow: hidden;
}
.hero::before {
    background:
        radial-gradient(420px 300px at 84% 16%, rgba(240, 96, 79, 0.32), transparent 65%),
        radial-gradient(360px 300px at 12% 96%, rgba(16, 156, 139, 0.24), transparent 65%);
}
.hero::after {
    background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1.2px, transparent 1.2px);
    background-size: 24px 24px;
    opacity: 0.55;
    mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.9), transparent 85%);
    -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.9), transparent 85%);
}
.hero > * { position: relative; z-index: 2; }

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.1rem;
    font-size: 10.5px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.55);
}
.hero-eyebrow::before {
    content: '';
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--primary), #f0b429);
}

.hero h1 {
    max-width: 46rem;
    margin-bottom: 0.85rem;
    font-size: clamp(2.05rem, 4.4vw, 3.35rem);
    line-height: 1.08;
    letter-spacing: -0.04em;
    color: #fff;
}
.hero-highlight {
    background: linear-gradient(110deg, #ffb199 0%, #f0b429 48%, #3dc9b6 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero p {
    max-width: 44rem;
    margin-bottom: 1.6rem;
    font-size: 0.98rem;
    font-weight: 500;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.62);
    opacity: 1;
}
.hero .hero-actions { display: flex; flex-wrap: wrap; gap: 0.7rem; align-items: center; }
.hero .btn-primary {
    color: #fff;
    background: var(--primary-grad);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.24) inset, 0 16px 34px -12px rgba(240, 96, 79, 0.65);
}
.hero .btn-primary:hover { color: #fff; background: linear-gradient(135deg, #ff927b, #f0604f 55%, #d94b3b); }
.hero .btn-outline-light {
    color: rgba(255, 255, 255, 0.86);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: none;
}
.hero .btn-outline-light:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.13);
    border-color: rgba(255, 255, 255, 0.32);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.1rem;
    margin-top: 1.5rem;
    font-size: 11.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.42);
}
.hero-meta span { display: inline-flex; align-items: center; gap: 0.35rem; }
.hero-meta i { color: var(--accent); }

.hero-bead {
    position: absolute;
    z-index: 1;
    border-radius: 50%;
    box-shadow: inset -3px -3px 8px rgba(0, 0, 0, 0.35), 0 8px 20px rgba(0, 0, 0, 0.35);
    opacity: 0.9;
    pointer-events: none;
    animation: hero-float 8s ease-in-out infinite;
}
.hero-bead::after {
    content: '';
    position: absolute;
    inset: 32%;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.22);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
}
.hero-bead-1 { top: 16%; right: 7%; width: 34px; height: 34px; background: #f0604f; }
.hero-bead-2 { bottom: 20%; right: 17%; width: 22px; height: 22px; background: #f0b429; animation-delay: 1.2s; }
.hero-bead-3 { top: 24%; right: 26%; width: 14px; height: 14px; background: #109c8b; animation-delay: 2.4s; }
@keyframes hero-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-7px); }
}

/* ---------- 公告 ---------- */
.announcement-bar {
    background: linear-gradient(90deg, var(--warning-light), var(--bg-card) 70%);
    border-bottom: 1px solid var(--border-color);
}
.ann-badge { background: var(--primary-grad); color: #fff; letter-spacing: 0.06em; }
.ann-item { color: var(--text-secondary); font-size: 0.82rem; }

/* ---------- 热门侧栏 ---------- */
.trending-rail {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1.2rem;
    box-shadow: var(--shadow-sm);
}
.trending-rail h6 { font-size: 0.9rem; }
.trending-item { border-bottom: 1px dashed var(--border-color); }
.trending-title { color: var(--text-primary); }
.trending-rank { background: var(--bg-muted); color: var(--text-muted); }
.trending-rank.top1 { background: var(--primary-grad); color: #fff; }
.trending-rank.top2 { background: linear-gradient(135deg, #cbb89e, #a98f6d); color: #fff; }
.trending-rank.top3 { background: var(--accent-grad); color: #fff; }
.trending-thumb, .trending-thumb-ph { border-radius: 10px; }
.trending-thumb-ph { background: var(--bg-muted); color: var(--text-muted); }

/* ---------- 空状态 / 加载 / 提示 ---------- */
.empty-state {
    background: var(--bg-card);
    border: 1px dashed var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    color: var(--text-muted);
}
.empty-state > i { background: var(--primary-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; opacity: 0.75; }
.empty-state h5 { color: var(--text-primary); }

.btn-load-more {
    background: var(--bg-card);
    border: 1px dashed var(--border-color);
    color: var(--text-secondary);
    box-shadow: var(--shadow-sm);
}
.btn-load-more:hover:not(:disabled) { color: var(--primary-dark); border-color: rgba(240, 96, 79, 0.35); background: var(--primary-ultra-light); }
.load-more-end { color: var(--text-muted); }

.alert {
    border: 1px solid transparent;
    border-left-width: 3px;
    border-radius: 14px;
    padding: 0.85rem 1.1rem;
    font-weight: 500;
    box-shadow: var(--shadow-sm);
}
.alert-success { background: var(--success-light); color: var(--success); border-color: var(--success); }
.alert-info { background: var(--info-light); color: var(--info); border-color: var(--info); }
.alert-warning { background: var(--warning-light); color: var(--warning); border-color: var(--warning); }
.alert-danger { background: var(--danger-light); color: var(--danger); border-color: var(--danger); }

.pagination { gap: 0.3rem; }
.page-item .page-link {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-card);
    color: var(--text-secondary);
    font-weight: 700;
    box-shadow: var(--shadow-sm);
}
.page-item .page-link:hover { background: var(--primary-ultra-light); color: var(--primary-dark); border-color: rgba(240, 96, 79, 0.25); }
.page-item.active .page-link { background: var(--primary-grad); border-color: transparent; color: #fff; box-shadow: var(--shadow-primary); }
.page-item.disabled .page-link { background: var(--bg-muted); color: var(--text-muted); opacity: 0.6; }

/* ---------- 头像 / 统计 ---------- */
.avatar, .avatar-circle {
    background: var(--primary-grad);
    color: #fff;
    box-shadow: var(--shadow-primary);
}
.avatar { border: 4px solid var(--bg-card); }
.info-card .stats-grid { grid-template-columns: repeat(4, 1fr); }
.stat-value {
    background: linear-gradient(120deg, var(--primary), #f0a429);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-variant-numeric: tabular-nums;
}
.stat-label { color: var(--text-muted); }
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}
.stat-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.stat-icon { border-radius: 12px; }

/* ---------- 作品详情 ---------- */
.post-title { font-size: clamp(1.5rem, 2.4vw, 1.9rem); line-height: 1.3; }
.post-meta { color: var(--text-muted); }
.post-meta a { color: var(--text-secondary); }
.post-meta a:hover { color: var(--primary-dark); }

.sticky-action-bar {
    top: 78px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 0.5rem 0.6rem;
    box-shadow: var(--shadow-sm);
}
.sticky-action-bar .btn { box-shadow: none; }

.user-card { border-radius: var(--radius-xl); }
.user-card .avatar { width: 72px; height: 72px; font-size: 1.9rem; }
.username { color: var(--text-primary); }
.user-card .role, .role { background: var(--bg-muted); color: var(--text-muted); }

.info-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}
.info-row { border-bottom: 1px dashed var(--border-color); }
.info-label { color: var(--text-muted); }
.info-value { color: var(--text-primary); }

.comment-card {
    background: var(--bg-muted);
    border: 1px solid transparent;
    border-radius: 14px;
    padding: 0.85rem 1rem;
}
.comment-card:hover { background: var(--primary-ultra-light); border-color: rgba(240, 96, 79, 0.1); }
.comment-meta { color: var(--text-muted); }
.comment-body { color: var(--text-primary); }

/* ---------- 网格查看器 ---------- */
.grid-viewer {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}
.gv-toolbar {
    padding: 0.8rem 1rem;
    background: linear-gradient(180deg, var(--bg-card), var(--bg-card-hover));
    border-bottom: 1px solid var(--border-color);
}
.gv-title { font-size: 0.92rem; }
.gv-seg { background: var(--bg-muted); border: 1px solid var(--border-color); padding: 3px; }
.gv-seg button { font-size: 0.76rem; padding: 0.3rem 0.75rem; }
.gv-seg button.active { background: var(--primary-grad); box-shadow: var(--shadow-primary); }
.gv-icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}
.gv-icon-btn:hover { color: var(--primary-dark); border-color: rgba(240, 96, 79, 0.3); background: var(--primary-ultra-light); }
.gv-stage {
    background-color: var(--bg-muted);
    background-image: radial-gradient(rgba(45, 35, 20, 0.08) 1px, transparent 1.2px);
    background-size: 20px 20px;
    background-position: 0 0;
}
[data-theme="dark"] .gv-stage { background-image: radial-gradient(rgba(255, 244, 226, 0.07) 1px, transparent 1.2px); }
.bead-cell { border-radius: 3px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06); }
.bead-cell:hover { box-shadow: var(--shadow-md); }
.bead-cell.is-hl { outline-color: var(--primary); }
.gv-char .bead-cell { background: var(--bg-card); box-shadow: inset 0 0 0 1px var(--border-color); }
.gv-char .bead-cell.is-hl { background: var(--primary-ultra-light); outline-color: var(--primary); }
.gv-stats { background: var(--bg-card); border-top: 1px solid var(--border-color); }
.gv-bead-item { background: var(--bg-muted); border: 1px solid transparent; }
.gv-bead-item:hover { background: var(--primary-ultra-light); }
.gv-bead-item.active { background: var(--primary-ultra-light); border-color: rgba(240, 96, 79, 0.25); color: var(--primary-dark); }
.gv-bead-swatch { border-radius: 5px; }
.gv-bead-count { color: var(--text-muted); }

/* ---------- 导入预览 / 代码 ---------- */
.import-preview {
    background: var(--bg-card-hover);
    border: 1px dashed var(--border-color);
    border-radius: var(--radius-md);
}
.import-preview-title { color: var(--primary-dark); }
.grid-data {
    background: #221e19;
    color: #ffd9a8;
    border: 1px solid #3b3328;
    border-radius: 12px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.76rem;
}

/* ---------- 登录 / 分享 ---------- */
.auth-row {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background: var(--bg-card);
}
.auth-row > [class*="col-"] { display: flex; }
.auth-row .auth-card {
    width: 100%;
    max-width: none;
    min-height: 100%;
}
.auth-row .auth-split-brand {
    flex: 1;
    min-height: 100%;
}
.auth-card, .share-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    padding: 2.25rem;
}
.auth-card::before, .share-card::before {
    height: 5px;
    background: linear-gradient(90deg, var(--primary), #f0b429 55%, var(--accent));
}
.auth-icon, .share-icon {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    background: var(--primary-grad);
    box-shadow: var(--shadow-primary);
    font-size: 1.5rem;
}
.auth-title, .share-title { font-size: 1.45rem; }
.auth-subtitle, .share-subtitle { color: var(--text-muted); font-weight: 500; }
.auth-split-brand {
    background: linear-gradient(155deg, #35302a 0%, #221e19 46%, #14110d 100%);
    color: #fff;
    border-radius: var(--radius-xl);
    position: relative;
    overflow: hidden;
}
.auth-split-brand::before {
    content: '';
    position: absolute;
    width: 320px;
    height: 320px;
    top: -100px;
    right: -80px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(240, 96, 79, 0.32), transparent 65%);
}
.auth-split-brand::after {
    background-image: radial-gradient(rgba(255, 255, 255, 0.15) 1.2px, transparent 1.2px);
    background-size: 22px 22px;
    opacity: 0.5;
}
.auth-split-brand > * { position: relative; z-index: 2; }
.auth-split-brand h2 { color: #fff; }
.auth-split-brand p { color: rgba(255, 255, 255, 0.62); }

/* ---------- 个人主页 ---------- */
.profile-header {
    background: linear-gradient(155deg, #35302a 0%, #221e19 46%, #14110d 100%);
    border-radius: var(--radius-xl);
    box-shadow: 0 34px 64px -34px rgba(34, 30, 25, 0.6);
    color: #fff;
    padding: 2rem;
}
.profile-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(300px 220px at 82% 12%, rgba(240, 96, 79, 0.3), transparent 65%),
        radial-gradient(260px 220px at 12% 96%, rgba(16, 156, 139, 0.2), transparent 65%);
    pointer-events: none;
}
.profile-header::after {
    background-image: radial-gradient(rgba(255, 255, 255, 0.14) 1.2px, transparent 1.2px);
    background-size: 22px 22px;
}
.profile-avatar {
    background: rgba(255, 255, 255, 0.1);
    border: 4px solid rgba(255, 255, 255, 0.22);
    box-shadow: 0 14px 30px -16px rgba(0, 0, 0, 0.5);
}
.profile-name { color: #fff; }
.profile-bio, .profile-joined { color: rgba(255, 255, 255, 0.72); }
.level-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}

/* ---------- 通知 ---------- */
.notification-item {
    border: 1px solid var(--border-color) !important;
    border-left: 3px solid transparent !important;
    border-radius: var(--radius-md);
    background: var(--bg-card);
}
.notification-item.unread {
    border-left-color: var(--primary) !important;
    background: linear-gradient(90deg, var(--primary-ultra-light), var(--bg-card) 65%);
}
.notification-item:hover { box-shadow: var(--shadow-sm); }
.notif-icon { background: var(--bg-muted); color: var(--text-muted); }
.notification-item.unread .notif-icon { background: var(--primary-ultra-light); }
.unread-dot { background: var(--primary); }
.mark-read-btn {
    color: var(--primary-dark);
    background: var(--primary-ultra-light);
    border: 1px solid rgba(240, 96, 79, 0.2);
}
.mark-read-btn:hover { background: var(--primary); color: #fff; }

/* ---------- 弹窗 / Toast ---------- */
.modal-content {
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}
.modal-header { background: var(--bg-card-hover); border-bottom: 1px solid var(--border-color); }
.modal-footer { border-top: 1px solid var(--border-color); }
.modal-backdrop.show { opacity: 0.48; }
.share-quick a { border-radius: 12px; box-shadow: var(--shadow-sm); }
.share-quick a:hover { transform: translateY(-2px); }

.pd-toast {
    background: var(--bg-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--primary);
    border-radius: 13px;
    box-shadow: var(--shadow-lg);
    font-weight: 600;
}
.pd-toast-success { border-left-color: var(--success); }
.pd-toast-danger { border-left-color: var(--danger); }

/* ---------- 管理 / 表格 ---------- */
.admin-page-header {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}
.admin-sidebar .nav-link { color: var(--text-secondary); }
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active { background: var(--primary-ultra-light); color: var(--primary-dark); }
.table { color: var(--text-primary); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.table thead th {
    background: var(--bg-muted);
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.72rem;
    letter-spacing: 0.06em;
}
.table tbody td { border-color: var(--border-light); color: var(--text-secondary); }
.table tbody tr { background: var(--bg-card); }
.table tbody tr:hover { background: var(--bg-card-hover); }
.table-dark thead th { background: var(--primary-grad); color: #fff; }
.admin-table, .log-table { border: 1px solid var(--border-color); }
.review-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}
.review-card:hover { box-shadow: var(--shadow-md); }
.review-thumbnail, .review-thumb-placeholder { border-radius: 12px; }
.review-thumb-placeholder { background: var(--bg-muted); color: var(--text-muted); }
.tag-cell { color: var(--primary-dark); }
.chart-wrap { background: transparent; }

/* ---------- 页脚 ---------- */
.site-footer {
    position: relative;
    z-index: 1;
    margin-top: 3.5rem;
    padding: 2.2rem 0 1.3rem;
    border-top: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.35);
}
[data-theme="dark"] .site-footer { background: rgba(255, 255, 255, 0.015); }
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}
.footer-brand { display: flex; align-items: center; gap: 0.8rem; }
.footer-brand .brand-mark { width: 38px; height: 38px; border-radius: 11px; }
.footer-brand strong { display: block; font-size: 0.95rem; font-weight: 800; color: var(--text-primary); }
.footer-brand p { margin: 0.1rem 0 0; font-size: 0.78rem; color: var(--text-muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; }
.footer-links a { font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); }
.footer-links a:hover { color: var(--primary-dark); }
.footer-copy {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px dashed var(--border-color);
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* ---------- SEO 区 ---------- */
.seo-section {
    margin-top: 3rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--border-color);
}
.seo-title { color: var(--text-primary); font-size: 0.92rem; }
.seo-section p { color: var(--text-muted); font-size: 0.8rem; line-height: 1.9; }

/* ---------- 暗色细节 ---------- */
[data-theme="dark"] .hero,
[data-theme="dark"] .profile-header,
[data-theme="dark"] .auth-split-brand {
    border: 1px solid rgba(255, 255, 255, 0.07);
}
[data-theme="dark"] .btn-close { filter: invert(1) grayscale(1) brightness(1.6); }
[data-theme="dark"] .gv-char .bead-cell { background: var(--bg-card); color: var(--text-primary); }
[data-theme="dark"] .trending-thumb-ph { background: var(--bg-muted); }
[data-theme="dark"] .navbar .nav-link:hover { background: rgba(255, 255, 255, 0.06); }
[data-theme="dark"] .card.hover-lift:hover { border-color: var(--border-light); }

/* ---------- 响应式 ---------- */
@media (max-width: 991.98px) {
    .navbar-nav.align-items-lg-center {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.4rem;
        margin-top: 0.35rem;
        padding-top: 0.65rem;
        border-top: 1px solid var(--border-color);
    }
    .navbar-nav.align-items-lg-center .nav-item { margin: 0 !important; }
    .navbar-nav.align-items-lg-center .nav-link { padding: 0.45rem 0.65rem !important; }
    .navbar-nav.align-items-lg-center .nav-link .d-none { display: none !important; }
    .navbar-nav.align-items-lg-center .btn { margin: 0 !important; }
    .navbar-collapse {
        margin-top: 0.6rem;
        padding: 0.75rem;
        border: 1px solid var(--border-color);
        border-radius: 16px;
        background: var(--bg-card);
        box-shadow: var(--shadow-md);
    }
    .navbar .nav-link { padding: 0.55rem 0.8rem !important; }
    .navbar-nav .nav-item { margin-bottom: 1px; }
    .navbar-nav .btn { margin: 0.4rem 0 0; }
    .sticky-action-bar { top: 70px; }
}

@media (max-width: 767.98px) {
    .hero { padding: 1.9rem 1.35rem; border-radius: 24px; }
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 0.9rem; }
    .hero-meta { gap: 0.75rem; margin-top: 1.2rem; }
    .hero-bead-1 { width: 22px; height: 22px; top: 10%; right: 6%; }
    .hero-bead-2, .hero-bead-3 { display: none; }
    .hero .hero-actions .btn { width: 100%; justify-content: center; }
    .page-header { padding: 1.1rem; border-radius: 20px; }
    .card-body { padding: 0.9rem 0.95rem 1rem; }
    .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; }
    .auth-card, .share-card { padding: 1.6rem 1.2rem; }
    .profile-header { padding: 1.6rem 1.2rem; }
    .sticky-action-bar { top: 66px; }
    .site-footer { margin-top: 2.5rem; }
    .footer-inner { flex-direction: column; align-items: flex-start; }
    .footer-links { gap: 0.9rem; }
    .footer-copy { flex-direction: column; gap: 0.35rem; }
    .brand-text span { display: none; }
    .brand-mark { width: 38px; height: 38px; border-radius: 11px; }
    .brand-text strong { font-size: 15px; }
    .gv-toolbar { gap: 0.4rem; }
    .gv-toolbar .gv-title { flex: 1 1 100%; margin-bottom: 0.15rem; }
    .correction-hint { display: none; }
    .page-header form { width: 100%; }
    .page-header .search-box { flex: 1; width: 100%; }
    .page-header .search-box .form-control { width: 100%; }
}

@media (max-width: 480px) {
    .info-card .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .gallery-grid { grid-template-columns: 1fr; }
    .related-grid { grid-template-columns: 1fr; }
    .hero .btn-lg { padding: 0.7rem 1.1rem; font-size: 0.9rem; }
    .footer-links { width: 100%; justify-content: space-between; gap: 0.5rem; }
    .footer-links a { font-size: 0.76rem; }
}

/* ==========================================================================
   P1：材料估算 / 作者编辑 / 评论回复
   ========================================================================== */

/* ---------- 作品页材料估算条 ---------- */
.estimate-strip {
    background: linear-gradient(135deg, rgba(16, 156, 139, 0.08), rgba(240, 180, 41, 0.06));
    border: 1px solid rgba(16, 156, 139, 0.18);
    border-radius: var(--radius-xl);
    padding: 1rem 1.15rem;
    box-shadow: var(--shadow-sm);
}
.estimate-strip-head {
    display: flex; align-items: center; justify-content: space-between;
    gap: .75rem; flex-wrap: wrap; margin-bottom: .8rem;
}
.estimate-strip-title { font-weight: 800; color: var(--text-primary); }
.estimate-strip-title i { color: var(--accent); }
.estimate-strip-note {
    font-size: .76rem; font-weight: 700; color: var(--accent-dark);
    background: var(--accent-light); border-radius: var(--radius-full);
    padding: .2rem .65rem;
}
.estimate-strip-grid {
    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .55rem;
}
.estimate-strip-item {
    display: flex; flex-direction: column; gap: .15rem;
    padding: .55rem .7rem; border-radius: var(--radius-md);
    background: var(--bg-card); border: 1px solid var(--border-light);
}
.estimate-strip-label { font-size: .72rem; font-weight: 700; color: var(--text-muted); }
.estimate-strip-value {
    font-size: 1.15rem; font-weight: 800; color: var(--text-primary);
    line-height: 1.2; font-variant-numeric: tabular-nums;
}
.estimate-strip-value small { margin-left: .15rem; font-size: .68rem; color: var(--text-muted); font-weight: 700; }
.estimate-strip-foot {
    margin: .65rem 0 0; font-size: .72rem; font-weight: 600; color: var(--text-muted);
}
.estimate-strip-foot a { font-weight: 700; }

/* ---------- 作者编辑页 ---------- */
.edit-post-card { border-radius: var(--radius-xl); }
.edit-post-form .form-label { font-size: .9rem; }
.edit-cover-row { display: flex; gap: .9rem; align-items: flex-start; }
.edit-cover-preview {
    width: 180px; height: 120px; flex: 0 0 auto; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-md); border: 1px solid var(--border-color);
    background: var(--bg-muted); color: var(--text-muted); font-size: 1.6rem;
}
.edit-cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.estimate-edit-box {
    padding: .9rem 1rem; border-radius: var(--radius-md);
    background: var(--accent-light); border: 1px solid rgba(16, 156, 139, 0.18);
}
.estimate-edit-box strong { font-size: .88rem; color: var(--text-primary); }
.estimate-mini-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; }
.estimate-mini {
    display: flex; flex-direction: column; gap: .1rem; padding: .55rem .65rem;
    border-radius: var(--radius-sm); background: var(--bg-muted);
}
.estimate-mini span { font-size: .72rem; font-weight: 600; color: var(--text-muted); }
.estimate-mini strong { font-size: .95rem; font-weight: 800; color: var(--text-primary); }

/* ---------- 评论回复 ---------- */
.comment-section-head { margin-bottom: .9rem; }
.comment-section-hint { font-size: .78rem; color: var(--text-muted); font-weight: 500; }
.comment-section-hint code {
    color: var(--primary-dark); background: var(--primary-ultra-light);
    border-radius: 5px; padding: .05rem .3rem; font-size: .78rem;
}
.comment-count-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 22px; height: 20px; padding: 0 .4rem; margin-left: .2rem;
    border-radius: var(--radius-full); background: var(--primary-ultra-light);
    color: var(--primary-dark); font-size: .72rem; font-weight: 800;
    vertical-align: 2px;
}
.comment-thread { margin-bottom: .55rem; }
.comment-thread:last-child { margin-bottom: 0; }
.comment-card { position: relative; margin-bottom: 0; }
.comment-card.is-reply { background: var(--bg-card); border-color: var(--border-light); }
.comment-meta-main { display: inline-flex; align-items: center; flex-wrap: wrap; gap: .25rem; min-width: 0; }
.comment-author { color: var(--text-secondary); text-decoration: none; font-weight: 700; }
.comment-author:hover { color: var(--primary-dark); }
.comment-reply-to {
    font-size: .7rem; font-weight: 700; color: var(--accent-dark);
    background: var(--accent-light); border-radius: var(--radius-full);
    padding: .05rem .4rem;
}
.comment-dot { color: var(--text-muted); opacity: .55; }
.comment-time { font-size: .73rem; font-weight: 600; color: var(--text-muted); }
.comment-actions { display: inline-flex; align-items: center; gap: .25rem; flex-shrink: 0; }
.comment-action-btn {
    border: 0; background: transparent; color: var(--text-muted);
    font-size: .74rem; font-weight: 700; padding: .15rem .35rem;
    border-radius: 7px; line-height: 1.4; transition: var(--transition-fast);
}
.comment-action-btn i { font-size: .68rem; margin-right: .1rem; }
.comment-action-btn:hover { color: var(--primary-dark); background: var(--primary-ultra-light); }
.comment-action-btn.danger:hover { color: var(--danger); background: var(--danger-light); }
.comment-replies {
    margin: .5rem 0 0 1rem; padding-left: .85rem;
    border-left: 2px solid var(--border-color);
}
.comment-replies .comment-card { background: var(--bg-muted); }
.comment-mention {
    color: var(--primary-dark); background: var(--primary-ultra-light);
    border-radius: 5px; padding: 0 .2rem; font-weight: 700;
}
.comment-empty { text-align: center; padding: 1.25rem 1rem; background: var(--bg-muted); border-radius: var(--radius-md); color: var(--text-muted); }
.comment-empty i { font-size: 1.5rem; display: block; opacity: .55; }
.comment-empty p { margin: 0; font-size: .85rem; font-weight: 600; }
.comment-composer { border-top: 1px dashed var(--border-color); padding-top: .85rem; }
.comment-reply-hint {
    display: flex; align-items: center; justify-content: space-between; gap: .6rem;
    flex-wrap: wrap; margin-bottom: .55rem; padding: .4rem .65rem;
    border-radius: var(--radius-sm); background: var(--accent-light);
    color: var(--accent-dark); font-size: .78rem; font-weight: 700;
}
.comment-reply-cancel {
    border: 0; background: transparent; color: var(--text-muted);
    font-size: .74rem; font-weight: 700; padding: .1rem .2rem;
}
.comment-reply-cancel:hover { color: var(--danger); }
.comment-composer-foot {
    display: flex; justify-content: space-between; gap: .5rem;
    margin-top: .35rem; font-size: .7rem; font-weight: 600; color: var(--text-muted);
}
.comment-thread.is-target .comment-card {
    animation: comment-target 2.6s ease-out;
    border-color: var(--primary-light);
}
@keyframes comment-target {
    0%, 100% { box-shadow: 0 0 0 0 rgba(240, 96, 79, 0); }
    18% { box-shadow: 0 0 0 4px rgba(240, 96, 79, 0.22); background: var(--primary-ultra-light); }
    70% { box-shadow: 0 0 0 4px rgba(240, 96, 79, 0.1); }
}
@media (hover: hover) {
    .comment-actions { opacity: 0; transition: opacity var(--transition-fast); }
    .comment-card:hover .comment-actions,
    .comment-card:focus-within .comment-actions { opacity: 1; }
}
@media (max-width: 767.98px) {
    .estimate-strip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .estimate-strip-value { font-size: 1.05rem; }
    .edit-cover-row { flex-direction: column; }
    .edit-cover-preview { width: 100%; height: 150px; }
    .comment-replies { margin-left: .45rem; padding-left: .6rem; }
    .comment-section-hint { font-size: .74rem; }
    .comment-actions { opacity: 1; }
}

.comment-composer .btn { flex: 0 0 auto; white-space: nowrap; min-width: 64px; }
@media (max-width: 420px) {
    .comment-composer .form-control { font-size: .82rem; }
    .comment-composer .btn { padding-left: .7rem; padding-right: .7rem; }
}
.edit-cover-picker { max-width: 100%; width: 100%; }
