/* SLU Services design system, following DESIGN_2.md ("Ramp"):
   bone canvas, white hairline cards with no shadows, ink type at weight 400, one highlighter accent
   for primary actions, live counters and active states. Radii: 6 buttons/tags, 10 inputs, 12 wash, 16 cards. */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bone: #f4f2f0;
  --wash: #ebe8e4;
  --white: #ffffff;
  --ink: #0c0a08;
  --ash: #6d6c6b;
  --obsidian: #1a1919;
  --hl: #e4f222;
  --hl-press: #d3e010;
  --smoke: #d3d3d3;
  --line: #e5e7eb;
  --err: #a8200d;
  --err-wash: #fbebe8;
  --r-btn: 6px;
  --r-input: 10px;
  --r-wash: 12px;
  --r-card: 16px;
  --max: 1200px;
  --gutter: 24px;
  --nav-h: 64px;
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0;
  background: var(--bone);
  color: var(--ink);
  font: 400 16px/1.5 var(--font);
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1 0 auto; }
h1, h2, h3, h4 { font-weight: 400; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: 40px; line-height: 1.05; letter-spacing: -0.025em; }
h2 { font-size: 24px; line-height: 1.17; letter-spacing: -0.015em; }
h3 { font-size: 20px; line-height: 1.3; }
p { margin: 0 0 12px; }
p:last-child { margin-bottom: 0; }
strong, b { font-weight: 500; }
small { font-size: 13px; }
a { color: inherit; text-decoration: underline; text-decoration-color: var(--smoke); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
img { max-width: 100%; display: block; }
code, pre, .key { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 14px; }
code { background: var(--wash); padding: 1px 6px; border-radius: var(--r-btn); word-break: break-word; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
::selection { background: var(--hl); color: var(--ink); }

.i { width: 20px; height: 20px; flex-shrink: 0; vertical-align: middle; }
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--hl); color: var(--ink); padding: 10px 16px; border-radius: var(--r-btn); text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- type helpers ---------- */
.micro { display: block; font-size: 10px; line-height: 1.4; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ash); margin: 0 0 8px; }
.display { font-size: 64px; line-height: 1; letter-spacing: -0.035em; }
.h-lg { font-size: 40px; line-height: 1.05; letter-spacing: -0.025em; margin-bottom: 16px; }
.lede { font-size: 20px; line-height: 1.3; color: var(--ash); max-width: 720px; margin: 12px 0 0; }
.muted { color: var(--ash); }
.small { font-size: 14px; }
.hint { font-size: 14px; color: var(--ash); margin: 0; }
.link { font-size: 14px; color: var(--ash); text-decoration: none; }
.link:hover { color: var(--ink); }
small.muted, td small, .rows small { display: block; }
.pre { white-space: pre-wrap; word-break: break-word; }
.prose, .prose-sm { max-width: 720px; }
.prose-sm { font-size: 15px; white-space: pre-wrap; }
.prose h2 { margin: 32px 0 12px; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 20px; }
.prose li { margin-bottom: 6px; }

/* ---------- announcement bar + nav ---------- */
.announce { background: var(--obsidian); color: var(--white); font-size: 13px; line-height: 1.4; }
.announce .wrap { padding-top: 10px; padding-bottom: 10px; }
.announce a { color: var(--hl); text-decoration-color: var(--hl); }

.topnav { position: sticky; top: 0; z-index: 40; background: var(--white); border-bottom: 1px solid var(--line); }
.nav-row { display: flex; align-items: center; gap: 24px; height: var(--nav-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-size: 18px; letter-spacing: -0.01em; white-space: nowrap; }
.brand .mark { width: 28px; height: 28px; }
.brand.big { font-size: 24px; margin-bottom: 24px; }
.brand.big .mark { width: 40px; height: 40px; }
.nav-links { display: flex; gap: 4px; margin-right: auto; }
.nav-links a { padding: 8px 12px; border-radius: var(--r-btn); color: var(--ash); text-decoration: none; font-size: 15px; white-space: nowrap; }
.nav-links a:hover { color: var(--ink); background: var(--bone); }
.nav-links a.on { color: var(--ink); background: var(--hl); }
.nav-right { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-links + .nav-right { margin-left: 0; }
.icon-btn { position: relative; display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-btn); color: var(--ink); text-decoration: none; }
.icon-btn:hover { background: var(--bone); }
.bell .dot { position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--r-btn); background: var(--hl); color: var(--ink); font-size: 11px; line-height: 18px; text-align: center; border: 1px solid var(--ink); }

.menu { position: relative; }
.menu > summary { list-style: none; cursor: pointer; }
.menu > summary::-webkit-details-marker { display: none; }
.avatar-btn { display: inline-flex; border-radius: var(--r-input); padding: 2px; }
.avatar-btn:hover { background: var(--bone); }
.avatar { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-input); background: var(--ink); color: var(--white); font-size: 13px; letter-spacing: 0.02em; }
.menu-pop { position: absolute; right: 0; top: calc(100% + 8px); width: 260px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-wash); padding: 6px; z-index: 50; }
.menu-head { padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-head strong, .menu-head span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu-head span { font-size: 13px; color: var(--ash); }
.menu-head .micro { margin: 6px 0 0; }
.menu-pop a, .menu-pop button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: var(--r-btn); border: 0; background: none; font: inherit; font-size: 15px; color: var(--ink); text-decoration: none; cursor: pointer; text-align: left; }
.menu-pop a:hover, .menu-pop button:hover { background: var(--bone); }
.menu-pop .i { width: 18px; height: 18px; color: var(--ash); }

/* console sub navigation: dark band */
.subnav { background: var(--obsidian); color: var(--white); }
.subnav .wrap { display: flex; align-items: center; gap: 20px; min-height: 52px; }
.subnav .micro { color: var(--smoke); margin: 0; white-space: nowrap; }
.subnav-tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; padding: 8px 0; }
.subnav-tabs::-webkit-scrollbar { display: none; }
.subnav-tabs a { padding: 7px 12px; border-radius: var(--r-btn); color: var(--smoke); text-decoration: none; font-size: 14px; white-space: nowrap; }
.subnav-tabs a:hover { color: var(--white); background: rgba(255, 255, 255, 0.08); }
.subnav-tabs a.on { background: var(--hl); color: var(--ink); }

.crumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding-top: 24px; font-size: 14px; color: var(--ash); }
.crumbs a { color: var(--ash); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.crumbs > span:last-child { color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }

/* ---------- page structure ---------- */
.app-main { padding-bottom: 72px; }
.public-main { padding-bottom: 0; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; padding: 40px 0 28px; flex-wrap: wrap; }
.page-head > div:first-child { min-width: 0; flex: 1 1 480px; }
.page-head h1 { overflow-wrap: anywhere; }
.head-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.head-actions form { margin: 0; }
.section { margin-top: 48px; }
.section-head, .card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.card-head h2, .section-head h2 { font-size: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 24px 0; }
.grid-side { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.grid-side > div { min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.side form { margin: 0; }
.cols3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.row form { margin: 0; }
.narrow { max-width: 560px; }
.setup { padding: 48px var(--gutter) 72px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: var(--r-btn); border: 1px solid transparent;
  background: transparent; color: var(--ink); font: inherit; font-size: 15px; line-height: 1;
  text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color .12s, color .12s, border-color .12s;
}
.btn .i { width: 18px; height: 18px; }
.btn.primary { background: var(--hl); border-color: var(--hl); }
.btn.primary:hover { background: var(--hl-press); border-color: var(--hl-press); }
.btn.outline { border-color: var(--ink); }
.btn.outline:hover { background: var(--ink); color: var(--white); }
.btn.outline.on { background: var(--hl); border-color: var(--ink); }
.btn.outline.on:hover { background: var(--hl-press); color: var(--ink); }
.btn.ghost:hover { background: var(--bone); }
.card .btn.ghost:hover, .menu-pop .btn.ghost:hover { background: var(--bone); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 14px; }
.btn.block { width: 100%; }
.btn.danger { color: var(--err); }
.btn.danger:hover { background: var(--err-wash); color: var(--err); }
.btn.outline.danger { border-color: var(--err); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
form > .btn.primary:only-of-type, .form > .btn { align-self: flex-start; }
.form > .btn.block { align-self: stretch; }

/* ---------- cards ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); padding: 24px; min-width: 0; }
.card > h2 { font-size: 20px; line-height: 1.3; margin-bottom: 16px; }
.card > h2:not(:first-child) { margin-top: 24px; }
.card.flush { padding: 0; overflow-x: auto; }
.card.flush > .muted.pad, .pad { padding: 24px; }
.wash { background: var(--wash); border-radius: var(--r-wash); padding: 16px 20px; }
.card .wash { background: var(--bone); }

.callout { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px 24px; margin: 24px 0; }
.callout > div { flex: 1 1 320px; min-width: 0; }
.callout strong { font-size: 18px; }
.callout p { color: var(--ash); margin: 4px 0 0; }
.callout form { margin: 0; }
.callout.hot { background: var(--hl); border-color: var(--hl); }
.callout.hot p { color: var(--ink); }
.callout.dark { background: var(--obsidian); border-color: var(--obsidian); color: var(--white); }
.callout.dark p { color: var(--smoke); }
.notice { margin-bottom: 12px; }
.notice.new { border-color: var(--ink); }

.empty { background: var(--white); border: 1px dashed var(--smoke); border-radius: var(--r-card); padding: 40px 24px; text-align: center; color: var(--ash); }
.empty > div { margin-top: 16px; }
.empty.small { padding: 24px 12px; font-size: 14px; border-radius: var(--r-wash); }

/* ---------- tags ---------- */
.tag { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 8px; border-radius: var(--r-btn); background: var(--white); border: 1px solid var(--line); color: var(--ink); font-size: 13px; font-style: normal; white-space: nowrap; text-decoration: none; vertical-align: middle; }
.card .tag, .svc-card .tag, .shot-card .tag, .wash .tag { background: var(--bone); border-color: transparent; }
.tag .i { width: 14px; height: 14px; }
.tag.hot, .card .tag.hot, .svc-card .tag.hot, .shot-card .tag.hot { background: var(--hl); border-color: var(--hl); }
.tag.ok, .card .tag.ok, .svc-card .tag.ok { background: var(--white); border-color: var(--line); }
.tag.done, .card .tag.done { background: var(--ink); border-color: var(--ink); color: var(--white); }
.tag.off, .card .tag.off { background: transparent; border-color: var(--line); color: var(--ash); }
a.tag:hover { border-color: var(--ink); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- service cards, chips, topics ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.cards.one { grid-template-columns: minmax(0, 1fr); }
.svc-card { display: flex; flex-direction: column; gap: 8px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px; text-decoration: none; color: var(--ink); min-width: 0; transition: border-color .12s; }
.svc-card:hover { border-color: var(--ink); }
.svc-card .micro { margin: 0; }
.svc-card strong { font-weight: 400; font-size: 20px; line-height: 1.3; letter-spacing: -0.01em; }
.svc-card p { color: var(--ash); font-size: 15px; margin: 0; }
.svc-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 8px; }

.chip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.chip { display: flex; align-items: center; gap: 12px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-wash); padding: 14px 16px; text-decoration: none; color: var(--ink); font-size: 15px; min-width: 0; }
.chip:hover { border-color: var(--ink); }
.chip span { flex: 1; min-width: 0; }
.chip small { color: var(--ash); }

.topic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.topic { display: flex; flex-direction: column; gap: 8px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); padding: 24px; text-decoration: none; color: var(--ink); }
.topic:hover { border-color: var(--ink); }
.topic .i { width: 28px; height: 28px; margin-bottom: 8px; }
.topic strong { font-weight: 400; font-size: 20px; line-height: 1.3; }
.topic p { color: var(--ash); font-size: 15px; margin: 0; }
.topic .micro { margin: auto 0 0; padding-top: 8px; }

.agency-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 8px; }
.agency-list a { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-wash); padding: 14px 16px; text-decoration: none; }
.agency-list a:hover { border-color: var(--ink); }
.agency-list small { white-space: nowrap; }
.plain { list-style: none; margin: 0; padding: 0; }
.plain li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.plain li:last-child { border-bottom: 0; }

/* ---------- forms ---------- */
.form { display: flex; flex-direction: column; gap: 16px; margin: 0; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; margin: 0; border: 0; padding: 0; }
.field > span, .field > legend { font-size: 14px; color: var(--ink); padding: 0; }
.field > legend { margin-bottom: 8px; }
.field small, .field > span small { color: var(--ash); font-size: 13px; }
input, select, textarea { font: inherit; color: inherit; }
.field input:not([type=checkbox]):not([type=radio]):not([type=file]), .field select, .field textarea,
.filters input, .filters select, .inline-filter select, .request-builder input:not([type=checkbox]), .request-builder select {
  width: 100%; height: 44px; padding: 0 14px; border: 1px solid var(--smoke); border-radius: var(--r-input); background: var(--white); font-size: 16px; min-width: 0;
}
.field textarea { height: auto; min-height: 96px; padding: 12px 14px; resize: vertical; line-height: 1.5; }
.field select, .filters select, .inline-filter select, .request-builder select {
  appearance: none; -webkit-appearance: none; padding-right: 36px; cursor: pointer;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230c0a08' stroke-width='1.5'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 10px center / 18px;
}
.field select[multiple] { height: auto; padding: 8px; background-image: none; }
.field input:focus, .field select:focus, .field textarea:focus, .filters input:focus, .filters select:focus, .inline-filter select:focus, .request-builder input:focus, .request-builder select:focus { outline: 2px solid var(--ink); outline-offset: -1px; border-color: var(--ink); }
.field input[type=file] { font-size: 14px; padding: 10px; border: 1px dashed var(--smoke); border-radius: var(--r-input); background: var(--white); width: 100%; }
.field input[readonly], .field input:disabled { background: var(--bone); color: var(--ash); }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; cursor: pointer; }
.check input, .checks input, .check-grid input, .radio-card input, .table input[type=checkbox] { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--ink); flex-shrink: 0; }
.check-list { display: flex; flex-direction: column; gap: 10px; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px 16px; }
.check-grid label { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.radio-card { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--r-wash); padding: 16px; cursor: pointer; background: var(--white); }
.radio-card strong { display: block; font-weight: 400; }
.radio-card small { display: block; color: var(--ash); font-size: 14px; }
.radio-card:has(input:checked) { border-color: var(--ink); box-shadow: inset 4px 0 0 var(--hl); }
.code-input { font-size: 24px !important; letter-spacing: 0.3em; text-align: center; font-variant-numeric: tabular-nums; }
.narrow-form { max-width: 560px; }

.composite { display: flex; align-items: center; gap: 4px; background: var(--white); border: 1px solid var(--ink); border-radius: var(--r-input); padding: 4px; max-width: 560px; margin: 0; }
.composite:focus-within { outline: 2px solid var(--ink); outline-offset: 1px; }
.composite input { flex: 1; min-width: 0; border: 0; background: transparent; height: 44px; padding: 0 12px; font-size: 16px; outline: none; }
.composite .btn { height: 40px; }
.composite.big { max-width: 760px; margin-bottom: 8px; }
.composite.big input { height: 52px; font-size: 18px; }
.composite.big .btn { height: 48px; }

.filters, .inline-filter { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.filters input { flex: 1 1 200px; width: auto; }
.filters select, .inline-filter select { width: auto; min-width: 180px; max-width: 100%; height: 40px; text-overflow: ellipsis; }
.inline-filter { margin: 0; max-width: 100%; min-width: 0; }
.head-actions > * { max-width: 100%; }
select { max-width: 100%; }

.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-input); padding: 4px; margin-bottom: 16px; max-width: 100%; }
.seg a { padding: 8px 14px; border-radius: var(--r-btn); color: var(--ash); text-decoration: none; font-size: 14px; white-space: nowrap; }
.seg a:hover { color: var(--ink); background: var(--bone); }
.seg a.on { background: var(--hl); color: var(--ink); }

.dropzone { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 32px 20px; border: 1px dashed var(--smoke); border-radius: var(--r-wash); background: var(--bone); cursor: pointer; position: relative; }
.dropzone:hover, .dropzone.over { border-color: var(--ink); }
.dropzone .i { width: 28px; height: 28px; }
.dropzone span { color: var(--ash); font-size: 14px; }
.dropzone input[type=file] { margin-top: 8px; font-size: 14px; max-width: 100%; }
.tab-pane[hidden] { display: none; }
.intake-box .seg { margin-bottom: 4px; }

.uploads { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.upload { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; border: 1px dashed var(--smoke); border-radius: var(--r-wash); padding: 16px; background: var(--bone); cursor: pointer; min-width: 0; }
.upload .micro { margin: 0; }
.upload .i { width: 28px; height: 28px; }
.upload input { font-size: 13px; max-width: 100%; }
.upload[hidden] { display: none; }

.file-pick { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px; border: 1px dashed var(--smoke); border-radius: var(--r-input); cursor: pointer; font-size: 15px; color: var(--ash); max-width: 100%; }
.file-pick:hover { border-color: var(--ink); color: var(--ink); }
.file-pick input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.file-pick span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border: 1px solid var(--line); border-radius: var(--r-btn); background: var(--white); font-size: 14px; text-decoration: none; margin-top: 8px; }
.file:hover { border-color: var(--ink); }
.file .i { width: 16px; height: 16px; }
.reply { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--line); }
.reply .row { justify-content: space-between; }
.feedback { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; }
.feedback summary { cursor: pointer; font-size: 14px; color: var(--ash); }
.feedback .form { margin-top: 12px; }

/* service editor: highlight fields a draft changes */
.service-form .field.changed > span, .service-form .field.changed > legend { display: inline-flex; gap: 8px; align-items: center; }
.field.changed { border-left: 3px solid var(--hl); padding-left: 12px; }
fieldset.field.changed { padding-left: 12px; }
.was { font-size: 14px; color: var(--ash); }
.was summary { cursor: pointer; }
.was .pre { background: var(--bone); border-radius: var(--r-btn); padding: 8px 10px; margin: 6px 0 0; }
.request-builder .table th, .request-builder .table td { padding: 6px 6px 6px 0; border: 0; }
.request-builder .table { min-width: 560px; }
.request-builder { overflow-x: auto; }
.request-builder .btn { align-self: flex-start; }

/* ---------- landing ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; align-items: center; padding: 72px 0 80px; }
.hero-copy .lede { margin: 24px 0 32px; }
.hero-copy .hint { margin-top: 12px; }
.shot { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); overflow: hidden; }
.shot-bar { display: flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border-bottom: 1px solid var(--line); }
.shot-bar i { width: 10px; height: 10px; border-radius: var(--r-btn); background: var(--smoke); }
.shot-bar span { margin-left: 12px; background: var(--bone); border-radius: var(--r-btn); padding: 4px 12px; font-size: 12px; color: var(--ash); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shot-body { background: var(--bone); padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.shot-search { display: flex; align-items: center; gap: 10px; background: var(--white); border: 1px solid var(--ink); border-radius: var(--r-input); padding: 12px 14px; font-size: 15px; }
.shot-card { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-wash); padding: 16px; }
.shot-card .micro { margin: 0; }
.shot-card strong { font-weight: 400; font-size: 18px; }
.shot-card p { margin: 0; color: var(--ash); font-size: 14px; }
.shot-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.shot-steps { display: flex; gap: 4px; width: 100%; }
.shot-steps i { flex: 1; height: 4px; border-radius: var(--r-btn); background: var(--smoke); }
.shot-steps i.on { background: var(--ink); }

.ticker { background: var(--obsidian); color: var(--white); margin-inline: calc(50% - 50vw); padding: 32px 0; }
.ticker-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.ticker-row > div { border-left: 1px solid rgba(255, 255, 255, 0.14); padding-left: 20px; }
.ticker .micro { color: var(--smoke); }
.ticker strong { display: block; font-weight: 400; font-size: 48px; line-height: 1; letter-spacing: -0.03em; color: var(--hl); font-variant-numeric: tabular-nums; }

.band { padding: 72px 0; border-bottom: 1px solid var(--line); }
.band:last-child { border-bottom: 0; }
.band .cols3 .card h2 { margin: 16px 0 8px; }
.band .cols3 .card p { color: var(--ash); }
.band.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.band .lede { margin-top: 0; }
.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.checklist li { display: flex; align-items: center; gap: 12px; font-size: 18px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-wash); padding: 14px 16px; }
.checklist .i { background: var(--hl); border-radius: var(--r-btn); padding: 3px; width: 26px; height: 26px; }

/* ---------- service page ---------- */
.svc-body > section { margin-bottom: 32px; }
.svc-body > section > h2 { margin-bottom: 12px; }
.facts-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-bottom: 32px; }
.facts-row .wash p { font-size: 18px; margin: 0; }
.fees { width: 100%; border-collapse: collapse; font-size: 15px; }
.fees td { padding: 6px 0; border-bottom: 1px solid rgba(12, 10, 8, 0.08); vertical-align: top; }
.fees tr:last-child td { border-bottom: 0; }
.fees td + td { padding-left: 12px; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.c { text-align: center; }
.facts p { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 12px; font-size: 15px; overflow-wrap: anywhere; }
.facts p .i { width: 18px; height: 18px; margin-top: 2px; color: var(--ash); }
.facts .micro { margin: 16px 0 8px; display: block; }
.facts .micro:first-child { margin-top: 0; }
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.checks label { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-input); cursor: pointer; }
.checks input:checked + span { color: var(--ash); text-decoration: line-through; text-decoration-color: var(--smoke); }
.svc-body .hint { margin-bottom: 12px; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; display: flex; flex-direction: column; gap: 12px; }
.steps li { counter-increment: step; position: relative; padding: 4px 0 0 44px; min-height: 32px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: var(--r-btn); background: var(--white); border: 1px solid var(--ink); display: grid; place-items: center; font-size: 14px; }

/* ---------- requests ---------- */
.progress { list-style: none; margin: 0 0 24px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.progress span { display: block; border-top: 4px solid var(--smoke); padding-top: 8px; font-size: 14px; color: var(--ash); }
.progress li.done span { border-color: var(--ink); color: var(--ink); }
.progress li.now span { border-color: var(--hl); color: var(--ink); }
.timeline { list-style: none; margin: 16px 0 0; padding: 0 0 0 20px; border-left: 1px solid var(--line); }
.timeline li { position: relative; padding: 0 0 20px 16px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -26px; top: 6px; width: 11px; height: 11px; border-radius: var(--r-btn); background: var(--smoke); border: 2px solid var(--white); }
.timeline li.agency::before { background: var(--ink); }
.timeline li.citizen::before { background: var(--hl); border-color: var(--ink); border-width: 1px; }
.tl-head { font-size: 15px; }
.tl-head time { display: block; font-size: 13px; color: var(--ash); }
.tl-body { background: var(--bone); border-radius: var(--r-input); padding: 12px 14px; margin-top: 8px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; }
.timeline li.internal .tl-body { background: var(--white); border: 1px dashed var(--ash); }
.answers { display: grid; grid-template-columns: minmax(0, 1fr); margin: 0 0 12px; }
.answers dt { font-size: 13px; color: var(--ash); margin-top: 12px; }
.answers dt:first-child { margin-top: 0; }
.answers dd { margin: 2px 0 0; overflow-wrap: anywhere; }

/* ---------- lists and tables ---------- */
.rows { list-style: none; margin: 0; padding: 0; }
.rows li { border-bottom: 1px solid var(--line); }
.rows li:last-child { border-bottom: 0; }
.rows a { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 20px; text-decoration: none; color: var(--ink); }
.rows a > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.rows a:hover { background: var(--bone); }
.card:not(.flush) .rows a { padding: 12px 0; }
.card:not(.flush) .rows a:hover { background: none; }
.card:not(.flush) .rows a:hover strong { text-decoration: underline; }
.rows li.unread a { box-shadow: inset 4px 0 0 var(--hl); }
.rows li.unread a > span:first-child { color: var(--ink); }
.rows li:not(.unread) a > span:first-child { color: var(--ash); }
.rows .i { color: var(--ash); }

.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; font-weight: 400; font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ash); padding: 14px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tbody tr:last-child td { border-bottom: 0; }
.table td small { color: var(--ash); }
.table tr.dim td { color: var(--ash); }
.table td form { margin: 0; }
.table.plain th, .table.plain td { padding-left: 0; }
.card:not(.flush) > .table th:first-child, .card:not(.flush) > .table td:first-child { padding-left: 0; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px; text-decoration: none; color: var(--ink); }
a.stat:hover { border-color: var(--ink); }
.stat .micro { margin-bottom: 12px; }
.stat strong { font-weight: 400; font-size: 40px; line-height: 1.05; letter-spacing: -0.025em; font-variant-numeric: tabular-nums; }
.stat small { color: var(--ash); margin-top: 6px; }

.meter { display: inline-block; vertical-align: middle; width: 96px; height: 6px; border-radius: var(--r-btn); background: var(--bone); overflow: hidden; }
.meter i { display: block; height: 100%; width: var(--v, 0%); background: var(--ink); border-radius: var(--r-btn); }
.bars { list-style: none; margin: 0 0 8px; padding: 0; }
.bars li { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.bars li:has(.meter) { grid-template-columns: minmax(0, 1fr) 120px 48px; }
.bars li:last-child { border-bottom: 0; }
.bars .meter { width: 100%; }
.bars strong { font-weight: 400; text-align: right; font-variant-numeric: tabular-nums; }

.versions { list-style: none; margin: 0; padding: 0; font-size: 14px; }
.versions li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.versions li:last-child { border-bottom: 0; }
.versions small { color: var(--ash); display: block; }

/* ---------- ID ---------- */
.id-card { position: relative; max-width: 420px; background: var(--obsidian); color: var(--white); border-radius: var(--r-card); padding: 24px; display: flex; flex-direction: column; gap: 16px; overflow: hidden; }
.id-card::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 160px; height: 160px; border: 28px solid var(--hl); border-radius: var(--r-card); opacity: .9; transform: rotate(12deg); }
.id-top { display: flex; align-items: center; gap: 10px; }
.id-top .mark { width: 28px; height: 28px; }
.id-top .micro { color: var(--smoke); margin: 0; }
.id-name { font-weight: 400; font-size: 28px; line-height: 1.14; letter-spacing: -0.015em; }
.id-card dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0; font-size: 15px; position: relative; z-index: 1; }
.id-card dt { color: var(--smoke); }
.id-card dd { margin: 0; }
.id-card .tag { align-self: flex-start; position: relative; z-index: 1; }
.id-card + .hint { margin-top: 12px; }
.id-ok { display: flex; align-items: center; gap: 8px; }
.id-photos { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.id-photos figure { margin: 0; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.id-photos img { width: 100%; border-radius: var(--r-input); background: var(--bone); }
.id-photos figcaption { margin: 0; }

/* ---------- codes, keys, sources ---------- */
.key { display: inline-block; background: var(--bone); border: 1px solid var(--line); border-radius: var(--r-btn); padding: 4px 8px; word-break: break-all; }
.codes ul { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 15px; }
pre.code, pre.source { background: var(--obsidian); color: #f4f2f0; border-radius: var(--r-wash); padding: 16px; overflow-x: auto; white-space: pre; font-size: 13px; line-height: 1.55; margin: 0 0 12px; }
pre.source { background: var(--bone); color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 480px; overflow-y: auto; }

/* ---------- flash messages ---------- */
.flashes { display: flex; flex-direction: column; gap: 8px; padding-top: 16px; }
.flash { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; background: var(--white); border: 1px solid var(--line); border-left: 4px solid var(--ink); border-radius: var(--r-input); padding: 12px 12px 12px 16px; font-size: 15px; }
.flash.ok { border-left-color: var(--hl); }
.flash.warn { border-left-color: var(--ink); background: #fbfce6; }
.flash.err { border-left-color: var(--err); background: var(--err-wash); color: var(--err); }
.flash ul { margin: 0; padding-left: 18px; }
.flash-x { border: 0; background: none; cursor: pointer; padding: 2px; border-radius: var(--r-btn); color: inherit; display: inline-grid; place-items: center; }
.flash-x:hover { background: var(--bone); }
.flash-x .i { width: 16px; height: 16px; }
.auth .flash, .grid-side + .flash { margin-bottom: 16px; }

/* ---------- auth / setup ---------- */
.auth { max-width: 440px; margin: 56px auto 72px; }
.auth.wide { max-width: 640px; }
.auth h1 { margin-bottom: 4px; }
.auth .lede { margin: 0 0 24px; font-size: 18px; }
.auth .card { margin-bottom: 16px; }
.auth .hint { text-align: center; }
.setup .card { margin-top: 24px; }
.setup h1 { margin-bottom: 8px; }

/* ---------- footer + mobile tab bar ---------- */
.foot { border-top: 1px solid var(--line); background: var(--white); font-size: 14px; color: var(--ash); }
.foot-row { display: flex; justify-content: space-between; align-items: center; gap: 12px 24px; flex-wrap: wrap; padding-top: 24px; padding-bottom: 24px; }
.foot nav { display: flex; gap: 20px; flex-wrap: wrap; }
.foot a { color: var(--ash); text-decoration: none; }
.foot a:hover { color: var(--ink); }
.tabbar { display: none; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav-links a { padding: 8px 10px; }
  .hero { gap: 40px; }
  .display { font-size: 52px; }
}
@media (max-width: 900px) {
  .grid-side { grid-template-columns: minmax(0, 1fr); }
  .hero { grid-template-columns: minmax(0, 1fr); padding: 48px 0 56px; }
  .band.split { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .cols3 { grid-template-columns: minmax(0, 1fr); }
  .ticker-row { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 28px; }
}
@media (max-width: 800px) {
  :root { --gutter: 16px; --nav-h: 56px; }
  .app .nav-links, .app .nav-right > a.icon-btn:first-child { display: none; }
  .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .uploads { grid-template-columns: minmax(0, 1fr); }
  body.app { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
    background: var(--white); border-top: 1px solid var(--line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border-radius: var(--r-btn); color: var(--ash); text-decoration: none; font-size: 11px; }
  .tabbar a.on { color: var(--ink); }
  .tabbar a.on .i { background: var(--hl); border-radius: var(--r-btn); }
  .tabbar .i { width: 36px; height: 26px; padding: 3px 8px; }
  h1, .h-lg { font-size: 32px; }
  .display { font-size: 40px; line-height: 1.05; }
  .lede { font-size: 18px; }
  .page-head { padding: 28px 0 20px; }
  .ticker strong, .stat strong { font-size: 36px; }
  .band { padding: 48px 0; }
  .card { padding: 20px; }
  .callout { padding: 16px 20px; }
  .two { grid-template-columns: minmax(0, 1fr); }
  .codes ul { grid-template-columns: minmax(0, 1fr); }
  .head-actions { width: 100%; }
}
@media (max-width: 520px) {
  .composite { flex-direction: column; align-items: stretch; }
  .composite .btn, .composite.big .btn { width: 100%; }
  .composite.big input { font-size: 16px; }
  .brand span { font-size: 16px; }
  .public .nav-right .btn.ghost { padding: 0 10px; }
  .public .nav-right .btn.primary { padding: 0 12px; }
  .chip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chip { flex-direction: column; align-items: flex-start; gap: 8px; }
  .agency-list { grid-template-columns: minmax(0, 1fr); }
  .table th, .table td { padding: 12px; }
  .shot-bar span { display: none; }
  .bars li:has(.meter) { grid-template-columns: minmax(0, 1fr) 72px 44px; }
}
@media (max-width: 380px) {
  .public .nav-right .btn.ghost { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .topnav, .subnav, .announce, .tabbar, .foot, .head-actions, .btn { display: none !important; }
  body { background: #fff; }
  .card { border-color: #ccc; }
}
