/* ============================================================
   style-core.css — classical-reading-site design system (faithful base)
   Copy into assets/style.css. This is the reusable CORE: tokens, layout,
   3-column reading grid, character-bio cards + impact-tier markers, the
   供參考 callout, and the mobile fixes from the design-review pass.
   Text-specific sections (guang / jingjian / themes / timeline) are omitted
   on purpose — add them per classic.
   ============================================================ */

:root {
  /* ---- 色 ---- */
  --paper:        oklch(0.952 0.018 85);
  --paper-raised: oklch(0.975 0.014 85);
  --paper-sunk:   oklch(0.918 0.020 82);
  --slip:         oklch(0.940 0.034 78);   /* manuscript face — commentary panel */

  --ink:          oklch(0.272 0.020 50);    /* warm lacquer ink */
  --ink-soft:     oklch(0.430 0.022 50);
  --ink-faint:    oklch(0.520 0.020 50);   /* AA-cleared on all paper tones */

  --rule:         oklch(0.272 0.020 50 / 0.16);
  --rule-strong:  oklch(0.272 0.020 50 / 0.38);

  --vermilion:    oklch(0.548 0.185 28);    /* 朱砂 — signature commentary + active */
  --vermilion-lo: oklch(0.548 0.185 28 / 0.10);
  --gold:         oklch(0.720 0.095 80);    /* 赭金 — rules, chrome */
  --gold-lo:      oklch(0.720 0.095 80 / 0.30);
  --gold-text:    oklch(0.640 0.095 80);    /* gold lifted for small text on ink */

  /* ---- per-紀色相（各頁覆寫 --hue，卡片覆寫 --card-hue）---- */
  --hue: 30;
  --accent:      oklch(0.485 0.115 var(--hue));
  --accent-deep: oklch(0.385 0.095 var(--hue));
  --accent-wash: oklch(0.485 0.115 var(--hue) / 0.08);
  --accent-line: oklch(0.485 0.115 var(--hue) / 0.32);

  /* ---- per-element hue + tooltip arrow (supplied inline per card/tooltip;
          defaults here keep vars defined even before JS/CSS sets them) ---- */
  --card-hue: 30;
  --chue: 30;
  --mhue: 30;
  --arrow-x: 50%;
  --arrow-top: auto;
  --arrow-bottom: -7px;

  /* ---- 間距（base 4px）---- */
  --s1: 4px;  --s2: 8px;  --s3: 12px; --s4: 16px;
  --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px; --s9: 96px;

  /* ---- 字 ---- */
  --song: "Noto Serif SC", "Source Han Serif SC", "SimSun", serif;
  --kai:  "KaiTi", "STKaiti", "楷体", "Noto Serif SC", serif;
  --hei:  "Noto Sans SC", "Source Han Sans SC", "Microsoft YaHei", sans-serif;

  /* 別名：供人物卡片等次級中繼資料使用（與全站 --ink-soft/--ink-faint/--song 對齊）。
     DEFINING these is P0 — an undefined var silently inherits --ink and flattens hierarchy. */
  --serif: var(--song);
  --ink-1: var(--ink-soft);
  --ink-2: var(--ink-faint);
  --ink-3: var(--ink-faint);

  --t-xs:   0.75rem;
  --t-sm:   0.875rem;
  --t-base: 1.0625rem;
  --t-md:   1.25rem;
  --t-lg:   1.5rem;
  --t-xl:   1.9rem;
  --t-2xl:  2.4rem;
  --t-3xl:  3rem;
  --t-4xl:  4rem;

  --radius: 2px;
  --measure: 35em;     /* ~50 字/行 cap for long-form prose */
  --slip-w: 58px;      /* manuscript column pitch */
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

/* descendants that override --hue must re-declare the accents */
.jcard, .vrow, .gcase {
  --hue: var(--card-hue);
  --accent:      oklch(0.485 0.115 var(--hue));
  --accent-deep: oklch(0.385 0.095 var(--hue));
  --accent-wash: oklch(0.485 0.115 var(--hue) / 0.08);
  --accent-line: oklch(0.485 0.115 var(--hue) / 0.32);
}

html { scroll-behavior: smooth; scroll-padding-top: 92px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---- 3-column reading layout ---- */
.layout {
  display: grid;
  grid-template-columns: minmax(0, 220px) minmax(0, 1fr) minmax(0, 320px);
  gap: var(--s7);
  align-items: start;
  padding: var(--s8) 0 var(--s9);
  max-width: 1480px; margin: 0 auto;
}
.lhs { position: sticky; top: 100px; max-height: calc(100vh - 128px); overflow-y: auto;
       font-family: var(--hei); }
.rhs { position: sticky; top: 100px; max-height: calc(100vh - 128px); overflow-y: auto;
       display: grid; gap: var(--s5); align-content: start; }
.layout > .main { min-width: 0; max-width: 880px; margin: 0 auto; width: 100%; }

/* RHS collapsible (JS sets body[data-rhs="collapsed"]) */
body[data-rhs="collapsed"] .layout { grid-template-columns: minmax(0,220px) minmax(0,1fr) 48px; }
body[data-rhs="collapsed"] .rhs { width:48px; min-width:48px; padding:0; overflow:visible;
       background:transparent; border:0; box-shadow:none; gap:0; }
body[data-rhs="collapsed"] .rhs > *:not(.rhs__toggle) { display:none; }
.rhs__toggle {
  position: sticky; top:100px; z-index:5; align-self:start; justify-self:end;
  width:32px; height:32px; display:inline-flex; align-items:center; justify-content:center;
  font-family:var(--hei); font-size:14px; line-height:1; color:var(--vermilion);
  background:var(--paper-raised); border:1px solid var(--rule); border-radius:16px;
  cursor:pointer; margin-bottom:calc(-1 * var(--s5)); box-shadow:0 1px 2px rgba(0,0,0,.04);
  transition:background .15s,color .15s,border-color .15s;
}
.rhs__toggle:hover { background:var(--vermilion); color:var(--paper); border-color:var(--vermilion); }
body[data-rhs="collapsed"] .rhs__toggle { position:static; margin:var(--s5) auto 0; justify-self:center;
  width:44px; min-width:0; padding:6px 2px; white-space:normal; text-align:center; line-height:1.5; font-size:13px; }
body[data-rhs="collapsed"] .rhs__toggle::before { content:""; margin:0; }
body[data-rhs="collapsed"] .rhs__toggle::after { content:"顯示背景"; }
body:not([data-rhs="collapsed"]) .rhs__toggle::before { content:"›"; margin-right:4px; }
body:not([data-rhs="collapsed"]) .rhs__toggle::after { content:"隱藏背景"; }

@media (max-width:1180px){
  .layout{grid-template-columns:minmax(0,200px) minmax(0,1fr);}
  .rhs{grid-column:1/-1;position:static;max-height:none;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));}
  .layout>.main{max-width:none;}
}
@media (max-width:920px){
  .layout{grid-template-columns:1fr;gap:var(--s6);}
  .lhs{position:static;max-height:none;border:1px solid var(--rule);border-radius:var(--radius);
       padding:var(--s4) var(--s5);background:var(--paper-raised);}
  .rhs{grid-template-columns:1fr;}
  .rhs__toggle{display:none;}
  /* 人物頁：行動版隱藏卷次清單，讓人物導覽置頂，避免首篇傳記被埋 */
  .lhs.nav-vols .nav-lhs__title,
  .lhs.nav-vols .nav-vols__list{display:none;}
  .lhs.nav-vols .band-head{margin-top:var(--s4)!important;}
}

/* ---- left nav list ---- */
.nav-lhs__title { font-size:var(--t-xs); font-weight:700; letter-spacing:.3em;
  color:var(--ink-faint); margin:0 0 var(--s3); padding-bottom:var(--s2); border-bottom:1px solid var(--rule); }
.nav-lhs ol { list-style:none; margin:0; padding:0; }
.nav-lhs li { margin-bottom:1px; }
.nav-lhs a { display:flex; align-items:baseline; gap:var(--s3); padding:var(--s2) var(--s3);
  text-decoration:none; font-size:var(--t-sm); color:var(--ink-soft);
  border-left:2px solid transparent; transition:all .2s; border-radius:0 var(--radius) var(--radius) 0; }
.nav-lhs a:hover { background:var(--accent-wash); color:var(--ink); border-left-color:var(--accent); }

/* ---- preview cards (紀 landing) ---- */
.plgrid { display:grid; grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:var(--s4); margin-top:var(--s5); }
.plcard { display:block; background:var(--paper-raised); border:1px solid var(--rule);
  border-top:3px solid oklch(0.55 0.12 var(--card-hue)); border-radius:var(--radius);
  padding:var(--s4) var(--s5); text-decoration:none!important; color:inherit;
  transition:transform .15s,box-shadow .15s,border-color .15s; }
.plcard:hover { transform:translateY(-2px); box-shadow:0 6px 18px rgba(0,0,0,.06); border-top-color:var(--vermilion); }
.plcard__name { font-family:var(--serif); font-size:var(--t-lg); font-weight:700; color:var(--ink); }
.plcard__title { font-family:var(--hei); font-size:var(--t-xs); color:var(--ink-2); margin-top:4px; }
.plcard__facts { list-style:none; padding:0; margin:var(--s3) 0 0; font-family:var(--hei); font-size:var(--t-sm); color:var(--ink-2); }
.plcard__facts li { padding:3px 0; border-top:1px dotted var(--rule); }
.plcard__facts li::before { content:"·"; margin-right:6px; color:var(--ink-3); }
.plcard__goto { display:inline-block; margin-top:var(--s3); font-family:var(--hei); font-size:var(--t-xs); color:var(--vermilion); opacity:.6; }
.plcard:hover .plcard__goto { opacity:1; }

/* ---- people grid + full bio cards ---- */
.people-grid { display:grid; gap:var(--s6); }
.pcard { background:var(--paper-raised); border:1px solid var(--rule);
  border-left:4px solid oklch(0.55 0.12 var(--card-hue)); border-radius:var(--radius);
  padding:var(--s5) var(--s6); scroll-margin-top:110px; }
.pcard__head { display:flex; flex-direction:column; align-items:flex-start; gap:var(--s2); }
.pcard__name { font-family:var(--serif); font-size:var(--t-xl); font-weight:700; color:var(--ink); }
.pcard__role { font-family:var(--hei); font-size:var(--t-sm); color:var(--ink-2); }
.pcard__summary { font-family:var(--hei); font-size:var(--t-md); line-height:1.8; color:var(--ink-1); margin:var(--s3) 0; }
.pcard__facts { list-style:none; padding:0; margin:var(--s3) 0 0; font-family:var(--hei); font-size:var(--t-sm); line-height:1.7; color:var(--ink-2); }
.pcard__facts li { padding:4px 0 4px 18px; position:relative; border-top:1px dotted var(--rule); }
.pcard__facts li:first-child { border-top:0; }
.pcard__facts li::before { content:"※"; position:absolute; left:0; top:4px; color:oklch(0.55 0.12 var(--card-hue)); font-weight:700; }
.band-head__sub { font-family:var(--hei); font-size:var(--t-sm); color:var(--ink-2); margin:var(--s2) 0 0; max-width:60ch; line-height:1.6; }
@media (max-width:720px){ .plcard{padding:var(--s3) var(--s4);} .pcard{padding:var(--s4) var(--s5);} .pcard__name{font-size:var(--t-lg);} }

/* ---- biography sections ---- */
.pbio { display:grid; gap:var(--s6); margin-top:var(--s6); padding-top:var(--s6); border-top:1px solid var(--rule); }
.pbio__sec { }
.pbio__h { font-family:var(--hei); font-size:14px; font-weight:600; letter-spacing:.12em;
  color:var(--vermilion); margin:0 0 6px; padding-left:11px; border-left:3px solid var(--vermilion); }
.pbio__sec p { margin:0 0 12px; font-size:15px; line-height:1.9; color:var(--ink);
  max-width:var(--measure); text-align:justify; }     /* P1#5: cap line width */
.pbio__sec p:last-child { margin-bottom:0; }
@media (max-width:920px){ .pbio{gap:var(--s5);} }

/* ---- impact tier markers (S=典範/A=重要/B=知名/C=一般) ---- */
.pcard--tier-S { border-left-width:6px; box-shadow:0 2px 22px oklch(0.55 0.12 var(--card-hue) / 0.10); }
.pcard__badge { font-family:var(--hei); font-size:12px; font-weight:700; letter-spacing:.08em;
  color:oklch(0.42 0.11 var(--card-hue)); background:oklch(0.96 0.03 var(--card-hue));
  border:1px solid oklch(0.86 0.05 var(--card-hue)); padding:2px 10px; border-radius:999px; white-space:nowrap; }
.pcard__meta { display:flex; flex-wrap:wrap; align-items:center; gap:var(--s3); margin-top:4px; }
.pcard__tier { font-family:var(--hei); font-size:12px; font-weight:600; color:var(--ink-2); letter-spacing:.03em; white-space:nowrap; }
.pcard__tier--minor { color:#9a9488; font-weight:500; }
.pcard__stars { color:#8a6500; font-size:13px; letter-spacing:1px; }   /* P0#2: was #c8a13a (~2.3:1) */
.star-empty { color:#d6c9a8; }                                        /* P2#9: faint unused stars */
.pcard--tier-A { border-left-width:4px; }
.pcard--tier-B { border-left-width:3px; }
.plcard__meta { display:flex; flex-wrap:wrap; align-items:center; gap:6px; margin:2px 0; }
.plcard__tier { font-family:var(--hei); font-size:11px; color:var(--ink-2); white-space:nowrap; }
.plcard__tier--minor { color:#9a9488; }
.plcard__stars { color:#8a6500; font-size:12px; letter-spacing:1px; }

/* ---- 供參考：考古 / 正史新證 callout ---- */
.pbio__ref { margin-top:var(--s6); padding:var(--s4) var(--s5) var(--s5);
  background:oklch(0.97 0.02 var(--card-hue)); border:1px solid oklch(0.90 0.03 var(--card-hue));
  border-left:4px solid oklch(0.62 0.11 var(--card-hue)); border-radius:var(--radius); }
.pbio__ref-tag { display:inline-block; font-family:var(--hei); font-size:12px; font-weight:700;
  letter-spacing:.12em; color:#fff; background:oklch(0.55 0.11 var(--card-hue));
  padding:2px 11px; border-radius:999px; margin-bottom:10px; }
.pbio__ref p { margin:0 0 10px; font-size:14px; line-height:1.85; color:var(--ink-1); text-align:justify; }
.pbio__ref p:last-child { margin-bottom:0; }

/* ============================================================
   Reading-enrichment modules (hover tags · quotes · highlights)
   Self-contained: defines the gold helper vars + tooltip it needs.
   ============================================================ */
:root {
  --gold-deep: #8a5e12;     /* darker gold for fine text/borders */
  --gold-soft: #f6e8c6;     /* hover wash */
  --gold-line: rgba(192,138,30,.45);
}

/* ---- hover glossary term / famous-quote 'tags' (Module A) ---- */
.term {
  border-bottom: 1px dotted var(--gold-deep);
  cursor: help; color: inherit; transition: background .15s;
}
.term:hover, .term:focus { background: var(--gold-soft); outline: none; }
.q-famous {
  background: linear-gradient(180deg,#fbeec4,#f3dd9c); color: #5a3d00;
  border-radius: 3px; padding: 0 3px; cursor: help;
  box-shadow: inset 0 -1px 0 var(--gold-line); transition: background .15s;
}
.q-famous:hover, .q-famous:focus { background: linear-gradient(180deg,#fff0c2,#eccf7a); outline: none; }

/* tooltip (positioned by site.js) */
#anno-tip {
  position: fixed; z-index: 9999; max-width: 320px;
  background: #241405; color: #f6ecd8;
  border: 1px solid var(--gold); border-radius: 9px;
  padding: 10px 13px;
  font-family: var(--hei); font-size: 13px; line-height: 1.75;
  box-shadow: 0 10px 34px rgba(0,0,0,.42);
  pointer-events: none; opacity: 0; transition: opacity .14s;
}
#anno-tip.show { opacity: 1; }
#anno-tip::after {
  content: ""; position: absolute; left: var(--arrow-x,50%); transform: translateX(-50%);
  border-left: 7px solid transparent; border-right: 7px solid transparent;
  bottom: var(--arrow-bottom,-7px); top: var(--arrow-top,auto);
  border-top: 7px solid var(--gold);
}
#anno-tip.below::after { border-top: 0; border-bottom: 7px solid var(--gold); }

/* control bar: hosts the 字詞註 toggle (Module A) AND the 繁/簡 toggle
   (Module F, button id="han-toggle"). Both buttons inherit these styles. */
#anno-ctrl { position: fixed; right: 14px; bottom: 14px; z-index: 9998;
  display: flex; gap: 6px; background: var(--paper-raised);
  border: 1px solid var(--rule); border-radius: 999px; padding: 5px 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.10); font-family: var(--hei); }
#anno-ctrl button { font: inherit; font-size: 12px; cursor: pointer;
  border: 1px solid var(--rule); background: var(--paper); color: var(--ink-soft);
  border-radius: 999px; padding: 3px 10px; }
#anno-ctrl button.is-off { opacity: .5; text-decoration: line-through; }
body.no-anno .term { border-bottom: none; cursor: auto; background: none; }
body.no-anno .q-famous { background: none; box-shadow: none; cursor: auto; color: inherit; }
body.no-anno #anno-tip { display: none; }

/* ---- 人物亮點 callout (Module C) ---- */
.pcard__highlight { display:flex; gap:10px; align-items:flex-start;
  margin: var(--s4) 0 var(--s2); padding: 10px 14px;
  background: oklch(0.97 0.02 var(--card-hue));
  border: 1px solid oklch(0.90 0.03 var(--card-hue));
  border-left: 3px solid oklch(0.55 0.11 var(--card-hue)); border-radius: var(--radius); }
.pcard__highlight-tag { font-family: var(--hei); font-size: 11px; font-weight: 700;
  letter-spacing: .1em; color: oklch(0.45 0.11 var(--card-hue)); white-space: nowrap; margin-top: 3px; }
.pcard__highlight-txt { font-family: var(--song); font-size: 14px; line-height: 1.7; color: var(--ink-1); }

/* ---- 名句 / 名言 (Module B) ---- */
.pbio__quotes { margin: var(--s5) 0 var(--s3); }
.pbio__quotes-h { font-family: var(--hei); font-size: 13px; font-weight: 600; letter-spacing: .12em;
  color: var(--gold-text); margin: 0 0 10px; padding-left: 11px; border-left: 3px solid var(--gold); }
.pbio__quote { margin: 0 0 var(--s4); padding: var(--s4) var(--s5);
  background: linear-gradient(180deg,#fbf3da,#f6e7bd);
  border: 1px solid var(--gold-line); border-left: 4px solid var(--gold); border-radius: var(--radius); }
.pbio__quote-text { font-family: var(--kai); font-size: 1.05rem; line-height: 1.95; color: #5a3d00; margin: 0; text-align: justify; }
.pbio__quote-anno { font-family: var(--hei); font-size: 12px; color: var(--ink-soft); margin: 8px 0 0; line-height: 1.7; }
.pbio__quote-src { display: block; font-family: var(--hei); font-style: normal; font-size: 12px; color: var(--ink-faint); margin-top: 6px; }

/* ---- RHS 人物亮點 aggregate (Module D) ---- */
.panel--gold { border-top-color: var(--gold); }
.hl-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
.hl-list li a { display: block; text-decoration: none; color: var(--ink-soft); font-size: var(--t-sm); line-height: 1.6; }
.hl-list li b { font-family: var(--song); color: var(--ink); font-weight: 700; }
.hl-list li a:hover { color: var(--vermilion); }

/* ---- per-paragraph modern-Chinese translation (Module E: 白話 + 解讀) ---- */
.zhang__baihua{margin:var(--s4) 0 0;max-width:var(--measure);
  padding:var(--s3) var(--s4);
  background:color-mix(in oklch, var(--gold-soft) 28%, var(--paper));
  border-left:3px solid var(--gold-lo);border-radius:var(--radius);
  font-family:var(--hei);line-height:1.95;text-align:justify;}
.zhang__line{margin:0;}
.zhang__line+.zhang__line{margin-top:var(--s2);}
.zhang__baihua-label,.zhang__interp-label{display:inline-block;font-size:11px;
  font-weight:700;letter-spacing:.14em;color:var(--gold-deep);
  margin-right:var(--s2);vertical-align:middle;}
.zhang__baihua-text{font-size:.98rem;color:var(--ink);}
.zhang__interp-text{display:inline;font-size:.9rem;color:var(--ink-soft);}


/* =========================================================
   style-xiaojing.css — 《孝經》 text layer.
   Appended AFTER style-core.css. OKLCH only (no hsl()).
   Supplies: base typography, topbar/footer chrome, hero,
   band heads, panels, 章 rendering, group cards, pager,
   index-specific blocks.
   ========================================================= */

/* ---------- base ---------- */
html, body { margin: 0; padding: 0; }
body {
  background:
    radial-gradient(120% 90% at 50% 0%, oklch(0.972 0.016 85), transparent 60%),
    var(--paper);
  color: var(--ink);
  font-family: var(--song);
  font-size: var(--t-base);
  line-height: 1.95;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-deep); }
h1, h2, h3, h4 { font-family: var(--song); font-weight: 900; letter-spacing: .06em; }
.wrap { max-width: 1480px; margin: 0 auto; padding: 0 var(--s5); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--s4); top: var(--s4); z-index: 10000; background: var(--paper-raised);
  padding: var(--s2) var(--s4); border: 1px solid var(--rule); }

/* ---------- topbar ---------- */
.topbar { position: sticky; top: 0; z-index: 60; background: oklch(0.215 0.018 50);
  border-bottom: 2px solid var(--gold); }
.topbar__in { max-width: 1480px; margin: 0 auto; padding: var(--s3) var(--s5);
  display: flex; align-items: center; gap: var(--s6); }
.brand { display: flex; align-items: baseline; gap: var(--s3); text-decoration: none; flex: 0 0 auto; }
.brand__zi { font-family: var(--song); font-size: var(--t-md); font-weight: 900;
  letter-spacing: .3em; color: var(--paper); }          /* P2#10: paper, not mid-gold */
.brand__sub { font-family: var(--hei); font-size: 11px; letter-spacing: .2em;
  color: oklch(0.80 0.075 80); }
.topnav { display: flex; flex-wrap: wrap; gap: var(--s2); margin-left: auto; }
.topnav a { font-family: var(--hei); font-size: var(--t-sm); text-decoration: none;
  color: oklch(0.86 0.012 80); padding: 5px var(--s3); border-radius: 999px;
  border: 1px solid transparent; transition: background .15s, color .15s, border-color .15s; }
.topnav a:hover { background: oklch(0.30 0.02 50); color: var(--paper); border-color: var(--gold-lo); }
.topnav a.is-current { background: var(--vermilion); color: #fff; border-color: var(--vermilion); }
@media (max-width: 720px) {
  .topbar__in { flex-direction: column; align-items: flex-start; gap: var(--s3); }
  .topnav { margin-left: 0; }
}

/* ---------- footer ---------- */
.foot { margin-top: var(--s9); background: oklch(0.215 0.018 50); color: oklch(0.82 0.012 80);
  border-top: 2px solid var(--gold); font-family: var(--hei); font-size: var(--t-sm); }
.foot__in { max-width: 1480px; margin: 0 auto; padding: var(--s7) var(--s5);
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--s6); }
.foot h4 { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .24em;
  color: var(--gold); margin: 0 0 var(--s3); font-weight: 700; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.foot a { color: oklch(0.86 0.012 80); text-decoration: none; }
.foot a:hover { color: var(--gold); }
.foot__note { max-width: 1480px; margin: 0 auto; padding: 0 var(--s5) var(--s7);
  font-size: var(--t-xs); color: oklch(0.66 0.012 80); line-height: 1.9; }

/* ---------- hero (index) ---------- */
.hero { position: relative; overflow: hidden;
  background: radial-gradient(130% 150% at 12% 0%, oklch(0.965 0.026 78), var(--paper) 70%);
  border-bottom: 1px solid var(--rule); }
.hero__in { max-width: 1180px; margin: 0 auto; padding: var(--s9) var(--s5) var(--s8);
  position: relative; z-index: 1; }
.hero__eyebrow { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .34em;
  color: var(--vermilion); margin: 0 0 var(--s4); }
.hero__zi { font-family: var(--song); font-size: clamp(3.2rem, 11vw, 7rem); font-weight: 900;
  letter-spacing: .18em; line-height: 1; margin: 0; color: var(--ink); }
.hero__sub { font-family: var(--hei); font-size: var(--t-md); color: var(--ink-soft);
  letter-spacing: .18em; margin: var(--s4) 0 0; }
.hero__quote { font-family: var(--kai); font-size: clamp(1.1rem, 2.4vw, 1.6rem);
  color: var(--vermilion); margin: var(--s6) 0 0; padding-left: var(--s5);
  border-left: 3px solid var(--vermilion); line-height: 1.9; }
.hero__meta { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s6); margin-top: var(--s6);
  font-family: var(--hei); font-size: var(--t-xs); color: var(--ink-faint); letter-spacing: .1em; }
.hero__meta b { color: var(--ink-soft); font-weight: 600; }
.hero__seal { position: absolute; right: -18px; top: 50%; transform: translateY(-50%) rotate(-6deg);
  font-family: var(--song); font-size: clamp(9rem, 26vw, 20rem); font-weight: 900;
  color: oklch(0.548 0.185 28 / 0.045); line-height: .8; pointer-events: none; user-select: none; }

/* stats strip */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: var(--s4); margin-top: var(--s7); }
.stat { background: var(--paper-raised); border: 1px solid var(--rule);
  border-top: 3px solid var(--gold); border-radius: var(--radius); padding: var(--s4) var(--s5); }
.stat__k { font-family: var(--song); font-size: var(--t-xl); font-weight: 900; color: var(--ink); line-height: 1.1; }
.stat__v { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .18em; color: var(--ink-faint); margin-top: 4px; }

/* ---------- section band heads ---------- */
.band-head { text-align: center; display: flex; flex-direction: column; align-items: center;
  margin: var(--s9) 0 var(--s5); }
.band-head__eyebrow { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .3em;
  color: var(--vermilion); margin: 0 0 var(--s2); }
.band-head h2 { font-size: var(--t-2xl); margin: 0; color: var(--ink); letter-spacing: .12em; }
.band-head__rule { width: 96px; height: 2px; background: var(--gold); margin: var(--s4) auto 0; position: relative; }
.band-head__rule::after { content: ""; position: absolute; left: 50%; top: -3px; width: 8px; height: 8px;
  transform: translateX(-50%) rotate(45deg); background: var(--vermilion); }

/* ---------- 篇 cards (index) ---------- */
.jgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--s5); }
.jcard { display: block; text-decoration: none; color: inherit; background: var(--paper-raised);
  border: 1px solid var(--rule); border-top: 4px solid var(--accent);
  border-radius: var(--radius); padding: var(--s5) var(--s6);
  box-shadow: 0 2px 0 var(--gold-lo); transition: transform .15s, box-shadow .15s, border-color .15s; }
.jcard:hover { transform: translateY(-3px); box-shadow: 0 8px 22px oklch(0 0 0 / .08);
  border-top-color: var(--vermilion); }
.jcard__ord { font-family: var(--hei); font-size: 10.5px; letter-spacing: .24em; color: var(--accent-deep); }
.jcard__name { font-family: var(--song); font-size: var(--t-xl); font-weight: 900; color: var(--ink);
  margin: var(--s2) 0 var(--s1); letter-spacing: .1em; }
.jcard__range { font-family: var(--hei); font-size: var(--t-xs); color: var(--ink-faint);
  letter-spacing: .08em; margin-bottom: var(--s3); }
.jcard__blurb { font-size: var(--t-sm); line-height: 1.9; color: var(--ink-soft); margin: 0; }
.jcard__chaps { list-style: none; margin: var(--s4) 0 0; padding: var(--s3) 0 0; border-top: 1px dotted var(--rule);
  display: flex; flex-wrap: wrap; gap: 6px; }
.jcard__chaps li { font-family: var(--hei); font-size: 11px; color: var(--accent-deep);
  background: var(--accent-wash); border: 1px solid var(--accent-line);
  padding: 2px 9px; border-radius: 999px; }
.jcard__goto { display: inline-block; margin-top: var(--s4); font-family: var(--hei);
  font-size: var(--t-xs); color: var(--vermilion); }

/* ---------- 卷首 head (篇 / people / themes pages) ---------- */
.slip-head { border-bottom: 1px solid var(--rule);
  background: radial-gradient(120% 140% at 0% 0%, oklch(0.965 0.022 var(--hue)), var(--paper) 68%); }
.slip-head__inner { display: flex; align-items: center; gap: var(--s6);
  max-width: 1180px; margin: 0 auto; padding: var(--s8) var(--s5); }
.juan-plate { width: 92px; height: 112px; flex: 0 0 auto; border-radius: var(--radius);
  background: linear-gradient(160deg, oklch(0.93 0.03 var(--hue)), var(--paper-raised));
  border: 1px solid var(--rule); box-shadow: 0 2px 0 var(--gold-lo);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.juan-plate__zi { font-family: var(--song); font-size: var(--t-2xl); font-weight: 900;
  color: var(--accent-deep); line-height: 1; }
.juan-plate__no { font-family: var(--hei); font-size: 10.5px; letter-spacing: .22em; color: var(--ink-faint); }
.juan-lead { min-width: 0; }
.juan-lead__kicker { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .26em;
  color: var(--accent-deep); margin: 0 0 var(--s2); }
.juan-lead h1 { font-size: var(--t-2xl); margin: 0; letter-spacing: .12em; color: var(--ink); }
.juan-lead__span { font-family: var(--hei); font-size: var(--t-sm); color: var(--ink-soft);
  margin: var(--s3) 0 0; line-height: 1.9; max-width: 62ch; }
@media (max-width: 720px) {
  .slip-head__inner { flex-direction: column; align-items: flex-start; gap: var(--s4); padding: var(--s7) var(--s5); }
}

/* ---------- summary box ---------- */
.summary { background: var(--slip); border: 1px solid var(--rule); border-left: 4px solid var(--vermilion);
  border-radius: var(--radius); padding: var(--s5) var(--s6); }
.summary__tag { display: inline-block; font-family: var(--hei); font-size: 11px; font-weight: 700;
  letter-spacing: .18em; color: #fff; background: var(--vermilion);
  padding: 2px 12px; border-radius: 999px; margin-bottom: var(--s3); }
.summary p { margin: 0; font-family: var(--hei); font-size: var(--t-sm); line-height: 2.05; color: var(--ink-1); }

/* ---------- RHS panels ---------- */
.panel { background: var(--paper-raised); border: 1px solid var(--rule);
  border-top: 3px solid var(--accent); border-radius: var(--radius); padding: var(--s4) var(--s5); }
.panel__title { font-family: var(--hei); font-size: var(--t-xs); font-weight: 700; letter-spacing: .22em;
  color: var(--accent-deep); margin: 0 0 var(--s3); padding-bottom: var(--s2); border-bottom: 1px solid var(--rule); }
.panel p { font-family: var(--hei); font-size: var(--t-sm); line-height: 1.95; color: var(--ink-soft); margin: 0; }
.panel--red { border-top-color: var(--vermilion); }
.panel--red .panel__title { color: var(--vermilion); }
.kv { display: grid; gap: var(--s2); margin: 0; font-family: var(--hei); font-size: var(--t-sm); }
.kv div { display: grid; grid-template-columns: 4.5em 1fr; gap: var(--s3); align-items: baseline; }
.kv dt { color: var(--ink-faint); font-size: var(--t-xs); letter-spacing: .1em; }
.kv dd { margin: 0; color: var(--ink-soft); line-height: 1.75; }
.panel ul.plain { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2);
  font-family: var(--hei); font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.7; }
.panel ul.plain li::before { content: "·"; color: var(--accent); margin-right: 6px; font-weight: 700; }
.legend { display: grid; gap: var(--s3); font-family: var(--hei); font-size: var(--t-xs);
  color: var(--ink-soft); line-height: 1.7; }
.legend__row { display: grid; grid-template-columns: auto 1fr; gap: var(--s3); align-items: start; }
.legend__swatch { display: inline-block; padding: 1px 7px; border-radius: 3px; white-space: nowrap; }
.legend__swatch--term { border-bottom: 1px dotted var(--gold-deep); }
.legend__swatch--q { background: linear-gradient(180deg, #fbeec4, #f3dd9c); color: #5a3d00; }
.legend__swatch--b { background: color-mix(in oklch, var(--gold-soft) 28%, var(--paper));
  border-left: 3px solid var(--gold-lo); }
.legend__swatch--c { color: var(--gold-deep); border-bottom: 1.5px solid var(--gold); }

/* ---------- 章 / 節 rendering ---------- */
.chap { margin: var(--s8) 0 0; scroll-margin-top: 110px; }
.chap:first-child { margin-top: var(--s4); }
.chap__head { display: flex; align-items: baseline; gap: var(--s4); flex-wrap: wrap;
  padding-bottom: var(--s3); border-bottom: 2px solid var(--gold); position: relative; }
.chap__head::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 56px; height: 2px;
  background: var(--vermilion); }
.chap__no { font-family: var(--hei); font-size: 11px; font-weight: 700; letter-spacing: .2em;
  color: #fff; background: var(--accent-deep); padding: 3px 11px; border-radius: 999px; white-space: nowrap; }
.chap__title { font-family: var(--song); font-size: var(--t-xl); font-weight: 900;
  color: var(--ink); letter-spacing: .12em; margin: 0; }
.chap__gist { font-family: var(--hei); font-size: var(--t-xs); color: var(--ink-faint);
  letter-spacing: .06em; margin: 0; flex: 1 1 100%; padding-top: var(--s2); line-height: 1.8; }

.zhang { margin: var(--s6) 0 0; scroll-margin-top: 110px; }
.zhang__no { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .16em;
  color: var(--ink-faint); margin: 0 0 var(--s2); display: flex; align-items: center; gap: var(--s3); }
.zhang__no span:first-child { color: var(--accent-deep); font-weight: 700; }
.zhang__speaker { font-family: var(--hei); font-size: 10.5px; letter-spacing: .12em;
  color: var(--vermilion); border: 1px solid var(--vermilion-lo); background: var(--vermilion-lo);
  padding: 1px 8px; border-radius: 999px; }
.zhang__t { font-family: var(--kai); font-size: 1.22rem; line-height: 2.25; color: var(--ink);
  margin: 0; text-align: justify; max-width: var(--measure); }
.charlink { color: var(--gold-deep); font-weight: 700; text-decoration: none;
  border-bottom: 1px solid var(--gold-lo); }
.charlink:hover { color: var(--vermilion); border-bottom-color: var(--vermilion); }
.xref { color: var(--accent-deep); text-decoration: none; border-bottom: 1px dashed var(--accent-line); }
.xref:hover { color: var(--vermilion); border-bottom-color: var(--vermilion); }

/* ---------- chapter LHS nav ---------- */
.nav-chaps { display: grid; gap: 1px; }
.nav-chap { display: flex; align-items: baseline; gap: var(--s3); padding: var(--s2) var(--s3);
  text-decoration: none; font-family: var(--hei); font-size: var(--t-sm); color: var(--ink-soft);
  border-left: 2px solid transparent; border-radius: 0 var(--radius) var(--radius) 0; transition: all .18s; }
.nav-chap:hover { background: var(--accent-wash); color: var(--ink); border-left-color: var(--accent); }
.nav-chap.is-current { background: var(--accent-wash); border-left-color: var(--vermilion);
  color: var(--accent-deep); font-weight: 700; }
.nav-chap__no { font-size: 10.5px; color: var(--ink-faint); flex: 0 0 2.2em; }
.nav-group { font-family: var(--hei); font-size: 10.5px; font-weight: 700; letter-spacing: .2em;
  color: var(--ink-faint); margin: var(--s4) 0 var(--s2) var(--s2); }
.nav-group:first-child { margin-top: 0; }
.nav-people ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; }
.nav-people a { display: block; padding: var(--s2) var(--s3); text-decoration: none;
  font-family: var(--hei); font-size: var(--t-sm); color: var(--ink-soft);
  border-left: 2px solid transparent; border-radius: 0 var(--radius) var(--radius) 0; }
.nav-people a:hover { background: var(--accent-wash); border-left-color: var(--accent); color: var(--ink); }

/* ---------- pager ---------- */
.pager { display: flex; gap: var(--s4); justify-content: space-between; padding: var(--s7) 0 var(--s9); }
.pager a { flex: 1 1 0; display: flex; flex-direction: column; gap: 4px; text-decoration: none;
  background: var(--paper-raised); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: var(--s4) var(--s5); transition: border-color .15s, transform .15s; }
.pager a:hover { border-color: var(--vermilion); transform: translateY(-2px); }
.pager__next { text-align: right; }
.pager .dir { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .2em; color: var(--ink-faint); }
.pager .who { font-family: var(--song); font-size: var(--t-md); font-weight: 700; color: var(--ink); }

/* ---------- prose (guide / 凡例) ---------- */
.prose { max-width: var(--measure); }
.prose p { font-size: var(--t-md); line-height: 2.15; color: var(--ink); margin: 0 0 var(--s5); }
.fanli { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--s5); }
.fanli__item { background: var(--paper-raised); border: 1px solid var(--rule);
  border-left: 3px solid var(--gold); border-radius: var(--radius); padding: var(--s4) var(--s5); }
.fanli__h { font-family: var(--hei); font-size: var(--t-sm); font-weight: 700; letter-spacing: .1em;
  color: var(--accent-deep); margin: 0 0 var(--s2); }
.fanli__item p { font-family: var(--hei); font-size: var(--t-sm); line-height: 1.95;
  color: var(--ink-soft); margin: 0; }

/* ---------- theme category hues (override 論語 ids) ---------- */
#cat-root   { --cat-hue: 25;  }
#cat-govern { --cat-hue: 145; }
#cat-modern { --cat-hue: 320; }


/* =========================================================
   THEME MODULE (主題閱讀) — 論語 edition, OKLCH.
   Adapted from classical-reading-site/references/style-theme.css.
   The skill's original shipped in HSL, which violates SKILL.md's
   own "OKLCH, not HSL" rule and would fail the HSL-drift gate.
   Every accent below is oklch(... var(--hue)/--cat-hue/--card-hue/
   --mhue/--chue); neutral shadows are oklch(0 0 0 / .x); #fff stays.
   Append AFTER style-core.css + style-lunyu.css.
   ========================================================= */

/* --- PHASE 4 — 主題閱讀 / 年表 --- */
.slip-head--theme { background:
   radial-gradient(120% 140% at 0% 0%, oklch(0.96 0.02 var(--hue)), var(--paper)); }
.slip-head--theme .slip-head__inner { display: flex; align-items: center; gap: var(--s6);
   max-width: 1180px; margin: 0 auto; padding: var(--s9) var(--s5); position: relative; z-index: 1; }
.theme-mark { width: 92px; height: 92px; border-radius: var(--radius);
   background: linear-gradient(135deg, oklch(0.93 0.02 var(--mhue,30)), var(--paper-raised));
   border: 1px solid var(--rule); display: flex; align-items: center; justify-content: center; flex: 0 0 auto;
   box-shadow: 0 2px 0 var(--gold-lo); }
.theme-mark__cat { font-family: var(--hei); font-weight: 700; font-size: var(--t-xs);
   letter-spacing: .22em; color: oklch(0.40 0.11 var(--mhue,30)); writing-mode: vertical-rl; }
.slip-head--theme .juan-lead__kicker { color: oklch(0.42 0.10 var(--hue)); }

/* 主題正文 */
.theme-body .theme-h { font-family: var(--song); font-size: var(--t-xl); font-weight: 900;
   color: var(--accent-deep); margin: var(--s8) 0 var(--s4); padding-bottom: var(--s2);
   border-bottom: 2px solid var(--gold); position: relative; }
.theme-body .theme-h::before { content: ""; position: absolute; left: 0; bottom: -2px;
   width: 52px; height: 2px; background: var(--vermilion); }
.theme-body p { font-size: var(--t-md); line-height: 2.15; color: var(--ink); margin: 0 0 var(--s5); }
.tlink { color: var(--accent-deep); font-weight: 700; text-decoration: none;
   border-bottom: 1.5px solid var(--gold); padding-bottom: 1px; }
.tlink:hover { color: var(--vermilion); border-bottom-color: var(--vermilion); }

/* 左欄：主題導覽 */
.nav-theme__cat { font-family: var(--hei); font-size: 10.5px; font-weight: 700; letter-spacing: .2em;
   color: oklch(0.40 0.12 var(--chue,30)); margin: var(--s4) 0 var(--s2) var(--s2); padding-top: var(--s3); }
.nav-theme__cat:first-child { margin-top: 0; padding-top: 0; }
.nav-theme__item { display: block; padding: var(--s2) var(--s3); font-size: var(--t-sm);
   color: var(--ink-soft); text-decoration: none; border-left: 2px solid transparent;
   border-radius: 0 var(--radius) var(--radius) 0; margin-left: var(--s2); }
.nav-theme__item:hover { background: var(--accent-wash); border-left-color: var(--accent); color: var(--ink); }
.nav-theme__item.is-current { background: var(--accent-wash); border-left-color: var(--vermilion);
   color: var(--accent-deep); font-weight: 700; }
.nav-cats { list-style: none; margin: 0; padding: 0; }
.nav-cats a { display: flex; flex-direction: column; padding: var(--s2) var(--s3); text-decoration: none;
   color: var(--ink-soft); border-left: 2px solid transparent; border-radius: 0 var(--radius) var(--radius) 0; }
.nav-cats a:hover { background: var(--accent-wash); border-left-color: var(--accent); }

/* 右欄：相關卷次 / 關聯主題 */
.tref-list { display: grid; gap: var(--s2); }
.tref { display: flex; align-items: baseline; gap: var(--s3); padding: var(--s3);
   background: var(--paper-sunk); border: 1px solid var(--rule); border-radius: var(--radius); text-decoration: none;
   transition: border-color .15s; }
.tref:hover { border-color: var(--accent); }
.tref__no { font-family: var(--hei); font-weight: 700; color: var(--accent-deep); flex: 0 0 auto; font-size: var(--t-sm); }
.tref__span { font-family: var(--song); font-size: var(--t-xs); color: var(--ink-soft); line-height: 1.5; }
.trel-list { display: grid; gap: var(--s1); }
.trel { display: block; font-size: var(--t-sm); color: var(--accent-deep); text-decoration: none;
   padding: var(--s3) 0; border-bottom: 1px dashed var(--rule); }
.trel:hover { color: var(--vermilion); }

/* 主題 landing：分類 + 卡片 */
.tsec { margin-top: var(--s9); scroll-margin-top: 100px; }
.tsec__desc { font-size: var(--t-sm); line-height: 1.9; color: var(--ink-soft); margin: var(--s2) 0 0; max-width: 60ch; }
.tgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--s5); margin-top: var(--s5); }
.tcard { display: block; background: var(--paper-raised); border: 1px solid var(--rule);
   border-top: 3px solid oklch(0.45 0.13 var(--card-hue,30)); border-radius: var(--radius); padding: var(--s5);
   text-decoration: none; color: inherit; box-shadow: 0 2px 0 var(--gold-lo);
   transition: transform .15s, box-shadow .15s; }
.tcard:hover { transform: translateY(-3px); box-shadow: 0 6px 16px oklch(0 0 0 / .09); border-top-color: var(--vermilion); }
.tcard__cat { font-family: var(--hei); font-size: 10.5px; letter-spacing: .18em; color: oklch(0.40 0.12 var(--card-hue,30)); }
.tcard h3 { font-family: var(--song); font-size: var(--t-lg); font-weight: 900; color: var(--ink);
   margin: var(--s2) 0 var(--s3); line-height: 1.4; }
.tcard p { font-size: var(--t-sm); line-height: 1.85; color: var(--ink-soft); margin: 0 0 var(--s3); }
.tcard__era { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .1em; color: var(--ink-faint); }

/* 一頁速讀 box（主題頁頭） */
.summary__meta { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); margin-top: var(--s4);
   font-family: var(--hei); font-size: var(--t-xs); color: var(--ink-soft); letter-spacing: .04em; }
.summary__meta b { color: var(--accent-deep); font-weight: 700; }

/* 年表：時間軸（論語非編年，預留；一般不用） */
.tl { position: relative; padding-left: 108px; margin: var(--s7) 0; }
.tl::before { content: ""; position: absolute; left: 92px; top: 6px; bottom: 6px; width: 3px;
   background: linear-gradient(var(--accent), var(--vermilion)); border-radius: 2px; }
.tl-item { position: relative; margin-bottom: var(--s7); }
.tl-item::before { content: ""; position: absolute; left: -24px; top: 7px; width: 14px; height: 14px;
   border-radius: 50%; background: oklch(0.45 0.15 var(--hue)); border: 3px solid var(--paper);
   box-shadow: 0 0 0 2px oklch(0.45 0.15 var(--hue)); }
.tl-rail { position: absolute; left: -108px; width: 80px; text-align: right; padding-top: 2px; }
.tl-year { font-family: var(--hei); font-weight: 700; font-size: var(--t-sm); color: var(--ink-soft);
   letter-spacing: .04em; }
.tl-card { background: var(--paper-raised); border: 1px solid var(--rule);
   border-left: 4px solid oklch(0.45 0.15 var(--hue)); border-radius: var(--radius); padding: var(--s5); }
.tl-card__top { display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; }
.tl-tag { font-family: var(--hei); font-size: 10.5px; letter-spacing: .12em; color: #fff;
   background: oklch(0.42 0.14 var(--hue)); padding: 2px var(--s3); border-radius: 99px; white-space: nowrap; }
.tl-title { font-family: var(--song); font-size: var(--t-lg); font-weight: 900; color: var(--accent-deep);
   text-decoration: none; }
.tl-title:hover { color: var(--vermilion); }
.tl-ji { font-family: var(--hei); font-size: var(--t-xs); letter-spacing: .1em; color: var(--ink-faint);
   margin: var(--s2) 0; }
.tl-note { font-size: var(--t-sm); line-height: 1.9; color: var(--ink-soft); margin: 0; }

@media (max-width: 720px) {
  .tl { padding-left: 0; }
  .tl::before { display: none; }
  .tl-rail { position: static; width: auto; text-align: left; margin-bottom: var(--s2); }
  .tl-item::before { display: none; }
  .slip-head--theme .slip-head__inner { flex-direction: column; align-items: flex-start; gap: var(--s4); }
}

/* --- PHASE 4 — 主題閱讀 視覺強化 (polish layer) --- */

/* 分類主色：依 id 注入 --cat-hue，驅動整段配色 */
#cat-ren   { --cat-hue: 12;  }
#cat-li    { --cat-hue: 42;  }
#cat-xue   { --cat-hue: 158; }
#cat-junzi { --cat-hue: 232; }
#cat-zheng { --cat-hue: 268; }
#cat-xiao  { --cat-hue: 318; }

/* 分類區塊：淡彩底 + 描邊，形成清晰視覺分組 */
.tsec {
  background: linear-gradient(180deg,
    oklch(0.965 0.02 var(--cat-hue)) 0%,
    oklch(0.985 0.015 var(--cat-hue)) 55%,
    transparent 100%);
  border: 1px solid oklch(0.88 0.04 var(--cat-hue));
  border-radius: var(--radius);
  padding: var(--s7) var(--s6) var(--s6);
  margin-top: var(--s8);
  scroll-margin-top: 100px;
}
.tsec .band-head { text-align: left; align-items: flex-start; margin-bottom: var(--s5); }
.tsec .band-head__eyebrow {
  display: inline-block;
  font-family: var(--hei); font-size: 10.5px; font-weight: 700; letter-spacing: .24em;
  color: oklch(0.34 0.12 var(--cat-hue));
  background: oklch(0.92 0.03 var(--cat-hue));
  border: 1px solid oklch(0.84 0.05 var(--cat-hue));
  padding: 3px 12px; border-radius: 99px; margin: 0 0 var(--s3);
}
.tsec .band-head h2 { color: oklch(0.32 0.13 var(--cat-hue)); letter-spacing: .1em; }
.tsec .band-head__rule {
  margin: var(--s4) 0 0; width: 132px; height: 3px;
  border: none; border-radius: 2px;
  background: linear-gradient(90deg, oklch(0.48 0.14 var(--cat-hue)), transparent);
}
.tsec .band-head__rule::after { display: none; }
