/* LowVoltCalc — one stylesheet for every page.
   Tokens first: every colour, size and radius a page uses is defined here,
   so a new calculator matches by using the components below, never by
   restating values. Dark is the original palette; light is the same palette
   re-inked for direct sun. The theme follows the phone unless the visitor
   picks one (html[data-theme]). */

@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/assets/fonts/plex-sans-var.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/assets/fonts/plex-mono-400.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 600; font-display: swap;
  src: url(/assets/fonts/plex-mono-600.woff2) format("woff2"); }

:root {
  /* Type */
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --fs-xs: 12px;   /* fine print, sources */
  --fs-sm: 14px;   /* labels, secondary */
  --fs-md: 16px;   /* body, inputs (16px stops iOS zooming on focus) */
  --fs-lg: 19px;   /* lede */
  --fs-xl: 24px;   /* section heads */
  --fs-2xl: 34px;  /* readout figure */
  --fs-3xl: clamp(30px, 6vw, 48px); /* page title */

  /* Space: a 4px grid */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px;
  --gutter: 16px;
  --measure: 68ch;
  --tap: 48px;           /* minimum touch target */
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px;
  --maxw: 1080px;

  /* Colour: dark (the original look) */
  --bg: #0c1116;
  --panel: #121a21;
  --inset: #0c1116;
  --line: #22303b;
  --line-strong: #33475a;
  --grid: rgba(120, 170, 200, 0.06);
  --text: #e6edf2;
  --dim: #8a9aa7;
  --amber: #f5b400;       /* brand + primary action fill */
  --amber-ink: #f5b400;   /* amber used as text */
  --on-amber: #111111;
  --ok: #3ccf8e;
  --warn: #ff8a3d;
  --bad: #ff5a5f;
  --ok-bg: rgba(60, 207, 142, 0.12);
  --warn-bg: rgba(255, 138, 61, 0.12);
  --bad-bg: rgba(255, 90, 95, 0.13);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

/* Light: same hues, darker inks so they hold up in sunlight. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #e8eef2; --panel: #fbfcfd; --inset: #f1f5f8; --line: #c3cfd8; --line-strong: #93a5b3;
    --grid: rgba(20, 70, 110, 0.07); --text: #0c1116; --dim: #45545f;
    --amber-ink: #8a5700; --ok: #0a7a4a; --warn: #a94700; --bad: #c21f2a;
    --ok-bg: #dff3e9; --warn-bg: #fbe9dc; --bad-bg: #fbe1e2;
    --shadow: 0 10px 30px rgba(12, 17, 22, 0.10);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #e8eef2; --panel: #fbfcfd; --inset: #f1f5f8; --line: #c3cfd8; --line-strong: #93a5b3;
  --grid: rgba(20, 70, 110, 0.07); --text: #0c1116; --dim: #45545f;
  --amber-ink: #8a5700; --ok: #0a7a4a; --warn: #a94700; --bad: #c21f2a;
  --ok-bg: #dff3e9; --warn-bg: #fbe9dc; --bad-bg: #fbe1e2;
  --shadow: 0 10px 30px rgba(12, 17, 22, 0.10);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; }
body {
  background:
    linear-gradient(var(--grid) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, var(--grid) 1px, transparent 1px) 0 0 / 24px 24px,
    var(--bg);
  color: var(--text);
  font: 400 var(--fs-md)/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--amber-ink); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; border-radius: 4px; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: var(--gutter); top: var(--s2); background: var(--panel); padding: var(--s2) var(--s3); z-index: 10; }
.num, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* ---------- Header ---------- */
.site-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s4) 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 600 18px var(--mono); letter-spacing: 0.3px; color: var(--text); text-decoration: none; min-height: var(--tap); }
.brand svg { width: 30px; height: 30px; flex: none; }
.brand b { color: var(--amber-ink); font-weight: 600; }
.head-tools { display: flex; align-items: center; gap: var(--s2); }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-width: var(--tap); min-height: var(--tap); padding: 0 var(--s3);
  background: transparent; color: var(--text); border: 1px solid var(--line); border-radius: var(--r-sm);
  font: 600 var(--fs-sm) var(--sans); cursor: pointer; text-decoration: none;
}
.icon-btn svg { width: 20px; height: 20px; }
.nav-menu { position: relative; }
.nav-menu > summary { list-style: none; }
.nav-menu > summary::-webkit-details-marker { display: none; }
.nav-menu[open] > summary { border-color: var(--line-strong); }
.nav-list {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; min-width: 250px;
  margin: 0; padding: var(--s2); list-style: none;
  background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--r-md); box-shadow: var(--shadow);
}
.nav-list a { display: flex; align-items: center; min-height: var(--tap); padding: 0 var(--s3); border-radius: var(--r-sm); color: var(--text); text-decoration: none; }
.nav-list a[aria-current="page"] { background: var(--inset); color: var(--amber-ink); font-weight: 600; }

/* ---------- Page title ---------- */
.page-head { padding: var(--s2) 0 var(--s4); }
h1 { font-size: var(--fs-3xl); line-height: 1.08; letter-spacing: -0.02em; margin: 0 0 var(--s2); font-weight: 700; }
.lede { color: var(--dim); font-size: var(--fs-lg); margin: 0; max-width: 40em; }
.page-head .lede { font-size: var(--fs-md); }

/* ---------- Calculator shell ----------
   Phone: the result sits above the inputs and scrolls away with the page;
   the fixed result bar (below) carries the answer while you edit inputs.
   Wide: inputs left, result right, sticky. */
.calc {
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 0;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow);
  margin-bottom: var(--s6);
}
.calc > * { min-width: 0; }
.readout {
  background: var(--panel); border-bottom: 1px solid var(--line);
  border-radius: var(--r-lg) var(--r-lg) 0 0; padding: var(--s4);
}
.inputs { padding: var(--s4); }
@media (min-width: 900px) {
  .calc { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
  .calc .inputs { order: 1; border-right: 1px solid var(--line); padding: var(--s5); }
  /* Sticky beside the inputs. It never changes size in response to scrolling. */
  .calc .readout { order: 2; position: sticky; top: var(--s4); z-index: 5; align-self: start; border-bottom: 0; border-radius: 0 var(--r-lg) 0 0; padding: var(--s5); }
}

/* The meter: one big figure, its status in words and colour. */
.meter { display: flex; align-items: baseline; flex-wrap: wrap; gap: var(--s1) var(--s3); }
.meter-figure { font: 600 var(--fs-2xl)/1.05 var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.meter-label { color: var(--dim); font-size: var(--fs-sm); }
.meter-range { font: 400 var(--fs-sm) var(--mono); color: var(--dim); }
.status {
  display: flex; align-items: flex-start; gap: var(--s2); margin-top: var(--s3);
  padding: var(--s2) var(--s3); border-radius: var(--r-sm); font-size: var(--fs-sm); font-weight: 600;
  background: var(--inset); color: var(--dim); border-left: 4px solid var(--line-strong);
}
.status[data-state="ok"] { background: var(--ok-bg); color: var(--ok); border-left-color: var(--ok); }
.status[data-state="warn"] { background: var(--warn-bg); color: var(--warn); border-left-color: var(--warn); }
.status[data-state="bad"] { background: var(--bad-bg); color: var(--bad); border-left-color: var(--bad); }
.status .glyph { flex: none; font-family: var(--mono); }
.gauge { height: 6px; background: var(--inset); border-radius: 99px; margin-top: var(--s3); overflow: hidden; }
.gauge > span { display: block; height: 100%; width: 0; background: var(--ok); transition: width .25s, background-color .25s; }
.gauge[data-state="warn"] > span { background: var(--warn); }
.gauge[data-state="bad"] > span { background: var(--bad); }

/* Secondary figures under the meter */
.figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: var(--s3) var(--s4); margin: var(--s4) 0 0; }
.figs > div { min-width: 0; }
.figs dt { color: var(--dim); font-size: var(--fs-xs); }
.figs dd { margin: 2px 0 0; font: 600 18px var(--mono); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.figs dd small { font: 400 var(--fs-xs) var(--mono); color: var(--dim); }
/* On a phone the sticky readout must not eat the screen: secondary figures fold behind a toggle. */
.more-toggle { display: inline-flex; align-items: center; min-height: 40px; margin-top: var(--s2); padding: 0; background: none; border: 0; color: var(--amber-ink); font: 600 var(--fs-sm) var(--sans); cursor: pointer; }
@media (max-width: 899px) { .readout:not(.expanded) .extra { display: none; } }
@media (min-width: 900px) { .more-toggle { display: none; } }

/* ---------- Fields ---------- */
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4) var(--s3); }
.fields > * { min-width: 0; }
.fields .full { grid-column: 1 / -1; }
.field label, .field .label { display: block; font-size: var(--fs-sm); font-weight: 600; color: var(--dim); margin-bottom: 6px; }
.field .hint { display: block; font-size: var(--fs-xs); color: var(--dim); margin-top: 6px; }
.input-wrap { position: relative; display: flex; }
.input-wrap .unit { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--dim); font: 400 var(--fs-sm) var(--mono); pointer-events: none; }
.input-wrap input { padding-right: 52px; }
input, select, textarea {
  width: 100%; min-height: var(--tap);
  background: var(--inset); color: var(--text); border: 1px solid var(--line-strong); border-radius: var(--r-sm);
  padding: 10px 12px; font: 600 var(--fs-md) var(--mono); font-variant-numeric: tabular-nums;
}
input[type="text"]:not([inputmode]), select { font-family: var(--sans); }
select { appearance: none; -webkit-appearance: none; padding-right: 36px;
  background-image: linear-gradient(45deg, transparent 50%, var(--dim) 50%), linear-gradient(135deg, var(--dim) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
input:focus, select:focus { outline: 2px solid var(--amber); outline-offset: 1px; border-color: transparent; }
input[aria-invalid="true"] { border-color: var(--bad); }

/* Segmented choice (units, modes): real radio buttons, big targets. */
.seg { display: flex; flex-wrap: wrap; gap: 0; border: 1px solid var(--line-strong); border-radius: var(--r-sm); overflow: hidden; background: var(--inset); }
.seg label { flex: 1 1 auto; margin: 0; display: flex; }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.seg span { flex: 1; display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 var(--s3);
  font: 600 var(--fs-sm) var(--sans); color: var(--dim); cursor: pointer; text-align: center; border-left: 1px solid var(--line); }
.seg label:first-child span { border-left: 0; }
.seg input:checked + span { background: var(--amber); color: var(--on-amber); }
.seg input:focus-visible + span { outline: 2px solid var(--amber); outline-offset: -3px; }

.check { display: flex; align-items: center; gap: var(--s3); min-height: var(--tap); font-weight: 600; cursor: pointer; }
.check input { width: 22px; height: 22px; min-height: 0; accent-color: var(--amber); flex: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s2);
  min-height: var(--tap); padding: 0 var(--s4); border-radius: var(--r-sm); border: 1px solid transparent;
  background: var(--amber); color: var(--on-amber); font: 600 var(--fs-md) var(--sans); text-decoration: none; cursor: pointer;
}
.btn.ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn.small { min-height: 40px; font-size: var(--fs-sm); padding: 0 var(--s3); }
.btn.danger { background: transparent; color: var(--bad); border-color: var(--line-strong); }
.actions { display: flex; flex-wrap: wrap; gap: var(--s2); margin-top: var(--s4); }
.toast { font-size: var(--fs-sm); color: var(--ok); min-height: 1.5em; margin: var(--s2) 0 0; }

/* ---------- Groups / rows (camera groups, PoE devices, battery loads) ---------- */
.group { border: 1px solid var(--line); border-radius: var(--r-md); background: var(--inset); padding: var(--s4); margin-bottom: var(--s3); }
.group-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); margin-bottom: var(--s3); }
.group-head h3 { margin: 0; font-size: var(--fs-md); }
.group-sub { color: var(--dim); font: 400 var(--fs-xs) var(--mono); }
.group .fields { gap: var(--s3); }
.group input, .group select { background: var(--panel); }
.row-flag { margin-top: var(--s2); font-size: var(--fs-sm); font-weight: 600; color: var(--bad); }
.row-flag[data-state="warn"] { color: var(--warn); }
.row-flag:empty { display: none; }
details.adv { margin-top: var(--s3); border-top: 1px dashed var(--line); padding-top: var(--s2); }
details.adv > summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--amber-ink); font-weight: 600; font-size: var(--fs-sm); }
.sub-head { font-size: var(--fs-sm); color: var(--dim); font-weight: 600; margin: var(--s4) 0 var(--s2); }

/* Tables inside results */
.tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: var(--s3) 0; border: 1px solid var(--line); border-radius: var(--r-sm); }
table { border-collapse: collapse; width: 100%; font-size: var(--fs-sm); }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--dim); font-weight: 600; background: var(--inset); }
td.n, th.n { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
tr[data-state="bad"] td { color: var(--bad); }
tr[data-state="warn"] td { color: var(--warn); }

/* ---------- Explainer (the "how this works" text search engines read) ---------- */
.explain { max-width: var(--measure); padding-bottom: var(--s6); }
.explain h2 { font-size: var(--fs-xl); line-height: 1.2; margin: var(--s7) 0 var(--s3); letter-spacing: -0.01em; }
.explain h3 { font-size: var(--fs-md); margin: var(--s5) 0 var(--s2); }
.explain p, .explain li { color: var(--text); }
.explain .formula { font: 400 var(--fs-md) var(--mono); background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--amber); border-radius: var(--r-sm); padding: var(--s3) var(--s4); overflow-x: auto; white-space: pre; }
.explain dl.faq dt { font-weight: 700; margin-top: var(--s4); }
.explain dl.faq dd { margin: var(--s1) 0 0; }
.limits { border: 1px solid var(--line-strong); border-radius: var(--r-md); padding: var(--s3) var(--s4); background: var(--panel); }
.limits h2 { margin-top: 0; }
.sources { font-size: var(--fs-sm); padding-left: 1.2em; }
.sources li { margin-bottom: var(--s2); }
.sources cite { font-style: normal; font-weight: 600; }
.cite { font-size: var(--fs-xs); color: var(--dim); margin: var(--s3) 0 0; }

/* The slot for later gear recommendations and app links: empty and hidden until used. */
.slot:empty { display: none; }

/* ---------- Home ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s5); padding: var(--s4) 0 var(--s6); }
.hero > * { min-width: 0; }
.hero h1 { font-size: clamp(34px, 6.5vw, 56px); letter-spacing: -0.03em; }
@media (min-width: 900px) { .hero { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; gap: var(--s7); padding-top: var(--s6); } }
.tool-list { list-style: none; margin: 0 0 var(--s7); padding: 0; border-top: 1px solid var(--line); }
.tool-list li { border-bottom: 1px solid var(--line); }
.tool-list a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px var(--s4); padding: var(--s4) var(--s1); text-decoration: none; color: var(--text); }
.tool-list .t { font-weight: 700; font-size: var(--fs-lg); }
.tool-list .d { grid-column: 1; color: var(--dim); font-size: var(--fs-sm); }
.tool-list .std { grid-column: 2; grid-row: 1 / span 2; align-self: center; font: 400 var(--fs-xs) var(--mono); color: var(--dim); text-align: right; }
.tool-list a:hover .t, .tool-list a:focus-visible .t { color: var(--amber-ink); }
@media (max-width: 560px) { .tool-list a { grid-template-columns: minmax(0, 1fr); } .tool-list .std { grid-column: 1; grid-row: auto; text-align: left; } }
.section-title { font-size: var(--fs-xl); margin: 0 0 var(--s3); }

/* ---------- Footer ---------- */
.site-foot { border-top: 1px solid var(--line); padding: var(--s5) 0 var(--s7); color: var(--dim); font-size: var(--fs-sm); }
.site-foot .cols { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s3) var(--s5); }
.site-foot a { color: var(--text); }
.site-foot button.linklike { background: none; border: 0; padding: 0; color: var(--text); text-decoration: underline; text-underline-offset: 3px; font: inherit; cursor: pointer; min-height: 0; }

/* ---------- Print: the bid-ready report ---------- */
.print-only { display: none; }
@media print {
  @page { margin: 14mm; }
  :root, :root[data-theme] { --bg: #fff; --panel: #fff; --inset: #fff; --line: #bbb; --line-strong: #888; --text: #000; --dim: #444; --amber-ink: #000; --ok: #000; --warn: #000; --bad: #000; --ok-bg: #fff; --warn-bg: #fff; --bad-bg: #fff; }
  body { background: #fff; font-size: 11pt; }
  .site-head, .site-foot, .inputs, .actions, .explain, .no-print, .more-toggle, .slot { display: none !important; }
  .calc { display: block; border: 0; box-shadow: none; }
  .readout { position: static; border: 0; padding: 0; }
  .readout .extra { display: grid !important; }
  .print-only { display: block; }
  .tbl-wrap { overflow: visible; border: 0; }
  table { font-size: 9.5pt; }
  th, td { padding: 4px 6px; }
  a { color: #000; }
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }



/* Head editors sit inside a camera group: a rule and a title, not another box. */
.group.head { border: 0; border-top: 1px dashed var(--line-strong); border-radius: 0; background: transparent; padding: var(--s3) 0 var(--s2); margin: var(--s3) 0 0; }
.group.head .group-sub { margin: 0 0 var(--s2); font-family: var(--sans); font-weight: 600; font-size: var(--fs-sm); color: var(--amber-ink); }
@media (max-width: 420px) {
  .group { padding: var(--s3); } .inputs { padding: var(--s3); }
  select { padding-left: 10px; padding-right: 26px; background-position: calc(100% - 14px) 50%, calc(100% - 9px) 50%; }
}

/* ---------- Phone result bar ----------
   While the calculator's inputs are on screen but its result has scrolled
   away, a one-line bar pinned to the top shows the answer. It is position:
   fixed with a fixed height, so showing or hiding it never moves the page;
   nothing on this site changes size in response to scrolling (that caused a
   bounce loop: a readout that shrank when stuck let the page scroll back
   above its own threshold, where it grew again). */
.result-bar {
  position: fixed; left: 0; right: 0; top: 0; z-index: 30;
  height: calc(var(--bar-h) + env(safe-area-inset-top, 0px));
  padding: env(safe-area-inset-top, 0px) var(--gutter) 0;
  display: flex; align-items: center; gap: var(--s3);
  background: var(--panel); color: var(--text); border: 0; border-bottom: 1px solid var(--line-strong);
  border-left: 4px solid var(--line-strong);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  font: 600 var(--fs-sm) var(--sans); text-align: left; pointer-events: none;
  transform: translateY(-110%); visibility: hidden;
  transition: transform .18s ease, visibility 0s linear .18s;
}
.result-bar.show { transform: none; visibility: visible; transition: transform .18s ease; }
.result-bar[data-state="ok"] { border-left-color: var(--ok); }
.result-bar[data-state="warn"] { border-left-color: var(--warn); }
.result-bar[data-state="bad"] { border-left-color: var(--bad); }
.result-bar .rb-fig { flex: none; font: 600 20px var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.result-bar .rb-status { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--dim); }
.result-bar[data-state="ok"] .rb-status { color: var(--ok); }
.result-bar[data-state="warn"] .rb-status { color: var(--warn); }
.result-bar[data-state="bad"] .rb-status { color: var(--bad); }
:root { --bar-h: 52px; }
@media (max-width: 899px) {
  /* A focused field is scrolled clear of the bar, not under it. */
  html { scroll-padding-top: calc(var(--bar-h) + env(safe-area-inset-top, 0px) + 12px); }
}
@media (min-width: 900px) { .result-bar { display: none; } }
@media print { .result-bar { display: none !important; } }

/* Range figures ("35.2–82.8 Mbps") wrap to two lines or one as numbers change;
   on a phone that moved the field being typed in. Reserve both lines. */
@media (max-width: 899px) {
  .figs dd { line-height: 1.3; }
  .figs.ranges dd { min-height: 2.6em; }
}

/* Phone: the result sits above the fields, so any change in its height moves
   the field being typed in. Its parts get fixed room: the figure on one line
   and its label on the next, three lines for the status, two for the source
   note. Messages fit in that room at 360 px. */
@media (max-width: 899px) {
  .meter { flex-wrap: wrap; }
  .meter-figure { white-space: nowrap; }
  .meter-label { flex-basis: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .readout .status { min-height: calc(3 * 1.55 * var(--fs-sm) + 16px); }
  .readout .cite { min-height: calc(2 * 1.55 * var(--fs-xs)); }
}

/* Solar: a list of warnings would change the readout's height as you type,
   so on a phone it sits after the fields instead; beside them on a wide
   screen, and in the readout when printed. */
.flags-narrow { display: none; }
@media (max-width: 899px) {
  .flags-wide { display: none; }
  .flags-narrow { display: block; }
}
@media print { .flags-wide { display: block !important; } }

/* IP addresses never break mid-address. */
.figs.ips dd { white-space: nowrap; overflow-wrap: normal; font-size: 16px; }
.figs.ips .extra dd, .figs.ips.extra dd { font-size: 15px; }
@media (max-width: 420px) { .figs.ips dd { font-size: 15px; } }
.ip-table td { white-space: nowrap; }
.ip-table td:first-child { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.figs .wide { grid-column: 1 / -1; }
.warn-list { margin: var(--s3) 0 0; padding-left: 1.1em; font-size: var(--fs-sm); color: var(--warn); }
.warn-list li { margin-top: var(--s1); }
