:root {
  color-scheme: light;
  --field: #d9effb;
  --field-deep: #c6e6f7;
  --paper: #f7f2e8;
  --paper-clean: #fffdf8;
  --ink: #071b34;
  --muted: #5c6875;
  --blue: #0875e8;
  --blue-deep: #054ba7;
  --blue-soft: #a9d7ff;
  --signal: #ef493b;
  --line: rgba(7, 27, 52, .17);
  --hairline: rgba(8, 117, 232, .34);
  --header-h: 66px;
  --radius: 4px;
  --shadow-paper: 0 23px 35px rgba(15, 47, 68, .22), 0 4px 7px rgba(15, 47, 68, .14);
  --shadow-soft: 0 13px 24px rgba(15, 47, 68, .17), 0 2px 4px rgba(15, 47, 68, .12);
  --ease: cubic-bezier(.22, .8, .24, 1);
  font-family: "Avenir Next", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 28px);
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% 0, rgba(255, 255, 255, .72), transparent 36rem),
    linear-gradient(135deg, var(--field) 0%, var(--field-deep) 100%);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
img { max-width: 100%; }

button:focus-visible,
a:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--blue) 72%, white);
  outline-offset: 4px;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 8px;
  left: 8px;
  padding: 10px 14px;
  background: var(--ink);
  color: white;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 180ms var(--ease);
}
.skip-link:focus { transform: translateY(0); }

.topbar {
  position: sticky;
  z-index: 100;
  top: 0;
  height: var(--header-h);
  padding: 0 clamp(22px, 3.2vw, 52px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(7, 27, 52, .22);
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 3px 8px rgba(25, 55, 74, .12);
  backdrop-filter: blur(16px);
}

.brand {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.brand-type { display: grid; line-height: 1.05; }
.brand-type b { font-size: 18px; font-weight: 850; letter-spacing: -.04em; }
.brand-type small { margin-top: 6px; color: var(--blue); font-size: 8px; font-weight: 800; letter-spacing: .18em; }

.header-actions { display: flex; align-items: center; gap: 10px; }
.header-rule { width: 1px; height: 27px; margin-inline: 2px 4px; background: rgba(7, 27, 52, .22); }
.icon-button {
  min-width: 44px;
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: color 180ms var(--ease), transform 180ms var(--ease);
}
.icon-button:hover { color: var(--blue); }
.icon-button:active { transform: scale(.96); }
.icon-button svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.search-trigger span { font-size: 14px; font-weight: 750; }
.menu-toggle { display: none; }
.menu-toggle svg { width: 26px; height: 26px; }
.reader-mode .menu-toggle { display: inline-flex; }
.home-mode .header-rule, .home-mode .menu-toggle { display: none; }

.reading-progress {
  position: fixed;
  z-index: 201;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  pointer-events: none;
}
.reading-progress span { display: block; width: 0; height: 100%; background: var(--blue); }

.loading-state {
  min-height: calc(100vh - var(--header-h));
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 16px;
  color: var(--muted);
}
.loading-orbit { width: 42px; height: 42px; border: 2px solid rgba(7, 27, 52, .2); border-top-color: var(--blue); border-radius: 50%; animation: spin 800ms linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Home — an archival field manual on a blue worktable */
.home { padding-bottom: 24px; overflow: clip; }
.hero { padding: clamp(16px, 2vw, 28px) clamp(12px, 3vw, 44px) 0; }
.desk-scene {
  position: relative;
  width: min(1360px, 100%);
  height: clamp(600px, calc(100vh - var(--header-h) - 48px), 720px);
  min-height: 600px;
  margin: 0 auto;
}
.desk-scene::before {
  content: "";
  position: absolute;
  inset: 1% 5% 3%;
  border-radius: 50%;
  background: rgba(73, 149, 191, .18);
  filter: blur(42px);
}

.paper-stack {
  position: absolute;
  z-index: 2;
  inset: 7% 18% 7% 12.6%;
  pointer-events: none;
}
.paper-stack i {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(7, 27, 52, .22);
  background: #eee9dd;
  box-shadow: var(--shadow-paper);
  transform: rotate(-.7deg) translate(-8px, 9px);
}
.paper-stack i:last-child { transform: rotate(.45deg) translate(8px, 2px); background: #f4efe5; }

.manual-cover {
  position: absolute;
  z-index: 4;
  inset: 5% 19.8% 8.5% 13.8%;
  min-width: 0;
  border: 1px solid rgba(7, 27, 52, .23);
  border-radius: 3px 8px 4px 4px;
  background:
    linear-gradient(rgba(249, 245, 235, .9), rgba(249, 245, 235, .9)),
    url("/assets/paper-texture-v1.jpg") center / 700px auto repeat;
  background-blend-mode: normal, multiply;
  box-shadow: var(--shadow-paper);
}
.manual-cover::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  width: 12px;
  height: 98px;
  border-radius: 0 0 11px 0;
  background: var(--field);
  box-shadow: 2px 0 2px rgba(7, 27, 52, .08);
}

.cover-rule { position: absolute; top: 17%; left: 10%; right: 9%; border-top: 2px solid var(--blue); }
.cover-rule::after { content: ""; position: absolute; right: 0; top: -2px; width: 32%; border-top: 2px dotted rgba(8, 117, 232, .35); }
.cover-copy { position: absolute; z-index: 2; inset: 25% 9% 23% 11%; }
.eyebrow { margin: 0 0 23px; color: var(--blue); font-size: 10px; font-weight: 850; letter-spacing: .15em; }
.cover-copy h1 { margin: 0; color: var(--ink); font-size: clamp(64px, 7vw, 108px); font-weight: 900; line-height: .96; letter-spacing: -.075em; white-space: nowrap; }
.cover-copy h1 span { display: inline; }
.hero-lede { margin: 26px 0 0; color: var(--ink); font-size: clamp(19px, 2vw, 30px); line-height: 1.72; letter-spacing: -.035em; }
.cover-meta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding-top: 13px;
  border-top: 1px dotted var(--hairline);
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 11px;
  color: var(--blue);
  font: 800 9px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .08em;
}
.cover-meta b { justify-self: end; font-weight: 800; }

.ribbon-cta {
  position: absolute;
  z-index: 8;
  left: -1.5%;
  right: -6%;
  bottom: 4.4%;
  min-height: 80px;
  padding: 0 11%;
  display: flex;
  align-items: center;
  gap: 28px;
  background: #111820;
  color: white;
  box-shadow: 0 8px 18px rgba(7, 27, 52, .28);
  text-decoration: none;
  transition: background 180ms var(--ease), transform 180ms var(--ease);
}
.ribbon-cta::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 0;
  border-top: 22px solid #111820;
  border-right: 70px solid transparent;
}
.ribbon-cta span { font-size: clamp(24px, 2.5vw, 36px); font-weight: 850; letter-spacing: -.04em; }
.ribbon-cta svg { width: 36px; height: 36px; fill: none; stroke: currentColor; stroke-width: 1.6; transition: transform 180ms var(--ease); }
.ribbon-cta:hover { background: var(--blue-deep); transform: translateX(5px); }
.ribbon-cta:hover::after { border-top-color: var(--blue-deep); }
.ribbon-cta:hover svg { transform: translateX(7px); }

.fold-corner {
  position: absolute;
  z-index: 6;
  right: -1px;
  bottom: -1px;
  width: 105px;
  height: 105px;
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
  background:
    repeating-linear-gradient(0deg, transparent 0 10px, rgba(255,255,255,.4) 10px 11px),
    repeating-linear-gradient(90deg, transparent 0 10px, rgba(255,255,255,.4) 10px 11px),
    #71b6f7;
  box-shadow: -5px -5px 7px rgba(7, 27, 52, .12);
}
.registration-mark { position: absolute; z-index: 4; top: 14.3%; right: 4.3%; width: 20px; height: 20px; border: 1px solid var(--signal); border-radius: 50%; }
.registration-mark::before, .registration-mark::after { content: ""; position: absolute; background: var(--signal); }
.registration-mark::before { width: 30px; height: 1px; top: 9px; left: -6px; }
.registration-mark::after { width: 1px; height: 30px; top: -6px; left: 9px; }

.binder-clip {
  position: absolute;
  z-index: 10;
  top: -13px;
  right: 10%;
  width: 84px;
  height: 55px;
  border-radius: 2px 2px 9px 9px;
  background: #111;
  box-shadow: 0 4px 4px rgba(7, 27, 52, .24), inset 0 -8px 0 rgba(255,255,255,.08);
}
.binder-clip::before, .binder-clip::after {
  content: "";
  position: absolute;
  bottom: -4px;
  width: 14px;
  height: 18px;
  border-radius: 2px;
  background: #050505;
}
.binder-clip::before { left: -5px; transform: rotate(8deg); }
.binder-clip::after { right: -5px; transform: rotate(-8deg); }
.binder-clip i {
  position: absolute;
  left: 50%;
  bottom: 39px;
  width: 44px;
  height: 50px;
  border: 3px solid #77818a;
  border-bottom: 0;
  border-radius: 50% 50% 5px 5px;
  transform: translateX(-50%) perspective(50px) rotateX(-18deg);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.7);
}

.left-tabs { position: absolute; z-index: 3; top: 13%; left: 5%; display: grid; gap: 4px; }
.binder-tab {
  position: relative;
  width: 145px;
  height: 112px;
  padding: 24px 24px 18px;
  border: 1px solid rgba(3, 39, 93, .42);
  border-radius: 10px 0 0 10px;
  display: grid;
  align-content: center;
  color: white;
  background: linear-gradient(135deg, #3b9ff1, #1274d6);
  box-shadow: 0 10px 16px rgba(7, 46, 95, .2);
  text-decoration: none;
  transition: width 180ms var(--ease), filter 180ms var(--ease);
}
.binder-tab::after { content: ""; position: absolute; top: -1px; right: -12px; width: 23px; height: 100%; background: inherit; clip-path: polygon(0 0, 50% 0, 50% 30%, 100% 40%, 50% 50%, 50% 100%, 0 100%); }
.binder-tab strong { font: 850 26px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.binder-tab span { width: fit-content; margin-top: 13px; padding-bottom: 5px; border-bottom: 1px solid currentColor; font-size: 14px; }
.binder-tab.tab-2 { background: linear-gradient(135deg, #0875e8, #045fc4); }
.binder-tab.tab-3 { background: linear-gradient(135deg, #075cc5, #023a91); }
.binder-tab:hover { width: 158px; filter: brightness(1.08); }

.right-slips { position: absolute; z-index: 3; top: 14%; right: 2.3%; width: 275px; display: grid; gap: 8px; }
.task-slip {
  position: relative;
  min-height: 124px;
  padding: 17px 38px 20px 27px;
  border: 1px solid rgba(7, 27, 52, .34);
  display: grid;
  align-content: space-between;
  color: var(--ink);
  background: linear-gradient(rgba(253, 250, 244, .9), rgba(253, 250, 244, .9)), url("/assets/paper-texture-v1.jpg") center / 440px auto;
  box-shadow: var(--shadow-soft);
  clip-path: polygon(0 0, calc(100% - 25px) 0, 100% 25px, 100% 100%, 0 94%);
  text-decoration: none;
  transform: rotate(2.7deg);
  transition: transform 180ms var(--ease), color 180ms var(--ease);
}
.task-slip.slip-2 { transform: rotate(5.4deg) translateX(-1px); background-color: #edf4f9; }
.task-slip.slip-3 { transform: rotate(7.2deg) translateX(-5px); background-color: #dcecf7; }
.task-slip:hover { z-index: 4; color: var(--blue); transform: translateX(-9px) rotate(1deg); }
.slip-head { display: flex; justify-content: space-between; padding-bottom: 10px; border-bottom: 1px dotted var(--hairline); color: var(--blue); font: 800 10px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; }
.slip-head b { font-size: 16px; }
.slip-body { display: flex; align-items: center; gap: 18px; }
.slip-body i { width: 47px; height: 47px; border: 2px solid var(--blue); display: grid; place-items: center; color: var(--blue); font: 850 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; transform: rotate(-3deg); }
.slip-body strong { font-size: 17px; letter-spacing: -.03em; }
.eyelet { position: absolute; right: 18px; bottom: 21px; width: 17px; height: 17px; border: 4px solid var(--signal); border-radius: 50%; background: var(--field-deep); box-shadow: 0 0 0 1px rgba(7,27,52,.45); }

.proof-photo {
  position: absolute;
  z-index: 6;
  right: 4.5%;
  bottom: 1.4%;
  width: 210px;
  margin: 0;
  padding: 8px 8px 23px;
  border: 1px solid rgba(7, 27, 52, .25);
  background: #fff;
  box-shadow: 0 12px 22px rgba(7, 27, 52, .2);
  transform: rotate(-3deg);
}
.proof-photo img { width: 100%; height: 105px; display: block; object-fit: cover; object-position: left top; }
.proof-photo figcaption { position: absolute; right: 9px; bottom: 7px; color: var(--blue); font: 800 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .1em; }

.updates {
  width: min(1080px, calc(100% - 36px));
  margin: 26px auto 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
}
.update-card {
  position: relative;
  min-height: 178px;
  padding: 28px 34px 23px;
  border: 1px solid rgba(7, 27, 52, .23);
  display: flex;
  flex-direction: column;
  background: linear-gradient(rgba(255, 253, 248, .93), rgba(255, 253, 248, .93)), url("/assets/paper-texture-v1.jpg") center / 520px auto;
  box-shadow: var(--shadow-soft);
  text-decoration: none;
  transition: transform 180ms var(--ease), box-shadow 180ms var(--ease);
}
.update-card::after { content: ""; position: absolute; z-index: -1; inset: 7px -5px -8px 5px; border: 1px solid rgba(7,27,52,.18); background: #eeeae1; }
.update-card:hover { transform: translateY(-5px) rotate(-.3deg); box-shadow: var(--shadow-paper); }
.update-kicker { width: 100%; padding-bottom: 10px; border-bottom: 1px solid var(--hairline); color: var(--blue); font-size: 11px; font-weight: 800; }
.update-card h3 { margin: 15px 0 4px; font-size: clamp(18px, 2vw, 24px); line-height: 1.25; letter-spacing: -.04em; }
.update-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.update-foot { margin-top: auto; padding-top: 16px; display: flex; justify-content: space-between; align-items: center; color: var(--blue); }
.update-foot small { font: 800 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.update-foot b { font-size: 24px; }
.paperclip { position: absolute; z-index: 2; top: -17px; right: 38px; width: 21px; height: 60px; border: 3px solid #757d83; border-radius: 14px; transform: rotate(14deg); box-shadow: inset 0 0 0 1px rgba(255,255,255,.7); }
.update-2 .paperclip { border-color: var(--blue); transform: rotate(12deg); }

.home-section { max-width: 1180px; margin: 0 auto; padding: clamp(96px, 11vw, 150px) 24px 0; }
.section-kicker { margin: 0 0 15px; color: var(--blue); font: 850 11px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .13em; }
.section-heading { margin-bottom: 38px; display: flex; align-items: end; justify-content: space-between; gap: 36px; }
.section-heading h2 { max-width: 680px; margin: 0; font-size: clamp(34px, 4vw, 57px); line-height: 1.04; letter-spacing: -.06em; }
.section-heading p { max-width: 430px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.78; }

.path-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.path-card {
  position: relative;
  min-height: 410px;
  padding: 30px 28px 25px;
  border: 1px solid rgba(7,27,52,.24);
  display: flex;
  flex-direction: column;
  background: linear-gradient(rgba(250, 246, 237, .93), rgba(250, 246, 237, .93)), url("/assets/paper-texture-v1.jpg") center / 600px auto;
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  text-decoration: none;
  transition: transform 220ms var(--ease), box-shadow 220ms var(--ease);
}
.path-card::before { content: ""; position: absolute; left: -1px; top: 42px; width: 8px; height: 42px; background: var(--blue); }
.path-card:nth-child(2) { transform: translateY(12px); }
.path-card:nth-child(3) { transform: translateY(24px); }
.path-card:hover { transform: translateY(-6px) rotate(-.35deg); box-shadow: var(--shadow-paper); }
.path-index { padding-bottom: 16px; border-bottom: 1px dotted var(--hairline); color: var(--blue); font: 850 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .12em; }
.path-card h3 { margin: 30px 0 12px; font-size: clamp(25px, 2.2vw, 34px); line-height: 1.12; letter-spacing: -.05em; }
.path-card > p { margin: 0; color: var(--muted); line-height: 1.7; }
.path-samples { margin: auto 0 0; padding: 0; list-style: none; }
.path-samples li { padding: 9px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.path-count { margin-top: 17px; display: flex; justify-content: space-between; color: var(--blue); font-size: 11px; font-weight: 800; }
.path-count b { font-size: 17px; }

.task-band {
  width: min(1260px, calc(100% - 28px));
  margin: clamp(115px, 13vw, 170px) auto 0;
  padding: clamp(48px, 6vw, 78px) clamp(22px, 6vw, 70px);
  border: 1px solid rgba(7, 27, 52, .22);
  background: rgba(255, 255, 255, .38);
  box-shadow: inset 0 0 50px rgba(255,255,255,.35);
}
.task-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.task-card {
  min-height: 178px;
  padding: 24px;
  border: 1px solid rgba(7, 27, 52, .23);
  display: flex;
  flex-direction: column;
  background: linear-gradient(rgba(255,253,248,.94), rgba(255,253,248,.94)), url("/assets/paper-texture-v1.jpg") center / 500px auto;
  box-shadow: 0 8px 16px rgba(15,47,68,.12);
  color: var(--ink);
  text-decoration: none;
  transition: transform 180ms var(--ease), background 180ms var(--ease), color 180ms var(--ease);
}
.task-card:hover { color: white; background: var(--blue-deep); transform: translateY(-5px); }
.task-tag { padding-bottom: 12px; border-bottom: 1px dotted currentColor; color: var(--blue); font: 850 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .1em; }
.task-card:hover .task-tag { color: #b9ddff; }
.task-card h3 { margin: 22px 0 0; font-size: 19px; line-height: 1.38; }
.task-arrow { margin-top: auto; align-self: end; font-size: 25px; }

.scenario-layout { display: grid; grid-template-columns: .78fr 1.22fr; gap: 70px; align-items: start; }
.scenario-sticky { position: sticky; top: calc(var(--header-h) + 38px); }
.scenario-sticky h2 { margin: 0; font-size: clamp(36px, 5vw, 65px); line-height: 1.01; letter-spacing: -.065em; }
.scenario-sticky p { max-width: 420px; margin: 24px 0 0; color: var(--muted); line-height: 1.78; }
.scenario-list { padding: 5px 28px; border: 1px solid rgba(7,27,52,.23); background: linear-gradient(rgba(255,253,248,.9), rgba(255,253,248,.9)), url("/assets/paper-texture-v1.jpg") center / 620px auto; box-shadow: var(--shadow-soft); }
.scenario-item { padding: 25px 2px; display: grid; grid-template-columns: 62px 1fr auto; align-items: center; gap: 18px; border-bottom: 1px solid var(--line); text-decoration: none; transition: color 180ms var(--ease), padding 180ms var(--ease); }
.scenario-item:last-child { border-bottom: 0; }
.scenario-item:hover { padding-left: 10px; color: var(--blue); }
.scenario-no { color: var(--blue); font: 800 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .1em; }
.scenario-item h3 { margin: 0; font-size: clamp(18px, 2vw, 24px); }
.scenario-item p { margin: 6px 0 0; color: var(--muted); font-size: 12px; }
.scenario-item b { color: var(--muted); font-size: 11px; }

.sync-strip { max-width: 1180px; margin: 120px auto 0; padding: 28px 24px; border-top: 1px solid rgba(7,27,52,.24); display: flex; justify-content: space-between; gap: 24px; color: var(--muted); font-size: 11px; }
.sync-strip strong { color: var(--ink); }

/* Reader — the same manual opened to a field note */
.reader-shell {
  width: min(1540px, 100%);
  min-height: calc(100vh - var(--header-h));
  margin: 0 auto;
  padding: 34px clamp(20px, 3vw, 48px) 70px;
  display: grid;
  grid-template-columns: 260px minmax(0, 820px) 218px;
  justify-content: center;
  align-items: start;
  gap: clamp(24px, 3.4vw, 54px);
}
.doc-sidebar {
  position: sticky;
  top: calc(var(--header-h) + 34px);
  height: calc(100vh - var(--header-h) - 68px);
  padding: 29px 19px 42px;
  border: 1px solid rgba(7,27,52,.23);
  overflow: auto;
  background: linear-gradient(rgba(249,246,238,.93), rgba(249,246,238,.93)), url("/assets/paper-texture-v1.jpg") center / 520px auto;
  box-shadow: var(--shadow-soft);
  scrollbar-width: thin;
}
.doc-sidebar::before { content: "INDEX"; position: absolute; top: 26px; right: -29px; width: 68px; padding: 8px 4px; border: 1px solid rgba(4,75,167,.5); background: var(--blue); color: white; font: 800 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace; text-align: center; transform: rotate(90deg); }
.sidebar-label { margin: 0 0 15px; color: var(--blue); font: 850 9px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .12em; }
.sidebar-home { min-height: 44px; padding: 0 11px; border: 1px solid transparent; display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; font-weight: 750; text-decoration: none; }
.sidebar-home:hover { border-color: var(--line); color: var(--blue); }
.sidebar-group { margin-top: 20px; }
.sidebar-group-title { width: 100%; min-height: 43px; padding: 0 8px; border: 0; border-bottom: 1px dotted var(--hairline); display: flex; align-items: center; justify-content: space-between; gap: 10px; background: transparent; color: var(--ink); font-size: 13px; font-weight: 850; text-align: left; cursor: pointer; }
.sidebar-group-title:hover { color: var(--blue); }
.sidebar-group-title svg { width: 16px; height: 16px; fill: none; stroke: currentColor; transition: transform 180ms var(--ease); }
.sidebar-group.collapsed .sidebar-group-title svg { transform: rotate(-90deg); }
.sidebar-links { margin-top: 5px; }
.sidebar-group.collapsed .sidebar-links { display: none; }
.sidebar-link { position: relative; min-height: 37px; padding: 8px 8px 8px calc(10px + var(--depth, 0) * 11px); display: block; color: var(--muted); font-size: 11px; line-height: 1.5; text-decoration: none; }
.sidebar-link:hover { color: var(--ink); background: rgba(8,117,232,.06); }
.sidebar-link.active { padding-left: calc(16px + var(--depth, 0) * 11px); background: var(--blue); color: white; font-weight: 750; }
.sidebar-link.active::before { content: ""; position: absolute; left: 7px; top: 50%; width: 4px; height: 4px; border-radius: 50%; background: var(--signal); transform: translateY(-50%); }

.article {
  position: relative;
  min-width: 0;
  min-height: 900px;
  padding: clamp(46px, 6vw, 78px) clamp(34px, 6vw, 76px) 92px;
  border: 1px solid rgba(7, 27, 52, .24);
  background: linear-gradient(rgba(251,248,241,.92), rgba(251,248,241,.92)), url("/assets/paper-texture-v1.jpg") center / 760px auto;
  box-shadow: var(--shadow-paper);
}
.article::before, .article::after { content: ""; position: absolute; z-index: -1; border: 1px solid rgba(7,27,52,.18); background: #ebe7de; }
.article::before { inset: 8px -7px -9px 7px; transform: rotate(.35deg); }
.article::after { inset: 13px 5px -15px -6px; transform: rotate(-.25deg); }
.breadcrumbs { margin: 0 0 30px; padding-bottom: 13px; border-bottom: 1px dotted var(--hairline); display: flex; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: 10px; }
.breadcrumbs a { color: var(--blue); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; text-underline-offset: 3px; }
.article-header { position: relative; padding: 0 0 36px; border-bottom: 2px solid var(--ink); }
.article-header::after { content: ""; position: absolute; right: 0; bottom: -7px; width: 13px; height: 13px; border: 3px solid var(--signal); border-radius: 50%; background: var(--paper); }
.article-header .overline { margin: 0 0 18px; color: var(--blue); font: 850 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .13em; }
.article-header h1 { margin: 0; font-size: clamp(40px, 5vw, 68px); line-height: 1.07; letter-spacing: -.065em; text-wrap: balance; }
.article-meta { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 11px; }
.article-meta span { display: inline-flex; align-items: center; gap: 7px; }
.article-meta span::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--blue); }
.article-meta a { color: var(--blue); text-decoration: none; }

.article-body { padding-top: 34px; font-family: "Songti SC", STSong, "Noto Serif CJK SC", serif; font-size: 16px; line-height: 1.9; overflow-wrap: anywhere; }
.article-body > :first-child { margin-top: 0; }
.article-body p { margin: 1.25em 0; }
.article-body h2, .article-body h3, .article-body h4 { font-family: "Avenir Next", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; scroll-margin-top: calc(var(--header-h) + 28px); text-wrap: balance; }
.article-body h2 { margin: 2.5em 0 .8em; padding: 14px 0 0 18px; border-top: 1px solid var(--hairline); border-left: 7px solid var(--blue); font-size: clamp(26px, 3vw, 36px); line-height: 1.23; letter-spacing: -.045em; }
.article-body h3 { margin: 2.1em 0 .7em; font-size: clamp(20px, 2.3vw, 26px); line-height: 1.34; letter-spacing: -.03em; }
.article-body h4 { margin: 1.8em 0 .6em; font-size: 18px; }
.article-body a { color: var(--blue-deep); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.article-body strong { color: var(--ink); }
.article-body ul, .article-body ol { margin: 1.25em 0; padding-left: 1.6em; }
.article-body li { margin: .58em 0; padding-left: .35em; }
.article-body hr { margin: 2.5em 0; border: 0; border-top: 1px dotted var(--hairline); }
.article-body blockquote { margin: 1.8em 0; padding: 20px 24px; border: 1px solid var(--hairline); border-left: 6px solid var(--blue); background: rgba(8,117,232,.065); color: color-mix(in srgb, var(--ink) 84%, var(--muted)); }
.article-body blockquote p { margin: 0; }
.article-body code:not(pre code) { padding: .16em .4em; border: 1px solid var(--line); background: rgba(255,255,255,.6); font: .87em ui-monospace, SFMono-Regular, Menlo, monospace; }
.code-block { position: relative; margin: 1.8em 0; border: 1px solid #263546; overflow: hidden; background: #101820; color: #edf5ff; }
.code-head { min-height: 39px; padding: 0 13px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #263546; color: #8da6be; font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.copy-code { min-height: 30px; padding: 0 10px; border: 1px solid #344a60; background: transparent; color: #c7d9ea; cursor: pointer; }
.copy-code:hover { border-color: var(--blue-soft); color: white; }
.code-block pre { margin: 0; padding: 21px; overflow: auto; }
.code-block code { font: 13px/1.72 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; word-break: break-word; }
.article-figure { margin: 2.2em 0 2.55em; padding: 8px 8px 12px; border: 1px solid rgba(7,27,52,.22); background: #fff; box-shadow: 0 13px 24px rgba(15,47,68,.14); }
.article-figure img { width: 100%; max-height: 760px; display: block; object-fit: contain; background: #f1f3f4; cursor: zoom-in; }
.article-figure figcaption { max-width: 92%; margin: 10px auto 0; color: var(--muted); font-family: "Avenir Next", "PingFang SC", system-ui, sans-serif; font-size: 11px; line-height: 1.6; text-align: center; }
.article-media-grid { margin: 2.2em 0 2.55em; display: flex; align-items: stretch; gap: 14px; }
.article-media-column { min-width: 0; flex: var(--column-ratio, 1) 1 0; }
.article-media-column > .article-figure { height: 100%; margin: 0; display: flex; flex-direction: column; }
.article-media-column > .article-figure img { flex: 1 1 auto; }
.table-wrap { margin: 1.9em 0; border: 1px solid var(--line); overflow: auto; }
.article-body table { width: 100%; min-width: 560px; border-collapse: collapse; font-family: "Avenir Next", "PingFang SC", system-ui, sans-serif; font-size: 13px; line-height: 1.55; }
.article-body th, .article-body td { padding: 12px 14px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.article-body tr:last-child td { border-bottom: 0; }
.article-body th:last-child, .article-body td:last-child { border-right: 0; }
.article-body th { background: rgba(8,117,232,.08); font-weight: 850; }
.article-nav { margin-top: 72px; padding-top: 25px; border-top: 2px solid var(--ink); display: grid; grid-template-columns: 1fr 1fr; gap: 12px; font-family: "Avenir Next", "PingFang SC", system-ui, sans-serif; }
.article-nav a { min-height: 108px; padding: 18px; border: 1px solid var(--line); display: flex; flex-direction: column; justify-content: center; text-decoration: none; transition: background 180ms var(--ease), color 180ms var(--ease), transform 180ms var(--ease); }
.article-nav a:hover { background: var(--blue-deep); color: white; transform: translateY(-3px); }
.article-nav a.next { text-align: right; }
.article-nav small { color: var(--blue); font: 800 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .1em; }
.article-nav a:hover small { color: #b9ddff; }
.article-nav b { margin-top: 10px; font-size: 14px; line-height: 1.45; }

.toc { position: sticky; top: calc(var(--header-h) + 34px); max-height: calc(100vh - var(--header-h) - 68px); padding: 26px 20px; border: 1px solid rgba(7,27,52,.2); overflow: auto; background: rgba(255,255,255,.54); box-shadow: 0 9px 18px rgba(15,47,68,.1); }
.toc-title { margin: 0 0 16px; padding-bottom: 11px; border-bottom: 1px dotted var(--hairline); color: var(--blue); font: 850 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .12em; }
.toc a { position: relative; display: block; padding: 8px 0 8px 15px; color: var(--muted); font-size: 11px; line-height: 1.5; text-decoration: none; }
.toc a::before { content: ""; position: absolute; left: 0; top: 13px; width: 5px; height: 5px; border: 1px solid var(--blue); border-radius: 50%; }
.toc a.depth-3 { padding-left: 25px; }
.toc a:hover, .toc a.active { color: var(--blue-deep); }
.toc a.active::before { border-color: var(--signal); background: var(--signal); }

/* Dialogs */
dialog { padding: 0; border: 0; color: var(--ink); }
dialog::backdrop { background: rgba(7, 20, 32, .58); backdrop-filter: blur(7px); }
.search-dialog { width: min(720px, calc(100vw - 28px)); max-height: min(680px, calc(100vh - 40px)); margin-top: 11vh; border: 1px solid rgba(7,27,52,.3); background: linear-gradient(rgba(255,253,248,.96), rgba(255,253,248,.96)), url("/assets/paper-texture-v1.jpg") center / 600px auto; box-shadow: 0 30px 90px rgba(7,20,32,.38); overflow: hidden; }
.search-head { min-height: 70px; padding: 0 19px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px; border-bottom: 1px solid var(--line); }
.search-head svg { width: 22px; height: 22px; fill: none; stroke: var(--blue); stroke-width: 2; }
.search-head input { min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 18px; }
.search-close { min-height: 31px; padding: 0 9px; border: 1px solid var(--line); background: transparent; color: var(--muted); font-size: 9px; cursor: pointer; }
.search-hint { padding: 10px 19px; display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; }
.search-results { max-height: 500px; padding: 0 10px 12px; overflow: auto; }
.search-result { width: 100%; min-height: 77px; padding: 13px 14px; border: 0; display: grid; grid-template-columns: 42px 1fr; gap: 12px; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.search-result:hover, .search-result.selected { background: rgba(8,117,232,.09); }
.result-index { width: 38px; height: 38px; border: 1px solid var(--hairline); display: grid; place-items: center; color: var(--blue); font: 850 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.search-result h3 { margin: 0; font-size: 14px; }
.search-result p { margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.search-empty { padding: 60px 20px; color: var(--muted); text-align: center; }
.image-dialog { width: min(94vw, 1500px); max-width: none; max-height: 94vh; overflow: hidden; background: #0b1017; }
.image-dialog figure { width: 100%; height: 100%; max-height: 94vh; margin: 0; display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.image-dialog img { max-width: 100%; max-height: calc(94vh - 56px); margin: auto; object-fit: contain; }
.image-dialog figcaption { min-height: 44px; padding: 12px 60px; color: #c6cada; font-size: 12px; text-align: center; }
.image-close { position: absolute; z-index: 2; top: 10px; right: 10px; width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.3); border-radius: 50%; background: rgba(0,0,0,.45); color: white; font-size: 26px; cursor: pointer; }
.error-state { min-height: calc(100vh - var(--header-h)); padding: 60px 24px; display: grid; place-content: center; text-align: center; }
.error-state h1 { margin: 0; font-size: clamp(38px, 7vw, 72px); }
.error-state p { color: var(--muted); }
.error-state a { color: var(--blue); }
.sidebar-scrim { display: none; }

@media (max-width: 1220px) {
  .desk-scene { height: 650px; }
  .manual-cover { right: 17%; }
  .paper-stack { right: 15%; }
  .right-slips { right: .4%; width: 245px; }
  .task-slip { min-height: 116px; padding-left: 22px; }
  .proof-photo { width: 190px; right: 2%; }
  .reader-shell { grid-template-columns: 250px minmax(0, 790px); gap: 38px; padding-inline: 30px; }
  .toc { display: none; }
}

@media (max-width: 930px) {
  .brand-type small { display: none; }
  .desk-scene { height: 620px; }
  .manual-cover { inset: 6% 5% 11% 15%; }
  .paper-stack { inset: 8% 4% 9% 14%; }
  .left-tabs { left: 1%; }
  .right-slips { display: none; }
  .proof-photo { right: 1%; bottom: 0; }
  .cover-copy h1 { font-size: clamp(56px, 10vw, 84px); }
  .updates { margin-top: 28px; }
  .path-grid { grid-template-columns: 1fr; gap: 17px; }
  .path-card, .path-card:nth-child(n) { min-height: 330px; transform: none; }
  .task-grid { grid-template-columns: repeat(2, 1fr); }
  .scenario-layout { grid-template-columns: 1fr; }
  .scenario-sticky { position: static; }
  .reader-shell { display: block; padding: 24px 24px 64px; }
  .doc-sidebar {
    position: fixed;
    z-index: 120;
    top: var(--header-h);
    left: 0;
    width: min(350px, 88vw);
    height: calc(100vh - var(--header-h));
    padding: 25px 20px 50px;
    border-top: 0;
    transform: translateX(-106%);
    transition: transform 220ms var(--ease);
  }
  .doc-sidebar.open { transform: translateX(0); }
  .sidebar-scrim { position: fixed; z-index: 110; inset: var(--header-h) 0 0; display: block; background: rgba(7,20,32,.45); backdrop-filter: blur(2px); }
  .sidebar-scrim[hidden] { display: none; }
  .article { max-width: 820px; margin: 0 auto; }
}

@media (max-width: 680px) {
  :root { --header-h: 60px; }
  .topbar { padding-inline: 17px; }
  .brand-type b { font-size: 16px; }
  .search-trigger { gap: 0; }
  .search-trigger span { display: none; }
  .header-actions { gap: 3px; }
  .hero { padding: 10px 8px 0; }
  .desk-scene {
    height: auto;
    min-height: 0;
    padding: 72px 10px 24px;
    display: flex;
    flex-direction: column;
  }
  .paper-stack { inset: 82px 9px 25px 15px; }
  .manual-cover {
    position: relative;
    inset: auto;
    width: 100%;
    min-height: 485px;
  }
  .left-tabs { z-index: 7; top: 12px; left: 10px; right: 10px; display: flex; gap: 3px; }
  .binder-tab { width: auto; height: 68px; min-width: 0; flex: 1; padding: 12px 13px; border-radius: 8px 8px 0 0; align-content: center; }
  .binder-tab::after { display: none; }
  .binder-tab:hover { width: auto; }
  .binder-tab strong { font-size: 19px; }
  .binder-tab span { margin-top: 6px; padding: 0; border: 0; font-size: 11px; }
  .binder-clip { right: 10%; transform: scale(.76); transform-origin: top right; }
  .cover-rule { top: 17%; left: 8%; right: 8%; }
  .cover-copy { inset: 25% 7% 24% 8%; }
  .eyebrow { font-size: 8px; margin-bottom: 16px; }
  .cover-copy h1 { font-size: clamp(43px, 13.4vw, 63px); white-space: normal; }
  .cover-copy h1 span { display: block; }
  .hero-lede { margin-top: 21px; font-size: 17px; line-height: 1.65; }
  .cover-meta { grid-template-columns: 1fr auto; font-size: 7px; }
  .cover-meta b { display: none; }
  .ribbon-cta { left: -2%; right: -2%; bottom: 4.4%; min-height: 68px; padding-inline: 10%; }
  .ribbon-cta::after { display: none; }
  .ribbon-cta span { font-size: 24px; }
  .ribbon-cta svg { width: 29px; height: 29px; }
  .fold-corner { width: 75px; height: 75px; }
  .registration-mark { right: 4%; transform: scale(.72); }
  .proof-photo { display: none; }
  .updates { width: calc(100% - 20px); margin-top: 15px; grid-template-columns: 1fr; gap: 20px; }
  .update-card { min-height: 164px; padding: 25px 24px 20px; }
  .home-section { padding: 88px 18px 0; }
  .section-heading { align-items: start; flex-direction: column; gap: 18px; }
  .section-heading h2 { font-size: 38px; }
  .path-card { min-height: 350px; padding: 26px 23px 22px; }
  .task-band { margin-top: 100px; padding: 45px 17px; }
  .task-grid { grid-template-columns: 1fr; }
  .task-card { min-height: 150px; }
  .scenario-list { padding-inline: 19px; }
  .scenario-item { grid-template-columns: 47px 1fr; }
  .scenario-item > b { display: none; }
  .sync-strip { margin-top: 85px; padding-inline: 18px; flex-direction: column; }
  .reader-shell { padding: 13px 10px 48px; }
  .article { padding: 39px 23px 72px; }
  .article::before { inset: 7px 0 -9px 5px; }
  .article::after { inset: 12px 4px -14px 0; }
  .article-header h1 { font-size: 38px; }
  .article-body { font-size: 15px; line-height: 1.86; }
  .article-body h2 { padding-left: 13px; font-size: 27px; }
  .article-body h3 { font-size: 21px; }
  .article-nav { grid-template-columns: 1fr; }
  .article-nav a.next { text-align: left; }
  .image-dialog figcaption { padding-inline: 46px; }
}

@media (prefers-reduced-motion: no-preference) {
  .manual-cover { animation: settle-cover 680ms var(--ease) both; }
  .binder-tab { animation: slide-tab 520ms var(--ease) both; }
  .binder-tab:nth-child(2) { animation-delay: 70ms; }
  .binder-tab:nth-child(3) { animation-delay: 130ms; }
  .task-slip { animation: slide-slip 620ms var(--ease) both; }
  .task-slip:nth-child(2) { animation-delay: 80ms; }
  .task-slip:nth-child(3) { animation-delay: 145ms; }
  @keyframes settle-cover { from { opacity: 0; transform: translateY(18px) rotate(.3deg); } to { opacity: 1; transform: none; } }
  @keyframes slide-tab { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
  @keyframes slide-slip { from { opacity: 0; translate: 24px 0; } to { opacity: 1; translate: 0 0; } }
}

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

/* Neo-brutalist sharpening pass */
:root {
  --field: #a8ddff;
  --field-deep: #84cdf8;
  --paper: #fff9ec;
  --paper-clean: #fffdf7;
  --ink: #050505;
  --muted: #3f464d;
  --blue: #075cff;
  --blue-deep: #003db7;
  --blue-soft: #7cc7ff;
  --signal: #ffdc00;
  --line: #050505;
  --hairline: rgba(5, 5, 5, .38);
  --radius: 0;
  --shadow-paper: 13px 13px 0 #050505;
  --shadow-soft: 7px 7px 0 #050505;
}

body {
  background-color: var(--field);
  background-image:
    linear-gradient(rgba(5,5,5,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(5,5,5,.055) 1px, transparent 1px);
  background-size: 28px 28px;
}

.topbar {
  border-bottom: 3px solid var(--ink);
  background: #fff;
  box-shadow: 0 5px 0 var(--ink);
}
.brand-type b { font-weight: 950; letter-spacing: -.06em; text-transform: uppercase; }
.brand-type small { color: var(--ink); font-weight: 900; }
.icon-button { border: 2px solid transparent; font-weight: 900; }
.icon-button:hover { border-color: var(--ink); background: var(--signal); color: var(--ink); box-shadow: 4px 4px 0 var(--ink); transform: translate(-2px, -2px); }
.header-rule { width: 3px; background: var(--ink); }
.reading-progress { height: 5px; }
.reading-progress span { background: var(--signal); border-right: 2px solid var(--ink); }

.desk-scene::before { display: none; }
.paper-stack i {
  border: 3px solid var(--ink);
  box-shadow: none;
  transform: rotate(-.7deg) translate(-13px, 14px);
}
.paper-stack i:last-child { transform: rotate(.55deg) translate(11px, 6px); }
.manual-cover {
  border: 3px solid var(--ink);
  border-radius: 0;
  box-shadow: var(--shadow-paper);
}
.manual-cover::before { width: 15px; border-right: 3px solid var(--ink); border-radius: 0; box-shadow: none; }
.cover-rule { border-top: 4px solid var(--ink); }
.cover-rule::after { top: -4px; border-top: 4px dotted var(--blue); }
.eyebrow {
  width: fit-content;
  margin-bottom: 18px;
  padding: 8px 10px 7px;
  border: 2px solid var(--ink);
  background: var(--signal);
  color: var(--ink);
  font-weight: 950;
  letter-spacing: .1em;
  box-shadow: 4px 4px 0 var(--ink);
}
.cover-copy h1 {
  font-family: "Arial Black", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: 1000;
  letter-spacing: -.09em;
  text-shadow: 5px 5px 0 var(--blue-soft);
}
.cover-copy h1 span {
  color: var(--blue);
  -webkit-text-stroke: 2px var(--ink);
  text-shadow: 5px 5px 0 var(--signal);
}
.hero-lede { font-weight: 800; line-height: 1.5; }
.cover-meta { padding-top: 12px; border-top: 3px solid var(--ink); color: var(--ink); font-weight: 950; }
.ribbon-cta {
  border: 3px solid var(--ink);
  background: var(--blue);
  box-shadow: 9px 9px 0 var(--signal), 12px 12px 0 var(--ink);
}
.ribbon-cta::after { border-top-color: var(--ink); }
.ribbon-cta:hover {
  background: var(--signal);
  color: var(--ink);
  transform: translate(-4px, -4px);
  box-shadow: 13px 13px 0 var(--ink);
}
.ribbon-cta:hover::after { border-top-color: var(--ink); }
.ribbon-cta span { font-weight: 950; }
.fold-corner { border-left: 3px solid var(--ink); border-top: 3px solid var(--ink); box-shadow: none; }
.registration-mark { border: 3px solid var(--ink); background: var(--signal); }
.registration-mark::before, .registration-mark::after { background: var(--ink); }
.binder-clip { border: 2px solid var(--ink); border-radius: 0; box-shadow: 5px 5px 0 var(--signal); }

.binder-tab {
  border: 3px solid var(--ink);
  border-radius: 0;
  background: var(--blue);
  box-shadow: 7px 7px 0 var(--ink);
  transition: transform 150ms ease, box-shadow 150ms ease;
}
.binder-tab::after { border-block: 3px solid var(--ink); }
.binder-tab.tab-2 { background: var(--signal); color: var(--ink); }
.binder-tab.tab-3 { background: var(--ink); color: white; }
.binder-tab:hover { width: 145px; filter: none; transform: translate(-4px, -4px); box-shadow: 11px 11px 0 var(--ink); }
.binder-tab strong { font-weight: 950; }

.task-slip {
  border: 3px solid var(--ink);
  background: var(--paper-clean);
  box-shadow: 7px 7px 0 var(--ink);
  clip-path: polygon(0 0, calc(100% - 25px) 0, 100% 25px, 100% 100%, 0 100%);
}
.task-slip.slip-2 { background: var(--signal); }
.task-slip.slip-3 { background: var(--blue); color: white; }
.task-slip:hover { color: var(--ink); background: white; transform: translate(-10px, -4px) rotate(0); box-shadow: 11px 11px 0 var(--ink); }
.slip-head { border-bottom: 2px solid currentColor; color: inherit; font-weight: 950; }
.slip-body i { border: 3px solid currentColor; color: inherit; font-weight: 950; }
.eyelet { border: 3px solid var(--ink); background: var(--signal); box-shadow: 3px 3px 0 var(--ink); }
.proof-photo { border: 3px solid var(--ink); box-shadow: 8px 8px 0 var(--ink); }
.proof-photo figcaption { color: var(--ink); font-weight: 950; }

.update-card {
  border: 3px solid var(--ink);
  background: var(--paper-clean);
  box-shadow: 8px 8px 0 var(--ink);
}
.update-card::after { display: none; }
.update-card.update-2 { background: var(--signal); }
.update-card:hover { transform: translate(-5px, -5px); box-shadow: 13px 13px 0 var(--ink); }
.update-kicker { border-bottom: 3px solid var(--ink); color: var(--ink); font-weight: 950; }
.update-card h3 { font-family: "Arial Black", "PingFang SC", sans-serif; font-weight: 950; }
.update-foot { color: var(--ink); }
.paperclip { border: 4px solid var(--ink); border-radius: 0; box-shadow: none; }
.update-2 .paperclip { border-color: var(--blue); }

.section-kicker {
  width: fit-content;
  padding: 7px 9px;
  border: 2px solid var(--ink);
  background: var(--ink);
  color: white;
  font-weight: 950;
}
.section-heading { padding-bottom: 25px; border-bottom: 4px solid var(--ink); }
.section-heading h2, .scenario-sticky h2 {
  font-family: "Arial Black", "PingFang SC", sans-serif;
  font-weight: 1000;
  letter-spacing: -.075em;
}
.section-heading p, .scenario-sticky p { color: var(--ink); font-weight: 650; }
.path-card {
  border: 3px solid var(--ink);
  background: var(--paper-clean);
  box-shadow: 9px 9px 0 var(--ink);
}
.path-card:nth-child(2) { background: var(--blue); color: white; }
.path-card:nth-child(3) { background: var(--signal); color: var(--ink); }
.path-card:hover { transform: translate(-6px, -6px); box-shadow: 15px 15px 0 var(--ink); }
.path-index { border-bottom: 3px solid currentColor; color: inherit; font-weight: 950; }
.path-card h3 { font-family: "Arial Black", "PingFang SC", sans-serif; font-weight: 1000; }
.path-card > p, .path-card:nth-child(2) .path-card > p { color: inherit; }
.path-card:nth-child(2) > p, .path-card:nth-child(2) .path-samples li, .path-card:nth-child(2) .path-count { color: white; }
.path-samples li { border-top: 2px solid currentColor; color: inherit; }
.path-count { color: inherit; font-weight: 950; }

.task-band {
  border: 4px solid var(--ink);
  background: var(--blue);
  box-shadow: 12px 12px 0 var(--ink);
}
.task-band .section-kicker { background: var(--signal); color: var(--ink); }
.task-band .section-heading { color: white; border-bottom-color: white; }
.task-band .section-heading p { color: white; }
.task-card {
  border: 3px solid var(--ink);
  background: white;
  box-shadow: 6px 6px 0 var(--ink);
}
.task-card:hover { background: var(--signal); color: var(--ink); transform: translate(-4px, -4px); box-shadow: 10px 10px 0 var(--ink); }
.task-tag { border-bottom: 2px solid currentColor; color: var(--ink); font-weight: 950; }
.task-card:hover .task-tag { color: var(--ink); }

.scenario-sticky { padding: 25px; border: 4px solid var(--ink); background: var(--signal); box-shadow: 9px 9px 0 var(--ink); }
.scenario-sticky .section-kicker { background: var(--blue); }
.scenario-list { border: 4px solid var(--ink); background: white; box-shadow: 9px 9px 0 var(--ink); }
.scenario-item { border-bottom: 3px solid var(--ink); }
.scenario-item:hover { background: var(--blue); color: white; padding-inline: 12px; }
.scenario-item:hover p, .scenario-item:hover b, .scenario-item:hover .scenario-no { color: white; }
.scenario-no { color: var(--ink); font-weight: 950; }
.sync-strip { border-top: 4px solid var(--ink); color: var(--ink); font-weight: 700; }

.reader-shell { background-image: linear-gradient(rgba(5,5,5,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(5,5,5,.045) 1px, transparent 1px); background-size: 28px 28px; }
.doc-sidebar {
  border: 3px solid var(--ink);
  background: var(--signal);
  box-shadow: 8px 8px 0 var(--ink);
}
.doc-sidebar::before { right: -31px; border: 3px solid var(--ink); background: var(--blue); font-weight: 950; }
.sidebar-label { color: var(--ink); font-weight: 950; }
.sidebar-home { border: 2px solid var(--ink); background: white; color: var(--ink); font-weight: 900; }
.sidebar-group-title { border-bottom: 3px solid var(--ink); font-weight: 950; }
.sidebar-link { color: var(--ink); font-weight: 650; }
.sidebar-link:hover { background: white; }
.sidebar-link.active { border: 2px solid var(--ink); background: var(--blue); color: white; box-shadow: 4px 4px 0 var(--ink); }

.article {
  border: 4px solid var(--ink);
  background: linear-gradient(rgba(255,249,236,.91), rgba(255,249,236,.91)), url("/assets/paper-texture-v1.jpg") center / 760px auto;
  box-shadow: 14px 14px 0 var(--ink);
}
.article::before, .article::after { display: none; }
.breadcrumbs { border-bottom: 3px solid var(--ink); color: var(--ink); font-weight: 750; }
.article-header { border-bottom: 5px solid var(--ink); }
.article-header::after { width: 15px; height: 15px; border: 3px solid var(--ink); background: var(--signal); }
.article-header .overline { width: fit-content; padding: 7px 9px; border: 2px solid var(--ink); background: var(--signal); color: var(--ink); font-weight: 950; box-shadow: 4px 4px 0 var(--ink); }
.article-header h1 { font-family: "Arial Black", "PingFang SC", sans-serif; font-weight: 1000; letter-spacing: -.075em; text-shadow: 4px 4px 0 var(--blue-soft); }
.article-meta { color: var(--ink); font-weight: 700; }
.article-meta span::before { width: 7px; height: 7px; border: 1px solid var(--ink); background: var(--signal); }
.article-body h2 { border-top: 4px solid var(--ink); border-left: 10px solid var(--blue); font-weight: 950; }
.article-body h3 { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 7px; }
.article-body blockquote { border: 3px solid var(--ink); border-left: 10px solid var(--blue); background: var(--signal); box-shadow: 6px 6px 0 var(--ink); }
.article-body code:not(pre code) { border: 2px solid var(--ink); background: var(--signal); }
.code-block { border: 4px solid var(--ink); box-shadow: 7px 7px 0 var(--blue); }
.code-head { border-bottom: 3px solid var(--signal); }
.copy-code { border: 2px solid white; }
.article-figure { border: 4px solid var(--ink); box-shadow: 9px 9px 0 var(--blue); }
.table-wrap { border: 4px solid var(--ink); box-shadow: 7px 7px 0 var(--ink); }
.article-body th, .article-body td { border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.article-body th { background: var(--blue); color: white; }
.article-nav { border-top: 5px solid var(--ink); }
.article-nav a { border: 3px solid var(--ink); background: white; box-shadow: 5px 5px 0 var(--ink); }
.article-nav a:hover { background: var(--signal); color: var(--ink); transform: translate(-4px, -4px); box-shadow: 9px 9px 0 var(--ink); }
.article-nav a:hover small { color: var(--ink); }
.toc { border: 3px solid var(--ink); background: var(--signal); box-shadow: 7px 7px 0 var(--ink); }
.toc-title { border-bottom: 3px solid var(--ink); color: var(--ink); font-weight: 950; }
.toc a { color: var(--ink); font-weight: 700; }
.toc a::before { border: 2px solid var(--ink); background: white; }
.toc a.active::before { border-color: var(--ink); background: var(--blue); }

.search-dialog { border: 4px solid var(--ink); background: var(--paper-clean); box-shadow: 12px 12px 0 var(--ink); }
.search-head { border-bottom: 4px solid var(--ink); }
.search-close { border: 2px solid var(--ink); background: var(--signal); color: var(--ink); font-weight: 950; }
.search-result { border-bottom: 2px solid var(--ink); }
.search-result:hover, .search-result.selected { background: var(--signal); }
.result-index { border: 2px solid var(--ink); background: var(--blue); color: white; }

@media (max-width: 930px) {
  .doc-sidebar { background: var(--signal); }
}

@media (max-width: 680px) {
  .topbar { box-shadow: 0 4px 0 var(--ink); }
  .manual-cover { box-shadow: 8px 8px 0 var(--ink); }
  .binder-tab { border-width: 2px; box-shadow: 4px 4px 0 var(--ink); }
  .cover-copy h1 { text-shadow: 3px 3px 0 var(--blue-soft); }
  .cover-copy h1 span { -webkit-text-stroke-width: 1px; text-shadow: 3px 3px 0 var(--signal); }
  .eyebrow { padding: 6px 7px 5px; box-shadow: 3px 3px 0 var(--ink); }
  .ribbon-cta { box-shadow: 6px 6px 0 var(--signal), 9px 9px 0 var(--ink); }
  .update-card, .path-card, .task-card, .scenario-list, .scenario-sticky { box-shadow: 6px 6px 0 var(--ink); }
  .article { border-width: 3px; box-shadow: 7px 7px 0 var(--ink); }
}

/* Cool-paper correction: keep texture, remove the warm ivory cast */
:root {
  --paper: #f3faff;
  --paper-clean: #fbfdff;
}

.paper-stack i { background: #dcecf6; }
.paper-stack i:last-child { background: #edf7fc; }
.manual-cover {
  background:
    linear-gradient(rgba(243, 250, 255, .965), rgba(243, 250, 255, .965)),
    url("/assets/paper-texture-v1.jpg") center / 700px auto repeat;
}
.task-slip, .update-card, .path-card, .task-card, .scenario-list, .sidebar-home, .article-nav a, .search-dialog {
  background-color: var(--paper-clean);
}
.article {
  background:
    linear-gradient(rgba(243, 250, 255, .965), rgba(243, 250, 255, .965)),
    url("/assets/paper-texture-v1.jpg") center / 760px auto repeat;
}
.article-figure, .article-figure img { background-color: var(--paper-clean); }

/* Wide-screen composition: let the field manual occupy the desk instead of
   floating inside a narrow laptop-sized frame. */
@media (min-width: 1231px) {
  .hero {
    padding-inline: clamp(16px, 1.4vw, 28px);
  }

  .desk-scene {
    width: min(1760px, 100%);
    height: clamp(660px, 46vw, 800px);
  }

  .paper-stack {
    inset: 6% 17% 6% 9%;
  }

  .manual-cover {
    inset: 4% 18.2% 7.5% 10%;
  }

  .left-tabs {
    top: 12.5%;
    left: 2%;
  }

  .right-slips {
    top: 13.5%;
    right: .5%;
    width: clamp(285px, 16vw, 320px);
  }

  .proof-photo {
    right: 2%;
    width: 220px;
  }

  .cover-copy h1 {
    font-size: clamp(72px, 6vw, 124px);
  }

  .updates {
    width: min(1420px, calc(100% - 64px));
    gap: 32px;
  }

  .home-section,
  .sync-strip {
    max-width: 1420px;
  }

  .task-band {
    width: min(1580px, calc(100% - 48px));
  }
}

/* Original field-tool stickers for the wide cover. The reference supplies the
   scattered rhythm only; every symbol and label is specific to this guide. */
.cover-toolkit {
  display: none;
  position: absolute;
  z-index: 5;
  top: 25%;
  right: 1.8%;
  width: 30%;
  height: 48%;
  pointer-events: none;
}

.cover-toolkit::before {
  content: "";
  position: absolute;
  inset: 17% 13% 18% 15%;
  border: 2px dashed var(--blue);
  transform: rotate(-8deg);
}

.toolkit-caption,
.toolkit-note {
  position: absolute;
  font: 950 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .13em;
}

.toolkit-caption {
  top: -10px;
  left: 50%;
  right: auto;
  padding: 5px 7px 4px;
  border: 2px solid var(--ink);
  background: var(--signal);
  box-shadow: 3px 3px 0 var(--ink);
  transform: translateX(-50%) rotate(-1deg);
}

.toolkit-note {
  right: 1%;
  bottom: -4px;
  padding-top: 6px;
  border-top: 2px solid var(--ink);
}

.tool-sticker {
  position: absolute;
  width: clamp(72px, 6vw, 108px);
  aspect-ratio: .9;
  padding: 12px 10px 9px;
  border: 3px solid var(--ink);
  display: grid;
  grid-template-rows: 1fr auto;
  place-items: center;
  background: var(--paper-clean);
  color: var(--ink);
  box-shadow: 6px 6px 0 var(--ink);
}

.tool-sticker svg {
  width: 78%;
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: square;
  stroke-linejoin: miter;
}

.tool-sticker b {
  font: 950 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .08em;
}

.tool-prompt { top: 7%; left: 1%; transform: rotate(-7deg); }
.tool-deliver { top: 0; right: 3%; background: var(--signal); transform: rotate(5deg); }
.tool-flow { bottom: 1%; left: 17%; background: var(--blue); color: white; transform: rotate(4deg); }
.tool-insight { right: 7%; bottom: 8%; transform: rotate(-5deg); }

@media (min-width: 1231px) {
  .cover-toolkit { display: block; }
}

@media (prefers-reduced-motion: no-preference) and (min-width: 1231px) {
  .tool-sticker { animation: tool-sticker-in 520ms var(--ease) both; }
  .tool-deliver { animation-delay: 70ms; }
  .tool-flow { animation-delay: 130ms; }
  .tool-insight { animation-delay: 190ms; }

  @keyframes tool-sticker-in {
    from { opacity: 0; translate: 0 14px; }
    to { opacity: 1; translate: 0 0; }
  }
}

/* Mobile composition pass: preserve the manual metaphor without shrinking the
   desktop canvas wholesale. Keep actions thumb-sized and reading width useful. */
@media (max-width: 680px) {
  body { background-size: 22px 22px; }

  .topbar { padding-inline: 16px; }
  .hero { padding: 8px 6px 0; }
  .desk-scene { padding: 68px 7px 16px; }
  .paper-stack { inset: 77px 6px 19px 11px; }

  .left-tabs {
    top: 10px;
    left: 7px;
    right: 7px;
    gap: 2px;
  }

  .binder-tab {
    height: 64px;
    padding: 10px 12px;
  }

  .binder-tab strong { font-size: 18px; }
  .binder-clip { transform: scale(.7); }

  .manual-cover { min-height: 458px; }
  .cover-rule { top: 18%; }
  .cover-copy { inset: 24% 7% 24% 8%; }
  .eyebrow { margin-bottom: 14px; }

  .cover-copy h1 {
    font-size: clamp(42px, 13vw, 51px);
    line-height: .92;
  }

  .hero-lede {
    margin-top: 18px;
    font-size: 16px;
    line-height: 1.55;
  }

  .cover-meta { padding-top: 9px; }
  .cover-toolkit { display: none !important; }

  .ribbon-cta {
    min-height: 64px;
    padding-inline: 9%;
    gap: 20px;
  }

  .ribbon-cta span { font-size: 23px; }
  .ribbon-cta svg { width: 27px; height: 27px; }

  .updates {
    width: calc(100% - 16px);
    margin-top: 12px;
    gap: 16px;
  }

  .update-card {
    min-height: 154px;
    padding: 23px 21px 18px;
  }

  .update-card h3 { margin-top: 13px; }
  .update-card p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .home-section { padding: 72px 14px 0; }
  .section-heading { margin-bottom: 28px; gap: 15px; }
  .section-heading h2 { font-size: 35px; line-height: 1.02; }
  .section-heading p { font-size: 14px; line-height: 1.65; }

  .path-grid { gap: 14px; }
  .path-card {
    min-height: 318px;
    padding: 23px 20px 20px;
  }

  .path-card h3 { margin-top: 23px; }

  .task-band {
    width: calc(100% - 16px);
    margin-top: 78px;
    padding: 36px 13px;
  }

  .task-grid { gap: 12px; }
  .task-card { min-height: 136px; padding: 20px; }
  .task-card h3 { margin-top: 17px; font-size: 18px; }

  .scenario-sticky { padding: 21px; }
  .scenario-sticky p { margin-top: 17px; line-height: 1.65; }
  .scenario-list { padding-inline: 14px; }
  .scenario-item { padding-block: 20px; gap: 11px; }
  .scenario-item p { line-height: 1.55; }

  .sync-strip {
    margin-top: 68px;
    padding: 23px 14px;
    gap: 12px;
  }

  .reader-shell { padding: 9px 7px 42px; }
  .article { padding: 31px 19px 58px; }
  .breadcrumbs { margin-bottom: 24px; }
  .article-header { padding-bottom: 28px; }
  .article-header .overline { margin-bottom: 15px; }

  .article-header h1 {
    font-size: clamp(32px, 10vw, 38px);
    line-height: 1.08;
  }

  .article-meta { margin-top: 20px; gap: 8px 13px; }
  .article-body { padding-top: 27px; font-size: 16px; line-height: 1.82; }
  .article-body h2 { margin-top: 2.2em; font-size: 26px; }
  .article-body h3 { margin-top: 1.9em; }
  .article-body blockquote { margin-inline: 0; padding: 17px 16px; }
  .article-figure { margin: 1.8em -2px 2.2em; padding: 6px 6px 10px; }
  .code-block pre { padding: 17px 15px; }
  .article-nav { margin-top: 56px; gap: 10px; }
  .article-nav a { min-height: 94px; padding: 16px; }

  .search-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 24px);
    margin-top: 12px;
  }

  .search-head { min-height: 62px; padding-inline: 14px; gap: 10px; }
  .search-head input { font-size: 16px; }

  .binder-tab:hover,
  .update-card:hover,
  .path-card:hover,
  .task-card:hover {
    transform: none;
  }

  .binder-tab:hover { width: auto; box-shadow: 4px 4px 0 var(--ink); }
  .scenario-item:hover { padding-left: 2px; }
}

@media (max-width: 360px) {
  .binder-tab { padding-inline: 9px; }
  .manual-cover { min-height: 442px; }
  .cover-copy h1 { font-size: 42px; }
  .hero-lede { font-size: 15px; }
  .article { padding-inline: 16px; }
}

/* Palette sampled from the approved reference: pale ice-blue desk, cool paper,
   dark navy structure and three blue depths. Red is reserved for tiny marks. */
:root {
  --field: #c0e3f9;
  --field-deep: #b8ddf5;
  --paper: #f7fbfe;
  --paper-clean: #fff;
  --ink: #031b35;
  --muted: #526579;
  --blue: #116ae1;
  --blue-deep: #0142ac;
  --blue-soft: #7ab1e8;
  --signal: #ee4036;
  --line: rgba(3, 27, 53, .24);
  --hairline: rgba(17, 106, 225, .38);
  --shadow-paper: 13px 13px 0 var(--ink);
  --shadow-soft: 7px 7px 0 var(--ink);
}

body {
  background-color: var(--field);
  background-image:
    linear-gradient(rgba(3, 27, 53, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(3, 27, 53, .055) 1px, transparent 1px);
}

.topbar { background: #fff; }

.manual-cover {
  background:
    linear-gradient(rgba(247, 251, 254, .97), rgba(247, 251, 254, .97)),
    url("/assets/paper-texture-v1.jpg") center / 700px auto repeat;
}

.paper-stack i { background: #dbeaf4; }
.paper-stack i:last-child { background: #eef6fb; }

.task-slip,
.update-card,
.path-card,
.task-card,
.scenario-list,
.article-figure,
.article-figure img,
.sidebar-home,
.article-nav a,
.search-dialog {
  background: #fff;
}

.binder-tab { background: #6fa8df; color: #fff; }
.binder-tab.tab-2 { background: var(--blue); color: #fff; }
.binder-tab.tab-3 { background: var(--blue-deep); color: #fff; }

.task-slip.slip-2 { background: #e9f1f7; color: var(--ink); }
.task-slip.slip-3 { background: #d7e8f3; color: var(--ink); }
.task-slip:hover { background: #fff; color: var(--blue-deep); }

.update-card.update-2 {
  background: #edf5fa;
  color: var(--ink);
}

.update-card.update-2 .update-kicker,
.update-card.update-2 p,
.update-card.update-2 .update-foot {
  color: inherit;
}

.path-card:nth-child(2) {
  background: #eaf3f9;
  color: var(--ink);
}

.path-card:nth-child(3) {
  background: #d7e9f4;
  color: var(--ink);
}

.path-card:nth-child(2) > p,
.path-card:nth-child(2) .path-samples li,
.path-card:nth-child(2) .path-count,
.path-card:nth-child(3) > p,
.path-card:nth-child(3) .path-samples li,
.path-card:nth-child(3) .path-count {
  color: inherit;
}

.eyebrow,
.section-kicker,
.article-header .overline,
.result-index {
  background: var(--blue);
  color: #fff;
}

.cover-copy h1 { text-shadow: 5px 5px 0 var(--blue-soft); }
.cover-copy h1 span {
  color: var(--blue-deep);
  text-shadow: 5px 5px 0 var(--blue-soft);
}

.ribbon-cta {
  background: var(--ink);
  color: #fff;
  box-shadow: 10px 10px 0 var(--blue-deep);
}

.ribbon-cta::after { border-top-color: var(--ink); }
.ribbon-cta:hover { background: var(--blue-deep); color: #fff; }
.ribbon-cta:hover::after { border-top-color: var(--ink); }

.fold-corner {
  background:
    repeating-linear-gradient(0deg, transparent 0 10px, rgba(255, 255, 255, .72) 10px 11px),
    repeating-linear-gradient(90deg, transparent 0 10px, rgba(255, 255, 255, .72) 10px 11px),
    var(--blue-soft);
}

.binder-clip { box-shadow: 5px 5px 0 var(--blue-deep); }
.binder-clip i,
.paperclip { border-color: var(--ink); }
.update-2 .paperclip { border-color: var(--blue); }

.registration-mark,
.eyelet,
.article-header::after {
  background: var(--signal);
}

.task-band {
  background: var(--ink);
  color: #fff;
}

.task-band .section-kicker {
  background: var(--blue);
  color: #fff;
}

.task-band .section-heading,
.task-band .section-heading p {
  color: #fff;
  border-bottom-color: #fff;
}

.task-card:hover,
.search-result:hover,
.search-result.selected {
  background: var(--blue-deep);
  color: #fff;
}

.task-card:hover .task-tag,
.search-result:hover p,
.search-result.selected p {
  color: #fff;
}

.scenario-sticky {
  background: var(--blue);
  color: #fff;
}

.scenario-sticky .section-kicker {
  background: var(--ink);
  color: #fff;
}

.scenario-sticky p { color: #fff; }
.scenario-list { background: #fff; }

.doc-sidebar,
.toc {
  background: #eaf3f9;
}

.sidebar-link.active {
  background: var(--blue-deep);
  color: #fff;
}

.article {
  background:
    linear-gradient(rgba(247, 251, 254, .97), rgba(247, 251, 254, .97)),
    url("/assets/paper-texture-v1.jpg") center / 760px auto repeat;
}

.article-body blockquote {
  background: #e2f0f9;
  color: var(--ink);
}

.article-body code:not(pre code) {
  background: #e2f0f9;
  color: var(--blue-deep);
}

.code-block,
.image-dialog {
  background: var(--ink);
  color: #fff;
}

.code-head,
.copy-code,
.image-dialog figcaption { color: #fff; }
.code-head { border-bottom-color: var(--blue); }
.copy-code { border-color: #fff; }
.article-body th { background: var(--blue-deep); color: #fff; }

.toolkit-caption {
  background: var(--blue-deep);
  color: #fff;
}

.tool-deliver {
  background: #d7e9f4;
  color: var(--ink);
}

.tool-flow {
  background: var(--blue);
  color: #fff;
}

.tool-insight { background: #eaf3f9; }

@media (max-width: 930px) {
  .doc-sidebar { background: #eaf3f9; }
}

@media (max-width: 680px) {
  .cover-copy h1 { text-shadow: 3px 3px 0 var(--blue-soft); }
  .cover-copy h1 span { text-shadow: 3px 3px 0 var(--blue-soft); }
  .ribbon-cta { box-shadow: 7px 7px 0 var(--blue-deep); }
}

.article-video {
  margin: 2.2em 0 2.55em;
  padding: 8px 8px 11px;
  border: 4px solid var(--ink);
  background: var(--ink);
  box-shadow: 9px 9px 0 var(--blue);
}

.article-video video {
  width: 100%;
  max-height: min(72vh, 760px);
  display: block;
  background: #000;
}

.article-video figcaption {
  padding: 11px 8px 2px;
  color: #fff;
  font-family: "Avenir Next", "PingFang SC", system-ui, sans-serif;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.5;
  text-align: center;
}

@media (max-width: 680px) {
  .article-media-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
}

@media (max-width: 680px) {
  .article-video {
    margin: 1.8em -2px 2.2em;
    padding: 5px 5px 9px;
    border-width: 3px;
    box-shadow: 6px 6px 0 var(--blue);
  }

  .article-video video { max-height: 64vh; }
}

/* Global guide navigation — a compact editorial index above the field manual. */
.topbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(190px, 1fr);
  column-gap: clamp(16px, 2.2vw, 38px);
}

.brand { justify-self: start; }
.brand-type b {
  font-family: "Arial Black", "Avenir Next", "PingFang SC", sans-serif;
  font-size: 18px;
  letter-spacing: -.055em;
  text-transform: none;
}

.primary-nav {
  height: 100%;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 2px;
}

.primary-nav a {
  position: relative;
  min-height: 44px;
  padding: 0 clamp(8px, .8vw, 14px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  font-size: 14px;
  font-weight: 850;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: color 160ms var(--ease), background 160ms var(--ease), transform 160ms var(--ease);
}

.primary-nav a::after {
  content: "";
  position: absolute;
  right: 11px;
  bottom: 0;
  left: 11px;
  height: 3px;
  background: transparent;
}

.primary-nav a:hover {
  background: #eaf3f9;
  color: var(--blue-deep);
}

.primary-nav a:active { transform: translateY(2px); }
.primary-nav a[aria-current="page"] { color: var(--blue-deep); }
.primary-nav a[aria-current="page"]::after { background: var(--ink); }

.primary-nav .github-nav {
  margin-left: 7px;
  border-left: 2px solid var(--ink);
  color: var(--blue-deep);
}

.primary-nav .github-nav span { margin-left: 4px; font-size: 12px; }
.header-actions { justify-self: end; }
.nav-toggle { display: none; }
.reader-mode .menu-toggle { display: none; }

@media (min-width: 1231px) {
  .cover-copy h1 { font-size: clamp(70px, 5.45vw, 112px); }
}

@media (max-width: 1280px) {
  .topbar { grid-template-columns: minmax(200px, 1fr) auto minmax(58px, 1fr); }
  .primary-nav a { padding-inline: 9px; font-size: 13px; }
  .search-trigger span { display: none; }
  .search-trigger { gap: 0; }
}

@media (max-width: 1100px) {
  .topbar {
    display: flex;
    justify-content: space-between;
  }

  .primary-nav {
    position: fixed;
    z-index: 99;
    top: var(--header-h);
    right: 0;
    left: 0;
    height: auto;
    max-height: calc(100dvh - var(--header-h));
    padding: 14px clamp(16px, 4vw, 38px) 20px;
    border-bottom: 4px solid var(--ink);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    overflow-y: auto;
    background: #fff;
    box-shadow: 0 8px 0 rgba(3, 27, 53, .2);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-12px);
    transition: opacity 180ms var(--ease), transform 180ms var(--ease), visibility 180ms;
  }

  .nav-open .primary-nav {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  .primary-nav a {
    min-height: 52px;
    padding: 0 14px;
    border: 2px solid var(--ink);
    justify-content: flex-start;
    background: #fff;
    font-size: 15px;
  }

  .primary-nav a::after { display: none; }
  .primary-nav a:hover,
  .primary-nav a[aria-current="page"] {
    background: var(--blue-deep);
    color: #fff;
    box-shadow: 4px 4px 0 var(--ink);
    transform: translate(-2px, -2px);
  }

  .primary-nav .github-nav {
    margin-left: 0;
    border-left: 2px solid var(--ink);
  }

  .nav-toggle { display: inline-flex; }
  .header-rule { display: inline-block !important; }
  .home-mode .header-rule { display: inline-block; }
}

@media (max-width: 930px) {
  .reader-mode .menu-toggle { display: inline-flex; }
}

@media (max-width: 680px) {
  .brand-type b { font-size: 15px; letter-spacing: -.045em; }
  .brand-type small { margin-top: 5px; font-size: 7px; letter-spacing: .12em; }
  .header-rule { display: none !important; }
  .header-actions { gap: 0; }
  .icon-button { padding-inline: 6px; }

  .primary-nav {
    padding: 10px 10px 15px;
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .primary-nav a {
    min-height: 48px;
    font-size: 14px;
  }

  .cover-copy h1 { font-size: clamp(39px, 12.1vw, 49px); }
}

@media (max-width: 380px) {
  .brand-type b { font-size: 13px; }
  .brand-type small { display: none; }
  .icon-button { min-width: 42px; }
}
