:root {
  --ink: #1C2321;
  --muted: #4E5A57;
  --paper: #FFFFFF;
  --concrete: #E9ECEA;
  --mandatory: #1D4E89;   /* ISO 7010 mandatory-action blue */
  --warning: #F2B705;     /* ISO 7010 warning yellow */
  --danger: #B3261E;      /* ISO 7010 prohibition/danger red */
  --neutral: #5B6670;
  --focus: #1D4E89;
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Atkinson Hyperlegible", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.5 var(--body); }
a { color: var(--mandatory); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.top, .demo, main { max-width: 520px; margin: 0 auto; padding-left: 16px; padding-right: 16px; }
.top { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; padding-top: 14px; }
.brand { font: 700 22px/1.1 var(--display); color: var(--ink); text-decoration: none; }
nav { display: flex; gap: 14px; font-size: 15px; }
.demo { font-size: 14px; color: var(--muted); margin-top: 6px; margin-bottom: 0; }
main { padding-bottom: 24px; }
h1 { font: 700 30px/1.1 var(--display); margin: 22px 0 6px; }
h2 { font: 700 22px/1.15 var(--display); margin: 26px 0 8px; }
p { margin: 6px 0; max-width: 62ch; }
.small { font-size: 15px; color: var(--muted); }

/* zone picker */
.zones { display: grid; gap: 10px; margin-top: 14px; }
.zones button { text-align: left; padding: 14px 16px; border: 2px solid var(--ink); background: var(--paper); font: 700 20px/1.2 var(--body); color: var(--ink); cursor: pointer; }
.zones button span { display: block; font-weight: 400; font-size: 15px; color: var(--muted); }
.zonebar { display: flex; justify-content: space-between; align-items: baseline; margin-top: 18px; gap: 12px; }
.zonebar strong { font: 700 24px/1 var(--display); }

/* legal band: mandatory blue sign */
.legal { background: var(--mandatory); color: #fff; padding: 14px 16px; margin-top: 14px; }
.legal h2 { margin: 0 0 6px; color: #fff; font-size: 20px; }
.legal ul { margin: 0; padding-left: 20px; }
.legal li { margin: 4px 0; }
.legal a { color: #fff; }
.src { font-size: 13px; opacity: .85; display: block; }

/* tier: the bold element */
.tier { margin-top: 18px; border-left: 14px solid var(--neutral); padding: 4px 0 4px 14px; }
.tier.high { border-color: var(--danger); }
.tier.elevated { border-color: var(--warning); }
.tier.none { border-color: var(--neutral); }
.tier.off { border-color: #C9CFCC; }
.tier.off .word { font-size: 44px; color: var(--ink); }
.tier .word { font: 700 64px/0.95 var(--display); letter-spacing: -0.5px; margin: 0; }
.tier.high .word { color: var(--danger); }
.tier .what { font-size: 16px; color: var(--muted); margin-top: 2px; }
.why { font-size: 18px; margin-top: 10px; }

.strip { margin-top: 14px; }
.strip svg { width: 100%; height: 46px; display: block; }
.strip .legend { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }

.cta { position: fixed; left: 0; right: 0; bottom: 0; background: var(--paper); border-top: 2px solid var(--ink); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
.cta div { max-width: 520px; margin: 0 auto; display: flex; gap: 10px; }
.btn { flex: 1; display: inline-block; text-align: center; padding: 14px 16px; font: 700 18px/1.2 var(--body); background: var(--ink); color: #fff; border: 2px solid var(--ink); text-decoration: none; cursor: pointer; }
.btn.secondary { background: var(--paper); color: var(--ink); }

/* crew switches */
fieldset { border: 0; padding: 0; margin: 18px 0 0; }
legend { font-weight: 700; font-size: 18px; margin-bottom: 8px; max-width: 62ch; }
.seg { display: flex; border: 2px solid var(--ink); }
.seg label { flex: 1; text-align: center; padding: 12px 6px; cursor: pointer; font-weight: 700; }
.seg label + label { border-left: 2px solid var(--ink); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg input:checked + span { text-decoration: underline 3px; }
.seg label:has(input:checked) { background: var(--ink); color: #fff; }
.seg label:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: -5px; }

/* plan */
.layer { margin-top: 18px; border-top: 3px solid var(--ink); padding-top: 8px; }
.layer.law { border-color: var(--mandatory); }
.layer.model { border-color: var(--warning); }
.layer h2 { margin: 0 0 4px; font-size: 21px; }
.status { font-size: 14px; color: var(--muted); }
.actions { list-style: none; padding: 0; margin: 6px 0 0; }
.actions li { padding: 10px 0; border-bottom: 1px solid var(--concrete); }
.owner { display: block; font-size: 14px; color: var(--muted); }
.ack { background: var(--concrete); padding: 14px 16px; margin-top: 18px; }

/* tables */
table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 16px; }
th, td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--concrete); vertical-align: top; }
th { font-weight: 700; }
td.num { font-variant-numeric: tabular-nums; }
.chip { font-weight: 700; padding: 2px 8px; display: inline-block; }
.chip.high { background: var(--danger); color: #fff; }
.chip.elevated { background: var(--warning); color: var(--ink); }
.chip.none { background: var(--concrete); }
.chip.off { background: repeating-linear-gradient(45deg, var(--concrete) 0 6px, #fff 6px 12px); }
select, input[type=date] { font: 400 17px var(--body); padding: 10px; border: 2px solid var(--ink); width: 100%; background: var(--paper); color: var(--ink); }
.picks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.picks button { padding: 8px 12px; border: 2px solid var(--ink); background: var(--paper); font: 700 15px var(--body); cursor: pointer; color: var(--ink); }
.big { font: 700 44px/1 var(--display); }
.facts { display: grid; gap: 14px; margin-top: 12px; }
.facts p { margin: 2px 0 0; }

@media (min-width: 900px) {
  body { font-size: 18px; }
  .top, .demo, main { max-width: 640px; }
  .cta div { max-width: 640px; }
}
.zlist { list-style: none; padding: 0; margin: 10px 0 0; }
.zlist li { padding: 12px 0; border-bottom: 1px solid var(--concrete); }
.zrow { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 19px; }
.foot { max-width: 520px; margin: 0 auto; padding: 0 16px 140px; font-size: 13px; color: var(--muted); }
@media (min-width: 900px) { .foot { max-width: 640px; } }

/* S7: emergency card */
.sos { position: sticky; top: 0; z-index: 5; display: block; max-width: 520px; margin: 10px auto 0; padding: 10px 16px; background: var(--danger); color: #fff; font: 700 17px/1.25 var(--body); text-decoration: none; box-sizing: border-box; }
.sos::before { content: "+ " / ""; }
.btn.call { display: block; margin: 14px 0 6px; background: var(--danger); border-color: var(--danger); font-size: 22px; }
.sos-steps { padding-left: 24px; margin: 14px 0; }
.sos-steps li { margin-bottom: 12px; font-size: 18px; }

/* Out of season: one tap to a real summer day */
.offseason { border: 2px solid var(--ink); padding: 12px 14px; margin: 14px 0; }
.offseason .btn { display: block; width: 100%; margin: 10px 0 6px; }

/* v3 risk map (review feedback, 17 Nov 2026) */
nav a[aria-current] { font-weight: 700; text-decoration-thickness: 3px; }
body.wide .top, body.wide .demo, body.wide main, body.wide .sos, body.wide .foot { max-width: 1240px; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.dash { display: grid; gap: 14px 22px; grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "left" "side"; margin-top: 14px; }
.dash-head { grid-area: head; } .dash-left { grid-area: left; display: grid; gap: 14px; } .dash-side { grid-area: side; contain: layout style; }
.dash h1 { margin-top: 4px; }
.modes, .clock, .sts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.modes button, .clock button, .sts button, .zchips button { font: 700 15px/1.2 var(--body); padding: 8px 12px; border: 2px solid var(--ink); background: var(--paper); color: var(--ink); cursor: pointer; }
.modes button[aria-pressed=true], .clock button[aria-pressed=true], .sts button[aria-pressed=true], .zchips button[aria-pressed=true] { background: var(--ink); color: #fff; }
.clock button { font-size: 14px; padding: 6px 10px; }
.banner { background: var(--concrete); padding: 10px 14px; margin: 10px 0 0; max-width: none; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--mandatory); text-decoration: underline; cursor: pointer; }
.map { height: 360px; border: 2px solid var(--ink); background: var(--concrete); isolation: isolate; }
.ztip { font: 400 13px/1.2 var(--body); border: 1px solid var(--ink); border-radius: 0; box-shadow: none; padding: 2px 6px; }
.zchips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.zchips button { display: inline-flex; align-items: center; gap: 6px; }
.zchips button span { font-weight: 400; }
.zchips i, .legend-keys i { width: 12px; height: 12px; display: inline-block; border: 1px solid var(--ink); }
.legend-keys { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 14px; padding: 0; margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.legend-keys li { display: inline-flex; align-items: center; gap: 5px; }
.legend-keys i.off, .zchips i[style*="FFFFFF"] { background: #fff; }
.dash-time fieldset { margin: 0; }
.dash-time legend { font-weight: 400; font-size: 14px; }
.trow { display: flex; gap: 10px; align-items: center; }
.trow .btn { flex: 0 0 auto; padding: 8px 14px; font-size: 15px; }
#d-range { flex: 1; accent-color: var(--ink); min-height: 40px; }
#d-out { flex: 0 0 auto; font-weight: 700; font-size: 15px; min-width: 9.5em; text-align: right; }
fieldset[disabled] .trow, fieldset[disabled] .season { opacity: .45; }
.season { position: relative; margin-top: 6px; padding-left: 0; }
.season svg { width: 100%; height: 64px; display: block; cursor: pointer; border: 1px solid var(--ink); }
.months { position: relative; height: 18px; font-size: 12px; color: var(--muted); }
.months span { position: absolute; top: 2px; }
.srows { display: none; }
.board { display: grid; grid-template-columns: repeat(auto-fit, minmax(72px, 1fr)); gap: 4px; margin-top: 10px; font-size: 13px; }
.board div { background: var(--concrete); padding: 6px 8px; line-height: 1.2; }
.board .n { display: block; font: 700 26px/1 var(--display); }
.board .escalated { background: #FBE3E1; }
.dash-side h2 { margin: 16px 0 6px; font-size: 20px; }
.feed { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.feed button { display: block; width: 100%; text-align: left; padding: 10px 12px; border: 2px solid var(--concrete); border-left: 8px solid var(--neutral); background: var(--paper); color: var(--ink); font: 400 15px/1.35 var(--body); cursor: pointer; }
.feed button[aria-pressed=true] { border-color: var(--ink); border-left-color: inherit; outline: 2px solid var(--ink); }
.feed .lv-high { border-left-color: var(--danger); } .feed .lv-elevated { border-left-color: var(--warning); } .feed .lv-gap { border-left-color: var(--mandatory); } .feed .lv-check { border-left-color: var(--neutral); }
.feed strong { display: inline; font-size: 16px; margin-left: 6px; }
.feed .sum, .feed .who { display: block; margin-top: 3px; } .feed .who { font-size: 13px; color: var(--muted); }
.esc { color: var(--danger); font-weight: 700; }
.chip.gap { background: var(--mandatory); color: #fff; } .chip.check { background: var(--neutral); color: #fff; }
.detail { margin-top: 14px; }
.detail .empty { background: var(--concrete); padding: 12px 14px; }
.card { border: 2px solid var(--ink); border-top: 8px solid var(--neutral); padding: 12px 16px 16px; }
.card.lv-high { border-top-color: var(--danger); } .card.lv-elevated { border-top-color: var(--warning); } .card.lv-gap { border-top-color: var(--mandatory); }
.card header h3 { display: inline; margin-left: 6px; }
.card h3 { font: 700 19px/1.2 var(--display); margin: 18px 0 6px; }
.card h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 10px 0 4px; }
.drivers { list-style: none; padding: 0; margin: 0; }
.drivers li { padding: 6px 0; border-bottom: 1px solid var(--concrete); font-size: 15px; }
.drivers li.unmet .dlabel { color: var(--muted); }
.bar { position: relative; height: 10px; background: var(--concrete); margin: 5px 0 3px; }
.bar i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--neutral); }
.bar i.met { background: var(--ink); }
.bar b { position: absolute; top: -4px; bottom: -4px; width: 3px; background: var(--danger); }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.tag { font-size: 12px; padding: 1px 6px; border: 1px solid var(--muted); color: var(--muted); }
.tag.tested { border-color: var(--ink); color: var(--ink); font-weight: 700; }
.tag.simulated { border-style: dashed; }
.holder { background: var(--concrete); padding: 8px 12px; } .holder.esc { background: #FBE3E1; color: var(--ink); font-weight: 400; }
.chain { margin: 6px 0; padding-left: 22px; font-size: 15px; }
.sts { margin-top: 8px; }
.plan { padding-left: 22px; margin: 6px 0; }
.plan li { padding: 8px 0; border-bottom: 1px solid var(--concrete); }
.plan label { display: flex; gap: 8px; align-items: flex-start; cursor: pointer; }
.plan input { margin-top: 5px; width: 18px; height: 18px; accent-color: var(--ink); flex: 0 0 auto; }
.plan input:checked + .atext { text-decoration: line-through; color: var(--muted); }
.because { display: inline-block; font-size: 13px; background: #FFF4CC; padding: 0 6px; margin: 4px 0 0 26px; }
.plan .owner, .plan .src { margin-left: 26px; }
.plan .src, .lawlist .src { font-size: 12px; color: var(--muted); display: block; }
.lawlist { padding-left: 20px; font-size: 15px; }
@media (min-width: 900px) {
  .dash { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-areas: "head head" "left side"; align-items: start; }
  .map { height: 460px; }
  .dash-side { position: sticky; top: 52px; max-height: calc(100vh - 64px); overflow-y: auto; padding-right: 4px; }
}
nav { flex-wrap: wrap; gap: 4px 14px; }
@media (min-width: 900px) { .feed button:not([aria-pressed=true]) .sum { display: none; } }

/* v4: health signal, dust, onset, hand-off (second review, 18 Nov 2026) */
:root { --signal: #6B3FA0; --dust: #7A4A1E; }
.chip.signal { background: var(--signal); color: #fff; } .chip.dust { background: var(--dust); color: #fff; }
.feed .lv-signal { border-left-color: var(--signal); } .feed .lv-dust { border-left-color: var(--dust); }
.card.lv-signal { border-top-color: var(--signal); } .card.lv-dust { border-top-color: var(--dust); }
.new { display: inline-block; margin-left: 6px; padding: 1px 6px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; background: var(--ink); color: #fff; }
.tag.pending { border-color: var(--signal); color: var(--signal); font-weight: 700; }
.legend-keys i.ring { background: transparent; border: 2px dashed var(--dust); border-radius: 50%; }
.hflag { color: var(--signal); font-weight: 700; font-size: 15px; line-height: 1; }
.send { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; margin-top: 14px; }
.send .btn { flex: 0 0 auto; padding: 8px 14px; font-size: 15px; }
.send .small { flex: 1 1 220px; }

/* v4: NASA satellite layer */
.satbar { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 8px; }
.satbar input[type=range] { width: 140px; accent-color: var(--ink); }
.satinfo img { display: block; max-width: 100%; height: auto; margin-top: 6px; background: #fff; }
.satinfo p { margin: 4px 0; max-width: none; }
.satinfo .err { color: var(--danger); }

/* v4 back-test explorer (Evidence page) */
.bty { margin-top: 10px; }
.btsum { margin-top: 12px; }
.btcal { margin-top: 8px; }
.btm { margin-top: 6px; }
.btl { font-size: 13px; color: var(--muted); display: block; }
.btr { display: grid; grid-template-columns: repeat(31, 1fr); gap: 2px; }
.btr .c { aspect-ratio: 1; min-width: 0; padding: 0; border: 0; position: relative; cursor: pointer; background: var(--concrete); }
.btr .c.h { background: var(--danger); } .btr .c.e { background: var(--warning); } .btr .c.x { background: transparent; cursor: default; }
.btr .c.ev::after { content: ""; position: absolute; inset: 22%; border-radius: 50%; background: #fff; border: 2px solid var(--ink); }
.btr .c.miss::after { background: var(--ink); }
.btr .c[aria-pressed=true] { outline: 3px solid var(--mandatory); outline-offset: 1px; z-index: 1; }
.legend-keys span { white-space: nowrap; margin-right: 8px; }
.legend-keys i.kh { background: var(--danger); } .legend-keys i.ke { background: var(--warning); } .legend-keys i.kn { background: var(--concrete); }
.legend-keys i.kev { background: #fff; border-radius: 50%; border: 2px solid var(--ink); } .legend-keys i.kmiss { background: var(--ink); border-radius: 50%; }
.btday { margin-top: 10px; padding: 10px 12px; border-left: 6px solid var(--ink); background: #F6F7F6; }
.btday p { margin: 4px 0; }
tr.sel td { font-weight: 700; } tr.total td { border-top: 2px solid var(--ink); font-weight: 700; }
@media (max-width: 480px) { .btr { grid-template-columns: repeat(11, 1fr); gap: 3px; } }   /* about 30 px squares on a 390 px phone */
.btnav { margin-top: 8px; }
