/* =========================================================
   Glow Ritual · site-2026.css
   Shared foundation for the 2026 redesign: tokens, base, buttons, forms,
   utility bar, header, mobile menu, footer and the .img-fade / .img-frame utilities.
   Inner pages can link this file and reuse .site-header / .site-footer /
   .btn / .field / .seg / .img-fade without the home-page CSS (home-2026.css).

   BRAND: "a softer pace". Warm paper (--bg) and deep moss ink (--ink) with ONE accent, clay (--clay #8f3b26),
   plus its peach tint. Three quiet surface tints (peach / sage / sand) are used only behind product glyphs.
   Display: Fraunces (variable, optical size). Text: Outfit. No third family: meta labels are small Outfit caps.
   Both fonts are self-hosted (assets/fonts): no third-party font requests.

   PALETTE (round 2: slightly richer and more cohesive, same hues as round 1)
     paper ramp   --bg #f8f2ea > --surface #fffaf4 (lifted panels) > --surface-2 #f0e7dc (linen bands) > --surface-3 #e7dac9
     hairlines    --line #e2d5c5 · --line-strong #c9b8a4 · --control-line #76655a (form borders, 3:1+)
     ink ramp     --ink #1b2a23 > --ink-soft #384a40 > --muted #4a5b51   (green-leaning, never pure black)
     accent       clay --clay #8f3b26 · --clay-hover #742e1d · --clay-tint #f8e1d3 · --clay-on-dark #f2bba3
     dark bands   --moss #15281f (people, closing CTA) · --moss-2 #1d352a · --moss-3 #294539
                  --moss-deep #0f1f18 (footer, the deepest step) · --moss-line #3d5c4e · --moss-dim #c9d8cf
     product tints --tint-peach #f8e1d3 · --tint-sage #dfe9dc · --tint-sand #eadfce (all under ink text)

   CONTRAST (WCAG AA, computed with the WCAG 2.x relative-luminance formula)
     text on paper   ink on bg 13.5:1 · ink on surface 14.4:1 · ink on surface-2 12.3:1
                     ink-soft on bg 8.5:1 · on surface 9.1:1 · on surface-2 7.7:1
                     muted on bg 6.5:1 · on surface 7.0:1 · on surface-2 5.9:1 · on surface-3 5.3:1
     accent text     accent on bg 6.7:1 · on surface 7.2:1 · on surface-2 6.1:1 · on accent-tint 5.9:1
     filled controls white on accent 7.4:1 · white on accent-hover 9.8:1 · white on ink 15.0:1
     product tiles   ink on peach 11.9:1 · sage 12.0:1 · sand 11.4:1 · muted on sage 5.8:1 · on sand 5.5:1
     on dark         white on moss 15.5:1 · moss-dim on moss 10.5:1 · on moss-2 8.9:1 · on moss-3 7.1:1 · on moss-deep 11.6:1
                     accent-on-dark on moss 9.2:1 · on moss-deep 10.1:1 · moss on accent-tint (dark-band button) 12.3:1
     semantics       danger on white 8.1:1 · danger-night on moss 8.8:1 · success on surface 7.6:1
     non-text (1.4.11, needs 3:1)  control-line on bg 5.0:1 · on surface 5.4:1 · on surface-2 4.5:1

   NO MOTION (round 2): this stylesheet has no transitions, animations, keyframes, smooth scrolling or hover
   lifts. State changes (hover colour, pressed, open) are instant. The focus ring stays.

   READABILITY + MICRO-SPACING TOKENS (standing rules for every page that links this file)
   Type scale, fluid (390px -> 1440px):
     --t-display 40 -> 76 · --t-h2 30 -> 52 · --t-h3 20 -> 24
     --t-lede    17 -> 19  (lead paragraph, 18px+ on desktop)
     --t-body    16 -> 17  (paragraphs, inputs, descriptions; never below 16)
     --t-small   15 -> 16  (nav, buttons, table cells, notes, "sample" lines; never below 15)
     --t-meta    14 -> 15  (caps labels, eyebrows, badges, table heads; never below 14)
   Nothing renders below 14px. Line-height: body 1.6, small 1.5, headings 1.05-1.2.
   Letter-spacing: display -.03em, h2 -.025em, h3 -.015em, caps labels +.08em.
   Measure: paragraphs cap at --measure (66ch); lede at 54ch.
   Spacing: 4px base, only these steps (--s-1..--s-10): 4 8 12 16 24 32 48 64 96 128.
     label -> input 8 · icon -> text 8 · badge padding 4 x 8 · button 48 high (44 min) · list rows 16-24
     table cells 12-16 · heading -> paragraph 12-16 · card padding 24 (32-48 desktop)
   Tap targets: every link/button is at least 44 x 44 (inline text links in paragraphs excepted).
   Figures (prices, minutes, counts) use tabular-nums so columns and baselines line up.
   ========================================================= */
@font-face { font-family: "Fraunces"; src: url("../assets/fonts/fraunces-latin-opsz-normal.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url("../assets/fonts/fraunces-latin-wght-italic.woff2") format("woff2"); font-weight: 100 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Outfit"; src: url("../assets/fonts/outfit-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }

/* Metric-matched fallbacks: the local system font is scaled to Fraunces / Outfit so the swap to the web font
   moves nothing (keeps CLS at ~0). Values measured from the shipped woff2 files (avg glyph width, hhea). */
@font-face { font-family: "Fraunces Fallback"; src: local("Times New Roman"), local("TimesNewRomanPSMT"), local("Liberation Serif"), local("Georgia"); size-adjust: 126.8%; ascent-override: 77.1%; descent-override: 20.1%; line-gap-override: 0%; }
@font-face { font-family: "Outfit Fallback"; src: local("Arial"), local("ArialMT"), local("Liberation Sans"), local("Helvetica"); size-adjust: 98.9%; ascent-override: 101.1%; descent-override: 26.3%; line-gap-override: 0%; }

:root {
  /* colour: neutrals (warm paper) */
  --bg: #f8f2ea;
  --surface: #fffaf4;
  --surface-2: #f0e7dc;
  --surface-3: #e7dac9;
  --line: #e2d5c5;
  --line-strong: #c9b8a4;
  --control-line: #76655a;      /* 5.0:1 on bg, 5.4:1 on surface, 4.5:1 on surface-2 (WCAG 1.4.11 needs 3:1) */
  --ink: #1b2a23;
  --ink-soft: #384a40;
  --muted: #4a5b51;
  /* colour: the one accent, clay, plus its tint */
  --clay: #8f3b26;
  --clay-hover: #742e1d;
  --clay-tint: #f8e1d3;
  --clay-on-dark: #f2bba3;
  --on-ink-accent: #f8e1d3;     /* peach, used on ink-filled controls (checked boxes, segmented control) */
  /* colour: surface tints behind product glyphs and panels */
  --tint-peach: #f8e1d3;
  --tint-sage: #dfe9dc;
  --tint-sand: #eadfce;
  /* colour: dark bands */
  --moss: #15281f;
  --moss-2: #1d352a;
  --moss-3: #294539;
  --moss-deep: #0f1f18;
  --moss-line: #3d5c4e;
  --moss-dim: #c9d8cf;
  --moss-edge: #8fa89a;         /* outline-button border on dark: 6.3:1 on moss */
  /* colour: semantics */
  --danger: #8a3048;
  --danger-night: #f0b3c2;
  --success: #1f5c40;
  --focus: #8f3b26;

  /* type */
  --font-display: "Fraunces", "Fraunces Fallback", "Iowan Old Style", Palatino, Georgia, serif;
  --font-text: "Outfit", "Outfit Fallback", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: var(--font-text);   /* no third family: figures use tabular-nums in Outfit */
  --t-display: clamp(2.75rem, 1.25rem + 4.9vw, 4.75rem);
  --t-h2: clamp(1.875rem, 1.2rem + 2.6vw, 3.25rem);
  --t-h3: clamp(1.25rem, 1.12rem + .5vw, 1.5rem);
  --t-lede: clamp(1.0625rem, 1rem + .3vw, 1.1875rem);
  --t-body: clamp(1rem, .98rem + .1vw, 1.0625rem);
  --t-small: clamp(.9375rem, .92rem + .07vw, 1rem);
  --t-meta: clamp(.875rem, .86rem + .07vw, .9375rem);
  --lh-body: 1.6;
  --lh-small: 1.5;
  --lh-head: 1.12;
  --track-label: .08em;
  --measure: 66ch;

  /* spacing: 4px scale */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px; --s-10: 128px;

  /* shape: two levels */
  --r-control: 12px;
  --r-card: 20px;
  --shadow-overlay: 0 24px 64px -16px rgba(27, 42, 35, .38);

  /* layout */
  --max: 1320px;
  --gutter: 24px;
  --margin: clamp(20px, 4vw, 56px);
  --header-h: 64px;
  --section: clamp(64px, 40px + 6vw, 128px);

  /* premium imagery tokens (see .img-fade / .img-frame below) */
  --img-grade: contrast(1.03) saturate(1.05);    /* very light tonal grade, never heavy */
  --img-radius: 20px;
  --img-ring: rgb(27 42 35 / .14);               /* hairline ring on crisp edges */
  --img-shadow: 0 1px 2px rgb(27 42 35 / .06), 0 16px 32px -16px rgb(27 42 35 / .3);
  --img-ph: var(--surface-2);                    /* placeholder behind a loading photo */
  color-scheme: light;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + var(--s-4)); background: var(--moss-deep); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 var(--t-body)/var(--lh-body) var(--font-text);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p, ul, ol, figure, dl, dd, table, fieldset, blockquote { margin: 0; }
:where(ul[role="list"], ol[role="list"]) { list-style: none; padding: 0; margin: 0; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: var(--r-control); }
.on-dark :focus-visible, .site-footer :focus-visible, .utility :focus-visible, .mobile-bar :focus-visible { outline-color: var(--clay-on-dark); }
::selection { background: var(--clay-tint); color: var(--ink); }
.wrap { width: 100%; max-width: calc(var(--max) + var(--margin) * 2); margin-inline: auto; padding-inline: var(--margin); }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: var(--s-4); top: -64px; z-index: 100; background: var(--clay); color: #fff; font-weight: 600; padding: var(--s-3) var(--s-4); border-radius: var(--r-control); }
.skip-link:focus { top: var(--s-3); }
.num { font-variant-numeric: tabular-nums; }
:where(p) { max-width: var(--measure); text-wrap: pretty; }
:where(li, dd, figcaption, summary, blockquote) { text-wrap: pretty; }
:where(h1, h2, h3, .h3, .display, .h2) { text-wrap: balance; }

/* ---------- type ---------- */
.meta { font: 500 var(--t-meta)/1.4 var(--font-text); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--muted); }
.on-dark .meta { color: var(--moss-dim); }
.eyebrow { display: inline-flex; align-items: center; gap: var(--s-2); color: var(--clay); }
.eyebrow::before { content: ""; width: 24px; height: 1px; background: currentColor; }
.on-dark .eyebrow { color: var(--clay-on-dark); }
.display { font: 400 var(--t-display)/1.02 var(--font-display); font-variation-settings: "opsz" 144; letter-spacing: -.035em; text-wrap: balance; }
.h2 { font: 400 var(--t-h2)/var(--lh-head) var(--font-display); font-variation-settings: "opsz" 96; letter-spacing: -.025em; text-wrap: balance; }
.h3 { font: 500 var(--t-h3)/1.2 var(--font-display); font-variation-settings: "opsz" 36; letter-spacing: -.015em; }
:is(.display, .h2, .h3) em { font-style: italic; color: var(--clay); }
.on-dark :is(.display, .h2, .h3) em { color: var(--clay-on-dark); }
.lede { font-size: var(--t-lede); line-height: 1.55; color: var(--ink-soft); max-width: 54ch; text-wrap: pretty; }
.on-dark .lede { color: var(--moss-dim); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2);
  min-height: 48px; padding: 0 var(--s-5); border-radius: var(--r-control);
  border: 1px solid transparent; font: 500 var(--t-small)/1.2 var(--font-text); letter-spacing: .005em;
  text-decoration: none; white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; flex: none; }
.btn-primary { background: var(--clay); color: #fff; }
.btn-primary:hover { background: var(--clay-hover); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-soft); }
.btn-line { background: transparent; color: var(--ink); border-color: var(--ctl-line); }
.btn-line:hover { border-color: var(--control-line); }
.on-dark .btn-primary { background: var(--clay-tint); color: var(--moss); }
.on-dark .btn-primary:hover { background: #fff; }
.on-dark .btn-line { color: #fff; border-color: var(--moss-edge); }
.on-dark .btn-line:hover { border-color: #fff; }
.btn-sm { min-height: 44px; padding: 0 var(--s-4); }
.btn-lg { min-height: 56px; padding: 0 var(--s-6); font-size: var(--t-body); }
.link-arrow { display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; font-weight: 500; color: var(--ink); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 5px; text-decoration-thickness: 2px; }
.link-arrow svg { width: 16px; height: 16px; }
.link-arrow:hover { text-decoration-color: var(--clay); }
.on-dark .link-arrow { color: #fff; text-decoration-color: var(--moss-edge); }
.on-dark .link-arrow:hover { text-decoration-color: var(--clay-on-dark); }

/* ---------- buttons: states (instant, no motion) ---------- */
.btn:disabled, .btn[aria-disabled="true"] {
  background: var(--surface-2); color: var(--muted); border-color: var(--line-strong);
  cursor: not-allowed;
}
.btn[aria-busy="true"] { pointer-events: none; }
.btn[aria-busy="true"]::before {
  content: ""; width: 16px; height: 16px; flex: none; border-radius: 50%;
  border: 2px solid currentColor; border-right-color: transparent;
}

/* =========================================================
   FORMS · reusable component layer (plain CSS, no build step)
   ---------------------------------------------------------
   Markup contract (see forms-demo.html for every state):
     .field            stacked label + control + .field-hint / .field-error
     .field--float     floating-label variant (input needs placeholder=" ")
     .input-group      input with .affix prefix/suffix (£, m, kW)
     select            native <select>; styled closed state everywhere,
                       styled popup where `appearance: base-select` exists
     .check / .switch  checkbox + radio / toggle (label wraps the input)
     input[type=range] + <output> readout, .seg segmented radio group
     .btn[aria-busy]   loading, .btn:disabled
   Validation: :user-invalid / :user-valid (after interaction),
   [aria-invalid="true"] or .field[data-invalid] for server-side errors.
   Targets >= 44px, input text >= 16px (no iOS zoom). Soft hairline fields (see the FORMS REFINEMENT tokens) with a documented 1.4.11 trade-off; checkbox, radio, switch and outline buttons keep a 3:1 line.
   Customizable-select pattern informed by Open Props UI (MIT,
   github.com/argyleink/open-props) and the Chrome customizable-select guide.
   ========================================================= */
/* FORMS REFINEMENT (soft fields). Tokens for every form control; hairlines are deliberately lighter than --control-line.
   --field-bg         #f4ede3  gentle fill (70% surface-2, 30% surface): reads as a field on bg and on white cards; goes to --surface on focus
   --field-line       #aa9d94  1px hairline at rest: 2.4:1 on bg, 2.5:1 on surface, 2.3:1 on the field fill
   --field-line-hover #76655a  = --control-line, 5.0:1 on bg (instant swap on hover, no transition)
   --ctl-line         #96887e  3:1 line (3.1:1 on bg, 3.3:1 on surface) for controls with NO fill or other boundary: checkbox, radio, switch,
                          range track, outline buttons, icon buttons, chips
   WCAG 1.4.11 TRADE-OFF (documented, chosen by the site owner): text fields, selects, textareas and segmented controls rest on a
   hairline of ~2.3:1 plus a fill and a visible label above, which is below the strict 3:1 boundary rule. Mitigations: hover shows the
   5.0:1 line, focus shows a 2px focus-coloured ring plus a white fill, errors and valid states carry an icon and text, forced-colors
   and prefers-contrast: more restore the full --control-line. To meet 3:1 everywhere set --field-line to --ctl-line. */
:root {
  --field-h: 48px; --field-px: var(--s-4); --r-field: 14px;
  --field-bg: #f4ede3; --field-bg-focus: var(--surface); --field-line: #aa9d94; --field-line-hover: var(--control-line); --ctl-line: #96887e;
  --field-danger-bg: #fbf0f2;
}
@media (prefers-contrast: more) { :root { --field-line: var(--control-line); --ctl-line: var(--control-line); } }

.field { display: grid; gap: 6px; min-width: 0; align-content: start; }
.field > label, .field > .label, .label {
  font: 600 var(--t-small)/1.3 var(--font-text); letter-spacing: 0; color: var(--form-label);
}
.field-opt { font-weight: 400; color: var(--form-hint); margin-left: var(--s-1); }
.field-hint, .field-error { margin: 0; font-size: var(--t-small); line-height: var(--lh-small); color: var(--form-hint); }
.field-error { display: none; gap: var(--s-2); align-items: flex-start; color: var(--form-error); font-weight: 500; }
.field-error::before {
  content: ""; flex: none; width: 16px; height: 16px; margin-top: .15em; background: currentColor;
  -webkit-mask: var(--i-alert) center / contain no-repeat; mask: var(--i-alert) center / contain no-repeat;
}
.field:has(:user-invalid, [aria-invalid="true"]) .field-error, .field[data-invalid] .field-error { display: flex; }
.field:has(:user-invalid, [aria-invalid="true"]) .field-hint, .field[data-invalid] .field-hint { display: none; }
.field:has(:disabled) > label { color: var(--form-hint); }
:root {
  --i-alert: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13Zm-.75 3.25h1.5v4h-1.5v-4Zm.75 6.9a.9.9 0 1 1 0-1.8.9.9 0 0 1 0 1.8Z'/%3E%3C/svg%3E");
  --i-chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4.5 7.5 5.5 5.5 5.5-5.5'/%3E%3C/svg%3E");
  --i-chev-soft: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23384a40' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 7.75 5 5 5-5'/%3E%3C/svg%3E");
  --i-chev-ink: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%231e2c26' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4.5 7.5 5.5 5.5 5.5-5.5'/%3E%3C/svg%3E");
  --i-chev-muted: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234e5e56' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4.5 7.5 5.5 5.5 5.5-5.5'/%3E%3C/svg%3E");
  --i-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m3 8.5 3.2 3.2L13 4.8'/%3E%3C/svg%3E");
}

/* --- text-like controls --- */
.input,
.field input:not([type="range"], [type="radio"], [type="checkbox"], [type="hidden"], [type="submit"], [type="button"], [type="file"]),
.field textarea {
  width: 100%; min-height: var(--field-h); padding: 0 var(--field-px);
  background: var(--field-bg); color: var(--ink);
  border: 1px solid var(--field-line); border-radius: var(--r-field);
  font: 400 var(--t-body)/1.4 var(--font-text);   /* >= 16px: no iOS zoom */
}
.field textarea { min-height: 7.5rem; padding-block: 14px; resize: vertical; field-sizing: content; }
.input:hover, .field input:hover:not(:disabled), .field textarea:hover:not(:disabled) { border-color: var(--field-line-hover); }
.input:focus-visible, .field input:focus-visible, .field textarea:focus-visible {
  border-color: var(--focus); background-color: var(--field-bg-focus); outline: 2px solid var(--focus); outline-offset: 1px;
}
.input::placeholder, .field input::placeholder, .field textarea::placeholder { color: var(--muted); opacity: 1; }
.input:user-invalid, .field input:user-invalid, .field textarea:user-invalid, select:user-invalid,
[aria-invalid="true"], .field[data-invalid] :where(input, select, textarea) {
  border-color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); background-color: var(--field-danger-bg);
}
/* valid tick: required fields only, so optional blanks never turn green */
.field input:required:user-valid:not([type="range"], [type="radio"], [type="checkbox"]) {
  border-color: var(--success); padding-inline-end: calc(var(--field-px) + 28px);
  background: var(--field-bg) var(--i-check) no-repeat right var(--field-px) center / 18px;
}
.input:disabled, .field input:disabled:not([type="range"], [type="radio"], [type="checkbox"]), .field textarea:disabled, select:disabled {
  background-color: var(--surface-2); border-color: var(--line); color: var(--muted); cursor: not-allowed;
}
.field input:read-only:not(:disabled, [type="range"]) { background: var(--bg); border-style: dashed; }
.field input:-webkit-autofill { -webkit-box-shadow: 0 0 0 100px var(--field-bg) inset; -webkit-text-fill-color: var(--ink); }

/* floating label (needs placeholder=" ") */
.field--float { position: relative; }
.field--float > label {
  position: absolute; z-index: 1; inset: 15px auto auto calc(var(--field-px) + 1px); max-width: calc(100% - 2 * var(--field-px));
  font: 400 var(--t-body)/1.3 var(--font-text); color: var(--muted); pointer-events: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.field.field--float input[placeholder] { min-height: 56px; padding-top: 22px; padding-bottom: 4px; }
.field--float input::placeholder { color: transparent; }
.field--float:has(input:focus, input:not(:placeholder-shown)) > label { top: 6px; font-size: var(--t-meta); font-weight: 600; color: var(--ink-soft); }
.field--float:has(input:disabled) > label { color: var(--form-hint); }

/* input with affixes */
.input-group {
  display: flex; align-items: stretch; min-height: var(--field-h); background: var(--field-bg);
  border: 1px solid var(--field-line); border-radius: var(--r-field); overflow: hidden;
}
.input-group:hover { border-color: var(--field-line-hover); }
.input-group:has(input:focus-visible) { border-color: var(--focus); background: var(--field-bg-focus); outline: 2px solid var(--focus); outline-offset: 1px; }
.input-group:has(:user-invalid, [aria-invalid="true"]) { border-color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); background: var(--field-danger-bg); }
.input-group:has(input:disabled) { background: var(--surface-2); border-color: var(--line); }
.field .input-group input {
  flex: 1; min-width: 0; min-height: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; outline: 0;
}
.affix {
  display: grid; place-items: center; padding-inline: var(--s-4); background: var(--surface-3); color: var(--ink-soft);
  font: 500 var(--t-small)/1 var(--font-mono); white-space: nowrap;
}
.affix:first-child { border-inline-end: 1px solid var(--field-line); }
.affix:last-child { border-inline-start: 1px solid var(--field-line); }

/* --- select: closed state (every browser) --- */
select {
  appearance: none; width: 100%; min-height: var(--field-h); padding: 0 var(--s-7) 0 var(--field-px);
  background: var(--field-bg) var(--i-chev-soft) no-repeat right 14px center / 18px;
  color: var(--ink); border: 1px solid var(--field-line); border-radius: var(--r-field);
  font: 400 var(--t-body)/1.4 var(--font-text); text-overflow: ellipsis; cursor: pointer;
}
select:hover:not(:disabled) { border-color: var(--field-line-hover); }
select:focus-visible { border-color: var(--focus); background-color: var(--field-bg-focus); outline: 2px solid var(--focus); outline-offset: 1px; }
select:disabled { background-image: var(--i-chev-muted); }

/* --- select: customizable popup (Chrome/Edge 135+, Safari 27+, fine pointers only) ---
   Touch devices keep the native OS picker (better UX); Firefox keeps the native popup. */
@media (hover: hover) and (pointer: fine) {
  @supports (appearance: base-select) {
    select, select::picker(select) { appearance: base-select; }
    select, select:disabled { display: flex; align-items: center; background-image: none; }
    select::picker-icon {
      content: ""; width: 18px; height: 18px; margin-inline-start: auto; background: var(--ink-soft);
      -webkit-mask: var(--i-chev) center / contain no-repeat; mask: var(--i-chev) center / contain no-repeat;
    }
    select:open::picker-icon { rotate: 180deg; }
    select::picker(select) {
      box-sizing: border-box; min-inline-size: anchor-size(width); max-block-size: min(22rem, 50svh); margin-block: var(--s-1);
      padding: var(--s-1); background: var(--surface); color: var(--ink);
      border: 1px solid var(--field-line); border-radius: calc(var(--r-field) + 2px); box-shadow: var(--shadow-overlay);
      font: 400 var(--t-body)/1.4 var(--font-text);
    }
    select option {
      display: flex; align-items: center; gap: var(--s-3); min-height: 44px; padding: 0 var(--s-3);
      border-radius: 8px; color: var(--ink); cursor: pointer;
    }
    select option:hover, select option:focus-visible { background: var(--surface-2); }
    select option:checked { background: var(--clay-tint); color: var(--ink); font-weight: 600; }
    select option:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
    select option:disabled { color: var(--muted); cursor: not-allowed; }
    select option::checkmark { order: 1; margin-inline-start: auto; color: var(--clay); font-weight: 700; }
    select optgroup label { display: block; padding: var(--s-3) var(--s-3) var(--s-1); font: 500 var(--t-meta)/1.3 var(--font-mono); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--muted); }
  }
}
@media (forced-colors: active) {   /* system colours + native arrow */
  select, select::picker(select) { appearance: auto; background-image: none; }
}

/* --- checkbox / radio --- */
.check, .switch { display: flex; align-items: center; gap: var(--s-3); min-height: 44px; cursor: pointer; font-size: var(--t-body); line-height: 1.35; color: var(--form-label); }
.check:has(:disabled), .switch:has(:disabled) { color: var(--form-hint); cursor: not-allowed; }
.check input, .switch input {
  appearance: none; flex: none; margin: 0; display: grid; place-content: center; cursor: inherit;
  background: var(--surface); border: 2px solid var(--ctl-line);
}
.check input { width: 24px; height: 24px; border-radius: 6px; }
.check input[type="radio"] { border-radius: 50%; }
.check input:hover:not(:disabled), .switch input:hover:not(:disabled) { border-color: var(--control-line); }
.check input[type="checkbox"]::after {
  content: ""; width: 16px; height: 16px; background: var(--on-ink-accent); scale: 0;
  -webkit-mask: var(--i-check) center / contain no-repeat; mask: var(--i-check) center / contain no-repeat;
}
.check input[type="checkbox"]:indeterminate::after { -webkit-mask: none; mask: none; height: 2px; width: 12px; scale: 1; }
.check input:checked, .check input[type="checkbox"]:indeterminate { background: var(--ink); border-color: var(--ink); }
.check input[type="checkbox"]:checked::after { scale: 1; }
.check input[type="radio"]:checked { background: var(--on-ink-accent); box-shadow: inset 0 0 0 4px var(--ink); }
.check input:user-invalid { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
.check input:disabled, .switch input:disabled { background: var(--surface-2); border-color: var(--line); }
.check input:checked:disabled { background: var(--line-strong); }

/* --- toggle (checkbox with role="switch") --- */
.switch input { position: relative; width: 48px; height: 28px; border-radius: 14px; background: var(--surface-2); }
.switch input::after {
  content: ""; position: absolute; inset: 2px auto 2px 2px; width: 20px; border-radius: 50%;
  background: var(--ink-soft);
}
.switch input:checked { background: var(--ink); border-color: var(--ink); }
.switch input:checked::after { translate: 20px 0; background: var(--on-ink-accent); }
.switch input:disabled::after { background: var(--muted); }
@media (forced-colors: active) {
  .check input, .switch input { appearance: auto; }
  .switch input::after { display: none; }
}

/* --- range slider + readout --- */
input[type="range"] {
  --fill: var(--ink); --track: var(--form-track); --p: 16%;
  appearance: none; -webkit-appearance: none; width: 100%; height: 44px; margin: 0; background: transparent; cursor: pointer; accent-color: var(--ink);
}
input[type="range"]::-webkit-slider-runnable-track { height: 8px; border-radius: 4px; background: linear-gradient(to right, var(--fill) var(--p), var(--track) var(--p)); box-shadow: inset 0 0 0 1px var(--ctl-line); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 28px; height: 28px; margin-top: -10px; border-radius: 50%; background: var(--on-ink-accent); border: 3px solid var(--ink); box-shadow: 0 1px 4px rgba(27, 42, 35, .3); }
input[type="range"]::-moz-range-track { height: 8px; border-radius: 4px; background: var(--track); box-shadow: inset 0 0 0 1px var(--ctl-line); }
input[type="range"]::-moz-range-progress { height: 8px; border-radius: 4px; background: var(--fill); }
input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--on-ink-accent); border: 3px solid var(--ink); box-shadow: 0 1px 4px rgba(27, 42, 35, .3); }
input[type="range"]:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
input[type="range"]:disabled { cursor: not-allowed; --fill: var(--muted); }
input[type="range"]:disabled::-webkit-slider-thumb { border-color: var(--muted); background: var(--surface-2); }
input[type="range"]:disabled::-moz-range-thumb { border-color: var(--muted); background: var(--surface-2); }
.range-ends { display: flex; justify-content: space-between; margin-top: calc(-1 * var(--s-1)); font: 400 var(--t-meta)/1.3 var(--font-mono); color: var(--form-hint); font-variant-numeric: tabular-nums; }
.calc-row { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-3); }
.calc-row output { font: 600 1.25rem/1.2 var(--font-display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
@media (forced-colors: active) {
  input[type="range"] { appearance: auto; accent-color: Highlight; }
}

/* --- surfaces: controls are always light boxes; only the text around them flips ---
   .on-dark flips labels/hints/errors/track; .on-light switches back inside a light card. */
:root, .on-light { --form-label: var(--ink); --form-hint: var(--muted); --form-error: var(--danger); --form-track: var(--surface-2); }
.on-dark { --form-label: #fff; --form-hint: var(--moss-dim); --form-error: var(--danger-night); --form-track: var(--moss-line); }

/* --- fieldset + segmented radio group --- */
.fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.fieldset legend { padding: 0; margin-bottom: var(--s-2); font: 600 var(--t-small)/1.3 var(--font-text); color: var(--form-label); }
.seg { display: grid; grid-template-columns: repeat(var(--seg-n, 3), 1fr); border: 1px solid var(--field-line); border-radius: var(--r-field); overflow: hidden; background: var(--field-bg); }
.seg label { position: relative; display: block; }
.seg label + label { border-left: 1px solid var(--field-line); }
.seg input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.seg span { display: grid; place-items: center; text-align: center; padding: var(--s-2) var(--s-2); min-height: var(--field-h); font: 500 var(--t-small)/1.25 var(--font-text); color: var(--ink-soft); }
.seg input:hover + span { background: var(--surface); }
.seg input:checked + span { background: var(--ink); color: var(--on-ink-accent); font-weight: 600; }
.seg input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: -4px; }
.seg input:disabled + span { color: var(--muted); background: var(--surface-2); cursor: not-allowed; }
@media (forced-colors: active) {
  .seg input:checked + span { background: Highlight; color: HighlightText; forced-color-adjust: none; }
}

/* ---------- utility bar ---------- */
.utility { background: var(--moss); color: var(--moss-dim); font-size: var(--t-small); line-height: var(--lh-small); border-bottom: 1px solid var(--moss-2); }
.utility .wrap { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3) var(--s-5); min-height: 44px; }
.utility .facts { display: none; white-space: nowrap; gap: var(--s-5); padding: 0; margin: 0; list-style: none; }
.utility .facts li + li::before { content: ""; display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: var(--moss-dim); margin: 0 var(--s-5) 3px 0; opacity: .6; }
.utility strong { color: #fff; font-weight: 500; }
.utility p { margin: 0; white-space: nowrap; }
.status { display: inline-flex; align-items: center; gap: var(--s-2); }
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: transparent; box-shadow: inset 0 0 0 2px var(--moss-dim); flex: none; }
.status[data-state="open"]::before { background: var(--clay-on-dark); box-shadow: none; }
.utility .sample-note { display: flex; align-items: center; gap: var(--s-2); }
@media (max-width: 719px) { .utility .sample-note { display: none; } .utility .wrap { justify-content: center; } }
@media (min-width: 1000px) { .utility .facts { display: flex; } }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 40; background: rgba(248, 242, 234, .96); color: var(--ink); border-bottom: 1px solid var(--line); }
@supports (backdrop-filter: blur(1px)) { .site-header { background: rgba(248, 242, 234, .88); backdrop-filter: saturate(1.3) blur(16px); } }
.site-header .wrap { display: flex; align-items: center; gap: var(--s-3); min-height: var(--header-h); }
.logo { display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; margin-right: auto; color: var(--ink); text-decoration: none; font: 500 1.375rem/1 var(--font-display); font-variation-settings: "opsz" 48; letter-spacing: -.02em; }
.logo svg { width: 28px; height: 28px; color: var(--clay); }
.nav { display: none; }
.nav a { display: inline-flex; align-items: center; white-space: nowrap; min-height: 44px; padding: 0 var(--s-3); font-size: var(--t-small); font-weight: 400; color: var(--ink-soft); text-decoration: none; border-radius: var(--r-control); position: relative; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }
.nav a::after { content: ""; position: absolute; left: var(--s-3); right: var(--s-3); bottom: 6px; height: 1px; background: var(--clay); display: none; }
.nav a:hover::after, .nav a[aria-current="page"]::after { display: block; }
.tool { position: relative; display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; min-width: 44px; justify-content: center; padding: 0 var(--s-3); border: 0; background: none; border-radius: var(--r-control); font-size: var(--t-small); font-weight: 400; text-decoration: none; color: var(--ink-soft); }
.tool:hover { color: var(--ink); background: var(--surface-2); }
.tool svg { width: 22px; height: 22px; }
.tool-count { position: absolute; top: 4px; right: 2px; min-width: 20px; height: 20px; padding: 0 var(--s-1); display: grid; place-items: center; border-radius: 10px; background: var(--clay); color: #fff; font: 500 .875rem/1 var(--font-text); font-variant-numeric: tabular-nums; }
.tool-count[data-n="0"] { background: var(--surface-2); color: var(--ink-soft); }
.header-cta { display: none; }
.menu-btn { border: 1px solid var(--ctl-line); color: var(--ink); }
@media (min-width: 1000px) {
  :root { --header-h: 72px; }
  .nav { display: flex; gap: var(--s-1); margin-right: var(--s-4); }
  .site-header .wrap { gap: var(--s-2); }
  .logo { margin-right: var(--s-5); }
  .header-cta { display: inline-flex; margin-left: var(--s-2); }
  .menu-btn { display: none; }
}

/* mobile menu: native popover */
.menu { margin: 0; inset: 0 0 0 auto; width: min(420px, 100%); height: 100%; max-height: none; border: 0; padding: 0; background: var(--bg); color: var(--ink); box-shadow: var(--shadow-overlay); overflow: auto; }
.menu::backdrop { background: rgba(15, 31, 24, .6); }
.menu:popover-open { display: flex; flex-direction: column; }
.menu-head { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); padding: 0 var(--margin); border-bottom: 1px solid var(--line); }
.menu nav { display: grid; padding: var(--s-4) var(--margin); }
.menu nav a { display: flex; align-items: center; justify-content: space-between; min-height: 60px; border-bottom: 1px solid var(--line); font: 400 1.75rem/1 var(--font-display); font-variation-settings: "opsz" 48; letter-spacing: -.02em; text-decoration: none; color: var(--ink); }
.menu nav a svg { width: 18px; height: 18px; color: var(--muted); }
.menu nav a.sub { min-height: 48px; font: 400 var(--t-body)/1 var(--font-text); letter-spacing: 0; color: var(--ink-soft); }
.menu-foot { margin-top: auto; padding: var(--s-5) var(--margin) var(--s-6); display: grid; gap: var(--s-3); }
.menu-foot .btn { width: 100%; }

/* ---------- footer ----------
   Deepest moss step. Three tiers: brand + one action, four ruled columns (3 sitemap + visit), then the legal line.
   Text on --moss-deep: white 17.1:1, moss-dim 11.6:1, accent-on-dark 10.1:1. Every link is >= 44px tall. */
.site-footer { background: var(--moss-deep); color: var(--moss-dim); padding-block: var(--s-8) var(--s-6); }
.site-footer a { color: #fff; text-decoration-line: none; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.site-footer a:hover { text-decoration-line: underline; }
.footer-top { display: grid; gap: var(--s-5); align-items: end; padding-bottom: var(--s-7); }
.footer-brand { display: grid; gap: var(--s-3); max-width: 44ch; }
.footer-brand .logo { color: #fff; margin: 0; }
.footer-brand .logo svg { color: var(--clay-on-dark); }
.footer-brand p { font-size: var(--t-body); line-height: 1.5; }
.footer-top .btn { justify-self: start; }
.footer-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-7) var(--s-5); }
.footer-col { padding-top: var(--s-4); border-top: 1px solid var(--moss-line); min-width: 0; }
.site-footer h2 { margin: 0 0 var(--s-2); font: 500 var(--t-meta)/1.4 var(--font-text); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--clay-on-dark); }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; }
.site-footer li a { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; font-size: var(--t-small); line-height: 1.3; }
.footer-visit { display: grid; gap: var(--s-1); font-size: var(--t-small); line-height: var(--lh-small); }
.footer-visit > * { max-width: 320px; }
.footer-visit address { font-style: normal; color: var(--moss-dim); margin-bottom: var(--s-2); }
.footer-hours { display: grid; gap: 0; margin: 0 0 var(--s-1); }
.footer-hours div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0 var(--s-3); }
.footer-hours dt, .footer-hours dd { margin: 0; }
.footer-hours dt { color: var(--moss-dim); }
.footer-hours dd { color: #fff; font-variant-numeric: tabular-nums; }
.footer-visit a { display: inline-flex; align-items: center; min-height: 44px; overflow-wrap: anywhere; }
.footer-legal { margin-top: var(--s-8); padding-top: var(--s-5); border-top: 1px solid var(--moss-line); display: grid; gap: var(--s-3); font-size: var(--t-small); line-height: var(--lh-small); }
.footer-legal p { max-width: 76ch; }
.footer-legal strong { color: #fff; font-weight: 500; }
.footer-legal .legal-row { display: grid; gap: var(--s-2) var(--s-5); align-items: center; }
.footer-legal .to-top { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; justify-self: start; }
@media (min-width: 720px) {
  .footer-top { grid-template-columns: minmax(0, 1fr) auto; gap: var(--s-7); }
  .footer-top .btn { justify-self: end; }
  .footer-legal .legal-row { grid-template-columns: minmax(0, 1fr) auto; }
}
@media (max-width: 999px) { .footer-visit { grid-column: 1 / -1; order: -1; } .footer-visit h2 { margin-bottom: var(--s-3); } }
@media (min-width: 1000px) { .footer-cols { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-6); } }

/* =========================================================
   PREMIUM IMAGERY  ·  .img-fade (dissolving edges)  +  .img-frame (crisp, rounded, ringed)
   ---------------------------------------------------------
   Both are reusable CSS utilities. They style whatever <picture>/<img> sits inside the wrapper, so
   REPLACING THE PHOTO (new src, new <picture>, new file) KEEPS EVERYTHING. Nothing is baked into
   the image files. Captions, flags and badges live outside <picture>, so they stay crisp.

   MARKUP
     <figure class="img-fade"><picture>...<img ...></picture><figcaption>..</figcaption></figure>
     <figure class="img-frame"><picture>...<img ...></picture></figure>
   Use .img-fade for atmospheric / full-width photographs that should melt into the page (hero,
   flow, workshop). Use .img-frame for photographs inside cards and lists, where a crisp rounded
   edge reads as more premium than a soft one.

   WHAT EVERY PHOTO GETS (all tokens live in :root)
     tonal grade   filter: var(--img-grade)     very light contrast/saturation lift, never heavy
     vignette      picture::after, --vig        radial edge darkening, 0.16 by default, 0 = off
     placeholder   background: var(--img-ph)    shows while a lazy photo loads
     stability     keep width/height + aspect-ratio on the wrapper; object-fit: cover; no layout shift
   .img-fade extras
     --fade-size / --fade-x / --fade-y   fade length (default clamp(24px, 6vw, 88px))
     .img-fade--l .--r .--t .--b .--x .--y   which edges fade (or --fade-t/-r/-b/-l: 1 or 0)
     smootherstep ramp (9 stops per edge), so the dissolve has no visible start line
     hairline ring appears ONLY on edges that stay crisp (a 1px ring on a fading edge would be wrong)
   .img-frame extras
     radius var(--img-radius) 12px, inset hairline ring var(--img-ring), soft depth var(--img-shadow)
   --ring: transparent  on a wrapper turns the ring off (hero touches the viewport edges)

   FALLBACKS
     No mask support or forced-colors: the mask is dropped and the photo shows in full with the
     normal media radius. Photos are always static: no fade-in, zoom or Ken Burns.
   ========================================================= */
.img-fade {
  --fade-size: clamp(24px, 6vw, 88px);
  --fade-x: var(--fade-size);
  --fade-y: var(--fade-size);
  --fade-t: 1; --fade-r: 1; --fade-b: 1; --fade-l: 1;
}
.img-fade--l { --fade-t: 0; --fade-r: 0; --fade-b: 0; }
.img-fade--r { --fade-t: 0; --fade-b: 0; --fade-l: 0; }
.img-fade--t { --fade-r: 0; --fade-b: 0; --fade-l: 0; }
.img-fade--b { --fade-t: 0; --fade-r: 0; --fade-l: 0; }
.img-fade--x { --fade-t: 0; --fade-b: 0; }
.img-fade--y { --fade-r: 0; --fade-l: 0; }

/* shared photo treatment */
:where(.img-fade, .img-frame) picture { position: relative; display: block; height: 100%; overflow: hidden; background: var(--img-ph); }
:where(.img-fade, .img-frame) picture img { height: 100%; filter: var(--img-grade); }
:where(.img-fade, .img-frame) picture::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: radial-gradient(125% 100% at 50% 42%, transparent 58%, rgb(27 42 35 / var(--vig, .16)) 100%);
  border: 0 solid var(--ring, var(--img-ring));
}
/* ring only on crisp sides of a fading photo */
.img-fade picture::after {
  border-width: calc((1 - var(--fade-t)) * 1px) calc((1 - var(--fade-r)) * 1px) calc((1 - var(--fade-b)) * 1px) calc((1 - var(--fade-l)) * 1px);
}
/* crisp, rounded, ringed, soft depth */
.img-frame picture { border-radius: var(--img-radius); box-shadow: var(--img-shadow); }
.img-frame picture::after { border-width: 1px; }

@supports ((-webkit-mask-image: linear-gradient(#000, #000)) or (mask-image: linear-gradient(#000, #000))) {
  @media not (forced-colors: active) {
    .img-fade picture, .img-fade > img {
      /* smootherstep-eased ramps: alpha = 1 - fade * (1 - s(t)), s(t) = 6t^5 - 15t^4 + 10t^3 */
      --_ax: linear-gradient(to right,
        rgb(0 0 0 / calc(1 - var(--fade-l) * 1.000)) 0,
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.984)) calc(var(--fade-x) * 0.125),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.896)) calc(var(--fade-x) * 0.25),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.725)) calc(var(--fade-x) * 0.375),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.500)) calc(var(--fade-x) * 0.5),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.275)) calc(var(--fade-x) * 0.625),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.104)) calc(var(--fade-x) * 0.75),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.016)) calc(var(--fade-x) * 0.875),
        rgb(0 0 0 / calc(1 - var(--fade-l) * 0.000)) calc(var(--fade-x) * 1),
        #000 var(--fade-x),
        #000 calc(100% - var(--fade-x)),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.000)) calc(100% - var(--fade-x) * 1),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.016)) calc(100% - var(--fade-x) * 0.875),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.104)) calc(100% - var(--fade-x) * 0.75),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.275)) calc(100% - var(--fade-x) * 0.625),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.500)) calc(100% - var(--fade-x) * 0.5),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.725)) calc(100% - var(--fade-x) * 0.375),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.896)) calc(100% - var(--fade-x) * 0.25),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 0.984)) calc(100% - var(--fade-x) * 0.125),
        rgb(0 0 0 / calc(1 - var(--fade-r) * 1.000)) 100%);
      --_ay: linear-gradient(to bottom,
        rgb(0 0 0 / calc(1 - var(--fade-t) * 1.000)) 0,
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.984)) calc(var(--fade-y) * 0.125),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.896)) calc(var(--fade-y) * 0.25),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.725)) calc(var(--fade-y) * 0.375),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.500)) calc(var(--fade-y) * 0.5),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.275)) calc(var(--fade-y) * 0.625),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.104)) calc(var(--fade-y) * 0.75),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.016)) calc(var(--fade-y) * 0.875),
        rgb(0 0 0 / calc(1 - var(--fade-t) * 0.000)) calc(var(--fade-y) * 1),
        #000 var(--fade-y),
        #000 calc(100% - var(--fade-y)),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.000)) calc(100% - var(--fade-y) * 1),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.016)) calc(100% - var(--fade-y) * 0.875),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.104)) calc(100% - var(--fade-y) * 0.75),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.275)) calc(100% - var(--fade-y) * 0.625),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.500)) calc(100% - var(--fade-y) * 0.5),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.725)) calc(100% - var(--fade-y) * 0.375),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.896)) calc(100% - var(--fade-y) * 0.25),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 0.984)) calc(100% - var(--fade-y) * 0.125),
        rgb(0 0 0 / calc(1 - var(--fade-b) * 1.000)) 100%);
      -webkit-mask-image: var(--_ax), var(--_ay);
      -webkit-mask-composite: source-in;
      mask-image: var(--_ax), var(--_ay);
      mask-composite: intersect;
    }
  }
}
/* no mask support, or forced colours: show the whole photo with the normal media radius */
@supports not ((-webkit-mask-image: linear-gradient(#000, #000)) or (mask-image: linear-gradient(#000, #000))) {
  .img-fade picture, .img-fade > img { border-radius: var(--img-radius); overflow: hidden; }
}
@media (forced-colors: active) {
  .img-fade picture, .img-fade > img { border-radius: var(--img-radius); overflow: hidden; }
  :where(.img-fade, .img-frame) picture::after { display: none; }
}
