/*
  CH101 production home + trip stylesheet; shell shared sitewide.
  Basis: production design kit tokens + direction-demo structure (adjudicated).
  Font rule (D-024 Phase A): display/mono never exceed weight 700.
  Load order: /assets/fonts.css then this file.
*/

:root {
  color-scheme: light;
  --ink: #141414; --yellow: #ffcc00; --paper: #f4f4f2; --white: #fff;
  --soft: #eceae3; --muted: #74716a; --risk: #d4322a; --logic: #2563a8;
  --proof: #1f8a52; --insider: #c05621;
  --display: "Archivo Narrow", "Arial Narrow", "Roboto Condensed", Impact, sans-serif;
  --body: "Space Grotesk", Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "Space Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
/* Font-lock rule (D-024 Phase A): display/mono cap at 700 — browser default
   b/strong "bolder" would synthesize a fake 900 above our 700 base. */
b, strong { font-weight: 700; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; background: var(--paper); }
body { margin: 0; min-width: 320px; font-family: var(--body); color: var(--ink); background: var(--paper); font-size: 14px; -webkit-font-smoothing: antialiased; }
body.modal-open { overflow: hidden; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.skip-link { position: fixed; left: 16px; top: -80px; z-index: 1000; background: var(--yellow); border: 2px solid var(--ink); padding: 10px 14px; font: 700 12px var(--mono); }
.skip-link:focus { top: 12px; }
.page-width { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.tool-surface .wrap { width: min(960px, calc(100% - 40px)); }
.tool-surface .hero { display: block; grid-template-columns: none; min-height: 0; }
.tool-surface .hero h1 { line-height: .98; }
.staging-banner { background: var(--ink); color: #b8b5ac; text-align: center; padding: 6px 12px; font: 700 9px var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.staging-banner a { color: var(--yellow); }

/* ---------- header shell (F1/F6) ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.97); border-bottom: 1px solid rgba(20,20,20,.16); }
.header__inner { width: min(1320px, calc(100% - 40px)); min-height: 72px; margin-inline: auto; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; flex: none; }
.brand__panda { width: 34px; height: 34px; border-radius: 7px; }
.brand__type { display: grid; line-height: 1; }
.brand__type strong { font: 700 22px/1 var(--display); letter-spacing: -.02em; }
.brand__type small { margin-top: 4px; color: var(--muted); font: 700 7px/1 var(--mono); letter-spacing: .13em; text-transform: uppercase; }
.desktop-nav { display: flex; align-self: stretch; }
.nav-item { position: relative; display: flex; align-items: center; justify-content: center; min-width: 72px; padding: 0 14px; border: 0; background: transparent; cursor: pointer; text-decoration: none; color: #4f4d47; font: 700 11px var(--mono); text-transform: uppercase; letter-spacing: .04em; }
.nav-item:hover, .nav-item:focus-visible { color: var(--ink); background: var(--paper); outline: 0; }
.nav-item--active { color: var(--ink); }
.nav-item--active::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 12px; height: 3px; background: var(--yellow); }
.nav-count { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; margin-left: 6px; padding: 0 5px; background: var(--yellow); color: var(--ink); font-weight: 700; line-height: 1; }
.header__actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.search-button { min-height: 44px; border: 0; background: transparent; padding: 10px 8px; cursor: pointer; font: 700 10px var(--mono); text-transform: uppercase; letter-spacing: .04em; }
.search-button kbd { margin-left: 4px; padding: 2px 4px; border: 1px solid #c8c5bd; background: var(--paper); font: inherit; font-size: 8px; }
.search-button:hover, .search-button:focus-visible { background: var(--paper); outline: 2px solid var(--ink); outline-offset: -2px; }
.trip-button { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 7px 8px 7px 13px; border: 2px solid var(--ink); background: var(--white); cursor: pointer; font: 700 11px var(--mono); text-transform: uppercase; }
.trip-button strong { background: var(--yellow); padding: 5px 7px; font-weight: 700; }
.trip-button:hover, .trip-button:focus-visible { box-shadow: 4px 4px 0 var(--ink); transform: translate(-1px,-1px); outline: 0; }
.trip-button--current { background: var(--yellow); cursor: default; }
.trip-button--current:hover { box-shadow: none; transform: none; }
.trip-button--current strong { background: var(--white); }
.menu-button { display: none; min-height: 44px; border: 0; background: transparent; padding: 10px 12px; cursor: pointer; font: 700 10px var(--mono); text-transform: uppercase; letter-spacing: .04em; }
.menu-button:hover, .menu-button:focus-visible { background: var(--paper); outline: 2px solid var(--ink); outline-offset: -2px; }
.hazard { height: 9px; background: repeating-linear-gradient(135deg, var(--ink) 0 10px, var(--yellow) 10px 20px); }

/* ---------- hero (home, F3) ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(360px, .8fr); gap: 64px; align-items: start; padding-block: 64px 52px; }
.eyebrow { margin: 0 0 15px; color: var(--muted); font: 700 10px/1.2 var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.hero h1 { max-width: 720px; margin: 0; font: 700 clamp(42px, 6vw, 88px)/.88 var(--display); letter-spacing: -.04em; text-transform: uppercase; }
.hero h1 mark { background: var(--yellow); color: var(--ink); padding: 0 .05em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.hero-line { display: block; width: max-content; max-width: 100%; }
.hero__dek { max-width: 640px; margin: 24px 0 0; color: #4d4b46; font-size: 17px; line-height: 1.55; }
.hero-actions { display: flex; align-items: center; gap: 16px; margin-top: 28px; flex-wrap: wrap; }
.hero-cta { display: inline-grid; place-items: center; min-width: 230px; min-height: 48px; padding: 14px 22px; border: 2px solid var(--ink); cursor: pointer; text-decoration: none; text-align: center; font: 700 10px var(--mono); letter-spacing: .05em; text-transform: uppercase; }
.hero-cta--yellow { background: var(--yellow); }
.hero-cta--white { background: var(--white); }
.hero-cta:hover, .hero-cta:focus-visible { box-shadow: 5px 5px 0 var(--ink); transform: translate(-1px,-1px); outline: 0; }
.continue-strip { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 12px; align-items: center; margin-top: 18px; padding: 12px 16px; max-width: 560px; border: 2px solid var(--ink); border-left: 8px solid var(--yellow); background: var(--white); cursor: pointer; text-align: left; text-decoration: none; }
.continue-strip:hover, .continue-strip:focus-visible { box-shadow: 5px 5px 0 var(--ink); transform: translate(-1px,-1px); outline: 0; }
.continue-strip b { display: grid; place-items: center; width: 28px; height: 28px; background: var(--ink); color: var(--yellow); font-style: normal; font-size: 14px; }
.continue-strip span { font-size: 13px; }
.continue-strip small { color: var(--muted); font: 700 9px var(--mono); letter-spacing: .08em; white-space: nowrap; }
.verified-line { display: flex; align-items: center; gap: 10px; margin-top: 22px; color: var(--muted); font: 700 9px var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.verified-line img { width: 34px; height: 34px; }

/* example card (story list) */
.answer-card { border: 2px solid var(--ink); background: var(--white); box-shadow: 9px 9px 0 var(--ink); }
.example-card__label { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; background: var(--ink); color: var(--yellow); font: 700 10px var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.example-flag { background: var(--yellow); color: var(--ink); padding: 3px 6px; white-space: nowrap; font: 700 8px var(--mono); letter-spacing: .08em; }
.example-card__body { padding: 18px 20px 16px; }
.example-card__body h2 { margin: 0; font: 700 30px/.95 var(--display); text-transform: uppercase; }
.example-card__meta { margin: 6px 0 14px; color: var(--muted); font: 700 9px var(--mono); letter-spacing: .08em; }
.example-card__count { display: flex; align-items: baseline; gap: 8px; }
.example-card__count strong { font: 700 38px/.9 var(--display); }
.example-card__count span { color: var(--muted); font: 700 9px var(--mono); text-transform: uppercase; }
.progress-track { height: 8px; margin-top: 10px; background: #e3e0d8; }
.progress-track span { display: block; height: 100%; background: var(--yellow); transition: width .25s ease; }
.story-rows { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.story-row { display: grid; grid-template-columns: 30px minmax(0,1fr); gap: 10px; align-items: center; padding: 11px 20px; border-top: 1px solid #dfddd6; font-size: 13px; }
.story-row:first-child { border-top: 0; }
.story-row b { display: grid; place-items: center; width: 22px; height: 22px; font: 700 11px var(--mono); }
.story-row--done { color: #6a675f; }
.story-row--done b { background: var(--proof); color: var(--white); }
.story-row--done span { text-decoration: line-through; text-decoration-color: #b9b6ad; }
.story-row--next { background: var(--yellow); }
.story-row--next b { background: var(--ink); color: var(--yellow); }
.story-row--next strong { display: block; font-size: 13px; }
.story-row--next small, .story-row--recheck small { display: block; margin-top: 2px; color: rgba(20,20,20,.62); font: 9px var(--mono); text-transform: uppercase; }
.story-row--recheck { border-left: 5px solid var(--risk); padding-left: 15px; }
.story-row--recheck b { background: var(--white); border: 2px solid var(--risk); color: var(--risk); }
.story-row--recheck strong { display: block; color: var(--risk); font-size: 13px; }
.story-row--recheck small { color: var(--muted); }
.answer-card .primary-action { min-height: 58px; margin: 0; gap: 3px; padding-block: 11px; }
.answer-card .primary-action strong { font-size: 11px; }
.answer-card .primary-action small { color: rgba(20,20,20,.68); font: 700 8px/1.25 var(--mono); letter-spacing: .06em; }

.trust-strip { border-block: 1px solid #d8d5cd; background: var(--white); }
.trust-strip__inner { display: flex; gap: 34px; flex-wrap: wrap; min-height: 52px; align-items: center; color: var(--muted); font: 10px var(--mono); text-transform: uppercase; letter-spacing: .05em; }
.trust-strip__inner b { color: var(--ink); margin-right: 6px; font-weight: 700; }

/* ---------- modules ---------- */
.content-stack { display: grid; gap: 24px; padding-block: 34px 84px; }
.module { --module-edge: var(--yellow); background: var(--white); border: 2px solid var(--ink); border-left: 8px solid var(--module-edge); }
.module--changes { --module-edge: var(--logic); }
.module__head { display: grid; grid-template-columns: 56px minmax(0,1fr) auto; align-items: start; gap: 17px; padding: 21px 22px; border-bottom: 2px solid var(--ink); }
.module__index { display: grid; place-items: center; width: 56px; height: 56px; background: var(--ink); color: var(--yellow); font: 700 15px var(--mono); }
.module__heading > p:first-child { margin: 2px 0 7px; color: var(--muted); font: 700 10px/1.2 var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.module__heading h2 { margin: 0; font: 700 clamp(28px, 3.6vw, 46px)/.92 var(--display); letter-spacing: -.02em; text-transform: uppercase; }
.module__heading > p:last-child { margin: 9px 0 0; color: var(--muted); font-size: 13px; }
.lens { align-self: start; border: 1px solid currentColor; padding: 4px 7px; font: 700 8px var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.lens--essentials { color: var(--muted); }
.lens--decode { color: var(--logic); }

/* baseline checklist */
.baseline-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); }
.baseline-list { border-right: 2px solid var(--ink); }
.baseline-group__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 20px; background: var(--ink); color: var(--white); font: 700 10px var(--mono); text-transform: uppercase; letter-spacing: .07em; }
.baseline-group__head b { color: var(--yellow); }
.baseline-task { border-bottom: 1px solid #ddd9d1; }
.baseline-task:last-child { border-bottom: 0; }
.baseline-task--off { opacity: .45; }
.baseline-row { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; align-items: center; gap: 8px; padding: 2px 20px 2px 0; }
.baseline-num { display: grid; place-items: center; justify-self: center; width: 26px; height: 24px; background: var(--yellow); font: 700 10px var(--mono); }
.trip-area--page .baseline-row, .baseline-row--nonum { grid-template-columns: minmax(0,1fr) auto; padding-left: 0; }
.check-row { position: relative; display: grid; grid-template-columns: 24px minmax(0,1fr); gap: 10px; align-items: start; padding: 13px 0; cursor: pointer; min-height: 44px; }
.check-row--off { cursor: default; }
.check-row input { position: absolute; opacity: 0; pointer-events: none; }
.check-box { width: 21px; height: 21px; border: 2px solid currentColor; display: grid; place-items: center; }
.check-row input:checked + .check-box { background: var(--yellow); border-color: var(--yellow); }
.check-row input:checked + .check-box::after { content: ""; width: 8px; height: 4px; border-left: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(-45deg) translateY(-1px); }
.check-row input:focus-visible + .check-box { outline: 3px solid var(--logic); outline-offset: 2px; }
.check-row strong { display: block; font-size: 13px; line-height: 1.35; }
.check-row small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.check-row--compact { min-height: 36px; padding: 9px 0; }
.check-row--compact .check-box { width: 17px; height: 17px; }
.check-row--compact strong { font-size: 12px; font-weight: 600; }
.when-chip { display: inline-block; margin-left: 8px; padding: 2px 5px; vertical-align: 1px; background: var(--paper); border: 1px solid #cfccc4; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .06em; font-style: normal; }
.task-state-chip { display: inline-block; margin-top: 6px; padding: 3px 6px; background: #fff8d6; border: 1px solid #9b7100; color: #704f00; font: 700 8px var(--mono); letter-spacing: .06em; font-style: normal; }
.recheck-chip { display: inline-block; margin-top: 6px; padding: 3px 6px; background: #fff3f1; border: 1px solid var(--risk); color: var(--risk); font: 700 8px var(--mono); letter-spacing: .06em; font-style: normal; }
.baseline-side { display: flex; gap: 8px; align-items: center; }
.mini-link { border: 0; background: transparent; cursor: pointer; padding: 8px 4px; color: var(--muted); font: 700 9px var(--mono); text-transform: uppercase; letter-spacing: .04em; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.mini-link:hover, .mini-link:focus-visible { color: var(--ink); background: var(--yellow); outline: 0; }
.mini-link--on { color: var(--proof); }
.mini-link--steps { color: var(--ink); text-decoration: none; border: 1px solid #c7c4bc; padding: 6px 8px; }
.mini-link--steps:hover, .mini-link--steps:focus-visible { border-color: var(--ink); }
/* Mobile DoD rule 2 (shell spec §4): interactive targets ≥44px on touch. */
@media (pointer: coarse), (max-width: 600px) {
  .mini-link, .brand { min-height: 44px; display: inline-flex; align-items: center; }
}
.sub-list { display: grid; padding: 0 20px 14px 64px; }
.sub-list .check-row { border-bottom: 1px dashed #ddd9d1; }
.sub-list .check-row:last-of-type { border-bottom: 0; }
.sub-guide { justify-self: start; margin-top: 6px; color: var(--logic); }
.trip-area--page .sub-list { padding: 0 0 12px 34px; }

/* rail */
.baseline-rail { display: grid; align-content: start; }
.rail-progress { padding: 22px; background: var(--ink); color: var(--white); }
.rail-progress__label { margin: 0 0 12px; color: var(--yellow); font: 700 9px var(--mono); letter-spacing: .09em; }
.rail-progress__count { display: flex; align-items: baseline; gap: 8px; }
.rail-progress__count strong { color: var(--yellow); font: 700 46px/.9 var(--display); }
.rail-progress__count span { color: #aaa69d; font: 700 9px var(--mono); text-transform: uppercase; }
.rail-progress .progress-track { margin-top: 14px; background: #44423e; }
.rail-progress__note { margin: 12px 0 0; color: #c0bdb5; font-size: 11px; line-height: 1.55; }
.persist-note { margin: 12px 0 0; color: #85827b; font: 700 8px var(--mono); letter-spacing: .05em; }
.primary-action { display: grid; place-items: center; width: 100%; min-height: 46px; margin-top: 18px; border: 0; background: var(--yellow); color: var(--ink); padding: 14px; cursor: pointer; text-decoration: none; text-align: center; font: 700 10px var(--mono); letter-spacing: .05em; text-transform: uppercase; }
.primary-action:hover, .primary-action:focus-visible { background: var(--white); box-shadow: 4px 4px 0 var(--yellow); outline: 2px solid var(--ink); }
.secondary-action { min-height: 44px; margin-top: 12px; border: 2px solid var(--ink); background: var(--yellow); padding: 10px 12px; cursor: pointer; font: 700 9px var(--mono); text-transform: uppercase; }
.refine-box { padding: 20px 22px; border-top: 2px solid var(--ink); background: var(--white); }
.refine-box__label { margin: 0 0 6px; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .09em; }
.refine-box__context { margin: 0 0 10px; font-size: 13px; font-weight: 700; }
.refine-box small { display: block; margin-top: 12px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.refine-form { display: grid; gap: 10px; margin-top: 6px; }
.refine-form label { display: grid; gap: 4px; font: 700 8px var(--mono); text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.refine-form select, .refine-form input { min-height: 40px; border: 1px solid #c7c4bc; background: var(--paper); padding: 8px 10px; font: 400 13px var(--body); }

/* teasers */
.library-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.library-card { display: grid; gap: 8px; align-content: start; min-height: 170px; padding: 18px; text-align: left; background: var(--white); border: 0; border-right: 1px solid #ddd9d1; cursor: pointer; text-decoration: none; }
.library-card:nth-child(4n) { border-right: 0; }
.library-card:hover, .library-card:focus-visible { background: var(--paper); outline: 2px solid var(--ink); outline-offset: -2px; }
.library-card__type { color: var(--muted); font: 700 8px var(--mono); letter-spacing: .08em; }
.library-card h3 { margin: 0; font: 700 20px/.95 var(--display); text-transform: uppercase; }
.library-card p { margin: 0; color: #5d5a54; font-size: 11px; line-height: 1.5; }
.library-card__foot { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: auto; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .05em; }
.library-card__feeds { color: var(--logic); }
.library-foot { display: flex; justify-content: flex-end; padding: 12px 20px; border-top: 1px solid #ddd9d1; background: var(--paper); }
.changes-list { display: grid; }
.change-row { display: grid; grid-template-columns: 110px minmax(0,1fr); gap: 18px; padding: 20px 24px; border-bottom: 1px solid #ddd9d1; text-decoration: none; }
.change-row:last-of-type { border-bottom: 0; }
.change-row:hover { background: var(--paper); }
.change-date { color: var(--muted); font: 700 9px var(--mono); letter-spacing: .06em; }
.change-row h3 { margin: 0 0 6px; font-size: 15px; line-height: 1.3; }
.change-row p { margin: 0 0 10px; color: #5d5a54; font-size: 12px; line-height: 1.5; }
.change-meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.evidence-chip { border: 1px solid var(--logic); color: var(--logic); padding: 3px 6px; font: 700 8px var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.change-affects { color: var(--muted); font: 700 9px var(--mono); text-transform: uppercase; }

.two-paths { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.home-surface .path-card { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; gap: 16px; align-items: center; text-align: left; padding: 22px; border: 2px solid var(--ink); background: var(--white); cursor: pointer; text-decoration: none; }
.home-surface .path-card:hover, .home-surface .path-card:focus-visible { box-shadow: 6px 6px 0 var(--ink); transform: translate(-1px,-1px); outline: 0; }
.home-surface .path-card b { display: grid; place-items: center; width: 44px; height: 44px; background: var(--yellow); font: 700 13px var(--mono); }
.home-surface .path-card small { display: block; margin-bottom: 5px; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .09em; text-transform: uppercase; }
.home-surface .path-card strong { display: block; font: 700 21px/1 var(--display); text-transform: uppercase; }
.home-surface .path-card em { display: block; margin-top: 6px; color: var(--muted); font-style: normal; font-size: 11px; }
.home-surface .path-card i { font-style: normal; font-size: 18px; }

.page-footer { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; padding: 30px 0 40px; color: var(--muted); }
.page-footer strong { color: var(--ink); font: 700 18px var(--display); }
.page-footer p { max-width: 520px; margin: 7px 0 0; font-size: 11px; line-height: 1.5; }
.source-links { display: flex; justify-content: flex-end; gap: 12px; flex-wrap: wrap; align-content: start; }
.source-links span, .source-links a { border: 1px solid #ccc9c1; padding: 6px 8px; font: 700 8px var(--mono); text-transform: uppercase; text-decoration: none; }

/* ---------- overlays ---------- */
.overlay { position: fixed; inset: 0; z-index: 100; display: flex; justify-content: flex-end; background: rgba(20,20,20,.55); backdrop-filter: blur(2px); }
.overlay--center { justify-content: center; align-items: flex-start; padding-top: 8vh; }
.trip-drawer { width: min(480px, 100%); height: 100%; overflow-y: auto; background: var(--paper); border-left: 2px solid var(--ink); box-shadow: -18px 0 50px rgba(0,0,0,.22); }
.panel-top { min-height: 76px; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 18px 22px; border-bottom: 2px solid var(--ink); background: var(--white); }
.panel-top p { margin: 0 0 3px; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .09em; }
.panel-top h2 { margin: 0; font: 700 30px/.9 var(--display); text-transform: uppercase; }
.panel-top button { min-height: 44px; border: 1px solid var(--ink); background: var(--white); padding: 8px 10px; cursor: pointer; font: 700 9px var(--mono); text-transform: uppercase; }
.panel-top button:hover, .panel-top button:focus-visible { background: var(--yellow); outline: 2px solid var(--ink); }
.panel-brand { font: 700 22px var(--display); }
.trip-progress { padding: 22px; background: var(--ink); color: var(--white); }
.trip-progress > div:first-child { display: flex; align-items: baseline; gap: 8px; }
.trip-progress strong { color: var(--yellow); font: 700 42px/.9 var(--display); }
.trip-progress span { color: #aaa69d; font: 700 9px var(--mono); text-transform: uppercase; }
.trip-progress .progress-track { margin-top: 14px; background: #44423e; }
.trip-progress p { margin: 10px 0 0; color: #c0bdb5; font-size: 11px; }
.quick-next { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; gap: 12px; align-items: center; margin: 14px; padding: 14px; border: 2px solid var(--ink); background: var(--yellow); text-align: left; cursor: pointer; text-decoration: none; }
.quick-next:hover, .quick-next:focus-visible { box-shadow: 4px 4px 0 var(--ink); transform: translate(-1px,-1px); outline: 0; }
.quick-next small { font: 700 9px var(--mono); letter-spacing: .08em; }
.quick-next strong { display: block; font-size: 14px; }
.quick-next em { display: block; margin-top: 3px; color: rgba(20,20,20,.62); font-style: normal; font-size: 11px; }
.quick-next i { font-style: normal; font-size: 16px; }
.quick-rechecks { margin: 0 14px 14px; border: 2px solid var(--risk); background: #fff3f1; }
.quick-rechecks > p { margin: 0; padding: 9px 14px; color: var(--risk); font: 700 9px var(--mono); letter-spacing: .08em; border-bottom: 1px solid #f0d5d2; }
.quick-rechecks a { display: grid; grid-template-columns: minmax(0,1fr) auto auto; gap: 10px; align-items: center; min-height: 44px; padding: 8px 14px; border-top: 1px solid #f0d5d2; text-decoration: none; }
.quick-rechecks a:first-of-type { border-top: 0; }
.quick-rechecks a:hover, .quick-rechecks a:focus-visible { background: #ffe9e6; outline: 0; }
.quick-rechecks strong { font-size: 12px; }
.quick-rechecks span { color: var(--muted); font: 700 8px var(--mono); text-transform: uppercase; }
.quick-rechecks i { font-style: normal; }
.quick-areas { margin: 0 14px 14px; border: 2px solid var(--ink); background: var(--white); }
.quick-areas > p { margin: 0; padding: 9px 14px; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .08em; border-bottom: 1px solid #ddd9d1; }
.quick-area { display: grid; grid-template-columns: minmax(0,1fr) auto 18px; gap: 10px; align-items: center; min-height: 46px; padding: 0 14px; border-top: 1px solid #e6e3dc; text-decoration: none; }
.quick-area:first-of-type { border-top: 0; }
.quick-area:hover, .quick-area:focus-visible { background: var(--paper); outline: 0; }
.quick-area span { font: 700 15px var(--display); text-transform: uppercase; }
.quick-area b { padding: 3px 6px; background: var(--paper); font: 700 9px var(--mono); }
.quick-area i { font-style: normal; color: var(--muted); }
.drawer-foot { padding: 14px; }
.drawer-foot .primary-action { margin: 0; }
.drawer-foot small { display: block; margin-top: 9px; color: var(--muted); font: 700 8px/1.5 var(--mono); text-transform: uppercase; letter-spacing: .04em; text-align: center; }

.mobile-menu { width: min(390px, 100%); height: 100%; overflow-y: auto; background: var(--paper); border-left: 2px solid var(--ink); }
.mobile-menu nav > a, .mobile-menu nav > button { display: flex; width: 100%; justify-content: space-between; align-items: center; min-height: 64px; padding: 20px 22px; border: 0; border-bottom: 1px solid #cac7bf; background: transparent; color: inherit; cursor: pointer; text-align: left; text-decoration: none; font: 700 28px var(--display); text-transform: uppercase; }
.mobile-menu nav > a:hover, .mobile-menu nav > a:focus-visible, .mobile-menu nav > button:hover, .mobile-menu nav > button:focus-visible { background: var(--yellow); outline: 2px solid var(--ink); outline-offset: -2px; }
.mobile-menu nav > a[aria-current="page"] { background: var(--yellow); color: var(--ink); }
.mobile-menu nav > a span, .mobile-menu nav > button span { color: var(--muted); font: 700 9px var(--mono); }

/* Search is a router over existing surfaces and My Trip tasks (F1/P2-9). */
.search-card { width: min(720px, calc(100% - 32px)); max-height: 84vh; display: grid; grid-template-rows: auto minmax(0,1fr); background: var(--white); border: 2px solid var(--ink); box-shadow: 12px 12px 0 var(--ink); }
.search-body { min-height: 0; overflow-y: auto; padding: 20px; }
.search-body > label { display: block; margin-bottom: 7px; color: var(--muted); font: 700 8px var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.search-body > input { width: 100%; min-height: 52px; border: 2px solid var(--ink); background: var(--paper); padding: 11px 14px; font-size: 16px; }
.search-body > input:focus { outline: 3px solid var(--yellow); outline-offset: 2px; }
.search-hint { margin: 9px 0 14px; color: var(--muted); font: 700 8px var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.search-results { border: 2px solid var(--ink); }
.search-results > a { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 3px 16px; align-items: center; min-height: 54px; padding: 10px 14px; border-top: 1px solid #ddd9d1; text-decoration: none; }
.search-results > a:first-child { border-top: 0; }
.search-results > a:hover, .search-results > a:focus-visible { background: var(--yellow); outline: 2px solid var(--ink); outline-offset: -2px; }
.search-results strong { font-size: 13px; }
.search-results small { grid-column: 1; color: var(--muted); font-size: 10px; }
.search-results i { grid-column: 2; grid-row: 1 / span 2; font-style: normal; }
.search-empty { margin: 0; padding: 18px; color: var(--muted); font-size: 12px; }
.toast { position: fixed; z-index: 150; left: 50%; bottom: 26px; transform: translateX(-50%); background: var(--ink); color: var(--white); border: 2px solid var(--yellow); padding: 13px 18px; box-shadow: 5px 5px 0 var(--yellow); font: 700 10px var(--mono); text-transform: uppercase; white-space: nowrap; }

/* ---------- trip page ---------- */
.trip-layout { display: grid; grid-template-columns: 190px minmax(0,1fr) 250px; gap: 28px; align-items: start; padding-block: 34px 84px; }
.trip-sidebar { position: sticky; top: 100px; display: grid; gap: 4px; padding: 18px 0; background: var(--ink); color: var(--white); }
.trip-chip { margin: 0 14px 14px; padding: 8px 10px; border: 1px solid #57554f; color: #d0cdc5; font: 700 8px var(--mono); letter-spacing: .06em; }
.trip-nav__item { display: flex; align-items: center; width: 100%; text-align: left; min-height: 44px; padding: 11px 18px; border: 0; border-left: 4px solid transparent; background: transparent; color: #b8b5ac; cursor: pointer; text-decoration: none; font: 700 10px var(--mono); text-transform: uppercase; letter-spacing: .05em; }
.trip-nav__item:hover, .trip-nav__item:focus-visible { color: var(--white); background: #232320; outline: 0; }
.trip-nav__item--active { border-left-color: var(--yellow); color: var(--white); }
.trip-sidebar .mini-link { margin: 14px 18px 0; color: #b8b5ac; }
.trip-main { display: grid; gap: 18px; }
.trip-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; }
.trip-head h1 { margin: 0; font: 700 clamp(42px, 5vw, 64px)/.98 var(--display); letter-spacing: -.04em; text-transform: uppercase; }
.trip-head__meta { margin: 8px 0 0; color: var(--muted); font: 700 10px var(--mono); letter-spacing: .06em; }
.trip-head__actions { display: flex; gap: 8px; }
.ghost-button { min-height: 44px; border: 2px solid var(--ink); background: var(--white); padding: 9px 12px; cursor: pointer; font: 700 9px var(--mono); text-transform: uppercase; }
.ghost-button:hover, .ghost-button:focus-visible { background: var(--yellow); outline: 0; }
.trip-progress--page { border: 2px solid var(--ink); }
.critical-banner { border: 2px solid var(--risk); border-left-width: 8px; background: var(--white); padding: 16px 20px; }
.critical-banner__label { margin: 0 0 8px; color: var(--risk); font: 700 10px var(--mono); letter-spacing: .08em; }
.critical-row { display: grid; grid-template-columns: 28px minmax(0,1fr) auto; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid #f0d5d2; }
.critical-row b { display: grid; place-items: center; width: 24px; height: 24px; background: var(--risk); color: var(--white); font: 700 10px var(--mono); }
.critical-row strong { display: block; font-size: 13px; }
.critical-row span { color: var(--muted); font-size: 11px; }
.trip-area { margin: 0; padding: 18px; border: 2px solid var(--ink); border-left-width: 7px; background: var(--white); }
.trip-area > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid #d8d5cd; }
.trip-area > header span { font: 700 22px var(--display); text-transform: uppercase; }
.trip-area > header strong { padding: 4px 6px; background: var(--paper); font: 700 10px var(--mono); }
.trip-area--alert { border-left-color: var(--risk); }
.trip-area--payment { border-left-color: var(--yellow); }
.trip-area--quiet { border-left-color: var(--proof); }
.trip-rightcol { position: sticky; top: 100px; display: grid; gap: 16px; }
.side-card { border: 1px solid #c7c4bc; background: var(--white); padding: 16px; }
.side-card__label { margin: 0 0 10px; color: var(--muted); font: 700 8px var(--mono); letter-spacing: .09em; }
.side-card__body { margin: 0; font-size: 11px; line-height: 1.55; color: #55524d; }
.side-change { display: grid; gap: 3px; padding: 10px 0; border-top: 1px solid #e4e1da; text-decoration: none; }
.side-change:first-of-type { border-top: 0; }
.side-change span { color: var(--muted); font: 700 8px var(--mono); }
.side-change strong { font-size: 12px; line-height: 1.35; }
.side-change em { color: var(--risk); font-style: normal; font: 700 9px var(--mono); }
.subscribe-mock { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; margin-top: 10px; }
.subscribe-mock input { min-height: 44px; border: 1px solid #c7c4bc; background: var(--paper); padding: 8px 10px; font: 400 12px var(--body); min-width: 0; }
.subscribe-mock button { min-height: 44px; border: 2px solid var(--ink); background: var(--yellow); padding: 8px 10px; cursor: pointer; font: 700 8px var(--mono); text-transform: uppercase; }
.persist-note--dark { color: #85827b; }

/* snapshot */
.snapshot-card { width: min(640px, calc(100% - 32px)); max-height: 84vh; display: grid; grid-template-rows: auto 1fr; background: var(--white); border: 2px solid var(--ink); box-shadow: 12px 12px 0 var(--ink); }
.snapshot-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 20px; border-bottom: 2px solid var(--ink); background: var(--ink); color: var(--white); }
.snapshot-head p { margin: 0 0 4px; color: var(--yellow); font: 700 8px var(--mono); letter-spacing: .09em; }
.snapshot-head h2 { margin: 0; font: 700 26px/.95 var(--display); text-transform: uppercase; }
.snapshot-head__actions { display: flex; gap: 8px; }
.snapshot-head .ghost-button { background: var(--white); color: var(--ink); }
.snapshot-body { overflow-y: auto; padding: 6px 20px 18px; }
.snapshot-area h3 { margin: 16px 0 6px; font: 700 15px var(--display); text-transform: uppercase; border-bottom: 2px solid var(--ink); padding-bottom: 5px; }
.snapshot-row { display: grid; grid-template-columns: 56px minmax(0,1fr); gap: 12px; align-items: start; padding: 8px 0; border-bottom: 1px dashed #ddd9d1; }
.snapshot-row:last-child { border-bottom: 0; }
.snapshot-row b { font: 700 9px var(--mono); color: var(--muted); }
.snapshot-row strong { display: block; font-size: 12.5px; }
.snapshot-row small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.snapshot-foot { margin: 18px 0 0; padding-top: 12px; border-top: 2px solid var(--ink); color: var(--muted); font: 700 9px/1.6 var(--mono); letter-spacing: .04em; text-transform: uppercase; }

/* My Trip profile editor: the canonical returning-user surface for the same
   four lightweight fields first offered on Home. */
.trip-details-card { width: min(560px, calc(100% - 32px)); max-height: 84vh; overflow-y: auto; background: var(--white); border: 2px solid var(--ink); box-shadow: 12px 12px 0 var(--ink); }
.trip-details-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 20px; }
.trip-details-intro { grid-column: 1 / -1; margin: 0 0 4px; color: #55524d; font-size: 12px; line-height: 1.55; }
.trip-details-form label { display: grid; gap: 6px; color: var(--muted); font: 700 9px var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.trip-details-form input, .trip-details-form select { width: 100%; min-height: 46px; border: 2px solid var(--ink); background: var(--paper); padding: 10px 12px; color: var(--ink); font: 400 14px var(--body); text-transform: none; letter-spacing: 0; }
.trip-details-form input:focus, .trip-details-form select:focus { outline: 3px solid var(--yellow); outline-offset: 2px; }
.trip-details-actions { grid-column: 1 / -1; display: grid; gap: 9px; margin-top: 4px; }
.trip-details-actions .primary-action { margin: 0; min-height: 48px; border: 2px solid var(--ink); }
.trip-details-actions small { color: var(--muted); font: 700 8px var(--mono); text-align: center; text-transform: uppercase; letter-spacing: .05em; }

@media print {
  body > *:not(.snapshot-overlay) { display: none !important; }
  .snapshot-overlay { position: static !important; background: none !important; backdrop-filter: none !important; padding: 0 !important; display: block !important; }
  .snapshot-card { width: 100% !important; max-height: none !important; border: 1px solid #000 !important; box-shadow: none !important; }
  .snapshot-head__actions { display: none !important; }
  .snapshot-body { overflow: visible !important; }
}

/* ---------- responsive (DoD: 600 / 920 / 1100 collapse) ---------- */
@media (max-width: 1100px) {
  .trip-layout { grid-template-columns: minmax(0,1fr); }
  .trip-sidebar, .trip-rightcol { position: static; }
  .trip-sidebar { display: flex; overflow-x: auto; align-items: center; padding: 10px 12px; }
  .trip-sidebar nav { display: flex; flex: none; }
  .trip-chip { margin: 0 8px 0 0; }
  .trip-nav__item { width: auto; flex: none; white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; }
  .trip-nav__item--active { border-bottom-color: var(--yellow); }
  .trip-sidebar .mini-link { margin: 0 0 0 8px; }
}
@media (max-width: 920px) {
  .page-width { width: min(100% - 32px, 760px); }
  .desktop-nav { display: none; }
  .search-button { display: none; }
  .menu-button { display: inline-block; }
  .hero { grid-template-columns: 1fr; gap: 42px; padding-block: 44px 40px; }
  .baseline-grid { grid-template-columns: 1fr; }
  .baseline-list { border-right: 0; border-bottom: 2px solid var(--ink); }
  .library-grid { grid-template-columns: 1fr 1fr; }
  .library-card { min-height: 0; }
  .library-card:nth-child(2n) { border-right: 0; }
  .library-card:nth-last-child(-n+2) { border-bottom: 0; }
  .library-card { border-bottom: 1px solid #ddd9d1; }
  .two-paths { grid-template-columns: 1fr; }
  .change-row { grid-template-columns: 1fr; gap: 6px; }
}
@media (max-width: 600px) {
  .tool-surface .wrap { width: calc(100% - 24px); }
  html { scroll-padding-top: 88px; }
  .page-width { width: calc(100% - 24px); }
  .header__inner { width: calc(100% - 24px); min-height: 60px; gap: 8px; }
  .brand__type small { display: none; }
  .brand__panda { width: 28px; height: 28px; }
  .brand__type strong { font-size: 20px; }
  .hazard { height: 7px; }
  /* DoD rule 8: first viewport must fit headline + dek + one CTA. */
  .hero { gap: 30px; padding-block: 30px 26px; }
  .eyebrow { margin-bottom: 10px; font-size: 8px; }
  .hero h1 { font-size: clamp(34px, 11vw, 52px); line-height: .9; }
  .hero-line { display: block; width: max-content; max-width: 100%; }
  .hero__dek { margin-top: 14px; font-size: 14px; }
  .hero-actions { margin-top: 16px; gap: 10px; }
  .hero-cta { width: 100%; min-height: 46px; }
  .verified-line { margin-top: 14px; align-items: flex-start; line-height: 1.5; }
  .verified-line img { width: 28px; height: 28px; }
  .answer-card { box-shadow: 6px 6px 0 var(--ink); }
  .module__head { grid-template-columns: 43px minmax(0,1fr); gap: 12px; padding: 16px; }
  .module__index { width: 43px; height: 43px; font-size: 12px; }
  .lens { display: none; }
  .baseline-row { grid-template-columns: 36px minmax(0,1fr); padding-right: 12px; }
  .baseline-num { width: 22px; height: 20px; font-size: 9px; }
  .baseline-side { grid-column: 2; padding-bottom: 10px; flex-wrap: wrap; }
  .trip-area--page .baseline-row, .baseline-row--nonum { grid-template-columns: minmax(0,1fr); }
  .sub-list { padding: 0 16px 12px 44px; }
  .library-grid { grid-template-columns: 1fr; }
  .library-card { border-right: 0 !important; }
  .trust-strip__inner { gap: 8px; padding-block: 10px; flex-direction: column; align-items: flex-start; }
  .trip-head__actions { width: 100%; }
  .trip-head__actions > * { flex: 1; display: grid; place-items: center; text-align: center; }
  .trip-layout { padding-block: 16px 54px; }
  .trip-sidebar { margin-inline: -12px; }
  .trip-chip, .trip-sidebar > .mini-link { display: none; }
  .critical-row { grid-template-columns: 24px minmax(0,1fr); }
  .critical-row .secondary-action { grid-column: 2; justify-self: start; margin-top: 2px; }
  .overlay--center { padding-top: 0; align-items: stretch; }
  .snapshot-card { width: 100%; max-height: 100%; border: 0; box-shadow: none; }
  .trip-details-card { width: 100%; max-height: 100%; border: 0; box-shadow: none; }
  .trip-details-form { grid-template-columns: 1fr; padding: 16px 12px; }
  .snapshot-head { align-items: flex-start; padding: 14px 12px; }
  .snapshot-head__actions { flex-direction: column; }
  .snapshot-head .ghost-button { min-height: 44px; padding: 7px 9px; font-size: 8px; }
  .search-card { width: 100%; max-height: 100%; border: 0; box-shadow: none; }
  .trip-drawer { width: 100%; border-left: 0; }
  .page-footer { grid-template-columns: 1fr; gap: 18px; }
  .source-links { justify-content: flex-start; }
  .toast { max-width: calc(100% - 24px); white-space: normal; text-align: center; bottom: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
