/* 十五五，增量落在哪里 — editorial field guide
   Warm minimalism: ivory paper, ink, serif headings, fine rules.
   Deep blue = 受益侧, burnt orange = 逆风侧. No external assets. */

:root {
  --paper: #f6f3ec;
  --paper-2: #fbf9f3;
  --surface: #ffffff;
  --ink: #1b1a17;
  --ink-soft: #524d46;
  --ink-faint: #70685c;
  --rule: #ded7c9;
  --rule-strong: #b6ac99;
  --blue: #1c4f70;
  --blue-deep: #143b55;
  --blue-soft: #e4edf3;
  --blue-line: #b5cadb;
  --orange: #9d4c1b;
  --orange-deep: #7c3a12;
  --orange-soft: #f7e7d8;
  --orange-line: #e0c1a2;
  --serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC", "Source Han Serif CN", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
  --bar-h: 52px;
  --prose: 34em;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--bar-h) + 18px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.78;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.24;
  letter-spacing: .01em;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--blue-deep); }

button, input, select, textarea { font: inherit; color: inherit; }

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

[hidden] { display: none !important; }

img, svg, table { max-width: 100%; }

.vh {
  position: absolute;
  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;
  z-index: 60;
  top: 8px; left: 8px;
  padding: 9px 14px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

/* ---------- sticky bar ---------- */

.bar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: var(--bar-h);
  padding: 0 clamp(14px, 3vw, 34px);
  background: rgba(246, 243, 236, .94);
  border-bottom: 1px solid var(--rule);
  backdrop-filter: saturate(140%) blur(6px);
}

.bar a { text-decoration: none; }

.bar-home {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
  white-space: nowrap;
}
.bar-home:hover { color: var(--blue); }

.bar-title {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bar-nav {
  margin-left: auto;
  display: flex;
  gap: 16px;
}

.bar-nav a {
  font-size: 13.5px;
  color: var(--ink-soft);
  white-space: nowrap;
}
.bar-nav a:hover { color: var(--blue); }

@media (max-width: 860px) {
  .bar-nav { display: none; }
  .bar-title { font-size: 10px; }
}
@media (max-width: 420px) {
  :root { --bar-h: 46px; }
  .bar { gap: 12px; }
}

/* ---------- shells ---------- */

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
}

.prose { max-width: var(--prose); }

section.band {
  padding: clamp(40px, 6vw, 76px) 0;
  border-top: 1px solid var(--rule);
}

.section-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(22px, 3vw, 29px);
}

.eyebrow {
  margin: 0;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.section-note {
  margin: 0 0 26px;
  max-width: var(--prose);
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------- hero ---------- */

.hero {
  padding-top: clamp(46px, 8vw, 96px);
  padding-bottom: clamp(34px, 5vw, 58px);
}

.hero-kicker {
  display: flex;
  gap: 10px 20px;
  flex-wrap: wrap;
  margin: 0 0 clamp(20px, 4vw, 34px);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.hero h1 {
  margin: 0 0 22px;
  font-size: clamp(32px, 8.4vw, 82px);
  line-height: 1.06;
  letter-spacing: -.01em;
}

.hero h1 .h1-sub {
  display: block;
  margin-top: .18em;
  font-size: .54em;
  color: var(--ink-soft);
  letter-spacing: .02em;
}

.hero-deck {
  max-width: 36em;
  margin: 0 0 30px;
  font-size: clamp(16.5px, 2.1vw, 19px);
  color: var(--ink-soft);
}

.thesis {
  max-width: 44em;
  margin: 0 0 30px;
  padding: 22px 26px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--ink);
}

.thesis p {
  font-family: var(--serif);
  font-size: clamp(17px, 2.3vw, 20.5px);
  line-height: 1.66;
}

.hero-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.hero-toc a {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  background: var(--paper-2);
  font-size: 13.5px;
  text-decoration: none;
  color: var(--ink);
}
.hero-toc a:hover { border-color: var(--blue); color: var(--blue); }

/* ---------- summary cards ---------- */

.cards {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 255px), 1fr));
}

.card {
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--rule);
}

.card h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

.card p { font-size: 15.3px; color: var(--ink-soft); }

/* ---------- strength scale ---------- */

.scale-list {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 255px), 1fr));
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
}

.scale-item {
  padding: 18px 20px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
}

.scale-item h3 {
  margin: 10px 0 8px;
  font-size: 16.5px;
}

.scale-item p { font-size: 14.6px; color: var(--ink-soft); }

.segs {
  display: inline-flex;
  gap: 3px;
  vertical-align: -1px;
}

.segs i {
  display: block;
  width: 13px;
  height: 7px;
  border: 1px solid var(--rule-strong);
  background: transparent;
}

.segs i.on { background: var(--ink); border-color: var(--ink); }

.side-benefit .segs i.on { background: var(--blue); border-color: var(--blue); }
.side-headwind .segs i.on { background: var(--orange); border-color: var(--orange); }

.caution {
  max-width: var(--prose);
  padding: 16px 20px;
  background: var(--orange-soft);
  border: 1px solid var(--orange-line);
  font-size: 14.6px;
  color: var(--orange-deep);
}

/* ---------- matrix table ---------- */

.matrix-scroll { margin: 0; }

table.matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.6px;
}

table.matrix th,
table.matrix td {
  padding: 13px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--rule);
}

table.matrix thead th {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 500;
  border-bottom: 1px solid var(--rule-strong);
  white-space: nowrap;
}

table.matrix tbody tr:hover { background: var(--paper-2); }

.matrix-theme a {
  font-family: var(--serif);
  font-size: 16px;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid var(--rule-strong);
}
.matrix-theme a:hover { color: var(--blue); border-color: var(--blue); }

.matrix-theme .kicker {
  display: block;
  margin-top: 5px;
  font-size: 13.4px;
  color: var(--ink-faint);
}

.cell-benefit { color: var(--blue-deep); }
.cell-headwind { color: var(--orange-deep); }

.cell-who { display: block; }

.cell-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 5px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.novelty { color: var(--ink-soft); }

@media (max-width: 820px) {
  table.matrix, table.matrix tbody, table.matrix tr, table.matrix td { display: block; width: 100%; }
  table.matrix thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); }
  table.matrix tr {
    margin-bottom: 14px;
    padding: 16px 18px;
    background: var(--surface);
    border: 1px solid var(--rule);
  }
  table.matrix td { padding: 0; border: 0; }
  table.matrix td + td { margin-top: 12px; padding-top: 12px; border-top: 1px dotted var(--rule); }
  table.matrix td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ink-faint);
  }
  table.matrix .matrix-theme::before { display: none; }
}

/* ---------- controls ---------- */

.controls {
  padding: 20px 22px;
  margin-bottom: 26px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
}

.control-row {
  display: flex;
  align-items: center;
  gap: 10px 14px;
  flex-wrap: wrap;
}

.control-row + .control-row { margin-top: 14px; }

.control-label {
  flex: 0 0 auto;
  min-width: 66px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.search-field {
  flex: 1 1 260px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--surface);
  border: 1px solid var(--rule-strong);
}

.search-field input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 15px;
}
.search-field input:focus { outline: none; }
.search-field:focus-within { border-color: var(--blue); box-shadow: 0 0 0 2px var(--blue-soft); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  padding: 6px 13px;
  background: var(--surface);
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  font-size: 13.5px;
  cursor: pointer;
}
.chip:hover { border-color: var(--blue); color: var(--blue); }
.chip[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.chips[data-filter="direction"] .chip[aria-pressed="true"][data-value="benefit"] { background: var(--blue); border-color: var(--blue); }
.chips[data-filter="direction"] .chip[aria-pressed="true"][data-value="headwind"] { background: var(--orange); border-color: var(--orange); }

.baseline-select {
  padding: 7px 10px;
  background: var(--surface);
  border: 1px solid var(--rule-strong);
  font-size: 14.5px;
}

.control-hint {
  margin: 12px 0 0;
  font-size: 13.4px;
  color: var(--ink-faint);
  max-width: var(--prose);
}

.result-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid var(--rule);
}

.result-count {
  margin: 0;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .08em;
  color: var(--ink-soft);
}

.reset-btn {
  padding: 6px 13px;
  background: transparent;
  border: 1px solid var(--rule-strong);
  font-size: 13.4px;
  cursor: pointer;
}
.reset-btn:hover { border-color: var(--ink); }

.empty-state {
  padding: 30px 24px;
  background: var(--paper-2);
  border: 1px dashed var(--rule-strong);
  text-align: center;
}
.empty-state h3 { margin: 0 0 8px; font-size: 18px; }
.empty-state p { margin: 0 auto 16px; max-width: 30em; color: var(--ink-soft); font-size: 15px; }

/* ---------- theme entries ---------- */

.theme-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; }

.theme {
  min-width: 0;
  padding: clamp(20px, 3vw, 30px);
  background: var(--surface);
  border: 1px solid var(--rule);
  scroll-margin-top: calc(var(--bar-h) + 18px);
}

.theme:target {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px var(--paper-2), 0 0 0 4px var(--rule-strong);
}

.theme-head {
  display: flex;
  gap: 16px;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.theme-no {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--ink-faint);
}

.theme-head h3 { margin: 0; font-size: clamp(20px, 2.6vw, 25px); }

.theme-head h3 a { color: inherit; text-decoration: none; }
.theme-head h3 a:hover { color: var(--blue); }

.theme-kicker {
  margin: 0 0 14px;
  max-width: var(--prose);
  font-family: var(--serif);
  font-size: 16.6px;
  color: var(--ink-soft);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.meta-row li {
  padding: 4px 10px;
  background: var(--paper);
  border: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 10.6px;
  letter-spacing: .07em;
  color: var(--ink-soft);
}

.meta-row li b { font-weight: 600; color: var(--ink-faint); }

.theme-change {
  max-width: var(--prose);
  margin: 0 0 20px;
  padding-left: 14px;
  border-left: 2px solid var(--rule-strong);
}

.sides {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  margin-bottom: 18px;
}

.side {
  padding: 18px 20px;
  border: 1px solid;
}

.side-benefit { background: var(--blue-soft); border-color: var(--blue-line); }
.side-headwind { background: var(--orange-soft); border-color: var(--orange-line); }

.side-top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  font-family: var(--mono);
  font-size: 10.6px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.side-benefit .side-top { color: var(--blue-deep); }
.side-headwind .side-top { color: var(--orange-deep); }

.side h4 {
  margin: 0 0 8px;
  font-size: 17px;
}

.side-benefit h4 { color: var(--blue-deep); }
.side-headwind h4 { color: var(--orange-deep); }

.side p { font-size: 14.9px; color: var(--ink-soft); }

.side.is-dim { opacity: .62; }

.tag {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 9.6px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.tag-fact { color: var(--ink-soft); }
.tag-inference { color: var(--orange-deep); }

.baseline-block {
  margin: 0 0 18px;
  padding: 16px 18px;
  background: var(--paper);
  border: 1px solid var(--rule);
}

.baseline-block > .eyebrow { margin-bottom: 8px; }

.baseline-line { margin: 0 0 10px; font-size: 15px; }
.baseline-line:last-child { margin-bottom: 0; }

.baseline-line b {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--ink-faint);
  margin-right: 8px;
}

details.block {
  margin-top: 12px;
  border: 1px solid var(--rule);
  background: var(--paper-2);
}

details.block > summary {
  padding: 12px 16px;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 11.4px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  list-style-position: inside;
}

details.block > summary:hover { color: var(--blue); }
details.block[open] > summary { border-bottom: 1px solid var(--rule); }

.details-body { padding: 18px 20px; }
.details-body > *:first-child { margin-top: 0; }

.details-body h4 {
  margin: 20px 0 8px;
  font-size: 15.4px;
}

.details-body p,
.details-body li { font-size: 15px; color: var(--ink-soft); }

.details-body ul { margin: 0 0 12px; padding-left: 1.2em; }
.details-body li { margin-bottom: 5px; }

/* timeline */

.timeline { margin: 0; padding: 0; list-style: none; }

.tl-item {
  position: relative;
  padding: 0 0 20px 24px;
  border-left: 1px solid var(--rule-strong);
}

.tl-item:last-child { padding-bottom: 0; }

.tl-item::before {
  content: "";
  position: absolute;
  left: -5px; top: 7px;
  width: 9px; height: 9px;
  background: var(--paper-2);
  border: 1px solid var(--rule-strong);
  border-radius: 50%;
}

.tl-item.is-focus::before { background: var(--ink); border-color: var(--ink); }
.tl-item.is-baseline { background: var(--blue-soft); }
.tl-item.is-baseline::before { background: var(--blue); border-color: var(--blue); }

.tl-head {
  display: flex;
  gap: 10px;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.tl-period {
  font-family: var(--mono);
  font-size: 11.6px;
  letter-spacing: .1em;
  color: var(--ink);
}

.tl-chapter { font-size: 13.4px; color: var(--ink-faint); }

.tl-summary { margin: 0 0 8px; font-size: 15px; }

blockquote.quote {
  margin: 0 0 8px;
  padding: 10px 14px;
  background: var(--surface);
  border-left: 2px solid var(--ink);
  font-family: var(--serif);
  font-size: 15.4px;
  line-height: 1.72;
}

.quote-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  font-family: var(--mono);
  font-size: 10.8px;
  letter-spacing: .06em;
  color: var(--ink-faint);
}

/* ---------- method, perspectives, sources ---------- */

.method-list { margin: 0; padding: 0; list-style: none; }

.method-item {
  display: grid;
  gap: 4px 20px;
  grid-template-columns: 96px 1fr;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
}

.method-item:last-child { border-bottom: 1px solid var(--rule); }

.method-time {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-faint);
}

.method-time a { color: var(--ink-faint); }

.method-lesson { margin: 0 0 6px; font-size: 15.4px; }

.method-apply { margin: 0; font-size: 14.4px; color: var(--ink-faint); }

@media (max-width: 560px) {
  .method-item { grid-template-columns: 1fr; }
}

.persp {
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--rule);
}

.persp h3 { margin: 0 0 4px; font-size: 17px; }

.persp .persp-meta {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 10.6px;
  letter-spacing: .08em;
  color: var(--ink-faint);
}

.persp p { font-size: 15px; color: var(--ink-soft); }

.persp .assessment {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dotted var(--rule-strong);
  font-size: 14.4px;
}

table.sources {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.4px;
}

table.sources th,
table.sources td {
  padding: 12px 12px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--rule);
}

table.sources thead th {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 500;
  border-bottom: 1px solid var(--rule-strong);
}

.hash {
  font-family: var(--mono);
  font-size: 10.6px;
  color: var(--ink-faint);
  word-break: break-all;
}

@media (max-width: 760px) {
  table.sources, table.sources tbody, table.sources tr, table.sources td { display: block; width: 100%; }
  table.sources thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  table.sources tr { margin-bottom: 12px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--rule); }
  table.sources td { padding: 0; border: 0; }
  table.sources td + td { margin-top: 9px; }
  table.sources td::before {
    content: attr(data-label) " ";
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ink-faint);
  }
}

.caveat-list { margin: 0; padding-left: 1.2em; max-width: var(--prose); }
.caveat-list li { margin-bottom: 9px; font-size: 15px; color: var(--ink-soft); }

.stack { display: grid; gap: 16px; }

.foot {
  padding: 34px 0 60px;
  border-top: 1px solid var(--rule-strong);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--ink-faint);
}

.foot a { color: var(--ink-faint); }

.foot p { margin: 0 0 8px; }

/* ---------- motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

@media (prefers-contrast: more) {
  :root { --rule: #9b9282; --ink-soft: #33302b; --ink-faint: #5a544c; }
}
