/* app-theme.css — the parts of the design system.
   Every colour, size and space comes from tokens.css (generated from design/tokens.json).
   No hex colour and no font size in px may be written in this file: scripts/design.test.js checks it.
   Each part is shown with its states at /design/. */

/* ── base ─────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; color-scheme: dark; }
/* the question form has a sticky progress line: a field that gets focus must not end up under it */
html:has(.progress) { scroll-padding-top: calc(2 * var(--space-7) + var(--space-5)); }
body {
  margin: 0; min-height: 100vh; background: var(--c-ground); color: var(--c-text-body);
  font-family: var(--font-sans); font-size: var(--text-m); font-weight: var(--weight-light);
  line-height: 1.65; -webkit-font-smoothing: antialiased;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; border-radius: var(--radius-image); }
h1, h2, h3, p, ul, ol, figure, fieldset { margin: 0; padding: 0; }
fieldset { border: 0; min-width: 0; }
ul[role="list"], ol[role="list"] { list-style: none; }
h1, h2, h3 { color: var(--c-text); font-weight: var(--weight-light); line-height: 1.2; letter-spacing: var(--track-none); }
h1 { font-size: var(--text-xxl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-l); font-weight: var(--weight-regular); }
a { color: var(--c-text); text-underline-offset: 0.2em; text-decoration-thickness: var(--edge); }
a:hover { text-decoration-thickness: var(--edge-heavy); }
button, input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }

/* The focus ring: white, with a black gap, so it shows on black and on a photo. */
:focus-visible { outline: var(--focus); outline-offset: 2px; box-shadow: 0 0 0 2px var(--c-ground); }
/* a date field: Chromium puts focus on a segment inside it, so the field itself shows the ring */
.input:focus-within { outline: var(--focus); outline-offset: 2px; box-shadow: 0 0 0 2px var(--c-ground); }

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: var(--space-4); top: -10rem; z-index: 50; padding: var(--space-3) var(--space-4); background: var(--c-text); color: var(--c-on-white); }
.skip:focus { top: var(--space-4); }

.wrap { width: 100%; max-width: var(--width-page); margin-inline: auto; padding-inline: var(--space-gutter); }
.wrap--text { max-width: calc(var(--width-text) + 2 * var(--space-gutter)); }
.wrap--narrow { max-width: calc(26rem + 2 * var(--space-gutter)); }
.stack > * + * { margin-top: var(--space-4); }
.stack--loose > * + * { margin-top: var(--space-6); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); }
.row--between { justify-content: space-between; }

.label { font-size: var(--text-xs); font-weight: var(--weight-regular); letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--c-text-dim); }
.lead { font-size: var(--text-l); color: var(--c-text); max-width: var(--width-text); }
.dim { color: var(--c-text-dim); }
.small { font-size: var(--text-s); }
.measure { max-width: var(--width-text); }

.icon { width: 1.5rem; height: 1.5rem; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.icon--s { width: 1.125rem; height: 1.125rem; }

/* ── page frame: top, section, foot ───────────────────────────────────── */
.top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding-block: var(--space-4); }
.top__logo { display: block; width: 3.5rem; height: 3.5rem; flex: none; }
.top__logo img { width: 100%; height: 100%; }
.top__nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-2) var(--space-5); margin-left: auto; }
/* a phone: logo and the three links stay on one line */
@media (max-width: 30rem) { .top { gap: var(--space-3); } .top__logo { width: 2.5rem; height: 2.5rem; } .top__nav { flex-wrap: nowrap; gap: 0 var(--space-5); } .top__nav a { letter-spacing: var(--track-none); white-space: nowrap; } }
.top__nav a { display: inline-flex; align-items: center; min-height: var(--target); font-size: var(--text-xs); font-weight: var(--weight-regular); letter-spacing: var(--track-wide); text-transform: uppercase; text-decoration: none; color: var(--c-text-dim); }
.top__nav a:hover, .top__nav a[aria-current] { color: var(--c-text); }
.top__nav a[aria-current] { text-decoration: underline; text-underline-offset: 0.6em; }

.section { padding-block: var(--space-8); }
.section + .section { border-top: var(--edge) solid var(--c-line); }
.section__head { margin-bottom: var(--space-6); }
.section__head .label { display: block; margin-bottom: var(--space-3); }

.foot { padding-block: var(--space-6); border-top: var(--edge) solid var(--c-line); font-size: var(--text-xs); letter-spacing: var(--track-open); color: var(--c-text-dim); text-align: center; }

/* ── start page ───────────────────────────────────────────────────────── */
.hero { min-height: 72vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-block: var(--space-7); }
.hero__logo { width: min(22rem, 70vw); height: auto; margin-block: calc(-1 * var(--space-5)); }
.hero__line { margin-top: var(--space-5); }
.hero__lead { margin-top: var(--space-5); margin-inline: auto; }

.areas { display: grid; gap: var(--space-6); grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); }
.area h3 { font-size: var(--text-xs); letter-spacing: var(--track-wide); text-transform: uppercase; margin-bottom: var(--space-3); }

/* ── buttons ──────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: var(--target); padding: var(--space-2) var(--space-5);
  border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius); background: transparent; color: var(--c-text);
  font-size: var(--text-s); font-weight: var(--weight-regular); letter-spacing: var(--track-open); text-transform: uppercase; text-decoration: none; white-space: nowrap;
  cursor: pointer; transition: background var(--motion-fast) var(--motion-ease), border-color var(--motion-fast) var(--motion-ease), color var(--motion-fast) var(--motion-ease);
}
.btn:hover { border-color: var(--c-text); background: var(--c-surface-raised); }
.btn:active { background: var(--c-line); }
.btn--primary { background: var(--c-text); border-color: var(--c-text); color: var(--c-on-white); font-weight: var(--weight-medium); }
.btn--primary:hover { background: var(--c-text-body); border-color: var(--c-text-body); }
.btn--primary:active { background: var(--c-text-dim); border-color: var(--c-text-dim); }
.btn--text { border-color: transparent; padding-inline: var(--space-2); text-decoration: underline; text-underline-offset: 0.3em; }
.btn--text:hover { background: transparent; border-color: transparent; text-decoration-thickness: var(--edge-heavy); }
.btn--icon { width: var(--target); padding: 0; }
.btn--wide { width: 100%; }
.btn:disabled, .btn[aria-disabled="true"] { border-color: var(--c-line); background: transparent; color: var(--c-text-dim); cursor: not-allowed; }
.btn--primary:disabled, .btn--primary[aria-disabled="true"] { background: var(--c-line); border-color: var(--c-line); color: var(--c-text-dim); }
.btn[aria-busy="true"] { cursor: progress; }

/* ── fields ───────────────────────────────────────────────────────────── */
.field { display: block; }
.field__label { display: block; margin-bottom: var(--space-2); color: var(--c-text); font-weight: var(--weight-regular); }
.field__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-1) var(--space-3); margin-bottom: var(--space-2); }
.field__head .field__label { margin-bottom: 0; }
.field__hint { display: block; margin-top: var(--space-2); font-size: var(--text-s); color: var(--c-text-dim); }
.field__error { display: flex; gap: var(--space-2); align-items: flex-start; margin-top: var(--space-2); font-size: var(--text-s); font-weight: var(--weight-regular); color: var(--c-text); }
.input {
  display: block; width: 100%; min-height: var(--target); padding: var(--space-2) var(--space-3);
  background: var(--c-surface); border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius); color: var(--c-text);
  font-size: var(--text-m); font-weight: var(--weight-regular); color-scheme: dark;
}
textarea.input { min-height: 6.5rem; resize: vertical; line-height: 1.5; }
.input::placeholder { color: var(--c-text-dim); opacity: 1; }
.input:hover { border-color: var(--c-text-dim); }
.input[aria-invalid="true"] { border: var(--edge-heavy) solid var(--c-text); }
.input:disabled { border-color: var(--c-line); color: var(--c-text-dim); }
.pw { position: relative; }
.pw .input { padding-right: 4.5rem; }
.pw__toggle { position: absolute; right: 0; top: 0; height: 100%; min-width: 4rem; border: 0; background: none; color: var(--c-text-dim); font-size: var(--text-s); cursor: pointer; }
.pw__toggle:hover { color: var(--c-text); }

/* radio, checkbox: the native control, recoloured */
.choice { display: flex; align-items: flex-start; gap: var(--space-3); min-height: var(--target); padding: var(--space-2) 0; cursor: pointer; color: var(--c-text-body); }
.choice input { appearance: none; flex: none; width: var(--target-min); height: var(--target-min); margin: 0.15rem 0 0; border: var(--edge) solid var(--c-line-strong); background: var(--c-surface); display: grid; place-content: center; cursor: pointer; }
.choice input[type="radio"] { border-radius: var(--radius-round); }
.choice input[type="checkbox"] { border-radius: var(--radius); }
.choice input::after { content: ""; width: 0.625rem; height: 0.625rem; background: var(--c-text); transform: scale(0); }
.choice input[type="radio"]::after { border-radius: var(--radius-round); }
.choice input:checked { border-color: var(--c-text); border-width: var(--edge-heavy); }
.choice input:checked::after { transform: scale(1); }
.choice:hover input { border-color: var(--c-text); }
.choice:has(input:disabled), .switch:has(input:disabled) { color: var(--c-text-dim); cursor: not-allowed; }
.choice input:disabled, .switch input:disabled { border-color: var(--c-line); cursor: not-allowed; }

/* switch ("På startsidan") */
.switch { display: inline-flex; align-items: center; gap: var(--space-2); min-height: var(--target); cursor: pointer; font-size: var(--text-s); color: var(--c-text-body); }
.switch input { appearance: none; flex: none; position: relative; width: 2.75rem; height: 1.5rem; margin: 0; border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius-round); background: var(--c-surface); cursor: pointer; transition: background var(--motion-fast) var(--motion-ease); }
.switch input::after { content: ""; position: absolute; top: 50%; left: 0.2rem; width: 1rem; height: 1rem; border-radius: var(--radius-round); background: var(--c-text-dim); transform: translateY(-50%); transition: left var(--motion-fast) var(--motion-ease), background var(--motion-fast) var(--motion-ease); }
.switch input:checked { background: var(--c-text); border-color: var(--c-text); }
.switch input:checked::after { left: 1.45rem; background: var(--c-on-white); }

/* picture choice: cards that act as radio buttons */
.picks { display: grid; gap: var(--space-3); grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); }
.pick { position: relative; display: block; cursor: pointer; }
.pick input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.pick__card { display: block; height: 100%; border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius); background: var(--c-surface); overflow: hidden; }
.pick__image { aspect-ratio: 4 / 3; width: 100%; object-fit: cover; }
.pick__text { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); padding: var(--space-3); font-size: var(--text-s); font-weight: var(--weight-regular); color: var(--c-text); }
.pick__text .icon { visibility: hidden; }
.pick:hover .pick__card { border-color: var(--c-text); }
.pick input:checked + .pick__card { border: var(--edge-heavy) solid var(--c-text); }
.pick input:checked + .pick__card .icon { visibility: visible; }
.pick input:focus-visible + .pick__card { outline: var(--focus); outline-offset: 2px; }

/* ── images: grid, tile, viewer ───────────────────────────────────────── */
.grid { display: grid; gap: var(--space-2); grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 48rem) { .grid { gap: var(--space-3); grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 75rem) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .grid--few { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.thumb { max-width: calc(var(--target) * 4); }
.tile { position: relative; display: block; aspect-ratio: 1; padding: 0; border: 0; background: var(--c-surface); overflow: hidden; color: inherit; text-decoration: none; }
a.tile, button.tile { cursor: zoom-in; }
button.tile[aria-pressed] { cursor: pointer; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: opacity var(--motion-slow) var(--motion-ease), transform var(--motion-slow) var(--motion-ease); }
.tile:hover img { transform: scale(1.02); }
.tile--loading { background: linear-gradient(100deg, var(--c-surface) 30%, var(--c-surface-raised) 50%, var(--c-surface) 70%); background-size: 300% 100%; animation: skel 1.6s linear infinite; }
.tile--missing { display: grid; place-content: center; color: var(--c-text-dim); font-size: var(--text-s); border: var(--edge) dashed var(--c-line-strong); cursor: default; }
.tile__badge { position: absolute; left: var(--space-2); bottom: var(--space-2); }
/* selected: a frame drawn inside the tile, so the focus ring outside it stays free */
.tile[aria-pressed="true"]::after { content: ""; position: absolute; inset: 0; border: calc(2 * var(--edge-heavy)) solid var(--c-text); pointer-events: none; }
@keyframes skel { from { background-position: 100% 0; } to { background-position: -100% 0; } }

.viewer { position: fixed; inset: 0; z-index: 40; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: var(--c-ground); color: var(--c-text); display: none; grid-template-rows: minmax(0, 1fr) auto; grid-template-columns: minmax(0, 1fr); }
.viewer[open] { display: grid; }
.viewer::backdrop { background: var(--c-veil); }
.viewer__stage { position: relative; min-height: 0; min-width: 0; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; padding: var(--space-3); touch-action: pan-y pinch-zoom; }
.viewer__img { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.viewer__error { display: grid; justify-items: center; gap: var(--space-4); padding: var(--space-5); border: var(--edge-heavy) solid var(--c-text); border-radius: var(--radius); text-align: center; }
.viewer__error[hidden] { display: none; }
.viewer__error p { display: flex; align-items: center; justify-content: center; gap: var(--space-2); }
.viewer__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-1); padding: var(--space-2) var(--space-3) calc(var(--space-2) + env(safe-area-inset-bottom, 0px)); background: var(--c-ground); border-top: var(--edge) solid var(--c-line); }
.viewer__bar .btn:not(.btn--icon) { padding-inline: var(--space-3); }
.viewer__count { min-width: 3.5rem; text-align: center; font-size: var(--text-s); font-weight: var(--weight-regular); color: var(--c-text-dim); font-variant-numeric: tabular-nums; }
.viewer__group { display: flex; align-items: center; gap: var(--space-1); }
@media (min-width: 48rem) { .viewer { grid-template-rows: auto minmax(0, 1fr); } .viewer__bar { order: -1; border-top: 0; border-bottom: var(--edge) solid var(--c-line); } }

/* ── upload ───────────────────────────────────────────────────────────── */
.drop { display: grid; justify-items: center; gap: var(--space-3); padding: var(--space-7) var(--space-4); border: var(--edge) dashed var(--c-line-strong); border-radius: var(--radius); text-align: center; color: var(--c-text-body); }
.drop--over { border: var(--edge-heavy) solid var(--c-text); background: var(--c-surface); }
.ups { display: grid; gap: var(--space-1); }
.up { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-1) var(--space-3); padding: var(--space-3); background: var(--c-surface); font-size: var(--text-s); }
.up__name { flex: 1 1 9rem; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--c-text); font-weight: var(--weight-regular); }
.up__status { flex: 0 1 auto; color: var(--c-text-dim); display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); font-variant-numeric: tabular-nums; }
.up__bar { flex: 1 0 100%; }
.up--done .up__status, .up--failed .up__status { color: var(--c-text); }
.up--failed { outline: var(--edge-heavy) solid var(--c-text); outline-offset: calc(-1 * var(--edge-heavy)); }
.bar { height: 0.25rem; background: var(--c-line); border-radius: var(--radius-round); overflow: hidden; }
.bar__fill { height: 100%; width: 0; background: var(--c-text); transition: width var(--motion-slow) var(--motion-ease); }

/* ── feedback ─────────────────────────────────────────────────────────── */
.banner { display: flex; gap: var(--space-3); align-items: flex-start; padding: var(--space-3) var(--space-4); background: var(--c-surface); border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius); color: var(--c-text-body); font-weight: var(--weight-regular); }
.banner--warn { border: var(--edge-heavy) solid var(--c-text); color: var(--c-text); }
.toasts { position: fixed; left: 50%; bottom: var(--space-5); z-index: 60; transform: translateX(-50%); display: grid; gap: var(--space-2); width: min(28rem, calc(100vw - 2 * var(--space-4))); }
.toast { display: flex; gap: var(--space-3); align-items: center; padding: var(--space-3) var(--space-4); background: var(--c-text); color: var(--c-on-white); border-radius: var(--radius); font-size: var(--text-s); font-weight: var(--weight-medium); }
.save-state { display: inline-flex; align-items: center; gap: var(--space-2); font-size: var(--text-s); color: var(--c-text-dim); font-variant-numeric: tabular-nums; }
.save-state--error { color: var(--c-text); font-weight: var(--weight-regular); }

.dialog { width: min(30rem, calc(100vw - 2 * var(--space-4))); padding: var(--space-5); border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius); background: var(--c-surface-raised); color: var(--c-text-body); }
.dialog::backdrop { background: var(--c-veil); }
.dialog h2 { font-size: var(--text-l); font-weight: var(--weight-regular); margin-bottom: var(--space-3); }
.dialog__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-3); margin-top: var(--space-5); }

/* ── page states ──────────────────────────────────────────────────────── */
.empty { display: grid; justify-items: center; gap: var(--space-4); padding: var(--space-7) var(--space-4); text-align: center; border: var(--edge) solid var(--c-line); border-radius: var(--radius); }
.empty p { max-width: 30rem; }
.state-page { min-height: 70vh; display: grid; align-content: center; justify-items: center; gap: var(--space-4); text-align: center; padding-block: var(--space-7); }
.state-page p { max-width: 32rem; }
/* Not real yet: a dashed frame and the word "Exempel". Never looks finished. */
.example { position: relative; padding: var(--space-4); border: var(--edge) dashed var(--c-line-strong); border-radius: var(--radius); }
.example::before { content: "Exempel"; position: absolute; top: calc(-1 * var(--space-2)); left: var(--space-3); padding: 0 var(--space-2); background: var(--c-ground); font-size: var(--text-xs); letter-spacing: var(--track-open); text-transform: uppercase; color: var(--c-text-dim); }

/* a framed block: one row of a list, a group of fields */
.card { padding: var(--space-4); background: var(--c-surface); border: var(--edge) solid var(--c-line); border-radius: var(--radius); }
.cards { display: grid; gap: var(--space-3); list-style: none; }

/* ── admin ────────────────────────────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; gap: var(--space-1); padding: 0.1rem var(--space-2); border: var(--edge) solid var(--c-line-strong); border-radius: var(--radius-round); background: var(--c-ground); font-size: var(--text-xs); font-weight: var(--weight-regular); letter-spacing: var(--track-open); text-transform: uppercase; color: var(--c-text); white-space: nowrap; }
.badge--solid { background: var(--c-text); border-color: var(--c-text); color: var(--c-on-white); }

.meter { display: grid; gap: var(--space-2); font-size: var(--text-s); }
.meter__text { display: flex; align-items: flex-start; gap: var(--space-2); color: var(--c-text-dim); }
.meter--warn .meter__text { color: var(--c-text); font-weight: var(--weight-regular); }

.linkbox { display: grid; gap: var(--space-3); padding: var(--space-4); background: var(--c-surface); border: var(--edge) solid var(--c-line); border-radius: var(--radius); }
.linkbox__url { overflow-wrap: anywhere; color: var(--c-text); font-weight: var(--weight-regular); user-select: all; }

/* a table on a wide screen, one card per row on a phone.
   rows__meta: cells that join into one line on a phone ("12 mars 2026 · 48 bilder · 1,2 GB");
   rows__unit: a word shown only on a phone, where the column heading is not visible. */
.rows__unit { display: none; }
.rows td.rows__actions > * + * { margin-left: var(--space-3); }
.rows { width: 100%; border-collapse: collapse; font-size: var(--text-s); }
.rows th { padding: var(--space-3); text-align: left; font-size: var(--text-xs); font-weight: var(--weight-regular); letter-spacing: var(--track-open); text-transform: uppercase; color: var(--c-text-dim); border-bottom: var(--edge) solid var(--c-line-strong); }
.rows td { padding: var(--space-3); border-bottom: var(--edge) solid var(--c-line); vertical-align: middle; }
.rows tbody tr:hover { background: var(--c-surface); }
.rows td:first-child { color: var(--c-text); font-weight: var(--weight-regular); }
.rows td:first-child a { display: inline-flex; align-items: center; min-height: var(--target-min); min-width: var(--target-min); }
@media (max-width: 47.99rem) {
  .rows thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .rows, .rows tbody, .rows tr, .rows td { display: block; }
  .rows { position: relative; overflow: hidden; }
  .rows tr { padding: var(--space-4); margin-bottom: var(--space-3); background: var(--c-surface); border: var(--edge) solid var(--c-line); border-radius: var(--radius); }
  .rows td { padding: var(--space-1) 0; border: 0; }
  .rows td[data-label]::before { content: attr(data-label) ": "; color: var(--c-text-dim); }
  .rows td.rows__meta { display: inline; color: var(--c-text-dim); }
  .rows td.rows__meta + td.rows__meta::before { content: " · "; }
  .rows td.rows__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); padding-top: var(--space-3); }
  .rows td:first-child { font-size: var(--text-l); padding-bottom: var(--space-2); }
  .rows__unit { display: inline; }
  .rows td.rows__actions > * + * { margin-left: 0; }
}

/* ── question form ────────────────────────────────────────────────────── */
.progress { position: sticky; top: 0; z-index: 20; display: grid; gap: var(--space-2); padding-block: var(--space-3); background: var(--c-ground); border-bottom: var(--edge) solid var(--c-line); }
.progress__text { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-2); font-size: var(--text-s); color: var(--c-text); font-weight: var(--weight-regular); }
.q { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); gap: var(--space-3); padding-block: var(--space-6); border-bottom: var(--edge) solid var(--c-line); scroll-margin-top: calc(2 * var(--space-7) + var(--space-5)); }
.q__nr { font-size: var(--text-l); color: var(--c-text-dim); font-variant-numeric: tabular-nums; }
.q__title { display: block; margin-bottom: var(--space-2); font-size: var(--text-l); font-weight: var(--weight-regular); color: var(--c-text); line-height: 1.35; }
.q__help { margin-bottom: var(--space-4); font-size: var(--text-s); color: var(--c-text-dim); max-width: var(--width-text); }
@media (max-width: 30rem) { .q { grid-template-columns: minmax(0, 1fr); } }

/* ── forced colours (Windows high contrast): the drawn states use system colours ── */
@media (forced-colors: active) {
  .choice input::after { background: Highlight; }
  .choice input:checked, .switch input:checked { border-color: Highlight; }
  .switch input::after { background: ButtonText; }
  .switch input:checked::after { background: Highlight; }
  .bar__fill { background: Highlight; }
  .pick input:checked + .pick__card { border-color: Highlight; }
}

/* ── less motion when the visitor asks for it ─────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .tile:hover img { transform: none; }
}
