
/* ============================================================
   基础层：变量 / 重置 / 背景流光 / 顶栏 / 布局
   ============================================================ */

:root {
  --bg: #070b16;
  --bg-2: #0b1120;
  --surface: rgba(17, 24, 39, 0.82);
  --surface-2: rgba(30, 41, 59, 0.6);
  --surface-3: rgba(51, 65, 85, 0.65);
  --border: rgba(148, 163, 184, 0.14);
  --border-strong: rgba(148, 163, 184, 0.28);
  --text-1: #f1f5f9;
  --text-2: #cbd5e1;
  --text-3: #94a3b8;
  --accent: #06b6d4;
  --accent-2: #8b5cf6;
  --accent-3: #7dd3fc;
  --glow-1: rgba(6, 182, 212, 0.25);
  --glow-2: rgba(139, 92, 246, 0.25);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --code-bg: #0d1424;
  --code-border: rgba(148, 163, 184, 0.16);
  --font-sans: "Segoe UI", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
}

[data-theme="light"] {
  --bg: #f4f7fb;
  --bg-2: #eaf0f8;
  --surface: rgba(255, 255, 255, 0.92);
  --surface-2: rgba(241, 245, 249, 0.9);
  --surface-3: rgba(226, 232, 240, 0.95);
  --border: rgba(71, 85, 105, 0.14);
  --border-strong: rgba(71, 85, 105, 0.26);
  --text-1: #0f172a;
  --text-2: #334155;
  --text-3: #64748b;
  --accent: #0891b2;
  --accent-2: #7c3aed;
  --accent-3: #0e7490;
  --glow-1: rgba(8, 145, 178, 0.18);
  --glow-2: rgba(124, 58, 237, 0.18);
  --shadow: 0 8px 28px rgba(15, 23, 42, 0.1);
  --code-bg: #f8fafc;
  --code-border: rgba(71, 85, 105, 0.18);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text-1);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
button { font-family: inherit; }
a { color: inherit; text-decoration: none; }
::selection { background: rgba(6, 182, 212, 0.3); }

/* ---------- 滚动条 ---------- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--border-strong); }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-corner { background: transparent; }

/* ---------- 背景流光层 ---------- */
.bg-fx { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.bg-grid {
  position: absolute; inset: -50%;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  transform: perspective(600px) rotateX(18deg);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 72%);
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 72%);
}
.bg-aurora {
  position: absolute; top: -28%; left: 50%; transform: translateX(-50%);
  width: 1300px; height: 640px;
  background:
    radial-gradient(ellipse at center, rgba(6, 182, 212, 0.10), transparent 58%),
    radial-gradient(ellipse at 32% 55%, rgba(139, 92, 246, 0.08), transparent 60%);
  filter: blur(58px);
  animation: aurora-drift 20s ease-in-out infinite alternate;
}
@keyframes aurora-drift {
  from { transform: translateX(-54%) rotate(-2deg); }
  to { transform: translateX(-46%) rotate(2deg); }
}
.beam-top {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 90;
  background: linear-gradient(90deg, transparent 5%, var(--accent) 30%, var(--accent-2) 65%, transparent 95%);
  opacity: 0.65;
  animation: beam-flow 6s linear infinite;
  background-size: 200% 100%;
}
@keyframes beam-flow {
  from { background-position: 0% 0; }
  to { background-position: 200% 0; }
}

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(18px) saturate(1.35);
  -webkit-backdrop-filter: blur(18px) saturate(1.35);
  border-bottom: 1px solid var(--border);
}
.topbar::after {
  content: ""; position: absolute; bottom: -1px; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent 3%, rgba(6,182,212,0.35) 30%, rgba(139,92,246,0.4) 65%, transparent 97%);
  pointer-events: none;
}
.topbar-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; gap: 18px;
  padding: 11px 24px;
}
.brand { display: flex; align-items: center; gap: 11px; cursor: pointer; flex-shrink: 0; position: relative; }
.brand::after {
  content: ""; position: absolute; left: 4px; bottom: -6px;
  width: 34px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  opacity: 0.65;
}
/* 顶栏开放式星群徽标（无框） */
.brand-emblem {
  width: 38px; height: 38px; display: grid; place-items: center;
  position: relative; flex-shrink: 0;
  filter: drop-shadow(0 0 8px rgba(129, 140, 248, 0.4));
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.brand-emblem svg { width: 38px; height: 38px; overflow: visible; }
.brand:hover .brand-emblem { transform: scale(1.12) rotate(-4deg); }
.brand-emblem .em-twinkle { transform-origin: center; transform-box: fill-box; animation: cstTwinkle 3.6s ease-in-out infinite; }
@keyframes brandShift { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes brandPulse { 0%,100% { opacity: 0.5; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
.brand-name { font-size: 17.5px; font-weight: 900; letter-spacing: 1.5px; white-space: nowrap; font-family: var(--font-sans); display: inline-flex; align-items: baseline; gap: 8px; }
.brand-name .brand-tag {
  font-size: 11px; font-weight: 700; letter-spacing: 2px;
  color: var(--accent);
  padding: 2px 8px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  opacity: 0.85;
  position: relative;
  top: -1px;
}
.brand-sub { font-size: 8.5px; letter-spacing: 2.6px; color: var(--text-3); font-weight: 700; white-space: nowrap; margin-top: 1px; }

.searchbox {
  flex: 1; max-width: 430px;
  display: flex; align-items: center; gap: 9px;
  padding: 9px 14px; border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.searchbox:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1); }
.search-icon { color: var(--text-3); display: grid; place-items: center; }
.search-icon svg { width: 16px; height: 16px; }
.searchbox input {
  flex: 1; min-width: 0;
  background: transparent; border: none; outline: none;
  color: var(--text-1); font-size: 13.5px; font-family: inherit;
}
.searchbox input::placeholder { color: var(--text-3); }
.search-kbd { display: flex; gap: 4px; flex-shrink: 0; }
.search-kbd kbd {
  font-family: var(--font-mono); font-size: 10.5px; color: var(--text-3);
  padding: 2px 6px; border-radius: 5px;
  border: 1px solid var(--border); background: var(--surface-2);
}
.topbar-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; flex-shrink: 0; }

/* 顶栏响应式（窄屏收敛） */
@media (max-width: 920px) {
  .topbar-actions { margin-left: 0; }
  .searchbox { min-width: 0; }
  .searchbox input { min-width: 0; }
}
@media (max-width: 760px) {
  .topbar-inner {
    flex-wrap: wrap; gap: 10px; padding: 10px 16px;
  }
  .searchbox {
    order: 3; flex-basis: 100%; max-width: none;
  }
  .topbar-actions { margin-left: auto; gap: 6px; }
  .icon-btn { width: 30px; height: 30px; }
  .brand-name { font-size: 13.5px; }
  .brand-sub { display: none; }
}

.icon-btn {
  position: relative;
  width: 34px; height: 34px; border-radius: 10px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-3); cursor: pointer;
  transition: color 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.icon-btn:hover { color: var(--text-1); border-color: var(--accent); box-shadow: 0 0 12px var(--glow-1); }
.icon-btn svg { width: 17px; height: 17px; }
.notif-dot {
  position: absolute; top: -5px; right: -5px;
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 999px; background: #ef4444; color: #fff;
  font-size: 10px; font-weight: 700;
  display: grid; place-items: center;
  border: 2px solid var(--bg);
}

/* ---------- 首页 Hero ---------- */
.hero {
  position: relative; z-index: 1;
  max-width: 1100px; margin: 0 auto;
  padding: 64px 24px 40px;
  text-align: center;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11.5px; font-weight: 700; letter-spacing: 1.8px;
  color: var(--text-2);
  padding: 7px 16px; border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  margin-bottom: 22px;
}
.hero-badge .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.75);
}
.hero h1 {
  font-size: 52px; font-weight: 900; line-height: 1.16; letter-spacing: 1px;
  font-family: var(--font-mono);
  text-shadow: 0 0 40px rgba(139, 92, 246, 0.18);
  display: flex; align-items: center; justify-content: center; gap: 18px;
  flex-wrap: wrap;
}
/* Hero 开放式星群徽章（无边框） */
.hero-emblem-badge {
  display: inline-grid; place-items: center;
  width: 118px; height: 118px;
  position: relative; flex-shrink: 0;
  filter: drop-shadow(0 4px 22px rgba(129, 140, 248, 0.35));
  animation: emblemFloat 6s ease-in-out infinite;
}
.hero-emblem-badge svg { width: 118px; height: 118px; overflow: visible; }
@keyframes emblemFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
.hero-emblem-badge .he-txt {
  font-family: var(--font-mono); font-weight: 800;
}
.hero-emblem-badge .he-en { font-size: 10px; letter-spacing: 3.5px; fill: #a5f3fc; }
[data-theme="light"] .hero-emblem-badge .he-en { fill: #0e7490; }
.hero-title-main {
  font-size: 76px;
  letter-spacing: 6px;
  background: linear-gradient(120deg, #22d3ee 5%, #818cf8 35%, #c084fc 65%, #f0abfc 95%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: hueFlow 8s ease infinite;
  padding-right: 0.08em;
}
/* 北斗七星星图（hero 背景）——突破 1100px 容器满视口宽，slice 满宽放大填满左右 */
/* ===== hero 背景：WebGL 星云（julian-vance-nebula 算法）+ 神经球拓扑 ===== */
/* WebGL 星云层：最底层的动态星云（fbm 噪声 + 鼠标视差 + 呼吸脉冲） */
.hero-nebula {
  position: absolute; inset: 0; z-index: -2; overflow: hidden; pointer-events: none;
  width: 100vw; left: 50%; transform: translateX(-50%);
  background: linear-gradient(180deg, #010409 0%, #020817 55%, #020617 100%);
}
.hero-nebula canvas { display: block; width: 100%; height: 100%; }
[data-theme="light"] .hero-nebula { opacity: 0.35; }
/* 神经球拓扑层：星云之上、正文之下，居中 */
.hero-neurosphere {
  position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none;
  width: 100vw; left: 50%; transform: translateX(-50%);
  mask-image: radial-gradient(ellipse 75% 70% at 50% 46%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 75% 70% at 50% 46%, #000 30%, transparent 78%);
}
.hero-neurosphere canvas { display: block; width: 100%; height: 100%; }
.hero-neurosphere .hns-glow {
  position: absolute; left: 50%; top: 46%; width: 420px; height: 420px;
  transform: translate(-50%, -50%); border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.16) 0%, rgba(37, 99, 235, 0.07) 45%, transparent 70%);
  filter: blur(28px); pointer-events: none;
}
[data-theme="light"] .hero-neurosphere { opacity: 0.55; }
[data-theme="light"] .hero-emblem-badge { filter: saturate(1.4) brightness(0.74) drop-shadow(0 4px 20px rgba(80, 60, 160, 0.28)); }
[data-theme="light"] .brand-emblem { filter: saturate(1.4) brightness(0.74) drop-shadow(0 0 6px rgba(80, 60, 160, 0.3)); }
[data-theme="light"] .ft-logo { filter: saturate(1.3) brightness(0.78); }
@media (max-width: 640px) {
  .hero-emblem-badge { width: 92px; height: 92px; }
  .hero-emblem-badge svg { width: 92px; height: 92px; }
  .hero-emblem-badge .he-en { font-size: 8px; }
  .hero-title-main { font-size: 48px; letter-spacing: 3px; }
  .hero h1 { gap: 12px; }
}
@keyframes hueFlow { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
.gradient-text {
  background: linear-gradient(135deg, var(--accent) 20%, var(--accent-2) 80%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
/* Hero 动态统计条（玻璃拟态：低不透明度+磨砂，星图背景可透过） */
.hero-stats {
  display: flex; align-items: stretch; justify-content: center; gap: 0;
  margin: 26px auto 30px;
  padding: 16px 10px;
  border: 1px solid rgba(148, 163, 184, 0.20); border-radius: 16px;
  background: rgba(17, 24, 39, 0.38);
  backdrop-filter: blur(7px) saturate(1.15); -webkit-backdrop-filter: blur(7px) saturate(1.15);
  max-width: 720px;
  position: relative; overflow: hidden;
}
[data-theme="light"] .hero-stats {
  background: rgba(255, 255, 255, 0.45);
  border-color: rgba(71, 85, 105, 0.16);
}
.hero-stats::before {
  content: ""; position: absolute; top: 0; left: 10%; right: 10%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-2), transparent);
  opacity: 0.6;
}
.hs-item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 2px 8px; }
.hs-num {
  font-family: var(--font-mono); font-size: 24px; font-weight: 800;
  background: linear-gradient(135deg, var(--accent-3), var(--accent-2));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  font-variant-numeric: tabular-nums;
}
.hs-label { font-size: 11px; color: var(--text-3); letter-spacing: 1.5px; }
.hs-divider { width: 1px; background: linear-gradient(180deg, transparent, var(--border-strong), transparent); margin: 4px 0; }
@media (max-width: 640px) {
  .hero h1 { font-size: 38px; }
  .hero-stats { flex-wrap: wrap; gap: 10px; }
  .hs-divider { display: none; }
  .hs-item { flex: 1 1 40%; }
}
.hero-desc { color: var(--text-3); font-size: 15.5px; line-height: 1.8; max-width: 640px; margin: 18px auto 30px; }
.hero-actions { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.btn-lg { padding: 13px 26px; font-size: 15px; border-radius: 13px; }

/* ---------- 面包屑 ---------- */
.crumbs {
  max-width: 1100px; margin: 0 auto;
  padding: 18px 28px 0;
  font-size: 13px; color: var(--text-3);
  position: relative; z-index: 1;
}


/* ============================================================
   智能问答（QA）模块：与全站暗色主题一致的风格
   ============================================================ */
.qa-hero {
  text-align: center; padding: 46px 20px 18px; position: relative;
}
.qa-hero-badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 11.5px; font-weight: 700; letter-spacing: 1.6px;
  color: var(--accent); padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface);
  margin-bottom: 18px;
}
.qa-hero-badge svg { width: 14px; height: 14px; }
.qa-title { font-size: 38px; font-weight: 900; line-height: 1.2; letter-spacing: 0.5px; margin-bottom: 14px; }
.qa-desc {
  color: var(--text-3); font-size: 14.5px; line-height: 1.8; max-width: 620px; margin: 0 auto 26px;
}
.qa-input-wrap {
  display: flex; gap: 10px; align-items: stretch;
  max-width: 780px; margin: 0 auto;
  padding: 12px; border-radius: 18px;
  border: 1px solid var(--border-strong); background: var(--surface);
  box-shadow: var(--shadow); transition: border-color 0.2s, box-shadow 0.2s;
}
.qa-input-wrap:focus-within {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1);
}
.qa-input-wrap textarea {
  flex: 1; background: transparent; border: none; outline: none; resize: none;
  color: var(--text-1); font-family: var(--font-sans); font-size: 15px; line-height: 1.6;
  padding: 8px 6px;
}
.qa-input-wrap textarea::placeholder { color: var(--text-3); }
.qa-suggest-row {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  max-width: 780px; margin: 14px auto 0;
}
.qa-suggest-chip {
  font-size: 12.5px; color: var(--text-2); padding: 6px 13px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface-2); cursor: pointer;
  transition: all 0.2s;
}
.qa-suggest-chip:hover {
  color: var(--accent); border-color: var(--accent); box-shadow: 0 0 10px var(--glow-1);
}

/* 统计条 */
.qa-stats-bar {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 12px;
  max-width: 900px; margin: 26px auto 10px;
}
.qa-stat {
  display: flex; flex-direction: column; align-items: center; min-width: 108px;
  padding: 13px 20px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--surface);
}
.qa-stat-num { font-size: 21px; font-weight: 800; color: var(--text-1); }
.qa-stat-num .qa-stat-sub { font-size: 12px; color: var(--text-3); font-weight: 600; }
.qa-stat-label { font-size: 11.5px; color: var(--text-3); margin-top: 3px; letter-spacing: 0.4px; }

/* 加载态 */
.qa-thinking {
  display: flex; align-items: center; gap: 7px; justify-content: center;
  padding: 44px 20px; color: var(--text-3); font-size: 14px;
}
.qa-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
  animation: qa-blink 1.2s infinite;
}
.qa-dot:nth-child(2) { animation-delay: 0.2s; }
.qa-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes qa-blink { 0%, 80%, 100% { opacity: 0.25; } 40% { opacity: 1; } }
.qa-spin {
  display: inline-block; width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.35); border-top-color: #fff;
  animation: qa-rotate 0.7s linear infinite; vertical-align: -2px; margin-right: 6px;
}
@keyframes qa-rotate { to { transform: rotate(360deg); } }

/* 回答卡片 */
.qa-answer {
  max-width: 900px; margin: 18px auto 30px;
  padding: 22px 26px; border-radius: 18px;
  border: 1px solid var(--border); background: var(--surface);
  box-shadow: var(--shadow);
}
.qa-ans-head {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-bottom: 16px;
}
.qa-conf {
  font-size: 12.5px; font-weight: 700; padding: 5px 12px; border-radius: 999px;
  color: var(--text-3); border: 1px solid var(--border-strong); background: var(--surface-2);
}
.qa-conf.good { color: #34d399; border-color: rgba(52, 211, 153, 0.4); background: rgba(52, 211, 153, 0.1); }
.qa-conf.mid  { color: #fbbf24; border-color: rgba(251, 191, 36, 0.4); background: rgba(251, 191, 36, 0.08); }
.qa-cost { font-size: 12px; color: var(--text-3); }

.qa-sources-head {
  display: flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 700; color: var(--text-2);
  margin-bottom: 12px;
}
.qa-sources-head svg { width: 15px; height: 15px; color: var(--accent); }
.qa-src-list { display: flex; flex-direction: column; gap: 12px; }
.qa-src-card {
  padding: 15px 18px; border-radius: 14px; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface-2);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.qa-src-card:hover {
  border-color: var(--accent); box-shadow: 0 0 16px var(--glow-1);
  transform: translateY(-1px);
}
.qa-src-top { display: flex; align-items: flex-start; gap: 11px; }
.qa-src-idx {
  flex-shrink: 0; width: 24px; height: 24px; border-radius: 8px;
  display: grid; place-items: center; font-size: 12.5px; font-weight: 800;
  color: var(--accent); background: rgba(6, 182, 212, 0.12);
  border: 1px solid rgba(6, 182, 212, 0.3);
}
.qa-src-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.qa-src-title { font-size: 15px; font-weight: 700; color: var(--text-1); line-height: 1.4; }
.qa-src-score {
  flex-shrink: 0; font-size: 11.5px; font-weight: 700; color: var(--accent-3);
  padding: 3px 9px; border-radius: 999px; background: var(--surface-3);
}
.qa-snip {
  margin-top: 11px; padding: 10px 13px; border-radius: 10px;
  border-left: 3px solid var(--accent);
  background: var(--code-bg); color: var(--text-2);
  font-size: 12.8px; line-height: 1.7;
  max-height: 150px; overflow: hidden;
  white-space: pre-wrap; word-break: break-word;
}
.qa-hl { background: rgba(6, 182, 212, 0.28); color: var(--text-1); border-radius: 3px; padding: 0 2px; }
.qa-src-go {
  margin-top: 10px; font-size: 12px; color: var(--accent); font-weight: 600;
}
.qa-rel-head { font-size: 13px; font-weight: 700; color: var(--text-2); margin: 18px 0 10px; }
.qa-rel-row { display: flex; flex-wrap: wrap; gap: 8px; }
.qa-rel-chip {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
  font-size: 12.5px; padding: 7px 13px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface-2);
  color: var(--text-2); transition: all 0.2s;
}
.qa-rel-chip:hover { border-color: var(--accent); color: var(--accent); }
.qa-note {
  display: flex; align-items: center; gap: 7px;
  margin-top: 18px; font-size: 12.3px; color: var(--text-3); line-height: 1.6;
}
.qa-note svg { width: 14px; height: 14px; color: #34d399; flex-shrink: 0; }

/* 拒答卡片 */
.qa-refused {
  text-align: center; padding: 36px 28px;
}
.qa-ref-icon {
  width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 16px;
  display: grid; place-items: center; color: var(--accent);
  background: rgba(6, 182, 212, 0.1); border: 1px solid rgba(6, 182, 212, 0.3);
}
.qa-ref-icon svg { width: 26px; height: 26px; }
.qa-ref-title { font-size: 18px; font-weight: 800; color: var(--text-1); margin-bottom: 12px; }
.qa-ref-text { color: var(--text-2); font-size: 14px; line-height: 1.8; max-width: 520px; margin: 0 auto 8px; }
.qa-ref-text.sm { font-size: 13px; color: var(--text-3); margin-bottom: 4px; }
.qa-ref-text b { color: var(--text-1); }
.qa-ref-link { color: var(--accent); cursor: pointer; text-decoration: underline; }
.qa-ref-sug-head {
  margin: 20px 0 10px; font-size: 13px; font-weight: 700; color: var(--text-3);
}
.qa-sugg-list {
  display: flex; flex-direction: column; gap: 8px; max-width: 480px; margin: 0 auto;
}
.qa-sugg-card {
  display: flex; align-items: center; gap: 10px; cursor: pointer; text-align: left;
  padding: 11px 15px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--surface-2);
  transition: all 0.2s;
}
.qa-sugg-card:hover { border-color: var(--accent); box-shadow: 0 0 10px var(--glow-1); }
.qa-sugg-title { font-size: 13.5px; color: var(--text-2); font-weight: 600; }

@media (max-width: 640px) {
  .qa-title { font-size: 27px; }
  .qa-input-wrap { flex-direction: column; }
  .qa-input-wrap .btn-primary { width: 100%; }
  .qa-answer { padding: 16px 14px; }
  .qa-snip { font-size: 12px; }
}

.crumb { cursor: pointer; transition: color 0.2s; }
.crumb:hover { color: var(--accent); }
.sep { opacity: 0.5; }
.crumb-cur { color: var(--text-2); font-weight: 600; }

/* ---------- 词条详情文档页 ---------- */
.doc {
  position: relative; z-index: 1;
  max-width: 1100px; margin: 14px auto 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.doc-head {
  padding: 30px 38px 24px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(148,163,184,0.04), transparent);
}
.doc-meta {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--text-3); margin-bottom: 14px;
}
.doc-chapter-chip {
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 700;
  color: var(--accent-3); background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 6px; padding: 2px 9px;
}
.doc-title { font-size: 30px; font-weight: 900; line-height: 1.3; margin-bottom: 10px; }
.doc-summary { color: var(--text-3); font-size: 14.5px; line-height: 1.75; }
.doc-body { padding: 26px 38px 40px; }

/* ---------- 通用表格 ---------- */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.blk-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.blk-table th {
  text-align: left; font-weight: 700; color: var(--text-1);
  padding: 12px 16px; background: var(--surface-2);
  border-bottom: 1px solid var(--border-strong);
  white-space: nowrap;
}
.blk-table td { padding: 11px 16px; color: var(--text-2); border-bottom: 1px solid var(--border); }
.blk-table tbody tr:last-child td { border-bottom: none; }
.blk-table tbody tr:hover td { background: var(--surface-2); }
.blk-table .ops { white-space: nowrap; }

/* ---------- 搜索高亮 ---------- */
mark {
  background: rgba(6, 182, 212, 0.22);
  color: var(--accent-3);
  border-radius: 3px; padding: 0 2px;
}
[data-theme="light"] mark { color: #0e7490; }

/* ---------- 加载/空态 ---------- */
.loading { text-align: center; color: var(--text-3); padding: 60px; font-size: 14px; }

/* ---------- 页脚 ---------- */
.footer {
  position: relative; z-index: 1;
  border-top: 1px solid var(--border);
  padding: 30px 28px 36px;
  text-align: center;
  color: var(--text-3); font-size: 12.5px;
}

/* ============================================================
   社区版组件样式（登录 / 词条 / 看板 / 管理后台）
   ============================================================ */

/* ---------- 按钮 ---------- */
.btn-primary, .btn-ghost, .btn-danger {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: inherit; font-size: 13.5px; font-weight: 600;
  border-radius: 9px; padding: 9px 18px; cursor: pointer;
  transition: all 0.2s; border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; box-shadow: 0 2px 14px var(--glow-1); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 22px var(--glow-1); }
.btn-ghost { background: var(--surface); border-color: var(--border-strong); color: var(--text-1); }
.btn-ghost:hover { border-color: var(--accent); box-shadow: 0 0 14px var(--glow-1); }
.btn-ghost.warn { color: #f59e0b; }
.btn-danger { background: transparent; border-color: rgba(239, 68, 68, 0.4); color: #ef4444; }
.btn-danger:hover { background: rgba(239, 68, 68, 0.12); }
.btn-lg { padding: 13px 28px; font-size: 15px; border-radius: 12px; }
.btn-sm { padding: 4px 12px; font-size: 12px; border-radius: 7px; }
.btn-block { width: 100%; justify-content: center; margin-top: 6px; }
.btn-primary svg, .btn-ghost svg { width: 15px; height: 15px; }

/* ---------- 登录弹窗 ---------- */
.auth-overlay {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(5, 8, 18, 0.72);
  backdrop-filter: blur(10px);
  display: grid; place-items: center;
  animation: fade-in 0.25s;
  padding: 16px;
}
@keyframes fade-in { from { opacity: 0; } }
.auth-card {
  width: 100%; max-width: 400px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5), 0 0 40px var(--glow-1);
  padding: 32px 30px 26px;
  position: relative;
  animation: rise-in 0.35s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.auth-close {
  position: absolute; top: 14px; right: 14px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 8px; width: 30px; height: 30px;
  color: var(--text-3); cursor: pointer; display: grid; place-items: center;
}
.auth-close svg { width: 14px; height: 14px; }
.auth-close:hover { color: var(--text-1); border-color: var(--accent); }
.auth-logo {
  width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: grid; place-items: center; color: #fff;
  box-shadow: 0 0 26px var(--glow-1);
}
.auth-logo svg { width: 26px; height: 26px; }
.auth-tabs {
  display: flex; gap: 4px; background: var(--surface-2);
  border-radius: 11px; padding: 4px; margin-bottom: 20px;
}
.auth-tab {
  flex: 1; padding: 9px; border: none; border-radius: 8px;
  background: transparent; color: var(--text-3);
  font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: all 0.2s;
}
.auth-tab.on { background: var(--surface-3); color: var(--text-1); box-shadow: 0 2px 10px rgba(0,0,0,0.25); }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12.5px; color: var(--text-3); margin-bottom: 6px; font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; background: var(--surface-2);
  border: 1px solid var(--border-strong); border-radius: 10px;
  color: var(--text-1); font-family: inherit; font-size: 14px;
  padding: 10px 13px; outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1);
}
.field input::placeholder, .field textarea::placeholder { color: var(--text-3); }
.field-err { color: #ef4444; font-size: 12px; margin-top: 4px; min-height: 14px; }
.phone-wrap { display: flex; align-items: center; gap: 8px; }
.phone-wrap .pfx { color: var(--text-3); font-size: 13px; font-weight: 600; }
.phone-wrap input { flex: 1; }
.code-wrap { display: flex; gap: 8px; }
.code-wrap input { flex: 1; letter-spacing: 3px; }
.code-wrap .btn-ghost { flex-shrink: 0; }
.code-wrap .btn-ghost:disabled { opacity: 0.55; cursor: not-allowed; }
.demo-code { margin-top: 6px; font-size: 12px; color: var(--accent-3); }
.auth-tip { text-align: center; font-size: 12px; color: var(--text-3); margin-top: 12px; min-height: 16px; }

/* ---------- 顶栏用户区 ---------- */
.user-chip {
  display: flex; align-items: center; gap: 8px; cursor: pointer;
  background: var(--surface); border: 1px solid var(--border);
  padding: 4px 12px 4px 4px; border-radius: 999px;
  transition: all 0.2s;
}
.user-chip:hover { border-color: var(--accent); box-shadow: 0 0 14px var(--glow-1); }
.user-chip .avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-3), var(--accent));
  display: grid; place-items: center;
  color: #fff; font-size: 13px; font-weight: 700;
}
.user-chip .nick { font-size: 13px; font-weight: 600; color: var(--text-1); }
.notif-dot {
  position: absolute; top: -4px; right: -4px;
  background: #ef4444; color: #fff;
  font-size: 10px; font-weight: 700;
  min-width: 17px; height: 17px; border-radius: 999px;
  display: grid; place-items: center; padding: 0 4px;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
}
.icon-btn { position: relative; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; top: 76px; left: 50%;
  transform: translate(-50%, -12px);
  background: var(--surface-3); color: var(--text-1);
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  padding: 11px 22px; border-radius: 11px;
  font-size: 13.5px; z-index: 400;
  box-shadow: var(--shadow);
  opacity: 0; transition: all 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
  pointer-events: none;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast-err { border-left-color: #ef4444; }

/* ---------- 词条卡片 ---------- */
.section { position: relative; z-index: 1; max-width: 1560px; margin: 0 auto; padding: 0 28px 60px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 20px; }
.section-head h2 { font-size: 22px; font-weight: 800; display: flex; align-items: center; gap: 10px; }
.section-head h2 svg { width: 17px; height: 17px; flex: none; color: var(--accent); }
.see-all { color: var(--accent); font-size: 13.5px; cursor: pointer; }

/* ---------- 搜索联想下拉 ---------- */
.search-suggest {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 300;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: 14px; box-shadow: var(--shadow);
  padding: 6px; max-height: 420px; overflow-y: auto;
  animation: rise-in 0.18s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.sg-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; cursor: pointer; }
.sg-item:hover, .sg-item.on { background: var(--surface-2, rgba(255,255,255,0.06)); }
.sg-dot { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.sg-mid { flex: 1; min-width: 0; }
.sg-title { font-size: 13.5px; font-weight: 600; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sg-title mark { background: transparent; color: var(--accent); font-weight: 800; }
.sg-snippet { font-size: 11.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.sg-cat { font-size: 11px; color: var(--text-3); flex: none; }
.hero-actions { display: flex; gap: 14px; justify-content: center; }

/* ---------- 功能模块导航（首页六模块） ---------- */
.module-nav {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}
.module-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 18px 18px 16px;
  cursor: pointer; transition: all 0.22s;
  display: flex; flex-direction: column; gap: 6px;
}
.module-card:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 10px 30px rgba(0,0,0,0.3), 0 0 20px var(--glow-1); }
.mc-icon {
  width: 34px; height: 34px; border-radius: 10px;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 14px var(--glow-1); margin-bottom: 2px;
}
.mc-icon svg { width: 17px; height: 17px; }
.mc-name { font-size: 14.5px; font-weight: 700; color: var(--text-1); }
.mc-desc { font-size: 11.5px; color: var(--text-3); line-height: 1.5; }
/* HOT 模块徽标（AI Infra 置顶入口） */
.module-hot { border-color: rgba(139,92,246,0.45); background: linear-gradient(160deg, rgba(139,92,246,0.10), var(--surface) 55%); }
.module-hot:hover { border-color: #8b5cf6; box-shadow: 0 10px 30px rgba(0,0,0,0.3), 0 0 24px rgba(139,92,246,0.35); }
.module-hot .mc-icon { background: linear-gradient(135deg, #8b5cf6, #d946ef); box-shadow: 0 0 14px rgba(139,92,246,0.5); }
.mc-hot-badge {
  position: absolute; top: 10px; right: 12px;
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.08em;
  color: #fff; background: linear-gradient(135deg, #8b5cf6, #d946ef);
  border-radius: 999px; padding: 2px 8px;
  animation: hotPulse 2.4s ease-in-out infinite;
}
.module-card { position: relative; }
@keyframes hotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(139,92,246,0.55); }
  50% { box-shadow: 0 0 0 6px rgba(139,92,246,0); }
}

/* ---------- AI Infra 专区（首页主打横幅区） ---------- */
.ai-infra-zone {
  position: relative; overflow: hidden;
  border: 1px solid rgba(139,92,246,0.35); border-radius: 18px;
  background:
    radial-gradient(600px 220px at 8% -10%, rgba(139,92,246,0.16), transparent 60%),
    radial-gradient(500px 200px at 92% 0%, rgba(217,70,239,0.10), transparent 65%),
    var(--surface);
  padding: 22px 24px 24px;
}
.ai-infra-zone .section-head h2 {
  display: flex; align-items: center; gap: 8px;
  background: linear-gradient(90deg, #c4b5fd, #f0abfc);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ai-infra-zone .section-head h2 svg { width: 20px; height: 20px; stroke: #a78bfa; -webkit-text-fill-color: initial; }
.ai-zone-desc { font-size: 12.5px; color: var(--text-3); margin: -6px 0 14px; line-height: 1.6; }
.aii-row {
  display: grid; gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.aii-card {
  background: var(--surface-2, rgba(255,255,255,0.03));
  border: 1px solid rgba(139,92,246,0.22); border-radius: 12px;
  padding: 14px 15px 12px; cursor: pointer; transition: all 0.2s;
  display: flex; flex-direction: column; gap: 7px; min-width: 0;
}
.aii-card:hover { transform: translateY(-3px); border-color: #8b5cf6; box-shadow: 0 8px 24px rgba(0,0,0,0.25), 0 0 18px rgba(139,92,246,0.28); }
.aii-chip {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.1em; color: #c4b5fd;
}
.aii-chip svg { width: 12px; height: 12px; }
.aii-title {
  font-size: 13.5px; font-weight: 700; color: var(--text-1); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.aii-summary {
  font-size: 11.5px; color: var(--text-3); line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.aii-meta { font-size: 10.5px; color: var(--text-3); margin-top: auto; opacity: 0.85; }

/* ---------- 问题分类卡片（首页速览 + 总览大列表） ---------- */
.cat-grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}
.cat-grid.big { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.cat-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; overflow: hidden; cursor: pointer;
  display: flex; transition: all 0.22s; position: relative;
}
.cat-card:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 10px 30px rgba(0,0,0,0.3), 0 0 20px var(--glow-1); }
.cc-bar { width: 4px; flex-shrink: 0; }
.cc-body { padding: 16px 18px 14px; flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.cc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cc-name { font-size: 15.5px; font-weight: 800; color: var(--text-1); }
.cc-count {
  font-size: 12px; font-weight: 700; color: var(--accent);
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px; padding: 2px 10px; font-variant-numeric: tabular-nums;
}
.cc-desc { font-size: 12px; color: var(--text-3); line-height: 1.55; }
.cc-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 11.5px; color: var(--text-3); margin-top: auto; }
.cc-go { color: var(--accent); font-weight: 600; white-space: nowrap; }

/* ---------- 分类总览页 ---------- */
.cat-page { position: relative; z-index: 1; max-width: 1360px; margin: 0 auto; padding: 26px 28px 70px; }
.cat-page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 24px;
}
.cat-page-sub { font-size: 13px; color: var(--text-3); margin-top: 6px; }
.cat-page-sub b { color: var(--accent); font-size: 14.5px; }

/* ---------- 编辑表单分类提示 ---------- */
.cat-hint { font-size: 11.5px; color: var(--text-3); margin-top: 5px; min-height: 15px; line-height: 1.5; }

.entries-grid {
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
.entry-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 20px;
  cursor: pointer; transition: all 0.25s;
  position: relative; overflow: hidden;
}
/* 鼠标跟随光泽（JS 设置 --mx/--my 变量） */
.entry-card::before, .module-card::before, .cat-card::before, .aii-card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 0%), rgba(139, 92, 246, 0.13), transparent 65%);
  opacity: 0; transition: opacity 0.3s; pointer-events: none; z-index: 0;
}
.entry-card:hover::before, .module-card:hover::before, .cat-card:hover::before, .aii-card:hover::before { opacity: 1; }
.entry-card > * { position: relative; z-index: 1; }
.entry-card::after {
  content: ""; position: absolute; top: 0; left: 10%; right: 10%; height: 1.5px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0; transition: opacity 0.3s;
}
.entry-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: 0 12px 36px rgba(0,0,0,0.35), 0 0 24px var(--glow-1); }
.entry-card:hover::after { opacity: 1; }
.ec-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.cat-chip {
  font-size: 11px; font-weight: 700; color: #fff;
  padding: 2px 10px; border-radius: 999px;
}
.cat-chip.sm { font-size: 10px; padding: 1px 8px; }
.ec-ver { font-size: 11px; color: var(--text-3); font-family: "JetBrains Mono", Consolas, monospace; }
.ec-title { font-size: 16px; font-weight: 700; margin-bottom: 8px; line-height: 1.4; }
.ec-summary { font-size: 13px; color: var(--text-3); line-height: 1.65; min-height: 42px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ec-meta { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-3); margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }

/* ---------- 列表页 ---------- */
.list-page { position: relative; z-index: 1; max-width: 1100px; margin: 0 auto; padding: 0 28px 70px; }
.list-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; margin-bottom: 20px; }
.list-title { font-size: 19px; font-weight: 800; }
.list-title b { color: var(--accent); }
.cat-filter { display: flex; gap: 8px; flex-wrap: wrap; }
.cf-btn {
  font-family: inherit; font-size: 12.5px; font-weight: 600;
  background: var(--surface); color: var(--text-2);
  border: 1px solid var(--border); border-radius: 999px;
  padding: 5px 15px; cursor: pointer; transition: all 0.2s;
}
.cf-btn:hover { border-color: var(--accent); color: var(--text-1); }
.cf-btn.on { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border-color: transparent; color: #fff; }
.result-list { display: grid; gap: 14px; }
.result-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 18px 22px; cursor: pointer;
  transition: all 0.22s;
}
.result-card:hover { border-color: var(--accent); transform: translateX(5px); box-shadow: 0 0 22px var(--glow-1); }
.rc-meta { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--text-3); margin-bottom: 8px; flex-wrap: wrap; }
.rc-title { font-size: 15.5px; font-weight: 700; margin-bottom: 5px; }
.rc-snippet { font-size: 13px; color: var(--text-2); line-height: 1.7; }
.rc-tags { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.mini-tag {
  font-size: 11px; color: var(--text-3);
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px; padding: 1px 9px;
}
.pager { display: flex; justify-content: center; align-items: center; gap: 16px; margin-top: 26px; }
.pager-info { font-size: 13px; color: var(--text-3); }
.empty-tip { text-align: center; color: var(--text-3); padding: 50px 20px; font-size: 14.5px; }
.empty-tip.sm { padding: 18px; font-size: 13px; }
.empty-tip .btn-ghost { margin-left: 10px; }
.empty-tip a { color: var(--accent); cursor: pointer; }

/* ---------- 词条详情 ---------- */
.entry-actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.entry-actions .btn-ghost.fav-on { color: #f59e0b; border-color: rgba(245, 158, 11, 0.5); }
.md-body .md-h2 { font-size: 22px; font-weight: 800; margin: 26px 0 12px; color: var(--text-1); }
.md-body .md-h3 { font-size: 17px; font-weight: 700; margin: 20px 0 10px; color: var(--text-1); display: flex; align-items: center; gap: 9px; }
.md-body .md-h3::before { content: ""; width: 7px; height: 7px; border-radius: 2px; background: linear-gradient(135deg, var(--accent), var(--accent-2)); transform: rotate(45deg); flex-shrink: 0; }
.md-body .md-h4 { font-size: 14.5px; font-weight: 700; margin: 16px 0 8px; color: var(--accent-3); }
.md-body .md-p { color: var(--text-2); font-size: 14.5px; line-height: 1.85; margin-bottom: 10px; }
.md-body .md-list { margin: 8px 0 14px; display: grid; gap: 6px; }
.md-body .md-list li { list-style: none; position: relative; padding-left: 18px; color: var(--text-2); font-size: 14px; line-height: 1.75; }
.md-body .md-list li::before { content: ""; position: absolute; left: 2px; top: 0.72em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.md-body .md-quote {
  border-left: 3px solid var(--accent-2); background: var(--surface-2);
  padding: 10px 16px; border-radius: 0 10px 10px 0;
  color: var(--text-2); font-size: 13.8px; margin: 10px 0;
}
/* ---------- 书稿排版：插图 / 图注 / 公式 / 脚注 ---------- */
.md-body .md-img {
  display: block; max-width: 100%; height: auto;
  margin: 16px auto 6px; border-radius: 10px;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 4px 18px rgba(0,0,0,0.18), 0 0 0 1px var(--border);
  padding: 8px;
}
[data-theme="light"] .md-body .md-img { background: #fff; box-shadow: 0 4px 18px rgba(15,23,42,0.08), 0 0 0 1px var(--border); }
.md-body .md-p em { color: var(--text-3); font-size: 12.8px; }
.md-body .md-p:has(> em:only-child) { text-align: center; margin: 2px 0 14px; }
.md-mathblk {
  text-align: center; overflow-x: auto;
  padding: 10px 8px; margin: 12px 0;
  background: var(--surface-2); border-radius: 10px;
  font-family: "JetBrains Mono", Consolas, monospace;
  font-size: 13px; color: var(--text-2); direction: ltr;
}
.md-mathblk-done, .md-math-inline { direction: ltr; }
.md-mathblk-done { display: block; text-align: center; margin: 12px 0; overflow-x: auto; }
.md-math-inline { display: inline-block; vertical-align: middle; margin: 0 2px; }
.md-math { font-family: "JetBrains Mono", Consolas, monospace; font-size: 0.92em; color: var(--accent-3); direction: ltr; }
.md-fn {
  font-size: 0.72em; color: var(--accent); cursor: default;
  vertical-align: super; margin: 0 1px; opacity: 0.85;
}
.katex { font-size: 1.05em; }
.md-body .md-link { color: var(--accent); text-decoration: none; border-bottom: 1px dashed var(--accent); }
.md-body .md-link:hover { opacity: 0.8; }
.md-body .md-code {
  font-family: "JetBrains Mono", Consolas, monospace; font-size: 0.9em;
  background: rgba(99, 102, 241, 0.14); color: var(--accent-3);
  border-radius: 5px; padding: 1px 6px;
}
.md-body .md-pre {
  position: relative; background: var(--code-bg);
  border: 1px solid var(--code-border); border-radius: 12px;
  overflow: hidden; margin: 12px 0;
}
.md-body .md-pre pre {
  padding: 13px 16px; overflow-x: auto;
  font-family: "JetBrains Mono", Consolas, monospace;
  font-size: 12.8px; line-height: 1.7; color: #c9d6f2;
}
.md-body .md-pre .code-copy {
  position: absolute; top: 8px; right: 8px;
  font-size: 11px; font-family: inherit;
  background: rgba(255,255,255,0.06); color: #8fa3c8;
  border: 1px solid var(--code-border); border-radius: 6px;
  padding: 3px 10px; cursor: pointer; z-index: 1;
}
.md-body .md-pre .code-copy:hover { color: #fff; border-color: var(--accent); }
.md-body .md-table { width: 100%; border-collapse: collapse; font-size: 13.2px; margin: 12px 0; }
.md-body .md-table th { background: var(--surface-3); color: var(--text-1); font-weight: 700; text-align: left; padding: 9px 13px; border-bottom: 2px solid var(--accent); white-space: nowrap; }
.md-body .md-table td { padding: 8px 13px; color: var(--text-2); border-bottom: 1px solid var(--border); }
.md-body .md-table tr:hover td { background: var(--surface-2); }

/* ---------- 编辑器 ---------- */
.editor-page {
  position: relative; z-index: 1; max-width: 900px; margin: 0 auto;
  padding: 0 28px 60px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 28px 30px;
  box-shadow: var(--shadow);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field textarea {
  font-family: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
  font-size: 13.5px; line-height: 1.8; resize: vertical; min-height: 300px;
  background: var(--code-bg); color: #c9d6f2;
}
[data-theme="light"] .field textarea { background: #f8fafc; color: #1e293b; }
/* 富文本工具栏 + 分屏预览 */
.ed-toolbar {
  display: flex; align-items: center; gap: 2px; flex-wrap: wrap;
  padding: 6px 8px; margin-bottom: -1px;
  background: var(--surface-2, rgba(148, 163, 184, 0.08));
  border: 1px solid var(--border); border-bottom: none;
  border-radius: 10px 10px 0 0;
}
.ed-tb {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  min-width: 30px; height: 30px; padding: 0 7px;
  background: transparent; border: none; border-radius: 7px;
  color: var(--text-2); font-size: 12px; font-weight: 700; font-family: inherit;
  cursor: pointer; transition: background .15s, color .15s;
}
.ed-tb svg { width: 15px; height: 15px; }
.ed-tb:hover { background: var(--accent-soft, rgba(56, 132, 255, 0.15)); color: var(--text-1); }
.ed-tb.on { background: var(--accent-soft, rgba(56, 132, 255, 0.22)); color: var(--accent); }
.ed-tb-sep { width: 1px; height: 18px; margin: 0 5px; background: var(--border); }
.ed-tb-flex { flex: 1; }
.ed-split { display: flex; gap: 0; }
.ed-split textarea {
  flex: 1; min-width: 0; border-radius: 0 0 10px 10px;
}
.ed-split textarea:only-child { border-radius: 0 0 10px 10px; }
.ed-preview {
  flex: 1; min-width: 0; overflow: auto;
  max-height: 640px; padding: 14px 18px;
  background: var(--surface-2, rgba(148, 163, 184, 0.06));
  border: 1px solid var(--border); border-left: none;
  border-radius: 0 0 10px 0;
  font-size: 14px; line-height: 1.75;
}
.editor-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 8px; }
@media (max-width: 720px) {
  .ed-split { flex-direction: column; }
  .ed-preview { border-left: 1px solid var(--border); border-top: none; border-radius: 0 0 10px 10px; max-height: 360px; }
  .ed-split textarea { border-radius: 0; min-height: 220px; }
}
.conflict-box {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 12px; padding: 16px 18px; margin: 6px 0 14px;
}
.conflict-title { font-weight: 800; color: #f59e0b; margin-bottom: 8px; font-size: 15px; }
.conflict-box p { font-size: 13.5px; color: var(--text-2); margin-bottom: 6px; line-height: 1.7; }
.conflict-actions { display: flex; gap: 10px; margin-top: 10px; }

/* ---------- 历史 ---------- */
.history-page { position: relative; z-index: 1; max-width: 1200px; margin: 0 auto; padding: 0 28px 60px; }
.page-title { font-size: 21px; font-weight: 800; margin-bottom: 18px; display: flex; align-items: center; gap: 10px; }
.page-title svg { width: 18px; height: 18px; flex: none; color: var(--accent); }
.empty-tip svg { width: 18px; height: 18px; vertical-align: -3px; margin-right: 6px; color: var(--text-3); }
.ver-badge { font-size: 12px; color: var(--text-3); font-weight: 500; margin-left: 8px; }
.cur-row { background: color-mix(in srgb, var(--accent) 8%, transparent); }
.cur-badge { font-size: 10px; background: var(--accent); color: #fff; border-radius: 4px; padding: 1px 6px; margin-left: 4px; }
.ver-modal {
  width: 100%; max-width: 860px; max-height: 82vh; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: 18px; box-shadow: var(--shadow);
  animation: rise-in 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.ver-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 22px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: var(--surface); z-index: 2;
}
.ver-body { padding: 20px 26px 30px; }

/* ---------- 个人看板 ---------- */
.dash-page { position: relative; z-index: 1; max-width: 1360px; margin: 0 auto; padding: 0 28px 70px; }
.dash-grid { display: grid; grid-template-columns: 300px 1fr 1fr; gap: 20px; }
.dash-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 22px; box-shadow: var(--shadow);
}
.dash-card.wide { grid-column: span 2; }
.dash-card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.dash-card-head h3 { font-size: 15.5px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.dash-card-head h3 svg { width: 16px; height: 16px; color: var(--accent); }
.dash-card-head .cnt { font-size: 12px; color: var(--text-3); background: var(--surface-2); padding: 2px 10px; border-radius: 999px; }
.profile-card { display: flex; flex-direction: column; align-items: center; text-align: center; }
.avatar-xl {
  width: 76px; height: 76px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-3), var(--accent), var(--accent-2));
  display: grid; place-items: center; color: #fff;
  font-size: 30px; font-weight: 800; margin-bottom: 14px;
  box-shadow: 0 0 30px var(--glow-1);
}
.pc-name { font-size: 19px; font-weight: 800; }
.pc-phone { font-size: 13px; color: var(--text-3); margin: 4px 0 10px; }
.role-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12px; font-weight: 600;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  color: var(--text-2); border-radius: 999px; padding: 4px 13px;
}
.role-badge.admin { background: linear-gradient(135deg, rgba(245,158,11,0.15), rgba(239,68,68,0.1)); border-color: rgba(245,158,11,0.5); color: #f59e0b; }
.role-badge svg { width: 13px; height: 13px; }
.pc-stats { display: flex; gap: 0; margin: 18px 0; width: 100%; }
.pc-stats > div { flex: 1; }
.pc-stats > div + div { border-left: 1px solid var(--border); }
.pc-stats b { display: block; font-size: 21px; font-weight: 800; color: var(--text-1); font-variant-numeric: tabular-nums; }
.pc-stats span { font-size: 11.5px; color: var(--text-3); }
.pc-actions { display: flex; gap: 10px; width: 100%; }
.pc-actions .btn-ghost { flex: 1; justify-content: center; }
/* 头像图模式：圆形裁剪填充 */
.av-img { overflow: hidden; background: var(--surface-2); }
.av-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* 个人卡资料字段 */
.pc-pos, .pc-loc { font-size: 12.5px; color: var(--text-2); margin-top: 5px; }
.pc-bio {
  font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-top: 10px;
  background: var(--surface-2); border-radius: 10px; padding: 9px 12px;
  border: 1px solid var(--border); text-align: left; word-break: break-word;
}
/* 编辑资料弹窗 */
.profile-edit-card {
  width: 400px; max-width: calc(100vw - 40px);
  background: var(--surface-1); border: 1px solid var(--border-strong);
  border-radius: 16px; padding: 26px 24px 22px; position: relative;
  box-shadow: 0 24px 60px rgba(0,0,0,0.35); max-height: calc(100vh - 60px); overflow-y: auto;
}
.profile-edit-card .pe-title { font-size: 17px; font-weight: 800; margin-bottom: 18px; }
.pe-avatar-row { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.pe-avatar {
  width: 64px; height: 64px; border-radius: 50%; flex: none;
  background: linear-gradient(135deg, var(--accent-3), var(--accent), var(--accent-2));
  display: grid; place-items: center; color: #fff; font-size: 26px; font-weight: 800;
  box-shadow: 0 0 22px var(--glow-1);
}
.pe-avatar-ops { display: flex; flex-direction: column; gap: 7px; align-items: flex-start; }
.pe-hint { font-size: 11.5px; color: var(--text-3); }
.profile-edit-card .field { margin-bottom: 14px; }
.profile-edit-card textarea { width: 100%; resize: vertical; }
.pe-bio-cnt { text-align: right; font-size: 11px; color: var(--text-3); margin-top: 3px; }
/* 用户主页弹窗资料字段 */
.upc-pos { font-size: 12.5px; color: var(--text-2); margin-top: 4px; }
.upc-loc { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.upc-bio {
  font-size: 13px; color: var(--text-2); line-height: 1.7; margin-top: 12px;
  background: var(--surface-2); border-radius: 10px; padding: 10px 12px;
  border: 1px solid var(--border); word-break: break-word;
}
/* 个人中心回收站 */
.trash-list { display: grid; gap: 8px; }
.trash-row {
  display: flex; align-items: center; gap: 12px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 14px;
}
.tr-mid { flex: 1; min-width: 0; }
.tr-title { font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tr-meta { font-size: 11.5px; color: var(--text-3); margin-top: 2px; }
.tr-days { color: #f59e0b; font-weight: 600; }
/* 首页最近浏览 */
.hist-row { display: flex; flex-wrap: wrap; gap: 10px; }
.hist-chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px; padding: 6px 14px 6px 8px; cursor: pointer;
  transition: border-color .18s ease, transform .18s ease;
}
.hist-chip:hover { border-color: var(--accent); transform: translateY(-1px); }
.hc-title { font-size: 13px; font-weight: 600; color: var(--text-1); max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-list { display: grid; gap: 4px; }
.dash-item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px; border-radius: 10px; cursor: pointer;
  transition: background 0.15s; font-size: 13px;
}
.dash-item:hover { background: var(--surface-2); }
.di-ver { font-family: "JetBrains Mono", Consolas, monospace; font-size: 11.5px; color: var(--accent); flex-shrink: 0; }
.di-title { font-weight: 600; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 240px; }
.di-comment { color: var(--text-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.di-time { color: var(--text-3); font-size: 11.5px; flex-shrink: 0; }
/* 浏览足迹（个人中心） */
.foot-title { flex: 1; min-width: 0; }
.foot-del {
  flex-shrink: 0; width: 22px; height: 22px; border: none; border-radius: 6px;
  background: transparent; color: var(--text-3); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s; padding: 0;
}
.foot-del svg { width: 13px; height: 13px; }
.foot-del:hover { background: rgba(239,68,68,.12); color: #ef4444; }
.fav-grid { display: grid; gap: 10px; }
.fav-card { padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; cursor: pointer; transition: all 0.2s; }
.fav-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: 0 0 16px var(--glow-1); }
.fc-title { font-size: 13.5px; font-weight: 700; margin: 6px 0 4px; }
.fc-meta { font-size: 11.5px; color: var(--text-3); }
.notif-list { display: grid; gap: 2px; max-height: 420px; overflow-y: auto; }
.notif-item { display: flex; align-items: flex-start; gap: 10px; padding: 9px 10px; border-radius: 9px; font-size: 13px; }
.notif-item.unread { background: color-mix(in srgb, var(--accent) 7%, transparent); }
.ni-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; flex-shrink: 0; background: var(--text-3); }
.ni-dot.review { background: #10b981; box-shadow: 0 0 8px rgba(16,185,129,0.5); }
.ni-dot.edit { background: var(--accent); box-shadow: 0 0 8px var(--glow-1); }
.ni-dot.ban { background: #ef4444; }
.ni-dot.system { background: var(--accent-3); }
.ni-content { flex: 1; color: var(--text-2); line-height: 1.55; }
.notif-item.unread .ni-content { color: var(--text-1); font-weight: 500; }
.ni-time { font-size: 11px; color: var(--text-3); flex-shrink: 0; }
.ni-dot.friend { background: #10b981; box-shadow: 0 0 8px rgba(16,185,129,0.5); }

/* ---------- 好友 ---------- */
.dash-card-head .head-ops { display: flex; align-items: center; gap: 10px; }
.friend-body { display: grid; gap: 14px; }
.friend-sec { display: grid; gap: 6px; }
.friend-sec-title { font-size: 12px; font-weight: 700; color: var(--text-3); letter-spacing: 1px; margin-bottom: 2px; }
.friend-sec-title b { color: var(--accent); margin-left: 2px; }
.friend-row {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px; border-radius: 10px;
  background: var(--surface-2); border: 1px solid var(--border);
  transition: all 0.2s; font-size: 13px;
}
.friend-row:hover { border-color: var(--border-strong); }
.friend-row.req { border-color: rgba(16, 185, 129, 0.35); background: color-mix(in srgb, #10b981 5%, transparent); }
.friend-row.out { opacity: 0.75; }
.fr-avatar {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent-3), var(--accent));
  display: grid; place-items: center; color: #fff; font-size: 14px; font-weight: 700;
}
.fr-name { font-weight: 600; color: var(--text-1); flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fr-admin { font-size: 10px; background: rgba(245,158,11,0.15); color: #f59e0b; border-radius: 4px; padding: 1px 5px; vertical-align: 1px; }
.fr-time { font-size: 11.5px; color: var(--text-3); flex-shrink: 0; white-space: nowrap; }
@media (max-width: 720px) {
  .fr-time { display: none; }
  .friend-row { gap: 8px; }
}

/* ---------- 添加好友弹窗 ---------- */
.fs-card { max-width: 440px; }
.fs-title { text-align: center; font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.fs-sub { text-align: center; font-size: 12.5px; color: var(--text-3); margin-bottom: 18px; }
.fs-search input { min-width: 0; }
.fs-results { margin-top: 14px; max-height: 320px; overflow-y: auto; display: grid; gap: 8px; }
.fs-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 11px;
  background: var(--surface-2); border: 1px solid var(--border);
}
.fs-row .fr-name { flex: 1; }
.fs-row button { flex-shrink: 0; }
.fs-row button:disabled { opacity: 0.55; cursor: not-allowed; }

/* ---------- 私信 ---------- */
.chat-page { position: relative; z-index: 1; max-width: 860px; margin: 0 auto; padding: 0 28px 60px; }
.chat-threads { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; }
.ct-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.thread-row {
  display: flex; align-items: center; gap: 13px;
  padding: 14px 22px; cursor: pointer; transition: background 0.15s;
  border-bottom: 1px solid var(--border);
}
.thread-row:last-child { border-bottom: none; }
.thread-row:hover { background: var(--surface-2); }
.th-mid { flex: 1; min-width: 0; }
.th-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 3px; }
.th-name { font-size: 14.5px; font-weight: 700; color: var(--text-1); }
.th-time { font-size: 11px; color: var(--text-3); }
.th-preview { font-size: 12.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.th-unread {
  flex-shrink: 0; background: #ef4444; color: #fff;
  font-size: 11px; font-weight: 700; min-width: 19px; height: 19px;
  border-radius: 999px; display: grid; place-items: center; padding: 0 5px;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
}
.ni-dot.chat { background: var(--accent-2); box-shadow: 0 0 8px rgba(139,92,246,0.5); }
.ni-dot.comment { background: #f59e0b; box-shadow: 0 0 8px rgba(245,158,11,0.5); }

/* ---------- 用户公开主页弹层 ---------- */
.user-profile-card {
  width: 360px; max-width: calc(100vw - 40px);
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: 18px; box-shadow: var(--shadow);
  padding: 26px 26px 20px; position: relative;
  animation: rise-in 0.25s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.upc-head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.upc-avatar { width: 54px; height: 54px; border-radius: 16px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2)); box-shadow: 0 4px 14px var(--glow-1); }
.upc-name { font-size: 19px; font-weight: 800; color: var(--text-1); margin-bottom: 5px; }
.upc-joined { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.upc-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.upc-stats > div { background: var(--surface-2, rgba(255,255,255,0.04)); border-radius: 12px; padding: 14px; text-align: center; }
.upc-stats b { display: block; font-size: 21px; font-weight: 800; color: var(--accent); }
.upc-stats span { font-size: 11.5px; color: var(--text-3); }
.upc-actions { display: flex; gap: 10px; justify-content: center; }
.cmt-nick[data-uid], .fr-name[data-uid] { cursor: pointer; }
.cmt-nick[data-uid]:hover, .fr-name[data-uid]:hover { color: var(--accent); }

/* ---------- 词条删除二次确认 ---------- */
.del-confirm-card {
  width: 380px; max-width: calc(100vw - 40px);
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: 18px; box-shadow: var(--shadow);
  padding: 28px 26px 22px; position: relative; text-align: center;
  animation: rise-in 0.25s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.dc-icon { width: 46px; height: 46px; margin: 0 auto 12px; border-radius: 14px; display: flex; align-items: center; justify-content: center; color: #ef4444; background: rgba(239,68,68,0.12); }
.dc-icon svg { width: 22px; height: 22px; }
.dc-title { font-size: 17px; font-weight: 800; color: var(--text-1); margin-bottom: 10px; }
.dc-text { font-size: 14px; color: var(--text-2); line-height: 1.6; }
.dc-warn { font-size: 12px; color: #f59e0b; margin-top: 8px; line-height: 1.6; }
.dc-actions { display: flex; gap: 10px; justify-content: center; margin-top: 18px; }

/* ---------- 通知筛选 chips ---------- */
.nt-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.nt-chip { font-family: inherit; font-size: 11.5px; font-weight: 600; padding: 3px 11px; border-radius: 999px; border: 1px solid var(--border-strong); background: transparent; color: var(--text-3); cursor: pointer; transition: all .15s ease; }
.nt-chip:hover { color: var(--text-1); border-color: var(--accent); }
.nt-chip.on { background: color-mix(in srgb, var(--accent) 14%, transparent); border-color: var(--accent); color: var(--accent); }
.notif-item.unread { cursor: pointer; background: var(--surface-2, rgba(255,255,255,0.04)); border-radius: 8px; }
.notif-item { padding: 4px 6px; transition: background .15s ease; }

/* ---------- 个人中心：私信记录卡 ---------- */
.dm-list { display: flex; flex-direction: column; }
.dm-row { display: flex; align-items: center; gap: 12px; padding: 10px 8px; border-radius: 10px; cursor: pointer; transition: background .15s ease; }
.dm-row:hover { background: var(--surface-2, rgba(255,255,255,0.05)); }
.dm-row + .dm-row { border-top: 1px solid var(--border, rgba(255,255,255,0.04)); }
.dm-mid { flex: 1; min-width: 0; }
.dm-top { display: flex; align-items: baseline; gap: 8px; }
.dm-name { font-size: 13.5px; font-weight: 700; color: var(--text-1); }
.dm-time { font-size: 11.5px; color: var(--text-3); margin-left: auto; flex: none; }
.dm-preview { font-size: 12.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.dm-me { color: var(--accent); font-weight: 600; }
.dm-unread-chip { font-size: 11px; font-weight: 700; color: #fff; background: var(--accent-2, #8b5cf6); border-radius: 999px; padding: 2px 10px; margin-right: 6px; }

/* ---------- 词条留言板 ---------- */
.cmt-section { max-width: 1100px; margin: 0 auto 70px; padding: 26px 34px 16px; border: 1px solid var(--border); border-radius: 20px; background: var(--surface); box-shadow: var(--shadow); }
.cmt-section .section-head { margin-bottom: 16px; }
.cmt-total { font-size: 12px; font-weight: 700; color: var(--text-3); background: var(--surface-2, rgba(255,255,255,0.06)); border-radius: 10px; padding: 2px 10px; margin-left: 2px; vertical-align: 2px; }
.cmt-form { display: flex; gap: 12px; margin: 2px 0 18px; }
.cmt-avatar { width: 34px; height: 34px; border-radius: 50%; flex: none; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--accent-2), var(--accent)); box-shadow: 0 2px 10px var(--glow-1, rgba(6,182,212,0.25)); }
.cmt-avatar.me { background: linear-gradient(135deg, #10b981, #06b6d4); }
.cmt-input-wrap { flex: 1; min-width: 0; }
.cmt-input-wrap textarea { width: 100%; box-sizing: border-box; resize: vertical; min-height: 72px; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--surface-2, rgba(255,255,255,0.04)); color: var(--text-1); padding: 10px 12px; font: inherit; line-height: 1.55; transition: border-color .18s ease, box-shadow .18s ease; }
.cmt-input-wrap textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1, rgba(6,182,212,0.15)); }
.cmt-input-wrap textarea::placeholder { color: var(--text-3); }
.cmt-form-ops { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-top: 8px; }
.cmt-cnt { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.cmt-login-tip { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; padding: 14px 16px; border: 1px dashed var(--border-strong); border-radius: 12px; background: var(--surface-2, rgba(255,255,255,0.03)); color: var(--text-3); font-size: 13px; }
.cmt-list { display: flex; flex-direction: column; }
.cmt-item { display: flex; gap: 12px; padding: 14px 2px; border-bottom: 1px solid var(--border, rgba(255,255,255,0.05)); }
.cmt-item:last-child { border-bottom: none; }
.cmt-main { flex: 1; min-width: 0; }
.cmt-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.cmt-nick { font-size: 13.5px; font-weight: 700; color: var(--text-1); }
.cmt-author-mark { font-size: 10px; font-weight: 700; color: var(--accent); border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent); background: color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 5px; padding: 0 6px; line-height: 17px; }
.cmt-time { font-size: 12px; color: var(--text-3); margin-left: auto; }
.cmt-content { font-size: 14px; line-height: 1.65; color: var(--text-2); white-space: pre-wrap; word-break: break-word; max-width: 760px; }
@media (max-width: 560px) {
  .cmt-section { margin-left: 0; margin-right: 0; padding: 18px 16px 10px; }
  .cmt-avatar { width: 30px; height: 30px; font-size: 13px; }
  .cmt-head { flex-wrap: wrap; }
  .cmt-login-tip { flex-wrap: wrap; }
  .cmt-content { max-width: none; }
  .doc-body { padding: 20px 18px 30px; }
}

.chat-window { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; }
.cw-head {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 20px; border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(148,163,184,0.05), transparent);
}
.cw-peer { display: flex; flex-direction: column; }
.cw-peer b { font-size: 15px; }
.cw-peer span { font-size: 11.5px; color: var(--text-3); }
.cw-body {
  height: 480px; overflow-y: auto; padding: 20px 22px;
  display: flex; flex-direction: column; gap: 14px;
}
.chat-day-tip { text-align: center; color: var(--text-3); font-size: 12.5px; padding: 18px 0 6px; }
.msg-row { display: flex; align-items: flex-end; gap: 9px; }
.msg-row.mine { justify-content: flex-end; }
.msg-bubble {
  max-width: 72%;
  background: var(--surface-3); border-radius: 4px 14px 14px 14px;
  font-size: 14px; line-height: 1.6; color: var(--text-1);
  word-break: break-word;
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 9px 14px 8px;
  min-width: 118px; /* 至少容纳时间戳，短消息不会与时间重叠 */
}
.msg-bubble.mine {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-radius: 14px 4px 14px 14px; color: #fff;
  align-items: flex-end;
}
.msg-text { white-space: pre-wrap; }
.msg-time { font-size: 10px; opacity: 0.65; font-weight: 400; line-height: 1.4; font-variant-numeric: tabular-nums; }
.fr-avatar.me { background: linear-gradient(135deg, var(--accent-2), var(--accent)); }
.cw-input { display: flex; gap: 10px; padding: 14px 18px; border-top: 1px solid var(--border); }
.cw-input input {
  flex: 1; min-width: 0;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  border-radius: 12px; color: var(--text-1); font-family: inherit; font-size: 14px;
  padding: 11px 16px; outline: none;
}
.cw-input input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1); }
@media (max-width: 720px) {
  .chat-page { padding: 0 16px 40px; }
  .cw-body { height: calc(100vh - 320px); min-height: 320px; padding: 16px 14px; }
  .cw-input { padding: 12px 14px; }
  .msg-bubble { max-width: 80%; }
  .th-time { display: none; }
}

/* ---------- 管理后台 ---------- */
.admin-page { position: relative; z-index: 1; max-width: 1360px; margin: 0 auto; padding: 0 28px 70px; }
.admin-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.admin-tab {
  font-family: inherit; font-size: 13.5px; font-weight: 600;
  background: var(--surface); color: var(--text-2);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 8px 20px; cursor: pointer; transition: all 0.2s;
}
.admin-tab:hover { border-color: var(--accent); color: var(--text-1); }
.admin-tab.on { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; border-color: transparent; box-shadow: 0 4px 16px var(--glow-1); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 20px; }
.stat-grid > * { min-width: 0; }
.dash-grid > * { min-width: 0; }
.stat-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px 22px;
  position: relative; overflow: hidden;
}
.stat-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent-3), var(--accent), var(--accent-2));
  background-size: 200% 100%;
  animation: beam-slide 6s linear infinite;
  opacity: 0.5;
}
.sc-num { font-size: 32px; font-weight: 800; font-variant-numeric: tabular-nums; }
.sc-label { font-size: 13.5px; font-weight: 700; margin-top: 2px; }
.sc-sub { font-size: 11.5px; color: var(--text-3); margin-top: 6px; }
.admin-2col { display: grid; grid-template-columns: 1.2fr 1fr; gap: 20px; }
.admin-2col > *, .admin-2col-r > * { min-width: 0; }
.admin-2col-r { display: grid; gap: 20px; align-content: start; }
.trend-chart { display: flex; align-items: flex-end; gap: 10px; height: 220px; padding-top: 20px; }
.trend-col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; }
.trend-bar {
  width: 100%; max-width: 46px; border-radius: 7px 7px 3px 3px;
  background: linear-gradient(180deg, var(--accent-3), var(--accent));
  position: relative; min-height: 4px;
  box-shadow: 0 0 14px var(--glow-1);
  animation: bar-grow 0.8s cubic-bezier(0.2, 0.8, 0.3, 1) both;
  transform-origin: bottom;
}
@keyframes bar-grow { from { transform: scaleY(0); } }
.trend-bar span { position: absolute; top: -20px; left: 50%; transform: translateX(-50%); font-size: 11px; color: var(--text-3); }
.trend-day { font-size: 11px; color: var(--text-3); margin-top: 8px; }
.rank-list { display: grid; gap: 4px; }
.rank-row { display: flex; align-items: center; gap: 12px; padding: 7px 10px; border-radius: 9px; font-size: 13px; cursor: default; }
.rank-row[data-slug] { cursor: pointer; }
.rank-row[data-slug]:hover { background: var(--surface-2); }
.rank-no { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; font-size: 11.5px; font-weight: 700; background: var(--surface-2); color: var(--text-3); flex-shrink: 0; }
.rank-no.top { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; box-shadow: 0 0 10px var(--glow-1); }
.rank-name { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-1); font-weight: 500; }
.rank-cnt { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.role-chip { font-size: 11px; font-weight: 600; padding: 2px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); }
.role-chip.admin { background: rgba(245, 158, 11, 0.14); border-color: rgba(245, 158, 11, 0.45); color: #f59e0b; }
.role-chip.mod { background: rgba(6, 182, 212, 0.13); border-color: rgba(6, 182, 212, 0.45); color: #06b6d4; }
.role-chip.contrib { background: rgba(139, 92, 246, 0.13); border-color: rgba(139, 92, 246, 0.45); color: #8b5cf6; }
.role-mark { font-size: 10px; font-weight: 700; border-radius: 4px; padding: 1px 5px; vertical-align: 1px; white-space: nowrap; }
.role-mark.c1 { background: rgba(139, 92, 246, 0.16); color: #a78bfa; }
.role-mark.c2 { background: rgba(6, 182, 212, 0.16); color: #22d3ee; }
.role-mark.c3 { background: rgba(245, 158, 11, 0.16); color: #f59e0b; }
.role-select {
  font-family: inherit; font-size: 12.5px; font-weight: 600;
  background: var(--surface-2); color: var(--text-1);
  border: 1px solid var(--border-strong); border-radius: 8px;
  padding: 5px 8px; outline: none; cursor: pointer;
}
.role-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1); }
.my-role-chip {
  font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 999px;
  background: rgba(6, 182, 212, 0.13); border: 1px solid rgba(6, 182, 212, 0.4); color: #06b6d4;
  flex: none; align-self: center;
}
/* 后台头部：标题与角色标签同行分开，与下方 tabs 拉开间距 */
.admin-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.admin-head .page-title { margin-bottom: 0; }
.admin-tabs { margin-bottom: 22px; }

/* ---------- 数据概览：分类分布饼图 ---------- */
.admin-2col-l { display: grid; gap: 20px; align-content: start; }
.pie-wrap { display: flex; align-items: center; gap: 26px; padding: 6px 4px 2px; flex-wrap: wrap; }
.pie-svg { width: 168px; height: 168px; flex: none; transform: rotate(0deg); filter: drop-shadow(0 4px 14px rgba(0,0,0,0.25)); }
.pie-seg { transition: stroke-width .18s ease; }
.pie-svg:hover .pie-seg { stroke-width: 8.2; }
.pie-total { font-size: 8.5px; font-weight: 800; fill: var(--text-1); text-anchor: middle; }
.pie-total-sub { font-size: 3.6px; fill: var(--text-3); text-anchor: middle; }
.pie-legend { flex: 1; min-width: 150px; display: flex; flex-direction: column; gap: 7px; }
.pie-legend-row { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.pie-dot { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.pl-name { color: var(--text-2); font-weight: 600; }
.pl-cnt { margin-left: auto; color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  .pie-wrap { gap: 16px; }
  .pie-svg { width: 130px; height: 130px; }
  .pie-legend { min-width: 130px; gap: 5px; }
  .pie-legend-row { font-size: 12px; }
}
.admin-only-hint { font-size: 10px; color: var(--text-3); font-weight: 500; }
.status-chip { font-size: 11px; font-weight: 600; padding: 2px 10px; border-radius: 999px; background: rgba(16, 185, 129, 0.12); border: 1px solid rgba(16, 185, 129, 0.4); color: #10b981; }
.status-chip.banned { background: rgba(239, 68, 68, 0.12); border-color: rgba(239, 68, 68, 0.4); color: #ef4444; }
.you-badge { font-size: 10px; background: var(--accent); color: #fff; border-radius: 4px; padding: 1px 6px; }
.review-card { border: 1px solid var(--border); border-radius: 13px; padding: 16px 18px; margin-bottom: 12px; background: var(--surface-2); }
.rc-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; flex-wrap: wrap; gap: 6px; }
.rc-head b { font-size: 15px; }
.rc-author { font-size: 12px; color: var(--text-3); }
.rc-sum { font-size: 13px; color: var(--text-2); margin-bottom: 12px; }
.rc-ops { display: flex; gap: 8px; }
.sens-add { display: flex; gap: 10px; margin-bottom: 18px; }
.sens-add input {
  flex: 1; max-width: 320px;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  border-radius: 10px; color: var(--text-1);
  font-family: inherit; font-size: 14px; padding: 9px 14px; outline: none;
}
.sens-add input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--glow-1); }
.sens-list { display: flex; flex-wrap: wrap; gap: 10px; }
.sens-word {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(239, 68, 68, 0.1); border: 1px solid rgba(239, 68, 68, 0.35);
  color: #f87171; border-radius: 999px; padding: 5px 8px 5px 14px;
  font-size: 13px; font-weight: 600;
}
.sens-word button {
  width: 19px; height: 19px; border-radius: 50%; border: none;
  background: rgba(239, 68, 68, 0.2); color: #f87171;
  cursor: pointer; font-size: 12px; line-height: 1; display: grid; place-items: center;
}
.sens-word button:hover { background: #ef4444; color: #fff; }
.sens-tip { font-size: 12px; color: var(--text-3); margin-top: 16px; }
.log-action { font-family: "JetBrains Mono", Consolas, monospace; font-size: 12px; color: var(--accent-3); background: var(--surface-2); padding: 2px 8px; border-radius: 6px; }
.loading { text-align: center; color: var(--text-3); padding: 60px; font-size: 14px; }

/* ---------- 响应式补充 ---------- */
@media (max-width: 1080px) {
  .dash-grid { grid-template-columns: 1fr 1fr; }
  .dash-card.wide { grid-column: span 2; }
  .admin-2col { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .topbar-inner { padding: 10px 14px; gap: 10px; }
  .brand-sub { display: none; }
  .brand-name { font-size: 14px; }
  .brand-emblem svg { width: 28px; height: 28px; }
  .searchbox { padding: 7px 10px; }
  .search-kbd { display: none; }
  .topbar-actions { gap: 7px; }
  .icon-btn { width: 32px; height: 32px; border-radius: 9px; }
  .icon-btn svg { width: 15px; height: 15px; }
  #loginBtn { padding: 7px 12px; font-size: 12.5px; }
  .user-chip { padding: 3px 8px 3px 3px; }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-card.wide { grid-column: span 1; }
  .field-row { grid-template-columns: 1fr; }
  .list-page, .editor-page, .history-page, .dash-page, .admin-page, .section { padding-left: 16px; padding-right: 16px; }
  .editor-page { padding: 18px 16px; }
  .stats-chip { display: none; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .trend-chart { height: 160px; gap: 5px; }
  .di-comment { display: none; }
  .tbl-wrap { overflow-x: auto; }
  .blk-table { min-width: 640px; }
}
@media (max-width: 460px) {
  .hero h1 { font-size: 34px; }
  .doc-head { padding: 22px 18px 18px; }
  .doc-body { padding: 20px 18px 30px; }
  .crumbs { padding: 14px 16px 0; }
  .hero { padding: 54px 16px 40px; }
  .user-chip .nick { display: none; }
  .brand { gap: 8px; }
  .searchbox input { font-size: 13px; }
  .searchbox input::placeholder { font-size: 12px; }
}
.result-card .rc-title { font-size: 15.5px; font-weight: 700; color: var(--text-1); margin-bottom: 5px; }
.result-card .rc-snippet { font-size: 13.2px; color: var(--text-2); line-height: 1.7; }
/* 全文检索：正文命中徽标（区别于摘要展示） */
.rc-body-flag {
  display: inline-block; font-size: 10.5px; font-weight: 600; color: var(--accent);
  border: 1px solid var(--accent); border-radius: 4px; padding: 0 5px; margin-right: 7px;
  vertical-align: 1px; opacity: .85;
}
/* 站点监控（管理后台） */
.mon-probe { display: flex; align-items: center; gap: 10px; padding: 9px 4px; border-bottom: 0.5px solid var(--border); font-size: 13px; }
.mon-probe:last-child { border-bottom: none; }
.mon-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.mon-probe-name { font-weight: 600; min-width: 64px; }
.mon-probe-ms { color: var(--text-2); font-variant-numeric: tabular-nums; }
.mon-probe-code { margin-left: auto; color: var(--text-3); font-size: 12px; }
.mon-trend { width: 100%; height: auto; display: block; }
.mon-legend { display: flex; gap: 12px; font-size: 12px; font-weight: 400; color: var(--text-3); }
.mon-lg { display: inline-flex; align-items: center; gap: 5px; }
.mon-lg i { width: 9px; height: 9px; border-radius: 2px; display: inline-block; }
.mon-sys-row { display: flex; justify-content: space-between; padding: 9px 4px; border-bottom: 0.5px solid var(--border); font-size: 13px; color: var(--text-2); }
.mon-sys-row:last-child { border-bottom: none; }
.mon-sys-row b { color: var(--text-1); font-weight: 600; font-variant-numeric: tabular-nums; }
.mon-sys-row.warn b { color: #ef4444; }

/* 域徽标 */
.domain-chip {
  color: #fff; font-size: 11px; font-weight: 600;
  padding: 2px 10px; border-radius: 999px;
}

/* 页脚 */
.footer {
  position: relative; z-index: 1;
  border-top: 1px solid var(--border);
  padding: 30px 28px 36px;
  text-align: center;
  color: var(--text-3); font-size: 12.5px;
  overflow: hidden;
}
.footer::before {
  content: ""; position: absolute; top: 0; left: 20%; right: 20%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-2), transparent);
  opacity: 0.5;
}
.footer .ft-brand { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); }
.footer .ft-brand .ft-logo {
  display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
}
.footer .ft-brand .ft-logo svg { width: 18px; height: 18px; filter: drop-shadow(0 0 6px rgba(129, 140, 248, 0.5)); }
.footer b { color: var(--text-2); }
.footer .ft-line { margin-top: 8px; }
.footer .ft-qq {
  color: var(--accent); font-weight: 700;
  text-decoration: none; border-bottom: 1px dashed var(--accent);
  padding-bottom: 1px; transition: opacity .18s ease;
}
.footer .ft-qq:hover { opacity: .75; }
.footer .ft-sub { margin-top: 6px; font-size: 11.5px; color: var(--text-3); opacity: .8; }
/* 免审核标识徽章 */
.role-badge.exempt {
  background: linear-gradient(135deg, rgba(16,185,129,0.15), rgba(6,182,212,0.08));
  border-color: rgba(16,185,129,0.5); color: #10b981;
}
/* 免审核白名单管理面板 */
.wl-panel { display: grid; gap: 14px; }
.wl-tip {
  font-size: 12.5px; color: var(--text-2); line-height: 1.6;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 14px;
}
.wl-tip svg { width: 14px; height: 14px; color: var(--accent); vertical-align: -2px; }
.wl-tip b { color: var(--accent); }
.wl-add { display: flex; gap: 8px; flex-wrap: wrap; }
.wl-add input[type="text"], .wl-add input {
  flex: 1; min-width: 160px;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  border-radius: 8px; padding: 8px 12px; color: var(--text-1); font: inherit; font-size: 13px;
}
.wl-add input:focus { outline: none; border-color: var(--accent); }
.wl-add select {
  background: var(--surface-2); border: 1px solid var(--border-strong);
  border-radius: 8px; padding: 8px 10px; color: var(--text-1); font: inherit; font-size: 13px;
}
.wl-results { display: grid; gap: 6px; }
.wl-cand {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 8px; padding: 7px 12px;
}
.wl-cand .wl-name { flex: 1; font-size: 13px; font-weight: 600; }
.wl-already { font-size: 11.5px; color: var(--text-3); }
.wl-list { display: grid; gap: 8px; }
.wl-row {
  display: flex; align-items: center; gap: 12px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 14px;
}
.wl-mid { flex: 1; min-width: 0; }
.wl-row .wl-name { font-size: 13.5px; font-weight: 700; }
.wl-meta { font-size: 11.5px; color: var(--text-3); margin-top: 2px; }

/* 移动端抽屉按钮（默认隐藏） */
.mobile-only { display: none; }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 1080px) {
  .workspace { grid-template-columns: 1fr; padding: 18px 16px 60px; }
  .sidebar {
    position: fixed; z-index: 130;
    left: 14px; right: 14px; top: 74px; bottom: 14px;
    max-height: none;
    display: none;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  }
  .sidebar.open { display: flex; }
  .mobile-only { display: grid; }
  .stats-chip { display: none; }
  .crumbs { padding: 14px 16px 0; }
  .hero { padding: 54px 16px 40px; }
  .doc-head, .doc-body { padding-left: 20px; padding-right: 20px; }
  .topbar-inner { padding: 0 16px; gap: 12px; }
  .search-kbd { display: none; }
}

@media (max-width: 620px) {
  .brand-sub { display: none; }
  .hero h1 { font-size: 30px; }
  .doc-nav { flex-direction: column; }
  .doc-nav-btn.next { text-align: left; }
}

/* 进入动画 */
@keyframes rise-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.rise { animation: rise-in 0.45s cubic-bezier(0.2, 0.8, 0.3, 1) both; }
.rise-1 { animation-delay: 0.05s; }
.rise-2 { animation-delay: 0.12s; }
.rise-3 { animation-delay: 0.19s; }
.rise-4 { animation-delay: 0.26s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* 领域专家模块样式已移除（2026-11-03） */
.qa-src-chips { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; }

/* ============================================================
   生产环境部署运维模块：方案文档卡片
   ============================================================ */
.ops-card {
  position: relative; z-index: 1;
  max-width: 1100px; margin: 0 auto 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 20px 24px;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.ops-card:hover { border-color: var(--accent); box-shadow: 0 0 18px var(--glow-1); transform: translateY(-2px); }
.ops-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ops-ver { font-size: 11.5px; color: var(--text-3); margin-left: auto; }
.ops-title { font-size: 17px; font-weight: 800; color: var(--text-1); margin-bottom: 8px; line-height: 1.45; }
.ops-summary { font-size: 13px; color: var(--text-3); line-height: 1.75; }
.ops-go { font-size: 12.5px; color: var(--accent); font-weight: 700; margin-top: 10px; }

/* ============================================================
   分类子目录页（/categories/:cat）：多列目录布局
   ============================================================ */
.cat-detail-page { display: flex; flex-direction: column; gap: 20px; }
.cdp-head {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 22px 26px 18px;
}
.cdp-title-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.cdp-dot { width: 14px; height: 14px; border-radius: 4px; box-shadow: 0 0 12px currentColor; flex: none; }
.cdp-title-row .page-title { margin: 0; }
.cdp-cnt {
  font-size: 12px; font-weight: 700; color: var(--accent);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 999px; padding: 3px 10px;
}
.cdp-desc { font-size: 13px; color: var(--text-3); line-height: 1.7; margin: 10px 0 12px; }
.cdp-head .cat-filter { margin-top: 4px; }

.cat-sub-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 18px 22px 16px;
}
.css-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-bottom: 12px;
  border-bottom: 1px dashed var(--border);
  padding-bottom: 10px;
}
.css-name { font-size: 16px; font-weight: 800; color: var(--text-1); margin: 0; display: flex; align-items: center; gap: 8px; }
.css-icon { font-size: 17px; }
.css-count { font-size: 12px; color: var(--text-3); white-space: nowrap; }

.sub-list.multi-col { columns: 2; column-gap: 18px; }
.sub-list.multi-col .sub-item { break-inside: avoid; }
@media (min-width: 1280px) { .sub-list.multi-col { columns: 3; } }
@media (max-width: 760px) { .sub-list.multi-col { columns: 1; } }

.sub-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  margin-bottom: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s, transform 0.15s;
}
.sub-item:hover { border-color: var(--accent); background: rgba(6, 182, 212, 0.07); transform: translateX(4px); }
.si-slug {
  font-family: var(--font-mono);
  font-size: 11px; color: var(--text-3);
  background: var(--code-bg);
  border: 1px solid var(--code-border);
  border-radius: 5px; padding: 2px 7px;
  white-space: nowrap; flex: none;
  max-width: 220px; overflow: hidden; text-overflow: ellipsis;
}
.si-title { font-size: 13.2px; font-weight: 600; color: var(--text-2); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.si-go { color: var(--accent); font-weight: 700; flex: none; opacity: 0; transition: opacity 0.15s; }
.sub-item:hover .si-go { opacity: 1; }

/* 分类总览卡片内的子目录预览 chips */
.cc-sub { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 2px; }
.cc-sub-chip {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; color: var(--text-2);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px; padding: 2.5px 9px;
}
.cc-sub-chip i { font-style: normal; font-size: 11px; }
.cc-sub-chip b { color: var(--accent); font-weight: 800; }

/* ============================================================
   块内目录（md-toc）：多列锚点导航
   ============================================================ */
.md-toc {
  background: linear-gradient(180deg, rgba(6, 182, 212, 0.06), rgba(139, 92, 246, 0.05));
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: 14px;
  padding: 16px 20px 14px;
  margin: 18px 0 22px;
}
.md-toc-head {
  font-size: 14px; font-weight: 800; color: var(--text-1);
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 10px;
}
.md-toc-cnt {
  font-size: 11px; font-weight: 700; color: var(--text-3);
  background: var(--surface-2);
  border-radius: 999px; padding: 2px 8px;
}
.md-toc-list {
  list-style: none; margin: 0; padding: 0;
  columns: 2; column-gap: 20px;
}
.md-toc-list li { break-inside: avoid; margin: 0 0 2px; }
.md-toc-list li a {
  display: block;
  font-size: 12.8px; color: var(--text-2);
  text-decoration: none;
  padding: 5px 10px;
  border-radius: 7px;
  transition: background 0.12s, color 0.12s, transform 0.12s;
}
.md-toc-list li a:hover { background: rgba(6, 182, 212, 0.1); color: var(--text-1); transform: translateX(3px); }
@media (min-width: 1280px) { .md-toc-list { columns: 3; } }
@media (max-width: 760px) { .md-toc-list { columns: 1; } }

/* 锚点跳转目标视觉反馈（JS 加 class，避免 :target 与 hash 路由冲突） */
.md-body h2.md-h2.toc-target-flash, .md-body h3.md-h3.toc-target-flash, .md-body h4.md-h4.toc-target-flash {
  animation: toc-flash 1.6s ease;
}
.md-toc-list li a { cursor: pointer; }
@keyframes toc-flash {
  0% { background: rgba(6, 182, 212, 0.22); box-shadow: -14px 0 0 0 rgba(6, 182, 212, 0.22); }
  100% { background: transparent; box-shadow: none; }
}
