*, *::before, *::after { box-sizing: border-box; }
html { font-size: 18px; -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body { margin: 0; }
[hidden] { display: none !important; }

:root {
  /* UI colors follow the Mass.gov Mayflower palette (blue #14558F, near-black #141414, gray #535353, light gray #F2F2F2). */
  --bg: #FFFFFF; --surface: #FFFFFF; --tint: #EDF3F9; --ink: #141414; --muted: #535353; --line: #CCD5DF; --page: #F2F2F2;
  --brand: #14558F; --brand-dark: #0C3963; --accent: #F6C51B;
  --gap: #A9441A; --gap-soft: #FDEBDD; --ai: #14558F; --ai-soft: #DCE8F4; --ok: #1F6E43; --ok-soft: #E4F4EB; --neutral-soft: #EEF0F2;
  --focus: #0B57D0;
  --c-cap: #A9441A; --c-use: #2C7A4E; --c-ads: #1D5C96;
  --f-ui: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --f-display: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --r: 0px; --r-sm: 0px;
  color-scheme: light;
}

body { background: var(--bg); color: var(--ink); font-family: var(--f-ui); font-size: 1rem; line-height: 1.6; }
a { color: var(--ai); text-underline-offset: 3px; }
h1, h2, h3, h4, p, ul, ol, dl, dd { margin: 0; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
[tabindex="-1"]:focus { outline: none; }  /* headings and main take focus from code on page change; they are not controls */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); color: var(--ink); padding: 10px 14px; border: 2px solid var(--ink); z-index: 10; }
.skip:focus { left: 8px; }

.wrap { max-width: 60rem; margin-inline: auto; padding-block: 28px 64px; padding-left: max(18px, env(safe-area-inset-left, 0px)); padding-right: max(18px, env(safe-area-inset-right, 0px)); display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
header.top { display: grid; gap: 20px; }
.brand h1 { font-family: var(--f-display); font-weight: 700; font-size: 2.4rem; line-height: 1.1; }
.brand p { margin-top: 8px; font-size: 1.15rem; max-width: 40ch; }
nav.tabs { display: flex; flex-wrap: wrap; gap: 6px 22px; }
nav.tabs a { text-decoration: none; color: var(--ink); font-weight: 600; padding: 8px 0 6px; min-height: 44px; border-bottom: 4px solid transparent; }
nav.tabs a:hover { border-bottom-color: var(--line); }
nav.tabs a[aria-current="page"] { border-bottom-color: var(--ai); color: var(--ai); }
.geobox { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.notice { margin-bottom: 20px; background: var(--ai-soft); border-left: 6px solid var(--ai); padding: 12px 16px; }
.foot { color: var(--muted); font-size: .95rem; max-width: 62ch; }
footer.foot { border-top: 2px solid var(--line); padding-top: 18px; max-width: none; }

.btn, .seg, .chip, .status button { font: 600 1rem var(--f-ui); color: var(--ink); background: var(--surface); border: 2px solid var(--ink); border-radius: var(--r-sm); padding: 8px 16px; min-height: 48px; cursor: pointer; }
.btn:hover, .seg:hover, .chip:hover, .status button:hover { background: var(--tint); }
.seg[aria-pressed="true"], .chip[aria-pressed="true"] { background: var(--ai); border-color: var(--ai); color: #fff; }
.segs { display: flex; flex-wrap: wrap; gap: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chip { font-weight: 500; display: inline-flex; gap: 8px; align-items: center; padding: 6px 14px; min-height: 44px; border-color: var(--line); }
.chip:hover { border-color: var(--ink); }
.chip small { color: inherit; opacity: .8; }
.lbl { color: var(--muted); font-weight: 600; margin-right: 4px; }

.find { display: grid; gap: 12px; background: var(--tint); padding: 24px; border-radius: var(--r); }
.find > label { font-weight: 700; font-size: 1.35rem; font-family: var(--f-display); }
.combo { position: relative; }
#q { width: 100%; font: 500 1.2rem var(--f-ui); padding: 14px 16px; min-height: 58px; border: 2px solid var(--ink); border-radius: var(--r-sm); background: var(--surface); color: var(--ink); }
#results { position: absolute; top: 100%; left: 0; right: 0; z-index: 5; margin: 4px 0 0; padding: 4px; list-style: none; background: var(--surface); border: 2px solid var(--ink); border-radius: var(--r-sm); box-shadow: 0 8px 24px rgba(22,33,58,.18); max-height: 22rem; overflow: auto; }
#results li { padding: 12px; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; }
#results li[aria-selected="true"], #results li:hover { background: var(--ai-soft); }
#results small { color: var(--muted); font-size: .9rem; }

.viewhead { display: grid; gap: 8px; }
.viewhead h2, .occhead h2 { font-family: var(--f-display); font-weight: 700; font-size: 2.1rem; line-height: 1.15; text-wrap: balance; }
.lede { font-size: 1.15rem; max-width: 46ch; }
.jobview, .boardview, .aboutview { display: grid; gap: 32px; }
.grid { display: grid; gap: 24px; }
.panel { background: var(--surface); border: 2px solid var(--line); border-radius: var(--r); padding: 28px; display: grid; gap: 20px; align-content: start; min-width: 0; }
.panel h3 { font-family: var(--f-display); font-size: 1.5rem; line-height: 1.2; }
h4 { font-size: 1.05rem; font-weight: 700; margin-bottom: 6px; }
.empty { color: var(--muted); }
.status { display: grid; place-items: center; gap: 12px; padding: 48px 16px; color: var(--muted); text-align: center; }
.status.err { color: var(--gap); }
.spinner { width: 32px; height: 32px; border-radius: 50%; border: 4px solid var(--line); border-top-color: var(--ai); }
@media (prefers-reduced-motion: no-preference) { .spinner { animation: spin .8s linear infinite; } @keyframes spin { to { transform: rotate(360deg); } } }

details.more { border: 2px solid var(--line); border-radius: var(--r); }
details.more > summary { cursor: pointer; font-weight: 700; padding: 16px 20px; min-height: 52px; list-style: none; display: flex; justify-content: space-between; gap: 12px; align-items: center; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary::after { content: "+"; font-size: 1.6rem; line-height: 1; color: var(--ai); }
details.more[open] > summary::after { content: "−"; }
details.more > summary:hover { background: var(--tint); }
details.more > .morebody { padding: 8px 20px 24px; display: grid; gap: 24px; }

.occhead { display: grid; gap: 16px; }
.occhead .grp { color: var(--muted); font-weight: 600; }
dl.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 20px 28px; }
.fact { display: grid; gap: 2px; align-content: start; }
.fact dt { color: var(--muted); font-weight: 600; }
.fact .fv { display: block; font-family: var(--f-display); font-size: 1.7rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.fact small { display: block; color: var(--muted); font-size: .95rem; }
.fact.text .fv { font-family: var(--f-ui); font-size: 1.1rem; font-weight: 700; line-height: 1.35; }

.rulers { list-style: none; padding: 0; display: grid; gap: 28px; }
.ruler { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.rl { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.rl b { font-size: 1.1rem; }
.rl .src { color: var(--muted); font-size: .95rem; }
.rtrack { position: relative; height: 24px; margin-inline: 10px; }
.rtrack::before { content: ""; position: absolute; left: -10px; right: -10px; top: 8px; height: 8px; background: var(--line); }
.rtick { position: absolute; top: 2px; width: 2px; height: 20px; margin-left: -1px; background: var(--muted); }
.rtick.ref { top: -6px; height: 28px; background: var(--ink); }
.rticks, .rref { position: relative; height: 1.4em; margin-inline: 10px; color: var(--muted); font-size: .95rem; font-variant-numeric: tabular-nums; }
.rref { color: var(--ink); margin-bottom: -4px; }
.rticks span, .rref span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.rticks span:first-child { transform: translateX(-10px); }
.rticks span:last-child { transform: translateX(calc(-100% + 10px)); }
.rv { display: grid; line-height: 1.35; }
.rv b { font-size: 1.1rem; }
.rv small { color: var(--muted); font-size: .95rem; }
.mk { display: inline-block; width: 14px; height: 14px; background: var(--c); flex: none; }
.mk.cap { --c: var(--c-cap); } .mk.use { --c: var(--c-use); } .mk.ads { --c: var(--c-ads); }
.mk.circle { border-radius: 50%; }
.mk.diamond { clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); width: 17px; height: 17px; }
.mk.dotm { position: absolute; top: 0; width: 24px; height: 24px; transform: translateX(-50%); box-shadow: 0 0 0 3px var(--surface); }
.mk.dotm.diamond { width: 28px; height: 28px; top: -2px; box-shadow: none; }

.srow { display: grid; grid-template-columns: minmax(0, 1fr) 4rem; gap: 14px; align-items: center; }
.stat { display: grid; gap: 2px; align-content: start; }
.stat .k { color: var(--muted); font-weight: 600; }
.stat .v { font-family: var(--f-display); font-size: 1.8rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.15; }
.stat .n { color: var(--muted); font-size: .95rem; }

.spark svg { width: 100%; height: auto; display: block; overflow: visible; }
svg text { fill: var(--muted); font: 14px var(--f-ui); }
svg .endlabel { fill: var(--ink); font-weight: 700; font-size: 15px; }
svg .grid { stroke: var(--line); stroke-width: 1; }
svg .guide { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 2 3; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 22px; color: var(--ink); margin-bottom: 8px; }
.key::before { content: ""; display: inline-block; width: 24px; border-top: 3px solid var(--c); margin-right: 8px; vertical-align: middle; }
.key.dashed::before { border-top-style: dashed; }

.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr)); gap: 24px; }
.twocol { background: var(--tint); padding: 20px 22px; border-radius: var(--r); align-content: start; }
.alist { list-style: none; padding: 0; display: grid; margin-top: 8px; }
.alist li { padding: 10px 0; border-top: 1px solid var(--line); font-size: 1.05rem; }
.alist li:first-child { border-top: 0; }
.block { display: grid; gap: 16px; padding-top: 24px; border-top: 2px solid var(--line); }
.block h3 { font-family: var(--f-display); font-size: 1.35rem; }
.moves { list-style: none; padding: 0; display: grid; gap: 14px; }
.move { display: grid; gap: 10px; padding: 18px 20px; border: 2px solid var(--line); border-radius: var(--r); align-content: start; }
.move .t { font-weight: 700; font-size: 1.2rem; color: var(--ai); }
.move .row { display: flex; flex-wrap: wrap; gap: 4px 22px; color: var(--muted); font-variant-numeric: tabular-nums; align-items: center; }
.move .row b { color: var(--ink); font-weight: 700; }
.up { color: var(--ok) !important; }
.loose { color: var(--gap); font-weight: 700; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.tag { display: inline-flex; gap: 8px; align-items: baseline; padding: 4px 10px; border-radius: var(--r-sm); background: var(--neutral-soft); color: var(--ink); font-size: .95rem; }
.tag em { font-style: normal; color: var(--muted); font-size: .85rem; font-variant-numeric: tabular-nums; }
.tag.aiTag { background: var(--ai-soft); color: var(--ai); }
.tl { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 20px; }
.tl li { border-top: 5px solid var(--ai); padding-top: 12px; display: grid; gap: 6px; align-content: start; }
.tl b { font-size: 1.1rem; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.list { list-style: none; padding: 0; display: grid; gap: 14px; }
.list li { display: grid; gap: 4px; }
.list .meta { color: var(--muted); font-size: .95rem; }
.stack { display: grid; gap: 16px; }

.srcs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.src { font-size: .85rem; font-weight: 600; line-height: 1.5; padding: 0 8px; border-radius: var(--r-sm); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.src.lc { background: var(--ai-soft); color: var(--ai); border-color: transparent; }

label { display: grid; gap: 6px; font-weight: 600; }
select, input[type="search"] { font: 500 1.05rem var(--f-ui); padding: 10px 12px; min-height: 52px; border: 2px solid var(--ink); border-radius: var(--r-sm); background: var(--surface); color: var(--ink); width: 100%; }

.tablewrap { overflow: auto; max-height: 70vh; border: 2px solid var(--line); border-radius: var(--r); background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
th, td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: left; }
th { position: sticky; top: 0; background: var(--tint); z-index: 1; }
th button { all: unset; cursor: pointer; font-weight: 700; color: var(--ink); padding: 2px 0; white-space: nowrap; }
th button:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
th .arr { display: inline-block; width: 1.1em; color: var(--ai); }
td.n, th.n { text-align: right; }
td.title { min-width: 14rem; }
tbody tr { cursor: pointer; }
tbody tr:hover { background: var(--tint); }
td .q { display: inline-block; width: 12px; height: 12px; margin-right: 10px; background: var(--muted); }
td .q.gap { background: var(--gap); } td .q.ai { background: var(--ai); }
.summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 16px; }
.panel.stat .v { font-size: 2rem; }
.boardbar { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: 18px; }

.about { gap: 32px; }
.about-sec { display: grid; gap: 12px; }
.about p, .about li { max-width: 60ch; font-size: 1.05rem; }
ul.notes { padding-left: 1.3rem; display: grid; gap: 10px; }
.topics { display: grid; gap: 8px; }

@media (max-width: 640px) {
  html { font-size: 18px; }
  .brand h1 { font-size: 2rem; }
  .panel { padding: 20px; }
  .find { padding: 18px; }
  th.opt, td.opt { display: none; }
}
@media (forced-colors: active) {
  .mk, .rtrack::before, .rtick { forced-color-adjust: none; background: CanvasText; }
  .seg[aria-pressed="true"], .chip[aria-pressed="true"], nav.tabs a[aria-current="page"] { outline: 3px solid Highlight; }
}

.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { display: inline-flex; align-items: center; padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 1rem; background: var(--ai-soft); color: var(--ink); border-left: 6px solid var(--ai); }
.pill.gap { background: var(--gap-soft); border-left-color: var(--gap); }
.pill.neutral { background: var(--line); border-left-color: var(--muted); }
.result { font-size: 1.15rem; font-weight: 600; }
.count { color: var(--muted); font-variant-numeric: tabular-nums; }
th .srcs { display: flex; margin-top: 4px; font-weight: 400; }
.blist { display: grid; gap: 10px; }
.blist ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.blist li { display: grid; gap: 4px; }
.baxis { position: relative; height: 1.4em; margin-right: 4.5em; color: var(--muted); font-size: .9rem; font-variant-numeric: tabular-nums; border-bottom: 1px solid var(--line); }
.baxis span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.baxis span:first-child { transform: none; }
.btrack { position: relative; display: block; height: 14px; margin-right: 4.5em; }
.bgrid { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--line); }
.bfill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--c-use); min-width: 2px; }
.btrack .bval { position: absolute; left: 100%; margin-left: 8px; top: -3px; font-size: .95rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.blist .bunit { color: var(--muted); font-size: .9rem; }

.qgrid { display: grid; gap: 12px; grid-template-columns: minmax(8rem, .6fr) 1fr 1fr;
  grid-template-areas: ". c1 c2" "r1 a b" "r2 c d"; align-items: stretch; }
.qcol { color: var(--muted); font-weight: 600; text-align: center; align-self: end; }
.qrow { display: grid; align-content: center; gap: 2px; }
.qrow small { color: var(--muted); font-size: .9rem; }
.qcell { height: 100%; display: grid; border: 2px solid var(--line); border-radius: var(--r); background: var(--surface); overflow: hidden; }
.qcell.gap { background: var(--gap-soft); border-color: transparent; } .qcell.ai { background: var(--ai-soft); border-color: transparent; }
.qcell.on { border-color: var(--ink); }
.qcell button { font: inherit; color: var(--ink); background: none; border: 0; cursor: pointer; text-align: center; width: 100%; }
.qmain { display: grid; gap: 4px; justify-items: center; align-content: center; padding: 20px 16px; }
.qn { font-weight: 700; letter-spacing: .02em; text-transform: uppercase; font-size: .95rem; }
.qv { font-family: var(--f-display); font-size: 2.6rem; font-weight: 700; line-height: 1.05; font-variant-numeric: tabular-nums; }
.qcell.gap .qv { color: var(--gap); } .qcell.ai .qv { color: var(--ai); }
.qf, .qsil { display: grid; gap: 2px; font-size: .95rem; font-variant-numeric: tabular-nums; }
.qsil { padding: 10px 16px 16px; font-size: .95rem; font-weight: 700; color: var(--gap) !important; border-top: 1px solid rgba(169,68,26,.25) !important; }
.qsil[aria-pressed="true"] { text-decoration: underline; }
.qmain:focus-visible, .qsil:focus-visible { outline: 3px solid var(--ink); outline-offset: -3px; }
@media (max-width: 640px) {
  .qgrid { grid-template-columns: 1fr; grid-template-areas: "r1" "a" "b" "r2" "c" "d"; }
  .qcol { display: none; }
}
.warn { margin: 0; padding: 10px 14px; border-left: 6px solid #B7791F; background: #FFF6E0; border-radius: var(--r-sm); font-size: 1rem; max-width: 60ch; }

.btn.primary { background: var(--ai); border-color: var(--ai); color: #fff; text-decoration: none; display: inline-flex; align-items: center; }
.btn.primary:hover { background: #174C7D; }
a.btn { text-decoration: none; display: inline-flex; align-items: center; }
.btn.on { background: var(--ok-soft); border-color: var(--ok); color: var(--ink); }
.viewhead.row { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; justify-content: space-between; }
.summary.four .stat { background: var(--tint); border-radius: var(--r); padding: 16px 18px; }
.newtag { font-size: .72rem; font-weight: 700; padding: 0 6px; border-radius: 3px; background: #FFF1C9; color: #6B4A00; margin-left: 6px; white-space: nowrap; }
.formmsg { color: var(--gap); font-weight: 600; min-height: 1.2em; }
.fine { color: var(--muted); font-size: .9rem; }
.lede { font-size: 1.15rem; color: var(--muted); }

.in { max-width: 66rem; margin-inline: auto; padding-inline: max(18px, env(safe-area-inset-left, 0px)); }
.wrap { max-width: 66rem; padding-block: 28px 64px; }
.govbar { background: var(--page); color: var(--muted); font-size: .82rem; border-bottom: 1px solid var(--line); }
.govbar .in { padding-block: 6px; }
.masthead { background: #fff; border-bottom: 4px solid var(--brand); }
.mastrow { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; justify-content: space-between; padding-block: 18px; }
.brand { display: flex; gap: 14px; align-items: center; color: var(--brand); text-decoration: none; }
.brand .mark { width: 46px; height: 46px; flex: none; }
.brand .word { display: grid; line-height: 1.15; }
.brand .word b { font-size: 1.7rem; font-weight: 700; color: var(--ink); letter-spacing: -.01em; }
.mastctl { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; }
.masthead nav.tabs { max-width: 66rem; margin-inline: auto; padding-inline: max(18px, env(safe-area-inset-left, 0px)); gap: 0 4px; }
.masthead nav.tabs a { padding: 12px 14px 10px; border-bottom: 4px solid transparent; margin-bottom: -4px; color: var(--ink); }
.masthead nav.tabs a:first-child { margin-left: -14px; }
.masthead nav.tabs a:hover { background: var(--tint); border-bottom-color: var(--line); }
.masthead nav.tabs a[aria-current="page"] { color: var(--brand); border-bottom-color: var(--accent); background: none; }
.sitefoot { background: var(--brand-dark); color: #E6EEF6; font-size: .92rem; }
.sitefoot .in { display: grid; gap: 10px; padding-block: 32px 40px; max-width: 66rem; }
.sitefoot a { color: #fff; }
.sitefoot p { max-width: 80ch; }
.panel { border-width: 1px; border-color: var(--line); }
.panel h3, .viewhead h2, .occhead h2 { letter-spacing: -.01em; }
.viewhead h2, .occhead h2 { font-size: 2rem; }
.btn, .seg, .chip { border-width: 2px; }
.seg[aria-pressed="true"], .chip[aria-pressed="true"], .btn.primary { background: var(--brand); border-color: var(--brand); }
.find { background: var(--tint); border-left: 6px solid var(--brand); }
.pill { border-radius: 0; }
@media (max-width: 640px) {
  .brand .word b { font-size: 1.35rem; }
  .masthead nav.tabs { padding-inline: max(4px, env(safe-area-inset-left, 0px)); row-gap: 4px; }
  .masthead nav.tabs a:first-child { margin-left: 0; }
}

.overview { display: grid; gap: 40px; }
.hero { display: grid; gap: 18px; padding: 40px 36px; background: var(--brand); color: #fff; }
.hero h2 { font-size: 2.6rem; line-height: 1.12; font-weight: 700; letter-spacing: -.015em; max-width: 20ch; }
.herolede { font-size: 1.25rem; max-width: 52ch; color: #E6EEF6; }
.hero .btn { border-color: #fff; }
.hero .btn.primary { background: #fff; color: var(--brand); border-color: #fff; }
.hero .btn:not(.primary) { background: transparent; color: #fff; }
.hero .btn:not(.primary):hover { background: rgba(255,255,255,.12); }
.band { display: grid; gap: 20px; padding: 32px 36px; background: var(--page); border-top: 4px solid var(--accent); }
.band.light { background: var(--tint); border-top-color: var(--brand); }
.band h2, .sech { font-size: 1.6rem; font-weight: 700; letter-spacing: -.01em; }
.bandtext { font-size: 1.12rem; max-width: 64ch; }
.steps { list-style: none; padding: 0; margin: 16px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 16px; }
.step { display: grid; gap: 10px; align-content: start; padding: 20px; border: 1px solid var(--line); border-top: 4px solid var(--brand); }
.step .num { width: 36px; height: 36px; display: grid; place-items: center; background: var(--brand); color: #fff; font-weight: 700; }
.step h3 { font-size: 1.15rem; }
.step p { color: var(--muted); }
.ticks { list-style: none; padding: 0; display: grid; gap: 10px; }
.ticks li { padding-left: 28px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.pilotgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 16px; }
.pilotgrid dt { font-weight: 700; color: var(--brand); text-transform: uppercase; font-size: .82rem; letter-spacing: .05em; }
.pilotgrid dd { margin: 4px 0 0; }

.act { border-left: 6px solid #8A2E0E; }
@media (max-width: 640px) { .hero, .band { padding: 26px 20px; } .hero h2 { font-size: 2rem; } }
.mastctl .seg { min-height: 38px; padding: 4px 12px; font-size: .9rem; }

.surveyview, .resultsview { display: grid; gap: 24px; }
.jobcards { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 16px; }
.jobcard { display: grid; gap: 10px; align-content: start; padding: 20px; border: 1px solid var(--line); border-top: 4px solid var(--brand); background: #fff; }
.jobcard h3 { font-size: 1.2rem; }
.survey { gap: 26px; }
.q { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; min-width: 0; }
.q legend { font-weight: 700; font-size: 1.1rem; margin-bottom: 8px; display: flex; gap: 10px; align-items: baseline; }
.qn { display: inline-grid; place-items: center; width: 28px; height: 28px; background: var(--brand); color: #fff; font-size: .9rem; flex: none; }
.opts { display: grid; gap: 8px; }
.opts label, .sel { display: flex; gap: 10px; align-items: center; font-weight: 500; min-height: 40px; }
.opts input { width: 20px; height: 20px; flex: none; }
.sel select { font: 500 1rem var(--f-ui); padding: 10px 12px; min-height: 48px; border: 2px solid var(--ink); background: #fff; color: var(--ink); min-width: 16rem; }
.qtable { border-collapse: collapse; width: 100%; font-size: .95rem; }
.qtable th, .qtable td { border-bottom: 1px solid var(--line); padding: 10px 8px; text-align: center; vertical-align: middle; }
.qtable thead th { font-weight: 600; color: var(--muted); font-size: .85rem; vertical-align: bottom; }
.qtable tbody th { text-align: left; font-weight: 600; }
.qtable input { width: 20px; height: 20px; }
.qtable tr.newrow { background: #FFFBEA; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--brand); text-decoration: underline; font: inherit; cursor: pointer; }
.stat .n { color: var(--muted); font-size: .85rem; }
.finding { display: grid; grid-template-columns: auto 1fr; gap: 8px 24px; align-items: center; background: #fff; border: 1px solid var(--line); padding: 22px 24px; }
.finding .v { font-size: 3rem; font-weight: 700; color: var(--brand); line-height: 1; font-variant-numeric: tabular-nums; }
.finding b { font-size: 1.12rem; }
.finding .fig { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.srclink { display: inline-block; text-decoration: none; }
.srclink:hover .src { border-color: currentColor; }
@media (max-width: 640px) { .finding { grid-template-columns: 1fr; } }
.res { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.reshead { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: baseline; }
.resbars { display: grid; gap: 3px; margin-top: 6px; }
.srow { display: flex; align-items: center; }
.strack { position: relative; flex: 1; height: 14px; background: var(--neutral-soft); }
.sfill { position: absolute; left: 0; top: 0; bottom: 0; }
.sfill.do { background: #B9CDE3; } .sfill.often { background: #1F6E43; } .sfill.some { background: #8CC5A3; } .sfill.need { background: #A9441A; }
.stick { position: absolute; top: -3px; bottom: -3px; width: 3px; margin-left: -1px; background: var(--ink); }
.sval { width: 3.6em; padding-left: 8px; font-size: .9rem; font-variant-numeric: tabular-nums; }
.legend.sq { gap: 6px 18px; font-size: .92rem; }
.legend.sq span::before { content: ""; display: inline-block; width: 14px; height: 14px; background: var(--c); margin-right: 6px; vertical-align: -2px; }
.legend.sq span.tk::before { width: 3px; height: 16px; background: var(--ink); }
.ticks.plain li::before { content: "→"; color: var(--brand); }
.act { border-left: 6px solid var(--brand); }
.resultsview .boardbar { grid-template-columns: 1fr; }
.resultsview .boardbar .segs { margin-top: 6px; }
.resultsview .boardbar label select { max-width: 22rem; }
.saxis { position: relative; height: 1.4em; margin-right: 3.6em; color: var(--muted); font-size: .82rem; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.saxis span { position: absolute; transform: translateX(-50%); }
.saxis span:first-child { transform: none; }
.saxis span:last-child { transform: translateX(-100%); }
@media (max-width: 640px) {
  .qtable thead { display: none; }
  .qtable, .qtable tbody, .qtable tr, .qtable th, .qtable td { display: block; width: 100%; }
  .qtable tr { border: 1px solid var(--line); margin-bottom: 10px; padding: 8px 12px; }
  .qtable tbody th { border: 0; padding: 4px 0 6px; position: static; background: none; }
  .qtable td { border: 0; padding: 4px 0; text-align: left; display: flex; gap: 10px; align-items: center; }
  .qtable td::after { content: attr(data-label); order: 2; }
  .qtable td input { order: 1; }
}
.qtable tbody th { position: static; background: none; }
.survey .tablewrap { max-height: none; overflow: visible; border: 0; }
