/* Literature 01-04 — Editorial Light Paper v3 */
html:has(body.hub-literature-paper),
html body.hub-literature-paper {
  --editorial-navy: #eef3f0;
  --editorial-ink: #173b49;
  --editorial-muted: #526a72;
  --editorial-teal: #006f70;
  --editorial-paper: #fafaf7;
  --editorial-line: #cddbdc;
  --editorial-copper: #805828;
  --paper: #fafaf7 !important;
  --paper-2: #f2eee5 !important;
  --ink: #173b49 !important;
  --white: #173b49 !important;
  --muted-ink: #526a72 !important;
  --hairline: #cddbdc !important;
  --research-cyan: #805828;
  background: #fafaf7 !important;
  color: #173b49 !important;
}
/* --research-cyan 在紙本模式是深銅色，當字色可讀；當大區塊底色時改用淡紙色，保留上緣強調線。 */
html body.hub-literature-paper .outcome-equation {
  background: var(--paper-2) !important;
  border-top: 3px solid var(--research-cyan);
}
html body.hub-literature-paper .site-header {
  display: grid !important;
  grid-template-columns: minmax(140px,auto) minmax(0,1fr) minmax(200px,auto) !important;
  align-items: center !important;
  gap: 8px 16px !important;
  min-height: 64px !important;
  max-height: none !important;
  padding: 0 var(--hub-keepout, 24px) !important;
  background: #f8fafc !important;
  color: #0f172a !important;
  border-bottom: 1px solid #cbd5e1 !important;
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06) !important;
}
html body.hub-literature-paper .site-header .brand {
  color: #0f172a !important;
}
html body.hub-literature-paper .site-header .brand-section {
  color: #0f5866 !important;
  font-weight: 700 !important;
}
html body.hub-literature-paper .site-header .primary-nav a {
  color: #334155 !important;
}
html body.hub-literature-paper .site-header .primary-nav a:hover,
html body.hub-literature-paper .site-header .primary-nav a[aria-current="location"] {
  color: #0369a1 !important;
}
html body.hub-literature-paper .site-header .language-toggle {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
}
html body.hub-literature-paper .primary-nav {
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: center !important;
  gap: 4px 14px !important;
  overflow-x: auto !important;
  min-width: 0 !important;
}
html body.hub-literature-paper .primary-nav a {
  white-space: nowrap !important;
  font-size: 13px !important;
}
html body.hub-literature-paper .header-actions {
  display: flex !important;
  align-items: center !important;
  justify-self: end !important;
  gap: 8px !important;
  min-width: 200px !important;
}
html body.hub-literature-paper .brand-section,
html body.hub-literature-paper .research-label {
  color: #006f70 !important;
  letter-spacing: .08em !important;
}
html body.hub-literature-paper .site-breadcrumb,
html body.hub-literature-paper .topic-switch {
  background: #f1f5f9 !important;
  color: #475569 !important;
  border-bottom: 1px solid #e2e8f0 !important;
  letter-spacing: .03em !important;
}
html body.hub-literature-paper .site-breadcrumb a {
  color: #0369a1 !important;
  letter-spacing: .02em !important;
}
html body.hub-literature-paper .site-breadcrumb strong {
  color: #0f172a !important;
  letter-spacing: .02em !important;
}
html body.hub-literature-paper .research-hero,
html body.hub-literature-paper .briefing-hero,
html body.hub-literature-paper .oip-hero,
html body.hub-literature-paper .studio-hero {
  min-height: 0 !important;
  height: auto !important;
  padding: 48px var(--hub-keepout, 24px) 32px !important;
  color: #173b49 !important;
  background: #fafaf7 !important;
  background-image: none !important;
}
html body.hub-literature-paper .research-hero::before,
html body.hub-literature-paper .research-hero::after {
  display: none !important;
}
html body.hub-literature-paper .research-hero h1,
html body.hub-literature-paper .briefing-hero h1,
html body.hub-literature-paper .studio-hero h1 {
  color: #173b49 !important;
  font-weight: 500 !important;
  letter-spacing: -.02em !important;
  line-height: 1.22 !important;
}
html body.hub-literature-paper .research-hero h1 em,
html body.hub-literature-paper .studio-hero em {
  color: #006f70 !important;
  font-style: normal !important;
}
html body.hub-literature-paper .research-hero-lede,
html body.hub-literature-paper .briefing-hero p,
html body.hub-literature-paper .studio-hero .hero-intro {
  color: #526a72 !important;
  max-width: 58em;
  font-size: 18px !important;
  line-height: 1.85 !important;
}
html body.hub-literature-paper .research-hero-meta {
  background: #fff !important;
  border: 1px solid #cddbdc !important;
}
html body.hub-literature-paper .research-hero-meta b { color: #173b49 !important; }
html body.hub-literature-paper .research-hero-meta span { color: #805828 !important; }
html body.hub-literature-paper .paper-shell,
html body.hub-literature-paper .paper-section,
html body.hub-literature-paper main,
html body.hub-literature-paper .studio-main {
  background: #fafaf7 !important;
  color: #173b49 !important;
}
html body.hub-literature-paper .paper-kicker { color: #805828 !important; }
html body.hub-literature-paper :is(h2,h3,h4) { color: #173b49; font-weight: 500; }
html body.hub-literature-paper .paper-conclusion {
  margin-inline: 0 !important;
  padding: 56px var(--hub-keepout, 24px) !important;
  background: #eaf1ed !important;
  background-image: none !important;
  color: #173b49 !important;
  text-align: left !important;
  border-top: 3px solid #367c70 !important;
}
html body.hub-literature-paper .paper-conclusion h2 {
  color: #173b49 !important;
  font-size: clamp(28px, 4vw, 44px) !important;
  line-height: 1.25 !important;
  margin: 12px 0 18px !important;
}
html body.hub-literature-paper .paper-conclusion p,
html body.hub-literature-paper .paper-conclusion small {
  color: #526a72 !important;
}
html body.hub-literature-paper .evidence-toolbar,
html body.hub-literature-paper .source-card,
html body.hub-literature-paper .source-index,
html body.hub-literature-paper .source-content,
html body.hub-literature-paper .claim-rung,
html body.hub-literature-paper .abstract-panel,
html body.hub-literature-paper .abstract-verdict,
html body.hub-literature-paper .correction-card,
html body.hub-literature-paper .topology-card,
html body.hub-literature-paper .oip-threat-flow article,
html body.hub-literature-paper .oip-decision-grid article,
html body.hub-literature-paper .oip-architecture article,
html body.hub-literature-paper .slide-card,
html body.hub-literature-paper .slide-card-header,
html body.hub-literature-paper .slide-bullets,
html body.hub-literature-paper .slide-notes,
html body.hub-literature-paper .studio-panel,
html body.hub-literature-paper .contract-card,
html body.hub-literature-paper .paper-chapter,
html body.hub-literature-paper .view-dock {
  background: #fff !important;
  color: #173b49 !important;
  border-color: #cddbdc !important;
  box-shadow: none !important;
}
html body.hub-literature-paper .source-card,
html body.hub-literature-paper .claim-rung,
html body.hub-literature-paper .correction-card {
  background: #eef3ef !important;
  border: 1px solid #b6cbc1 !important;
}
html body.hub-literature-paper .slide-card-header { background: #f2eee5 !important; }
html body.hub-literature-paper .filter-btn,
html body.hub-literature-paper .evidence-filters button,
html body.hub-literature-paper .button.ghost {
  background: #fff !important;
  color: #173b49 !important;
  border: 1px solid #cddbdc !important;
}
html body.hub-literature-paper .filter-btn.active,
html body.hub-literature-paper .evidence-filters button.active,
html body.hub-literature-paper .ladder button.active,
html body.hub-literature-paper .role-tabs button.active {
  background: #006f70 !important;
  color: #fafaf7 !important;
  border-color: #006f70 !important;
}
html body.hub-literature-paper .filter-btn.active *,
html body.hub-literature-paper .evidence-filters button.active *,
html body.hub-literature-paper .ladder button.active *,
html body.hub-literature-paper .role-tabs button.active * {
  color: #fafaf7 !important;
}
html body.hub-literature-paper .phase-tabs button.active {
  background: #eaf1ed !important;
  color: #0f172a !important;
}
html body.hub-literature-paper .phase-tabs button.active b {
  color: #805828 !important;
}
html body.hub-literature-paper .phase-tabs button.active span {
  color: #0f172a !important;
}
html body.hub-literature-paper .correction-card > span,
html body.hub-literature-paper .topology-head > span {
  background: #006f70 !important;
  color: #fafaf7 !important;
}
html body.hub-literature-paper .formula-block {
  background: #eaf1ed !important;
  color: #173b49 !important;
  border: 1px solid #b6cbc1 !important;
}
html body.hub-literature-paper .formula-block small {
  color: #475569 !important;
}
html body.hub-literature-paper .btn-briefing-action,
html body.hub-literature-paper .button.secondary,
html body.hub-literature-paper a.secondary,
html body.hub-literature-paper button.secondary {
  background: #fff !important;
  color: #805828 !important;
  border: 1px solid #c4b08a !important;
}
html body.hub-literature-paper :is(.button.primary, a.primary, button.primary, .hero-actions .primary) {
  background: #805828 !important;
  color: #fafaf7 !important;
  border-color: #805828 !important;
}
html body.hub-literature-paper :is(.button.primary, a.primary, button.primary, .hero-actions .primary) * {
  color: #fafaf7 !important;
}
html body.hub-literature-paper .oip-threat-flow,
html body.hub-literature-paper .oip-decision-grid { background: #cddbdc !important; }
html body.hub-literature-paper .oip-image-band {
  background: #fff !important;
  border: 1px solid #cddbdc !important;
  box-shadow: none !important;
}
html body.hub-literature-paper .oip-image-band figcaption {
  background: #f2eee5 !important;
  color: #1e293b !important;
  border-top-color: #cddbdc !important;
}

/* ============================================================
   All Diagram Text, Labels, and Captions High-Contrast Protection
   ============================================================ */
html body.hub-literature-paper svg:not(:is(.bc-illustration, [data-topic], [data-engineering-palette], .nvm-op-drawing svg, .nvm-ip-structure-drawing svg)) text,
html body.hub-literature-paper svg:not(:is(.bc-illustration, [data-topic], [data-engineering-palette], .nvm-op-drawing svg, .nvm-ip-structure-drawing svg)) tspan {
  fill: #0f172a !important;
}
html body.hub-literature-paper svg text.bc-ion,
html body.hub-literature-paper svg [data-charge] + text,
html body.hub-literature-paper svg circle[fill="#bd354a"] + text,
html body.hub-literature-paper svg circle[fill="#075f9d"] + text {
  fill: #ffffff !important;
}
html body.hub-literature-paper svg text[fill="#075f9d"] { fill: #0369a1 !important; }
html body.hub-literature-paper svg text[fill="#bd354a"] { fill: #b91c1c !important; }
html body.hub-literature-paper svg text[fill="#087968"] { fill: #047857 !important; }
html body.hub-literature-paper svg text[fill="#a45410"] { fill: #b45309 !important; }

html body.hub-literature-paper figcaption,
html body.hub-literature-paper figure figcaption,
html body.hub-literature-paper .nvm-figure-caption,
html body.hub-literature-paper .nvm-figure-label,
html body.hub-literature-paper .nvm-op-caption,
html body.hub-literature-paper .nvm-op-legend,
html body.hub-literature-paper .nvm-op-caveat,
html body.hub-literature-paper .bc-legend,
html body.hub-literature-paper .bc-figure-head,
html body.hub-literature-paper .nvm-ip-structure-notes,
html body.hub-literature-paper .nvm-patent-figure > figcaption,
html body.hub-literature-paper [data-figure-notes] {
  color: #1e293b !important;
}
html body.hub-literature-paper .nvm-op-caption dt,
html body.hub-literature-paper .nvm-op-legend dt,
html body.hub-literature-paper .bc-legend b,
html body.hub-literature-paper .nvm-figure-label strong {
  color: #0f172a !important;
}
html body.hub-literature-paper .nvm-op-caption dd,
html body.hub-literature-paper .nvm-op-legend dd,
html body.hub-literature-paper .nvm-op-caveat,
html body.hub-literature-paper .bc-legend li,
html body.hub-literature-paper .nvm-figure-caption {
  color: #334155 !important;
}
html body.hub-literature-paper .hub-footer,
html body.hub-literature-paper .research-footer,
html body.hub-literature-paper footer {
  background: #fafaf7 !important;
  color: #526a72 !important;
  border-top: 1px solid #cddbdc !important;
}
html body.hub-literature-paper footer a { color: #006f70 !important; }
@media (max-width: 960px) {
  html body.hub-literature-paper .site-header {
    grid-template-columns: auto 1fr auto !important;
  }
  html body.hub-literature-paper .primary-nav { display: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  html body.hub-literature-paper * { animation: none !important; transition: none !important; }
}
