/* House form controls of the static sites — see controls.js. Source of truth for both sites; tools/sync_controls_kit.py
 * copies the block between the markers into site-v4.css and the other site's site.css. Colours come from the
 * site's own variables (--ink, --line-strong, --surface | --night-soft, --orange | --gold). */
/* ctl:begin */
.ctl-native { position: absolute !important; width: 1px !important; height: 1px !important; opacity: 0 !important; pointer-events: none !important; overflow: hidden; }
.ctl { position: relative; display: block; min-width: 0; }
.ctl-sel__btn, .ctl-time {
  box-sizing: border-box; display: flex; align-items: center; width: 100%; min-height: 46px; padding: 8px 14px; gap: 8px;
  color: var(--ink, CanvasText); font: inherit; font-weight: 500; text-align: start;
  background: transparent; border: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px;
}
.ctl-sel__btn { justify-content: space-between; cursor: pointer; }
.ctl-sel__btn:disabled { opacity: .5; cursor: not-allowed; }
.ctl-sel__btn:focus-visible, .ctl-time:focus-within { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 1px; }
.ctl-sel__text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; }
.ctl-sel__text.is-empty { opacity: .62; }
.ctl-sel__chev { flex: none; width: 8px; height: 8px; margin-inline-end: 2px; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); }
.ctl-sel__btn[aria-expanded="true"] .ctl-sel__chev { transform: translateY(2px) rotate(-135deg); }
.ctl-pop {
  position: fixed; z-index: 1000; box-sizing: border-box; margin: 0; padding: 6px; list-style: none; overflow-y: auto; overscroll-behavior: contain;
  color: var(--ink, CanvasText); background: var(--ctl-pop-bg, var(--surface, var(--night-soft, Canvas)));
  border: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px; box-shadow: 0 12px 32px color-mix(in srgb, CanvasText 28%, transparent); font: 500 16px/1.3 var(--sans, system-ui, sans-serif);
}
.ctl-pop__o { display: flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: 8px; overflow-wrap: anywhere; cursor: pointer; }
.ctl-pop__o.is-active { background: color-mix(in srgb, var(--orange, var(--gold, Highlight)) 14%, transparent); }
.ctl-pop__o[aria-selected="true"] { font-weight: 700; }
.ctl-pop__o[aria-selected="true"]::after { content: "✓"; margin-inline-start: auto; padding-inline-start: 10px; }
.ctl-pop__o[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.ctl-pop--q { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.ctl-pop__q { box-sizing: border-box; flex: none; width: 100%; min-height: 46px; padding: 8px 14px; font: inherit; font-size: 16px; color: inherit; background: transparent; border: 0; border-bottom: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px 12px 0 0; outline: 0; }
.ctl-pop__q:focus-visible { box-shadow: inset 0 0 0 2px var(--orange, var(--gold, Highlight)); }
.ctl-pop__q::placeholder { opacity: .6; }
.ctl-pop__l { flex: 1 1 auto; min-height: 0; margin: 0; padding: 6px; list-style: none; overflow-y: auto; overscroll-behavior: contain; }
.ctl-pop__none { padding: 14px 16px; opacity: .7; }
.ctl-pop [hidden] { display: none; }
.lang-menu__q { position: sticky; top: 0; z-index: 1; list-style: none; background: var(--ctl-pop-bg, var(--surface, var(--night-soft, Canvas))); }
.lang-menu__q .ctl-pop__q { border-radius: 10px 10px 0 0; }
.lang-menu__list [hidden] { display: none; }
.lang-menu__list .ctl-pop__none { list-style: none; }
.ctl-time { width: max-content; max-width: 100%; min-width: 8.5rem; display: inline-flex; justify-content: center; padding-block: 0; }
/* hh/mm cells fill the field's height and are 44px wide: each is a tap target of its own (forms audit 2026-10-28: 33x34) */
.ctl-time input.ctl-time__f { min-height: 44px; width: 2.75rem; min-width: 0; padding: 0 2px; text-align: center; font: inherit; font-size: 16px; font-variant-numeric: tabular-nums; color: inherit; background: transparent; border: 0; outline: 0; }
.ctl-time input.ctl-time__f::placeholder { opacity: .5; }
.ctl-time input.ctl-time__f:focus { background: color-mix(in srgb, var(--orange, var(--gold, Highlight)) 14%, transparent); border-radius: 6px; }
.ctl-time input.ctl-time__f[aria-invalid] { color: var(--t-bad, var(--terracotta, LinkText)); }
.ctl-time__sep { color: var(--ink-2, var(--ink-soft, inherit)); } /* full ink-2: a faded colon fell below AA (1.33:1, site forms audit 2026-10-28) */
.ctl-time__ap { display: inline-flex; gap: 2px; margin-inline-start: .4rem; align-self: center; }
.ctl-time__ap[hidden] { display: none; }
.ctl-time__ap button { min-height: 36px; min-width: 2.75rem; padding: 0 .5rem; border: 1px solid var(--line-strong, var(--line, currentColor)); border-radius: 8px; background: transparent; color: inherit; font: inherit; font-size: 15px; cursor: pointer; }
.ctl-time__ap button[aria-pressed="true"] { background: color-mix(in srgb, var(--orange, var(--gold, Highlight)) 14%, transparent); border-color: var(--orange, var(--gold, Highlight)); font-weight: 700; }
.ctl-time__ap button:focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 1px; }
.ctl-msg { display: block; margin-top: .35rem; color: var(--accent-ink, var(--gold-light, LinkText)); font-size: .9rem; line-height: 1.35; }
.ctl-msg[hidden] { display: none; }
/* segmented choice (<select data-seg>, 2–3 options): buttons side by side, the chosen one filled */
.ctl-seg { display: flex; gap: 8px; }
.ctl-seg__b { flex: 1 1 0; box-sizing: border-box; min-width: 0; min-height: 46px; padding: 8px 12px; color: var(--ink, CanvasText); font: 500 15px/1.2 inherit; font-family: inherit; text-align: center; overflow-wrap: anywhere; cursor: pointer; background: transparent; border: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px; }
.ctl-seg__b[aria-checked="true"] { color: var(--ctl-on-accent, Canvas); font-weight: 700; background: var(--orange, var(--gold, Highlight)); border-color: var(--orange, var(--gold, Highlight)); }
.ctl-seg__b:focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 2px; }
.ctl-seg__b:disabled { opacity: .5; cursor: not-allowed; }
.ctl-copy { position: fixed; inset: 0; z-index: 1100; display: grid; place-items: center; padding: 16px; background: color-mix(in srgb, CanvasText 45%, transparent); }
.ctl-copy__box { box-sizing: border-box; display: grid; gap: 12px; width: min(440px, 100%); padding: 18px; color: var(--ink, CanvasText); background: var(--ctl-pop-bg, var(--surface, var(--night-soft, Canvas))); border: 1px solid var(--line-strong, ButtonBorder); border-radius: 16px; }
.ctl-copy__in { box-sizing: border-box; width: 100%; min-height: 46px; padding: 8px 12px; font: 500 16px/1.3 var(--sans, system-ui, sans-serif); color: inherit; background: transparent; border: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px; }
.ctl-copy__btn { min-height: 46px; padding: 0 18px; font: 600 15px var(--sans, system-ui, sans-serif); color: var(--ctl-on-accent, Canvas); background: var(--orange, var(--gold, Highlight)); border: 0; border-radius: 12px; cursor: pointer; }
.ctl-copy__in:focus-visible, .ctl-copy__btn:focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 2px; }
/* checkbox: the real input, drawn (no browser mark) */
input[type="checkbox"] {
  appearance: none; -webkit-appearance: none; flex: none; display: inline-grid; place-content: center; box-sizing: border-box;
  width: 22px; height: 22px; margin: 0; cursor: pointer; background: transparent;
  border: 1.5px solid var(--line-strong, ButtonBorder); border-radius: 6px;
}
input[type="checkbox"]::before { content: ""; width: 12px; height: 12px; transform: scale(0); transition: transform .12s; background: var(--orange, var(--gold, Highlight)); clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%); }
input[type="checkbox"]:checked::before { transform: scale(1); }
input[type="checkbox"]:focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 2px; }
input[type="checkbox"]:disabled { opacity: .5; cursor: not-allowed; }
input[aria-invalid="true"] { border-color: var(--t-bad, var(--terracotta, LinkText)); }
input[type="checkbox"][aria-invalid="true"] { outline: 2px solid var(--t-bad, var(--terracotta, LinkText)); outline-offset: 2px; }
/* number: no spinner */
input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
input[type="number"]::-webkit-inner-spin-button, input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
/* range: own track and thumb */
input[type="range"] { appearance: none; -webkit-appearance: none; width: 100%; height: 44px; margin: 0; background: transparent; cursor: pointer; }
input[type="range"]::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: var(--line-strong, ButtonBorder); }
input[type="range"]::-moz-range-track { height: 6px; border-radius: 3px; background: var(--line-strong, ButtonBorder); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; margin-top: -8px; border: 0; border-radius: 50%; background: var(--orange, var(--gold, Highlight)); }
input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border: 0; border-radius: 50%; background: var(--orange, var(--gold, Highlight)); }
input[type="range"]:focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 3px; border-radius: 6px; }
/* a plain <details><summary> outside .faq (article questions): our marker; question bold in ink, answer in the body colour (owner 2026-11-05: no bar, no extra indent) */
main :not(.faq) > details:not([class]) > summary:not([class]) { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 44px; cursor: pointer; list-style: none; font-weight: 600; color: var(--ink, CanvasText); }
main :not(.faq) > details:not([class]) > summary:not([class])::-webkit-details-marker { display: none; }
main :not(.faq) > details:not([class]) > summary:not([class])::after { content: "+"; flex: none; font-size: 1.3em; line-height: 1; }
main :not(.faq) > details[open]:not([class]) > summary:not([class])::after { content: "–"; }
main :not(.faq) > details:not([class]) > summary:not([class]):hover { color: var(--accent-ink, var(--gold-light, var(--ink, CanvasText))); }
main :not(.faq) > details:not([class]) > summary:not([class]):focus-visible { outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 2px; border-radius: 6px; }
main :not(.faq) > details:not([class]) > summary:not([class]) ~ * { color: var(--ink, CanvasText); }
@media (prefers-reduced-motion: reduce) { input[type="checkbox"]::before { transition: none; } }
/* A text field no form styles is never a raw browser box (owner 2026-10-28): the kit's field look, at zero
   specificity (:where), so every form's own field rules still win. Text-like types only. */
:where(main) :where(input:is([type="text"], [type="email"], [type="tel"], [type="search"], [type="url"], [type="number"], :not([type])), textarea) {
  box-sizing: border-box; min-height: 46px; max-width: 100%; padding: 8px 14px; color: var(--ink, CanvasText); font: inherit;
  background: transparent; border: 1px solid var(--line-strong, ButtonBorder); border-radius: 12px;
}
:where(main) :where(input:is([type="text"], [type="email"], [type="tel"], [type="search"], [type="url"], [type="number"], :not([type])), textarea):focus-visible {
  outline: 2px solid var(--orange, var(--gold, Highlight)); outline-offset: 2px;
}
/* Phones zoom the page into a field whose text is under 16px (iOS), and every site field was 15.2px
   (site forms audit 2026-10-28): text-entry fields keep 16px on narrow screens. !important because form
   rules set `font: inherit`; this is a floor, not a look. */
@media (max-width: 760px) {
  :where(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="button"]):not([type="submit"]), textarea, select) { font-size: max(16px, 1em) !important; }
}
/* ctl:end */
