:root {
  color-scheme: light;
  --background: #f6f8f2;
  --surface: #ffffff;
  --raised: #edf3e9;
  --border: #d9e3d4;
  --ink: #263f30;
  --muted: #536957;
  --quiet: #647464;
  --accent: #38664b;
  --cyan: #488367;
  --mono: "Cascadia Code", Consolas, monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--background); color: var(--ink); font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; line-height: 1.8; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, .graph-node:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
button { color: var(--muted); background: var(--raised); border: 1px solid var(--border); border-radius: 7px; }
[hidden] { display: none !important; }
summary:focus-visible, textarea:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
::selection { background: #53775d; color: white; }
.site-header { border-bottom: 1px solid var(--border); background: #fafcf7; }
.navigation { max-width: 1440px; margin: auto; padding: 21px 36px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { font: 700 14px var(--mono); letter-spacing: .1em; color: var(--ink); white-space: nowrap; }
.brand span { color: var(--quiet); font-weight: 400; }
nav { display: flex; flex-wrap: wrap; gap: 22px; }
nav a { color: var(--muted); font-size: 13px; }
nav a[aria-current="page"] { color: var(--accent); }
.garden-main { max-width: 1440px; margin: auto; padding: 0 36px; }
.garden-hero { display: grid; grid-template-columns: 1.6fr 1fr; align-items: center; gap: 60px; padding: 68px 0 56px; }
.eyebrow { font: 600 11px var(--mono); letter-spacing: .16em; color: var(--accent); }
h1, h2, h3, h4, p { margin-top: 0; }
.garden-hero h1 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.45; letter-spacing: -.025em; margin: 18px 0; }
.garden-hero p { max-width: 620px; font-size: 15px; color: var(--muted); }
.hero-links { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; margin-top: 26px; font-size: 13px; }
.primary-link { display: inline-flex; align-items: center; justify-content: center; border: 1px solid #356249; border-radius: 8px; color: #ffffff; background: #356249; padding: 10px 16px; font-size: 13px; }
.primary-link:hover { background: #254c36; text-decoration: none; }
.garden-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin: 0; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; background: linear-gradient(135deg, #e8f0df, #f3f7ed); }
.garden-stats div { padding: 21px 24px; }
.garden-stats div:nth-child(odd) { border-right: 1px solid var(--border); }
.garden-stats div:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
.garden-stats dt { font-size: 12px; color: var(--muted); }
.garden-stats dd { margin: 3px 0 0; font: 600 30px/1.5 var(--mono); color: var(--ink); }
.garden-stats .version { color: var(--cyan); }
.map-section, .article-section { scroll-margin-top: 20px; }
.system-section { margin-bottom: 46px; scroll-margin-top: 20px; }
.system-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.system-card { min-width: 0; padding: 22px; border: 1px solid var(--border); border-radius: 12px; background: #fcfdf9; }
.system-card h3 { font-size: 17px; line-height: 1.6; margin: 12px 0 10px; }
.system-card p { font-size: 12px; color: var(--muted); margin-bottom: 14px; }
.system-card ul { list-style: none; padding: 0; margin: 0; }
.system-card li + li { margin-top: 6px; }
.system-card li a { display: block; font-size: 13px; padding: 4px 0; }
.system-deep-link { display: block; margin-top: 12px; font-size: 11px; }
.system-note { color: var(--muted); font-size: 12px; margin: 16px 0 0; }
@media print {
  .site-header, .reader-sidebar, .back-link, .site-footer { display: none; }
  .reader-main { max-width: none; padding: 0; }
  .reader-layout { display: block; }
}
@media (max-width: 1160px) { .system-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .system-grid { grid-template-columns: 1fr; } .system-card { padding: 18px; } }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin: 0 0 21px; }
.section-heading h2 { font-size: 24px; line-height: 1.5; margin: 8px 0 0; }
.section-heading > p { margin: 0; font-size: 12px; color: var(--quiet); }
.knowledge-workbench { display: grid; grid-template-columns: 225px minmax(0, 1fr) 250px; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; min-height: 620px; background: var(--surface); }
.notes-panel { padding: 20px 16px; border-right: 1px solid var(--border); min-width: 0; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-heading h3 { font-size: 14px; margin: 0; }
.panel-heading > span { color: var(--quiet); font: 12px var(--mono); }
.search-label { display: block; font-size: 11px; color: var(--quiet); margin-bottom: 7px; }
input[type="search"] { width: 100%; border: 1px solid var(--border); border-radius: 7px; background: #f8faf6; color: var(--ink); padding: 10px; font-size: 12px; }
input::placeholder { color: var(--quiet); }
.kind-filters { display: flex; flex-wrap: wrap; gap: 5px; margin: 13px 0 18px; }
.kind-filters button { padding: 3px 7px; font-size: 11px; background: transparent; }
.kind-filters button[aria-pressed="true"] { color: #284e36; border-color: #9ab592; background: #e5efdf; }
.note-list { display: grid; gap: 4px; max-height: 450px; overflow-y: auto; scrollbar-color: #c4d4bd transparent; }
.note-row { display: flex; align-items: flex-start; gap: 9px; padding: 9px 7px; border-radius: 7px; color: #3e5544; font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; }
.note-row small { display: block; font-size: 10px; color: var(--quiet); margin-top: 3px; }
.note-row:hover, .note-row.is-selected { background: var(--raised); text-decoration: none; }
.node-dot { width: 7px; height: 7px; flex: 0 0 7px; margin-top: 6px; border-radius: 50%; background: var(--node-color); }
.kind-concept { --node-color: #578260; }
.kind-pattern { --node-color: #6a9c8f; }
.kind-practice { --node-color: #ad8b51; }
.kind-article { --node-color: #78909a; }
.graph-panel { display: flex; flex-direction: column; min-width: 0; background: radial-gradient(ellipse at 40% 50%, #f1f6eb, #f9fcf6 75%); }
.graph-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; padding: 15px 18px; gap: 10px; border-bottom: 1px solid #dfe8d9; }
.graph-toolbar label { color: var(--quiet); font-size: 11px; }
.graph-toolbar select { max-width: 130px; background: #ffffff; border: 1px solid var(--border); border-radius: 5px; color: var(--muted); padding: 4px 8px; font-size: 11px; }
.graph-controls { display: flex; gap: 5px; }
.graph-controls button { padding: 3px 9px; min-width: 30px; font-size: 12px; }
.graph-stage { position: relative; flex: 1; min-height: 390px; display: flex; align-items: center; overflow: hidden; }
.graph-stage svg { display: block; width: 100%; height: 100%; min-height: 390px; touch-action: pan-y; }
.graph-loading { position: absolute; inset: 40% 30px auto; text-align: center; font-size: 12px; color: var(--quiet); pointer-events: none; }
.graph-node { cursor: pointer; transition: opacity .2s; }
.graph-node circle { fill: var(--node-color); stroke: #f5f8ef; stroke-width: 5px; }
.graph-node .graph-hitbox { fill: transparent; stroke: none; }
.graph-node text { fill: #37583f; font-size: 23px; text-anchor: middle; transition: opacity .15s; }
.graph-node.is-low-label text { opacity: 0; }
.graph-node.is-low-label:hover text,
.graph-node.is-low-label:focus text,
.graph-node.is-low-label.is-selected text { opacity: 1; }
.graph-node.is-selected circle { stroke: #234e34; stroke-width: 5px; }
.graph-node.is-selected text { fill: #234e34; font-weight: 600; }
.graph-node.is-muted { opacity: .5; }
.graph-edge { stroke: #abc1a4; stroke-width: 1.8; opacity: .55; }
.graph-edge.is-connected { stroke: #668a68; stroke-width: 2.7; opacity: .9; }
.graph-edge.is-muted { opacity: .13; }
.graph-arrow { fill: #6e906f; }
.is-filtered { display: none; }
.graph-legend { display: flex; justify-content: center; flex-wrap: wrap; gap: 16px; padding: 7px 12px; color: var(--muted); font-size: 11px; }
.graph-legend span { display: inline-flex; align-items: center; gap: 6px; }
.graph-legend i { width: 7px; height: 7px; border-radius: 50%; background: var(--node-color); }
.graph-caption { padding: 10px 18px 17px; text-align: center; margin: 0; color: var(--quiet); font-size: 10px; }
.detail-panel { border-left: 1px solid var(--border); padding: 22px 19px; overflow-wrap: anywhere; min-width: 0; }
.detail-panel h3 { font-size: 19px; line-height: 1.6; margin: 13px 0 12px; }
.detail-summary { color: var(--muted); font-size: 12px; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 7px; margin: 18px 0; }
.detail-meta span { color: var(--muted); background: #eaf1e4; border-radius: 4px; font-size: 10px; padding: 2px 7px; }
.detail-panel h4 { margin: 24px 0 12px; font-size: 12px; color: var(--muted); }
.detail-relations { list-style: none; padding: 0; margin: 0; max-height: 265px; overflow-y: auto; }
.detail-relations li { border-bottom: 1px solid #e3eadf; padding: 8px 0; font-size: 11px; line-height: 1.65; }
.detail-relations span { display: block; color: var(--quiet); font-size: 10px; }
.small-note { font-size: 10px; color: var(--quiet); line-height: 1.85; margin: 20px 0 0; }
.muted, .empty { color: var(--quiet); }
.search-empty { font-size: 12px; color: var(--quiet); }
.article-section { padding-top: 56px; }
.article-list { display: grid; gap: 18px; }
.article-card { display: block; padding: 28px 30px; border: 1px solid var(--border); border-radius: 12px; background: linear-gradient(110deg, #ffffff, #f0f5ea); color: var(--ink); }
.article-card:hover { border-color: #96b08b; text-decoration: none; }
.article-card h3 { font-size: 23px; margin: 13px 0 12px; line-height: 1.6; }
.article-card p { font-size: 14px; color: var(--muted); margin-bottom: 14px; }
.article-arrow { font-size: 12px; color: var(--accent); }
.garden-principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin: 40px 0 64px; }
.garden-principles article { border-top: 1px solid var(--border); padding-top: 20px; }
.garden-principles article > span { font: 10px var(--mono); color: var(--quiet); }
.garden-principles h3 { font-size: 15px; margin: 13px 0 10px; }
.garden-principles p { font-size: 12px; color: var(--muted); }
.site-footer { max-width: 1440px; padding: 25px 36px 35px; margin: auto; border-top: 1px solid var(--border); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 11px; color: var(--quiet); }
.reader-main { max-width: 1180px; padding: 36px 36px 64px; margin: auto; }
.back-link { display: inline-block; font-size: 12px; margin-bottom: 30px; }
.reader-layout { display: grid; grid-template-columns: minmax(0, 760px) 240px; gap: 56px; align-items: start; }
.note-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.note-badges span { font-size: 11px; padding: 3px 10px; border: 1px solid #bacfb0; border-radius: 5px; color: #456b4c; }
.note-article h1 { font-size: clamp(28px, 3vw, 39px); line-height: 1.5; letter-spacing: -.02em; margin: 18px 0; overflow-wrap: anywhere; }
.note-deck { color: var(--muted); font-size: 15px; padding: 14px 18px; border-left: 3px solid #9db98b; background: #f0f5ea; border-radius: 0 8px 8px 0; }
.note-deck b { display: block; margin-bottom: 4px; color: var(--accent); font: 600 11px var(--mono); letter-spacing: .08em; }
.note-dates { display: flex; flex-wrap: wrap; gap: 14px; font-size: 10px; color: var(--quiet); }
.note-tags { display: flex; flex-wrap: wrap; gap: 9px; margin: 15px 0 34px; }
.note-tags span { font-size: 11px; color: var(--quiet); }
.note-tags span::before { content: "#"; color: var(--accent); margin-right: 2px; }
.prose { font-size: 15px; line-height: 2; color: #3e5544; overflow-wrap: anywhere; }
.prose h2 { color: var(--ink); font-size: 23px; margin: 38px 0 18px; line-height: 1.6; scroll-margin-top: 24px; }
.prose h3 { color: var(--ink); font-size: 18px; margin: 24px 0 12px; }
.prose p { margin-bottom: 18px; }
.prose strong { color: #233f2d; font-weight: 600; }
.prose ul, .prose ol { padding-left: 25px; }
.prose li + li { margin-top: 8px; }
.prose .wiki-link { border-bottom: 1px solid #a2bc98; }
.prose a:hover { text-decoration: none; border-bottom-color: var(--accent); }
.prose code { font: .88em var(--mono); background: #eaf1e4; color: #355b40; border-radius: 4px; padding: 2px 5px; }
.prose pre { overflow-x: auto; padding: 18px; background: #edf3e8; border: 1px solid var(--border); border-radius: 8px; }
.prose pre code { padding: 0; background: none; line-height: 1.8; }
.prose blockquote { border-left: 3px solid var(--accent); margin: 20px 0; padding: 12px 20px; background: #edf3e6; }
.prose blockquote p:last-child { margin-bottom: 0; }
.prose table { border-collapse: collapse; display: block; max-width: 100%; overflow-x: auto; font-size: 13px; }
.prose th, .prose td { border: 1px solid var(--border); padding: 9px 12px; }
.prose img { max-width: 100%; }
.prose hr { border: none; border-top: 1px solid var(--border); margin: 30px 0; }
.reader-sidebar { padding-top: 10px; }
.reader-sidebar section { border-top: 1px solid var(--border); padding-top: 18px; margin-bottom: 26px; }
.reader-sidebar h2 { font-size: 13px; margin: 8px 0 12px; }
.reader-sidebar h2 small { font: 11px var(--mono); color: var(--quiet); margin-left: 6px; }
.toc, .relation-list { list-style: none; padding: 0; margin: 0; font-size: 12px; }
.toc li { margin-bottom: 8px; }
.toc a { color: var(--muted); }
.relation-list li { padding: 7px 0; border-bottom: 1px solid #dce6d6; }
.relation-list span { color: var(--quiet); font-size: 10px; margin-right: 7px; }
.backlinks span { display: block; }
.reading-end { border-top: 1px solid var(--border); margin-top: 38px; padding-top: 18px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 11px; color: var(--quiet); }
.notice { color: var(--muted); font-size: 13px; padding: 16px; border: 1px solid var(--border); }
@media (max-width: 1160px) {
  .knowledge-workbench { grid-template-columns: 210px minmax(0, 1fr); }
  .detail-panel { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--border); }
  .detail-relations { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; max-height: none; }
  .detail-panel .small-note { max-width: 700px; }
  .reader-layout { grid-template-columns: minmax(0, 1fr) 220px; gap: 32px; }
}
@media (max-width: 760px) {
  .navigation { padding: 18px 20px; flex-direction: column; align-items: flex-start; gap: 12px; }
  nav { gap: 16px; }
  .garden-main { padding: 0 20px; }
  .garden-hero { grid-template-columns: 1fr; gap: 28px; padding: 40px 0; }
  .garden-hero h1 { font-size: 32px; }
  .garden-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .garden-stats div { padding: 12px 8px; text-align: center; }
  .garden-stats div:nth-child(-n+2) { border-bottom: 0; }
  .garden-stats div + div { border-left: 1px solid var(--border); }
  .garden-stats div:nth-child(odd) { border-right: 0; }
  .garden-stats dt { font-size: 10px; }
  .garden-stats dd { font-size: 21px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 9px; }
  .section-heading h2 { font-size: 21px; }
  .knowledge-workbench { grid-template-columns: 1fr; }
  .notes-panel { border-right: 0; border-bottom: 1px solid var(--border); }
  .note-list { max-height: 155px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .graph-stage, .graph-stage svg { min-height: 290px; height: 290px; }
  .graph-toolbar { padding: 12px 15px; }
  .graph-legend { gap: 13px; }
  .detail-relations { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-section { padding-top: 40px; }
  .article-card { padding: 22px; }
  .article-card h3 { font-size: 21px; }
  .garden-principles { grid-template-columns: 1fr; gap: 10px; margin-bottom: 36px; }
  .site-footer { padding: 22px 20px; }
  .reader-main { padding: 26px 20px 40px; }
  .reader-layout { grid-template-columns: 1fr; gap: 36px; }
  .reader-sidebar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
  .reader-sidebar section:first-child, .reader-sidebar > p { grid-column: 1 / -1; }
  .prose { font-size: 14px; }
  .prose h2 { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* Sage garden, reading-first layout. */
body { background-image: radial-gradient(ellipse at 80% 0%, #e9f0df 0, transparent 44%); }
.garden-main, .navigation, .site-footer { max-width: 1560px; }
.site-header { background: #fafcf7e8; }
.garden-hero { padding: 62px 0 40px; gap: 7vw; }
.garden-hero h1 { font-family: "Noto Serif SC", "Songti SC", SimSun, serif; font-weight: 500; font-size: clamp(36px, 4vw, 56px); line-height: 1.4; letter-spacing: .025em; }
.garden-hero p { max-width: 610px; line-height: 2; }
.garden-stats { border-radius: 50% 50% 14px 14px; padding: 35px 20px 20px; max-width: 390px; background: linear-gradient(150deg,#e4eedb,#f8faf5); border-color: #c7d8bd; position: relative; }
.garden-stats::before { content: 'GROW AT YOUR OWN PACE'; grid-column: 1 / -1; text-align: center; color:#65805d; font: 10px var(--mono); letter-spacing: .16em; padding: 14px 0; }
.garden-stats dd { font-weight: 400; font-size: 34px; }
.garden-stats div:nth-child(-n+2) { border-bottom: none; }
.learning-trail { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; margin-bottom: 54px; }
.learning-trail a { padding: 17px 22px; background: #fbfcf8; color: var(--ink); display: flex; gap: 14px; align-items: center; font-size: 13px; }
.learning-trail a:hover { background: #edf4e6; text-decoration: none; }
.learning-trail b { color: #73906a; font: 18px Georgia,serif; }
.learning-trail small { display:block; color: var(--muted); font-size:11px; }
.knowledge-workbench { grid-template-columns: 200px minmax(0,1fr) 238px; box-shadow: 0 14px 48px #32533108; }
.graph-stage { min-height: 460px; background-image: radial-gradient(#a7bf9b55 .75px, transparent .75px); background-size: 22px 22px; }
.graph-stage svg { min-height: 460px; }
.graph-node text { font-size: 18px; fill:#37583f; }
.graph-node .node-card { fill: #fff; stroke: #c4d5ba; stroke-width: 1.5; }
.graph-node .node-index { font-size: 12px; fill:#718968; letter-spacing:1px; }
.graph-node .node-subtitle { font-size: 12px; fill:#67805e; }
.graph-node .node-dot-svg { fill:var(--node-color); stroke:none; }
.graph-node.is-selected .node-card, .graph-node:hover .node-card { fill:#e5efdd; stroke:#668b59; stroke-width:2; }
.graph-node:focus-visible { outline:none; }
.graph-node:focus-visible .node-card { stroke:#285f3c; stroke-width:3; }
.graph-node.is-muted { opacity: .72; }
.graph-node .root-core { fill:#dae8cc; stroke:#bdd0ae; stroke-width:1.5; }
.graph-node.is-selected .root-core { stroke:#688858; stroke-width:2; }
.graph-orbit { fill:none; stroke:#cadac2; stroke-dasharray:4 8; stroke-width:1; }
.graph-edge { stroke-width:1.2; opacity:.32; fill:none; }
.graph-edge.is-connected { stroke:#5c865e; stroke-width:2; opacity:.85; }
.graph-edge.is-muted { opacity:.06; }
.graph-mode { display:flex; gap:4px; }
.graph-mode button { padding:4px 9px; font-size:11px; background:white; }
.graph-mode button[aria-pressed="true"] { background:#e3eddc; color:#315839; border-color:#acc5a0; }
.graph-toolbar { padding:12px; }
.graph-caption { font-size:11px; }
.article-list { grid-template-columns:repeat(3,minmax(0,1fr)); }
.article-card { padding:25px; background:#fcfdf9; border-radius:12px; }
.article-card h3 { font-size:21px; }
.article-card .eyebrow { font-size:10px; letter-spacing:.06em; }
.note-article { min-width:0; }
.reader-main { max-width:1250px; }
.reader-layout { grid-template-columns:minmax(0,800px) 235px; }
.note-article h1 { font-family:"Noto Serif SC","Songti SC",SimSun,serif; font-weight:600; }
.prose { font-size:16px; line-height:2.05; }
.prose h2 { padding-bottom:10px; border-bottom:1px solid var(--border); margin-top:44px; }
.prose th { background:#e9f1e1; text-align:left; }
.prose td { background:#fcfdf9; }
.prose .align-right { text-align:right; } .prose .align-center { text-align:center; } .prose .align-left { text-align:left; }
.prose img { display:block; width:100%; height:auto; border-radius:12px; border:1px solid #d9e4d2; }
.diagram-link { display:block; margin-top:26px; }
.figure-caption { display:block; font-size:12px; color:var(--muted); line-height:1.8; margin:9px 0 25px; }
.math-block { max-width:100%; overflow-x:auto; padding:24px 20px; margin:24px 0; background:#eef4e7; border:1px solid #d8e5ce; border-left:3px solid #8bab78; border-radius:8px; color:#294631; }
.math-block math { font-family:"Cambria Math",math; font-size:1.12em; }
.math-block:focus-visible { outline:2px solid #668b59; }
.reader-sidebar { position:sticky; top:24px; max-height:calc(100vh - 48px); overflow:auto; scrollbar-width:thin; }
.toc a:hover { color:var(--accent); }
@media(min-width:1161px) { .graph-stage svg { height:540px; } }
@media(max-width:1160px) { .knowledge-workbench { grid-template-columns:190px minmax(0,1fr); } .article-list { grid-template-columns:1fr; } .detail-panel { grid-column:1/-1; } }
@media(max-width:760px) {
 .garden-main { padding:0 16px; } .garden-hero { padding:32px 0; gap:20px; } .garden-hero h1 { font-size:38px; }
 .garden-stats { max-width:none; border-radius:12px; padding:8px 0; } .garden-stats::before { display:none; } .garden-stats dd { font-size:25px; }
 .learning-trail { grid-template-columns:repeat(2,minmax(0,1fr)); margin-bottom:36px; } .learning-trail a { padding:13px 14px; gap:10px; }
 .knowledge-workbench { display:flex; flex-direction:column; } .graph-panel { order:0; } .notes-panel { order:2; border-top:1px solid var(--border); } .detail-panel { order:1; }
 .graph-stage { height:auto; min-height:330px; } .graph-stage svg,.graph-stage svg.is-expanded { height:auto; min-height:0; } .graph-toolbar { gap:8px; } .graph-toolbar select { max-width:96px; }
 .graph-node text { font-size:23px; } .graph-node .node-subtitle { font-size:17px; }
 .graph-legend { gap:10px; } .graph-caption { padding:10px 12px; }
 .reader-main { padding:24px 18px 40px; } .reader-layout { display:block; } .reader-sidebar { position:static; max-height:none; margin-top:36px; }
 .prose { font-size:15px; } .prose table { font-size:12px; } .math-block { padding:20px 12px; font-size:14px; }
 .detail-relations { max-height:210px; overflow:auto; } .note-list { max-height:230px; }
}

.knowledge-workbench { grid-template-columns: minmax(0, 1fr) 270px; }
.graph-panel { grid-column: 1; grid-row: 1; background: #f7faf4; }
.detail-panel { grid-column: 2; grid-row: 1; padding: 26px 22px; background: #fcfdf9; }
.detail-panel h3 { font-size: 21px; }
.detail-relations { max-height: 500px; }
.notes-panel { grid-column: 1 / -1; grid-row: 2; border-right: 0; border-top: 1px solid var(--border); padding: 22px 24px; }
.notes-panel input { max-width: 360px; }
.notes-panel .kind-filters { display: inline-flex; vertical-align: middle; margin: 0 0 0 18px; }
.notes-panel .note-list { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px 18px; max-height: 190px; margin-top: 18px; }
.graph-shortcuts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 14px 20px 0; font-size: 12px; }
.graph-shortcuts > span { color: var(--muted); font-size: 11px; }
.graph-shortcuts a { padding: 5px 9px; border: 1px solid var(--border); border-radius: 6px; background: #fff; font-size: 12px; }
.graph-toolbar { padding: 14px 20px; border-bottom: 0; }
.graph-help { font-size: 12px; color: var(--muted); }
.graph-controls button { min-width: 32px; min-height: 32px; background: #fff; }
.graph-options { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; padding: 0 20px 14px; border-bottom: 1px solid var(--border); }
.graph-options label { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); }
.graph-options input[type="range"] { width: 120px; accent-color: #4a7856; cursor: pointer; }
.graph-options select, .graph-options button { font-size: 11px; padding: 5px 9px; border: 1px solid var(--border); border-radius: 6px; color: var(--muted); background: #fff; }
.graph-options button:disabled { opacity: .4; cursor: default; }
.graph-stage { display: block; flex: none; min-height: 0; height: auto; background-image: radial-gradient(#b9cbb144 .65px, transparent .65px); background-size: 28px 28px; }
.graph-stage svg { display: block; width: 100%; height: auto; min-height: 0; touch-action: pan-y; cursor: grab; }
.graph-stage svg:active { cursor: grabbing; }
.graph-stage svg.is-dragging { cursor: grabbing; }
.graph-stage svg.is-dragging .graph-node, .graph-stage svg.is-dragging .graph-edge { pointer-events: none; }
.graph-stage svg:focus-visible { outline: 2px solid var(--accent); outline-offset: -3px; }
.graph-node { transition: opacity .16s; }
.graph-node .node-aura { fill: var(--node-color); fill-opacity: .11; stroke: none; }
.graph-node .node-sphere { fill: var(--node-color); stroke: #f7faf4; stroke-width: 2; }
.graph-node.rank-0 .node-sphere { fill: #365e43; stroke-width: 3; }
.graph-node .root-label { fill: #fff; font: 600 14px "Segoe UI", sans-serif; text-anchor: middle; }
.graph-node .node-label { fill: #344e3c; font-size: 13px; font-weight: 400; text-anchor: middle; paint-order: stroke; stroke: #f7faf4; stroke-width: 4px; stroke-linejoin: round; }
.graph-node.rank-1 .node-label { font-weight: 600; }
.node-label-hit { fill: transparent; stroke: none; }
.node-label-leader { stroke: #b1c4a9; stroke-width: .8; pointer-events: none; }
.graph-node.is-selected .node-label-hit, .graph-node.is-hovered .node-label-hit { fill: #edf4e7; }
.graph-node.is-selected .node-sphere, .graph-node.is-hovered .node-sphere { stroke: #2e5e3e; stroke-width: 2.5; }
.graph-node.is-selected .node-aura, .graph-node.is-hovered .node-aura { fill-opacity: .22; stroke: none; }
.graph-node.is-dimmed { opacity: .28; }
.graph-node.is-matched .node-sphere { stroke: #2e5e3e; stroke-width: 3; }
.graph-node:focus-visible { outline: none; }
.graph-node:focus-visible .node-aura { stroke: #2e5e3e; stroke-width: 2; }
.graph-edge { fill: none; stroke: #819b86; stroke-width: .85; opacity: .15; pointer-events: stroke; transition: opacity .16s; }
.graph-edge.is-mention { opacity: .075; }
.graph-edge.is-structural { stroke: #66886b; stroke-width: 1.3; opacity: .48; }
.graph-edge.is-connected { stroke: #3f7a54; stroke-width: 1.7; opacity: .84; }
.graph-edge.is-incoming { stroke: #a18454; }
.graph-edge.is-dimmed { opacity: .035; }
.graph-edge:hover { stroke: #2e6443; stroke-width: 2; opacity: 1; }
.graph-arrow { fill: #6d8c70; }
.graph-caption { font-size: 11px; padding: 8px 20px; }
.graph-counts { font: 12px var(--mono); color: #426447; padding-top: 14px; }
.graph-legend { padding-bottom: 18px; }
.is-compact .rank-2 .node-label-group, .is-compact .rank-3 .node-label-group { display: none; }
.is-compact .graph-node[data-node-id="knowledge-graph-engineering"] .node-label-group { display: block; }
.is-compact .graph-node.is-selected .node-label-group, .is-compact .graph-node.is-hovered .node-label-group, .is-compact .graph-node.is-matched .node-label-group { display: block; }
.graph-panel:fullscreen { display: block; width: 100%; height: 100%; overflow: auto; background: #f7faf4; }
@media (max-width: 1160px) {
  .knowledge-workbench { grid-template-columns: minmax(0, 1fr); }
  .graph-panel { grid-column: 1; grid-row: 1; }
  .detail-panel { grid-column: 1; grid-row: 2; border-left: 0; border-top: 1px solid var(--border); }
  .notes-panel { grid-column: 1; grid-row: 3; }
  .notes-panel .note-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .graph-shortcuts { padding: 12px 12px 0; gap: 7px; }
  .graph-toolbar { padding: 12px; gap: 8px; }
  .graph-help { font-size: 11px; }
  .graph-controls { margin-left: auto; }
  .graph-options { padding: 0 12px 12px; gap: 9px; }
  .graph-options input[type="range"] { width: 88px; }
  .graph-options select { max-width: 85px; }
  .detail-panel, .notes-panel { padding: 20px 16px; }
  .notes-panel .kind-filters { margin: 12px 0 0; display: flex; }
  .notes-panel .note-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .graph-caption { padding: 8px 12px; }
  .detail-relations { max-height: 250px; }
}
