/* ============================================================
   威廉看台 · 共享站点样式  /assets/site.css
   深夜看台蓝黑底 · 信号橙关键点 · 草皮绿数据态 · 等宽数字
   ============================================================ */

/* ---------- 1. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, ol, ul { margin: 0; }
ol, ul { list-style: none; padding: 0; }
img, svg, video, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; }
table { border-collapse: collapse; border-spacing: 0; }
input, textarea, select { font: inherit; }
hr { border: 0; }

/* ---------- 2. 设计令牌 ---------- */
:root {
  --night: #0B1118;
  --deep: #121C26;
  --rock: #2A333B;
  --paper: #F6F1E7;
  --bone: #E8E0D0;
  --orange: #FF6B2C;
  --green: #36C97A;
  --amber: #F2B84B;
  --moss: #6F8F6A;
  --clay: #C56F4E;

  --ink: var(--paper);
  --ink-2: var(--bone);
  --ink-3: rgba(232, 224, 208, 0.66);
  --ink-4: rgba(232, 224, 208, 0.44);
  --line: rgba(246, 241, 231, 0.12);
  --line-2: rgba(246, 241, 231, 0.26);

  --font-display: "Barlow Condensed", "Oswald", "Arial Narrow", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;

  --shell-w: 1280px;
  --gutter: clamp(18px, 4.5vw, 56px);
  --header-h: 76px;

  --r-s: 3px;
  --r-m: 10px;
  --r-l: 22px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 3. 基础排版 ---------- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 18px);
  -webkit-text-size-adjust: 100%;
}
body {
  background: var(--night);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: clamp(15px, 1.05vw, 17px);
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: 0.01em;
  color: var(--paper);
}
strong { font-weight: 700; }
::selection { background: var(--orange); color: var(--night); }

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 2px;
}
:focus:not(:focus-visible) { outline: none; }

/* ---------- 4. 工具与布局 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: clamp(44px, 7vw, 96px); }
.section--tight { padding-block: clamp(26px, 4vw, 56px); }

.grid { display: grid; gap: clamp(16px, 2.4vw, 32px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.rule { height: 1px; background: var(--line); margin-block: clamp(24px, 4vw, 48px); }

.ticks {
  height: 7px;
  background-image: repeating-linear-gradient(90deg, var(--line-2) 0 1px, transparent 1px 24px);
  background-position: left center;
}
.ticks--signal {
  background-image: repeating-linear-gradient(90deg, rgba(255, 107, 44, 0.55) 0 1px, transparent 1px 24px);
}

.frame {
  position: relative;
  border: 1px solid var(--line-2);
  border-radius: var(--r-l);
  padding: clamp(18px, 3vw, 40px);
}
.frame::before,
.frame::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid var(--orange);
  pointer-events: none;
}
.frame::before {
  top: -2px; left: -2px;
  border-right: 0; border-bottom: 0;
  border-top-left-radius: var(--r-l);
}
.frame::after {
  bottom: -2px; right: -2px;
  border-left: 0; border-top: 0;
  border-bottom-right-radius: var(--r-l);
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 10px; left: 10px;
  z-index: 200;
  transform: translateY(-180%);
  padding: 10px 16px;
  background: var(--orange);
  color: var(--night);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  border-radius: var(--r-s);
  transition: transform 0.18s var(--ease);
}
.skip-link:focus,
.skip-link:focus-visible { transform: translateY(0); }

.surface-paper {
  background: var(--paper);
  color: var(--night);
}

/* ---------- 5. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: var(--r-s);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.03em;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.18s var(--ease), color 0.18s var(--ease),
              border-color 0.18s var(--ease), transform 0.18s var(--ease);
}
.btn-signal {
  background: var(--orange);
  color: var(--night);
}
.btn-signal:hover {
  background: #ff8148;
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent;
  border-color: var(--line-2);
  color: var(--paper);
}
.btn-ghost:hover {
  border-color: var(--orange);
  color: var(--orange);
}
.btn-quiet {
  background: var(--deep);
  border-color: var(--line);
  color: var(--paper);
}
.btn-quiet:hover {
  border-color: var(--line-2);
  background: #16222e;
}

/* ---------- 6. 面包屑 ---------- */
.breadcrumb {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--ink-4);
}
.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.breadcrumb-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.breadcrumb-item + .breadcrumb-item::before {
  content: "/";
  color: rgba(232, 224, 208, 0.28);
}
.breadcrumb a { transition: color 0.16s var(--ease); }
.breadcrumb a:hover { color: var(--orange); }
.breadcrumb [aria-current="page"] { color: var(--bone); }

/* ---------- 7. 头部：轨道 + 铭牌 + 编号栏目 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: var(--night);
  border-bottom: 1px solid var(--line);
  isolation: isolate;
}
.site-header::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 6px;
  background-image: repeating-linear-gradient(90deg, var(--line-2) 0 1px, transparent 1px 26px);
  opacity: 0.45;
  pointer-events: none;
  z-index: 0;
}
.header-shell {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: clamp(10px, 2vw, 28px);
  width: 100%;
  max-width: var(--shell-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
  min-height: var(--header-h);
}

/* 品牌 */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  color: var(--paper);
  transition: opacity 0.18s var(--ease);
}
.brand:hover { opacity: 0.86; }
.brand-plate {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: var(--deep);
  border: 1px solid var(--line-2);
  border-bottom: 3px solid var(--orange);
  border-radius: var(--r-s);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 19px;
  line-height: 1;
  color: var(--paper);
}
.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.brand-mark {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 19px;
  letter-spacing: 0.06em;
  color: var(--paper);
}
.brand-sub {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.26em;
  color: var(--green);
  text-transform: uppercase;
}

/* 导航 */
.site-nav {
  display: flex;
  align-items: center;
  margin-left: auto;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(0px, 0.7vw, 10px);
}
.nav-list > li { display: flex; }
.nav-link {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 8px 10px;
  border-radius: var(--r-s);
  color: var(--ink-2);
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}
.nav-num {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.16em;
  color: rgba(232, 224, 208, 0.42);
  transition: color 0.18s var(--ease);
}
.nav-label {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.nav-note {
  position: absolute;
  left: 50%;
  top: calc(100% + 3px);
  transform: translate(-50%, -4px);
  padding: 2px 7px;
  background: var(--deep);
  border: 1px solid var(--line-2);
  border-radius: var(--r-s);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--green);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}
.nav-link:hover { background: rgba(246, 241, 231, 0.05); color: var(--paper); }
.nav-link:hover .nav-num { color: var(--orange); }
.nav-link:hover .nav-note,
.nav-link:focus-visible .nav-note {
  opacity: 1;
  transform: translate(-50%, 0);
}
.nav-link[aria-current="page"] { color: var(--paper); }
.nav-link[aria-current="page"] .nav-num { color: var(--green); }
.nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 10px; right: 10px;
  bottom: -3px;
  height: 2px;
  background: var(--green);
}

/* 头部 CTA */
.header-cta {
  flex: 0 0 auto;
  margin-left: 0;
}
.header-cta-short { display: none; }

/* 移动导航按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-s);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  cursor: pointer;
  transition: border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.nav-toggle:hover { border-color: var(--orange); color: var(--orange); }
.nav-toggle-lines {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  width: 16px;
}
.nav-toggle-lines span {
  display: block;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-lines span:first-child {
  transform: translateY(3px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-lines span:last-child {
  transform: translateY(-3px) rotate(-45deg);
}

/* 滚动进度 */
.scroll-meter {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  z-index: 3;
  background: rgba(255, 107, 44, 0.14);
  pointer-events: none;
}
.scroll-meter-fill {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: 0 50%;
  will-change: transform;
}

/* ---------- 8. 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(56px, 9vw, 120px);
  background: var(--night);
  border-top: 1px solid var(--line);
  color: var(--ink-2);
}
.site-footer::before {
  content: "";
  position: absolute;
  top: -1px; left: 0;
  width: clamp(120px, 22vw, 260px);
  height: 3px;
  background: var(--orange);
}
.footer-shell {
  width: 100%;
  max-width: var(--shell-w);
  margin-inline: auto;
  padding: clamp(38px, 5.5vw, 72px) var(--gutter) 26px;
}
.footer-top {
  display: grid;
  grid-template-columns: minmax(200px, 0.9fr) minmax(0, 2.1fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
}
.footer-mark {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(26px, 3.4vw, 34px);
  line-height: 1;
  letter-spacing: 0.04em;
  color: var(--paper);
}
.footer-sub {
  margin-top: 9px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--amber);
}
.footer-slogan {
  margin-top: 18px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink-2);
}
.footer-note {
  margin-top: 6px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-4);
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 44px);
}
.footer-col-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--paper);
}
.footer-col-title::before {
  content: "";
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  background: var(--green);
}
.footer-col-text {
  font-size: 13px;
  line-height: 1.75;
  color: var(--ink-4);
}
.footer-links {
  display: grid;
  gap: 7px;
  font-size: 13.5px;
}
.footer-links a {
  color: var(--ink-3);
  transition: color 0.16s var(--ease);
}
.footer-links a:hover { color: var(--orange); }
.footer-icp {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-4);
}
.footer-contact {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: clamp(28px, 4vw, 48px);
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r-s);
  overflow: hidden;
}
.footer-contact-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  padding: 14px 16px;
  background: var(--deep);
}
.footer-contact-item--wide { grid-column: 1 / -1; }
.footer-contact-key {
  flex: 0 0 100%;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--ink-4);
}
.footer-contact-value {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.01em;
  color: var(--paper);
  overflow-wrap: anywhere;
}
.copy-btn {
  padding: 4px 8px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-s);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--bone);
  cursor: pointer;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}
.copy-btn:hover { color: var(--orange); border-color: var(--orange); }
.copy-btn[data-copied] { color: var(--green); border-color: var(--green); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.footer-fine {
  max-width: 62ch;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--ink-4);
}

/* ---------- 9. 文字组件 ---------- */
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--amber);
}
.kicker::before {
  content: "";
  width: 18px;
  height: 2px;
  background: var(--orange);
}
.display {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(32px, 5.4vw, 64px);
  line-height: 1.03;
  letter-spacing: -0.01em;
  color: var(--paper);
}
.lede {
  max-width: 64ch;
  font-size: clamp(15px, 1.4vw, 17.5px);
  line-height: 1.8;
  color: var(--ink-2);
}

.chapter {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: clamp(10px, 1.6vw, 20px);
  margin-bottom: clamp(16px, 2.4vw, 28px);
}
.chapter-num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(44px, 7vw, 88px);
  line-height: 0.78;
  letter-spacing: -0.02em;
  color: rgba(246, 241, 231, 0.16);
}
@supports (-webkit-text-stroke: 1px #000) {
  .chapter-num {
    color: transparent;
    -webkit-text-stroke: 1px rgba(246, 241, 231, 0.42);
  }
}
.chapter-body { display: grid; gap: 5px; }
.chapter-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.1;
  color: var(--paper);
}
.chapter-desc {
  max-width: 52ch;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-4);
}

/* ---------- 10. 编辑部索引行 ---------- */
.entry-list {
  display: grid;
  border-top: 1px solid var(--line);
}
.entry {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: clamp(12px, 2.2vw, 30px);
  padding: clamp(14px, 2vw, 22px) 6px;
  border-bottom: 1px solid var(--line);
  transition: background 0.18s var(--ease), padding-inline-start 0.18s var(--ease);
}
.entry:hover,
.entry:focus-visible {
  background: linear-gradient(90deg, rgba(255, 107, 44, 0.1), rgba(255, 107, 44, 0) 62%);
  padding-inline-start: 16px;
}
.entry-num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(20px, 2.6vw, 30px);
  line-height: 1;
  color: rgba(246, 241, 231, 0.28);
  transition: color 0.18s var(--ease);
}
.entry:hover .entry-num { color: var(--orange); }
.entry-body { display: grid; gap: 3px; min-width: 0; }
.entry-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(18px, 2.1vw, 24px);
  line-height: 1.16;
  letter-spacing: 0.01em;
  color: var(--paper);
}
.entry-desc {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--ink-4);
}
.entry-note {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  color: var(--green);
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}
.entry:hover .entry-note,
.entry:focus-visible .entry-note {
  opacity: 1;
  transform: translateX(0);
}
.entry-arrow {
  font-family: var(--font-mono);
  font-size: 14px;
  color: rgba(246, 241, 231, 0.3);
  transition: color 0.18s var(--ease), transform 0.18s var(--ease);
}
.entry:hover .entry-arrow {
  color: var(--orange);
  transform: translateX(3px);
}

/* ---------- 11. 记分牌数据 ---------- */
.stat { display: grid; gap: 6px; }
.stat-value {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: clamp(34px, 6vw, 68px);
  line-height: 0.92;
  letter-spacing: -0.03em;
  color: var(--paper);
  font-variant-numeric: tabular-nums;
}
.stat-value--signal { color: var(--orange); }
.stat-value--green { color: var(--green); }
.stat-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.stat-foot {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--ink-3);
}

/* ---------- 12. 标签与旁注 ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-s);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--bone);
}
.tag--orange { color: var(--orange); border-color: rgba(255, 107, 44, 0.45); background: rgba(255, 107, 44, 0.1); }
.tag--green { color: var(--green); border-color: rgba(54, 201, 122, 0.4); background: rgba(54, 201, 122, 0.1); }
.tag--amber { color: var(--amber); border-color: rgba(242, 184, 75, 0.4); background: rgba(242, 184, 75, 0.1); }
.tag--clay { color: var(--clay); border-color: rgba(197, 111, 78, 0.45); background: rgba(197, 111, 78, 0.12); }

.note {
  padding: 14px 18px;
  background: var(--deep);
  border-left: 2px solid var(--clay);
  border-radius: 0 var(--r-s) var(--r-s) 0;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--bone);
}
.note--green { border-left-color: var(--green); }
.note--amber { border-left-color: var(--amber); }

/* ---------- 13. 数据表 ---------- */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  background: rgba(18, 28, 38, 0.55);
}
.data-table {
  width: 100%;
  min-width: 560px;
  font-size: 14px;
}
.data-table caption {
  padding: 14px 16px 10px;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--ink-4);
}
.data-table thead th {
  position: sticky;
  top: var(--header-h);
  z-index: 2;
  padding: 12px 14px;
  background: var(--deep);
  border-bottom: 1px solid var(--line-2);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-align: left;
  color: var(--bone);
  white-space: nowrap;
}
.data-table tbody td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  vertical-align: middle;
}
.data-table tbody tr:nth-child(even) { background: rgba(42, 51, 59, 0.34); }
.data-table tbody tr:hover { background: rgba(255, 107, 44, 0.08); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table .num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--paper);
}

/* ---------- 14. 图片容器 ---------- */
.media {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--deep);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
}
.media::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(246, 241, 231, 0.06);
  border-radius: inherit;
  pointer-events: none;
}
.media img,
.media svg,
.media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media--wide { aspect-ratio: 16 / 9; }
.media--square { aspect-ratio: 1 / 1; }
.media--tall { aspect-ratio: 4 / 5; }
.media--band { aspect-ratio: 21 / 9; }
.media-caption {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  line-height: 1.6;
  color: var(--ink-4);
}

/* ---------- 15. 长文排版 ---------- */
.prose {
  max-width: 70ch;
  font-size: clamp(15px, 1.1vw, 16.5px);
  line-height: 1.85;
  color: var(--ink-2);
}
.prose > * + * { margin-top: 1.1em; }
.prose h2 {
  margin-top: 1.9em;
  font-size: clamp(22px, 2.8vw, 30px);
  color: var(--paper);
}
.prose h3 {
  margin-top: 1.6em;
  font-size: clamp(17px, 1.6vw, 19px);
  font-weight: 700;
  color: var(--paper);
}
.prose ul { list-style: disc; padding-left: 1.3em; display: grid; gap: 0.5em; }
.prose ol { list-style: decimal; padding-left: 1.3em; display: grid; gap: 0.5em; }
.prose a {
  color: var(--orange);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose strong { color: var(--paper); }
.prose blockquote {
  padding: 14px 18px;
  border-left: 2px solid var(--green);
  background: var(--deep);
  border-radius: 0 var(--r-s) var(--r-s) 0;
  color: var(--bone);
}
.surface-paper .prose { color: #26313A; }
.surface-paper .prose h2,
.surface-paper .prose h3,
.surface-paper .prose strong { color: var(--night); }
.surface-paper .prose blockquote {
  background: rgba(11, 17, 24, 0.06);
  color: #22303A;
}
.surface-paper .prose a { color: #B8481A; }
.surface-paper .chapter-title { color: var(--night); }
.surface-paper .chapter-num { color: rgba(11, 17, 24, 0.14); }
@supports (-webkit-text-stroke: 1px #000) {
  .surface-paper .chapter-num {
    color: transparent;
    -webkit-text-stroke: 1px rgba(11, 17, 24, 0.38);
  }
}

/* ---------- 16. 响应式 ---------- */
@media (max-width: 1024px) {
  :root { --header-h: 62px; }

  .nav-toggle { display: inline-flex; }
  .header-cta {
    margin-left: auto;
    padding: 9px 12px;
    font-size: 12px;
  }
  .header-cta-full { display: none; }
  .header-cta-short { display: inline; }
  .brand-plate { width: 30px; height: 30px; font-size: 16px; border-bottom-width: 2px; }
  .brand-mark { font-size: 16px; }
  .brand-sub { display: none; }

  .site-nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    z-index: 90;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    width: min(88vw, 380px);
    height: calc(100vh - var(--header-h));
    height: calc(100dvh - var(--header-h));
    margin: 0;
    padding: 10px var(--gutter) 40px;
    background: var(--deep);
    border-left: 1px solid var(--line-2);
    box-shadow: -30px 0 60px -40px #000;
    overflow-y: auto;
    transform: translateX(101%);
    visibility: hidden;
    transition: transform 0.26s var(--ease), visibility 0.26s var(--ease);
  }
  .site-nav[data-open] {
    transform: translateX(0);
    visibility: visible;
  }
  html[data-nav-open] { overflow: hidden; }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
  }
  .nav-link {
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 15px 2px;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
  }
  .nav-link:hover { background: transparent; }
  .nav-num { font-size: 11px; }
  .nav-label { font-size: 16px; }
  .nav-note {
    position: static;
    margin-left: auto;
    padding: 0;
    border: 0;
    background: none;
    transform: none;
    opacity: 1;
    color: var(--ink-4);
    font-size: 10.5px;
  }
  .nav-link:hover .nav-note { transform: none; }
  .nav-link[aria-current="page"] {
    background: rgba(54, 201, 122, 0.08);
    padding-left: 12px;
  }
  .nav-link[aria-current="page"]::after { display: none; }
  .nav-link[aria-current="page"] .nav-label { color: var(--green); }

  .header-cta + .nav-toggle { flex: 0 0 auto; }

  .footer-top { grid-template-columns: minmax(0, 1fr); }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .data-table thead th { top: 0; }
}

@media (max-width: 860px) {
  .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 640px) {
  .footer-cols { grid-template-columns: minmax(0, 1fr); }
  .footer-contact { grid-template-columns: minmax(0, 1fr); }
  .footer-contact-item--wide { grid-column: auto; }
  .entry-note { display: none; }
  .entry { gap: 14px; }
  .footer-bottom { flex-direction: column; }
}

@media (hover: none) {
  .entry-note { opacity: 0.7; transform: none; }
}

/* ---------- 17. 减少动态 ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
