/* ===========================================================
   现代资讯站 — 设计系统与样式
   设计令牌 → 布局 → 组件 → 页面 → 响应式
   =========================================================== */

/* ---------- 设计令牌 ---------- */
:root {
  /* 暖米黄纸感底 + 纯白卡片（搜狐式淡黄基调） */
  --bg: #fbf7ee;
  --surface: #ffffff;
  --surface-2: #f4efe2;
  --text: #221e17;
  --text-2: #6b6255;
  --text-3: #7a6f5a;
  --border: rgba(96, 76, 44, 0.14);
  --border-strong: rgba(96, 76, 44, 0.26);
  --primary: #1a4fd0;
  --primary-soft: rgba(26, 79, 208, 0.10);
  /* 主色 / 危险色作为「实底」时的前景色。浅色主题用白字，
     深色主题下 --primary 是亮蓝（#8fb0ff），白字只有 2.14:1，必须换成深墨色。 */
  --on-primary: #ffffff;
  /* 频道色块（.cat/.slide-cat）上的字色。浅色主题频道色是深色（#d92d20 等），用白字；
     深色主题频道色被换成亮色（#8fb0ff/#e8b563/#5ecfb6），白字只有 1.87~2.14，必须换深墨。 */
  --on-cat: #ffffff;
  --on-danger: #ffffff;
  --danger: #d92d20;
  --danger-soft: rgba(217, 45, 32, 0.10);
  --ok: #12632f;
  --ok-soft: rgba(21, 128, 61, 0.10);
  /* 徽标文字需要压到 4.5:1，比 --danger 更深一档 */
  --pill-neg: #b02318;
  --warn: #8a4b04;
  --warn-soft: rgba(165, 90, 6, 0.11);
  /* 正文行内元素 */
  --mark: rgba(255, 208, 64, 0.42);
  --mark-text: #4a3208;
  --code-bg: #1d1a13;
  --code-text: #e8e0cf;
  --code-dim: #b9ad93;
  --code-line: rgba(255, 255, 255, 0.08);
  --footer-bg: #2a231a;
  --footer-text: rgba(255, 252, 244, 0.72);
  /* 频道色系统：每个频道一个识别色 */
  --c-yaowen: #d92d20;
  --c-keji: #1a56db;
  --c-caijing: #96650f;   /* 原 #b7791f 在白底仅 3.41，加深后 4.96（白）/ 4.65（米底） */
  --c-guoji: #0f766e;
  --c-shehui: #c2410c;
  --c-wenhua: #7c3aed;
  --c-nengyuan: #15803d;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-xs: 6px;
  --ring: 0 0 0 3px rgba(26, 86, 219, 0.28);
  --max: 1200px;
  --nav-h: 56px;
}

[data-theme="dark"] {
  --bg: #141109;
  --surface: #1c1811;
  --surface-2: #262016;
  --text: #f2ece0;
  --text-2: #b3aa98;
  --text-3: #948a78;
  --border: rgba(255, 244, 220, 0.13);
  --border-strong: rgba(255, 244, 220, 0.24);
  --primary: #8fb0ff;
  --primary-soft: rgba(143, 176, 255, 0.16);
  --on-primary: #141109;   /* 亮蓝底上的深墨字，9.6:1 */
  --on-cat: #141109;       /* 亮色频道底上的深墨字，与 --on-primary 同理 */
  --on-danger: #1b0f0c;    /* 亮红底上的深墨字，7.0:1 */
  --danger: #ff6b5e;
  --danger-soft: rgba(255, 107, 94, 0.16);
  --ok: #5cc98a;
  --ok-soft: rgba(92, 201, 138, 0.16);
  --pill-neg: #ff6b5e;
  --warn: #e0a451;
  --warn-soft: rgba(224, 164, 81, 0.16);
  --mark: rgba(255, 208, 64, 0.28);
  --mark-text: #ffe9a8;
  --code-bg: #0f0d08;
  --code-text: #e8e0cf;
  --code-dim: #b9ad93;
  --code-line: rgba(255, 255, 255, 0.08);
  --ring: 0 0 0 3px rgba(143, 176, 255, 0.3);
  --footer-bg: #0d0b07;
  --footer-text: rgba(255, 252, 244, 0.66);
  /* 频道色在深底上要整体提亮，否则 12px 的分类标签只有 3.66:1，达不到 AA */
  --c-yaowen:  #ff6b5e;
  --c-keji:    #8fb0ff;
  --c-caijing: #e8b563;
  --c-guoji:   #5ecfb6;
  --c-shehui:  #ff9a6b;
  --c-wenhua:  #b79bff;
  --c-nengyuan:#6fd694;
}

/* ---------- 基础重置 ---------- */
/* 注意：`*` 不匹配伪元素，必须显式带上 ::before / ::after，
   否则带 border 的伪元素会退回 content-box，造成尺寸偏大、居中错位
   （首页「最新快讯」时间轴的圆点曾因此比竖线宽 4px、偏移 2px）。 */
*, *::before, *::after { box-sizing: border-box; }
/* 作者样式里一旦写了 display（如 .results{display:grid}），会盖掉 UA 的 [hidden]{display:none}，
   导致 hidden 属性失效。统一加一条 !important 兜底。 */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB",
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: none;
  box-shadow: var(--ring);
  border-radius: var(--radius-xs);
}
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.35; }
p, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, textarea { font: inherit; color: inherit; }

/* ---------- 布局 ---------- */
.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}
.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 36px;
  align-items: start;
  padding: 24px 0 56px;
}
.main { min-width: 0; }
/* 侧栏本身不再 sticky：sticky 下沉到内层的 .sidebar-sticky。
   这样广告位放在外层，会随页面一起滚走；只有组件区跟随滚动。
   注意 .layout 是 align-items:start，侧栏默认只有内容高度，
   内层 sticky 就没有可滑动的余量 —— 必须显式 align-self:stretch 撑满行高。 */
.sidebar { display: grid; gap: 20px; align-content: start; align-self: stretch; }
.sidebar-sticky {
  position: sticky;
  top: calc(var(--nav-h) + 16px);
  display: grid;
  gap: 20px;
}

/* ===========================================================
   顶部：实用条（38px） + 品牌主区（78px） + 频道条（sticky）
   三层分工：日期与实用入口 / 品牌与转化 / 频道导航
   =========================================================== */
.topbar {
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.topbar-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 38px;
  font-size: 12.5px;
}
.topbar-date {
  color: var(--text-2);
  font-variant-numeric: tabular-nums;
  letter-spacing: .2px;
}
/* topbar 的底是 --surface-2（比 --bg 更深），--text-3 在上面只有 4.31:1，差一点到 AA；
   深色主题那边是 4.74:1 本来就过，所以只把浅色这两处提到 --text-2（5.29:1） */
.util-links { margin-left: auto; display: flex; gap: 18px; }
.util-links a { color: var(--text-2); }
.util-links a:hover { color: var(--primary); }

.masthead { background: var(--bg); }
.masthead-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 78px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 6px;
}
/* 品牌用图片呈现：明/暗各一份 PNG，由 html[data-theme] 切换。
   现图 319x75（比例 4.2533:1，旧图是 112x32 的 3.5:1）—— 换图后必须同步改这里的
   width 和模板里 <img> 的 width/height，两处不一致就会把 logo 拉变形。
   下面各断点的 width 一律 = round(height * 319 / 75)。 */
.brand-logo { display: block; width: 187px; height: 44px; }
/* 键盘用户跳转链接：默认移出视口，聚焦时回到左上角 */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 10px 16px;
  border-radius: 0 0 var(--radius-sm) 0;
  background: var(--primary);
  color: var(--on-primary);
  font-size: 14px;
}
.skip-link:focus { left: 0; }
.brand-logo.logo-invert { display: none; }
[data-theme="dark"] .brand-logo.logo-main { display: none; }
[data-theme="dark"] .brand-logo.logo-invert { display: block; }
.brand-sub {
  position: relative;
  padding-left: 15px;
  font-size: 13.5px;
  color: var(--text-3);
  font-weight: 400;
  letter-spacing: .3px;
}
/* 品牌与 slogan 之间的竖分隔线 */
.brand-sub::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 24px;
  background: var(--border-strong);
}
.masthead-side { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.masthead-cta {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 15px;
  border: 1px solid var(--primary);
  border-radius: 999px;
  font-size: 13px;
  color: var(--primary);
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.masthead-cta:hover { background: var(--primary); color: var(--on-primary); }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.icon-btn:hover { background: var(--surface); border-color: var(--border-strong); }
.icon-btn:focus-visible { outline: none; box-shadow: var(--ring); }

/* ---------- 导航 ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; gap: 24px; height: var(--nav-h); }
.nav-links { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a {
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  color: var(--text-2);
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.nav-links a:hover { background: var(--surface); color: var(--text); }
.nav-links a.active { color: var(--primary); background: var(--primary-soft); font-weight: 500; }

.search {
  position: relative;
  margin-left: auto;
  flex: 0 0 220px;
}
.search input {
  width: 100%;
  height: 36px;
  padding: 0 12px 0 34px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.search input:focus { border-color: var(--primary); box-shadow: var(--ring); }
.search svg { position: absolute; left: 11px; top: 10px; opacity: .55; }

.nav-toggle { display: none; }

/* ---------- 快讯滚动条 ---------- */
.home-title { margin: 22px 0 -10px; font-size: 24px; line-height: 1.3; font-weight: 650; }
.ticker {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0 0;
  padding: 10px 14px;
  background: var(--danger-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.ticker-badge {
  flex: none;
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  background: var(--danger);
  color: var(--on-danger);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .5px;
}
.ticker-view { overflow: hidden; flex: 1; }
.ticker-track {
  display: inline-flex;
  gap: 40px;
  white-space: nowrap;
  animation: ticker-scroll 28s linear infinite;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-track span { font-size: 14px; color: var(--text-2); }
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- 焦点区 ---------- */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 22px;
  margin-top: 24px;
}
.hero-main { min-width: 0; }

/* ---------- 焦点轮播（叠加式大图） ---------- */
.carousel {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
}
.carousel-track { position: relative; aspect-ratio: 16 / 9; }
.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .5s ease;
}
.slide.is-active { opacity: 1; visibility: visible; }
.slide-img { display: block; width: 100%; height: 100%; }
.slide-img img { width: 100%; height: 100%; object-fit: cover; }
.slide-body {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 64px 28px 26px;
  background: linear-gradient(to top, rgba(8, 10, 14, .88) 0%, rgba(8, 10, 14, .62) 45%, rgba(8, 10, 14, 0) 100%);
  color: #fff;
}
.slide-cat {
  display: inline-block;
  margin-bottom: 10px;
  padding: 3px 10px;
  border-radius: var(--radius-xs);
  background: var(--cat, var(--primary));
  color: var(--on-cat);
  font-size: 12px;
  font-weight: 500;
}
.slide-body h1 { font-size: 27px; line-height: 1.35; }
.slide-body h1 a:hover { text-decoration: underline; text-underline-offset: 3px; }
.slide-body p {
  margin-top: 8px;
  max-width: 62ch;
  font-size: 14px;
  line-height: 1.6;
  color: rgba(255, 255, 255, .82);
}
.slide-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, .78);
}
.slide-meta .ava i { background: rgba(255, 255, 255, .85); }

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 38px; height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(8, 10, 14, .42);
  color: #fff;
  cursor: pointer;
  opacity: 0;
  transition: opacity .2s, background .15s;
}
.carousel:hover .carousel-arrow { opacity: 1; }
.carousel-arrow:hover { background: rgba(8, 10, 14, .7); }
.carousel-arrow.prev { left: 14px; }
.carousel-arrow.next { right: 14px; }

.carousel-dots {
  position: absolute;
  right: 18px; bottom: 18px;
  display: flex;
  gap: 7px;
}
.carousel-dots button {
  width: 22px; height: 3px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: rgba(255, 255, 255, .38);
  cursor: pointer;
  transition: background .2s;
}
.carousel-dots button.active { background: #fff; }
/* 圆点本身只有 22x3px，手指根本点不到。用 ::after 撑出一块透明点击区，
   视觉上还是那条 3px 短横，不改变任何外观。 */
.carousel-dots button { position: relative; }
.carousel-dots button::after {
  content: "";
  position: absolute;
  left: -4px; right: -4px; top: -13px; bottom: -13px;
}

/* ---------- 焦点区右栏：今日要闻 ---------- */
.hero-side {
  display: flex;
  flex-direction: column;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.hero-side-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.hero-side-head h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
}
.hero-side-head h2::before {
  content: "";
  width: 3px; height: 14px;
  border-radius: 2px;
  background: var(--danger);
}
.hero-side-head .sub {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  font-size: 12px;
  color: var(--text-3);
}
.hero-side-head .live {
  display: inline-block;
  flex: none;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--danger);
  animation: livePulse 2s ease-out infinite;
}
@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 rgba(217, 45, 32, .5); }
  70%  { box-shadow: 0 0 0 6px rgba(217, 45, 32, 0); }
  100% { box-shadow: 0 0 0 0 rgba(217, 45, 32, 0); }
}

/* ---------- 快讯时间轴 ---------- */
.hero-list { display: grid; gap: 2px; flex: 1; }
.hero-list.timeline {
  position: relative;
  grid-auto-rows: 1fr;
  gap: 0;
  margin-top: 6px;
}
/* 主轴线：逐条画在 li 上，首条从圆点中心起、末条到圆点中心止。
   这样无论 grid-auto-rows:1fr 把行高算成多少，竖线都不会在两端多出一截。 */
.hero-list.timeline li::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--border);
  z-index: 0;
}
.hero-list.timeline li:first-child::after { top: 50%; }
.hero-list.timeline li:last-child::after { bottom: 50%; }
.hero-list.timeline li {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 12px;
  padding: 11px 6px 11px 20px;
  border-radius: var(--radius-sm);
  transition: background .15s;
}
/* 节点 */
.hero-list.timeline li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--border-strong);
  z-index: 1;                /* 压在竖线上，圆点遮住穿过它的那一段 */
  transition: border-color .15s, background .15s;
}
.hero-list.timeline li.is-new::before {
  background: var(--danger);
  border-color: var(--danger);
  animation: livePulse 2.6s ease-out infinite;
}
.hero-list.timeline li:hover { background: var(--surface-2); }
.hero-list.timeline li:hover::before { border-color: var(--primary); }
.hero-list.timeline li.is-new:hover::before { border-color: var(--danger); }
.hero-list li:first-child a { font-weight: 500; }
.hero-list a {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.55;
}
.hero-list a:hover { color: var(--primary); }
.hero-list time {
  font-size: 12px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  letter-spacing: .2px;
}
.hero-side-all {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  font-size: 13px;
  color: var(--text-3);
}
.hero-side-all:hover { color: var(--primary); }

/* ---------- 元信息 / 徽标 ---------- */
.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-3);
}
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 12px;
  font-weight: 500;
}
.badge.danger { background: var(--danger-soft); color: var(--pill-neg); }

/* ---------- 分区 ---------- */
.section { margin-top: 40px; }
.section-head {
  display: flex;
  align-items: baseline;        /* 右侧「查看更多」与 24px 标题共用基线，原先 center 会差 2.2px */
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.section-head h2 {
  position: relative;
  padding-left: 12px;
  font-size: 19px;
}
.section-head h2::before {
  content: "";
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 3px; height: 17px;
  border-radius: 2px;
  background: var(--accent, var(--primary));
}
.section-head .head-sub {
  padding-left: 12px;
  border-left: 1px solid var(--border);
  font-size: 13px;
  font-weight: 400;
  color: var(--text-3);
}
/* 只有「最后一个」才吃掉剩余空间。若同一行里还有别的右对齐元素
   （如 #stream 的连续加载开关），两个 auto 会把剩余空间平分，把计数顶到正中。 */
.section-head .head-count { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.section-head .head-count:last-child { margin-left: auto; }
.section-head .more { font-size: 13px; color: var(--text-3); }
.section-head .more:last-child { margin-left: auto; }
.section-head .more:hover { color: var(--primary); }
.section-head .head-count + .more { margin-left: 12px; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.card { display: grid; gap: 10px; }
/* 无图占位：本站 20707 篇里 14380 篇没有缩略图（约 69%）。
   以前统一塞 og-default.svg（1200x630 的社交分享图），当 16:9 缩略图用会被拉成一块大 logo；
   现在 NewsThumbInner() 输出 .ph，容器带 .no-img，这里画中性底。 */
.thumb.no-img,
.slide-img.no-img,
.lead-img.no-img {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--surface-2) 0%, var(--surface) 100%);
}
.ph {
  display: block;
  width: 100%;
  height: 100%;
  /* 落在 grid 单元里时自己在格内居中，且不被 stretch 拉变形：
     .rec-item / .split-item 是「图 + 文字」两列布局，容器不能整块居中（会破坏列），
     而 place-items 默认 normal 会把 .ph 拉成整行高。 */
  place-self: center;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  opacity: .6;
}
.thumb.no-img .ph,
.lead-img.no-img .ph { width: 46px; height: 46px; }
.slide-img.no-img .ph { width: 76px; height: 76px; }
.rec-item.no-img .ph { width: 64px; height: 46px; background: var(--surface-2); }
.split-item.no-img .ph { width: 84px; height: 60px; background: var(--surface-2); }
/* .entry .thumb（下面「文章列表」段）写了 display:block，与 .thumb.no-img 特异性相同
   （都是 0,2,0）且位置更靠后，会把上面的 grid 覆盖掉 → place-items 失效、.ph 贴顶不居中。
   这里用更高特异性（0,3,0）把居中补回来。 */
.entry .thumb.no-img { display: grid; }
.card .thumb {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 16 / 9;
}
.card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:hover .thumb img { transform: scale(1.04); }
.card h3, .topic h3, .entry h3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.card h3 { font-size: 16px; font-weight: 500; line-height: 1.5; }
.card h3 a:hover { color: var(--primary); }
.card p { font-size: 14px; color: var(--text-2); }

/* ---------- 专题策划（三栏专题卡） ---------- */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.topic {
  display: grid;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  transition: border-color .15s, transform .15s;
}
.topic:hover { border-color: var(--primary); transform: translateY(-2px); }
.topic-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 21 / 9;
}
.topic-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.topic:hover .topic-cover img { transform: scale(1.04); }
/* 没有封面图时：不渲染 <img>，这里就是一块 21/9 的中性底，角标压在上面仍然成立 */
.topic-cover.no-img { display: block; }
.topic-badge {
  position: absolute;
  left: 10px; top: 10px;
  padding: 3px 9px;
  border-radius: var(--radius-xs);
  background: rgba(0, 0, 0, .62);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  backdrop-filter: blur(4px);
}
.topic-count {
  position: absolute;
  right: 10px; bottom: 10px;
  padding: 3px 9px;
  border-radius: var(--radius-xs);
  background: rgba(0, 0, 0, .62);
  color: #fff;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.topic h3 { padding: 14px 16px 0; font-size: 16px; font-weight: 600; line-height: 1.5; }
.topic h3 a:hover { color: var(--primary); }
.topic p { padding: 0 16px; font-size: 14px; color: var(--text-2); }
.topic-foot { display: flex; align-items: center; gap: 8px; padding: 10px 16px 16px; font-size: 12px; color: var(--text-3); }
.topic-foot::after { content: "进入专题 →"; margin-left: auto; }
.topic:hover .topic-foot::after { color: var(--primary); }

/* ---------- 国际观察（大卡 + 列表分栏） ---------- */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 28px;
}
.split-lead { display: grid; gap: 10px; align-content: start; }
.split-lead .thumb {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 16 / 9;
}
.split-lead .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.split-lead:hover .thumb img { transform: scale(1.03); }
.split-lead h3 { font-size: 20px; font-weight: 600; line-height: 1.45; }
.split-lead h3 a:hover { color: var(--primary); }
.split-lead p { font-size: 14px; color: var(--text-2); }
.split-list { display: grid; gap: 4px; align-content: start; }
.split-item {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 12px;
  padding: 10px;
  border-radius: var(--radius-sm);
  transition: background .15s;
}
.split-item:hover { background: var(--surface-2); }
.split-item img { width: 84px; height: 60px; object-fit: cover; border-radius: var(--radius-xs); background: var(--surface-2); }
.split-item-b { display: grid; gap: 6px; align-content: center; min-width: 0; }
.split-item-b b { font-size: 14px; font-weight: 500; line-height: 1.55; }
.split-item:hover .split-item-b b { color: var(--primary); }
.split-item-b em { font-style: normal; font-size: 12px; color: var(--text-3); }

/* ---------- 信息流（加载更多） ---------- */
.feed { display: grid; }
.feed .entry-body { min-width: 0; }
.feed-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-top: 22px;
}
.feed-more .btn { min-width: 168px; }
.feed-tip { font-size: 12px; color: var(--text-3); }
.feed-more .btn[disabled] { opacity: .55; cursor: default; }

/* 横向图文条目（列表页 / 侧栏复用） */
.entry {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.entry:last-child { border-bottom: 0; }
.entry img { width: 180px; height: 116px; object-fit: cover; border-radius: var(--radius-sm); background: var(--surface-2); }
.entry .thumb { position: relative; display: block; border-radius: var(--radius-sm); overflow: hidden; }
.entry h3 { font-size: 18px; font-weight: 600; line-height: 1.45; margin-bottom: 6px; }
.entry h3 a:hover { color: var(--primary); }
.entry p { font-size: 14px; color: var(--text-2); margin-bottom: 8px; }

/* ---------- 侧栏组件 ---------- */
.widget {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.widget h2,
.widget h3,
.widget h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 15px;
}
.widget h2::before,
.widget h3::before,
.widget h4::before {
  content: "";
  width: 3px; height: 14px;
  border-radius: 2px;
  background: var(--primary);
}
/* 侧栏头部（标题 + 右侧补充信息） */
.widget-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.widget-head h2,
.widget-head h3,
.widget-head h4 { margin-bottom: 0; }
.widget-sub { margin-left: auto; font-size: 12px; color: var(--text-3); }

/* 24 小时热榜：榜首大卡 + 紧凑行 */
.rank { display: grid; gap: 4px; margin: 0 -8px; }
.rank li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 8px;
  padding: 7px 8px;
  border-radius: var(--radius-sm);
  transition: background .15s;
}
.rank li:nth-child(-n+4) { background: var(--surface-2); }
.rank li:hover { background: var(--surface-2); }
.rank .num {
  display: grid;
  place-items: center;
  width: 20px; height: 20px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}
.rank li:nth-child(-n+4) .num {
  border-color: transparent;
  background: linear-gradient(135deg, var(--danger), #ff8a4c);
  color: var(--on-danger);
}
.rank a { font-size: 14px; line-height: 1.55; }
.rank li:nth-child(-n+4) a { font-weight: 500; }
.rank a:hover { color: var(--primary); }
.rank .hot { font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* 榜首大卡 */
.rank-lead {
  display: block !important;
  margin-bottom: 8px;
  padding: 0 !important;
  border-radius: var(--radius);
  overflow: hidden;
  background: transparent !important;
}
.rank-lead:hover { background: transparent !important; }
.lead-img {
  position: relative;
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 16 / 9;
}
.lead-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.rank-lead:hover .lead-img img { transform: scale(1.04); }
.lead-img .num {
  position: absolute;
  left: 10px; top: 10px;
  width: 26px; height: 26px;
  border-radius: 8px;
  font-size: 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .28);
}
.lead-title {
  display: block;
  margin-top: 10px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
}
.rank-lead:hover .lead-title { color: var(--primary); }
.lead-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
  font-size: 12px;
  color: var(--text-3);
}
.lead-sub em { font-style: normal; color: var(--danger); font-variant-numeric: tabular-nums; }
.lead-sub span { padding-left: 8px; border-left: 1px solid var(--border); }

/* 编辑推荐 */
.rec { display: grid; gap: 12px; margin: 0 -6px; }
.rec-item {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 10px;
  padding: 6px;
  border-radius: var(--radius-sm);
  transition: background .15s;
}
.rec-item:hover { background: var(--surface-2); }
.rec-item img { width: 64px; height: 46px; object-fit: cover; border-radius: var(--radius-xs); background: var(--surface-2); }
.rec-b { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; min-width: 0; }
.rec-b b { font-size: 13.5px; font-weight: 500; line-height: 1.5; }
.rec-item:hover .rec-b b { color: var(--primary); }
.rec-b em { font-style: normal; font-size: 12px; color: var(--text-3); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  padding: 5px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg);
  font-size: 13px;
  color: var(--text-2);
  transition: all .15s;
}
.tag:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: var(--on-primary);
  font-size: 14px;
  cursor: pointer;
  transition: opacity .15s;
}
.btn:hover { opacity: .88; }
.btn.ghost { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn.ghost:hover { border-color: var(--primary); color: var(--primary); }

/* ---------- 面包屑 ---------- */
.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 0 0;
  font-size: 13px;
  color: var(--text-3);
}
.crumbs a:hover { color: var(--primary); }

/* ---------- 文章页 ---------- */
.article { padding-top: 20px; }
.article-head { margin-bottom: 22px; }
.article-head h1 { font-size: 34px; line-height: 1.35; margin: 12px 0 14px; }
.article-hero { margin: 0 0 26px; }
.article-hero img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--surface-2);
}
.article-hero figcaption { margin-top: 10px; font-size: 13px; color: var(--text-3); }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  color: var(--text-3);
}
.article-meta .author { color: var(--text); font-weight: 500; }
.share { display: flex; gap: 8px; margin-left: auto; }

.progress {
  position: fixed;
  top: 0; left: 0;
  z-index: 60;
  height: 2px;
  width: 0;
  background: var(--primary);
}

.body-text {
  font-size: 17px;
  line-height: 1.85;
  color: var(--text);
  overflow-wrap: break-word;   /* 正文里的长 URL / 无空格串不至于把页面撑出横向滚动 */
}
.body-text > * + * { margin-top: 18px; }
.body-text h2 {
  margin-top: 36px;
  padding-left: 13px;
  border-left: 3px solid var(--primary);
  font-size: 24px;
  letter-spacing: .2px;
}
.body-text p { color: var(--text); }
.body-text blockquote {
  padding: 14px 18px;
  border-left: 3px solid var(--border-strong);
  background: var(--surface);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-2);
  font-size: 15px;
}
.body-text figure img { width: 100%; border-radius: var(--radius-sm); background: var(--surface-2); }
.body-text figcaption { margin-top: 8px; font-size: 13px; color: var(--text-3); text-align: center; }

.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-sm); background: var(--surface-2); }

/* ===========================================================
   正文组件库：覆盖新闻 / 技术报道常用的全部 HTML 元素
   =========================================================== */

/* ---------- 三级小标题 ---------- */
.body-text h3 {
  margin-top: 26px;
  padding-left: 12px;
  border-left: 3px solid var(--border-strong);
  font-size: 19px;
  font-weight: 600;
  line-height: 1.5;
}

/* ---------- 列表：marker 用主色，数字等宽 ---------- */
.body-text ul { padding-left: 22px; list-style: disc; }
.body-text ol { padding-left: 24px; list-style: decimal; }
.body-text li { margin-bottom: 6px; }
.body-text li::marker { color: var(--primary); font-weight: 600; }
.body-text ol li::marker { font-variant-numeric: tabular-nums; }

/* ---------- 行内语义元素 ---------- */
.body-text code {
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--surface-2);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: .88em;
}
/* 代码块里的 code 走深底，不能继承行内 code 的浅色底 */
.body-text pre code {
  padding: 0;
  border-radius: 0;
  background: none;
  font-size: inherit;
}
.body-text mark {
  padding: 1px 3px;
  border-radius: 3px;
  background: var(--mark);
  color: var(--mark-text);
}
.body-text kbd {
  display: inline-block;
  min-width: 20px;
  padding: 2px 6px;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--surface);
  font-size: .82em;
  line-height: 1.4;
  text-align: center;
}
.body-text abbr[title] {
  text-decoration: underline dotted var(--text-3);
  text-underline-offset: 3px;
  cursor: help;
}
.body-text sup { font-size: .72em; line-height: 0; }
.body-text sup a {
  padding: 0 4px;
  border-radius: 3px;
  background: var(--primary-soft);
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}
.body-text sup a:hover { background: var(--primary); color: var(--on-primary); }

/* ---------- 代码块（固定深底，明暗主題下都可读） ---------- */
.codeblock {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--code-bg);
  overflow: hidden;
}
.cb-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 10px 5px 14px;   /* 收紧，抵消 .cb-copy 30→32 的增量，头部总高不变 */
  border-bottom: 1px solid var(--code-line);
}
.cb-lang {
  font-family: "SFMono-Regular", Consolas, Menlo, monospace;
  font-size: 11.5px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--code-dim);
}
.cb-copy {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;                 /* 与 .act / .follow 同为二级控件高度档 */
  padding: 0 11px;
  border: 1px solid var(--code-line);
  border-radius: var(--radius-xs);
  background: transparent;
  font-size: 12px;
  color: var(--code-dim);
  cursor: pointer;
  transition: color .15s, border-color .15s;
}
.cb-copy:hover { color: #fff; border-color: rgba(255, 255, 255, .3); }
.codeblock pre {
  margin: 0;
  padding: 14px 16px;
  overflow-x: auto;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 13.5px;
  line-height: 1.8;
  tab-size: 2;
  color: var(--code-text);
}
/* 极简语法着色：只标注四类 token，够用且两个主题下都达标 */
.codeblock .k { color: #9fd0ff; }
.codeblock .s { color: #b7e08a; }
.codeblock .n { color: #f0b37e; }
.codeblock .b { color: #d8a2ff; }
.codeblock .c { color: #9a9080; font-style: italic; }

/* ---------- Mermaid 图表 ---------- */
.chart-box {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  overflow-x: auto;
}
.chart-box .mermaid {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
}
.chart-box .mermaid svg { max-width: 100%; height: auto; }
.chart-loading,
.chart-error {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 22px 0;
  font-size: 13px;
  color: var(--text-3);
}
.chart-loading .dot {
  flex: none;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--primary);
  animation: livePulse 1.6s ease-out infinite;
}
.chart-error { color: var(--danger); }
/* 降级：渲染失败时把源码原样展示，读者不至于看到空白 */
.chart-box .mermaid.chart-fallback {
  justify-content: flex-start;
  overflow-x: auto;
}
.chart-box .mermaid.chart-fallback pre {
  margin: 0;
  font-family: "SFMono-Regular", Consolas, Menlo, monospace;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-2);
  white-space: pre;
}

/* ---------- 折叠块 details / summary ---------- */
.fold {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
}
.fold + .fold { margin-top: 10px; }
.fold > summary {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 12px 15px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::before {
  content: "\25B8";
  flex: none;
  color: var(--text-3);
  font-size: 13px;
  transition: transform .18s;
}
.fold[open] > summary::before { transform: rotate(90deg); }
.fold > summary:hover { color: var(--primary); }
.fold > summary:hover::before { color: var(--primary); }
.fold-body {
  padding: 12px 15px 15px;
  border-top: 1px solid var(--border);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-2);
}
.fold-body > * + * { margin-top: 10px; }

/* ---------- 提示框 note（4 种语义色） ---------- */
.note {
  display: flex;
  gap: 11px;
  padding: 13px 16px;
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--note-bg);
  font-size: 15px;
  line-height: 1.75;
}
.note::before {
  content: "i";
  flex: none;
  width: 20px; height: 20px;
  margin-top: 2px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; font-style: italic;
}
.note.info   { --accent: var(--primary); --note-bg: var(--primary-soft); }
.note.ok     { --accent: var(--ok);      --note-bg: var(--ok-soft); }
.note.warn   { --accent: var(--warn);    --note-bg: var(--warn-soft); }
.note.danger { --accent: var(--danger);  --note-bg: var(--danger-soft); }
.note.ok::before     { content: "\2713"; font-style: normal; }
.note.warn::before   { content: "!"; font-style: normal; }
.note.danger::before { content: "!"; font-style: normal; }
.note-b { min-width: 0; }
.note-t { font-weight: 600; color: var(--accent); }
.note p + p { margin-top: 4px; }

/* ---------- 并排对比图 ---------- */
.fig-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.fig-2 img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.fig-2 figcaption { margin-top: 8px; font-size: 13px; color: var(--text-3); text-align: left; }
.video figcaption { margin-top: 10px; font-size: 13px; color: var(--text-3); text-align: left; }

/* ---------- 视频占位 ---------- */
.video-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
}
.video-cover img { width: 100%; height: 100%; object-fit: cover; }
.video-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 12, 16, .6), rgba(10, 12, 16, .04));
}
.play {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: 62px; height: 62px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .94);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(10, 12, 16, .3);
  transition: transform .2s;
}
.play:hover { transform: translate(-50%, -50%) scale(1.06); }
.play:focus-visible { box-shadow: var(--ring); }
.play svg { margin-left: 3px; }
.video-meta {
  position: absolute;
  left: 16px; bottom: 13px;
  z-index: 1;
  color: rgba(255, 255, 255, .92);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

/* ---------- 表格增强：横向滚动 / 合计行 / 状态徽标 ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table tfoot td,
.data-table tfoot th {
  background: var(--surface-2);
  font-weight: 600;
  color: var(--text);
  border-bottom: 0;
}
.data-table th.num,
.data-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.pill {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.pill.pos { background: var(--ok-soft); color: var(--ok); }
.pill.neg { background: var(--danger-soft); color: var(--pill-neg); }
.pill.neu { background: var(--surface-2); color: var(--text-2); }

/* ---------- 脚注 ---------- */
.footnotes {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  line-height: 1.8;
  color: var(--text-3);
}
.footnotes h4 { font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 6px; }
.footnotes ol { padding-left: 20px; list-style: decimal; }
.footnotes li { margin-bottom: 5px; }
.footnotes li::marker { font-variant-numeric: tabular-nums; }
.footnotes .backref { color: var(--primary); }

.source-note {
  margin-top: 26px;
  padding: 12px 14px;
  border-left: 3px solid var(--border-strong);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface);
  font-size: 13px;
  line-height: 1.8;
  color: var(--text-3);
}
.source-note b { color: var(--text-2); font-weight: 500; }

.article-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; padding-top: 24px; border-top: 1px solid var(--border); }

.prevnext {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 26px;
}
.prevnext a {
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: 14px;
  line-height: 1.6;
  transition: border-color .15s, background .15s;
}
.prevnext a:hover { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); }
.prevnext a:last-child { text-align: right; }
.prevnext .label { display: block; font-size: 12px; color: var(--text-3); margin-bottom: 4px; }
.prevnext a:hover .label { color: var(--primary); }

/* 目录 */
.toc { display: grid; gap: 8px; }
.toc a {
  padding-left: 12px;
  border-left: 2px solid var(--border);
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.6;
}
.toc a:hover, .toc a.active { border-left-color: var(--primary); color: var(--primary); }
.toc a.sub { padding-left: 24px; font-size: 13px; color: var(--text-3); }

/* ---------- 评论 ---------- */
.comments { margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--border); }
.comments h3 { font-size: 19px; margin-bottom: 18px; }
.comment-form { display: grid; gap: 12px; margin-bottom: 28px; }
.comment-form textarea {
  min-height: 92px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  resize: vertical;
  outline: none;
  line-height: 1.6;
}
.comment-form textarea:focus { border-color: var(--primary); box-shadow: var(--ring); }
.comment-form .row { display: flex; gap: 10px; align-items: center; }
.comment-form input {
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  outline: none;
}
.comment-form .row .btn { margin-left: auto; }

.comment-list { display: grid; gap: 20px; }
.comment { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
.avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--primary-soft);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 500;
}
.comment .head { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.comment .head .name { font-weight: 500; }
.comment .head time { font-size: 12px; color: var(--text-3); }
.comment .text { margin-top: 4px; font-size: 15px; }
.comment .actions { display: flex; gap: 14px; margin-top: 8px; font-size: 13px; color: var(--text-3); }
.comment .actions button {
  border: 0; background: none; padding: 0; cursor: pointer;
  font-size: 13px; color: var(--text-3);
}
.comment .actions button:hover { color: var(--primary); }
.comment .replies {
  margin-top: 14px;
  padding-left: 14px;
  border-left: 2px solid var(--border);
  display: grid;
  gap: 14px;
}
.comment .replies .comment { grid-template-columns: 32px minmax(0, 1fr); }
.comment .replies .avatar { width: 32px; height: 32px; font-size: 13px; }

/* ---------- 分页 ---------- */
.pager { display: flex; justify-content: center; gap: 8px; margin-top: 36px; }
.pager a, .pager span {
  min-width: 38px; height: 38px;
  padding: 0 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text-2);
}
.pager a:hover { border-color: var(--primary); color: var(--primary); }
.pager .current { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.pager .disabled { opacity: .45; cursor: not-allowed; }

/* 兼容 DedeBIZ {dede:pagelist} 的输出结构：<li class="page-item"><a/span class="page-link">
   上面的 .pager a/.pager span 规则管不到 li 里的元素，这里按同一套视觉补齐。 */
.pager { flex-wrap: wrap; padding: 0; }
.pager li { list-style: none; }
.pager li.page-item > a,
.pager li.page-item > span {
  min-width: 38px; height: 38px; padding: 0 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text-2);
  text-decoration: none;
}
.pager li.page-item > a:hover { border-color: var(--primary); color: var(--primary); }
.pager li.page-item.active > span { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.pager li.page-item.disabled > span { opacity: .45; cursor: not-allowed; }
.pager select {
  height: 38px; padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text-2);
  font-size: 14px;
}

/* 频道页筛选条 */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}
.filters .chip {
  padding: 6px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 14px;
  color: var(--text-2);
  cursor: pointer;
}
.filters .chip.active { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
/* ---------- 频道页头部 ---------- */
.page-head {
  position: relative;
  padding-left: 16px;
  margin: 8px 0 18px;
}
.page-head::before {
  content: "";
  position: absolute;
  left: 0; top: 5px; bottom: 5px;
  width: 4px;
  border-radius: 2px;
  background: var(--accent, var(--primary));
}
.page-title { font-size: 28px; margin: 0 0 6px; letter-spacing: -.3px; }
.page-desc { font-size: 14px; color: var(--text-2); margin-bottom: 10px; }
.page-stat {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 13px;
  color: var(--text-3);
}
.page-stat b {
  color: var(--text);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.entries + .section-head, .entry-compact + .section-head { margin-top: 34px; }
/* ---------- 相关专题（卡片式） ---------- */
.wtopic-list { display: grid; gap: 10px; }
.wtopic {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 14px;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
  transition: border-color .18s, background .18s, transform .18s, box-shadow .18s;
}
/* 悬停时左侧亮起一道渐变色条 */
.wtopic::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--danger), #ff8a4c);
  opacity: 0;
  transition: opacity .18s;
}
.wtopic:hover {
  border-color: var(--border-strong);
  background: var(--surface-2);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .07);
}
.wtopic:hover::before { opacity: 1; }
.wt-n {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.4px;
  color: var(--danger);
  font-variant-numeric: tabular-nums;
  opacity: .85;
}
/* minmax(0,1fr) 而非隐式 auto 列：否则极端长串会把 min-content 顶上来撑破卡片 */
.wt-body { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.wt-body b {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
}
.wtopic:hover .wt-body b { color: var(--primary); }
.wt-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 12px;
  color: var(--text-3);
}
.wt-meta > * { min-width: 0; overflow-wrap: anywhere; }
.wt-meta em { font-style: normal; font-weight: 500; color: var(--text-2); }
.wt-meta .sep { width: 1px; height: 10px; background: var(--border); }
.wt-arrow {
  flex: none;
  color: var(--text-3);
  opacity: 0;
  transform: translateX(-3px);
  transition: opacity .18s, transform .18s, color .18s;
}
.wtopic:hover .wt-arrow { opacity: 1; transform: none; color: var(--primary); }

.filter-sep { flex: none; width: 1px; height: 18px; background: var(--border); margin: 0 2px; }
.pager-info { margin-left: 10px; font-size: 12px; color: var(--text-3); align-self: center; }

/* =========================================================
   文章页尾部「最新更新」——支持两种加载形式：
   ① 无限滚动（IntersectionObserver 命中哨兵自动加载）
   ② 点击「加载更多」手动加载
   两者共用同一套分页状态，可随时用顶部的开关切换。
   ========================================================= */
/* 不能用 inline-flex：flex 容器的基线取自第一个子项，而第一个子项是 checkbox
   （基线＝盒子下边缘），结果开关整体比标题基线高 7px。
   改回普通行内排列，label 的基线就是文字基线（作为 flex item 会被 blockify）。 */
.stream-switch {
  margin-left: auto;
  font-size: 12px;
  font-weight: 400;
  color: var(--text-3);
  cursor: pointer;
  user-select: none;
}
.stream-switch input {
  width: 14px; height: 14px;
  margin: 0 5px 0 0;
  vertical-align: -2px;
  accent-color: var(--primary);
}
.stream-switch:hover { color: var(--text-2); }

.stream-list { display: grid; }
.stream-item {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.stream-item:last-child { border-bottom: 0; }
.si-time {
  padding-top: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.si-body { min-width: 0; display: grid; gap: 6px; }
.si-body h3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.si-body h3 a:hover { color: var(--primary); }
.si-body .meta { font-size: 12px; gap: 6px; }

.stream-foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-top: 18px;
}
.stream-tip {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-3);
}
.stream-tip.is-loading::before {
  content: "";
  width: 11px; height: 11px;
  border: 2px solid var(--border-strong);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: skSpin .7s linear infinite;
}
.stream-tip.is-end { color: var(--text-3); letter-spacing: .3px; }
.stream-sentinel { width: 100%; height: 1px; }
@keyframes skSpin { to { transform: rotate(360deg); } }

/* =========================================================
   数据条（首页「今日关键数字」/ 频道页「频道数据」）
   ========================================================= */
.databar {
  margin-top: 24px;
  padding: 20px 24px 4px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.databar.compact {
  margin: 0 0 22px;
  padding: 18px 20px 2px;
}
.db-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 14px;
}
.db-head h2 { font-size: 15px; font-weight: 600; }
.db-sub { margin-left: auto; font-size: 12px; color: var(--text-3); }
.db-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
}
.databar.compact .db-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.db-cell {
  display: grid;
  align-content: start;
  gap: 3px;
  padding: 0 16px 18px 0;
  min-width: 0;
}
.db-cell + .db-cell { padding-left: 16px; border-left: 1px solid var(--border); }
.db-n {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -.6px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.db-n i { font-style: normal; font-size: 14px; font-weight: 600; margin-left: 2px; color: var(--text-2); }
.db-t { font-size: 13px; color: var(--text-2); }
.db-d {
  font-size: 12px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}
/* 涨跌遵循国内习惯：涨＝红，跌＝绿 */
.db-d.up { color: var(--danger); }
.db-d.down { color: var(--ok); }

/* ---------- 观点（引用卡） ---------- */
.opinion-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.op-card {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 18px 20px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.op-card::before {
  content: "\201C";
  position: absolute;
  left: 14px; top: 4px;
  font-size: 44px;
  line-height: 1;
  color: var(--primary);
  opacity: .22;
}
.op-card blockquote {
  margin: 0;
  font-size: 15px;
  line-height: 1.75;
  color: var(--text);
}
.op-by {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-3);
}
.op-by .ava { color: var(--text-2); font-weight: 500; }

/* ---------- 往期归档 ---------- */

/* ---------- 延伸阅读 · 问答（复用 .fold） ---------- */
.qa .fold { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.qa .fold + .fold { margin-top: 8px; }
.qa .fold > summary { padding: 13px 16px; background: var(--surface); }
.qa .fold[open] > summary { border-bottom: 1px solid var(--border); }
.qa .fold-body { padding: 12px 16px 14px; }
.qa .fold-body p { font-size: 15px; line-height: 1.8; color: var(--text-2); }

/* ---------- 回到顶部 ---------- */
.to-top {
  position: fixed;
  right: 26px; bottom: 26px;
  z-index: 70;
  display: grid;
  place-items: center;
  width: 42px; height: 42px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-2);
  box-shadow: 0 4px 16px rgba(0, 0, 0, .12);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .2s, transform .2s, visibility .2s, color .15s, border-color .15s;
}
.to-top.is-show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { color: var(--primary); border-color: var(--primary); }
.to-top:focus-visible { outline: none; box-shadow: var(--ring); }

/* 加载中骨架 */
.skeleton { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.skeleton i {
  display: block;
  border-radius: var(--radius-xs);
  background: linear-gradient(90deg, var(--surface-2) 25%, var(--border) 37%, var(--surface-2) 63%);
  background-size: 400% 100%;
  animation: skShimmer 1.2s ease-in-out infinite;
}
.skeleton i:nth-child(1) { height: 14px; }
.skeleton i:nth-child(2) { height: 14px; width: 62%; }
.skeleton:last-child { border-bottom: 0; }
/* 首页信息流用的骨架：左图右文，与 .entry 同构 */
.skeleton.sk-entry {
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 16px;
  padding: 18px 0;
}
.skeleton.sk-entry i:nth-child(1) { height: 116px; }
.skeleton.sk-entry i:nth-child(2) { height: 16px; width: 78%; }
@keyframes skShimmer {
  0%   { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}
@media (prefers-reduced-motion: reduce) {
  .skeleton i { animation: none; }
  .stream-tip.is-loading::before { animation-duration: 2s; }
}

/* 筛选切换后列表淡入，让「点了有反应」 */
.is-swap { animation: swapIn .28s ease; }
@keyframes swapIn {
  from { opacity: .3; transform: translateY(4px); }
  to   { opacity: 1; transform: none; }
}

/* 交互态：点赞 / 收藏 / 关注 */
[data-like].is-on, [data-collect].on { color: var(--primary); border-color: var(--primary); }
[data-like].is-on svg, [data-collect].on svg { fill: currentColor; }
.follow.on {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text-2);
}

/* 新发布的评论短暂高亮 */
.comment.is-new { animation: cmtIn .5s ease; }
@keyframes cmtIn {
  from { background: var(--primary-soft); }
  to   { background: transparent; }
}

/* =========================================================
   文本长度兜底
   规则：标题一律 2 行截断，摘要 2 行，单行型元信息省略号，
   所有可能出现长串（URL / 无空格英文 / 长数字）的地方强制断行。
   ========================================================= */
.clamp-1, .clamp-2, .clamp-3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.clamp-1 { -webkit-line-clamp: 1; }
.clamp-2 { -webkit-line-clamp: 2; }
.clamp-3 { -webkit-line-clamp: 3; }

/* 标题类 */
.card h3, .topic h3, .entry h3,          /* 已有 clamp-2 */
.split-lead h3, .rec-b b, .lead-title,
.slide-body h1, .wt-body b, .toc a,
.prevnext a, .rank a, .entries h3 {
  overflow-wrap: anywhere;
}
.split-lead h3, .rec-b b, .lead-title, .toc a, .prevnext a, .rank a {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.rank a { -webkit-line-clamp: 1; }        /* 榜单是单行紧凑行 */
.toc a  { -webkit-line-clamp: 1; }

/* 摘要类 */
.card p, .entry p, .topic p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  overflow-wrap: anywhere;
}

/* 单行元信息：宁可省略号，不要换行把行高撑开 */
.rec-b em, .lead-sub, .widget-sub, .brief-item a, .comment .head .name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.brief-item a { display: block; }

/* 标签 / 徽标：再长的词也不许把容器顶开 */
.tag, .badge, .pill {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 用户生成内容（评论）可长，但必须能断行 */
.comment .text, .comment .name, .fold-body, .note { overflow-wrap: anywhere; }

/* 兜底：任何容器都不允许被不可断的长串撑破 */
.main, .sidebar, .card-grid, .entry-body, .widget, .hero-side, .brief-grid { min-width: 0; }
.article-head h1, .lede, .footnotes li, .figcaption, .source-note,
.crumbs, .toc a, .wt-n, .si-time, .pager-info, .filter { overflow-wrap: anywhere; }

/* ---------- 页脚 ---------- */
.footer {
  margin-top: 44px;
  padding: 44px 0 28px;
  border-top: 1px solid var(--border);   /* 与 topbar / nav 的分隔线保持同一语言 */
  background: var(--footer-bg);
  color: var(--footer-text);
}
.footer h2 { color: #fff8ec; }
.footer-logo { display: block; width: 111px; height: 26px; }
.footer li, .footer .about { color: var(--footer-text); }
.footer a:hover { color: #fff; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
}
.footer h2 { margin: 0 0 12px; font-size: 14px; font-weight: 600; }
.footer-brand { margin: 0 0 12px; }
.footer li { margin-bottom: 8px; font-size: 14px; }
.footer li a:hover { color: #fff; }
.footer .about { font-size: 14px; }
.footer-bottom {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- 频道色徽标 ---------- */
.b-yaowen  { background: color-mix(in srgb, var(--c-yaowen) 12%, transparent);  color: var(--c-yaowen); }
.b-keji    { background: color-mix(in srgb, var(--c-keji) 12%, transparent);    color: var(--c-keji); }
.b-caijing { background: color-mix(in srgb, var(--c-caijing) 14%, transparent); color: var(--c-caijing); }
.b-guoji   { background: color-mix(in srgb, var(--c-guoji) 12%, transparent);   color: var(--c-guoji); }
.b-shehui  { background: color-mix(in srgb, var(--c-shehui) 12%, transparent);  color: var(--c-shehui); }
.b-wenhua  { background: color-mix(in srgb, var(--c-wenhua) 12%, transparent);  color: var(--c-wenhua); }
.b-nengyuan{ background: color-mix(in srgb, var(--c-nengyuan) 12%, transparent);color: var(--c-nengyuan); }

.accent-yaowen  { --accent: var(--c-yaowen); }
.accent-keji    { --accent: var(--c-keji); }
.accent-caijing { --accent: var(--c-caijing); }
.accent-guoji   { --accent: var(--c-guoji); }
.accent-shehui  { --accent: var(--c-shehui); }
.accent-wenhua  { --accent: var(--c-wenhua); }
.accent-nengyuan { --accent: var(--c-nengyuan); }

/* ---------- 栏目 eyebrow ---------- */
.kicker {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .18em;
  color: var(--accent, var(--primary));
}

/* ---------- 缩略图上的角标（视频/图集/头条/时长） ---------- */
.thumb .flag {
  position: absolute;
  left: 10px; top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: var(--radius-xs);
  background: rgba(10, 12, 16, .62);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  backdrop-filter: blur(3px);
}
.thumb .flag svg { flex: none; }
.thumb .flag.hot { left: 0; top: 0; border-radius: 0 var(--radius-xs) var(--radius-xs) 0; background: var(--danger); }
.thumb .flag.dur { left: auto; top: auto; right: 10px; bottom: 10px; font-variant-numeric: tabular-nums; }
.thumb .cat {
  position: absolute;
  left: 10px; bottom: 10px;
  padding: 3px 9px;
  border-radius: var(--radius-xs);
  background: var(--cat, var(--primary));
  color: var(--on-cat);
  font-size: 12px;
  font-weight: 500;
}

/* ---------- 元信息里的迷你头像 ---------- */
.meta .ava { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); }
.meta .ava i {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #8a6bff);
  color: transparent;
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ---------- 要闻速览（无图紧凑条） ---------- */
.brief {
  margin-top: 24px;
  padding: 4px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.brief-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0 4px;
  font-size: 15px;
  font-weight: 600;
}
.brief-head .sub { font-size: 12px; font-weight: 400; color: var(--text-3); }
.brief-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 36px;
}
.brief-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 11px 0;
  border-top: 1px dashed var(--border);
  font-size: 14px;
}
/* 不能用 inline-flex + align-items:center：flex 容器的基线取自第一个参与基线
   对齐的子项，而第一个子项是 ::before 那个 5px 圆点（没有文字，基线按盒子下边缘
   合成），结果是「要闻」二字比右侧标题低 2.5px。改成 inline-block + vertical-align
   后，父元素基线仍是文字基线，与标题天然对齐。 */
.brief-item .dotcat {
  flex: none;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.brief-item .dotcat::before {
  content: "";
  display: inline-block;
  width: 4px; height: 4px;
  margin-right: 4px;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
}
/* 没有 flag 时不写字（见 NewsBrief）：这时不能再占「圆点 + 两个字」的宽度，
   否则圆点孤零零挂在行首、和标题之间空出一大段 —— 圆点直接贴着标题 */
.brief-item .dotcat:empty::before { margin-right: 0; }
.brief-item a:hover { color: var(--primary); }
.brief-item time { margin-left: auto; flex: none; font-size: 12px; color: var(--text-3); }


/* ---------- 紧凑纯文字条目（密度对比） ---------- */
.entry-compact { padding: 2px 0; }
.entry-compact .entry {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
}
.entry-compact .entry:last-child { border-bottom: 0; }
.entry-compact .idx { flex: none; width: 22px; font-size: 13px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.entry-compact h3 { font-size: 15px; font-weight: 500; line-height: 1.6; margin: 0; }
.entry-compact h3 a:hover { color: var(--primary); }
.entry-compact time { margin-left: auto; flex: none; font-size: 12px; color: var(--text-3); }

/* ---------- 文章页：导语 / 数据卡 / 表格 / 金句 ---------- */
.lede {
  margin: 0 0 24px;
  padding: 16px 18px;
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--primary-soft);
  font-size: 17px;
  line-height: 1.85;
}
.lede strong { color: var(--primary); }

.callout {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 24px 0;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.callout .cell .n { font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; }
.callout .cell .n em { font-style: normal; font-size: 13px; font-weight: 400; color: var(--text-3); margin-left: 4px; }
.callout .cell .d { margin-top: 2px; font-size: 13px; color: var(--text-2); }
.callout .cell .up { color: var(--danger); }
.callout .cell .down { color: var(--c-nengyuan); }

.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table caption { caption-side: top; text-align: left; padding-bottom: 8px; font-size: 13px; color: var(--text-3); }
.data-table th, .data-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; }
.data-table thead th { background: var(--surface); font-size: 13px; font-weight: 500; color: var(--text-2); }
.data-table tbody tr:hover td { background: var(--surface); }

.pullquote { margin: 30px 0; text-align: center; }
.pullquote p {
  position: relative;
  display: inline-block;
  max-width: 34em;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.6;
}
.pullquote p::before,
.pullquote p::after { color: var(--primary); opacity: .45; }
.pullquote p::before { content: "“"; margin-right: 2px; }
.pullquote p::after { content: "”"; margin-left: 2px; }
.pullquote cite { display: block; margin-top: 10px; font-style: normal; font-size: 13px; color: var(--text-3); }

/* ---------- 文章页：操作条 / 作者卡 ---------- */
.follow {
  margin-left: auto;
  height: 32px;
  padding: 0 16px;
  border: 1px solid var(--primary);
  border-radius: 999px;
  background: transparent;
  color: var(--primary);
  font-size: 13px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.follow:hover { background: var(--primary); color: var(--on-primary); }

.actionbar { display: flex; gap: 10px; margin-left: auto; }
.act {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  font-size: 13px;
  color: var(--text-2);
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.act:hover { border-color: var(--primary); color: var(--primary); }
.act em { font-style: normal; font-variant-numeric: tabular-nums; }
.act.on { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }

/* 署名条：一行式，取代原来的作者资料卡。
   卡片版被右侧「186 篇 / 2.4 万 + 关注」撑到 190px，主信息只占中间一窄条，
   上下大片留白，且夹在上下篇与相关阅读之间切断阅读动线。
   这里只保留「谁写的 + 关注」，砍掉统计数字与长简介，高度 190px → 58px。 */
.author-byline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 26px;
  padding: 11px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.author-byline .avatar { width: 36px; height: 36px; font-size: 13px; }
.author-byline .who {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 10px;
  min-width: 0;
}
.author-byline .n { font-size: 15px; font-weight: 600; }
.author-byline .d { font-size: 13px; color: var(--text-3); }
.author-byline .follow { margin-left: auto; height: 32px; padding: 0 14px; font-size: 12.5px; }

/* =========================================================
   新增页面组件
   搜索页 / 标签页 / 专题页 / 404 / 作者页 / 关于 / 条款 / 联系
   ========================================================= */

/* ---------- 通用：圆形文字头像 ---------- */
.ava-round {
  flex: none;
  width: 40px; height: 40px;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 14px; font-weight: 600;
}
/* 侧栏推荐条目第一列是 64px（原为缩略图），头像居中放 */
.rec-item .ava-round { width: 44px; height: 44px; font-size: 15px; align-self: start; }

/* ---------- 搜索页 ---------- */
.search-head { padding: 6px 0 2px; }
.search-big {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 640px;
  padding: 8px 8px 8px 14px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--surface);
  transition: border-color .15s, box-shadow .15s;
}
.search-big:focus-within { border-color: var(--primary); box-shadow: var(--ring); }
.search-big > svg { flex: none; opacity: .5; }
.search-big input {
  flex: 1;
  min-width: 0;
  height: 40px;
  border: 0;
  background: none;
  outline: none;
  font-size: 16px;
}
.search-big .btn { flex: none; height: 40px; padding: 0 22px; border-radius: 999px; }
.search-meta { margin-top: 14px; font-size: 13px; color: var(--text-3); }
.search-meta b { color: var(--text); font-variant-numeric: tabular-nums; }
.search-head .filters { margin-top: 16px; }
.results { display: grid; }
/* 关键词命中高亮 */
mark {
  padding: 0 2px;
  border-radius: 2px;
  background: var(--mark);
  color: var(--mark-text);
}

/* 无结果空状态 */
.empty-state {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 54px 24px 58px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: center;
}
.es-icon {
  width: 60px; height: 60px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--surface-2);
  color: var(--text-3);
}
.empty-state h3 { font-size: 18px; }
.empty-state > p { max-width: 460px; font-size: 14px; color: var(--text-2); }
.es-tags { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 4px; }

/* ---------- 标签页头部 ---------- */
.tag-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: start;
  margin: 16px 0 4px;
  padding: 20px 0 18px;
  border-bottom: 1px solid var(--border);
}
.tag-head-main h1 {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: 30px;
  letter-spacing: -.5px;
}
.th-hash { color: var(--primary); font-weight: 700; }
.tag-desc { margin-top: 8px; max-width: 62ch; font-size: 14px; color: var(--text-2); }
.tag-stat {
  display: flex; flex-wrap: wrap; gap: 6px 18px;
  margin-top: 12px;
  font-size: 13px; color: var(--text-3);
}
.tag-stat b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.tag-head-side { display: grid; justify-items: end; gap: 8px; }
.tag-upd { font-size: 12px; color: var(--text-3); }

/* ---------- 专题页 ---------- */
/* 专题头：封面 + 压题（v26 重做，标题上封面，scrim 保证白字对比度）
   作用域坑：.topic-cover 同时被「首页专题策划卡」和「专题页 hero」使用。
   早期这里写的是裸 .topic-cover，结果把首页卡片 21/9 的封面压成了 340px 高
   （实测 249x340，设计应是 108px）。所以 hero 这一整套必须限定在 .topic-hero 下。 */
.topic-hero { margin: 16px 0 6px; }
.topic-hero .topic-cover {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
}
.topic-hero .topic-cover > img { display: block; width: 100%; height: 340px; object-fit: cover; }
.topic-hero .topic-cover::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(9, 13, 24, .95) 0%, rgba(9, 13, 24, .78) 42%, rgba(9, 13, 24, .22) 100%);
}
.topic-hero .topic-cover-body { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; padding: 26px 30px 24px; }
/* .topic-badge 在首页是 absolute 的图片角标；这里改回普通行内块并用主色底 */
.topic-hero .topic-cover-body .topic-badge { position: static; display: inline-block; margin-bottom: 12px; background: var(--primary); border-color: transparent; color: var(--on-primary); }
.topic-hero .topic-cover-body h1 { margin: 0 0 10px; font-size: 30px; line-height: 1.32; letter-spacing: -.5px; color: #fff; }
.topic-hero .topic-cover-body > p { max-width: 62ch; font-size: 14.5px; line-height: 1.75; color: rgba(255, 255, 255, .84); }
.topic-hero-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin-top: 14px;
  font-size: 13px; color: rgba(255, 255, 255, .72);
}
.topic-hero .topic-cover-body .topic-hero-meta .ava { color: rgba(255, 255, 255, .92); }
.topic-hero .topic-cover-body .topic-hero-meta .ava i { background: rgba(255, 255, 255, .24); }
/* 章节号：占用 .entry 的第一列（原缩略图列） */
.chapter {
  align-self: start;
  width: 56px; height: 56px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  font-size: 17px; font-weight: 700; letter-spacing: -.5px;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}
/* 有章节号时把首列从 180px 收成 56px（不支持 :has 时首列留白，仍可读） */
.entry:has(> .chapter) { grid-template-columns: 56px minmax(0, 1fr); }
.topic-more { display: flex; justify-content: center; padding-top: 20px; }
/* 章节号超过两位（专题篇数上百/上千）时缩小字号，56px 方块里才放得下 */
.chapter.len4 { font-size: 13px; letter-spacing: -.8px; }

/* ---------- 404 ---------- */
.nf { max-width: var(--max); margin: 0 auto; padding: 36px 20px 52px; }
.nf-inner { max-width: 680px; margin: 0 auto; text-align: center; }
.nf-code {
  font-size: 84px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -4px;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}
.nf-inner h1 { margin: 14px 0 8px; font-size: 24px; }
.nf-inner > p { font-size: 14.5px; color: var(--text-2); }
.nf-inner .search-big { margin: 22px auto 0; }
.nf-tags { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 18px; }
/* 404 频道入口（v26 新增） */
.nf-channels { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 18px; }
.nf-channels a {
  padding: 5px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: 13px;
  color: var(--text-2);
  transition: border-color .15s, color .15s;
}
.nf-channels a:hover { border-color: var(--primary); color: var(--primary); }
.nf-links {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 4px 10px;
  margin-top: 22px;
  font-size: 14px; color: var(--text-2);
}
.nf-links a:hover { color: var(--primary); }
.nf-links .sep { flex: none; width: 1px; height: 12px; background: var(--border-strong); }
.nf-latest {
  margin-top: 42px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: left;
}
/* 404 页内的 CTA 条：居中且留白收敛 */
.nf-cta { margin-top: 34px; text-align: left; }
.nf-latest h2 { margin-bottom: 12px; font-size: 17px; }

/* ---------- 作者页头部 ---------- */
.author-head {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  margin: 16px 0 4px;
  padding: 20px 0 18px;
  border-bottom: 1px solid var(--border);
}
.avatar.lg { width: 72px; height: 72px; font-size: 26px; }
.author-head-main h1 { font-size: 26px; letter-spacing: -.4px; }
.author-title { margin-top: 6px; font-size: 14px; color: var(--text-2); }
.author-bio { margin-top: 8px; max-width: 68ch; font-size: 14px; color: var(--text-2); }
.author-stat {
  display: flex; flex-wrap: wrap; gap: 6px 18px;
  margin-top: 12px;
  font-size: 13px; color: var(--text-3);
}
.author-stat b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.author-head-side { display: grid; justify-items: end; gap: 8px; }
.author-upd { font-size: 12px; color: var(--text-3); }

/* ---------- 静态页（关于 / 条款 / 联系）---------- */
.page-head h1 { font-size: 28px; margin: 0 0 6px; letter-spacing: -.3px; }
.page-head p { max-width: 68ch; font-size: 14px; color: var(--text-2); }

.static-doc { max-width: 780px; }
.static-doc > section { padding: 24px 0; border-bottom: 1px solid var(--border); }
.static-doc > section:first-child { padding-top: 8px; }
.static-doc > section:last-child { border-bottom: 0; padding-bottom: 8px; }
.static-doc h2 { margin-bottom: 12px; font-size: 20px; }
.static-doc h3 { margin: 18px 0 6px; font-size: 15.5px; }
.static-doc p { font-size: 15px; line-height: 1.85; color: var(--text-2); }
.static-doc p + p { margin-top: 10px; }
.static-doc a { color: var(--primary); text-decoration: underline; text-underline-offset: 2px; }
/* .static-doc a 是 (0,1,1)，会盖掉 .btn 的 (0,1,0) → static-doc 内的按钮链接
   变成「主色字压在实底主色上」整片看不见（about 客户端下载按钮踩过）。
   这里提权恢复，并去掉正文链接的下划线。 */
.static-doc a.btn { color: var(--on-primary); text-decoration: none; }
.static-doc a.btn.ghost { color: var(--text); }

/* 编辑部成员 */
.team-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.team-card {
  display: grid;
  justify-items: start;
  align-content: start;
  padding: 20px 20px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color .18s, transform .18s, box-shadow .18s;
}
.team-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .07);
}
.tc-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.tc-id { display: grid; gap: 2px; min-width: 0; }
.team-card .ava-round { flex: none; width: 42px; height: 42px; font-size: 16px; }
.tc-name { font-size: 16px; font-weight: 600; }
.tc-role { font-size: 12.5px; line-height: 1.6; color: var(--text-2); }
.static-doc .tc-bio { margin-top: 12px; font-size: 13.5px; line-height: 1.75; color: var(--text-2); }
.tc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.tc-tag {
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 11.5px;
  color: var(--text-2);
}
.tc-work { margin-top: 12px; min-width: 0; }
.tc-work-l { display: block; margin-bottom: 3px; font-size: 11.5px; color: var(--text-3); }
.tc-work a { font-size: 13px; line-height: 1.65; color: var(--primary); text-decoration: underline; text-underline-offset: 2px; }
.tc-foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; width: 100%;
  margin-top: auto; padding-top: 12px;
  border-top: 1px solid var(--border);
}
.tc-count { font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.app-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }

/* ---------- 关于页：品牌叙事 ---------- */
.about-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 34px;
  align-items: stretch;
  margin: 4px 0 0;
  padding: 36px 36px 38px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.ah-eyebrow { font-size: 12.5px; letter-spacing: 1.4px; color: var(--text-3); }
/* 36px 与 .doc-head h1 对齐（三静态页头部字号统一，原 42px 偏大） */
.ah-title { margin: 6px 0 0; font-size: 36px; line-height: 1.25; letter-spacing: -1px; }
.ah-claim { margin-top: 10px; font-size: 21px; font-weight: 500; color: var(--primary); }
.ah-lead { margin-top: 16px; max-width: 60ch; font-size: 16px; line-height: 1.9; color: var(--text-2); }
.ah-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.ah-chip {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 12.5px;
  color: var(--text-2);
}
.ah-mark {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 14px;
  padding: 24px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
  text-align: center;
}
.ah-mark svg { display: block; }
.ah-mark-t {
  width: 100%;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 14px; font-weight: 600; line-height: 1.6;
  color: var(--text);
}
.ah-mark-s { font-size: 11.5px; letter-spacing: .8px; color: var(--text-3); }

/* 编号小节（仅关于页） */
.about-doc { counter-reset: sec; margin-inline: auto; }
.about-doc > section { counter-increment: sec; }
.about-doc h2 { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; font-size: 22px; }
.about-doc h2::before {
  content: counter(sec, decimal-leading-zero);
  font-size: 13px; font-weight: 700; letter-spacing: .5px;
  color: var(--primary);
}

/* 我们相信 */
.value-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 16px; }
.value-card { padding: 14px 0 0; border-top: 2px solid var(--primary); }
.vc-icon {
  display: grid; place-items: center;
  width: 40px; height: 40px;
  margin-bottom: 12px;
  border-radius: var(--radius-sm);
  background: var(--primary-soft);
  color: var(--primary);
}
.value-card h3 { margin-bottom: 6px; font-size: 16px; font-weight: 600; }
.static-doc .value-card p { font-size: 13.5px; line-height: 1.8; color: var(--text-2); }

/* 里程碑时间线 */
.ms-list { margin: 6px 0 0; padding: 0; list-style: none; }
.ms-item {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 16px;
  padding: 15px 0;
  border-top: 1px solid var(--border);
}
.ms-item:last-child { padding-bottom: 0; }
.ms-year {
  font-size: 15px; font-weight: 700;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}
.ms-body b { font-size: 15px; font-weight: 600; }
.static-doc .ms-body p { margin-top: 4px; font-size: 14px; line-height: 1.8; color: var(--text-2); }

/* 数字条 */
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 16px;
  padding-top: 4px;
  border-top: 2px solid var(--border);
}
.stat { display: grid; align-content: start; gap: 4px; padding: 14px 16px 2px; min-width: 0; }
.stat:first-child { padding-left: 0; }
.stat + .stat { padding-left: 16px; border-left: 1px solid var(--border); }
.stat-n {
  font-size: 30px; font-weight: 700; line-height: 1.15;
  letter-spacing: -.8px;
  font-variant-numeric: tabular-nums;
}
.stat-n i {
  font-style: normal;
  margin-left: 2px;
  font-size: 14px; font-weight: 500;
  color: var(--text-2);
}
.stat-t { font-size: 13px; color: var(--text-2); }

/* 客户端分栏 */
.app-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 24px;
  align-items: start;
  margin-top: 14px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.as-actions {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
}
.as-actions .btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 40px; padding: 0 12px; }
.as-actions .btn svg { flex: none; }
.as-note { font-size: 12px; color: var(--text-3); text-align: center; }

/* 订阅卡 */
.sub-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  margin-top: 14px;
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.sc-text b { display: block; font-size: 15.5px; font-weight: 600; }
.static-doc .sc-text p { margin-top: 5px; font-size: 13.5px; line-height: 1.75; color: var(--text-2); }
.sub-card .field { margin-top: 0; max-width: 330px; }

/* 准则引用出处 */
/* .pullquote p 与 .static-doc p 同为 (0,1,1)，后者在后会把引用压成 15px —— 提权恢复 */
.static-doc .pullquote p { font-size: 24px; line-height: 1.6; font-weight: 600; color: var(--text); }
.pullquote .pq-src { display: block; margin-top: 14px; font-size: 13.5px; }
.pullquote .pq-src a { color: var(--primary); text-decoration: underline; text-underline-offset: 2px; }

/* 加入我们 */
.join-cta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; flex-wrap: wrap;
  margin-top: 0;
  padding: 24px 26px;
  border-radius: var(--radius);
  background: var(--primary);
}
.join-cta h2 { font-size: 19px; color: var(--on-primary); }
.join-cta p { margin-top: 5px; font-size: 14px; color: var(--on-primary); opacity: .85; }
.join-cta .btn { flex: none; background: var(--on-primary); color: var(--primary); }

/* 关于页侧栏 */
.side-p { font-size: 13px; line-height: 1.75; color: var(--text-2); }
.side-mail { display: block; margin: 12px 0 14px; font-size: 14px; font-weight: 600; color: var(--primary); }
.widget .side-mail + .btn { width: 100%; }

/* 订阅输入行 */
.field { display: flex; gap: 10px; max-width: 460px; margin-top: 14px; }
.field input {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  outline: none;
}
.field input:focus { border-color: var(--primary); box-shadow: var(--ring); }
/* 蜜罐字段：移出屏幕外（不能用 display:none —— 机器人会直接跳过隐藏字段，蜜罐就失效了） */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
/* 订阅说明小字 */
.sub-note { margin-top: 8px; font-size: 12.5px; line-height: 1.7; color: var(--text-3); }
/* 提交中：按钮置灰，避免用户以为没点上连点 */
.field .btn:disabled { opacity: .62; cursor: default; }

/* 圆点清单（联系方式 / 邮箱列表） */
.dot-list { display: grid; gap: 8px; margin-top: 12px; font-size: 14px; color: var(--text-2); }
.dot-list li { position: relative; padding-left: 16px; }
.dot-list li::before {
  content: "";
  position: absolute;
  left: 2px; top: .68em;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--primary);
  opacity: .55;
}
.dot-list b { margin-right: 2px; color: var(--text); font-weight: 600; }

/* 投稿表单 */
.contact-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; max-width: 640px; margin-top: 18px; }
.contact-form label { display: grid; gap: 6px; font-size: 13.5px; color: var(--text-2); }
.contact-form .f-full { grid-column: 1 / -1; }
.contact-form input, .contact-form textarea {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  outline: none;
  font-size: 14px;
  line-height: 1.6;
  resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--primary); box-shadow: var(--ring); }
.contact-form .btn { justify-self: start; }

/* 招聘岗位 */
.job-list { display: grid; gap: 12px; margin-top: 14px; }
.job {
  display: grid;
  gap: 8px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color .18s, box-shadow .18s;
}
.job:hover { border-color: var(--border-strong); box-shadow: 0 6px 18px rgba(0, 0, 0, .05); }
.job-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.job b { font-size: 16px; }
.job-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.job-meta span {
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 11.5px;
  color: var(--text-2);
}
.static-doc .job p { margin-top: 2px; font-size: 14px; line-height: 1.75; color: var(--text-2); }
.job-apply { flex: none; font-size: 13px; font-weight: 500; color: var(--primary); }
/* 提权重：否则会被前面的 .static-doc p(0,1,1) 盖掉，变成 15px */
.static-doc .job-tip { margin-top: 14px; font-size: 13px; line-height: 1.7; color: var(--text-3); }

/* ---------- 条款 / 联系页：文档头 ---------- */
.doc-eyebrow { font-size: 12.5px; letter-spacing: 1.4px; color: var(--text-3); }
.doc-head h1 { margin: 6px 0 0; font-size: 36px; line-height: 1.25; letter-spacing: -1px; }
.doc-lead { margin-top: 12px; max-width: 60ch; font-size: 16px; line-height: 1.9; color: var(--text-2); }
.doc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.doc-chip {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 12.5px;
  color: var(--text-2);
}

/* 编号小节：legal / contact 与 about 同一套（about 的规则在「关于页」区块） */
.legal-doc, .contact-doc { counter-reset: sec; margin-inline: auto; }
.legal-doc > section, .contact-doc > section { counter-increment: sec; }
.legal-doc h2, .contact-doc h2 { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; font-size: 22px; }
.legal-doc h2::before, .contact-doc h2::before {
  content: counter(sec, decimal-leading-zero);
  font-size: 13px; font-weight: 700; letter-spacing: .5px;
  color: var(--primary);
}

/* 小节导语：比正文深一档，作该节摘要 */
.static-doc .section-lead { margin-bottom: 4px; font-size: 15px; line-height: 1.85; color: var(--text); }

/* 条款页 h3 小节：主色短竖标记 */
.legal-doc h3 { display: flex; align-items: center; gap: 8px; margin: 22px 0 8px; font-size: 16px; }
.legal-doc h3::before {
  content: "";
  flex: none;
  width: 3px; height: 14px;
  border-radius: 2px;
  background: var(--primary);
  opacity: .55;
}

/* 联系渠道卡 */
.chan-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.chan {
  display: grid;
  gap: 6px;
  align-content: start;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color .18s, box-shadow .18s;
}
.chan:hover { border-color: var(--border-strong); box-shadow: 0 6px 18px rgba(0, 0, 0, .05); }
.chan-ic {
  display: grid; place-items: center;
  width: 34px; height: 34px;
  margin-bottom: 4px;
  border-radius: var(--radius-sm);
  background: var(--primary-soft);
  color: var(--primary);
}
.chan b { font-size: 14.5px; }
.chan a { font-size: 13px; font-weight: 500; }
.chan .chan-txt { font-size: 13px; font-weight: 500; color: var(--text); }
.static-doc .chan p { margin-top: 2px; font-size: 12.5px; line-height: 1.65; color: var(--text-3); }
.chan.secure { grid-column: 1 / -1; border-color: transparent; background: var(--primary-soft); }
.static-doc .chan.secure p { color: var(--text-2); }
.chan.secure .chan-ic { background: var(--surface); }
.chan-grid.chan-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1024px) { .chan-grid.chan-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .chan-grid.chan-4 { grid-template-columns: minmax(0, 1fr); } }

/* 侧栏：更新记录 */
.upd-list { display: grid; gap: 10px; }
.upd-list li { display: grid; gap: 3px; padding-top: 10px; border-top: 1px solid var(--border); }
.upd-list li:first-child { padding-top: 0; border-top: 0; }
.upd-list b { font-size: 12.5px; font-weight: 600; color: var(--primary); font-variant-numeric: tabular-nums; }
.upd-list span { font-size: 13px; line-height: 1.65; color: var(--text-2); }

/* 条款页侧栏 */
.toc-widget .toc { gap: 2px; }
.legal-upd { font-size: 13px; line-height: 1.75; color: var(--text-2); }

/* ---------- 新增组件响应式（放在文件末尾，确保在既有断点之后生效）---------- */
@media (max-width: 1024px) {
  .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .value-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 0; }
  .stat:nth-child(3) { padding-left: 0; border-left: 0; }
  .about-hero { grid-template-columns: minmax(0, 1fr) 200px; gap: 26px; padding: 28px 26px 30px; }
  .ah-title { font-size: 32px; }
  .ah-lead { font-size: 15px; }
  .doc-head h1 { font-size: 32px; }
  .app-split { grid-template-columns: minmax(0, 1fr); }
  .sub-card { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .tag-head, .author-head { grid-template-columns: minmax(0, 1fr); }
  .tag-head-side, .author-head-side {
    display: flex; align-items: center; gap: 12px;
    justify-items: start;
  }
  .avatar.lg { width: 56px; height: 56px; font-size: 21px; }
  .tag-head-main h1 { font-size: 24px; }
  .author-head-main h1 { font-size: 22px; }
  .topic-hero .topic-cover > img { height: 220px; }
  .topic-hero .topic-cover-body { padding: 16px 16px 14px; }
  .topic-hero .topic-cover-body h1 { font-size: 22px; }
  .topic-hero .topic-cover-body > p { font-size: 13px; }
  /* 移动端列表横排：缩略图左 + 文字右，避免全宽大图把页面拉得过长 */
  .entry { grid-template-columns: 118px minmax(0, 1fr); gap: 12px; padding: 14px 0; }
  .entry img { width: 118px; height: 88px; aspect-ratio: auto; }
  .entry h3 { font-size: 16px; }
  .entry p { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: 13px; }
  /* 横排卡片：.card 只有 118px | 1fr 两列，而 h3 / p / meta 都是 .card 的直接子元素，
     不显式指定列就会按「先左后右」交替填入 —— 摘要会被塞进 118px 的左列挤成一条窄条。
     所以这里把三块的位置写死：缩略图占左列并跨两行，标题与 meta 都落在右列。 */
  .card { grid-template-columns: 118px minmax(0, 1fr); gap: 10px 12px; align-items: start; }
  .card .thumb { grid-column: 1; grid-row: 1 / span 2; aspect-ratio: auto; height: 88px; }
  .card h3 { grid-column: 2; }
  /* 摘要在移动端隐藏：横排后右列只剩标题 + 一行 meta，再塞两行摘要会让每条都顶到 130px+，
     四个板块 24 条就把页面撑得过长 */
  .card p { display: none; }
  .card .meta { grid-column: 2; font-size: 12px; gap: 8px; }
  .nf-channels a { padding: 5px 13px; font-size: 12.5px; }
  .nf { padding: 26px 16px 40px; }
  .nf-code { font-size: 62px; letter-spacing: -2px; }
  .search-big { padding: 6px 6px 6px 12px; border-radius: var(--radius-sm); }
  .search-big input { height: 36px; font-size: 15px; }
  .search-big .btn { height: 36px; padding: 0 16px; border-radius: var(--radius-sm); }
  .team-grid { grid-template-columns: minmax(0, 1fr); }
  .value-grid { grid-template-columns: minmax(0, 1fr); }
  .about-hero { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 24px 20px 26px; }
  .ah-mark svg { width: 64px; height: 64px; }
  .ah-title { font-size: 28px; }
  .ah-claim { font-size: 17px; }
  .doc-head h1 { font-size: 28px; }
  .chan-grid { grid-template-columns: minmax(0, 1fr); }
  .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 0; }
  .stat-n { font-size: 26px; }
  .ms-item { grid-template-columns: 54px minmax(0, 1fr); gap: 12px; padding: 13px 0; }
  .join-cta { padding: 20px; }
  .join-cta .btn { width: 100%; }
  .field { flex-direction: column; }
  .static-doc h2 { font-size: 18px; }
}

/* =========================================================
   广告位（原型预留，必须可见标识）
   正式投放时把 .ad-slot 内部换成投放脚本即可，容器尺寸保持不变，
   避免素材加载前后页面跳动（CLS）。
   间距原则：不写死统一值，而是按所在容器的既有节奏给，
   并利用「相邻块级元素上下外边距合并」自动取较大值，避免和
   .section{margin-top:40px} / .layout{padding-top:24px} 叠加成双倍间距。
   ========================================================= */
.ad-slot {
  position: relative;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  width: 100%;
  padding: 20px 18px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  /* 斜纹只做极淡的底纹，避免抢正文注意 */
  background-color: var(--surface-2);
  background-image: repeating-linear-gradient(135deg,
      rgba(120, 100, 60, .055) 0 5px, transparent 5px 13px);
  text-align: center;
}
/* 左上角「广告」角标：投放合规要求必须可识别 */
.ad-slot::before {
  content: "广告";
  position: absolute;
  top: 8px; left: 10px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: 3px;
  background: var(--surface);
  font-size: 11px;
  line-height: 17px;
  /* --text-3 在 --surface / --surface-2 上分别只有 4.94 / 4.31，角标是最小的 11px，
     统一提到 --text-2（5.92 / 5.29） */
  color: var(--text-2);
}
.ad-size {
  font-size: 14px; font-weight: 600;
  color: var(--text);
  letter-spacing: .2px;
  font-variant-numeric: tabular-nums;
}
.ad-note { font-size: 12px; color: var(--text-2); }

/* ---- 间距档位 ---- */
/* 通栏：上 30、下 6。下方邻居是 .layout（padding-top:24），6+24=30，与上方对称 */
.ad-slot.banner { min-height: 96px;  margin: 30px 0 6px; }
/* 信息流 / 正文内：邻居多为 .section（margin-top:40），合并后取 40，不会翻倍 */
.ad-slot.infeed { min-height: 130px; margin: 30px 0; }
.ad-slot.intext { min-height: 140px; margin: 32px 0; }
/* 列表内：打断条目节奏，上下各留一点，比条目间距（18px padding）明显更大 */
.ad-slot.inlist { min-height: 120px; margin: 22px 0 24px; }
/* 侧栏：由 .sidebar 自身的 gap:20px 统一控制，这里不要再给 margin */
.ad-slot.rect   { min-height: 254px; margin: 0; }

/* 广告位响应式（放文件末尾，确保在既有断点之后生效） */
@media (max-width: 720px) {
  .ad-slot { padding: 16px 14px; }
  .ad-slot.banner { min-height: 76px;  margin: 22px 0 4px; }
  .ad-slot.rect   { min-height: 200px; }
  .ad-slot.infeed,
  .ad-slot.intext,
  .ad-slot.inlist { min-height: 112px; }
  .ad-slot.infeed,
  .ad-slot.intext { margin: 24px 0; }
  .ad-slot.inlist { margin: 18px 0 20px; }
}

/* 仅供屏幕阅读器 / 搜索引擎，视觉上不可见 */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ---------- 降低动效（晕动症友好） ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .ticker-track { animation: none; }
  /* Toast 依赖 animation 的 forwards 终态显示，动效被禁用时要兜住可见性 */
  .c-message.is-in { opacity: 1; transform: translateX(-50%); }
  .c-message.is-out { opacity: 0; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  /* 单列下正文不再 780px 居中：否则与页头/侧栏左缘错位 80px+（实测 1024 时 x=104 vs 20） */
  .static-doc { max-width: none; margin-inline: 0; }
  .sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* 两列断点下：广告位与组件区都要独占整行，
     否则广告占半格、组件区再被切成两列（实测 widget 只有 226px） */
  .sidebar > .ad-slot { grid-column: 1 / -1; }
  .sidebar-sticky {
    grid-column: 1 / -1;
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  /* 矩形位此时横跨整行，254px 高的大盒子不好看，压成通栏比例 */
  .ad-slot.rect { min-height: 132px; }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .card-grid, .topic-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .db-grid, .databar.compact .db-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: grid;
    position: absolute;
    top: var(--nav-h);
    left: 0; right: 0;
    padding: 10px 20px 16px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    gap: 2px;
  }
  .nav-toggle { display: inline-flex; }
  .search { flex: 1; }
  .sidebar { grid-template-columns: minmax(0, 1fr); }
  .sidebar-sticky { grid-template-columns: minmax(0, 1fr); }
  .carousel-arrow { display: none; }
  .slide-body { padding: 40px 18px 18px; }
  .slide-body h1 { font-size: 19px; }
  .slide-body p { display: none; }
  .slide-meta { margin-top: 8px; }
  .card-grid, .gallery, .prevnext, .callout, .brief-grid, .topic-grid, .fig-2 { grid-template-columns: minmax(0, 1fr); }
  .split-lead h3 { font-size: 18px; }
  .section-head .head-sub { display: none; }
  .feed-more { flex-direction: column; }
  .feed-more .btn { width: 100%; }
  .author-byline { flex-wrap: wrap; }
  .author-byline .d { flex-basis: 100%; }
  .prevnext a:last-child { text-align: left; }
  .actionbar { margin-left: 0; width: 100%; }
  .article-meta { gap: 10px; }
  .entry { grid-template-columns: minmax(0, 1fr); }
  .entry img { width: 100%; height: auto; aspect-ratio: 16 / 9; }
  .hero-main h1 { font-size: 23px; }
  .article-head h1 { font-size: 26px; }
  .body-text { font-size: 16px; }
  .body-text h2 { font-size: 20px; margin-top: 28px; }
  .body-text h3 { font-size: 17px; margin-top: 22px; }
  .chart-box { padding: 12px; }
  .codeblock pre { font-size: 12.5px; padding: 12px; }
  .lede { font-size: 16px; }
  .pullquote p { font-size: 20px; }
  .pullquote { margin: 24px 0; }
  /* 移动端：实用条整条收起，品牌区压缩 */
  .topbar { display: none; }
  .masthead-inner { height: 62px; gap: 10px; }
  .brand-logo { width: 145px; height: 34px; }
  .brand-sub { display: none; }
  .masthead-cta { display: none; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  /* 数据条：5 列 -> 2 列，并去掉单元之间的竖分隔线改成分隔横线 */
  .databar { padding: 16px 16px 2px; }
  .db-grid, .databar.compact .db-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .db-cell { padding: 0 0 14px; }
  .db-cell + .db-cell { padding-left: 0; border-left: 0; }
  .db-n { font-size: 22px; }
  .opinion-grid { grid-template-columns: minmax(0, 1fr); }
  .op-card { padding: 16px 16px 14px; }
  .to-top { right: 16px; bottom: 16px; width: 38px; height: 38px; }
}

/* ===========================================================
   Toast 提示（视觉与命名移植自 assets/air/script/message.min.js，
   配色改用本站设计令牌，明暗自适应）
   =========================================================== */
.c-message {
  position: fixed;
  top: 22px;
  left: 50%;
  z-index: 200;
  min-width: 220px;
  max-width: calc(100vw - 32px);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: 0 10px 30px rgba(10, 12, 16, .16), 0 2px 6px rgba(10, 12, 16, .1);
  overflow: hidden;
  opacity: 0;
}
.c-message.is-in { animation: msgIn .22s ease-out forwards; }
.c-message.is-out { animation: msgOut .18s ease-in forwards; }
@keyframes msgIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-12px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
@keyframes msgOut {
  from { opacity: 1; transform: translateX(-50%) translateY(0); }
  to   { opacity: 0; transform: translateX(-50%) translateY(-12px); }
}
.c-message--main { display: flex; align-items: stretch; }
.c-message--icon {
  flex: none;
  display: flex; align-items: center; justify-content: center;
  width: 42px;
  color: #fff;
}
.c-message--success .c-message--icon { background: var(--ok); }
.c-message--error   .c-message--icon { background: var(--danger); }
.c-message--warning .c-message--icon { background: var(--warn); }
.c-message--info    .c-message--icon { background: var(--primary); }
.c-message--tip {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
}
.c-message--close {
  flex: none;
  width: 34px;
  border: 0;
  background: none;
  color: var(--text-3);
  cursor: pointer;
}
.c-message--close:hover { color: var(--text); }


/* ---------- 标签聚合页：按热度分三档字号 ---------- */
.tag-cloud { gap: 10px; }
.tag-cloud .tag { font-size: 14px; }
.tag-cloud .tag.t-lg { font-size: 16px; font-weight: 500; }
.tag-cloud .tag.t-md { font-size: 14px; }
.tag-cloud .tag.t-sm { font-size: 12px; color: var(--text-3); }
.tag-cloud .tag .n { margin-left: 5px; font-size: 11px; color: var(--text-3); font-weight: 400; }

/* ---------- 搜索页：重搜表单 ---------- */
.search-filters {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}
.search-filters input {
  flex: 1 1 auto;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
}
.search-filters input:focus { border-color: var(--primary); box-shadow: var(--ring); outline: none; }

/* ---- 广告位实图：占位换 <img> 后去掉虚线/底纹与内边距，图片铺满容器；
      「广告」角标保留（披露要求）。 ---- */
.ad-slot.has-img {
  padding: 0;
  border-style: solid;
  border-color: var(--border);
  background-image: none;
  overflow: hidden;
}
.ad-slot.has-img > img {
  display: block;
  width: 100%;
  height: auto;
}

/* ---- 广告位实图：去掉 min-height 造成的「边框内空白」 ---- */
.ad-slot.banner.has-img { min-height: 0; }
.ad-slot.rect.has-img { min-height: 0; }
.ad-slot.infeed.has-img,
.ad-slot.intext.has-img,
.ad-slot.inlist.has-img { min-height: 0; }
.ad-slot.has-img picture { display: block; line-height: 0; }

/* ---- 角标新变体（NewsCatChip：flag 优先，与板块同名时退化为相对时间） ---- */
/* 角标按 flag 分色：头条 h / 特推 a / 推荐 c / 滚动 s。
   没有 flag 时 NewsCatChip 直接返回空串（不再退化成时间角标），所以没有 .is-time 了。 */
.thumb .cat.is-flag { font-weight: 600; letter-spacing: .02em; }
.thumb .cat.is-flag-h { --cat: var(--c-yaowen); }
.thumb .cat.is-flag-a { --cat: var(--c-shehui); }
.thumb .cat.is-flag-c { --cat: var(--primary); }
.thumb .cat.is-flag-s { --cat: var(--c-guoji); }

/* ================= 移动端细节优化 ================= */
@media (max-width: 720px) {
  .container { padding-left: 14px; padding-right: 14px; }
  /* 文章列表：左缩略图 + 右文字，避免每条一张全宽大图把页面拉得过长 */
  .entry { grid-template-columns: 104px minmax(0, 1fr); gap: 12px; padding: 14px 0; align-items: start; }
  .entry .thumb { width: 104px; }
  .entry img { width: 104px; height: 72px; aspect-ratio: auto; }
  .entry h3 { font-size: 16px; line-height: 1.45; margin-bottom: 4px; }
  .entry p {
    font-size: 13px; margin-bottom: 6px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .entry .meta { font-size: 12px; }
  .thumb .cat { left: 6px; bottom: 6px; padding: 2px 6px; font-size: 11px; }
  .card h3 { font-size: 15px; }
  .widget { padding: 14px; }
  .section-head h2 { font-size: 19px; }
  .split-item img { width: 76px; height: 56px; }
  .rec-item img { width: 76px; height: 56px; }
  /* 正文里的宽内容：表格 / 代码块横向滚动，图片不溢出 */
  .body-text img, .article-body img { max-width: 100%; height: auto; }
  .body-text table, .article-body table,
  .codeblock pre, .body-text pre { display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .article-meta { flex-wrap: wrap; row-gap: 6px; }
  /* 触控目标不小于 34~40px */
  .filters .chip, .chip { min-height: 34px; display: inline-flex; align-items: center; }
  .nav-toggle { min-width: 40px; min-height: 40px; justify-content: center; }
  .stream-item { padding: 12px 0; }
  .pager { justify-content: center; gap: 6px; }
  .ad-slot.banner.has-img { margin: 16px 0; }
  .ad-slot.rect.has-img { margin: 0 0 16px; }
  .brief-grid { gap: 10px; }
}

@media (max-width: 480px) {
  .container { padding-left: 12px; padding-right: 12px; }
  .entry { grid-template-columns: 92px minmax(0, 1fr); gap: 10px; }
  .entry .thumb { width: 92px; }
  .entry img { width: 92px; height: 64px; }
  .entry h3 { font-size: 15px; }
  .card h3 { font-size: 15px; }
  .topic-cover > img { height: 170px; }
  .hero-main h1, .slide-body h1 { font-size: 20px; }
  .article-head h1 { font-size: 22px; }
  .page-title { font-size: 22px; }
  .hero { border-radius: var(--radius-sm); }
  .masthead-inner { height: 56px; }
  .brand-logo { width: 128px; height: 30px; }
}
/* ===========================================================
   正文表格：直接作用在 table 上
   正文来自数据库，作者写 <table> 时不会带 class；
   app.js / NewsBody 也会给裸表补 .table-wrap + .data-table，
   但那只是加分项 —— 这里保证「什么都没有」时表也能看。
   =========================================================== */
.body-text table {
  width: 100%;
  max-width: 100%;
  margin: 0 0 22px;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: 14px;
  line-height: 1.65;
  color: var(--text);
  background: var(--surface);
}
.body-text .table-wrap { margin: 22px 0; border-radius: var(--radius-sm); }
.body-text .table-wrap > table { margin: 0; display: table; width: 100%; }
.body-text table caption {
  caption-side: top;
  text-align: left;
  padding: 0 0 8px;
  font-size: 13px;
  color: var(--text-3);
}
.body-text table th,
.body-text table td {
  padding: 10px 13px;
  border: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}
.body-text table thead th {
  background: var(--surface-2);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}
.body-text table tbody th { background: var(--surface-2); font-weight: 600; }
.body-text table tbody tr:hover td { background: var(--surface-2); }
.body-text table tfoot td,
.body-text table tfoot th {
  background: var(--surface-2);
  font-weight: 600;
  color: var(--text);
}
/* 数字列（.num 由编辑器手写或 NewsBody 自动补） */
.body-text table th.num, .body-text table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ===========================================================
   评论：一级列表 + 二级折叠（方法论照 air 主题）
   =========================================================== */
.comments-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 20px;
}
.comments-head h3 { margin: 0; }
.comments-note {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--text-3);
}
.comments-note::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--primary);
  opacity: .5;
}

/* 一级评论：分隔线式列表，比一张张卡片更耐读 */
.comment-list { display: grid; gap: 0; }
.comment {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.comment-list > .comment:first-child { padding-top: 2px; }
.comment-list > .comment:last-child { border-bottom: 0; padding-bottom: 0; }
.comment > .avatar {
  background: var(--primary-soft);
  color: var(--primary);
  box-shadow: inset 0 0 0 1px rgba(26, 79, 208, .14);
}
.comment .head { flex-wrap: wrap; }
.comment .head .name { color: var(--text); }
.comment .head time { font-variant-numeric: tabular-nums; }
.comment .text { color: var(--text-2); line-height: 1.78; }
.comment .actions button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  margin: -3px 0;
  border-radius: 999px;
  transition: background .16s, color .16s;
}
.comment .actions button:hover { background: var(--primary-soft); color: var(--primary); }
.comment .actions button em { font-style: normal; font-variant-numeric: tabular-nums; }
.comment .actions button.is-active { color: var(--primary); }

/* 二级：整块浅底，回复集中在一处 */
.comment .children {
  margin-top: 12px;
  padding: 2px 14px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  display: grid;
}
.comment .comment.is-child {
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  padding: 11px 0;
  border: 0;
  border-top: 1px solid var(--border);
  margin: 0;
}
.comment .comment.is-child:first-child { border-top: 0; }
/* 折叠区展开后，第一条隐藏回复要补回分隔线 */
.comment .children-more .comment.is-child:first-child { border-top: 1px solid var(--border); }
.comment .comment.is-child > .avatar {
  width: 28px; height: 28px;
  font-size: 12px;
  background: var(--surface);
}
.comment .comment.is-child .head { font-size: 13px; }
.comment .comment.is-child .text { margin-top: 2px; font-size: 14px; }
.comment .comment.is-child .actions { margin-top: 5px; font-size: 12px; }
.comment .comment.is-child .actions button { font-size: 12px; }

/* 「展开其余 N 条回复」 */
.comment-more {
  justify-self: start;
  margin: 10px 0 12px;
  padding: 5px 13px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--primary);
  font-size: 12.5px;
  line-height: 1.4;
  cursor: pointer;
  transition: background .16s, border-color .16s;
}
.comment-more:hover { background: var(--primary-soft); border-color: var(--primary); }
.comment-more:focus-visible { outline: none; box-shadow: var(--ring); }

.comment-empty {
  margin: 0;
  padding: 26px 0 22px;
  text-align: center;
  font-size: 14px;
  color: var(--text-3);
}

/* 评论分页（AJAX 换页，不走服务端跳转） */
.comment-pager {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 24px;
  transition: opacity .18s;
}
.comment-pager.is-loading { opacity: .5; pointer-events: none; }
.comment-pager .pg {
  min-width: 34px;
  height: 34px;
  padding: 0 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text-2);
  font-size: 13px;
  cursor: pointer;
  transition: border-color .16s, color .16s, background .16s;
}
.comment-pager .pg:hover { border-color: var(--primary); color: var(--primary); }
.comment-pager .pg:focus-visible { outline: none; box-shadow: var(--ring); }
.comment-pager .pg.active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--on-primary);
  font-weight: 500;
  cursor: default;
}
.comment-pager .gap { padding: 0 2px; color: var(--text-3); font-size: 13px; }
.comment-pager .total { margin-left: auto; font-size: 12.5px; color: var(--text-3); }

/* 取消回复 */
.cancel-reply {
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-3);
  font-size: 13px;
  cursor: pointer;
  transition: border-color .16s, color .16s;
}
.cancel-reply:hover { border-color: var(--danger); color: var(--danger); }
.cancel-reply[hidden] { display: none; }

@media (max-width: 720px) {
  .comments { margin-top: 30px; padding-top: 22px; }
  .comments-head { margin-bottom: 16px; gap: 4px 12px; }
  .comments h3 { font-size: 17px; }
  .comments-note { font-size: 12px; }
  .comment { grid-template-columns: 34px minmax(0, 1fr); gap: 10px; padding: 15px 0; }
  .comment > .avatar { width: 34px; height: 34px; font-size: 13px; }
  .comment .text { font-size: 14px; line-height: 1.75; }
  .comment .children { padding: 2px 11px; margin-top: 10px; }
  .comment .comment.is-child { grid-template-columns: 26px minmax(0, 1fr); gap: 9px; padding: 10px 0; }
  .comment .comment.is-child > .avatar { width: 26px; height: 26px; font-size: 11px; }
  .comment-pager { margin-top: 20px; }
  .comment-pager .total { margin-left: 0; width: 100%; padding-top: 4px; }
  .comment-more { margin: 9px 0 11px; }
  /* 正文表格：字号降一档，单元格内边距收紧 */
  .body-text table { font-size: 13px; }
  .body-text table th, .body-text table td { padding: 8px 10px; }
  .body-text .table-wrap { margin: 18px 0; }
}
/* ===========================================================
   评论表单：昵称 / 验证码 / 匿名评论
   =========================================================== */
.cf-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.cf-bar > #commentName { flex: 1 1 180px; min-width: 140px; }
.cf-code { display: inline-flex; align-items: center; gap: 8px; }
.cf-code input#commentCode {
  width: 112px;
  letter-spacing: .16em;
  text-transform: lowercase;
}
.cf-code img {
  width: 90px; height: 30px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  cursor: pointer;
  display: block;
}
.cf-code img:hover { border-color: var(--primary); }
.cf-anon {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--text-2);
  cursor: pointer; user-select: none;
}
/* 复选不能沿用 .comment-form input 的 38px 高/边框 */
.cf-anon input[type="checkbox"] {
  width: 15px; height: 15px; padding: 0;
  border: 0; background: none;
  accent-color: var(--primary);
  cursor: pointer;
}
.cf-anon input[type="checkbox"]:checked + span { color: var(--primary); font-weight: 500; }
.cf-actions { display: flex; align-items: center; gap: 10px; }
.cf-actions .btn { margin-left: auto; }
.cf-hint { font-size: 12.5px; color: var(--text-3); }
.cf-hint[hidden] { display: none; }
.comment-form input[disabled] {
  background: var(--surface-2);
  color: var(--text-3);
  cursor: not-allowed;
}

@media (max-width: 720px) {
  .cf-bar { gap: 8px; }
  .cf-bar > #commentName { flex: 1 1 100%; }
  .cf-code { flex: 1 1 auto; min-width: 0; }
  .cf-code input#commentCode { width: auto; flex: 1 1 auto; min-width: 0; }
  .cf-actions { flex-wrap: wrap; row-gap: 8px; }
  .cf-actions .cf-hint { flex: 1 1 100%; }
}

/* ---------- 专题页「相关报道」：卡片网格 ----------
   上方「专题目录」是竖排章节列表，这里用卡片网格做版式对比：上面是目录，下面是信息流。
   图区可选 —— 有图才渲染，无图整块省掉，不留空占位方框（本站约七成文章无缩略图）。 */
.rel-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.rel-grid:empty { display: none; }
.rel-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .15s, transform .15s;
}
.rel-card:hover { border-color: var(--primary); transform: translateY(-2px); }
.rel-thumb {
  flex: none;
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--surface-2);
  /* 定高而不是 aspect-ratio 16/9：多列时列宽一变图区高度就跟着暴涨
     （1024 两列下 466px 宽 → 261px 高），同行里「有图」和「无图」两种卡
     会差出 200px 空白。定高后同行卡片高度接近，空白压到几十 px 内。
     480 单列时改回 16/9（见下面断点）。 */
  height: 132px;
}
.rel-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.rel-card:hover .rel-thumb img { transform: scale(1.04); }
.rel-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 12px 14px 14px; }
/* .cat 的基础样式只定义在 .thumb 里（绝对定位压在图上）。这里是正文里的行内块，得自己写一份 */
.rel-body .cat {
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  background: var(--cat, var(--primary));
  color: var(--on-cat);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}
.rel-body .cat:empty { display: none; }
.rel-body h3 {
  margin: 0;
  font-size: 16px; font-weight: 600; line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.rel-body h3 a:hover { color: var(--primary); }
/* 无图时用来顶替图区的摘要：只在不渲染 .rel-thumb 的卡里出现（见 NewsRelCard） */
.rel-desc {
  margin: 0;
  font-size: 13px; line-height: 1.6; color: var(--text-2);
  display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden;
}
/* margin-top:auto 把 meta 推到卡片底部 —— 同行卡片被 grid 拉成等高后底边才对齐 */
.rel-meta { margin-top: auto; display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-3); }

@media (max-width: 1024px) {
  .rel-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rel-thumb { height: 108px; }
}

@media (max-width: 720px) {
  /* 720 保持两列：改单列会让 6 张卡撑成 6 屏高。每列约 329px，标题仍是满宽，
     不会出现「缩略图 + 右侧窄列」那种把文字挤成一条的布局。 */
  .rel-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .rel-thumb { height: 96px; }
  .rel-body { gap: 6px; padding: 10px 12px 12px; }
  .rel-body h3 { font-size: 15px; }
  .rel-desc { font-size: 12.5px; }
  .rel-meta { font-size: 11px; gap: 5px; }
}

@media (max-width: 480px) {
  /* 480 以下两列会把标题压到 3 行以上，改单列 */
  .rel-grid { grid-template-columns: minmax(0, 1fr); }
  /* 单列就没有「同行对齐」的问题了，图区回到 16/9 满宽，看起来像一条正常的信息流 */
  .rel-thumb { height: auto; aspect-ratio: 16 / 9; }
  .rel-body h3 { font-size: 16px; }
}

/* ================= 移动端触控目标 ================= */
@media (max-width: 720px) {
  /* 实测：手机下面包屑链接只有 26x22、.more 52x22、频道小链接 28x19、标题链接约 21px 高，
     手指点不准。统一把可点区域撑起来（桌面保持紧凑，只在移动端放宽）。 */
  .crumbs { row-gap: 2px; }
  /* 补左右内边距：只补高度时「首页」这类两字链接只有 26px 宽，仍容易点错 */
  .crumbs a, .crumbs > span { min-height: 32px; display: inline-flex; align-items: center; padding: 0 5px; }
  .crumbs > span[aria-hidden], .crumbs .sep { padding: 0 2px; }
  .section-head .more { min-height: 34px; display: inline-flex; align-items: center; }
  .util-links a { min-height: 32px; display: inline-flex; align-items: center; }
  /* 标题链接是行内的，盒子高度只等于一行文字。上下各留 6px 让整条更好点 */
  .entry h3 a, .card h3 a, .rel-body h3 a, .topic h3 a,
  .rank a, .toc a, .rec-item h3 a, .split-item h3 a,
  .entry-compact h3 a { display: inline-block; padding: 6px 0; }
  /* 第二轮巡检补漏（实测仍只有 17~24px 高）：页脚列表、快讯条、简报格、时间线、
     文章页最新条目标题、关于页代表作、引用出处、侧栏邮箱 */
  .footer-grid ul li a { display: block; padding: 7px 0; }
  .ticker-track a, .brief-item a, .hero-list.timeline a,
  .si-body h3 a, .tc-work a { display: inline-block; padding: 7px 0; }
  .pq-src a { display: inline-block; padding: 6px 0; }
  .widget .side-mail { display: inline-flex; align-items: center; min-height: 34px; }
}
