@font-face { font-family: 'Inter'; font-weight: 400; font-display: swap; src: url(/fonts/inter-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 600; font-display: swap; src: url(/fonts/inter-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 700; font-display: swap; src: url(/fonts/inter-latin-700-normal.woff2) format('woff2'); }

/*
 * Flat black and white, like bikybag.com: pill buttons (black when chosen, outlined when not), light grey panels
 * with big rounded corners, bold tight headings, thin line icons. The only colour is red, for overdue.
 */
:root {
  --ink: #111111;
  --ink-soft: #6b6b6b;
  --line: #e6e6e6;
  --line-strong: #cccccc;
  --fill: #f3f3f2;
  --paper: #ffffff;
  --red: #d92d20;
  --red-bg: #fdecea;
  --ink-mid: #444444;
  --line-fill: #e2e2e0;
  --none: #9a9a9a;
  --chart-grid: #e2e2e0;
  --scrim: rgba(0, 0, 0, .4);
  --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23111' stroke-width='1.6'/%3E%3C/svg%3E");
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}

/* Dark: the same black and white, swapped. Auto follows the phone; Settings can pin light or dark (data-theme). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #f2f2f2;
    --ink-soft: #a3a3a3;
    --ink-mid: #cfcfcf;
    --line: #2a2a2a;
    --line-strong: #4a4a4a;
    --line-fill: #303030;
    --fill: #1e1e1e;
    --paper: #111111;
    --red: #ff6b5e;
    --red-bg: #3d1915;
    --none: #777777;
    --chart-grid: #333333;
    --scrim: rgba(0, 0, 0, .65);
    --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23f2f2f2' stroke-width='1.6'/%3E%3C/svg%3E");
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ink: #f2f2f2;
  --ink-soft: #a3a3a3;
  --ink-mid: #cfcfcf;
  --line: #2a2a2a;
  --line-strong: #4a4a4a;
  --line-fill: #303030;
  --fill: #1e1e1e;
  --paper: #111111;
  --red: #ff6b5e;
  --red-bg: #3d1915;
  --none: #777777;
  --chart-grid: #333333;
  --scrim: rgba(0, 0, 0, .65);
  --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23f2f2f2' stroke-width='1.6'/%3E%3C/svg%3E");
  color-scheme: dark;
}

* { box-sizing: border-box; }
/* No zoom on double tap (quick taps stay taps); pinching to zoom still works. On every element: iPhone Safari doesn't
   pass it down. /taps.js covers what's left. */
html { -webkit-text-size-adjust: 100%; }
*, *::before, *::after { touch-action: manipulation; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.5 var(--font);
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
h1, h2, h3 { font-weight: 700; line-height: 1.15; letter-spacing: -0.03em; margin: 0; }
p { margin: 0; }
[hidden] { display: none !important; }
.boot { padding: 40px 0; font-weight: 600; color: var(--ink-soft); }

#app { max-width: 560px; margin: 0 auto; padding: calc(20px + var(--safe-top)) 20px calc(110px + var(--safe-bottom)); }
#app.signin { padding-bottom: calc(28px + var(--safe-bottom)); }

/* A small bold heading, like "Your rack" on bikybag.com. */
.label { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); }

/* ---------- controls ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 24px;
  border: 1px solid var(--ink); border-radius: 999px;
  background: var(--ink); color: var(--paper);
  font-weight: 600; font-size: 16px; text-decoration: none; white-space: nowrap;
  transition: opacity .12s;
}
.btn:active { opacity: .75; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.ghost { background: var(--paper); color: var(--ink); border-color: var(--line-strong); }
.btn.danger { background: var(--paper); color: var(--red); border-color: var(--line-strong); }
.btn.small { min-height: 40px; padding: 0 16px; font-size: 15px; }
.btn.wide { width: 100%; }
.btn[disabled] { opacity: .4; pointer-events: none; }
.link { background: none; border: 0; padding: 6px 4px; color: var(--ink); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.link.danger { color: var(--red); }

/* Two or more choices in one pill, like "cm | inches". */
.seg { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--paper); margin-bottom: 14px; }
.seg button { min-height: 42px; padding: 0 20px; border: 0; border-radius: 999px; background: none; font-weight: 600; color: var(--ink-mid); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }

.field { display: grid; gap: 6px; margin: 0 0 16px; }
.field > span { font-weight: 600; font-size: 15px; }
.field small { color: var(--ink-soft); font-size: 13px; }
.input {
  width: 100%; min-height: 50px; padding: 10px 16px;
  border: 1px solid var(--line-strong); border-radius: 14px; background: var(--paper);
  -webkit-appearance: none; appearance: none;
}
select.input {
  background-image: var(--chev);
  background-repeat: no-repeat; background-position: right 16px center; background-size: 12px; padding-right: 40px;
}
textarea.input { min-height: 90px; resize: vertical; }
.input:focus { border-color: var(--ink); outline: none; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.err { color: var(--red); font-weight: 600; font-size: 14px; min-height: 1.4em; margin: 4px 0; }
.note { color: var(--ink-soft); }

.panel { border: 1px solid var(--line); border-radius: 22px; padding: 20px; }
.panel + .panel { margin-top: 12px; }
.panel h2 { font-size: 20px; margin-bottom: 4px; }
.panel > .note { margin-bottom: 14px; font-size: 15px; }

#toast {
  position: fixed; left: 50%; bottom: calc(96px + var(--safe-bottom)); transform: translate(-50%, 12px);
  display: flex; align-items: center; gap: 16px;
  width: max-content; max-width: min(92vw, 480px); padding: 12px 20px; border-radius: 999px;
  background: var(--ink); color: var(--paper); font-weight: 600; font-size: 15px;
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 60;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
#toast button { border: 0; background: none; color: var(--paper); font-weight: 700; padding: 4px 2px; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- sign in ---------- */

.welcome { display: grid; gap: 22px; padding-top: 8vh; }
.welcome .panel { border: 0; padding: 0; border-radius: 0; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand-mark { width: 48px; height: 48px; flex: none; }
.mk-bg { fill: var(--ink); }
.mk-fg { fill: var(--paper); }
.brand h1 { font-size: 32px; }
.welcome .lead { font-size: 17px; color: var(--ink-soft); max-width: 32ch; }
.welcome .panel h2 { font-size: 20px; }
.pin-dots { display: flex; justify-content: center; gap: 14px; margin: 18px 0 14px; min-height: 14px; }
.pin-dots i { width: 14px; height: 14px; border-radius: 50%; background: var(--ink); }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pinpad button { min-height: 62px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--paper); font-size: 24px; font-weight: 600; }
.pinpad button:active { background: var(--fill); }
.pinpad .ok { background: var(--ink); border-color: var(--ink); color: var(--paper); }

/* ---------- header ---------- */

.top { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.avatar { width: 48px; height: 48px; flex: none; }
.top h1 { font-size: 30px; }
.top p { color: var(--ink-soft); font-size: 15px; }
.top .grow { flex: 1; min-width: 0; }
.call { flex: none; }
.avatar-btn { flex: none; border: 0; padding: 0; background: none; border-radius: 50%; line-height: 0; }
.avatar-photo { border-radius: 50%; object-fit: cover; background: var(--fill); }

/* Profile: the dog's photo, big, at the top. */
.profile-hero { position: relative; display: grid; justify-items: center; text-align: center; gap: 6px; margin: 8px 0 22px; }
.profile-hero .hero-call { position: absolute; top: 0; right: 0; }
.avatar-big-btn { border: 0; padding: 0; background: none; border-radius: 50%; line-height: 0; margin-bottom: 6px; }
.avatar-big { width: 128px; height: 128px; }
.profile-hero h1 { font-size: 30px; }
.profile-hero p { color: var(--ink-soft); font-size: 15px; }
.profile-hero .btn-row { justify-content: center; align-items: center; margin-top: 8px; }

/* ---------- icons: thin line icons in circles ---------- */

.tile {
  width: 48px; height: 48px; flex: none; border-radius: 50%;
  display: grid; place-items: center; background: var(--fill); color: var(--ink);
}
.tile svg { width: 24px; height: 24px; }
.tile.small { width: 42px; height: 42px; }
.tile.small svg { width: 22px; height: 22px; }

/* ---------- home ---------- */

.hero { background: var(--fill); border-radius: 26px; padding: 22px 20px 20px; margin-bottom: 30px; }
.hero .what { display: flex; align-items: center; gap: 14px; margin: 14px 0 14px; }
.hero .tile { background: var(--paper); }
.hero .what h2 { font-size: 26px; }
.hero .when { font-weight: 700; font-size: 18px; letter-spacing: -0.01em; }
.hero.late .when { color: var(--red); }
.hero .give { font-weight: 600; margin-top: 4px; }
.hero .meta { color: var(--ink-soft); font-size: 15px; margin-top: 2px; }
.hero .btn-row { margin-top: 18px; flex-wrap: nowrap; }
.hero .btn { flex: 1; }
.hero .btn.ghost { flex: 0 0 auto; }

/* Weight: the latest as a big number, then the chart. */
.hero .big { font-size: 46px; font-weight: 700; letter-spacing: -0.04em; line-height: 1.05; margin: 8px 0 4px; }
.chart { position: relative; margin-top: 18px; }
.chart, .chart * { touch-action: pan-y; }
.chart svg { display: block; overflow: visible; }
.chart svg:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; border-radius: 6px; }
.hero .where { font-weight: 600; font-size: 15px; margin-top: 6px; }
.chart .band-label { font-size: 12px; font-weight: 600; fill: var(--ink-soft); }
.chart .grid { stroke: var(--chart-grid); stroke-width: 1; }
.chart .band { fill: var(--paper); }
.chart .wline { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot, .chart .focus { fill: var(--ink); stroke: var(--fill); stroke-width: 2; }
.chart .cross { stroke: var(--ink); stroke-width: 1; }
.chart .axis text { font-size: 12px; fill: var(--ink-soft); font-variant-numeric: tabular-nums; }
.chart .tip { position: absolute; transform: translateX(-50%); padding: 6px 12px; border-radius: 12px; background: var(--ink); color: var(--paper); pointer-events: none; white-space: nowrap; text-align: center; font-size: 13px; line-height: 1.3; }
.chart .tip strong { display: block; font-size: 15px; }

.section-head { display: flex; align-items: center; justify-content: space-between; margin: 0 0 8px; }
.section-head h2 { font-size: 22px; }

.list { border-top: 1px solid var(--line); }
.row {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  background: none; border: 0; border-bottom: 1px solid var(--line); padding: 14px 0;
}
.row:active { background: var(--fill); }
.row .grow { flex: 1; min-width: 0; }
.row strong { display: block; font-weight: 600; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row small { display: block; color: var(--ink-soft); font-size: 14px; }
.list .note { padding: 14px 0; font-size: 15px; }

.chip { flex: none; padding: 5px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; border: 1px solid var(--line-strong); color: var(--ink-soft); white-space: nowrap; }
.chip.today { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip.soon { border-color: var(--ink); color: var(--ink); }
.chip.late { background: var(--red-bg); border-color: var(--red-bg); color: var(--red); }

/* Choices with an icon, like "Standard rear rack". */
.kinds { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.kind {
  display: inline-flex; align-items: center; gap: 14px; min-height: 54px; padding: 0 26px 0 22px;
  background: var(--paper); border: 1px solid var(--line-strong); border-radius: 999px; font-weight: 600; font-size: 17px;
}
.kind svg { width: 24px; height: 24px; flex: none; }
.kind:active { background: var(--ink); border-color: var(--ink); color: var(--paper); }

.empty { border: 0; padding: 8px 0 0; }
.empty h2 { font-size: 26px; margin-bottom: 8px; }
.empty p { color: var(--ink-soft); margin: 0 0 22px; max-width: 34ch; }

/* ---------- sheets ---------- */

.overlay {
  position: fixed; inset: 0; z-index: 40; background: var(--scrim);
  display: flex; align-items: flex-end; justify-content: center;
}
.sheet {
  width: min(560px, 100%); max-height: 92dvh; overflow: auto;
  background: var(--paper); border-radius: 26px 26px 0 0;
  padding: 24px 20px calc(22px + var(--safe-bottom));
}
.sheet:focus { outline: none; }
.sheet h2 { font-size: 22px; }
.sheet-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.sheet-head .grow { flex: 1; min-width: 0; }
.sheet-head p { color: var(--ink-soft); font-size: 15px; }
.sheet-actions { display: flex; gap: 10px; margin-top: 16px; }
.sheet-actions .btn { flex: 1; }
.facts { margin: 0 0 16px; background: var(--fill); border-radius: 20px; padding: 4px 18px; }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line-fill); }
.facts div:last-child { border-bottom: 0; }
.facts dt { color: var(--ink-soft); }
.facts dd { margin: 0; font-weight: 600; text-align: right; }
.notes { border: 1px solid var(--line); border-radius: 18px; padding: 12px 16px; margin-bottom: 16px; white-space: pre-wrap; font-size: 15px; }
/* Packaging photo: in the form and in the details (tap to see it bigger). */
.pack { display: block; width: 100%; max-height: 240px; object-fit: contain; border-radius: 18px; background: var(--fill); margin: 0 0 12px; cursor: zoom-in; }
.pack.zoom { max-height: none; cursor: zoom-out; }
.sheet > .pack { margin-bottom: 16px; }
/* Front and back photo slots in the form, and the pair in the details. */
.photos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.photo-slot { display: grid; gap: 6px; }
.photo-add {
  aspect-ratio: 3 / 4; width: 100%; display: grid; place-content: center; justify-items: center; gap: 8px;
  border: 1px dashed var(--line-strong); border-radius: 18px; background: var(--fill); color: var(--ink-soft); font-weight: 600;
}
.photo-add svg { width: 28px; height: 28px; }
.photo-slot .pack { aspect-ratio: 3 / 4; height: auto; max-height: none; object-fit: cover; margin: 0; cursor: pointer; }
.photo-foot { display: flex; align-items: center; justify-content: space-between; font-size: 14px; color: var(--ink-soft); min-height: 32px; }
.photo-foot .link { padding: 4px 0; font-size: 14px; }
.pack-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.pack-pair figure { margin: 0; }
.pack-pair figure:only-child, .pack-pair figure.zoom { grid-column: 1 / -1; }
.pack-pair .pack { margin: 0; max-height: 220px; }
.pack-pair figure.zoom .pack { max-height: none; cursor: zoom-out; }
.pack-pair figcaption { font-size: 13px; color: var(--ink-soft); margin-top: 4px; text-align: center; }
.with-btn { display: flex; gap: 8px; align-items: center; }
.with-btn .input { flex: 1; min-width: 0; }
.with-btn .btn { flex: none; }
.give-box { background: var(--fill); border-radius: 16px; padding: 12px 16px; font-weight: 600; margin: -4px 0 16px; }
/* Links in typed text: black, underlined. */
.facts a, .notes a, .give a, .give-box a, .history a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }
.next { font-weight: 600; min-height: 1.4em; margin: 2px 0 6px; }

.history { list-style: none; margin: 0; padding: 0; }
.history li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.history li:last-child { border-bottom: 0; }
.history .grow { flex: 1; min-width: 0; }
.history strong { display: block; font-weight: 600; }
.history small { display: block; color: var(--ink-soft); font-size: 14px; }
.history .x { border: 0; background: none; color: var(--ink-soft); font-size: 22px; width: 40px; height: 40px; border-radius: 50%; }
.history .x:active { background: var(--fill); }
/* History: search box, type chips, time filter. */
.hist-tools { display: grid; gap: 12px; margin-bottom: 16px; }
.search { position: relative; display: block; }
.search svg { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; color: var(--ink-soft); pointer-events: none; }
.search input {
  width: 100%; min-height: 50px; padding: 10px 16px 10px 46px;
  border: 1px solid var(--line-strong); border-radius: 999px; background: var(--paper); -webkit-appearance: none; appearance: none;
}
.search input:focus { border-color: var(--ink); outline: none; }
.search input::-webkit-search-cancel-button { filter: grayscale(1); cursor: pointer; }
.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -20px; padding: 0 20px 2px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips button {
  flex: none; min-height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--paper); color: var(--ink); font-weight: 600; font-size: 15px; white-space: nowrap;
}
.chips button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.hist-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hist-row select.input { width: auto; min-height: 40px; padding: 6px 38px 6px 16px; border-radius: 999px; font-size: 15px; }
.hist-row span { font-size: 14px; color: var(--ink-soft); }
.history .clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; }
.month { margin: 0 0 4px; }
.history li.tap, .plain li.tap-line { cursor: pointer; }
.history li.tap:active, .plain li.tap-line:active { background: var(--fill); }
.chev { color: var(--ink-soft); font-size: 22px; line-height: 1; flex: none; }
.plain li.tap-line { padding: 6px 0; }
.plain li.tap-line .chev { font-size: 18px; }

/* ---------- settings ---------- */

.status-line { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; margin-bottom: 14px; }
.status-line::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ink); flex: none; }
.status-line.warn { color: var(--red); }
.status-line.warn::before { background: var(--red); }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
.devices { list-style: none; margin: 0 0 4px; padding: 0; }
.devices li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.devices li:last-child { border-bottom: 0; }
.devices strong { font-weight: 600; }
.devices small { display: block; color: var(--ink-soft); font-size: 13px; }

/* ---------- notes ---------- */

.notes-card { margin-top: 28px; }
.note-list { list-style: none; margin: 4px 0 8px; padding: 0; }
.note-item { display: grid; gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.note-item:last-child { border-bottom: 0; }
.note-item:active { background: var(--fill); }
.note-item small { font-size: 13px; color: var(--ink-soft); }
.note-item span { white-space: pre-wrap; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.note-item a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }
.sheet .note-item span { -webkit-line-clamp: unset; display: block; }
textarea.note-text { min-height: 160px; }

/* ---------- flea and tick season ---------- */

.season { margin-top: 28px; }
.season .place { font-size: 14px; font-weight: 600; color: var(--ink-soft); }
.levels { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 10px 0 12px; }
.levels > div { background: var(--fill); border-radius: 16px; padding: 12px 14px; display: grid; gap: 6px; }
.levels span { font-size: 14px; color: var(--ink-soft); }
.levels strong { font-size: 18px; letter-spacing: -0.01em; }
.meter { display: flex; gap: 4px; }
.meter i { width: 100%; height: 6px; border-radius: 3px; background: var(--line-strong); }
.meter i.on { background: var(--ink); }
.strip { display: grid; gap: 9px; margin-top: 16px; }
.strip-row { display: grid; grid-template-columns: 44px repeat(12, 1fr); gap: 3px; align-items: end; height: 24px; }
.strip-row span { font-size: 12px; color: var(--ink-soft); align-self: center; }
.strip-row i { display: block; border-radius: 3px 3px 0 0; background: var(--ink); }
.strip-row i.lv-low { height: 4px; background: var(--line-strong); }
.strip-row i.lv-some { height: 9px; }
.strip-row i.lv-active { height: 16px; }
.strip-row i.lv-high { height: 24px; }
.strip-row i.now { box-shadow: 0 0 0 2px var(--paper), 0 0 0 3.5px var(--ink); }
.strip-row.months { height: auto; }
.strip-row.months b { font-size: 11px; font-weight: 400; color: var(--ink-soft); text-align: center; }
.strip-row.months b.now { font-weight: 700; color: var(--ink); }
.strip-caption { font-size: 12px; color: var(--ink-soft); margin: 4px 0 12px 47px; }
.note.small { font-size: 14px; }

/* ---------- profile ---------- */

.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.panel-head h2, .panel-head h3 { margin: 0; }
.info { margin: 0; }
.info div { padding: 11px 0; border-bottom: 1px solid var(--line); }
.info div:last-child { border-bottom: 0; padding-bottom: 0; }
.info dt { font-size: 14px; color: var(--ink-soft); }
.info dd { margin: 2px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.info a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }
.info .none { color: var(--none); }
.info .mono { font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.plain { list-style: none; margin: 0; padding: 0; white-space: normal; }
.plain li { padding: 2px 0; }

/* Choices as a pill switch, from radio buttons (no script needed). */
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label span { display: inline-flex; align-items: center; min-height: 42px; padding: 0 20px; border-radius: 999px; font-weight: 600; color: var(--ink-mid); cursor: pointer; }
.seg input:checked + span { background: var(--ink); color: var(--paper); }
.seg input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.field .seg { justify-self: start; margin-bottom: 0; }

/* ---------- tabs ---------- */

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--paper); border-radius: 22px 22px 0 0;
  box-shadow: 0 -1px 0 var(--line), 0 -6px 18px rgba(0, 0, 0, .04);
  padding: 8px max(8px, calc((100vw - 560px) / 2)) calc(8px + var(--safe-bottom));
}
.tabs button {
  border: 0; background: none; min-height: 54px;
  display: grid; justify-items: center; align-content: center; gap: 4px; font-size: 13px; font-weight: 400; color: var(--ink);
}
.tabs button svg { width: 25px; height: 25px; }
.tabs button[aria-current="page"] { font-weight: 700; }
.tabs button[aria-current="page"] svg { stroke-width: 2.2; }
.tabs .dot { position: relative; }
.tabs .dot::after { content: ''; position: absolute; top: 0; right: -2px; width: 9px; height: 9px; border-radius: 50%; background: var(--red); border: 2px solid var(--paper); }

/* Links to the other apps on this website */
.app-link { display: grid; flex: 1; color: inherit; text-decoration: none; padding: 2px 0; }
.app-link small { color: var(--ink-soft); font-size: 14px; }
.app-link + span { font-size: 22px; color: var(--ink-soft); }
