:root {
  --bg: rgba(18, 20, 28, 0.85);
  --fg: #eef;
  --muted: #99a;
  --accent: #d81b49;
  --border: rgba(255, 255, 255, 0.12);
  --yt: #ff0000;
  --tt: #25f4ee;
  --cctv: #ffb020;
}
[data-theme='light'] {
  --bg: rgba(255, 255, 255, 0.9);
  --fg: #111;
  --muted: #556;
  --border: rgba(0, 0, 0, 0.12);
}
/* Colours for SVG labels/lines drawn over the glass panel (must flip with the theme). */
:root {
  --vz-strong: #f1f5f9; --vz-muted: #94a3b8; --vz-sky: #7dd3fc; --vz-sky-line: #38bdf8; --vz-water-line: #e0f2fe;
  --vz-warn: #facc15; --vz-crit: #f97316; --vz-bank: #dc2626; --vz-ground: #e2e8f0; --vz-peak: #fbbf24; --vz-tick: rgba(226, 232, 240, 0.5);
}
[data-theme='light'] {
  --vz-strong: #0f172a; --vz-muted: #334155; --vz-sky: #075985; --vz-sky-line: #0284c7; --vz-water-line: #0c4a6e;
  --vz-warn: #854d0e; --vz-crit: #9a3412; --vz-bank: #991b1b; --vz-ground: #334155; --vz-peak: #92400e; --vz-tick: rgba(15, 23, 42, 0.4);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; font: 14px/1.4 system-ui, sans-serif; color: var(--fg); background: #000; }
#map { position: fixed; inset: 0; }
#appleMap { position: fixed; inset: 0; pointer-events: none; }
#appleMap[hidden] { display: none; }
.g-logo { position: fixed; left: 10px; bottom: 8px; height: 18px; z-index: 3; pointer-events: none; }
.g-copy { position: fixed; left: 82px; bottom: 8px; z-index: 3; font-size: 10px; color: #fff; text-shadow: 0 0 2px #000; pointer-events: none; max-width: 50vw; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-logo[hidden], .g-copy[hidden] { display: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; background: var(--bg); border: 1px solid var(--border); border-radius: 999px; padding: 6px 12px; backdrop-filter: blur(8px); }
button:hover { border-color: var(--accent); }
:focus-visible { outline: 2px solid #0096ff; outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.topbar { position: fixed; top: 12px; left: 12px; display: flex; gap: 8px; align-items: center; z-index: 5; }
.brand { font-weight: 700; font-size: 16px; }
.pill { background: var(--bg); border: 1px solid var(--border); padding: 6px 12px; border-radius: 999px; }

.actions { position: fixed; top: 12px; right: 12px; display: flex; gap: 6px; z-index: 5; flex-wrap: wrap; justify-content: flex-end; }
.actions input { background: var(--bg); border: 1px solid var(--border); border-radius: 999px; padding: 6px 12px; width: 200px; }
#radar.on { border-color: var(--accent); }

.filters { position: fixed; bottom: 12px; left: 12px; right: 12px; z-index: 5; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; pointer-events: none; }
.filters .row { display: flex; gap: 6px; flex-wrap: wrap; pointer-events: auto; }
.chip { opacity: 0.55; }
.chip.on { opacity: 1; border-color: var(--accent); }
.chip .n { color: var(--muted); margin-left: 4px; }
.chip[style*="--sw"]::before { content: ''; display: inline-block; width: 13px; height: 13px; margin-right: 5px; vertical-align: -2px; background: var(--sw) center / contain no-repeat; }
.results { position: fixed; top: 56px; right: 12px; width: 320px; max-height: 50vh; overflow: auto; margin: 0; padding: 4px; list-style: none; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; z-index: 6; }
.results li button { display: block; width: 100%; text-align: left; background: none; border: 0; border-radius: 8px; padding: 8px 10px; }
.results li button:hover { background: rgba(127, 127, 127, 0.2); border-color: transparent; }
.results li.no-results { display: flex; gap: 8px; align-items: center; justify-content: space-between; padding: 10px 12px; color: var(--muted); }
.results li.no-results .linkish { background: none; border: 0; padding: 0; color: #0096ff; text-decoration: underline; }

.cam-view { position: relative; width: 100%; height: 100%; }
.cam-view img { width: 100%; height: 100%; object-fit: contain; }
.cam-stamp { position: absolute; right: 10px; top: 10px; display: flex; flex-direction: column; align-items: flex-end; gap: 1px; padding: 5px 9px; border-radius: 8px; background: rgba(0, 0, 0, 0.82); color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8); font: 600 12px/1.35 var(--font, system-ui); font-variant-numeric: tabular-nums; pointer-events: none; }
.cam-stamp .muted { color: rgba(255, 255, 255, 0.85); font-weight: 400; font-size: 11px; }
.cam-stamp.old { background: rgba(124, 45, 18, 0.95); }
.cam-stamp[hidden] { display: none; }
.cam-offline { width: 100%; height: 100%; min-height: 200px; display: flex; align-items: center; justify-content: center; background: #000; color: #fff; font-size: 16px; }
.offline-pop .maplibregl-popup-content { background: #000; color: #fff; }
.offline-pop.maplibregl-popup-anchor-bottom .maplibregl-popup-tip { border-top-color: #000; }
.offline-pop.maplibregl-popup-anchor-top .maplibregl-popup-tip { border-bottom-color: #000; }
.offline-pop.maplibregl-popup-anchor-left .maplibregl-popup-tip { border-right-color: #000; }
.offline-pop.maplibregl-popup-anchor-right .maplibregl-popup-tip { border-left-color: #000; }
.cam-status { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 10px; align-items: center; justify-content: center; background: rgba(0, 0, 0, 0.75); color: #fff; text-align: center; padding: 16px; }
.cam-status[hidden] { display: none; }
.cam-status button { padding: 8px 18px; }
.results li { padding: 8px; border-radius: 8px; cursor: pointer; }
.results li:hover { background: rgba(127, 127, 127, 0.2); }

.player { position: fixed; right: 12px; bottom: 12px; width: min(560px, calc(100vw - 24px)); background: var(--bg); border: 1px solid var(--border); border-radius: 14px; z-index: 10; overflow: hidden; backdrop-filter: blur(10px); }
.player-head { display: flex; align-items: center; gap: 8px; padding: 8px 10px; }
.player-head strong { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-head button { padding: 2px 10px; }
.player-body { aspect-ratio: 16 / 9; background: #000; display: grid; place-items: center; }
.player-body iframe, .player-body video, .player-body img { width: 100%; height: 100%; border: 0; object-fit: contain; }
.player-meta { padding: 8px 10px; color: var(--muted); font-size: 12px; }
.badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 6px; color: #000; }
.badge.youtube { background: var(--yt); color: #fff; }
.badge.tiktok { background: var(--tt); }
.badge.cctv { background: var(--cctv); }
.badge.gauge { background: #0ea5e9; }

.gauge-rows { padding: 12px 16px; color: #fff; font-size: 13px; }
.gauge-row { display: flex; justify-content: space-between; gap: 16px; padding: 4px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.fr-thumb { width: 44px; height: 44px; padding: 0; border: 2px solid #fff; border-radius: 8px; overflow: hidden; background: #334155; box-shadow: 0 2px 6px rgba(0,0,0,.45); cursor: pointer; }
.fr-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fr-thumb:hover { border-color: #38bdf8; }
.freport-photo { display: block; width: 100%; max-height: 240px; object-fit: cover; border-radius: 10px; cursor: zoom-in; margin-top: 8px; }
/* Canal staff gauge: status pill + threshold-labelled water column. */
.canal-gauge { margin: 10px 0 2px; }
.canal-gauge svg { display: block; width: 100%; height: auto; }
.road-depth { margin: 10px 0 2px; }
.road-depth svg { display: block; width: 100%; height: auto; }
/* Dam detail: storage bar with normal-level tick, inflow vs release. */
.damviz { margin: 10px 0 2px; display: grid; gap: 7px; font-size: 12px; }
.dv-row { display: grid; grid-template-columns: 76px 1fr 92px; gap: 8px; align-items: center; }
.dv-row > .dv-val { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.dv-bar { position: relative; height: 12px; border-radius: 6px; background: rgba(127, 127, 127, 0.25); overflow: hidden; }
.dv-bar.thin { height: 8px; }
.dv-tick { position: absolute; top: 0; bottom: 0; width: 2px; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35); }
.canal-status { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; border: 1px solid; font-weight: 700; font-size: 12px; margin-bottom: 6px; }
.canal-status .dot { width: 8px; height: 8px; border-radius: 50%; }
/* River forecast chart: SVG lines stretched over .rc-plot, HTML labels positioned in % so text never scales. */
.river-chart { position: relative; height: 230px; margin: 10px 0 6px; background: rgba(15, 23, 42, 0.62); border-radius: 8px; color: #cbd5e1; font-size: 11px; line-height: 1.2; user-select: none; }
.rc-plot { position: absolute; left: 52px; right: 10px; top: 22px; bottom: 24px; touch-action: pan-y; cursor: crosshair; }
.rc-plot > svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.rc-plot > span, .rc-plot > div { position: absolute; pointer-events: none; white-space: nowrap; }
.rc-y { right: calc(100% + 6px); transform: translateY(-50%); color: #94a3b8; font-variant-numeric: tabular-nums; }
.rc-unit { right: calc(100% + 6px); top: -18px; color: #94a3b8; font-weight: 600; }
.rc-thr { right: 2px; transform: translateY(-115%); font-weight: 600; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8); }
.rc-region { top: -17px; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.04em; font-size: 10px; }
.rc-x { top: calc(100% + 6px); transform: translateX(-50%); color: #94a3b8; }
.rc-x.now { color: #f1f5f9; font-weight: 700; }
.rc-dot { width: 9px; height: 9px; border-radius: 50%; transform: translate(-50%, -50%); background: #38bdf8; box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.9); }
.rc-dot.now { background: #f1f5f9; }
.rc-dot.worst { background: #7dd3fc; }
.rc-tag { transform: translate(-50%, calc(-100% - 8px)); padding: 2px 6px; border-radius: 6px; background: rgba(15, 23, 42, 0.88); color: #f1f5f9; font-weight: 600; font-variant-numeric: tabular-nums; }
.rc-tag.flip { transform: translate(-90%, calc(-100% - 8px)); }
.rc-tag.worst { color: #7dd3fc; }
.rc-tag.now, .rc-tag.worst { transform: translate(-50%, 10px); }
.rc-tag.now.flip, .rc-tag.worst.flip { transform: translate(-90%, 10px); }
.rc-cross { top: 0; bottom: 0; width: 1px; background: rgba(241, 245, 249, 0.55); }
.rc-tip { top: 4px; transform: translateX(10px); padding: 6px 8px; border-radius: 8px; background: #020617; color: #e2e8f0; font-size: 12px; line-height: 1.45; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4); z-index: 5; }
.rc-tip.flip { transform: translateX(calc(-100% - 10px)); }
.rc-tip .muted { color: #94a3b8; }
@media (max-width: 700px) { .river-chart { height: 210px; font-size: 10px; } .rc-plot { left: 44px; } }
.near-cams { margin-top: 12px; display: grid; gap: 6px; }
.near-cams button { text-align: left; padding: 8px 10px; border-radius: 8px; border: 1px solid rgba(255, 255, 255, 0.15); background: rgba(255, 255, 255, 0.06); color: #fff; cursor: pointer; }
.near-cams button:hover { background: rgba(255, 255, 255, 0.14); }

button.primary { background: var(--accent); color: #fff; border-color: transparent; font-weight: 600; }

.forecast-strip { position: fixed; top: 56px; left: 12px; max-width: min(640px, calc(100vw - 24px)); background: var(--bg); border: 1px solid #7c3aed; border-radius: 10px; padding: 6px 12px; z-index: 5; font-size: 12px; backdrop-filter: blur(8px); }
.forecast-strip[hidden] { display: none; }
.dams { position: fixed; top: 100px; left: 12px; width: 240px; max-height: min(42vh, calc(100vh - 300px)); overflow: auto; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; z-index: 5; backdrop-filter: blur(10px); }
.dams[hidden] { display: none; }
.dams .panel-head { padding: 6px 10px; }
.dam-list { display: flex; flex-direction: column; padding: 4px; }
.dam-row { display: grid; grid-template-columns: 96px 1fr 48px; gap: 6px; align-items: center; background: none; border: 0; border-radius: 6px; padding: 3px 6px; font-size: 12px; color: var(--fg); text-align: left; backdrop-filter: none; }
.dam-row:hover { background: rgba(127, 127, 127, 0.2); }
.dam-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dam-bar { height: 8px; border-radius: 4px; background: rgba(127, 127, 127, 0.25); overflow: hidden; }
.dam-fill { display: block; height: 100%; }
.dam-val { text-align: right; font-variant-numeric: tabular-nums; }
.sources-btn { position: fixed; right: 12px; bottom: 12px; z-index: 6; font-size: 12px; }
.player:not([hidden]) ~ .sources-btn { display: none; }
.sources { top: auto; bottom: 52px; }
.sources-list { margin: 0; padding: 0 0 0 16px; display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.sources-list a { color: #38bdf8; }
.sources-list .stale { color: #f59e0b; }
.sources-list .fresh { color: var(--muted); }
.social-btn { position: fixed; right: 112px; bottom: 12px; z-index: 6; font-size: 12px; }
.player:not([hidden]) ~ .social-btn { display: none; }
.social { top: auto; bottom: 52px; width: min(420px, calc(100vw - 24px)); max-height: min(70vh, calc(100vh - 120px)); overflow-x: hidden; overflow-wrap: anywhere; }
.social .panel-body { padding: 8px 12px; }
.social-tabs, .social-out { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0; }
.social-tabs button, .social-out a { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); background: none; color: var(--fg); text-decoration: none; cursor: pointer; }
.social-tabs button.on { background: var(--accent); color: #fff; border-color: transparent; }
.social-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.social-list li a { display: grid; grid-template-columns: 22px 1fr; gap: 6px; padding: 6px; border-radius: 8px; color: var(--fg); text-decoration: none; font-size: 13px; }
.social-list li a:hover { background: rgba(127, 127, 127, 0.18); }
.social-list .meta { font-size: 11px; color: var(--muted); }
.social-list .new { color: #22c55e; font-weight: 700; }
@media (max-width: 1250px), (pointer: coarse) and (max-width: 1400px) { .dams { display: none; } }
.avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
#account img { width: 22px; height: 22px; border-radius: 50%; vertical-align: middle; margin: -4px 4px -4px -4px; }

.panel { position: fixed; top: 56px; right: 12px; width: min(380px, calc(100vw - 24px)); max-height: calc(100vh - 80px); overflow: auto; background: var(--bg); border: 1px solid var(--border); border-radius: 14px; z-index: 8; backdrop-filter: blur(10px); }
.panel-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.panel-head strong { flex: 1; }
.panel-head button { padding: 2px 10px; }
.panel-body { padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.panel label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.panel input:not([type=checkbox]), .panel select, .panel textarea { background: rgba(127,127,127,0.12); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; color: var(--fg); }
.panel .two { display: grid; grid-template-columns: 2fr 1fr; gap: 8px; }
.loc { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 13px; }
.loc span { flex: 1 1 100%; color: var(--muted); }
.muted { color: var(--muted); font-weight: normal; }
.small { font-size: 12px; margin: 0; }
.error { color: #ff6b6b; margin: 0; font-size: 13px; }
.pin-hint { position: fixed; top: 60px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; padding: 8px 16px; border-radius: 999px; z-index: 9; font-weight: 600; display: flex; align-items: center; gap: 10px; }
.pin-hint[hidden] { display: none; }
.pin-hint button { background: #fff; color: #111; border: 0; border-radius: 999px; padding: 4px 12px; font-weight: 600; cursor: pointer; }
body.picking #map { cursor: crosshair; }

.mine { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.mine li { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; padding: 8px; border: 1px solid var(--border); border-radius: 8px; font-size: 13px; }
.mine li .t { cursor: pointer; font-weight: 600; }
.mine li .m { color: var(--muted); font-size: 12px; grid-column: 1; }
.mine li .b { grid-row: 1 / span 2; display: flex; gap: 4px; align-items: center; }
  /* Drop the results panel below the full toolbar so it never overlaps the action buttons. */
  .results { left: 12px; right: 12px; width: auto; top: 118px; }
.mine li .b button { padding: 2px 8px; }
.verified { color: #3ddc84; }

.tt-card { text-align: center; padding: 24px; color: #fff; }
.tt-card a { display: inline-block; margin-top: 12px; padding: 10px 18px; border-radius: 999px; background: linear-gradient(90deg, #25f4ee, #fe2c55); color: #000; font-weight: 700; text-decoration: none; }
.cam-offline { flex-direction: column; gap: 6px; }
.cam-offline small { opacity: 0.7; font-size: 13px; }
.cam-report { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; padding: 4px 8px; font-size: 12px; }
.cam-report button { font-size: 12px; padding: 3px 8px; background: none; border: 1px solid var(--border); border-radius: 6px; color: inherit; opacity: 0.75; cursor: pointer; }
.cam-report button:hover { opacity: 1; }
.cam-report span { opacity: 0.8; }
.tt-link { display: block; text-align: right; padding: 4px 8px; font-size: 12px; color: #9cc3ff; }

@media (max-width: 1250px), (pointer: coarse) and (max-width: 1400px) {
  .actions input { width: 130px; }
  .player { left: 12px; right: 12px; width: auto; bottom: 110px; }
}

/* Contact panel feedback form */
.feedback-form { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; padding-top: 12px; border-top: 1px solid var(--border); }
.feedback-form textarea { resize: vertical; min-height: 84px; font: inherit; }
.feedback-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.feedback-form .ok { color: #34c759; margin: 0; }
.feedback-form .error { margin: 0; }

/* Type scale matches the other panels: 14px/600 headings, 13px body, 12px meta. */
.ai-headline { margin: 0; font-weight: 600; font-size: 14px; line-height: 1.4; letter-spacing: -0.01em; }
.ai-bullets { margin: 8px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; line-height: 1.4; }
#aiMeta.stale { color: #f59e0b; }
.sub-form select { font: inherit; }
.sub-form a { color: var(--tint, #38bdf8); }
.ai-alert { border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; background: color-mix(in srgb, var(--lv) 16%, transparent); border: 1px solid color-mix(in srgb, var(--lv) 55%, transparent); }
.ai-alert strong { display: block; font-size: 13px; font-weight: 600; }
.ai-scale { display: flex; gap: 4px; margin: 7px 0 2px; }
.ai-scale i { flex: 1; height: 6px; border-radius: 3px; background: rgba(127, 127, 127, 0.25); }
.ai-scale i.on { background: var(--lv); }
.ai-why { margin: 6px 0 0; padding-left: 18px; font-size: 12px; line-height: 1.4; }

/* Top-left stack: AI summary card, then the (collapsed-by-default) rain & flood outlook. */
.tl-stack { position: fixed; top: 76px; left: 16px; z-index: 5; width: min(380px, calc(100vw - 24px)); max-height: calc(100vh - 160px); overflow: auto; display: flex; flex-direction: column; gap: 8px; pointer-events: none; scrollbar-width: none; }
.tl-stack > * { pointer-events: auto; }
.tl-stack > .panel { position: static; inset: auto; width: auto; max-width: none; max-height: none; transform: none; }
.ai-panel .panel-head { gap: 6px; }
.ai-panel .panel-head .ai-more { margin-left: auto; width: auto; min-width: 0; height: auto; white-space: nowrap; border-radius: 999px; font-size: 12px; padding: 4px 10px; }
.ai-panel.compact .ai-bullets, .ai-panel.compact .ai-why, .ai-panel.compact .sub-form, .ai-panel.compact .panel-body > p:last-child { display: none; }
.ai-panel.compact .panel-body { padding-top: 8px; padding-bottom: 8px; gap: 6px; }
.ai-panel.compact .ai-headline { font-size: 13px; }
.ai-panel.compact .ai-alert { margin-bottom: 6px; padding: 7px 10px; }
@media (max-width: 700px) {
  .tl-stack { top: 124px; left: 8px; right: 8px; width: auto; max-height: 45vh; }
}
.ai-prov { display: flex; gap: 6px; align-items: stretch; }
.ai-prov select { flex: 1; min-width: 0; font: inherit; font-size: 13px; }
.ai-panel .ai-prov #aiLoc { flex: none; width: 42px; height: auto; min-height: 0; padding: 0; margin: 0; display: grid; place-items: center; border-radius: var(--r-row, 10px); background: var(--glass-hover, rgba(127,127,127,0.12)); border: 0.5px solid var(--glass-edge, rgba(127,127,127,0.3)); box-shadow: none; color: var(--fg); }
.ai-panel .ai-prov #aiLoc:hover { color: var(--tint, #38bdf8); }
.ai-panel.compact .ai-prov select { font-size: 13px; }

/* Corner buttons: only AI summary, Flood chatter and Rain & flood until "⋯" is tapped. */
.corner-btns:not(.expanded) > .corner-extra { display: none; }
.corner-btns > .more-btn { min-width: 36px; font-weight: 700; }

/* Rain & flood outlook: a bottom-right panel like Legend / Sources, same type scale as the other panels. */
#forecast { top: auto; left: auto; right: 14px; bottom: 58px; width: min(380px, calc(100vw - 24px)); max-width: none; max-height: calc(100vh - 140px); font-size: 13px; z-index: 8; }
#forecast .fc-title { font-size: 14px; }
#forecast .fc-official { font-size: 13px; }
#forecast .fc-label, #forecast .fc-meta, #forecast .fc-risk, #forecast .fc-more { font-size: 12px; }
@media (max-width: 700px) {
  #forecast { top: auto; left: 8px; right: 8px; bottom: 8px; width: auto; max-height: 75vh; }
}
.sub-form[hidden] { display: none; }
