/* South Zone Sanitation Monitor ---------------------------------------------- */
:root {
  /* palette matched to sims.longding.tech */
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #f1f5f9;
  --line: #e6eaf2;
  --line-strong: #d3dbe8;
  --ink: #0f172a;
  --ink-2: #334155;
  --muted: #64748b;
  --faint: #94a3b8;
  --accent: #2f5fd0;
  --accent-500: #3b6fe0;
  --accent-700: #2549a8;
  --accent-soft: #eef4ff;
  --accent-100: #dbe6ff;
  --accent-ring: #3b6fe059;
  --good: #16a34a;   --good-ink: #15803d;   --good-soft: #ecfdf3;
  --warn: #f59e0b;   --warn-ink: #92400e;   --warn-soft: #fffbeb;
  --serious: #f97316; --serious-ink: #9a3412; --serious-soft: #fff7ed;
  --crit: #dc2626;   --crit-ink: #b91c1c;   --crit-soft: #fef2f2;
  --info: #2f5fd0;   --info-ink: #2549a8;   --info-soft: #eef4ff;
  --series-aqi: #2f5fd0;
  --series-comp: #2f5fd0;
  --context: #a3a9b1;
  --chart-grid: #e6eaf2;
  --chart-axis: #d3dbe8;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-1: 0 1px 3px 0 #0000001a, 0 1px 2px -1px #0000001a;
  --shadow-2: 0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;
  --shadow-3: 0 25px 50px -12px #00000040;
  --sidebar-w: 256px;
  --topbar-h: 62px;
  --font: Geist, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
@font-face { font-family: Geist; font-style: normal; font-weight: 100 900; font-display: swap; src: url(fonts/geist.woff2) format("woff2"); }
* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; font: 15px/1.55 var(--font); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
[hidden] { display: none !important; }
a { color: var(--accent-700); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; }
h1 { font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: 17px; font-weight: 650; }
h3 { font-size: 15px; font-weight: 650; }
p { margin: 0 0 8px; }
code, .mono { font-family: var(--mono); font-size: 12.5px; }
.num, table.data td.num { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.boot { display: grid; place-items: center; height: 100vh; color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- shell */
.shell { display: grid; grid-template-columns: var(--sidebar-w) 1fr; grid-template-rows: var(--topbar-h) auto 1fr; min-height: 100vh; }
.topbar { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; padding: 0 16px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 900; }
.brand { display: flex; align-items: center; gap: 10px; min-width: calc(var(--sidebar-w) - 16px); color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); display: grid; place-items: center; flex: none; }
.brand-text b { display: block; font-size: 14px; line-height: 1.1; }
.brand-text small { color: var(--muted); font-size: 11.5px; }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.global-search { position: relative; width: min(380px, 34vw); }
.global-search input { width: 100%; padding: 7px 10px 7px 32px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); }
.global-search input:focus { background: var(--surface); outline: 2px solid var(--accent-ring); border-color: var(--accent); }
.global-search .icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.search-results { position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-2); max-height: 420px; overflow: auto; z-index: 1000; }
.search-results a { display: block; padding: 8px 12px; border-bottom: 1px solid var(--line); color: var(--ink); }
.search-results a:hover, .search-results a:focus { background: var(--accent-soft); text-decoration: none; }
.search-results small { color: var(--muted); display: block; font-size: 11.5px; }
.top-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface-2); font-size: 12.5px; white-space: nowrap; color: var(--ink-2); }
.top-chip:hover { text-decoration: none; background: var(--surface-3); }
.icon-btn { position: relative; border: 0; background: none; width: 36px; height: 36px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; color: var(--ink-2); }
.icon-btn:hover { background: var(--surface-3); }
.icon-btn .dot { position: absolute; top: 3px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; background: var(--crit); color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--surface); }
.user-menu { position: relative; }
.user-btn { display: flex; align-items: center; gap: 8px; border: 0; background: none; padding: 4px 6px; border-radius: 8px; cursor: pointer; }
.user-btn:hover { background: var(--surface-3); }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-700); display: grid; place-items: center; font-weight: 700; font-size: 12px; flex: none; }
.user-btn .who { text-align: left; line-height: 1.15; }
.user-btn .who b { display: block; font-size: 13px; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-btn .who small { color: var(--muted); font-size: 11.5px; }
.dropdown { position: absolute; right: 0; top: calc(100% + 6px); min-width: 220px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-2); padding: 6px; z-index: 1000; }
.dropdown a, .dropdown button { display: block; width: 100%; text-align: left; padding: 8px 10px; border: 0; background: none; border-radius: 6px; color: var(--ink); cursor: pointer; }
.dropdown a:hover, .dropdown button:hover { background: var(--surface-3); text-decoration: none; }
.dropdown hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0; }

.banners { grid-column: 1 / -1; grid-row: 2; }
.banner { padding: 7px 16px; font-size: 13px; display: flex; gap: 8px; align-items: flex-start; }
.banner svg { flex: none; margin-top: 2px; }
.banner span { min-width: 0; }
.banner.dev { background: #fbe9e9; color: var(--crit-ink); border-bottom: 1px solid #f1c4c4; }

.sidebar { background: var(--surface); border-right: 1px solid var(--line); padding: 12px 10px 24px; position: sticky; top: var(--topbar-h); height: calc(100vh - var(--topbar-h)); overflow-y: auto; grid-row: 3; }
.nav-group { margin-bottom: 14px; }
.nav-group > span { display: block; padding: 0 10px 4px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.nav-link { display: flex; align-items: center; gap: 11px; padding: 10px 11px; border-radius: 9px; color: var(--ink-2); font-weight: 550; font-size: 15px; }
.nav-link:hover { background: var(--surface-3); text-decoration: none; color: var(--ink); }
.nav-link.active { background: var(--accent-soft); color: var(--accent-700); font-weight: 650; }
.nav-link svg { flex: none; opacity: .8; }
.nav-link .count { margin-left: auto; font-size: 11.5px; font-weight: 700; padding: 0 6px; border-radius: 99px; background: var(--crit-soft); color: var(--crit-ink); }
.nav-link.primary-action { background: var(--accent); color: #fff; margin-bottom: 12px; justify-content: center; font-weight: 700; font-size: 16px; padding: 13px 11px; box-shadow: var(--shadow-1); }
.nav-link.primary-action:hover { background: var(--accent-700); color: #fff; }

.main { grid-row: 3; min-width: 0; padding: 20px 24px 64px; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head .sub { color: var(--muted); margin-top: 3px; font-size: 13px; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.crumbs { font-size: 12.5px; color: var(--muted); margin-bottom: 6px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--accent-700); }

.mobile-bar { display: none; }
.backdrop { display: none; }

/* ---------------------------------------------------------------- controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 15px; min-height: 42px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); color: var(--ink); cursor: pointer; font-weight: 550; white-space: nowrap; line-height: 1.3; text-decoration: none; }
.btn:hover { background: var(--surface-3); text-decoration: none; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-700); border-color: var(--accent-700); }
.btn.danger { color: var(--crit-ink); border-color: #e7b9b9; }
.btn.danger:hover { background: var(--crit-soft); }
.btn.danger.solid { background: var(--crit); color: #fff; border-color: var(--crit); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--surface-3); }
.btn.sm { padding: 6px 11px; font-size: 13.5px; border-radius: 8px; min-height: 34px; }
.btn.lg { padding: 14px 22px; font-size: 17px; min-height: 52px; border-radius: 10px; }
.btn.block { width: 100%; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; min-width: 0; }
.field > span, .field > label.lbl { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.field .hint { font-size: 13px; color: var(--muted); font-weight: 400; }
.input, .field input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]), .field select, .field textarea, select.input, textarea.input {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 9px; background: var(--surface); min-width: 0; min-height: 44px; font-size: 15px; }
.field textarea, textarea.input { resize: vertical; min-height: 72px; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--accent-ring); border-color: var(--accent); }
.field input[aria-invalid="true"], .field select[aria-invalid="true"] { border-color: var(--crit); }
.check { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 10px; cursor: pointer; }
.check input { margin-top: 2px; accent-color: var(--accent); width: 20px; height: 20px; flex: none; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.form-error { background: var(--crit-soft); color: var(--crit-ink); border: 1px solid #f0c8c8; padding: 8px 10px; border-radius: 8px; margin-bottom: 12px; font-size: 13px; }
.form-note { background: var(--info-soft); color: var(--info-ink); border: 1px solid #cadff7; padding: 8px 10px; border-radius: 8px; margin-bottom: 12px; font-size: 13px; }

.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 14px; }
.filters .field { margin-bottom: 0; min-width: 150px; }
.filters .field.grow { flex: 1; min-width: 200px; }
.seg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 8px; overflow: hidden; background: var(--surface); }
.seg button { border: 0; background: none; padding: 9px 15px; min-height: 42px; cursor: pointer; font-weight: 600; color: var(--ink-2); border-right: 1px solid var(--line); }
.seg button:last-child { border-right: 0; }
.seg button[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent-700); }

/* ---------------------------------------------------------------- cards / layout */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-1); }
.card-pad { padding: 16px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.card-head h2, .card-head h3 { display: flex; align-items: center; gap: 8px; }
.card-head .meta { color: var(--muted); font-size: 12.5px; }
.card-body { padding: 14px 16px; }
.card + .card, .stack > * + * { margin-top: 16px; }
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.main-side { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; }
.grid.side-main { grid-template-columns: 300px minmax(0, 1fr); align-items: start; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.tiny { font-size: 11.5px; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.between { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.divider { border: 0; border-top: 1px solid var(--line); margin: 14px 0; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; font-size: 13px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* KPI tiles */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; color: var(--ink); box-shadow: var(--shadow-1); position: relative; }
a.kpi:hover { text-decoration: none; border-color: var(--line-strong); box-shadow: var(--shadow-2); }
.kpi .label { font-size: 13.5px; color: var(--muted); font-weight: 550; display: flex; gap: 6px; align-items: center; }
.kpi .value { font-size: 32px; font-weight: 650; line-height: 1.15; margin-top: 4px; letter-spacing: -.01em; }
.kpi .value small { font-size: 13px; color: var(--muted); font-weight: 500; margin-left: 4px; letter-spacing: 0; }
.kpi .foot { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.kpi.crit .value { color: var(--crit-ink); }
.kpi.warn .value { color: var(--warn-ink); }
.kpi.good .value { color: var(--good-ink); }
.kpi .status-icon { position: absolute; top: 12px; right: 12px; }

/* ---------------------------------------------------------------- badges and chips */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 99px; font-size: 12.5px; font-weight: 600; white-space: nowrap; line-height: 1.5; border: 1px solid transparent; }
.badge.neutral { background: var(--surface-3); color: var(--ink-2); }
.badge.accent { background: var(--accent-soft); color: var(--accent-700); }
.badge.good { background: var(--good-soft); color: var(--good-ink); }
.badge.warn { background: var(--warn-soft); color: var(--warn-ink); }
.badge.serious { background: var(--serious-soft); color: var(--serious-ink); }
.badge.crit { background: var(--crit-soft); color: var(--crit-ink); }
.badge.info { background: var(--info-soft); color: var(--info-ink); }
.badge.outline { background: var(--surface); border-color: var(--line-strong); color: var(--ink-2); }
.badge svg { flex: none; }
.swatch { width: 10px; height: 10px; border-radius: 50%; flex: none; display: inline-block; box-shadow: 0 0 0 1px rgba(0,0,0,.12); }
.swatch.sq { border-radius: 3px; }
.cat { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-2); white-space: nowrap; }
.glyph { width: 20px; height: 20px; border-radius: 50%; color: #fff; font-size: 10.5px; font-weight: 800; display: inline-grid; place-items: center; flex: none; }
.aqi { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.aqi b { font-size: 15px; font-variant-numeric: tabular-nums; }
.aqi .cat-label { font-size: 12px; color: var(--ink-2); }
.aqi .pol { font-size: 11.5px; color: var(--muted); }
.ref { font-family: var(--mono); font-size: 12px; background: var(--surface-3); padding: 1px 6px; border-radius: 5px; color: var(--ink-2); white-space: nowrap; }
.flag-list { display: flex; flex-wrap: wrap; gap: 4px; }

/* ---------------------------------------------------------------- tables */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; }
table.data th { text-align: left; font-size: 12.5px; font-weight: 650; color: var(--muted); background: var(--surface-2); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; }
table.data td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: #fafbfc; }
table.data tr.clickable { cursor: pointer; }
table.data tr.flagged td:first-child { box-shadow: inset 3px 0 0 var(--crit); }
table.data td .title { font-weight: 600; color: var(--ink); }
table.data td .title:hover { color: var(--accent-700); }
table.data .sub { color: var(--muted); font-size: 12px; margin-top: 2px; }
table.data.compact td { padding: 6px 8px; }

/* ---------------------------------------------------------------- tabs */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; scrollbar-width: none; }
.tabs button { border: 0; background: none; padding: 12px 14px; min-height: 46px; font-weight: 600; font-size: 15px; color: var(--muted); border-bottom: 3px solid transparent; cursor: pointer; white-space: nowrap; }
.tabs button:hover { color: var(--ink); }
.tabs button[aria-selected="true"] { color: var(--accent-700); border-bottom-color: var(--accent); }
.tabs button .count { font-size: 11.5px; background: var(--surface-3); color: var(--ink-2); border-radius: 99px; padding: 0 6px; margin-left: 4px; }

/* ---------------------------------------------------------------- modal / toast */
.modal-backdrop { position: fixed; inset: 0; background: rgba(16, 24, 40, .45); z-index: 3000; display: grid; place-items: center; padding: 16px; animation: fade .12s ease-out; }
.modal { background: var(--surface); border-radius: 14px; box-shadow: var(--shadow-3); width: min(560px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; }
.modal.wide { width: min(880px, 100%); }
.modal.full { width: min(1100px, 100%); height: calc(100vh - 32px); }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.modal-body { padding: 16px 18px; overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--surface-2); border-radius: 0 0 14px 14px; flex-wrap: wrap; }
@keyframes fade { from { opacity: 0; } }
#toasts { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 4000; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { background: #1d2939; color: #fff; padding: 9px 14px; border-radius: 9px; box-shadow: var(--shadow-2); font-size: 13.5px; max-width: min(560px, 92vw); pointer-events: auto; animation: fade .15s ease-out; }
.toast.error { background: var(--crit-ink); }
.toast.good { background: var(--good-ink); }

/* ---------------------------------------------------------------- empty / states */
.empty { text-align: center; padding: 36px 16px; color: var(--muted); }
.empty h3 { color: var(--ink-2); margin-bottom: 4px; }
.empty .btn { margin-top: 10px; }
.loading { padding: 40px; text-align: center; color: var(--muted); }
.error-box { padding: 20px; border: 1px solid #f0c8c8; background: var(--crit-soft); color: var(--crit-ink); border-radius: var(--radius); }
.stale { opacity: .55; transition: opacity .15s; }

/* ---------------------------------------------------------------- dashboard */
.hotspot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.hs-card { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; color: var(--ink); box-shadow: var(--shadow-1); }
.hs-card:hover { text-decoration: none; border-color: var(--line-strong); box-shadow: var(--shadow-2); }
.hs-card .name { display: flex; align-items: center; gap: 8px; font-weight: 650; font-size: 14.5px; }
.hs-card .station { font-size: 12.5px; color: var(--muted); margin: 1px 0 8px 18px; }
.hs-card .hs-aqi { flex: none; min-width: 44px; height: 34px; padding: 0 9px; border-radius: 9px; color: #fff; font-weight: 750; font-size: 19px;
  display: grid; place-items: center; font-variant-numeric: tabular-nums; text-shadow: 0 1px 1px rgba(0,0,0,.2); }
.hs-card .name { font-size: 16px; }
.hs-card .stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; }
.hs-card .stat { background: var(--surface-2); border-radius: 7px; padding: 5px 7px; }
.hs-card .stat b { display: block; font-size: 17px; font-variant-numeric: tabular-nums; }
.hs-card .stat span { font-size: 11.5px; color: var(--muted); }
.hs-card .stat.crit b { color: var(--crit-ink); }
.hs-card .insight { font-size: 12px; margin-top: 8px; display: flex; gap: 6px; align-items: flex-start; color: var(--ink-2); }
.meter { height: 6px; border-radius: 99px; background: #d5e6f8; overflow: hidden; margin-top: 4px; }
.meter > i { display: block; height: 100%; background: var(--info); border-radius: 99px; }

.attention { list-style: none; margin: 0; padding: 0; }
.attention li { display: flex; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--line); align-items: flex-start; }
.attention li:last-child { border-bottom: 0; }
.attention .ico { flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; }
.attention .ico.crit { background: var(--crit-soft); color: var(--crit-ink); }
.attention .ico.warn { background: var(--warn-soft); color: var(--warn-ink); }
.attention .ico.info { background: var(--info-soft); color: var(--info-ink); }
.attention .txt { flex: 1; min-width: 0; font-size: 13px; }
.attention .txt .lvl { font-weight: 650; }

/* ---------------------------------------------------------------- compliance grid */
.cgrid { border-collapse: separate; border-spacing: 2px; font-size: 12.5px; }
.cgrid th { font-weight: 600; color: var(--muted); font-size: 11.5px; padding: 4px 6px; text-align: center; vertical-align: bottom; line-height: 1.2; }
.cgrid th.row-head { text-align: left; }
.cgrid td.hname { padding: 4px 8px 4px 0; white-space: nowrap; font-weight: 600; }
.cgrid td.cell { width: 64px; min-width: 52px; height: 34px; text-align: center; border-radius: 6px; font-variant-numeric: tabular-nums; cursor: default; position: relative; }
.cell.done { background: var(--good-soft); color: var(--good-ink); }
.cell.pending, .cell.partial { background: var(--warn-soft); color: var(--warn-ink); }
.cell.missed { background: var(--crit-soft); color: var(--crit-ink); }
.cell.today { background: var(--surface-3); color: var(--muted); }
.cell.na, .cell.future { background: transparent; color: var(--faint); }
.cell .cnt { display: block; font-size: 10.5px; opacity: .85; }
.cgrid td.pct { font-weight: 700; padding-left: 8px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.heat td.cell { color: #fff; font-weight: 650; }
/* positive actions: 7-day strip in tables, 30-day strip on the detail page */
.week-strip { display: inline-flex; gap: 2px; vertical-align: middle; }
.week-strip .cell { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 4px; font-size: 11px; }
.month-strip { display: flex; flex-wrap: wrap; gap: 4px; }
.month-strip .cell { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 6px; font-size: 14px; line-height: 1; }
.month-strip .cell small { font-size: 9.5px; opacity: .8; margin-bottom: 2px; }
.aqi-cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.aqi-cal .dow { font-size: 11px; font-weight: 600; color: var(--muted); text-align: center; padding-bottom: 2px; }
.aqi-cal .day { min-height: 58px; border-radius: 8px; padding: 5px 6px; color: #fff; display: flex; flex-direction: column; text-shadow: 0 1px 1px rgba(0,0,0,.25); }
.aqi-cal .day .dn { font-size: 11px; opacity: .9; }
.aqi-cal .day .v { font-size: 18px; line-height: 1.15; }
.aqi-cal .day .pol { font-size: 10px; opacity: .9; }
.aqi-cal .day.none { background: var(--surface-3); color: var(--muted); text-shadow: none; }
.aqi-cal .day.pad { background: transparent; }
.aqi-cal .day.today { outline: 2px solid var(--ink); outline-offset: 1px; }
@media (max-width: 560px) { .aqi-cal { gap: 2px; } .aqi-cal .day { min-height: 48px; padding: 3px 4px; } .aqi-cal .day .v { font-size: 15px; } .aqi-cal .day .pol { display: none; } }
.legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--ink-2); align-items: center; }
.legend span { display: inline-flex; gap: 5px; align-items: center; }
.legend .key-line { width: 18px; height: 2px; display: inline-block; border-radius: 2px; }
.legend .key-bar { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
.scale { display: inline-flex; border-radius: 4px; overflow: hidden; }
.scale i { width: 26px; height: 10px; display: block; }

/* ---------------------------------------------------------------- charts */
.chart { position: relative; }
.chart svg { display: block; overflow: visible; max-width: 100%; }
.chart text { font-family: var(--font); fill: var(--muted); font-size: 12px; }
.chart .grid-line { stroke: var(--chart-grid); stroke-width: 1; shape-rendering: crispEdges; }
.chart .axis-line { stroke: var(--chart-axis); stroke-width: 1; shape-rendering: crispEdges; }
.chart .band-label { fill: var(--faint); font-size: 10.5px; }
.chart .panel-title { fill: var(--ink-2); font-size: 13px; font-weight: 650; }
.chart .crosshair { stroke: #667085; stroke-width: 1; pointer-events: none; }
.chart .end-label { fill: var(--ink); font-size: 13px; font-weight: 700; }
.chart-tip { position: absolute; pointer-events: none; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-2); padding: 8px 11px; font-size: 13px; min-width: 165px; z-index: 5; }
.chart-tip .d { color: var(--muted); font-size: 11.5px; margin-bottom: 3px; }
.chart-tip .r { display: flex; align-items: center; gap: 6px; justify-content: space-between; }
.chart-tip .r b { font-variant-numeric: tabular-nums; }
.chart-tip .r .k { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); }
.chart-tip .r .k i { width: 12px; height: 2px; border-radius: 2px; display: inline-block; }
.chart-tip .r .k i.bar { height: 8px; width: 8px; border-radius: 2px; }
.insight-box { display: flex; gap: 9px; align-items: flex-start; padding: 11px 14px; border-radius: 9px; font-size: 14.5px; line-height: 1.45; margin-top: 12px; }
.insight-box.mismatch, .insight-box.low_compliance { background: var(--serious-soft); color: var(--serious-ink); }
.insight-box.improving, .insight-box.regional { background: var(--good-soft); color: var(--good-ink); }
.insight-box.steady, .insight-box.insufficient { background: var(--surface-2); color: var(--ink-2); }
.small-multiples { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 16px; }

/* ---------------------------------------------------------------- tasks tree / timeline */
.tree { list-style: none; margin: 0; padding: 0; }
.tree .tree { padding-left: 22px; border-left: 1px dashed var(--line-strong); margin-left: 10px; }
.task-row { display: flex; gap: 10px; align-items: flex-start; padding: 9px 10px; border-radius: 8px; }
.task-row:hover { background: var(--surface-2); }
.task-row .status-dot { margin-top: 3px; flex: none; }
.task-row .body { flex: 1; min-width: 0; }
.task-row .t { font-weight: 600; color: var(--ink); }
.task-row .meta { display: flex; flex-wrap: wrap; gap: 6px 10px; font-size: 12px; color: var(--muted); margin-top: 3px; align-items: center; }
.task-row.closed .t { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--faint); }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 14px 22px; }
.timeline li::before { content: ""; position: absolute; left: 6px; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.timeline li::after { content: ""; position: absolute; left: 9.5px; top: 16px; bottom: 0; width: 1px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li.accent::before { background: var(--accent); }
.timeline li.crit::before { background: var(--crit); }
.timeline li.good::before { background: var(--good); }
.timeline .when { font-size: 12px; color: var(--muted); }
.comments { list-style: none; margin: 0 0 10px; padding: 0; }
.comments li { padding: 9px 0; border-bottom: 1px solid var(--line); display: flex; gap: 10px; }
.comments li:last-child { border-bottom: 0; }
.comments .c-body { flex: 1; min-width: 0; }
.comments .c-meta { font-size: 12px; color: var(--muted); }
.comments li.system .c-body { color: var(--muted); font-size: 12.5px; }
.diff { font-size: 12px; margin-top: 4px; }
.diff .old { color: var(--crit-ink); text-decoration: line-through; }
.diff .new { color: var(--good-ink); }

/* ---------------------------------------------------------------- photos */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.photo-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; cursor: pointer; color: var(--ink); text-align: left; padding: 0; }
.photo-card:hover { box-shadow: var(--shadow-2); }
.photo-card .ph { aspect-ratio: 4 / 3; background: var(--surface-3); position: relative; overflow: hidden; }
.photo-card .ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-card .ph .badges { position: absolute; top: 6px; left: 6px; right: 6px; display: flex; gap: 4px; flex-wrap: wrap; }
.photo-card .info { padding: 8px 10px; font-size: 12.5px; }
.photo-card .info b { display: block; font-size: 13px; }
.photo-big { width: 100%; max-height: 60vh; object-fit: contain; background: #111; border-radius: 8px; display: block; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pair figure { margin: 0; }
.pair figcaption { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.thumb { width: 56px; height: 42px; object-fit: cover; border-radius: 6px; background: var(--surface-3); display: block; }

/* ---------------------------------------------------------------- capture */
.capture { display: flex; flex-direction: column; gap: 10px; }
.viewfinder { position: relative; background: #0b0f14; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; max-height: calc(100dvh - 330px); min-height: 220px; width: 100%; display: grid; place-items: center; }
.viewfinder video, .viewfinder img { width: 100%; height: 100%; object-fit: contain; display: block; }
.viewfinder .overlay-msg { position: absolute; inset: 0; display: grid; place-items: center; color: #e5e7eb; text-align: center; padding: 20px; font-size: 14px; }
.gps-line { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.shutter-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; }
.shutter { width: 76px; height: 76px; border-radius: 50%; border: 4px solid #fff; background: var(--accent); box-shadow: 0 0 0 2px var(--accent); cursor: pointer; }
.shutter:disabled { background: #9aa4ae; box-shadow: 0 0 0 2px #9aa4ae; cursor: not-allowed; }
.action-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.action-tile { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 11px; padding: 13px; text-align: left; cursor: pointer; font-weight: 600; font-size: 15px; min-height: 66px; }
.action-tile small { display: block; color: var(--muted); font-weight: 400; font-size: 12.5px; margin-top: 2px; }
.action-tile[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent); }
.steps { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.steps span { font-size: 12px; padding: 3px 10px; border-radius: 99px; background: var(--surface-3); color: var(--muted); font-weight: 600; }
.steps span.on { background: var(--accent); color: #fff; }
.steps span.done { background: var(--accent-soft); color: var(--accent-700); }

/* ---------------------------------------------------------------- map */
.map-box { height: 320px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--surface-3); position: relative; z-index: 0; }
.map-box.tall { height: calc(100vh - 170px); min-height: 460px; }
.map-box.short { height: 220px; }
.map-page { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 16px; align-items: start; }
.map-offline { display: grid; place-items: center; height: 100%; color: var(--muted); text-align: center; padding: 16px; }
.pin-icon svg { filter: drop-shadow(0 2px 2px rgba(0,0,0,.35)); }
.pin-icon .g { font: 800 10px/1 var(--font); fill: #fff; }
.centre-icon div { width: 18px; height: 18px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1.5px rgba(0,0,0,.45), 0 2px 5px rgba(0,0,0,.35); }
.station-icon div { width: 11px; height: 11px; background: #334155; border: 2px solid #fff; transform: rotate(45deg); box-shadow: 0 0 0 1px rgba(0,0,0,.4); }
.log-icon div { width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.45); }
.leaflet-tooltip.hs-name { background: rgba(255,255,255,.94); border: 0; border-radius: 5px; padding: 1px 6px; font-weight: 650; font-size: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.leaflet-tooltip.hs-name::before { display: none; }
.leaflet-popup-content { font: 13px/1.45 var(--font); margin: 10px 12px; min-width: 220px; }
.leaflet-popup-content h4 { margin: 0 0 4px; font-size: 13.5px; }
.map-legend { background: rgba(255,255,255,.95); padding: 8px 10px; border-radius: 8px; box-shadow: 0 1px 4px rgba(0,0,0,.2); font-size: 12px; line-height: 1.7; max-height: 280px; overflow: auto; }
.layer-list label { display: flex; gap: 8px; align-items: center; padding: 4px 0; cursor: pointer; font-size: 13px; }

/* ---------------------------------------------------------------- auth */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: linear-gradient(160deg, #eef4ff 0%, #f3f5f7 55%); }
.auth-card { width: min(460px, 100%); background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-3); padding: 28px; }
.auth-card.wide { width: min(640px, 100%); }
.auth-card .brand { margin-bottom: 18px; min-width: 0; }
.auth-card h1 { margin-bottom: 4px; }
.auth-foot { margin-top: 18px; font-size: 12px; color: var(--muted); text-align: center; }

/* ---------------------------------------------------------------- report document */
.report-doc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 32px; max-width: 1100px; }
.report-doc h1 { font-size: 22px; }
.report-doc h2 { font-size: 16px; margin: 24px 0 8px; padding-bottom: 6px; border-bottom: 2px solid var(--ink); }
.report-doc h3 { margin: 14px 0 6px; }
.report-doc .rep-head { display: flex; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 12px; }
.report-doc table.data th { position: static; }
.report-doc .attention-list li { margin-bottom: 4px; }
.report-doc .kpis { grid-template-columns: repeat(4, 1fr); }
.report-doc .kpi { box-shadow: none; }
.delta-up { color: var(--crit-ink); }
.delta-down { color: var(--good-ink); }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1180px) {
  .grid.main-side { grid-template-columns: minmax(0, 1fr); }
  .grid.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  :root { --topbar-h: 52px; }
  .shell { grid-template-columns: 1fr; }
  .menu-btn { display: grid; }
  .brand { min-width: 0; }
  .brand-text small { display: none; }
  .global-search { display: none; }
  .top-chip.hide-sm { display: none; }
  .user-btn .who { display: none; }
  .sidebar { position: fixed; left: 0; top: var(--topbar-h); bottom: 0; width: 272px; height: auto; z-index: 950; transform: translateX(-102%); transition: transform .18s ease-out; box-shadow: var(--shadow-3); }
  .shell.nav-open .sidebar { transform: none; }
  .shell.nav-open .backdrop { display: block; position: fixed; inset: var(--topbar-h) 0 0 0; background: rgba(16,24,40,.35); z-index: 940; }
  .main { padding: 16px 16px 90px; grid-row: auto; }
  .grid.two, .grid.three, .grid.side-main, .map-page { grid-template-columns: minmax(0, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .mobile-bar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); z-index: 900; padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); gap: 6px; }
  .mobile-bar a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; color: var(--ink-2); padding: 4px; border-radius: 8px; }
  .mobile-bar a.log { background: var(--accent); color: #fff; font-weight: 650; }
  .mobile-bar a:hover { text-decoration: none; }
  .map-box.tall { height: 62vh; }
  .small-multiples { grid-template-columns: minmax(0, 1fr); }
  .report-doc { padding: 18px 16px; }
  .report-doc .kpis { grid-template-columns: repeat(2, 1fr); }
  h1 { font-size: 19px; }
  .modal-backdrop { padding: 0; place-items: end center; }
  .modal, .modal.wide, .modal.full { width: 100%; max-height: 94vh; border-radius: 14px 14px 0 0; height: auto; }
  .modal-foot { border-radius: 0; }
}
@media (max-width: 520px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi .value { font-size: 24px; }
  .hotspot-grid { grid-template-columns: minmax(0, 1fr); }
  .page-head .actions { width: 100%; }
  .filters .field { min-width: calc(50% - 4px); flex: 1; }
}


/* ================================================================ simple & mobile
   Everything below is aimed at officers with little experience of apps: bigger targets,
   one column on a phone, tables that become cards, and plain visual cues.            */

/* --- "what to do now" action rows (home screen and empty states) */
.do-list { display: grid; gap: 10px; }
.do-row { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line);
  border-left: 5px solid var(--line-strong); border-radius: var(--radius); color: var(--ink); box-shadow: var(--shadow-1); min-height: 64px; }
a.do-row:hover, button.do-row:hover { text-decoration: none; border-color: var(--line-strong); box-shadow: var(--shadow-2); }
.do-row .ic { flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-2); }
.do-row { text-align: left; font: inherit; }
.do-row .tx { flex: 1; min-width: 0; }
.do-row .tx b { display: block; font-size: 16px; font-weight: 650; }
.do-row .tx span { color: var(--muted); font-size: 13.5px; }
.do-row .go { flex: none; color: var(--faint); }
.do-row.crit { border-left-color: var(--crit); } .do-row.crit .ic { background: var(--crit-soft); color: var(--crit-ink); }
.do-row.warn { border-left-color: var(--warn); } .do-row.warn .ic { background: var(--warn-soft); color: var(--warn-ink); }
.do-row.good { border-left-color: var(--good); } .do-row.good .ic { background: var(--good-soft); color: var(--good-ink); }
.do-row.accent { border-left-color: var(--accent); } .do-row.accent .ic { background: var(--accent-soft); color: var(--accent-700); }
.do-row .count-pill { flex: none; min-width: 34px; height: 34px; padding: 0 9px; border-radius: 99px; display: grid; place-items: center;
  font-weight: 700; font-size: 16px; background: var(--surface-3); color: var(--ink); }
.do-row.crit .count-pill { background: var(--crit); color: #fff; }
.do-row.warn .count-pill { background: var(--warn); color: #4a3000; }
.do-row.good .count-pill { background: var(--good-soft); color: var(--good-ink); }

/* --- big primary action (phone-first) */
.big-cta { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 18px; border-radius: 14px;
  background: var(--accent); color: #fff; font-size: 18px; font-weight: 700; box-shadow: var(--shadow-2); border: 0; cursor: pointer; }
.big-cta:hover { background: var(--accent-700); color: #fff; text-decoration: none; }
.big-cta small { display: block; font-weight: 500; font-size: 13px; opacity: .9; }

/* --- AQI hero: one large, colour-banded number */
.aqi-hero { display: flex; align-items: center; gap: 16px; padding: 16px; border-radius: var(--radius); color: #fff; }
.aqi-hero .n { font-size: 46px; font-weight: 750; line-height: 1; font-variant-numeric: tabular-nums; }
.aqi-hero .t b { display: block; font-size: 17px; }
.aqi-hero .t span { font-size: 13px; opacity: .92; }
.aqi-strip { display: flex; border-radius: 99px; overflow: hidden; height: 10px; margin-top: 8px; }
.aqi-strip i { flex: 1; }
.aqi-scale { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 3px; }

/* --- plain-language help line under a page title */
.help-line { background: var(--accent-soft); color: var(--accent-700); border-radius: 10px; padding: 10px 14px; font-size: 14px; margin-bottom: 14px;
  display: flex; gap: 9px; align-items: flex-start; }
.help-line svg { flex: none; margin-top: 2px; }

/* --- steps used by the guided forms */
.wizard-step { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; }
.wizard-step .n { width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; }
.wizard-step b { font-size: 16px; }

/* --- tables become cards on small screens (labels are stamped by core.js) */
@media (max-width: 760px) {
  .table-wrap { overflow-x: visible; }
  table.data, table.data tbody, table.data tr, table.data td { display: block; width: 100%; }
  table.data thead { display: none; }
  table.data tr { border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 10px; padding: 4px 2px; background: var(--surface); }
  table.data tr:last-child { margin-bottom: 0; }
  table.data td { border: 0; padding: 7px 12px; display: flex; gap: 12px; align-items: baseline; justify-content: space-between; }
  table.data td:empty { display: none; }
  table.data td::before { content: attr(data-label); flex: none; color: var(--muted); font-size: 12.5px; font-weight: 600; max-width: 42%; }
  table.data td[data-label=""]::before, table.data td.no-label::before { display: none; }
  table.data td:first-child { display: block; padding-top: 10px; }
  table.data td:first-child::before { display: none; }
  table.data td:first-child .title { font-size: 16px; }
  table.data td .sub { font-size: 13px; }
  table.data td.right, table.data td .right { text-align: left; }
  table.data tbody tr:hover td { background: transparent; }
  table.data tr.flagged { box-shadow: inset 4px 0 0 var(--crit); }
  table.data tr.flagged td:first-child { box-shadow: none; }
  table.data.compact td { padding: 6px 12px; }
  /* the cell-grid tables keep their grid shape and scroll instead */
  .cgrid, .cgrid tbody, .cgrid tr, .cgrid td, .cgrid thead { display: revert; }
  .card .table-wrap:has(.cgrid) { overflow-x: auto; }
}

/* --- phone layout */
@media (max-width: 900px) {
  body { font-size: 15.5px; }
  html, body { overflow-x: hidden; }
  .main { padding: 14px 14px 96px; min-width: 0; max-width: 100vw; }
  .shell, .page, .card, .stack, .grid { min-width: 0; }
  .page-head { margin-bottom: 12px; gap: 10px; }
  .page-head .actions { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .page-head .actions .btn { width: 100%; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .page-head .actions .btn:only-child { grid-column: 1 / -1; }
  .card-body, .card-pad { padding: 14px; }
  .card-head { padding: 12px 14px; }
  .card + .card, .stack > * + * { margin-top: 12px; }
  .grid { gap: 12px; }
  /* filters fold away behind one button */
  .filters { display: none; margin-bottom: 12px; }
  .filters.open { display: grid; grid-template-columns: 1fr; gap: 10px; background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 14px; }
  .filters.open .field, .filters.open .field.grow { min-width: 0; width: 100%; }
  .filter-toggle { display: inline-flex !important; }
  .seg { width: 100%; }
  .seg button { flex: 1; padding: 10px 6px; font-size: 14px; }
  .tabs { gap: 0; margin-bottom: 12px; -webkit-overflow-scrolling: touch; }
  .tabs button { padding: 12px 12px; font-size: 14.5px; }
  .modal-foot .btn { flex: 1 1 46%; }
  .modal-foot { position: sticky; bottom: 0; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .kv { grid-template-columns: 1fr; gap: 2px 0; }
  .kv dt { margin-top: 8px; font-size: 12.5px; }
  .aqi-hero .n { font-size: 40px; }
  .do-row { padding: 12px 13px; gap: 11px; }
  .do-row .tx b { font-size: 15.5px; }
  .month-strip .cell { width: 13.5vw; height: 13.5vw; max-width: 44px; max-height: 44px; }
  .report-doc .kpis { grid-template-columns: repeat(2, 1fr); }
  .leaflet-popup-content { min-width: 180px; }
}
.filter-toggle { display: none; }

@media (max-width: 520px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi { padding: 11px 12px; }
  .kpi .value { font-size: 26px; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pair { grid-template-columns: 1fr 1fr; gap: 6px; }
  .action-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  h1 { font-size: 21px; }
}

/* --- bottom bar: five big targets on a phone */
@media (max-width: 900px) {
  .mobile-bar { padding: 5px 4px calc(5px + env(safe-area-inset-bottom)); box-shadow: 0 -2px 10px rgba(16,24,40,.07); }
  .mobile-bar a { font-size: 11px; gap: 3px; padding: 7px 2px; min-height: 54px; justify-content: center; }
  .mobile-bar a.on { color: var(--accent-700); font-weight: 700; }
  .mobile-bar a.log { border-radius: 10px; }
}

/* --- inputs on iOS must be >=16px or the page zooms on focus */
@media (max-width: 900px) {
  .input, .field input, .field select, .field textarea, select.input, textarea.input, .global-search input { font-size: 16px; min-height: 48px; }
  .btn { min-height: 46px; padding: 11px 16px; }
  .btn.sm { min-height: 38px; font-size: 14px; }
  .check input { width: 22px; height: 22px; }
}

/* --- clearer status colours on the compliance grid */
.cgrid td.cell { height: 40px; font-size: 15px; }
.cell.done { box-shadow: inset 0 0 0 1px rgba(20,108,20,.18); }
.cell.missed { box-shadow: inset 0 0 0 1px rgba(159,37,37,.18); }

.help-steps { margin: 0; padding-left: 4px; list-style: none; counter-reset: none; }
.help-steps li { padding: 7px 0 7px 2px; border-bottom: 1px solid var(--line); line-height: 1.5; }
.help-steps li:last-child { border-bottom: 0; }
.help-steps b { color: var(--accent-700); margin-right: 6px; }
.help-list { margin: 0; padding-left: 20px; }
.help-list li { margin-bottom: 7px; line-height: 1.5; }

details.field > summary { padding: 8px 0; font-size: 14px; font-weight: 600; color: var(--accent-700); }
details.field > summary::marker { color: var(--faint); }

/* --- simple progress bar with a readable label */
.bar-line { display: flex; align-items: center; gap: 10px; }
.bar-line .meter { flex: 1; height: 10px; margin: 0; background: var(--surface-3); }
.bar-line .meter > i.lo { background: var(--crit); }
.bar-line .meter > i.mid { background: var(--warn); }
.bar-line .meter > i.hi { background: var(--good); }
.bar-line b { font-variant-numeric: tabular-nums; min-width: 42px; text-align: right; }

/* ---------------------------------------------------------------- print (reports) */
@media print {
  @page { size: A4 landscape; margin: 12mm; }
  body { background: #fff; font-size: 11.5px; }
  .topbar, .sidebar, .mobile-bar, .banner, .no-print, .page-head .actions, #toasts { display: none !important; }
  .shell { display: block; }
  .main { padding: 0; }
  .report-doc { border: 0; padding: 0; max-width: none; }
  .report-doc h2 { page-break-after: avoid; }
  .report-doc section { page-break-inside: avoid; }
  .report-doc .page-break { page-break-before: always; }
  table.data th { background: #f2f2f2 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .badge, .cell, .swatch, .glyph, .kpi { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  a { color: inherit; text-decoration: none; }
}

/* ================================================================ sanitation monitor */
h2.sec { font-size: 16px; margin: 20px 0 10px; }
.good-ink { color: var(--good-ink); font-weight: 600; }
.mono { font-family: var(--mono); }
.window-box { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius); background: var(--surface-3); color: var(--ink-2); margin-bottom: 14px; }
.window-box b { display: block; }
.window-box span { font-size: 13.5px; color: var(--muted); }
.window-box.on { background: var(--accent-soft); color: var(--accent-700); }
.window-box.on.check { background: var(--info-soft); color: var(--info-ink); }
.big-cta { margin-bottom: 6px; text-align: left; }
.big-cta span { display: block; }

.slots { display: inline-flex; gap: 4px; flex: none; }
.slot { font-size: 11.5px; padding: 3px 8px; border-radius: 99px; background: var(--surface-3); color: var(--muted); font-weight: 600; display: inline-flex; gap: 3px; align-items: center; white-space: nowrap; }
.slot.on { background: var(--good-soft); color: var(--good-ink); }
.kind { font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 5px; letter-spacing: .02em; background: #efe7da; color: #6b4e16; }
.kind.fcts { background: #e3ecfb; color: #1c4f9c; }

.fac-list { display: grid; gap: 8px; }
.fac-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); box-shadow: var(--shadow-1); }
.fac-row:hover { text-decoration: none; box-shadow: var(--shadow-2); }
.fac-row .tx { flex: 1; min-width: 180px; display: grid; gap: 2px; }
.fac-row .tx b { font-size: 15.5px; }
.fac-row[hidden] { display: none; }

.fac-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.fac-card { display: grid; gap: 8px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); box-shadow: var(--shadow-1); }
.fac-card:hover { text-decoration: none; box-shadow: var(--shadow-2); border-color: var(--line-strong); }
.fac-card .top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.fac-card .top > span { display: grid; }

.score { display: inline-grid; place-items: center; min-width: 34px; height: 30px; padding: 0 7px; border-radius: 8px; font-weight: 750; font-size: 14px; color: #fff; background: var(--faint); font-variant-numeric: tabular-nums; }
.score.big { min-width: 58px; height: auto; padding: 5px 9px; line-height: 1.1; }
.score.big b { font-size: 20px; }
.score.big small { display: block; font-size: 10.5px; font-weight: 600; opacity: .95; }
.score.good { background: #0c8a0c; } .score.fair { background: #c98a00; } .score.poor { background: #e0632f; } .score.critical { background: #b42323; } .score.new { background: #98a2b3; }

.issue-card { display: flex; gap: 12px; align-items: center; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); box-shadow: var(--shadow-1); }
.issue-card:hover { text-decoration: none; box-shadow: var(--shadow-2); }
.issue-card .tx { flex: 1; min-width: 0; display: grid; gap: 3px; }
.issue-card .tx > span { font-size: 13.5px; color: var(--ink-2); }
.issue-card .go { color: var(--faint); }
img.thumb, .ph-missing.thumb { width: 84px; height: 64px; object-fit: cover; border-radius: 8px; flex: none; background: var(--surface-3); }
.ph-missing { display: grid; place-items: center; text-align: center; font-size: 12px; color: var(--muted); background: var(--surface-3); border-radius: 8px; min-height: 90px; padding: 8px; }
.ph-missing.thumb { min-height: 0; font-size: 10px; }
img.zoomable { cursor: zoom-in; }

.ref-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.ref-grid.sm { grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); }
.ref-grid img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 8px; display: block; background: var(--surface-3); }
.ref-grid figure { margin: 0; }
.ref-item { position: relative; }
.ref-item .icon-btn { position: absolute; top: 4px; right: 4px; background: rgba(255,255,255,.9); width: 26px; height: 26px; }
.ref-strip > div { display: flex; gap: 6px; overflow-x: auto; margin-top: 4px; }
.ref-strip img { height: 64px; border-radius: 6px; }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.photo-card { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.photo-card img, .photo-card .ph-missing { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; border-radius: 0; }
.photo-card figcaption { padding: 8px 10px; display: grid; gap: 4px; font-size: 13px; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pair figure { margin: 0; }
.pair img, .pair .ph-missing { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 8px; display: grid; }
.pair figcaption { font-size: 12.5px; color: var(--muted); margin-top: 4px; }

.shot-preview { display: grid; gap: 6px; justify-items: start; }
.shot-preview img { width: 100%; max-height: 420px; object-fit: contain; background: #0b0f14; border-radius: 10px; }
.action-grid.two { grid-template-columns: 1fr 1fr; }
.action-tile.verdict-clean[aria-pressed="true"] { border-color: var(--good); background: var(--good-soft); box-shadow: 0 0 0 1px var(--good); }
.action-tile.verdict-dirty[aria-pressed="true"] { border-color: var(--crit); background: var(--crit-soft); box-shadow: 0 0 0 1px var(--crit); }
.action-tile svg { vertical-align: -3px; }
.action-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 4px 12px; max-height: 220px; overflow: auto; padding: 4px 0; }

.cal30 { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 5px; }
.cal30 .day { aspect-ratio: 1; border: 0; border-radius: 7px; font: 600 12px var(--font); color: #fff; cursor: pointer; background: var(--faint); }
.cal30 .day.clean { background: #0ca30c; } .cal30 .day.not_clean { background: #d03b3b; } .cal30 .day.no_check { background: #ec835a; }
.cal30 .day.missed { background: #7d1d1d; } .cal30 .day.pending { background: #c3c9d1; color: var(--ink-2); }
.cal30 .day.sel { outline: 3px solid var(--ink); outline-offset: 1px; }
.legend-inline { display: flex; flex-wrap: wrap; gap: 6px; }

.score-parts { margin: 0; display: grid; gap: 4px; }
.score-parts dt { font-size: 13px; font-weight: 600; margin-top: 6px; }
.score-parts dt span { font-weight: 400; color: var(--muted); font-size: 12px; margin-left: 4px; }
.score-parts dd { margin: 0; display: flex; gap: 8px; align-items: center; }
.score-parts dd i { display: block; height: 8px; border-radius: 99px; background: var(--accent); max-width: 100%; }
.score-parts dd::before { content: ''; }
.score-parts dd b { font-size: 12.5px; margin-left: auto; }

.status-grid th, .status-grid td { text-align: center; padding: 4px 3px; min-width: 30px; }
.status-grid td.hname { text-align: left; white-space: nowrap; padding-right: 10px; }
.gcell { font-weight: 700; color: #fff; display: inline-grid; place-items: center; min-width: 26px; height: 26px; border-radius: 6px; }
td.gcell { display: table-cell; border: 2px solid var(--surface); }
.gcell.clean { background: #0ca30c; } .gcell.not_clean { background: #d03b3b; } .gcell.no_check { background: #ec835a; } .gcell.missed { background: #7d1d1d; } .gcell.pending { background: #e4e7ec; color: var(--muted); }

.sample.done { opacity: .82; }
.sample-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.sample-cols h4 { margin: 0 0 6px; font-size: 13px; color: var(--muted); }

.annot-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.annot-tools .seg { width: auto; }
.annot-tools .dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; vertical-align: 0; }
.annot-canvas canvas { width: 100%; height: auto; display: block; border-radius: 8px; touch-action: none; cursor: crosshair; }

.fac-pin div { width: 24px; height: 24px; border-radius: 50%; border: 2.5px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.45); color: #fff; font: 800 11px/19px var(--font); text-align: center; }
.timeline .thumb { margin-top: 6px; }

@media (max-width: 900px) {
  .sample-cols { grid-template-columns: minmax(0, 1fr); }
  .fac-row .slots { order: 3; }
  .pair { grid-template-columns: 1fr 1fr; }
}

.photo-card figcaption .badge, .photo-card figcaption .btn { justify-self: start; }
.capture .ref-strip img { height: 48px; }
.capture .shutter-row { position: sticky; bottom: 0; background: var(--surface); padding: 4px 0; }
.cal30 .day.na { background: var(--surface-3); color: var(--faint); cursor: default; }
.gcell.na { background: var(--surface-2); }

/* ================================================================ all-device polish */
img, video, canvas { max-width: 100%; }
.topbar { padding-left: max(12px, env(safe-area-inset-left)); padding-right: max(12px, env(safe-area-inset-right)); }
.seg > a.btn { border-radius: 0; border: 0; border-right: 1px solid var(--line); box-shadow: none; }
.seg > a.btn:last-child { border-right: 0; }
.seg > a.btn.primary { background: var(--accent); color: #fff; }

/* tracker */
.tracker-days tr.sel td { background: var(--accent-soft); }
.up-yes { display: flex; gap: 8px; align-items: center; }
.up-yes > span { display: grid; gap: 1px; }
.up-yes b { color: var(--good-ink); font-size: 13.5px; }
.up-no { color: var(--crit-ink); font-weight: 650; font-size: 13.5px; display: inline-flex; gap: 4px; align-items: center; }
img.mini { width: 52px; height: 40px; object-fit: cover; border-radius: 6px; flex: none; }
.tracker-days .bar-line { min-width: 120px; }

/* the status grid scrolls sideways with the site names pinned */
.status-grid thead th.row-head, .status-grid td.hname { position: sticky; left: 0; background: var(--surface); z-index: 1; box-shadow: 1px 0 0 var(--line); }
.status-grid td.hname { max-width: 46vw; overflow: hidden; text-overflow: ellipsis; }

/* tablets */
@media (min-width: 761px) and (max-width: 1100px) {
  .sample-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fac-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* phones */
@media (max-width: 760px) {
  .modal-backdrop .modal.wide:has(.capture) { max-height: 100dvh; height: 100dvh; border-radius: 0; }
  .viewfinder { max-height: calc(100dvh - 300px); min-height: 180px; }
  .capture .shutter { width: 68px; height: 68px; }
  .fac-row { padding: 11px 12px; }
  .fac-row .tx { min-width: 0; flex-basis: 100%; }
  .issue-card { align-items: flex-start; }
  img.thumb, .ph-missing.thumb { width: 72px; height: 56px; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ref-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ref-grid.sm { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cal30 { grid-template-columns: repeat(7, minmax(0, 1fr)); }
  .action-bar .btn { flex: 1 1 46%; }
  .tracker-table td:first-child { padding-bottom: 2px; }
  .big-cta { font-size: 17px; padding: 15px; }
  .window-box { padding: 10px 12px; }
  .card-head { flex-wrap: wrap; gap: 6px; }
  .legend-inline .badge { font-size: 11px; }
  .page-head .actions .seg { grid-column: 1 / -1; }
}

/* small phones (320–375 px) */
@media (max-width: 380px) {
  body { font-size: 15px; }
  .main { padding: 12px 10px 92px; }
  .brand-text b { font-size: 14px; }
  .kpi .value { font-size: 22px; }
  .kpi .label { font-size: 12px; }
  .action-grid.two { grid-template-columns: 1fr; }
  .slot { padding: 3px 6px; font-size: 11px; }
  .mobile-bar a { font-size: 10.5px; }
  .gallery { grid-template-columns: minmax(0, 1fr); }
  .pair { grid-template-columns: 1fr; }
  .score.big b { font-size: 17px; }
}

/* phones held sideways: keep the shutter on screen */
@media (max-height: 500px) and (orientation: landscape) {
  .viewfinder { max-height: calc(100dvh - 140px); aspect-ratio: auto; }
  .capture .ref-strip { display: none; }
  .mobile-bar a { min-height: 44px; padding: 3px 2px; }
}
@media (max-width: 760px) {
  .card-head .meta { flex-wrap: wrap; min-width: 0; max-width: 100%; }
  .card-head .meta .badge, .sample .badge.outline { white-space: normal; text-align: left; }
  .card-head h3 { min-width: 0; overflow-wrap: anywhere; }
}
.seg > a.btn { flex: 1 1 auto; min-width: 0; justify-content: center; text-align: center; }
@media (max-width: 760px) { .seg > a.btn { padding-left: 8px; padding-right: 8px; white-space: normal; line-height: 1.2; } }


/* ================================================================ SIMS look (sims.longding.tech) */
body { font-size: 15px; letter-spacing: -.003em; }
h1 { font-weight: 700; letter-spacing: -.02em; }
h2, h3 { font-weight: 650; letter-spacing: -.01em; }
.card, .kpi, .fac-card, .fac-row, .issue-card, .do-row, .photo-card, .empty { border-radius: var(--radius); border-color: var(--line); box-shadow: var(--shadow-1); }
.card-head { border-bottom-color: var(--line); }
.btn { border-radius: 10px; font-weight: 600; font-size: 14px; border-color: var(--line-strong); }
.btn:focus-visible { box-shadow: 0 0 0 3px var(--accent-ring); outline: none; }
.btn.primary { background: var(--accent); border-color: transparent; box-shadow: var(--shadow-1); }
.btn.primary:hover { background: var(--accent-700); }
.btn.lg { border-radius: 10px; font-size: 15.5px; }
.input, .field input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]), .field select, .field textarea, select.input, textarea.input {
  border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); transition: border-color .15s, box-shadow .15s; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent-500); box-shadow: 0 0 0 3px var(--accent-ring); outline: none; }
.input::placeholder, .field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field > span, .field > label.lbl { color: var(--muted); font-size: 12.8px; font-weight: 600; }
.badge { border-radius: 999px; font-weight: 600; font-size: 11.5px; padding: 3px 9px; }
.seg { border-radius: 10px; border-color: var(--line-strong); }
.modal { border-radius: 16px; }
.toast { border-radius: 12px; }

.topbar { background: rgba(255,255,255,.92); backdrop-filter: saturate(160%) blur(8px); }
.brand-mark { width: 36px; height: 36px; border-radius: 11px; background: var(--accent); box-shadow: var(--shadow-1); }
.brand-text b { font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
.sidebar { background: var(--surface); border-right-color: var(--line); padding: 14px 12px 24px; }
.nav-group > span { color: var(--faint); font-size: 11px; letter-spacing: .07em; padding: 0 12px 6px; }
.nav-link { font-size: 14.5px; font-weight: 550; color: var(--ink-2); border-radius: 10px; padding: 9px 12px; }
.nav-link:hover { background: var(--surface-2); }
.nav-link.active { background: var(--accent-soft); color: var(--accent-700); font-weight: 650; }
.nav-link.active svg { opacity: 1; }
.nav-link.primary-action { background: var(--accent); border-radius: 12px; font-size: 15px; }
.avatar { background: var(--accent-soft); color: var(--accent-700); }
.top-chip { background: var(--accent-soft); border-color: var(--accent-100); color: var(--accent-700); font-weight: 600; }

.kpi .label { color: var(--muted); font-weight: 600; font-size: 12.8px; }
.kpi .value { letter-spacing: -.02em; font-weight: 700; }
.help-line { background: var(--accent-soft); border: 1px solid var(--accent-100); border-radius: 12px; }
.window-box { border-radius: 12px; border: 1px solid var(--line); background: var(--surface); }
.window-box.on, .window-box.on.check { background: var(--accent-soft); border-color: var(--accent-100); color: var(--accent-700); }
.big-cta { border-radius: 14px; background: linear-gradient(135deg, var(--accent) 0%, var(--accent-700) 100%); box-shadow: 0 10px 20px -8px #2f5fd080; }
.big-cta:hover { background: var(--accent-700); }
.do-row .ic { border-radius: 12px; }
.do-row.accent .ic { background: var(--accent-soft); color: var(--accent-700); }
.mobile-bar a.log { background: var(--accent); }
.mobile-bar a.on { color: var(--accent-700); }
.tabs button[aria-selected="true"] { color: var(--accent-700); border-bottom-color: var(--accent); }
.kind { border-radius: 6px; }
.kind.fcts { background: var(--accent-soft); color: var(--accent-700); }
svg.ic-stroke { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------------------------------------------------------------- split-screen sign-in (like SIMS) */
.auth2 { display: flex; min-height: 100vh; min-height: 100dvh; background: var(--bg); }
.auth2 .brand-pane { position: relative; display: none; width: 50%; flex-direction: column; justify-content: space-between; overflow: hidden;
  background: var(--accent-700); color: #fff; padding: 48px; }
.auth2 .brand-pane .glow { position: absolute; inset: 0; opacity: .3; pointer-events: none;
  background-image: radial-gradient(circle at 20% 20%, rgba(255,255,255,.25), transparent 40%), radial-gradient(circle at 80% 60%, rgba(255,255,255,.18), transparent 45%); }
.auth2 .logo { position: relative; display: flex; align-items: center; gap: 12px; }
.auth2 .logo-tile { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: rgba(255,255,255,.15); backdrop-filter: blur(6px); flex: none; }
.auth2 .logo b { display: block; font-size: 18px; font-weight: 700; }
.auth2 .logo small { display: block; font-size: 12px; color: rgba(255,255,255,.7); }
.auth2 .pitch { position: relative; }
.auth2 .pitch h2 { font-size: 30px; font-weight: 700; line-height: 1.2; letter-spacing: -.02em; color: #fff; }
.auth2 .pitch p { margin-top: 16px; max-width: 28rem; font-size: 14px; line-height: 1.65; color: rgba(255,255,255,.8); }
.auth2 .pitch ul { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 12px; font-size: 14px; }
.auth2 .pitch li { display: flex; align-items: center; gap: 10px; }
.auth2 .pitch li svg { color: rgba(255,255,255,.8); flex: none; }
.auth2 .foot { position: relative; font-size: 12px; color: rgba(255,255,255,.6); }
.auth2 .form-pane { flex: 1; display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.auth2 .form-box { width: 100%; max-width: 24rem; }
.auth2 .form-box.wide { max-width: 34rem; }
.auth2 .mobile-logo { margin-bottom: 32px; }
.auth2 .mobile-logo .logo-tile { background: var(--accent); color: #fff; margin-bottom: 12px; }
.auth2 .mobile-logo b { font-size: 18px; font-weight: 700; }
.auth2 h1 { font-size: 24px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); }
.auth2 .lead { margin-top: 6px; font-size: 14px; color: var(--muted); }
.auth2 form { margin-top: 24px; display: grid; gap: 16px; }
.auth2 .lbl { display: block; color: var(--muted); font-size: 12.8px; font-weight: 600; margin-bottom: 6px; }
.auth2 .ifield { position: relative; }
.auth2 .ifield > svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.auth2 .ifield input { width: 100%; padding: 10px 12px 10px 36px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); font-size: 14.5px; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.auth2 .ifield input.has-eye { padding-right: 40px; }
.auth2 .ifield input:focus { border-color: var(--accent-500); box-shadow: 0 0 0 3px var(--accent-ring); outline: none; }
.auth2 .ifield input::placeholder { color: var(--faint); }
.auth2 .eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 0; background: none; padding: 5px; border-radius: 6px; color: var(--faint); cursor: pointer; display: grid; place-items: center; }
.auth2 .eye:hover { background: var(--surface-2); color: var(--ink); }
.auth2 .hint { display: block; font-size: 12px; color: var(--muted); margin-top: 5px; }
.auth2 .submit { width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 10px; padding: 11px 16px;
  background: var(--accent); color: #fff; font-weight: 600; font-size: 14.5px; cursor: pointer; box-shadow: var(--shadow-1); transition: background .15s; }
.auth2 .submit:hover { background: var(--accent-700); }
.auth2 .submit:disabled { opacity: .6; cursor: wait; }
.auth2 .after { margin-top: 20px; font-size: 12.5px; color: var(--muted); text-align: center; }
.auth2 .grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.auth2 .check { margin-top: 2px; }
@media (min-width: 1024px) { .auth2 .brand-pane { display: flex; } .auth2 .mobile-logo { display: none; } .auth2 .form-pane { width: 50%; flex: none; } }
@media (max-width: 560px) { .auth2 .grid2 { grid-template-columns: 1fr; } .auth2 .form-pane { padding: 36px 20px; align-items: flex-start; } }
