/* Setshaba — national identity web app.
   Botswana flag palette: sky blue #75AADB, black band, white borders.
   No inline styles anywhere (strict CSP); dynamic sizes are set via CSSOM. */

:root {
  color-scheme: light dark;
  --sky: #75aadb;
  --sky-strong: #5d97cf;
  --sky-50: #eef5fc;
  --sky-100: #dcebf8;
  --sky-200: #bcd7f0;
  --black: #0a0a0a;
  --bg: #f5f8fb;
  --surface: #ffffff;
  --surface-2: #f0f4f8;
  --surface-3: #e6edf4;
  --border: #d5dfe9;
  --border-strong: #b7c6d6;
  --text: #0f1a24;
  --text-2: #3d4d5e;
  --muted: #56677a;
  --link: #185891;
  --focus: #0b5cad;
  --primary-bg: #75aadb;
  --primary-bg-hover: #5d97cf;
  --primary-fg: #06121e;
  --good: #1b7340;
  --good-bg: #e5f4eb;
  --warn: #85560a;
  --warn-bg: #fff3d6;
  --bad: #b42318;
  --bad-bg: #fdecea;
  --info: #185891;
  --info-bg: #e8f1fb;
  --female: #c8702a;
  --male: #2f6fae;
  --chart-ink: #3c4a58;
  --shadow-sm: 0 1px 2px rgb(15 26 36 / 0.06), 0 1px 1px rgb(15 26 36 / 0.04);
  --shadow: 0 1px 3px rgb(15 26 36 / 0.06), 0 8px 24px rgb(15 26 36 / 0.07);
  --shadow-lg: 0 24px 60px rgb(15 26 36 / 0.18);
  --radius: 14px;
  --radius-sm: 10px;
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --mono: ui-monospace, 'SF Mono', 'Cascadia Mono', Menlo, Consolas, monospace;
  --wrap: 1160px;
}

@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) {
    --sky-50: #13283c;
    --sky-100: #173049;
    --sky-200: #214466;
    --bg: #0a131d;
    --surface: #111e2b;
    --surface-2: #162636;
    --surface-3: #1c3043;
    --border: #243a50;
    --border-strong: #35526e;
    --text: #e8eff6;
    --text-2: #b4c4d4;
    --muted: #97abbf;
    --link: #9fcaf2;
    --focus: #9fcaf2;
    --good: #6fd49a;
    --good-bg: #10301f;
    --warn: #f3c552;
    --warn-bg: #33290c;
    --bad: #ff948a;
    --bad-bg: #3b1714;
    --info: #9fcaf2;
    --info-bg: #122a40;
    --female: #c96e2a;
    --male: #4a90d9;
    --chart-ink: #9fb3c6;
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.4);
    --shadow: 0 1px 3px rgb(0 0 0 / 0.35), 0 8px 24px rgb(0 0 0 / 0.35);
    --shadow-lg: 0 24px 60px rgb(0 0 0 / 0.55);
   color-scheme: dark;}

}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}
main { flex: 1; outline: none; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5rem; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.75rem, 1.3rem + 2vw, 2.5rem); }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 0.75rem; }
a { color: var(--link); text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
code, pre, .mono { font-family: var(--mono); font-size: 0.92em; }
img, svg { max-width: 100%; }
hr { border: 0; border-top: 1px solid var(--border); margin: 1.25rem 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
h1:focus, h2:focus { outline: none; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }
.small { font-size: 0.875rem; }
.tn { color: var(--muted); font-style: italic; margin: 0 0 0.5rem; }
h2 .tn, h3 .tn { display: block; font-size: 0.8rem; font-weight: 500; margin: 0.15rem 0 0; }
.eyebrow { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.75rem; font-weight: 700; color: var(--link); margin-bottom: 0.4rem; }
.lead { font-size: 1.075rem; color: var(--text-2); max-width: 62ch; }
.icon { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; vertical-align: -0.25em; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }
.page { padding-top: 28px; padding-bottom: 56px; }
.narrow { max-width: 560px; }
.narrow-wide { max-width: 820px; }

.skip-link { position: absolute; left: 12px; top: -48px; z-index: 100; background: var(--surface); color: var(--text); padding: 8px 14px; border-radius: 8px; box-shadow: var(--shadow); }
.skip-link:focus { top: 12px; }

/* ------------------------------------------------------------------ header */
.flag-stripe { height: 6px; background: linear-gradient(to bottom, var(--sky) 0 30%, #fff 30% 40%, var(--black) 40% 60%, #fff 60% 70%, var(--sky) 70%); }
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 30; }
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; margin-right: auto; }
.brand-mark { width: 36px; height: 36px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: 'Libre Baskerville', Georgia, 'Times New Roman', serif; font-size: 1.2rem; font-weight: 700; letter-spacing: 0; }
.brand-text small { color: var(--muted); font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase; }
.site-nav { display: flex; gap: 2px; flex-wrap: wrap; }
.site-nav a { color: var(--text-2); text-decoration: none; padding: 8px 12px; border-radius: 999px; font-weight: 550; font-size: 0.94rem; }
.site-nav a:hover { background: var(--surface-2); color: var(--text); }
.site-nav a[aria-current='page'] { background: var(--sky-100); color: var(--text); box-shadow: inset 0 0 0 1px var(--sky-200); }
.nav-toggle { display: none; }
@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; align-items: center; gap: 6px; background: var(--surface-2); color: var(--text); border: 1px solid var(--border); border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 600; cursor: pointer; }
  .site-nav { display: none; width: 100%; flex-direction: column; padding: 0 0 12px; }
  .site-nav.open { display: flex; }
  .site-nav a { border-radius: 10px; padding: 12px; }
}
.dev-banner { background: var(--warn-bg); color: var(--warn); text-align: center; font-size: 0.8rem; font-weight: 600; padding: 4px 16px; border-bottom: 1px solid var(--border); }

.site-footer { border-top: 1px solid var(--border); background: var(--surface); padding: 24px 0; font-size: 0.9rem; }
.footer-inner p { margin: 0.2rem 0; }

/* ------------------------------------------------------------------ buttons & forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 999px; font: inherit; font-weight: 650; border: 1px solid transparent; cursor: pointer; text-decoration: none; transition: background-color 0.15s, box-shadow 0.15s, transform 0.05s; text-align: center; }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: progress; }
.btn-primary { background: var(--primary-bg); color: var(--primary-fg); box-shadow: inset 0 -2px 0 rgb(0 0 0 / 0.12); }
.btn-primary:hover:not(:disabled) { background: var(--primary-bg-hover); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover:not(:disabled) { background: var(--surface-2); }
.btn-quiet { background: transparent; color: var(--link); padding-left: 10px; padding-right: 10px; }
.btn-quiet:hover:not(:disabled) { background: var(--surface-2); }
.btn-danger { background: var(--bad-bg); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 35%, transparent); }
.btn-danger:hover:not(:disabled) { background: color-mix(in srgb, var(--bad-bg) 70%, var(--bad) 12%); }
.btn-sm { min-height: 36px; padding: 6px 12px; font-size: 0.875rem; }
.btn-lg { min-height: 52px; padding: 12px 24px; font-size: 1.05rem; }
.row-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 12px; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; min-width: 0; }
.field label { font-weight: 600; font-size: 0.92rem; }
.hint { font-size: 0.82rem; color: var(--muted); margin: 0; }
input[type='text'], input[type='password'], input[type='number'], input[type='date'], input:not([type]), select, textarea {
  font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 10px 12px; min-height: 44px; width: 100%; min-width: 0;
}
textarea { resize: vertical; min-height: 80px; }
input::placeholder, textarea::placeholder { color: color-mix(in srgb, var(--muted) 85%, transparent); }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid color-mix(in srgb, var(--focus) 55%, transparent); outline-offset: 0; border-color: var(--focus); }
input[type='checkbox'], input[type='radio'] { width: 20px; height: 20px; accent-color: var(--male); margin: 0; flex: none; }
.check { display: flex; align-items: center; gap: 10px; font-weight: 550; margin: 6px 0 12px; cursor: pointer; }
.stack > * + * { margin-top: 4px; }
.stack > .btn { margin-top: 8px; }
.grid-2, .grid-3 { display: grid; gap: 0 14px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.phone .grid-2, .phone .grid-3 { grid-template-columns: 1fr 1fr; }
.inline-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.inline-form .field { flex: 1 1 220px; margin: 0; }
fieldset { border: 1px solid var(--border); border-radius: var(--radius-sm); margin: 0 0 14px; padding: 12px 14px; min-width: 0; }
fieldset.plain { border: 0; padding: 0; }
legend { font-weight: 650; font-size: 0.92rem; padding: 0 4px; }
fieldset.plain legend { padding: 0; margin-bottom: 8px; }

/* ------------------------------------------------------------------ pills, chips */
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 650; line-height: 1.6; white-space: nowrap; border: 1px solid transparent; }
.pill-good { background: var(--good-bg); color: var(--good); }
.pill-bad { background: var(--bad-bg); color: var(--bad); }
.pill-warn { background: var(--warn-bg); color: var(--warn); }
.pill-info { background: var(--info-bg); color: var(--info); }
.pill-neutral { background: var(--surface-2); color: var(--text-2); border-color: var(--border); }
.chips { display: inline-flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.chip { display: inline-block; padding: 1px 8px; border-radius: 6px; font-size: 0.78rem; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); white-space: nowrap; }
.chip-fast_track { background: var(--good-bg); color: var(--good); border-color: transparent; font-weight: 650; }
.chip-standard { background: var(--info-bg); color: var(--info); border-color: transparent; font-weight: 650; }
.chip-enhanced { background: var(--warn-bg); color: var(--warn); border-color: transparent; font-weight: 650; }
.chip-role { background: var(--sky-100); border-color: var(--sky-200); color: var(--text); }
.preset-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.chip-btn { font: inherit; font-size: 0.875rem; font-weight: 600; padding: 7px 14px; min-height: 36px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); cursor: pointer; display: inline-flex; gap: 6px; align-items: center; }
.chip-btn:hover { background: var(--surface-2); }
.chip-btn[aria-pressed='true'] { background: var(--sky-100); border-color: var(--sky); box-shadow: inset 0 0 0 1px var(--sky); }
.chip-btn .count { background: var(--surface-3); border-radius: 999px; padding: 0 7px; font-size: 0.75rem; }

/* ------------------------------------------------------------------ notices */
.notice { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm); margin: 12px 0; border: 1px solid transparent; }
.notice > .icon { margin-top: 2px; }
.notice p { margin: 0.2rem 0 0; }
.notice p + p { margin-top: 0.3rem; }
.notice ul { margin: 0.3rem 0 0; padding-left: 1.1rem; }
.notice-good { background: var(--good-bg); color: var(--text); border-color: color-mix(in srgb, var(--good) 30%, transparent); }
.notice-good > .icon { color: var(--good); }
.notice-bad { background: var(--bad-bg); color: var(--text); border-color: color-mix(in srgb, var(--bad) 30%, transparent); }
.notice-bad > .icon { color: var(--bad); }
.notice-warn { background: var(--warn-bg); color: var(--text); border-color: color-mix(in srgb, var(--warn) 30%, transparent); }
.notice-warn > .icon { color: var(--warn); }
.notice-info { background: var(--info-bg); color: var(--text); border-color: color-mix(in srgb, var(--info) 25%, transparent); }
.notice-info > .icon { color: var(--info); }
.ok-text { color: var(--good); font-weight: 600; }
.warn-text { color: var(--warn); font-weight: 600; }
.loading { display: flex; align-items: center; gap: 10px; color: var(--muted); padding: 24px 0; }
.spinner { width: 20px; height: 20px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--sky-strong); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; color: var(--muted); padding: 20px 8px; }
.empty .icon { width: 28px; height: 28px; opacity: 0.7; }
.empty p { margin: 0; }

.toasts { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
.toast { display: flex; gap: 10px; align-items: center; background: var(--text); color: var(--bg); padding: 12px 16px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 550; animation: toast-in 0.2s ease-out; transition: opacity 0.4s, transform 0.4s; }
.toast-good .icon { color: #6fd49a; }
.toast-bad .icon { color: #ff948a; }
.toast.leaving { opacity: 0; transform: translateY(8px); }
@media (min-width: 900px) { .toasts { left: auto; right: 24px; transform: none; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .toast { background: #e8eff6; color: #0a131d; }
:root:not([data-theme="light"]) .toast-good .icon { color: #1b7340; }
:root:not([data-theme="light"]) .toast-bad .icon { color: #b42318; }
 }

/* ------------------------------------------------------------------ cards, lists, tables */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-sm); margin-bottom: 18px; min-width: 0; }
.card-soft { background: var(--surface-2); box-shadow: none; }
.card > h2:first-child { margin-top: 0; }
.card h2 .icon { color: var(--link); }
.page-head { margin-bottom: 24px; }
.page-head.center { text-align: center; }
.page-head.center .lead { margin-left: auto; margin-right: auto; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; }

.kv { margin: 0 0 12px; display: grid; grid-template-columns: 1fr; }
.kv > div { display: grid; grid-template-columns: minmax(110px, 38%) 1fr; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.kv > div:last-child { border-bottom: 0; }
.kv dt { color: var(--muted); font-size: 0.875rem; }
.kv dd { margin: 0; font-weight: 550; overflow-wrap: anywhere; min-width: 0; }
.kv-tight > div { padding: 4px 0; border: 0; }
.kv-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); column-gap: 24px; }
.kv-big dd { font-size: 1.15rem; }

.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); margin: 8px 0 12px; }
.table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.table caption { text-align: left; padding: 10px 12px; color: var(--muted); font-size: 0.85rem; caption-side: top; }
.table th, .table td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: top; }
.table th { background: var(--surface-2); font-weight: 650; font-size: 0.82rem; color: var(--text-2); white-space: nowrap; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table-dense td { padding: 7px 10px; font-size: 0.85rem; }
@media (max-width: 640px) {
  .table-wrap:not(.keep) .table thead { display: none; }
  .table-wrap:not(.keep) .table, .table-wrap:not(.keep) .table tbody, .table-wrap:not(.keep) .table tr, .table-wrap:not(.keep) .table td { display: block; width: 100%; }
  .table-wrap:not(.keep) .table tr { border-bottom: 1px solid var(--border); padding: 6px 0; }
  .table-wrap:not(.keep) .table td { border: 0; padding: 4px 12px; display: grid; grid-template-columns: 38% 1fr; gap: 8px; text-align: left; }
  .table-wrap:not(.keep) .table td::before { content: attr(data-label); color: var(--muted); font-size: 0.8rem; font-weight: 600; }
  .table-wrap:not(.keep) .table td[data-label='']::before { content: none; }
  .table-wrap:not(.keep) .table td[data-label=''] { display: block; }
  .table-wrap:not(.keep) .table .num { text-align: left; }
  .table-wrap.keep .table th, .table-wrap.keep .table td { padding: 8px 10px; }
}

.mini-list, .app-list, .doc-list, .inbox, .consent-list, .queue, .clusters, .members, .grants, .cascade, .timeline { list-style: none; margin: 0; padding: 0; }
.mini-list li { padding: 8px 0; border-bottom: 1px solid var(--border); }
.mini-list li:last-child { border: 0; }
.app-list li { padding: 12px 0; border-bottom: 1px solid var(--border); }
.app-list li:last-child { border: 0; }
.app-list-top { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.ref { background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 0 6px; font-weight: 600; white-space: nowrap; }
.doc-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.doc-list li:last-child { border: 0; }
.doc-list li > div { flex: 1; min-width: 0; }
.doc-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--sky-50); color: var(--link); flex: none; }

details.explain { margin-top: 8px; background: var(--surface-2); border-radius: 10px; padding: 8px 12px; }
details.explain summary { cursor: pointer; font-size: 0.875rem; font-weight: 600; color: var(--text-2); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
details.explain ul { margin: 8px 0 4px; padding: 0; list-style: none; }
details.explain li { padding: 4px 0; font-size: 0.9rem; display: flex; gap: 8px; align-items: baseline; }
.pts { font-family: var(--mono); font-weight: 700; min-width: 3.2em; text-align: right; flex: none; }
.pts-up { color: var(--bad); }
.pts-down { color: var(--good); }
details.plain-details { border-top: 1px solid var(--border); padding-top: 10px; margin: 6px 0 4px; }
details.plain-details summary { cursor: pointer; font-weight: 600; color: var(--link); margin-bottom: 8px; }
.callout { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; margin: 12px 0; }
.payload { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 10px; font-size: 0.8rem; overflow-x: auto; margin: 8px 0; }

/* ------------------------------------------------------------------ home */
.hero { background: linear-gradient(160deg, var(--sky-100), var(--bg) 70%); border-bottom: 1px solid var(--border); overflow: hidden; }
.hero-inner { display: grid; gap: 32px; padding-top: 48px; padding-bottom: 56px; align-items: center; }
@media (min-width: 900px) { .hero-inner { grid-template-columns: 1.25fr 1fr; padding-top: 72px; padding-bottom: 80px; } }
.hero h1 { font-size: clamp(2rem, 1.4rem + 3vw, 3.3rem); letter-spacing: -0.025em; max-width: 16ch; }
.hero-tn { font-size: 1.05rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 24px; }
.hero-stats { display: flex; flex-wrap: wrap; gap: 28px; }
.hero-stat strong { display: block; font-size: 1.5rem; font-variant-numeric: tabular-nums; }
.hero-stat span { color: var(--muted); font-size: 0.875rem; }
.hero-art { display: flex; justify-content: center; perspective: 1200px; }
.omang-card-demo { transform: rotate(-4deg); max-width: 380px; box-shadow: var(--shadow-lg); }
@media (max-width: 899px) { .hero-art { display: none; } }

.tiles-section { padding-top: 36px; }
.tiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.tile { position: relative; display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 22px 22px 48px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); box-shadow: var(--shadow-sm); transition: box-shadow 0.2s, transform 0.2s, border-color 0.2s; }
.tile:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: var(--sky); }
.tile-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: var(--sky-100); color: var(--text); margin-bottom: 10px; }
.tile-icon .icon { width: 24px; height: 24px; }
.tile-title { font-size: 1.15rem; font-weight: 700; }
.tile-tn { color: var(--muted); font-style: italic; font-size: 0.875rem; }
.tile-body { color: var(--text-2); margin-top: 6px; }
.tile-go { position: absolute; right: 18px; bottom: 16px; color: var(--link); }
.tile-sky { background: linear-gradient(150deg, var(--sky) 0%, #9cc3e8 100%); border-color: transparent; color: #06121e; }
.tile-sky .tile-icon { background: rgb(255 255 255 / 0.55); }
.tile-sky .tile-tn, .tile-sky .tile-body, .tile-sky .tile-go { color: #10263b; }
.pillars { padding-top: 48px; padding-bottom: 64px; }
.pillar-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); margin-top: 16px; }
.pillar { padding: 20px; border-radius: var(--radius); background: var(--surface-2); }
.pillar-icon { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--black); color: #fff; margin-bottom: 12px; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .pillar-icon { background: var(--sky); color: #06121e; }
 }
.pillar p { color: var(--text-2); margin: 0; }

/* ------------------------------------------------------------------ Omang card */
.omang-card { position: relative; width: 100%; border-radius: 18px; overflow: hidden; color: #06121e; background: linear-gradient(135deg, #8ab9e3 0%, #75aadb 45%, #5f98cf 100%); box-shadow: var(--shadow); padding: 16px 18px 12px; isolation: isolate; }
.omang-card::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 85% 10%, rgb(255 255 255 / 0.35), transparent 45%); z-index: -1; }
.omang-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.omang-country { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; display: flex; flex-direction: column; }
.omang-country small { font-weight: 600; letter-spacing: 0.06em; text-transform: none; font-size: 0.72rem; opacity: 0.85; }
.omang-chip { width: 36px; height: 27px; border-radius: 6px; background: linear-gradient(135deg, #f3d98b, #c9a646); box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.2); }
.omang-badge { display: inline-flex; align-items: center; gap: 4px; background: #06121e; color: #fff; font-size: 0.72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.omang-band { height: 14px; margin: 12px -18px; background: linear-gradient(to bottom, #fff 0 22%, #0a0a0a 22% 78%, #fff 78%); }
.omang-body { display: flex; gap: 14px; align-items: flex-start; }
.omang-photo { width: 76px; height: 92px; border-radius: 10px; background: rgb(255 255 255 / 0.65); display: grid; place-items: center; font-size: 1.6rem; font-weight: 800; color: #1a4f80; flex: none; box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.12); }
.omang-fields { min-width: 0; flex: 1; }
.omang-label { font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.75; font-weight: 700; margin-top: 4px; }
.omang-name { font-size: 1.15rem; font-weight: 800; line-height: 1.2; }
.omang-number { font-family: var(--mono); font-size: 1.25rem; font-weight: 700; letter-spacing: 0.06em; }
.omang-row { display: flex; gap: 18px; font-weight: 650; font-size: 0.9rem; }
.omang-foot { display: flex; justify-content: space-between; align-items: center; font-size: 0.75rem; font-weight: 600; margin-top: 12px; padding-top: 8px; border-top: 1px solid rgb(0 0 0 / 0.12); gap: 8px; }
.omang-card .pill-good { background: #06121e; color: #b9f0cf; }

/* ------------------------------------------------------------------ citizen app (phone) */
.id-layout { display: grid; gap: 32px; align-items: start; grid-template-columns: minmax(0, 1fr); }
.id-layout > * { min-width: 0; }
@media (min-width: 900px) { .id-layout { grid-template-columns: minmax(0, 1fr) 400px; } .id-aside { position: sticky; top: 100px; } }
.checklist { list-style: none; padding: 0; margin: 16px 0 20px; }
.checklist li { display: flex; gap: 10px; padding: 6px 0; }
.checklist .icon { color: var(--good); margin-top: 3px; }
.demo-hint { display: flex; gap: 10px; background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--radius-sm); padding: 12px 14px; font-size: 0.92rem; }
.demo-hint p { margin: 0; }
.demo-hint .icon { color: var(--link); margin-top: 3px; }

.phone { width: 400px; max-width: 100%; height: 820px; border-radius: 52px; background: #0b0f14; padding: 14px; box-shadow: var(--shadow-lg), inset 0 0 0 2px #2a3440; display: flex; flex-direction: column; justify-self: center; }
.phone-status { display: flex; justify-content: space-between; align-items: center; color: #e8eff6; font-size: 0.8rem; font-weight: 650; padding: 4px 26px 8px; background: transparent; }
.phone-notch { width: 96px; height: 24px; border-radius: 999px; background: #000; }
.phone-screen { flex: 1; min-height: 0; border-radius: 40px; background: var(--bg); overflow: hidden; display: flex; flex-direction: column; }
@media (max-width: 899px) { .id-aside .checklist, .id-aside .lead { display: none; } .id-layout { gap: 16px; } }
@media (max-width: 600px) {
  .id-layout { padding-top: 12px; padding-left: 0; padding-right: 0; }
  .id-aside { padding: 0 16px; }
  .id-aside h1 { font-size: 1.6rem; }
  .phone { width: 100%; height: auto; min-height: 70vh; border-radius: 0; padding: 0; background: transparent; box-shadow: none; }
  .phone-status { display: none; }
  .phone-screen { border-radius: 0; overflow: visible; }
  .app-content { overflow: visible !important; }
}
.app-header { display: flex; align-items: center; gap: 10px; padding: 14px 16px 10px; background: var(--surface); border-bottom: 1px solid var(--border); }
.app-hello { display: flex; flex-direction: column; line-height: 1.15; margin-right: auto; }
.app-hello span { font-size: 0.8rem; color: var(--muted); }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--sky); color: #06121e; display: grid; place-items: center; font-weight: 800; flex: none; font-size: 0.95rem; }
.avatar-child { background: var(--sky-100); color: var(--text); }
.app-tabs { display: flex; gap: 4px; overflow-x: auto; padding: 8px 10px; background: var(--surface); border-bottom: 1px solid var(--border); scrollbar-width: none; flex: none; }
.app-tabs::-webkit-scrollbar { display: none; }
.app-tabs { mask-image: linear-gradient(to right, #000 85%, transparent); -webkit-mask-image: linear-gradient(to right, #000 85%, transparent); }
.app-tabs.at-end { mask-image: none; -webkit-mask-image: none; }
.app-tab { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; font-size: 0.84rem; font-weight: 650; color: var(--text-2); text-decoration: none; white-space: nowrap; border: 1px solid transparent; }
.app-tab:hover { background: var(--surface-2); }
.app-tab[aria-current='page'] { background: var(--black); color: #fff; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .app-tab[aria-current='page'] { background: var(--sky); color: #06121e; }
 }
.app-tab-accent:not([aria-current='page']) { border-color: var(--sky); color: var(--text); background: var(--sky-50); }
.app-content { flex: 1; overflow-y: auto; padding: 16px; overscroll-behavior: contain; }
.app-title { font-size: 1.35rem; margin: 2px 0 14px; }
.app-title .tn { font-size: 0.85rem; }
.app-pad { padding: 28px 22px; overflow-y: auto; }
.app-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin: 14px 0; box-shadow: var(--shadow-sm); }
.app-card > h3 { margin-bottom: 10px; }
.app-card .btn:not(.btn-sm) { width: 100%; }
.app-card .row-actions .btn { width: auto; flex: 1 1 auto; }
.signin h2 { font-size: 1.5rem; }
.signin-mark { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; background: var(--sky); color: #06121e; margin-bottom: 14px; }
.signin-mark .icon { width: 28px; height: 28px; }
.signin .btn { width: 100%; }
.otp-input { font-family: var(--mono); font-size: 1.4rem !important; letter-spacing: 0.3em; text-align: center; }
.dev-code { border: 2px dashed var(--warn); background: var(--warn-bg); border-radius: var(--radius-sm); padding: 12px 14px; margin: 14px 0; display: grid; gap: 6px; justify-items: start; }
.dev-code-label { font-size: 0.8rem; font-weight: 700; color: var(--warn); }
.dev-code-value { font-family: var(--mono); font-size: 1.8rem; letter-spacing: 0.25em; }
.dev-code .btn { width: auto; }

.privacy-teaser { display: flex; align-items: center; gap: 12px; padding: 14px 16px; margin: 14px 0; border-radius: var(--radius); background: var(--black); color: #fff; text-decoration: none; box-shadow: var(--shadow); }
.privacy-teaser > .icon:first-child { width: 28px; height: 28px; color: var(--sky); }
.privacy-teaser div { flex: 1; display: flex; flex-direction: column; }
.privacy-teaser .muted { color: #c5d6e6; font-size: 0.85rem; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .privacy-teaser { background: var(--sky-100); border: 1px solid var(--sky); }
 }

.claim-list { display: grid; gap: 6px; }
.claim { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; border: 1px solid var(--border); border-radius: 10px; cursor: pointer; background: var(--surface); }
.claim:has(input:checked) { border-color: var(--sky); background: var(--sky-50); }
.claim-name { font-weight: 600; font-size: 0.9rem; }
.claim-value { color: var(--muted); font-size: 0.82rem; text-align: right; overflow-wrap: anywhere; max-width: 12em; }
.presentation { display: grid; gap: 10px; margin-top: 14px; }
.qr-frame { background: #fff; border-radius: 16px; padding: 10px; border: 1px solid var(--border); display: flex; justify-content: center; }
.qr { width: 100%; max-width: 320px; height: auto; display: block; image-rendering: pixelated; }
.presentation-text { font-size: 0.72rem; word-break: break-all; min-height: 70px; }

.scanner { text-align: center; background: var(--surface-2); }
.scanner legend { text-align: left; }
.scanner legend .tn { display: inline; font-size: 0.8rem; margin-left: 6px; }
.scan-pad { position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 6px; width: 100%; max-width: 280px; padding: 16px; border-radius: 16px; border: 2px dashed var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-weight: 650; cursor: pointer; overflow: hidden; }
.scan-pad .icon { width: 44px; height: 44px; color: var(--link); stroke-width: 1.4; }
.scan-pad:hover { border-color: var(--sky); }
.scan-pad.scanning { border-style: solid; border-color: var(--sky); }
.scan-pad.scanning::after { content: ''; position: absolute; left: 0; right: 0; height: 3px; background: var(--sky); box-shadow: 0 0 12px var(--sky); animation: scanline 0.9s ease-in-out infinite alternate; top: 10%; }
@keyframes scanline { to { top: 85%; } }
.scan-pad.done { border-style: solid; border-color: var(--good); background: var(--good-bg); }
.scan-pad.done .icon { color: var(--good); }
.radio-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 16px; margin: 10px 0 4px; font-size: 0.88rem; }
.radio-row label { display: inline-flex; gap: 6px; align-items: center; cursor: pointer; }
.scan-status { font-size: 0.82rem; color: var(--muted); margin: 6px 0 0; }

.access-hero { display: flex; gap: 14px; padding: 16px; border-radius: var(--radius); background: var(--black); color: #fff; margin-bottom: 16px; }
.access-hero > .icon { width: 30px; height: 30px; color: var(--sky); margin-top: 2px; }
.access-hero strong { font-size: 1.05rem; }
.access-hero p { margin: 6px 0 0; color: #c5d6e6; font-size: 0.9rem; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .access-hero { background: var(--sky-100); border: 1px solid var(--sky); }
 }
.timeline { position: relative; }
.timeline::before { content: ''; position: absolute; left: 17px; top: 8px; bottom: 8px; width: 2px; background: var(--border); }
.tl-item { position: relative; display: flex; gap: 12px; padding-bottom: 16px; }
.tl-dot { position: relative; z-index: 1; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 2px solid var(--sky); color: var(--link); flex: none; }
.tl-officer .tl-dot { border-color: var(--black); color: var(--text); }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .tl-officer .tl-dot { border-color: var(--text-2); }
 }
.tl-body { flex: 1; min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; box-shadow: var(--shadow-sm); }
.tl-head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.tl-head time { color: var(--muted); font-size: 0.82rem; white-space: nowrap; }
.tl-kind { font-size: 0.8rem; margin-bottom: 6px; }
.tl-body .kv > div { grid-template-columns: 96px 1fr; }
.tl-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 0.8rem; margin-top: 4px; flex-wrap: wrap; }

.consent { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; margin-bottom: 10px; }
.consent-pending { border-color: var(--sky); background: var(--sky-50); }
.consent-head { display: flex; justify-content: space-between; gap: 8px; align-items: center; margin-bottom: 6px; }
.child-head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.child-head h3, .child-head h2 { margin: 0; }
.child-head p { margin: 0; }
.inbox li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.inbox li > div { flex: 1; min-width: 0; }
.inbox p { margin: 4px 0; overflow-wrap: anywhere; }
.inbox-icon { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--sky-50); color: var(--link); flex: none; }
.inbox-head { display: flex; justify-content: space-between; gap: 8px; }
.inbox-head time { color: var(--muted); font-size: 0.8rem; white-space: nowrap; }
.inbox .muted { font-size: 0.78rem; }

/* ------------------------------------------------------------------ officer console */
.console-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.officer-id { display: flex; align-items: center; gap: 12px; }
.officer-id .chips { margin-top: 2px; }
.console-grid { display: grid; gap: 24px; align-items: start; grid-template-columns: minmax(0, 1fr); }
.console-grid > * { min-width: 0; }
@media (min-width: 900px) { .console-grid { grid-template-columns: 240px minmax(0, 1fr); } .console-nav { position: sticky; top: 90px; } }
.console-nav ul { list-style: none; margin: 0; padding: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); display: flex; flex-direction: column; gap: 2px; }
.console-nav a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 10px; color: var(--text-2); text-decoration: none; font-weight: 600; font-size: 0.94rem; }
.console-nav a:hover { background: var(--surface-2); color: var(--text); }
.console-nav a[aria-current='page'] { background: var(--sky-100); color: var(--text); box-shadow: inset 3px 0 0 var(--sky-strong); }
@media (max-width: 899px) {
  .console-nav ul { flex-direction: row; overflow-x: auto; scrollbar-width: thin; padding: 6px; }
  .console-nav a { white-space: nowrap; padding: 8px 12px; }
  .console-nav a[aria-current='page'] { box-shadow: inset 0 -3px 0 var(--sky-strong); }
}
.console-content > h1 { font-size: 1.75rem; margin-bottom: 12px; }
.kpis { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); margin-bottom: 18px; }
.kpis-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }
.kpi { display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow-sm); color: var(--text); text-decoration: none; min-width: 0; }
.kpi-link:hover { border-color: var(--sky); box-shadow: var(--shadow); }
.kpi-label { color: var(--muted); font-size: 0.85rem; font-weight: 600; }
.kpi-value { font-size: 2rem; font-weight: 750; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi .muted { font-size: 0.82rem; }
.stackbar { display: flex; height: 10px; border-radius: 999px; overflow: hidden; gap: 2px; margin: 6px 0; background: var(--surface-2); }
.sbar-seg { display: block; min-width: 4px; }
.seg-fast_track { background: var(--good); }
.seg-standard { background: var(--male); }
.seg-enhanced { background: var(--female); }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 0.78rem; color: var(--text-2); }
.legend-item { display: inline-flex; align-items: center; gap: 6px; }
.swatch { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.s-female { background: var(--female); }
.s-male { background: var(--male); }
.audit-head .hash, .hash { display: block; font-size: 0.8rem; word-break: break-all; background: var(--surface-2); border-radius: 8px; padding: 8px 10px; border: 1px solid var(--border); }
.hash-short { font-size: 0.78rem; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: flex-end; justify-content: space-between; margin-bottom: 8px; }
.toolbar .field { min-width: 200px; margin: 0 0 14px; }
.queue-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.queue-item.decided { opacity: 0.75; }
.queue-top { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.queue-main { flex: 1; min-width: 180px; }
.queue-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.risk { display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 6px; border-radius: 12px; font-weight: 800; font-size: 1.05rem; font-variant-numeric: tabular-nums; border: 2px solid; flex: none; }
.risk-good { color: var(--good); background: var(--good-bg); }
.risk-warn { color: var(--warn); background: var(--warn-bg); }
.risk-bad { color: var(--bad); background: var(--bad-bg); }
.decide { display: grid; gap: 0 12px; margin-top: 10px; }
@media (min-width: 720px) { .decide { grid-template-columns: 1fr auto; align-items: end; } .decide .row-actions { margin: 0 0 14px; } }
.decide textarea { min-height: 44px; }
.result-card { border: 2px solid var(--good); background: var(--good-bg); border-radius: var(--radius); padding: 18px; margin-top: 16px; }
.result-card .kv > div { border-color: color-mix(in srgb, var(--good) 20%, transparent); }
.big-number { font-family: var(--mono); font-size: clamp(1.8rem, 1.2rem + 3vw, 2.6rem); font-weight: 800; letter-spacing: 0.08em; margin: 4px 0 12px; }
.cascade li { display: flex; gap: 8px; padding: 5px 0; }
.cascade .icon { color: var(--good); margin-top: 3px; }
.purpose-card { border-left: 4px solid var(--sky); }
.verdict { display: flex; gap: 12px; border-radius: var(--radius-sm); padding: 14px; margin-top: 12px; }
.verdict > .icon { width: 30px; height: 30px; }
.verdict p { margin: 4px 0 0; }
.verdict-good { background: var(--good-bg); }
.verdict-good > .icon { color: var(--good); }
.verdict-bad { background: var(--bad-bg); }
.verdict-bad > .icon { color: var(--bad); }
.cluster { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; margin-bottom: 10px; }
.cluster-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.member { margin-bottom: 14px; }
.member-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.member-head h2 { font-size: 1.1rem; margin: 0; }
.grants li { padding: 10px 0; border-top: 1px solid var(--border); display: grid; gap: 6px; }
.legal { font-size: 0.85rem; }
.demo-officers .preset-row { margin-bottom: 0; }

/* ------------------------------------------------------------------ verify */
.verify-grid { display: grid; gap: 20px; align-items: start; }
@media (min-width: 960px) { .verify-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.verify-grid textarea { font-size: 0.8rem; word-break: break-all; min-height: 130px; }
.keys-line { font-size: 0.82rem; margin: 12px 0 0; display: flex; gap: 6px; align-items: center; }
.video-wrap { margin-top: 12px; display: grid; gap: 8px; justify-items: start; }
.scan-video { width: 100%; max-width: 420px; border-radius: 12px; background: #000; }
.verdict-card { border-radius: var(--radius); padding: 22px; border: 2px solid; background: var(--surface); box-shadow: var(--shadow); }
.verdict-ok { border-color: var(--good); }
.verdict-fail { border-color: var(--bad); }
.verdict-head { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.verdict-head h2 { font-size: 1.6rem; margin: 0 0 4px; }
.verdict-head p { margin: 0; color: var(--text-2); }
.verdict-icon { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; flex: none; color: #fff; }
.verdict-icon .icon { width: 42px; height: 42px; stroke-width: 2.6; }
.verdict-ok .verdict-icon { background: var(--good); }
.verdict-fail .verdict-icon { background: var(--bad); }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .verdict-icon { color: #0a131d; }
 }
.disclosed { background: var(--surface-2); border-radius: var(--radius-sm); padding: 14px 16px; margin-bottom: 14px; }
.disclosed h3 { font-size: 0.95rem; color: var(--text-2); }
.disclosed p { margin: 0; font-size: 0.85rem; }
.claim-bool { display: inline-flex; gap: 6px; align-items: center; font-weight: 800; }
.claim-bool.yes { color: var(--good); }
.claim-bool.no { color: var(--bad); }
.checks li { display: flex; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--border); list-style: none; }
.checks { padding: 0; margin: 0 0 10px; }
.checks li:last-child { border: 0; }
.checks li > div { display: flex; flex-direction: column; min-width: 0; }
.checks li .muted { font-size: 0.85rem; overflow-wrap: anywhere; }
.checks li.ok > .icon { color: var(--good); }
.checks li.bad > .icon { color: var(--bad); }
.checks li.na > .icon { color: var(--muted); }

/* ------------------------------------------------------------------ charts */
.grid-charts { display: grid; gap: 18px; }
@media (min-width: 960px) { .grid-charts { grid-template-columns: 1fr 1fr; } .grid-charts .card { margin: 0; } }
.chart { margin: 0 0 12px; }
.pyramid { display: grid; gap: 6px; }
.prow { display: grid; grid-template-columns: 1fr 56px 1fr; align-items: center; gap: 8px; }
.phead { font-size: 0.8rem; color: var(--text-2); font-weight: 600; text-align: center; margin-bottom: 4px; }
.phead .legend-item:first-child { justify-self: end; }
.phead .legend-item:last-child { justify-self: start; }
.pside { display: flex; align-items: center; gap: 6px; height: 24px; }
.pside-f { justify-content: flex-end; }
.pband { text-align: center; font-size: 0.82rem; font-weight: 650; color: var(--text-2); font-variant-numeric: tabular-nums; }
.pbar { display: block; height: 100%; min-width: 3px; }
.pbar-f { background: var(--female); border-radius: 4px 0 0 4px; }
.pbar-m { background: var(--male); border-radius: 0 4px 4px 0; }
.plabel { font-size: 0.78rem; color: var(--text-2); font-variant-numeric: tabular-nums; min-width: 2ch; }
.pside-f .plabel { text-align: right; }

.cols { display: flex; align-items: stretch; gap: 4px; height: 190px; padding-top: 4px; border-bottom: 1px solid var(--border-strong); }
.col { flex: 1; display: flex; flex-direction: column; align-items: center; min-width: 0; }
.col-val { font-size: 0.72rem; color: var(--text-2); font-variant-numeric: tabular-nums; height: 18px; }
.col-track { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; }
.col-bar { display: block; width: min(100%, 26px); border-radius: 4px 4px 0 0; min-height: 3px; }
.tone-blue { background: var(--male); }
.tone-ink { background: var(--chart-ink); }
.pbar.suppressed, .col-bar.suppressed { background-image: repeating-linear-gradient(45deg, transparent 0 3px, rgb(255 255 255 / 0.65) 3px 5px); }
.col-x { font-size: 0.72rem; color: var(--muted); padding-top: 4px; transform: translateY(100%); margin-top: -2px; height: 0; }
.cols + details, .pyramid + details { margin-top: 28px; }
.pbar:focus-visible, .col-bar:focus-visible { outline-offset: 1px; }
.chart-tip { position: absolute; z-index: 80; background: var(--text); color: var(--bg); font-size: 0.8rem; font-weight: 600; padding: 6px 10px; border-radius: 8px; pointer-events: none; box-shadow: var(--shadow); white-space: nowrap; }
details.data-table summary { cursor: pointer; color: var(--link); font-weight: 600; font-size: 0.875rem; }
.targets { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); margin-top: 8px; }
.target-head { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; margin-bottom: 8px; }
.target-head strong { font-size: 1.4rem; font-variant-numeric: tabular-nums; }
.meter { position: relative; height: 14px; border-radius: 999px; background: var(--surface-3); margin-bottom: 30px; }
.meter-fill { display: block; height: 100%; border-radius: 999px; }
.meter-fill.met { background: var(--good); }
.meter-fill.short { background: var(--male); }
.meter-target { position: absolute; top: -5px; bottom: -5px; width: 3px; background: var(--text); border-radius: 2px; transform: translateX(-50%); }
.meter-target span { position: absolute; top: 26px; right: 0; white-space: nowrap; font-size: 0.75rem; font-weight: 700; color: var(--text-2); }

/* ------------------------------------------------------------------ USSD */
.ussd-grid { display: grid; gap: 28px; align-items: start; }
@media (min-width: 860px) { .ussd-grid { grid-template-columns: 340px minmax(0, 1fr); } }
.feature-phone { width: 100%; max-width: 340px; justify-self: center; background: linear-gradient(180deg, #2b3440, #151b22); border-radius: 36px 36px 48px 48px; padding: 22px 20px 26px; box-shadow: var(--shadow-lg), inset 0 1px 0 rgb(255 255 255 / 0.1); }
.feature-brand { text-align: center; color: #9fb3c6; font-size: 0.7rem; letter-spacing: 0.3em; font-weight: 700; margin-bottom: 10px; }
.feature-screen { background: #c9dcb4; color: #122106; border-radius: 10px; min-height: 190px; padding: 10px 12px; box-shadow: inset 0 2px 6px rgb(0 0 0 / 0.35); font-family: var(--mono); overflow-wrap: anywhere; }
.feature-screen pre { margin: 0; white-space: pre-wrap; font-size: 0.9rem; line-height: 1.45; }
.feature-meta { margin: 0 0 6px; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; opacity: 0.7; }
.feature-input { margin-top: 10px; background: #e7f0dc !important; color: #122106 !important; border: 0 !important; font-family: var(--mono) !important; font-size: 1.05rem !important; text-align: center; }
.feature-input::placeholder { color: #4d5f3d !important; }
.feature-keys-top { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 12px 0; }
.btn-call { background: #2e9d5b; color: #fff; }
.btn-call:hover { background: #268a4f; }
.btn-end { background: #c8412f; color: #fff; }
.btn-end:hover { background: #b03524; }
.keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.key { font: inherit; font-size: 1.2rem; font-weight: 700; min-height: 46px; border-radius: 14px; border: 0; background: #3a4552; color: #f1f5f9; cursor: pointer; box-shadow: inset 0 -2px 0 rgb(0 0 0 / 0.3); }
.key:hover { background: #475464; }
.steps { padding-left: 1.2rem; }
.steps li { margin-bottom: 6px; }

/* ------------------------------------------------------------------ assistant */
.chat { display: flex; flex-direction: column; gap: 12px; }
.chat-top { display: flex; justify-content: flex-end; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 3px; }
.seg-btn { font: inherit; font-weight: 650; font-size: 0.875rem; border: 0; background: transparent; color: var(--text-2); padding: 7px 16px; border-radius: 999px; cursor: pointer; min-height: 36px; }
.seg-btn[aria-pressed='true'] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.chat-log { list-style: none; margin: 0; padding: 4px; display: flex; flex-direction: column; gap: 10px; max-height: 52vh; min-height: 220px; overflow-y: auto; }
.bubble { display: flex; gap: 8px; align-items: flex-end; max-width: 88%; }
.bubble-text { padding: 10px 14px; border-radius: 18px; line-height: 1.45; overflow-wrap: anywhere; }
.bubble-bot .bubble-text { background: var(--surface-2); border: 1px solid var(--border); border-bottom-left-radius: 6px; }
.bubble-me { align-self: flex-end; }
.bubble-me .bubble-text { background: var(--sky); color: #06121e; border-bottom-right-radius: 6px; }
.bubble-avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--black); color: var(--sky); display: grid; place-items: center; font-weight: 800; font-size: 0.85rem; flex: none; }
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1.2s infinite; }
.dots i:nth-child(2) { animation-delay: 0.2s; }
.dots i:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 50% { opacity: 0.25; } }
.suggest { margin: 0; }
.chat-form { display: flex; gap: 8px; }
.chat-form input { flex: 1; }
.chat-form .btn { flex: none; }
@media (max-width: 480px) { .chat-form .btn span { display: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition: none !important; scroll-behavior: auto !important; }
}
@media (forced-colors: active) {
  .pbar, .col-bar, .sbar-seg, .meter-fill { forced-color-adjust: none; }
}

/* ------------------------------------------------------------------ small refinements */
.table code { white-space: nowrap; }
.grants li > .chip { justify-self: start; }
.officer-id strong { margin-right: 8px; }
@media (max-width: 600px) { .site-header { position: static; } }

/* ---------- Omang card specimen (print record preview) ---------- */
.idc-pair { display: grid; gap: 16px; margin: 0; max-width: 560px; }
.idc-pair figcaption { font-size: 13px; }
.idc {
  --idc-ink: #1b1d20; --idc-muted: #4b4f55; --idc-red: #b3261e;
  position: relative; aspect-ratio: 85.6 / 54; width: 100%; border-radius: 14px; overflow: hidden;
  color: var(--idc-ink); box-shadow: var(--shadow); container-type: inline-size; font-family: Arial, Helvetica, sans-serif;
}
.idc-front { background: linear-gradient(120deg, #f4ecc9 0%, #f7f3dc 45%, #e4efe8 100%); display: grid; grid-template-columns: 5% 29% 1fr; gap: 3cqw; padding: 4cqw 4cqw 3.5cqw 0; }
.idc-guard { background: repeating-linear-gradient(0deg, #9cc39a 0 2px, transparent 2px 6px); opacity: 0.7; }
.idc-photo { align-self: center; aspect-ratio: 3 / 4; border-radius: 45% / 40%; background: #d8d4c7; border: 1px solid #bdb6a2; display: grid; place-content: center; text-align: center; color: #6b6555; }
.idc-photo span { font-size: 9cqw; font-weight: 700; }
.idc-photo small, .idc-print small { font-size: 2.6cqw; text-transform: uppercase; letter-spacing: 0.1em; }
.idc-main { display: flex; flex-direction: column; gap: 0.9cqw; min-width: 0; }
.idc-head { display: flex; justify-content: space-between; align-items: start; gap: 2cqw; margin-bottom: 1cqw; }
.idc-issuer { font-size: 2.4cqw; font-weight: 700; text-transform: uppercase; white-space: nowrap; }
.idc-title { font-size: 2.4cqw; font-weight: 700; text-transform: uppercase; white-space: nowrap; }
.idc-c { background: #1b1d20; color: #f7f3dc; font-weight: 800; font-size: 6.5cqw; line-height: 1; padding: 0.5cqw 1.4cqw; }
.idc-row { display: grid; grid-template-columns: 27% 1fr; align-items: baseline; gap: 2cqw; }
.idc-label { font-size: 1.8cqw; text-transform: uppercase; color: var(--idc-muted); line-height: 1.1; }
.idc-value { font-size: 3.1cqw; font-weight: 700; letter-spacing: 0.02em; line-height: 1.2; overflow-wrap: anywhere; }
.idc-id .idc-value { color: var(--idc-red); }
.idc-sign { margin-top: auto; display: flex; flex-direction: column; gap: 0.8cqw; }
.idc-sigline { display: block; height: 2.4cqw; border-bottom: 1px solid #8a8577; width: 60%; }
.idc-back { background: linear-gradient(160deg, #e6efe9 0%, #eef3ee 60%, #e2ece6 100%); display: grid; grid-template-rows: 1fr auto; padding: 4cqw 5cqw 3cqw; gap: 2cqw; }
.idc-backtop { display: grid; grid-template-columns: 34% 1fr; gap: 4cqw; min-height: 0; }
.idc-print { border-radius: 50%; background: radial-gradient(circle, #efc4c4 0%, #e8b0b0 70%, transparent 71%); border: 1px dashed #c98f8f; display: grid; place-content: center; color: #7a4a4a; aspect-ratio: 1; align-self: start; }
.idc-back .idc-row { grid-template-columns: 42% 1fr; }
.idc-mrz { margin: 0; font-family: 'OCR B', 'OCR-B', 'Courier New', monospace; font-size: 3.9cqw; line-height: 1.25; letter-spacing: 0.06em; font-weight: 700; color: #1b1d20; white-space: pre; overflow: hidden; }
.idc-specimen { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; pointer-events: none; transform: rotate(-18deg); color: rgb(179 38 30 / 0.55); }
.idc-specimen span { font-size: 15cqw; font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; line-height: 1; }
.idc-specimen small { font-size: 3.2cqw; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; }

/* ---------- Brand emblem ---------- */
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand img { flex: none; }
.signin-emblem { width: 72px; height: 72px; display: block; margin-inline: auto; }

/* ---------- Border control ---------- */
.segmented { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.segmented legend { font-weight: 600; margin-bottom: 6px; padding: 0; }
.segmented label { display: flex; align-items: center; gap: 8px; }
.border-verdict { border-width: 2px; }
.verdict-good { border-color: var(--good); }
.verdict-warn { border-color: var(--warn); }
.verdict-bad { border-color: var(--bad); }
.verdict-banner { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 12px; margin-bottom: 12px; }
.verdict-banner .icon { width: 34px; height: 34px; flex: none; }
.verdict-banner strong { display: block; font-size: 1.35rem; }
.verdict-banner span { color: inherit; opacity: 0.85; }
.verdict-good .verdict-banner { background: var(--good-bg); color: var(--good); }
.verdict-warn .verdict-banner { background: var(--warn-bg); color: var(--warn); }
.verdict-bad .verdict-banner { background: var(--bad-bg); color: var(--bad); }
.verdict-actions { font-weight: 600; font-size: 1.05rem; display: grid; gap: 6px; padding-left: 1.2em; margin: 0 0 12px; }
.verdict-notes { padding-left: 1.2em; }
.hits-open { border-color: var(--bad); border-width: 2px; }
.hbars { display: grid; gap: 10px; }
.hbar-row { display: grid; grid-template-columns: minmax(0, 12rem) 1fr auto; gap: 12px; align-items: center; }
.hbar-label { font-weight: 600; overflow-wrap: anywhere; }
.hbar-track { display: flex; height: 16px; background: var(--surface-2); border-radius: 8px; overflow: hidden; min-width: 0; }
.hbar-out { background: var(--sky); }
.hbar-in { background: var(--good); }
.swatch.hbar-out, .swatch.hbar-in { display: inline-block; width: 12px; height: 12px; border-radius: 3px; }
.hbar-val { font-variant-numeric: tabular-nums; color: var(--text-2); font-size: 0.875rem; white-space: nowrap; }
@media (max-width: 560px) { .hbar-row { grid-template-columns: 1fr; gap: 4px; } }

/* Explicit dark choice in the viewer */
:root[data-theme="dark"] {
    --sky-50: #13283c;
    --sky-100: #173049;
    --sky-200: #214466;
    --bg: #0a131d;
    --surface: #111e2b;
    --surface-2: #162636;
    --surface-3: #1c3043;
    --border: #243a50;
    --border-strong: #35526e;
    --text: #e8eff6;
    --text-2: #b4c4d4;
    --muted: #97abbf;
    --link: #9fcaf2;
    --focus: #9fcaf2;
    --good: #6fd49a;
    --good-bg: #10301f;
    --warn: #f3c552;
    --warn-bg: #33290c;
    --bad: #ff948a;
    --bad-bg: #3b1714;
    --info: #9fcaf2;
    --info-bg: #122a40;
    --female: #c96e2a;
    --male: #4a90d9;
    --chart-ink: #9fb3c6;
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.4);
    --shadow: 0 1px 3px rgb(0 0 0 / 0.35), 0 8px 24px rgb(0 0 0 / 0.35);
    --shadow-lg: 0 24px 60px rgb(0 0 0 / 0.55);
   color-scheme: dark;}

:root[data-theme="dark"] .toast { background: #e8eff6; color: #0a131d; }
:root[data-theme="dark"] .toast-good .icon { color: #1b7340; }
:root[data-theme="dark"] .toast-bad .icon { color: #b42318; }
 :root[data-theme="dark"] .pillar-icon { background: var(--sky); color: #06121e; }
 :root[data-theme="dark"] .app-tab[aria-current='page'] { background: var(--sky); color: #06121e; }
 :root[data-theme="dark"] .privacy-teaser { background: var(--sky-100); border: 1px solid var(--sky); }
 :root[data-theme="dark"] .access-hero { background: var(--sky-100); border: 1px solid var(--sky); }
 :root[data-theme="dark"] .tl-officer .tl-dot { border-color: var(--text-2); }
 :root[data-theme="dark"] .verdict-icon { color: #0a131d; }
 