@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@500;700;900&display=swap');

/* ============================================================
   张栩铭 · 个人博客 —— 「墨纸」编辑风格设计系统
   依赖：../shared.css（全站 Design Token / 导航 / 页脚）
   说明：本文件在 shared.css 之后加载，用于把博客版面覆写为
        暖纸底 + 墨黑正文 + 朱砂点缀的杂志式排版
   ============================================================ */

:root {
  /* 纸与墨 */
  --b-paper: #f5f1e8;
  --b-paper-hi: #fffdf8;
  --b-paper-sunk: #ece6da;
  --b-ink: #17140f;
  --b-ink-2: #3b342b;
  --b-muted: #7a7164;
  --b-faint: #a49a8a;
  --b-rule: #e0d8c8;
  --b-rule-2: #cfc4ae;

  /* 点缀色：朱砂为主，保留站点靛蓝/青作辅助 */
  --b-red: #c0392b;
  --b-red-soft: rgba(192, 57, 43, 0.1);
  --b-red-line: rgba(192, 57, 43, 0.28);
  --b-indigo: #4f46e5;
  --b-cyan: #0e7490;
  --b-gold: #8a6212;
  --b-green: #15803d;

  /* 字体：宋体标题 + 黑体正文（中文报刊体例） */
  --b-serif: 'Noto Serif SC', 'Source Han Serif SC', 'Songti SC', 'STSong', 'SimSun', serif;
  --b-sans: 'Microsoft YaHei', '微软雅黑', 'Outfit', sans-serif;
  --b-mono: 'JetBrains Mono', Consolas, Monaco, monospace;

  --b-max: 1280px;
  --b-read: 720px;
}

/* ── 纸面基底 ───────────────────────────────────────────── */
body {
  background: var(--b-paper) !important;
  color: var(--b-ink);
  font-family: var(--b-sans);
}
/* 覆盖 shared.css 的冷色氛围光，换成暖色纸灯光 */
body::before {
  background:
    radial-gradient(ellipse 60% 45% at 12% -4%, rgba(192, 57, 43, 0.07), transparent 68%),
    radial-gradient(ellipse 55% 40% at 88% 4%, rgba(79, 70, 229, 0.06), transparent 68%),
    radial-gradient(ellipse 45% 32% at 50% 100%, rgba(138, 98, 18, 0.05), transparent 70%) !important;
}
/* 极细纸纹（SVG 噪点），提升"纸"的质感 */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.045'/%3E%3C/svg%3E");
}
#siteNav, .b-wrap, .site-footer, #siteFooter { position: relative; z-index: 1; }

/* ── 暂时隐藏站点通用「头部 / 底部」导航（2026-10-09）────────────
   需求：mianshizhuanjia.xyz 域名入口只呈现"纯博客"，
        不显示全站顶部导航条与底部页脚。
   范围：blog.css 只被博客页（index + 6 篇 post）引用，故仅影响博客，不动全站。
   恢复：删除下面这一条规则即可，不影响其它任何代码。 */
#siteNav, #siteFooter { display: none !important; }

/* 导航在纸面上加一层暖化，保持与全站一致的深色玻璃 */
#siteNav nav { border-bottom-color: rgba(192, 57, 43, 0.14) !important; }

/* ── 版面容器 ───────────────────────────────────────────── */
.b-wrap {
  max-width: var(--b-max);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
}
.b-narrow { max-width: 960px; }

/* ── 报头 / 首屏 ────────────────────────────────────────── */
.b-masthead {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(1.5rem, 3vw, 2.5rem);
}
.b-issue {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--b-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--b-red);
  font-weight: 700;
  margin-bottom: 1.5rem;
}
.b-issue::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--b-red-line), transparent);
}
.b-hero-title {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(2.6rem, 7vw, 5rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--b-ink);
  margin-bottom: 1.1rem;
}
.b-hero-title .thin {
  font-weight: 500;
  color: var(--b-muted);
}
.b-hero-title em {
  font-style: normal;
  color: var(--b-red);
}
.b-hero-dek {
  font-size: clamp(0.95rem, 1.6vw, 1.1rem);
  color: var(--b-ink-2);
  line-height: 1.9;
  max-width: 620px;
}
.b-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 2px solid var(--b-ink);
}
.b-stat .n {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.6rem, 3.4vw, 2.3rem);
  line-height: 1;
  color: var(--b-ink);
  display: block;
}
.b-stat .n i { font-style: normal; font-size: 0.5em; color: var(--b-red); margin-left: 2px; }
.b-stat .l {
  display: block;
  font-size: 0.76rem;
  color: var(--b-muted);
  letter-spacing: 0.06em;
  margin-top: 0.5rem;
}

/* 横贯标题条 */
.b-ticker {
  border-top: 1px solid var(--b-rule-2);
  border-bottom: 1px solid var(--b-rule-2);
  padding: 0.7rem 0;
  margin: 0 0 clamp(2rem, 4vw, 3rem);
  display: flex;
  align-items: center;
  gap: 1rem;
  overflow: hidden;
}
.b-ticker .lbl {
  /* 抬到跑马灯之上：标签是固定定位点，滚动内容只能从它右侧的轨道里出现 */
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  font-family: var(--b-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: #fff;
  background: var(--b-red);
  padding: 3px 10px;
  border-radius: 2px;
}
/* 跑马灯轨道：占满标签之外的宽度并裁掉溢出，滚动内容不再侵入标签区 */
.b-ticker .roll-track {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 44px), transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 44px), transparent 100%);
}
.b-ticker .roll {
  display: flex;
  gap: 2.5rem;
  /* 尾部补一个同等间距，使位移 -50% 恰好等于一份内容的周期，回环无跳变 */
  padding-right: 2.5rem;
  width: max-content;
  white-space: nowrap;
  font-size: 0.82rem;
  color: var(--b-ink-2);
  animation: b-roll 38s linear infinite;
  will-change: transform;
}
.b-ticker .roll a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
.b-ticker .roll a:hover { color: var(--b-red); }
.b-ticker .roll a:focus-visible { outline: 2px solid var(--b-red); outline-offset: 3px; border-radius: 2px; }
.b-ticker .roll b { color: var(--b-red); font-weight: 700; }
@keyframes b-roll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.b-ticker:hover .roll,
.b-ticker:focus-within .roll { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) {
  .b-ticker .roll { animation: none; }
  .b-ticker .roll-track { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
}

/* ── 区块标题 ───────────────────────────────────────────── */
.b-sec-head {
  display: flex;
  align-items: baseline;
  gap: 0.9rem;
  padding-bottom: 0.7rem;
  border-bottom: 2px solid var(--b-ink);
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
}
.b-sec-head .no {
  font-family: var(--b-mono);
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--b-red);
  letter-spacing: 0.1em;
}
.b-sec-head h2 {
  font-family: var(--b-serif);
  font-weight: 700;
  font-size: clamp(1.25rem, 2.6vw, 1.7rem);
  letter-spacing: -0.01em;
}
.b-sec-head .more {
  margin-left: auto;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--b-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.b-sec-head .more:hover { color: var(--b-red); }

/* ── 封面故事（大图 + 标题） ───────────────────────────── */
.b-feature {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
  background: var(--b-paper-hi);
  border: 1px solid var(--b-rule);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
  transition: box-shadow 0.35s ease, transform 0.35s ease, border-color 0.35s ease;
}
.b-feature:hover {
  box-shadow: 0 18px 50px rgba(23, 20, 15, 0.1);
  border-color: var(--b-rule-2);
  transform: translateY(-3px);
}
.b-feature .fig {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--b-paper-sunk);
}
.b-feature .fig img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.b-feature:hover .fig img { transform: scale(1.045); }
.b-feature .fig .pin {
  position: absolute;
  top: 0; left: 0;
  background: var(--b-red);
  color: #fff;
  font-family: var(--b-mono);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 6px 12px;
}
.b-feature .body { padding: clamp(1.5rem, 3vw, 2.75rem) clamp(1.5rem, 3vw, 2.75rem) clamp(1.5rem, 3vw, 2.5rem) 0; }
@media (max-width: 820px) { .b-feature .body { padding: 0 1.4rem 1.6rem; } }
.b-feature h3 {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.5rem, 3.4vw, 2.3rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0.9rem 0 0.9rem;
}
.b-feature h3 a { color: var(--b-ink); text-decoration: none; }
.b-feature h3 a:hover { color: var(--b-red); }
.b-feature p {
  font-size: 0.9rem;
  color: var(--b-ink-2);
  line-height: 1.9;
  margin-bottom: 1.4rem;
}

/* ── 封面故事内的整幅战略图（2026-10-12 加）──────────────
   封面故事卡片右栏文字较短、左图中部留白偏多，整块显空。
   把产品战略目标图作为整幅配图补在文字下方、跨满两栏，充实该区块。
   跨栏用 grid-column: 1 / -1，卡片本身是两列网格。 */
.b-feature-map {
  grid-column: 1 / -1;
  margin: 0;
  border-top: 1px solid var(--b-rule);
  background: var(--b-paper-sunk);
}
.b-feature-map img {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}
.b-feature-map figcaption {
  padding: 0.85rem clamp(1.25rem, 3vw, 2.75rem) 1.05rem;
  font-size: 0.78rem;
  color: var(--b-muted);
  letter-spacing: 0.02em;
  text-align: center;
  border-top: 1px solid var(--b-rule);
}

/* ── 本期资料（文档入口，2026-10-12 加）────────────────── */
.b-docs { margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.b-docs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.b-doc {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1.15rem 1.25rem 1.3rem;
  border: 1px solid var(--b-rule);
  border-radius: 4px;
  background: var(--b-paper-hi);
  text-decoration: none;
  transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.b-doc:hover {
  border-color: var(--b-rule-2);
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(23, 20, 15, 0.08);
}
.b-doc .k {
  font-family: var(--b-mono);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--b-red);
}
.b-doc .t {
  font-family: var(--b-serif);
  font-weight: 700;
  font-size: 1.02rem;
  line-height: 1.5;
  color: var(--b-ink);
}
.b-doc .d { font-size: 0.82rem; line-height: 1.7; color: var(--b-muted); }
/* 整幅宽的「全本」入口（2026-10-12 加）：跨满三列，作为分册之外的合订本 */
.b-doc--wide { grid-column: 1 / -1; }
@media (max-width: 820px) { .b-docs-grid { grid-template-columns: 1fr; } }

/* ── 分类条目 / 标签 ───────────────────────────────────── */
.b-cat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--b-red);
  font-family: var(--b-mono);
}
.b-cat::before { content: ''; width: 14px; height: 1px; background: var(--b-red); }

.b-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.74rem;
  color: var(--b-muted);
  font-family: var(--b-mono);
}
.b-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--b-faint); }

/* ── 筛选条 ─────────────────────────────────────────────── */
.b-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}
.b-chip {
  border: 1px solid var(--b-rule-2);
  background: transparent;
  color: var(--b-ink-2);
  font-family: var(--b-sans);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s;
}
.b-chip:hover { border-color: var(--b-ink); color: var(--b-ink); }
.b-chip.on {
  background: var(--b-ink);
  border-color: var(--b-ink);
  color: var(--b-paper-hi);
}

/* ── 文章网格 ───────────────────────────────────────────── */
.b-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
  margin-bottom: clamp(3rem, 6vw, 5rem);
}
.b-card {
  display: flex;
  flex-direction: column;
  background: var(--b-paper-hi);
  border: 1px solid var(--b-rule);
  border-radius: 4px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.b-card:hover {
  transform: translateY(-4px);
  border-color: var(--b-rule-2);
  box-shadow: 0 14px 38px rgba(23, 20, 15, 0.09);
}
.b-card .thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--b-paper-sunk);
}
.b-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.55s ease; }
.b-card:hover .thumb img { transform: scale(1.05); }
.b-card .thumb .idx {
  position: absolute;
  right: 0; bottom: 0;
  background: var(--b-paper-hi);
  color: var(--b-ink);
  font-family: var(--b-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  letter-spacing: 0.08em;
}
.b-card .text { padding: 1.15rem 1.25rem 1.35rem; display: flex; flex-direction: column; flex: 1; }
.b-card h3 {
  font-family: var(--b-serif);
  font-weight: 700;
  font-size: 1.12rem;
  line-height: 1.42;
  margin: 0.65rem 0 0.6rem;
  color: var(--b-ink);
  transition: color 0.2s;
}
.b-card:hover h3 { color: var(--b-red); }
.b-card p {
  font-size: 0.83rem;
  line-height: 1.8;
  color: var(--b-muted);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.b-card .b-meta { margin-top: 1rem; padding-top: 0.85rem; border-top: 1px solid var(--b-rule); }

/* ── 两栏：主列表 + 侧栏 ───────────────────────────────── */
.b-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
}
@media (max-width: 940px) { .b-cols { grid-template-columns: 1fr; } }

.b-side { position: sticky; top: 100px; display: flex; flex-direction: column; gap: 1.5rem; }
@media (max-width: 940px) { .b-side { position: static; } }
.b-panel {
  background: var(--b-paper-hi);
  border: 1px solid var(--b-rule);
  border-radius: 4px;
  padding: 1.4rem 1.4rem 1.5rem;
}
.b-panel > h4 {
  font-family: var(--b-serif);
  font-size: 1rem;
  font-weight: 700;
  padding-bottom: 0.6rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid var(--b-ink);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.b-panel > h4::before { content: ''; width: 4px; height: 15px; background: var(--b-red); border-radius: 1px; }

.b-tagcloud { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.b-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--b-ink-2);
  background: var(--b-paper-sunk);
  border: 1px solid transparent;
  padding: 4px 11px;
  border-radius: 3px;
  text-decoration: none;
  transition: all 0.2s;
}
.b-tag:hover { background: var(--b-ink); color: var(--b-paper-hi); }

.b-olist { list-style: none; }
.b-olist li { border-bottom: 1px dashed var(--b-rule-2); }
.b-olist li:last-child { border-bottom: none; }
.b-olist a {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
  padding: 0.75rem 0;
  text-decoration: none;
  color: var(--b-ink);
  font-size: 0.86rem;
  line-height: 1.6;
  font-weight: 600;
  transition: color 0.2s;
}
.b-olist a:hover { color: var(--b-red); }
.b-olist .rk {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: 1.05rem;
  color: var(--b-rule-2);
  flex-shrink: 0;
  width: 22px;
}
.b-olist li:nth-child(1) .rk { color: var(--b-red); }
.b-olist li:nth-child(2) .rk { color: var(--b-gold); }

/* 作者卡 */
.b-author-card { text-align: center; }
.b-author-card .ava {
  width: 84px; height: 84px;
  margin: 0 auto 0.9rem;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--b-rule-2);
  background: var(--b-paper-sunk);
}
.b-author-card .nm { font-family: var(--b-serif); font-weight: 700; font-size: 1.1rem; }
.b-author-card .rl { font-size: 0.76rem; color: var(--b-red); font-weight: 600; letter-spacing: 0.04em; margin-top: 3px; }
.b-author-card .bio { font-size: 0.78rem; color: var(--b-muted); line-height: 1.85; margin: 0.8rem 0 1.1rem; text-align: left; }

/* ── 按钮 ───────────────────────────────────────────────── */
/* ── 报头行动区（资料库入口按钮，2026-10-13 加）─────────── */
.b-hero-actions {
  margin-top: clamp(1.5rem, 3vw, 2.2rem);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.b-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-family: var(--b-sans);
  font-size: 0.84rem;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 3px;
  border: 1px solid var(--b-ink);
  background: var(--b-ink);
  color: var(--b-paper-hi);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.22s;
}
.b-btn:hover { background: var(--b-red); border-color: var(--b-red); color: #fff; }
.b-btn.ghost { background: transparent; color: var(--b-ink); }
.b-btn.ghost:hover { background: var(--b-ink); color: var(--b-paper-hi); border-color: var(--b-ink); }
.b-btn.block { display: flex; width: 100%; }

/* ── 订阅条 ─────────────────────────────────────────────── */
.b-sub {
  margin: clamp(3rem, 6vw, 5rem) 0;
  background: linear-gradient(135deg, #17140f 0%, #2a231a 55%, #3b2a1c 100%);
  border-radius: 6px;
  padding: clamp(2.25rem, 5vw, 3.5rem) clamp(1.5rem, 4vw, 3.5rem);
  color: #f0ebe1;
  position: relative;
  overflow: hidden;
}
.b-sub::after {
  content: '';
  position: absolute;
  right: -60px; top: -60px;
  width: 280px; height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(192, 57, 43, 0.35), transparent 68%);
}
.b-sub .in { position: relative; z-index: 1; max-width: 620px; }
.b-sub .k {
  font-family: var(--b-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: #e8a99f;
  font-weight: 700;
}
.b-sub h3 {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.5rem, 3.4vw, 2.1rem);
  line-height: 1.25;
  margin: 0.7rem 0 0.8rem;
  color: #fffdf8;
}
.b-sub p { font-size: 0.88rem; color: #b9b1a3; line-height: 1.85; margin-bottom: 1.5rem; }
.b-sub .acts { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.b-sub .b-btn { border-color: #f0ebe1; background: #f0ebe1; color: #17140f; }
.b-sub .b-btn:hover { background: var(--b-red); border-color: var(--b-red); color: #fff; }
.b-sub .b-btn.ghost { background: transparent; color: #f0ebe1; border-color: rgba(240, 235, 225, 0.4); }
.b-sub .b-btn.ghost:hover { background: #f0ebe1; color: #17140f; }

/* ============================================================
   文章页
   ============================================================ */

/* 阅读进度 */
.b-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0;
  z-index: 200;
  background: linear-gradient(90deg, var(--b-red), #e0a030, var(--b-red));
  box-shadow: 0 0 10px rgba(192, 57, 43, 0.45);
  transition: width 0.1s linear;
}

/* 面包屑 */
.b-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.76rem;
  color: var(--b-muted);
  padding: clamp(1.5rem, 3vw, 2.25rem) 0 0;
}
.b-crumb a { color: var(--b-muted); text-decoration: none; transition: color 0.2s; }
.b-crumb a:hover { color: var(--b-red); }
.b-crumb .sep { color: var(--b-faint); }

/* 文章头 */
.b-art-head {
  padding: clamp(1.5rem, 3.5vw, 2.5rem) 0 clamp(1.5rem, 3vw, 2.25rem);
  border-bottom: 2px solid var(--b-ink);
  margin-bottom: clamp(1.75rem, 3.5vw, 2.5rem);
}
.b-art-head h1 {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.85rem, 4.6vw, 3.1rem);
  line-height: 1.18;
  letter-spacing: -0.015em;
  margin: 0.85rem 0 1rem;
}
.b-art-head .dek {
  font-size: clamp(0.95rem, 1.7vw, 1.08rem);
  color: var(--b-ink-2);
  line-height: 1.9;
  max-width: 760px;
  font-weight: 400;
}
.b-byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  margin-top: 1.6rem;
}
.b-byline img {
  width: 44px; height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--b-rule-2);
  background: var(--b-paper-sunk);
}
.b-byline .who { font-size: 0.85rem; font-weight: 700; color: var(--b-ink); }
.b-byline .sub { font-size: 0.74rem; color: var(--b-muted); }
.b-byline .spacer { flex: 1; }

/* 阅读区两栏（目录 + 正文） */
.b-read-cols {
  display: grid;
  grid-template-columns: 220px minmax(0, var(--b-read));
  gap: clamp(2rem, 5vw, 4.5rem);
  justify-content: center;
  align-items: start;
  padding-bottom: clamp(2rem, 4vw, 3rem);
}
@media (max-width: 1000px) { .b-read-cols { grid-template-columns: minmax(0, 1fr); } }

.b-toc { position: sticky; top: 104px; }
@media (max-width: 1000px) { .b-toc { position: static; margin-bottom: 2rem; } }
.b-toc .t {
  font-family: var(--b-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--b-red);
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--b-rule-2);
  margin-bottom: 0.9rem;
}
.b-toc ol { list-style: none; counter-reset: toc; }
.b-toc li { counter-increment: toc; }
.b-toc a {
  display: block;
  font-size: 0.8rem;
  line-height: 1.55;
  color: var(--b-muted);
  text-decoration: none;
  padding: 0.42rem 0 0.42rem 1.75rem;
  position: relative;
  border-left: 2px solid transparent;
  transition: all 0.2s;
}
.b-toc a::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 0.5rem;
  font-family: var(--b-mono);
  font-size: 0.68rem;
  color: var(--b-faint);
}
.b-toc a:hover { color: var(--b-ink); border-left-color: var(--b-rule-2); }
.b-toc a.active {
  color: var(--b-red);
  font-weight: 700;
  border-left-color: var(--b-red);
  background: var(--b-red-soft);
}
.b-toc a.active::before { color: var(--b-red); }

/* 正文排版 */
.b-prose { font-size: 1.02rem; line-height: 1.98; color: var(--b-ink-2); }
.b-prose > * + * { margin-top: 1.35rem; }
.b-prose .lead {
  font-size: 1.08rem;
  line-height: 1.95;
  color: var(--b-ink);
  padding-left: 1.1rem;
  border-left: 3px solid var(--b-red);
}
.b-prose h2 {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  line-height: 1.35;
  color: var(--b-ink);
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  scroll-margin-top: 100px;
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
}
.b-prose h2::before {
  content: attr(data-n);
  font-family: var(--b-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--b-red);
  letter-spacing: 0.06em;
  flex-shrink: 0;
}
.b-prose h2::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--b-rule-2);
  transform: translateY(-4px);
}
.b-prose h3 {
  font-family: var(--b-serif);
  font-weight: 700;
  font-size: 1.12rem;
  color: var(--b-ink);
  margin-top: 2rem;
  scroll-margin-top: 100px;
}
.b-prose strong { color: var(--b-ink); font-weight: 700; }
.b-prose a { color: var(--b-red); text-decoration: none; border-bottom: 1px solid var(--b-red-line); transition: all 0.2s; }
.b-prose a:hover { border-bottom-color: var(--b-red); background: var(--b-red-soft); }
.b-prose ul, .b-prose ol { padding-left: 1.3rem; }
.b-prose li { margin: 0.55rem 0; }
.b-prose li::marker { color: var(--b-red); font-weight: 700; }
.b-prose code {
  font-family: var(--b-mono);
  font-size: 0.86em;
  background: var(--b-paper-sunk);
  border: 1px solid var(--b-rule);
  border-radius: 3px;
  padding: 1px 6px;
  color: #8a3b2c;
}
.b-prose hr { border: none; border-top: 1px solid var(--b-rule-2); margin: 2.5rem 0; }

/* 引用块 */
.b-quote {
  position: relative;
  margin: 2.25rem 0;
  padding: 1.6rem 1.75rem 1.6rem 2.5rem;
  background: var(--b-paper-hi);
  border: 1px solid var(--b-rule);
  border-left: 4px solid var(--b-red);
  border-radius: 0 4px 4px 0;
}
.b-quote::before {
  content: '\201C';
  position: absolute;
  left: 0.7rem; top: 0.4rem;
  font-family: var(--b-serif);
  font-size: 2.6rem;
  color: var(--b-red);
  opacity: 0.35;
  line-height: 1;
}
.b-quote p {
  font-family: var(--b-serif);
  font-size: 1.08rem;
  line-height: 1.85;
  color: var(--b-ink);
  font-weight: 500;
  margin: 0 !important;
}
.b-quote cite {
  display: block;
  margin-top: 0.9rem;
  font-style: normal;
  font-size: 0.78rem;
  color: var(--b-muted);
}

/* 提示框 */
.b-callout {
  margin: 2rem 0;
  padding: 1.15rem 1.35rem;
  background: var(--b-red-soft);
  border: 1px solid var(--b-red-line);
  border-radius: 4px;
}
.b-callout .hd {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--b-red);
  margin-bottom: 0.4rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.b-callout p { margin: 0 !important; font-size: 0.9rem; line-height: 1.85; }
.b-callout.neutral { background: var(--b-paper-sunk); border-color: var(--b-rule-2); }
.b-callout.neutral .hd { color: var(--b-gold); }

/* 图注 */
.b-figure { margin: 2.25rem 0; }
.b-figure img {
  width: 100%;
  border-radius: 4px;
  border: 1px solid var(--b-rule);
  display: block;
  background: var(--b-paper-sunk);
}
.b-figure figcaption {
  font-size: 0.76rem;
  color: var(--b-muted);
  margin-top: 0.7rem;
  padding-left: 0.85rem;
  border-left: 2px solid var(--b-red-line);
  line-height: 1.7;
}

/* 数据表 */
.b-table-wrap { margin: 2rem 0; overflow-x: auto; }
.b-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
  background: var(--b-paper-hi);
}
.b-table th, .b-table td {
  border: 1px solid var(--b-rule);
  padding: 0.7rem 0.9rem;
  text-align: left;
  vertical-align: top;
}
.b-table thead th {
  background: var(--b-ink);
  color: var(--b-paper-hi);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  border-color: var(--b-ink);
  white-space: nowrap;
}
.b-table tbody tr:nth-child(even) { background: rgba(236, 230, 218, 0.5); }
.b-table td.strong { font-weight: 700; color: var(--b-ink); }
.b-table td.em { color: var(--b-red); font-weight: 700; font-family: var(--b-mono); }

/* 指标卡组 */
.b-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  background: var(--b-rule-2);
  border: 1px solid var(--b-rule-2);
  border-radius: 4px;
  overflow: hidden;
  margin: 2rem 0;
}
.b-metric { background: var(--b-paper-hi); padding: 1.25rem 1.1rem; }
.b-metric .v {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: 1.7rem;
  line-height: 1;
  color: var(--b-red);
}
.b-metric .v small { font-size: 0.5em; margin-left: 2px; color: var(--b-muted); font-family: var(--b-sans); font-weight: 600; }
.b-metric .l { font-size: 0.76rem; color: var(--b-muted); margin-top: 0.55rem; line-height: 1.5; }

/* 文章尾 */
.b-art-foot {
  padding-top: 2rem;
  margin-top: 3rem;
  border-top: 2px solid var(--b-ink);
}
.b-art-foot .tags { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-bottom: 2rem; }

.b-endcard {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  background: var(--b-paper-hi);
  border: 1px solid var(--b-rule);
  border-radius: 4px;
  padding: 1.4rem;
  margin-bottom: 2.5rem;
}
.b-endcard img {
  width: 68px; height: 68px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--b-rule-2);
  background: var(--b-paper-sunk);
}
.b-endcard .nm { font-family: var(--b-serif); font-weight: 700; font-size: 1.05rem; }
.b-endcard .rl { font-size: 0.75rem; color: var(--b-red); font-weight: 600; margin-top: 2px; }
.b-endcard p { font-size: 0.83rem; color: var(--b-muted); line-height: 1.85; margin: 0.7rem 0 0.9rem; }
.b-endcard .links { display: flex; flex-wrap: wrap; gap: 0.6rem; }

/* 上下篇 */
.b-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2.5rem;
}
@media (max-width: 640px) { .b-pager { grid-template-columns: 1fr; } }
.b-pager a {
  display: block;
  border: 1px solid var(--b-rule);
  background: var(--b-paper-hi);
  border-radius: 4px;
  padding: 1.1rem 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.25s;
}
.b-pager a:hover { border-color: var(--b-ink); transform: translateY(-2px); }
.b-pager .dir { font-family: var(--b-mono); font-size: 0.68rem; color: var(--b-red); font-weight: 700; letter-spacing: 0.1em; }
.b-pager .tt { font-family: var(--b-serif); font-weight: 700; font-size: 0.98rem; margin-top: 0.5rem; line-height: 1.45; }
.b-pager a.next { text-align: right; }

/* ── 页脚前的关系图 / 装饰 ─────────────────────────────── */
.b-rule-top { border-top: 1px solid var(--b-rule-2); }

/* ── 滚动揭示 ───────────────────────────────────────────── */
.b-reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.b-reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .b-reveal { opacity: 1; transform: none; transition: none; }
  .b-ticker .roll { animation: none; }
}

/* ── 响应式 ─────────────────────────────────────────────── */
@media (max-width: 820px) {
  .b-feature { grid-template-columns: 1fr; }
  .b-feature .fig { aspect-ratio: 16 / 9; }
  .b-hero-stats { gap: 1.5rem 2rem; }
}
@media (max-width: 560px) {
  .b-prose { font-size: 0.98rem; }
  .b-endcard { flex-direction: column; gap: 0.9rem; }
  .b-card .thumb { aspect-ratio: 16 / 9; }
}

/* ── 排版式封面（无实拍图的文章） ───────────────────────── */
.b-thumb-plain {
  position: relative;
  width: 100%; height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.1rem 1.2rem;
  background:
    radial-gradient(circle at 80% 14%, rgba(192, 57, 43, 0.18), transparent 58%),
    linear-gradient(142deg, #efe9dd 0%, #e3d9c5 100%);
  overflow: hidden;
}
.b-thumb-plain .k {
  font-family: var(--b-mono);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--b-red);
}
.b-thumb-plain .big {
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  line-height: 1.15;
  color: var(--b-ink);
  letter-spacing: -0.01em;
  position: relative;
  z-index: 1;
}
.b-thumb-plain .ghost {
  position: absolute;
  right: -0.12em;
  bottom: -0.32em;
  font-family: var(--b-serif);
  font-weight: 900;
  font-size: 7.5rem;
  line-height: 1;
  color: rgba(23, 20, 15, 0.07);
  pointer-events: none;
  user-select: none;
}
.b-thumb-plain .tagsline {
  font-size: 0.68rem;
  color: var(--b-muted);
  font-family: var(--b-mono);
  position: relative;
  z-index: 1;
}

/* ── 文末署名条 ─────────────────────────────────────────── */
.b-sign {
  margin: clamp(2rem, 4vw, 3rem) 0 0;
  padding: 1.1rem 0 clamp(2rem, 4vw, 3rem);
  border-top: 1px solid var(--b-rule-2);
  font-size: 0.78rem;
  color: var(--b-muted);
  letter-spacing: 0.02em;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.25rem;
}
.b-sign .mark {
  font-family: var(--b-serif);
  font-weight: 700;
  color: var(--b-ink);
}
.b-sign .sep { color: var(--b-rule-2); }

/* ── 备案信息条（2026-10-10 加）─────────────────────────────
   域名入口指向博客后，全站页脚（#siteFooter）在博客内被隐藏，
   备案号随之不可见。此处补一条博客自带的合规信息条。
   工信部要求备案号可点击、指向 beian.miit.gov.cn，故与全站页脚同款处理。
   排版紧接 .b-sign 之下，居中、弱化，不抢正文。 */
.b-beian {
  margin: 0 0 clamp(2.5rem, 5vw, 4rem);
  font-size: 0.78rem;
  color: var(--b-muted);
  letter-spacing: 0.02em;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.4rem 0.9rem;
}
.b-beian a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--b-rule-2);
  transition: color 0.2s, border-color 0.2s;
}
.b-beian a:hover { color: var(--b-red); border-bottom-color: var(--b-red); }
.b-beian .sep { color: var(--b-rule-2); }

/* ── 空态 ───────────────────────────────────────────────── */
.b-empty {
  display: none;
  text-align: center;
  padding: 3rem 1rem;
  color: var(--b-muted);
  font-size: 0.9rem;
  border: 1px dashed var(--b-rule-2);
  border-radius: 4px;
  margin-bottom: 3rem;
}

/* 打印：去掉装饰，保留正文 */
@media print {
  body::after, .b-progress, .b-toc, .b-sub, #siteNav, #siteFooter { display: none !important; }
  .b-reveal { opacity: 1; transform: none; }
  body { background: #fff !important; }
}
