:root {
  color-scheme: light;
  --ink: #172e40;
  --navy: #13364d;
  --secondary: #456070;
  --green: #14684f;
  --green-pale: #e8f4ed;
  --paper: #ffffff;
  --wash: #f2f6f7;
  --line: #cbd9de;
  font-family: "Source Sans 3", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 100%;
  line-height: 1.65;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--wash); color: var(--ink); }
button, input, select, textarea { font: inherit; }
a { color: #135c77; text-underline-offset: .18em; }
a:hover { color: var(--green); }
:focus-visible { outline: 3px solid #1d8196; outline-offset: 3px; }
[hidden] { display: none !important; }
h1, h2, h3, h4, p, ul, ol, dl { margin-top: 0; }
h1, h2, h3, h4 { color: var(--navy); line-height: 1.4; }
h2 { font-size: clamp(1.35rem, 2.5vw, 1.8rem); margin-bottom: .65rem; }
h3 { font-size: 1.14rem; margin: 1.4rem 0 .55rem; }
h4 { font-size: 1rem; margin: 1.1rem 0 .45rem; }
p { margin-bottom: .9rem; }
summary, button, select { cursor: pointer; }
.masthead { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .65rem 1.5rem; min-height: 4rem; background: var(--paper); border-bottom: 1px solid var(--line); padding: .6rem max(4vw, calc((100vw - 73rem) / 2)); }
.masthead > div, .masthead nav { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.masthead a { color: var(--navy); font-weight: 650; text-decoration: none; }
.masthead a:hover { color: var(--green); text-decoration: underline; }
.shell { width: min(92%, 73rem); margin: 0 auto; padding-bottom: 3rem; }
.hero { background: var(--navy); color: #edf6f7; padding: clamp(1.45rem, 4vw, 3.3rem); margin: 1.5rem 0 1.1rem; border-radius: .8rem; border-inline-start: .48rem solid #52ac83; }
.hero h1 { color: white; font-size: clamp(2rem, 4.2vw, 3.3rem); line-height: 1.15; margin: .25rem 0 .8rem; letter-spacing: .015em; }
.hero p { max-width: 55rem; color: #dcecf1; margin-bottom: .4rem; }
.hero small, .hero .muted { color: #c1dce1; }
.tabs { display: flex; flex-wrap: wrap; gap: .35rem; margin: .8rem 0 1.1rem; padding: .35rem; width: fit-content; max-width: 100%; background: #e3ecee; border-radius: .65rem; }
.tabs :is(a,button) { border: 0; background: transparent; color: var(--navy); padding: .48rem .95rem; border-radius: .4rem; font-weight: 650; text-decoration: none; }
.tabs :is(a,button):hover { background: #d4e4e5; }
.tabs :is(.active, .selected, [aria-selected="true"], [aria-current="page"], [aria-pressed="true"]) { background: var(--navy); color: white; }
.panel, .card { background: var(--paper); border: 1px solid var(--line); border-radius: .72rem; min-width: 0; }
.panel { margin: 1rem 0; padding: clamp(1rem, 3.2vw, 2.2rem); }
.card { padding: 1.15rem; margin-bottom: .8rem; }
.panel > :last-child, .card > :last-child { margin-bottom: 0; }
.grid, .metrics { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit,minmax(min(100%, 17rem), 1fr)); align-items: start; }
.metrics { grid-template-columns: repeat(auto-fit,minmax(min(100%, 10rem),1fr)); margin: .85rem 0 1.1rem; }
.metrics > * { border: 1px solid var(--line); border-top: 3px solid var(--green); border-radius: .4rem; background: white; padding: .8rem 1rem; }
.metrics strong { display: block; color: var(--navy); font-size: 1.4rem; }
.muted, small { color: var(--secondary); }
.pill { display: inline-block; font-size: .88rem; background: var(--green-pale); color: #14543f; font-weight: 650; border-radius: 2rem; padding: .13rem .65rem; }
.notice { background: #edf6f5; color: #224c49; border-inline-start: 3px solid #439881; padding: .7rem 1rem; border-radius: .2rem; margin: .9rem 0; }
.notice:empty { display: none; }
form { margin: .85rem 0 1rem; }
.field { display: grid; gap: .25rem; margin-bottom: .85rem; min-width: 0; }
label { color: var(--ink); font-weight: 600; }
input:not([type="checkbox"]):not([type="radio"]), textarea, select {
  display: block; width: 100%; max-width: 100%; padding: .56rem .7rem; border: 1px solid #95aeb8; border-radius: .35rem;
  color: var(--ink); background-color: white; min-height: 2.7rem;
}
select { appearance: none; padding-inline-end: 2.1rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='10' viewBox='0 0 15 10'%3E%3Cpath d='m2 2 5.5 5.5L13 2' fill='none' stroke='%233e5665' stroke-width='1.7'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .8rem center; }
textarea { resize: vertical; min-height: 6rem; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--green); }
button, .actions a { background: var(--green); border: 1px solid var(--green); color: white; font-weight: 650; border-radius: .35rem; padding: .48rem .9rem; text-decoration: none; }
button:hover, .actions a:hover { background: #0e523e; color: white; }
button:disabled { opacity: .55; cursor: not-allowed; }
button.secondary, .actions .secondary { color: var(--navy); background: #f4f8f9; border-color: var(--line); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin: .8rem 0; }
pre, code { overflow-wrap: anywhere; }
pre { white-space: pre-wrap; }
table { width: 100%; border-collapse: collapse; font-size: 1rem; }
td, th { border-bottom: 1px solid var(--line); padding: .7rem; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
thead th { background: #edf3f5; color: var(--navy); font-weight: 650; }
.guide { min-width: 0; }
.guide > p:first-of-type { max-width: 60rem; color: var(--secondary); }
.guide-list { display: grid; gap: .6rem; }
.guide-topic { min-width: 0; border: 1px solid var(--line); border-radius: .55rem; background: white; }
.guide-topic[open] { border-color: #90b7ac; }
.guide-topic summary { display: flex; align-items: baseline; gap: .65rem; padding: .95rem 1.05rem; list-style: none; line-height: 1.55; }
.guide-topic summary::-webkit-details-marker { display: none; }
.guide-topic summary::after { content: "+"; color: var(--green); font-weight: 650; margin-inline-start: auto; }
.guide-topic[open] summary::after { content: "−"; }
.guide-topic[open] summary { background: #f0f7f3; border-radius: .55rem .55rem 0 0; }
.guide-id { color: var(--green); white-space: nowrap; font-size: .9rem; font-weight: 700; }
.guide-body { padding: 1rem 1.1rem; }
.guide-body p { margin: .3rem 0 .7rem; }
.guide-intro { color: var(--secondary); }
.guide-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1.3rem; }
.guide-pair h3 { margin-top: .6rem; }
.guide-readings { list-style: none; margin: 0; padding: 0; }
.guide-readings li { border-top: 1px solid #e2eaec; padding: .6rem 0; overflow-wrap: anywhere; }
.guide-readings li p { color: var(--secondary); margin: .2rem 0 0; }
.guide-readings a { font-weight: 600; }
.guide-question { background: var(--green-pale); border-inline-start: .2rem solid var(--green); padding: .65rem .8rem; margin-top: .9rem; }
.guide-question strong { color: var(--green); }
.guide-question p { margin: .2rem 0; }
.guide-sources { display: flex; gap: .4rem 1.3rem; flex-wrap: wrap; }
.guide-rhythm { padding-inline-start: 1.5rem; }
.guide-rhythm li { margin-bottom: .5rem; }
.plan-scroll { overflow-x: auto; margin: 1.25rem 0; }
.plan-table { min-width: 34rem; }
.plan-table caption { color: var(--navy); font-size: 1.15rem; font-weight: 700; text-align: left; padding: 0 0 .5rem; }
.plan-table tbody th { width: 20%; font-size: .95rem; }
.plan-table tbody td { width: 40%; }
.plan-table small { display: block; font-size: .88rem; white-space: nowrap; font-weight: 400; }
.plan-table p { margin: .15rem 0 0; }
.guide-stages { display: grid; grid-template-columns: max-content 1fr; gap: .6rem 1.1rem; }
.guide-stages dt { color: var(--green); font-weight: 650; }
.guide-stages dd { margin: 0; }
@media (max-width: 42rem) {
  .shell { width: 94%; }
  .masthead { padding: .65rem 3vw; }
  .hero { margin-top: .8rem; }
  .tabs { gap: .2rem; }
  .tabs :is(a,button) { padding: .45rem .6rem; }
  .guide-pair { grid-template-columns: 1fr; gap: .1rem; }
  .guide-topic summary { padding: .75rem; gap: .45rem; }
  .guide-body { padding: .85rem; }
  .guide-stages { grid-template-columns: 1fr; gap: .25rem; }
  .guide-stages dd { margin-bottom: .55rem; }
}
@media print {
  body.print-archive main > :not(#content), body.print-archive #content > :not(#archive) { display: none !important; }
  @page { margin: 14mm; }
  :root { font-size: 10.5pt; }
  body, .panel, .hero, .card { background: white; color: black; }
  .masthead, .tabs, .actions, button, form { display: none !important; }
  .shell { width: 100%; padding: 0; }
  .hero, .panel, .card { border: 0; padding: 0; margin: 0 0 .8rem; }
  .hero h1, .hero p, .hero .muted { color: #172e40; }
  .guide-topic, .guide-question, .plan-table tr { break-inside: avoid; }
  .plan-scroll { overflow: visible; }
  .plan-table { min-width: 0; }
  .plan-table thead { display: table-header-group; }
  a { color: #172e40; }
}
.masthead .shell { padding-bottom: 0; width: 100%; }
#archive dd, #archive article p { white-space: pre-wrap; overflow-wrap: anywhere; }
#archive dt { font-weight: 700; margin-top: .6rem; }
#archive dd { margin-left: 0; }
button.card { text-align: left; background: #fff; color: var(--navy); }
button.card[aria-pressed="true"] { background: var(--green-pale); border: 2px solid var(--green); }
