/* ==========================================================================
   Solvra — Lorana Services Limited
   Design system. Swiss technical documentation, oxblood on bone.
   Tokens verified for WCAG 2.2 AA (see DESIGN.md contrast table).
   ========================================================================== */

/* ---------- 1. Tokens ---------------------------------------------------- */
/* Direction B — Acid Lime on Charcoal. Every text pair below is verified in
   DESIGN.md; lime is a FILL and a signal, never text on a light ground. */
:root {
  /* Light surfaces */
  --paper:        oklch(97.0% 0.003 250);   /* #F4F5F7 */
  --paper-2:      oklch(94.2% 0.004 250);   /* #EAECEE */
  --paper-3:      oklch(90.0% 0.005 250);   /* #DBDEE1 */
  --rule:         oklch(88.0% 0.005 250);   /* #D5D8DB decorative hairline */
  --border-strong:oklch(62.0% 0.008 250);   /* #83878B form borders, 3.34:1 */

  /* Text on light */
  --ink:          oklch(20.0% 0.008 265);   /* #14161A  16.60:1 */
  --ink-2:        oklch(40.0% 0.008 265);   /* #45484C   8.45:1 */
  --ink-3:        oklch(52.0% 0.008 265);   /* #67696E   5.05:1 */

  /* Charcoal — the dominant brand surface. Names kept from the previous
     system so the diagrams and inline styles keep their token contract. */
  --claret:       oklch(24.0% 0.012 265);   /* #1C1F25 brand charcoal */
  --claret-deep:  oklch(21.5% 0.009 265);   /* #17191E */
  --claret-dark:  oklch(17.5% 0.008 265);   /* #0F1014 deepest: hero, footer */
  --claret-card:  oklch(27.5% 0.010 265);   /* #25282D raised card on dark */
  --claret-hair:  oklch(29.0% 0.010 265);   /* #292B30 hairline on dark */
  --claret-lift:  oklch(35.0% 0.011 265);   /* #383B40 decorative border on dark */
  --claret-edge:  oklch(54.0% 0.012 265);   /* #6B6F76 real UI boundary, 3.75:1 */
  --claret-tint:  oklch(96.0% 0.035 128);   /* lime wash for hover on light */
  --claret-line:  oklch(82.0% 0.006 250);   /* neutral light border */

  /* Accent */
  --citron:       oklch(92.0% 0.190 122);   /* #D0F854 lime — fill + signal only */
  --citron-2:     oklch(86.0% 0.185 124);   /* #B8E448 pressed lime */
  --mint:         oklch(79.0% 0.150 168);   /* #30D9A8 secondary signal */
  --olive:        oklch(48.0% 0.115 133);   /* #436B1E lime-family TEXT on light, 5.76:1 */

  /* Text on charcoal */
  --on-claret:    oklch(97.0% 0.003 250);   /* 17.40:1 on deepest */
  --on-claret-2:  oklch(78.0% 0.006 250);   /*  9.48:1 */
  --on-claret-3:  oklch(66.0% 0.008 250);   /*  6.10:1 */

  /* Type */
  --font-sans: 'Schibsted Grotesk', ui-sans-serif, system-ui, 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'Chivo Mono', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;

  --fs-display: clamp(2.6rem, 1.55rem + 4.4vw, 4.75rem);
  --fs-h1:      clamp(2.25rem, 1.5rem + 3.2vw, 4rem);
  --fs-h2:      clamp(1.75rem, 1.3rem + 1.9vw, 2.75rem);
  --fs-h3:      clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --fs-h4:      clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  --fs-lead:    clamp(1.0625rem, 1rem + 0.4vw, 1.3125rem);
  --fs-body:    1.0625rem;
  --fs-sm:      0.9375rem;
  --fs-xs:      0.8125rem;
  --fs-label:   0.75rem;

  /* Space */
  --sp-section: clamp(4.5rem, 9vw, 8.5rem);
  --gutter:     clamp(1.25rem, 4vw, 3.5rem);
  --container:  1280px;
  --measure:    68ch;

  /* Form — modern fintech geometry: soft radii, pill controls */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-pill: 999px;
  --sh-1: 0 1px 2px oklch(20% 0.008 265 / 0.06), 0 4px 12px -6px oklch(20% 0.008 265 / 0.10);
  --sh-2: 0 2px 6px oklch(20% 0.008 265 / 0.07), 0 18px 40px -22px oklch(20% 0.008 265 / 0.22);
  --sh-3: 0 30px 70px -30px oklch(20% 0.008 265 / 0.32);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
}

/* ---------- 2. Reset ----------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
  /* clip, not hidden: no scroll container, so position:sticky keeps working */
  overflow-x: clip;
}
body {
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-synthesis-weight: none;
  overflow-x: clip;
}
img, svg, canvas { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; }
ul, ol { padding: 0; list-style: none; }
:target { scroll-margin-top: 7rem; }

/* ---------- 3. Typography ------------------------------------------------ */
h1, h2, h3, h4, h5 {
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); line-height: 1.15; letter-spacing: -0.024em; font-weight: 750; }
h4 { font-size: var(--fs-h4); line-height: 1.25; letter-spacing: -0.018em; font-weight: 750; }
p  { text-wrap: pretty; }
.lead {
  font-size: var(--fs-lead);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 56ch;
}
.prose { max-width: var(--measure); }
.prose p + p { margin-top: 1.1em; }
.prose > * + h3 { margin-top: 2.2em; }
.prose > * + h4 { margin-top: 1.8em; }
/* Legal sub-headings: h3 for a correct outline, h4 for size. */
.prose .subh { font-size: var(--fs-h4); margin-top: 1.8em; letter-spacing: -0.012em; }
.prose > .subh:first-child { margin-top: 0; }
.prose h3, .prose h4 { margin-bottom: 0.6em; }
.prose ul { margin: 1.1em 0; display: grid; gap: 0.5rem; }
.prose ul li { padding-left: 1.4rem; position: relative; color: var(--ink-2); }
.prose ul li::before {
  content: ''; position: absolute; left: 0; top: 0.6em;
  width: 7px; height: 7px; border-radius: 2px; background: var(--citron);
  outline: 1px solid var(--claret-line);
}
.prose a { color: var(--olive); font-weight: 600; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose strong { font-weight: 640; color: var(--ink); }

/* Mono label — the document-numbering habit that is the identity */
.label {
  font-size: var(--fs-label);
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

/* ---------- 4. Layout --------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: var(--sp-section); position: relative; }
.section--tight { padding-block: clamp(3rem, 6vw, 5rem); }
.band { background: var(--paper-2); }

/* Section head: mono index + full-bleed hairline + heading */
.shead { margin-bottom: clamp(2.25rem, 4vw, 3.5rem); }
.shead__meta {
  display: flex; align-items: baseline; gap: 1rem;
  padding-bottom: 0.85rem; margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
  border-bottom: 1px solid var(--rule);
}
.shead__idx {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2rem; padding: 0.28rem 0.55rem;
  font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 600;
  letter-spacing: 0.04em; font-variant-numeric: tabular-nums;
  color: var(--ink); background: var(--citron);
  border-radius: var(--r-pill);
}
.shead__kicker { flex: 1; }
.shead__grid { display: grid; gap: clamp(1rem, 3vw, 3rem); align-items: end; }
@media (min-width: 900px) { .shead__grid { grid-template-columns: minmax(0,1.15fr) minmax(0,1fr); } }

/* Dark section variant */
.on-dark { color: var(--on-claret); }
.on-dark h1, .on-dark h2, .on-dark h3, .on-dark h4 { color: var(--on-claret); }
.on-dark p, .on-dark .lead { color: var(--on-claret-2); line-height: 1.71; }
.on-dark .label { color: var(--on-claret-3); }
.on-dark .shead__meta { border-bottom-color: var(--claret-hair); }
.on-dark .shead__idx { color: var(--claret-dark); background: var(--citron); }

/* ---------- 5. Utility -------------------------------------------------- */
.skip {
  position: absolute; left: var(--gutter); top: 0.5rem; z-index: 200;
  transform: translateY(-160%);
  background: var(--citron); color: var(--claret-dark);
  padding: 0.7rem 1.2rem; font-size: var(--fs-sm); font-weight: 700;
  text-decoration: none; border-radius: var(--r-pill);
  transition: transform 0.2s var(--ease);
}
.skip:focus-visible { transform: translateY(0); }
:where(a, button, summary, input, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 3px;
}
.on-dark :where(a, button, summary, input, textarea, [tabindex]):focus-visible,
.hero :where(a, button, summary):focus-visible { outline-color: var(--citron); }
.vh {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ---------- 6. Buttons -------------------------------------------------- */
.btn {
  --btn-bg: var(--citron);
  --btn-fg: var(--claret-dark);
  position: relative;
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.9rem 1.5rem;
  font-size: var(--fs-sm); font-weight: 700;
  letter-spacing: -0.005em;
  text-decoration: none; white-space: nowrap;
  border: 0; border-radius: var(--r-pill);
  background: var(--btn-bg); color: var(--btn-fg);
  cursor: pointer; isolation: isolate; overflow: hidden;
  transition: transform 0.3s var(--ease), background-color 0.2s var(--ease);
}
.btn:hover { transform: translateY(-2px); background: var(--citron-2); }
.btn:active { transform: translateY(0); }
.btn__arrow { transition: transform 0.4s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }

/* Kept as a wrapper for markup compatibility; renders as a plain solid button */
.btn--shimmer { padding: 0; background: var(--btn-bg); }
.btn--shimmer .btn__face {
  position: relative; z-index: 1;
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.9rem 1.5rem; width: 100%; justify-content: center;
  border-radius: inherit; color: var(--btn-fg);
}

.btn--ghost {
  --btn-bg: transparent; --btn-fg: var(--ink);
  box-shadow: inset 0 0 0 1px var(--border-strong);
}
.btn--ghost:hover { --btn-bg: var(--paper); box-shadow: inset 0 0 0 1px var(--ink), var(--sh-1); }

.btn--onDark {
  --btn-bg: oklch(100% 0 0 / 0.06); --btn-fg: var(--on-claret);
  box-shadow: inset 0 0 0 1px var(--claret-edge);
  backdrop-filter: blur(6px);
}
.btn--onDark:hover { --btn-bg: oklch(100% 0 0 / 0.12); box-shadow: inset 0 0 0 1px var(--citron); }

/* Text link */
.tlink {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: var(--fs-sm); font-weight: 700; color: var(--olive);
  text-decoration: none; padding-bottom: 3px;
  background-image: linear-gradient(var(--olive), var(--olive));
  background-size: 100% 1.5px; background-repeat: no-repeat; background-position: 0 100%;
  transition: background-size 0.4s var(--ease), color 0.25s var(--ease);
}
.tlink:hover { background-size: 0% 1.5px; color: var(--ink); }
.tlink svg { transition: transform 0.4s var(--ease); }
.tlink:hover svg { transform: translateX(4px); }
.on-dark .tlink, .hero .tlink {
  color: var(--citron); background-image: linear-gradient(var(--citron), var(--citron));
}
.on-dark .tlink:hover, .hero .tlink:hover { color: var(--on-claret); }

/* ---------- 7. Header --------------------------------------------------- */
.hdr {
  position: sticky; top: 0; z-index: 100;
  /* Solid charcoal at rest so it reads continuous with the dark hero below it
     (transparent would expose the light page ground, not the hero). */
  background: var(--claret-dark);
  border-bottom: 1px solid transparent;
  transition: background-color 0.45s var(--ease), border-color 0.45s var(--ease),
              backdrop-filter 0.45s var(--ease);
}
.hdr[data-stuck='true'] {
  background: oklch(17.5% 0.008 265 / 0.86);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  border-bottom-color: oklch(100% 0 0 / 0.10);
}
.hdr__bar {
  display: flex; align-items: center; gap: clamp(1rem, 3vw, 2.5rem);
  min-height: 72px;
}
.hdr__nav { display: none; margin-left: auto; }
.hdr__cta { display: none; }

.progress {
  position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%;
  transform: scaleX(0); transform-origin: left;
  background: var(--citron);
}

/* Logo lockup: S5s "stepped S" bars + "Solvra" in Archivo 800 italic, wide
   (chosen 2026-10-09). Main bars take currentColor (bone), the bottom bar
   the citron accent; the word is one colour, no split.
   --logo-fs is the one size knob. The word takes it as its font-size and the
   mark takes it as its box, so .logo--lg (footer) scales BOTH; the mark can
   never be left at header size. The mark's path inks 80.6% of its 64x64
   viewBox, so a 1em box lands the drawn height at ~1.12x the wordmark cap
   height — cap-matched with the small overshoot a round open form needs.
   Colour is currentColor on .logo__m; header and footer are both
   --claret-dark, so citron (15.61:1) is correct on both grounds. */
.logo {
  --logo-fs: 1.4375rem;
  display: inline-flex; align-items: center; gap: 0.18em;
  font-size: var(--logo-fs); line-height: 1; text-decoration: none;
}
/* The header logo is a flex item, so its inline-flex blockifies and its
   baseline is irrelevant. The footer one is alone in a <div>, where an
   inline-flex takes the baseline of its FIRST item — now the SVG, whose
   baseline is its bottom edge, which would lift the whole lockup and pad the
   line box. Taking it out of the line box keeps it where it was. */
.logo--lg { --logo-fs: 1.625rem; display: flex; width: fit-content; }
.logo__m {
  flex: none; width: 1em; height: 1em; display: block;
  color: var(--on-claret); --mark-accent: var(--citron);
  transition: opacity 0.25s var(--ease);
}
.logo__word {
  font-family: 'Archivo', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 1em; font-weight: 800; font-style: italic; font-stretch: 125%;
  letter-spacing: -0.03em; color: var(--on-claret); line-height: 1;
  transition: opacity 0.25s var(--ease);
}
.logo:hover .logo__word, .logo:hover .logo__m { opacity: 0.8; }

/* Nav */
.nav { display: flex; align-items: center; gap: clamp(0.25rem, 1.4vw, 1.1rem); }
.nav__item { position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.55rem 0.7rem;
  font-size: var(--fs-sm); font-weight: 500;
  color: var(--on-claret-2); text-decoration: none;
  border-radius: var(--r-sm);
  transition: color 0.22s var(--ease), background-color 0.22s var(--ease);
}
.nav__link:hover { color: var(--on-claret); background: oklch(100% 0 0 / 0.08); }
/* aria-current="page" = this IS the page. citron text 15.52:1 on the header
   ground, plus a citron 2px rule (15.52:1) so it is not colour-only. */
.nav__link[aria-current='page'] { color: var(--citron); }
/* The panel is opaque and starts at the <li>'s bottom edge, so without this the
   open panel paints over the current-page marker underneath it. */
.nav__link[aria-current]::after { z-index: 1; }
.nav__link[aria-current='page']::after {
  content: ''; position: absolute; left: 0.7rem; right: 0.7rem; bottom: -0.15rem;
  height: 2px; background: var(--citron);
}
/* aria-current="true" = ancestor of the page. Deliberately quieter than the
   page state: full-strength label (17.40:1) over a neutral rule (3.75:1). */
/* --claret-edge is only 2.57:1 once the header is translucent-over-paper, and
   colour was carrying this state alone. Lighter rule + a weight change. */
.nav__link[aria-current='true'] { color: var(--on-claret); font-weight: 600; }
.nav__link[aria-current='true']::after {
  content: ''; position: absolute; left: 0.7rem; right: 0.7rem; bottom: -0.15rem;
  height: 2px; background: var(--on-claret-3);
}
.nav__chev { transition: transform 0.3s var(--ease); }
.nav__item--has:hover .nav__chev, .nav__item--has:focus-within .nav__chev { transform: rotate(180deg); }

/* Dropdown.
   top:100% — NOT calc(100% + gap). The <li> is only as tall as the link, so a
   positional offset leaves a strip that belongs to neither trigger nor panel
   and the panel starts closing as the pointer crosses it (WCAG 1.4.13
   Hoverable). The gap is carried by the panel's own padding-top instead, so
   the hit area is continuous. */
.nav__panel {
  position: absolute; top: 100%; left: -0.6rem;
  width: min(30rem, calc(100vw - 2rem));
  background: var(--paper); color: var(--ink);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  box-shadow: 0 30px 70px -30px oklch(19% 0.02 32 / 0.42), 0 2px 8px -4px oklch(19% 0.02 32 / 0.2);
  padding: 1.05rem 0.5rem 0.5rem;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity 0.28s var(--ease), transform 0.34s var(--ease), visibility 0.28s;
}
.nav__item--has:hover .nav__panel, .nav__item--has:focus-within .nav__panel {
  opacity: 1; visibility: visible; transform: translateY(0);
}
/* Escape must be able to dismiss the panel. :focus-within can never be
   un-matched from the keyboard while focus is anywhere inside the <li> —
   including on the trigger itself — so JS sets this state attribute. Placed
   after the :hover/:focus-within rule: equal specificity, later wins. */
.nav__item--has[data-collapsed='true'] .nav__panel {
  opacity: 0; visibility: hidden; transform: translateY(-8px);
}
.nav__item--has[data-collapsed='true'] .nav__chev { transform: none; }
.nav__panel::before {
  content: ''; position: absolute; top: -1px; left: 1.4rem; width: 2.5rem; height: 3px;
  background: var(--citron); border-radius: 0 0 3px 3px;
}
.nav__sub {
  display: grid; grid-template-columns: auto 1fr; gap: 0 0.9rem; align-items: start;
  padding: 0.72rem 0.85rem; border-radius: var(--r-sm); text-decoration: none;
  transition: background-color 0.2s var(--ease);
}
.nav__sub:hover { background: var(--claret-tint); }
/* The panel child you are actually on. Inset rule instead of a border so the
   grid does not shift: olive 5.64:1 on the tint, 5.76:1 against the panel. */
.nav__sub[aria-current='page'] {
  background: var(--claret-tint);
  box-shadow: inset 3px 0 0 var(--olive);
}
.nav__sub[aria-current='page'] .nav__sub-t { color: var(--ink); font-weight: 700; }
.nav__sub-idx { font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 600; color: var(--olive); padding-top: 0.28em; }
.nav__sub-t { font-size: var(--fs-sm); font-weight: 600; color: var(--ink); letter-spacing: -0.008em; }
.nav__sub-d { font-size: var(--fs-xs); color: var(--ink-3); line-height: 1.45; grid-column: 2; }

/* Hamburger */
.burger {
  margin-left: auto; width: 44px; height: 44px;
  display: grid; place-items: center;
  background: oklch(100% 0 0 / 0.05); border: 1px solid var(--claret-edge);
  border-radius: var(--r-pill); cursor: pointer;
}
.burger__box { width: 20px; height: 13px; position: relative; }
.burger__box i {
  position: absolute; left: 0; height: 1.5px; width: 100%;
  background: var(--on-claret); border-radius: 2px;
  transition: transform 0.4s var(--ease), opacity 0.24s var(--ease), width 0.4s var(--ease);
}
.burger__box i:nth-child(1) { top: 0; }
.burger__box i:nth-child(2) { top: 5.75px; width: 72%; }
.burger__box i:nth-child(3) { top: 11.5px; }
.burger[aria-expanded='true'] .burger__box i:nth-child(1) { transform: translateY(5.75px) rotate(45deg); }
.burger[aria-expanded='true'] .burger__box i:nth-child(2) { opacity: 0; width: 0; }
.burger[aria-expanded='true'] .burger__box i:nth-child(3) { transform: translateY(-5.75px) rotate(-45deg); }

@media (min-width: 1080px) {
  .hdr__nav { display: block; }
  .hdr__cta { display: inline-flex; }
  .burger { display: none; }
}

/* Mobile drawer */
.drawer {
  position: fixed; inset: 72px 0 0; z-index: 99;
  background: var(--claret-dark);
  padding: 1.5rem var(--gutter) 3rem;
  overflow-y: auto;
  clip-path: inset(0 0 100% 0);
  transition: clip-path 0.55s var(--ease);
}
.drawer[data-open='true'] { clip-path: inset(0 0 0 0); }
/* Real list semantics: the nested <ul> carries the parent/child relationship,
   the indent below only draws it. Every level keeps the same 0.15rem rhythm. */
.drawer__list, .drawer__list ul, .drawer__list li { display: grid; gap: 0.15rem; }
.drawer a {
  display: flex; align-items: baseline; gap: 0.9rem;
  padding: 0.95rem 0.25rem; text-decoration: none;
  font-size: 1.125rem; font-weight: 600;
  color: var(--on-claret); letter-spacing: -0.015em;
  border-bottom: 1px solid var(--claret-hair);
  opacity: 0; transform: translateY(14px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.drawer[data-open='true'] a { opacity: 1; transform: none; }
.drawer a i {
  font-family: var(--font-mono); font-style: normal; font-size: 0.6875rem;
  font-weight: 600; color: var(--citron);
}
.drawer a[data-sub] { padding-left: 1.9rem; font-size: var(--fs-body); font-weight: 500; color: var(--on-claret-2); }
/* You-are-here in the drawer. citron 15.52:1 on the drawer ground for the
   page itself; neutral 3.75:1 rail for the ancestor row. */
.drawer a[aria-current='page'],
.drawer a[data-sub][aria-current='page'] {
  color: var(--citron); box-shadow: inset 3px 0 0 var(--citron);
}
.drawer a[aria-current='true'] {
  color: var(--on-claret); box-shadow: inset 3px 0 0 var(--claret-edge);
}
.drawer__foot { margin-top: 2rem; display: grid; gap: 0.9rem; }
@media (min-width: 1080px) { .drawer { display: none; } }

/* ---------- 8. Hero ----------------------------------------------------- */
.hero {
  position: relative;
  background: var(--claret-dark);
  color: var(--on-claret);
  overflow: clip;
  isolation: isolate;
}
/* 21st.dev "Aurora Background", recoloured — slow claret bloom */
/* No decorative bloom: the hero is flat charcoal carrying a hairline grid and
   the animated rails. Gradient glows read as generated. */
/* 21st.dev "Background Paths" — transaction rails drifting across the drench */
.hero__rails { position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0.85; }
.hero__grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, oklch(100% 0 0 / 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, oklch(100% 0 0 / 0.05) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: radial-gradient(120% 90% at 50% 0%, oklch(0% 0 0) 12%, transparent 72%);
}
.hero__inner { position: relative; z-index: 2; padding-block: clamp(3.5rem, 8vw, 6.5rem) clamp(3rem, 6vw, 4.5rem); }
.hero__grid2 { display: grid; gap: clamp(2.5rem, 5vw, 4rem); align-items: center; }
@media (min-width: 1000px) { .hero__grid2 { grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr); } }

.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 0.75rem;
  padding: 0.45rem 0.95rem 0.45rem 0.7rem;
  border: 1px solid var(--claret-edge); border-radius: var(--r-pill);
  background: oklch(100% 0 0 / 0.05);
  font-size: var(--fs-label); font-weight: 700;
  letter-spacing: 0.11em; text-transform: uppercase; color: var(--on-claret-2);
  margin-bottom: clamp(1.35rem, 3vw, 2rem);
}
.pulse { position: relative; width: 7px; height: 7px; flex: none; }
.pulse i { position: absolute; inset: 0; border-radius: 50%; background: var(--citron); }
.pulse i:first-child { animation: ping 2.4s var(--ease-io) infinite; }
@keyframes ping { 0% { transform: scale(1); opacity: 0.85; } 70%, 100% { transform: scale(3.2); opacity: 0; } }

.hero h1 {
  font-size: var(--fs-display);
  font-weight: 800;
  letter-spacing: -0.042em; line-height: 0.98;
  margin-bottom: clamp(1.1rem, 2.5vw, 1.6rem);
}
/* Per-word reveal, driven by the variable width axis */
.hero h1 .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.hero h1 .w > span {
  display: inline-block;
  transform: translateY(105%);
  opacity: 0;
  animation: word-rise 1.05s var(--ease) forwards;
  animation-delay: calc(var(--i) * 78ms + 120ms);
}
@keyframes word-rise {
  to { transform: translateY(0); opacity: 1; }
}
.hero .lead { color: var(--on-claret-2); max-width: 48ch; line-height: 1.62; }
.hero__actions {
  display: flex; flex-wrap: wrap; gap: 0.85rem;
  margin-top: clamp(1.75rem, 3.5vw, 2.5rem);
  opacity: 0; animation: fade-up 0.9s var(--ease) 0.72s forwards;
}
@keyframes fade-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

.hero__note {
  margin-top: clamp(1.75rem, 3.5vw, 2.5rem);
  padding-top: 1.1rem; border-top: 1px solid oklch(100% 0 0 / 0.09);
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem;
  opacity: 0; animation: fade-up 0.9s var(--ease) 0.86s forwards;
}
.hero__note span {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: var(--fs-xs); font-weight: 600;
  letter-spacing: 0.07em; text-transform: uppercase; color: var(--on-claret-3);
}
.hero__note span::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--citron); flex: none;
}

/* ---------- 9. Authorisation console ------------------------------------ */
/* Shows the mechanism: a live switch feed instead of a phone mockup */
.console {
  position: relative;
  background: oklch(100% 0 0 / 0.04);
  border: 1px solid oklch(100% 0 0 / 0.10);
  border-radius: var(--r-lg);
  box-shadow: 0 40px 90px -40px oklch(10% 0.01 265 / 0.9), inset 0 1px 0 oklch(100% 0 0 / 0.06);
  overflow: hidden;
  opacity: 0; animation: fade-up 1s var(--ease) 0.55s forwards;
  backdrop-filter: blur(6px);
}
.console::before {
  content: ''; position: absolute; top: 0; left: 0; width: 4.5rem; height: 2px;
  background: var(--citron);
}
.console__top {
  display: flex; align-items: center; gap: 0.85rem;
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid oklch(100% 0 0 / 0.08);
  background: oklch(100% 0 0 / 0.03);
}
.console__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--citron); flex: none; }
.console__title {
  font-family: var(--font-mono); font-size: var(--fs-label); font-weight: 600;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--on-claret-2);
}
.console__badge {
  margin-left: auto;
  font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 500;
  letter-spacing: 0.07em; color: var(--citron);
  padding: 0.22rem 0.55rem; border: 1px solid oklch(92% 0.19 122 / 0.4); border-radius: var(--r-pill);
  background: oklch(92% 0.19 122 / 0.10);
}
.console__head, .console__row {
  display: grid;
  grid-template-columns: 4.4rem minmax(0, 1fr) auto 3.4rem;
  gap: 0.55rem; align-items: center;
  padding: 0.6rem 1.05rem;
  font-family: var(--font-mono); font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.console__amt { text-align: right; }
.console__head {
  color: var(--on-claret-3); font-size: 0.6875rem; letter-spacing: 0.08em;
  text-transform: uppercase; border-bottom: 1px solid oklch(100% 0 0 / 0.08);
}
.console__feed { min-height: 15.5rem; }
.console__row {
  color: var(--on-claret-2);
  border-bottom: 1px solid oklch(100% 0 0 / 0.055);
  animation: row-in 0.55s var(--ease) both;
}
@keyframes row-in {
  from { opacity: 0; transform: translateY(-9px); background: oklch(92% 0.19 122 / 0.14); }
  to   { opacity: 1; transform: none; background: transparent; }
}
.console__row b { color: var(--on-claret); font-weight: 500; }
.console__net { display: flex; align-items: center; gap: 0.45rem; color: var(--on-claret-2); }
.console__net i { width: 4px; height: 4px; border-radius: 50%; background: var(--on-claret-3); flex: none; }
.console__ok {
  display: inline-flex; align-items: center; gap: 0.35rem;
  color: var(--citron); font-weight: 500;
}
.console__ok::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--citron); }
.console__ms { color: var(--on-claret-3); text-align: right; }
.console__foot {
  display: flex; flex-wrap: wrap; gap: 0.35rem 1.4rem;
  padding: 0.85rem 1.1rem;
  border-top: 1px solid oklch(100% 0 0 / 0.08);
  background: oklch(100% 0 0 / 0.03);
  font-family: var(--font-mono); font-size: 0.6875rem;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--on-claret-3);
  font-variant-numeric: tabular-nums;
}
.console__foot b { color: var(--citron); font-weight: 600; }

/* ---------- 10. Figure ledger (stats) ----------------------------------- */
.ledger {
  position: relative; z-index: 2;
  display: grid; gap: 1px;
  background: var(--claret-lift);
  border: 1px solid var(--claret-lift);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-top: clamp(3rem, 6vw, 4.5rem);
}
@media (min-width: 720px) { .ledger { grid-template-columns: repeat(3, 1fr); } }
.ledger__cell {
  background: var(--claret);
  padding: clamp(1.35rem, 3vw, 2rem);
  display: grid; gap: 0.5rem;
  transition: background-color 0.4s var(--ease);
}
.ledger__cell:hover { background: var(--claret-card); }
.ledger__lab {
  font-size: var(--fs-label); font-weight: 700;
  letter-spacing: 0.11em; text-transform: uppercase; color: var(--on-claret-3);
}
.ledger__fig {
  font-family: var(--font-mono); font-weight: 600;
  font-size: clamp(2.1rem, 1.4rem + 2.6vw, 3.1rem);
  line-height: 1; letter-spacing: -0.03em;
  color: var(--on-claret); font-variant-numeric: tabular-nums;
  display: flex; align-items: baseline; gap: 0.1em;
}
.ledger__fig sub { font-size: 0.42em; color: var(--citron); font-weight: 700; bottom: 0; }
.ledger__bar { height: 3px; border-radius: 3px; background: var(--claret-lift); overflow: hidden; }
.ledger__bar i {
  display: block; height: 100%; width: var(--w, 60%); background: var(--citron);
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.5s var(--ease) 0.2s;
}
.is-in .ledger__bar i { transform: scaleX(1); }

/* 21st.dev "Sliding Number" — digits roll in a masked column */
.roll { display: inline-flex; overflow: hidden; height: 1em; align-items: flex-start; }
.roll__col { display: block; overflow: hidden; height: 1em; }
.roll__col > span {
  display: block; height: 1em; line-height: 1;
  transition: transform 1.25s var(--ease);
  transform: translateY(calc(var(--d, 0) * -1em));
}

/* ---------- 11. Marquee (21st.dev "Marquee", dual-direction) ------------ */
.marq { position: relative; overflow: hidden; padding-block: clamp(1.75rem, 3.5vw, 2.5rem); }
.marq__mask {
  mask-image: linear-gradient(90deg, transparent, oklch(0% 0 0) 12%, oklch(0% 0 0) 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, oklch(0% 0 0) 12%, oklch(0% 0 0) 88%, transparent);
}
.marq__track { display: flex; width: max-content; gap: 0; }
.marq__group {
  display: flex; align-items: center; gap: clamp(2rem, 4.5vw, 4rem);
  padding-right: clamp(2rem, 4.5vw, 4rem);
  animation: marq var(--dur, 42s) linear infinite;
}
.marq--rev .marq__group { animation-direction: reverse; }
.marq:hover .marq__group { animation-play-state: paused; }
@keyframes marq { to { transform: translateX(-100%); } }
.marq__item {
  display: inline-flex; align-items: center; gap: 0.7rem;
  font-size: var(--fs-sm); font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--ink-3); white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.marq__item:hover { color: var(--ink); }
.marq__item::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--paper-3); flex: none;
  transition: background-color 0.3s var(--ease);
}
.marq__item:hover::before { background: var(--citron); }

/* ---------- 12. Bento solutions ----------------------------------------- */
.bento { display: grid; gap: clamp(0.85rem, 1.6vw, 1.15rem); }
@media (min-width: 860px) { .bento { grid-template-columns: repeat(2, minmax(0,1fr)); } }

/* Card: spotlight + border beam + tilt (21st.dev Shine Border / Tilt Card) */
.card {
  --mx: 50%; --my: 50%;
  position: relative;
  display: flex; flex-direction: column;
  padding: clamp(1.4rem, 2.6vw, 2rem);
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-1);
  text-decoration: none; color: inherit;
  isolation: isolate; overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.5s var(--ease), border-color 0.4s var(--ease), box-shadow 0.5s var(--ease);
  will-change: transform;
}
.card:hover { border-color: var(--ink-3); box-shadow: var(--sh-2); }
/* Flat hover fill, no cursor spotlight */
.card::before {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: var(--claret-tint);
  opacity: 0; transition: opacity 0.35s var(--ease);
}
.card:hover::before { opacity: 1; }
/* A single solid rule that draws itself along the top edge on hover, in place
   of a rotating conic beam */
.card__beam {
  position: absolute; top: 0; left: 0; right: 0; height: 3px; z-index: 2;
  pointer-events: none; background: var(--citron);
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.5s var(--ease);
}
.card:hover .card__beam { transform: scaleX(1); }
/* Dot pattern (21st.dev "Card with Grid Ellipsis Pattern") */
.card__dots {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image: radial-gradient(var(--rule) 1px, transparent 1px);
  background-size: 15px 15px;
  mask-image: radial-gradient(80% 70% at 100% 0%, oklch(0% 0 0), transparent 70%);
  -webkit-mask-image: radial-gradient(80% 70% at 100% 0%, oklch(0% 0 0), transparent 70%);
  opacity: 0.75;
}
.card > * { position: relative; z-index: 1; }
.card__idx {
  font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 600;
  letter-spacing: 0.04em; color: var(--olive); margin-bottom: 1.1rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.card__idx svg { color: var(--ink-3); transition: transform 0.45s var(--ease), color 0.3s var(--ease); }
.card:hover .card__idx svg { transform: translate(4px, -4px); color: var(--claret); }
.card__fig {
  margin: 0 0 1.25rem; padding: 0.35rem 0;
  color: var(--claret);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
}
.card__fig svg { width: 100%; height: auto; min-width: 25rem; }
.panel > svg { min-width: 0; }
.card h3 { margin-bottom: 0.6rem; }
.card p { color: var(--ink-2); font-size: var(--fs-sm); line-height: 1.62; }
.card__chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: auto; padding-top: 1.35rem; }
.chip {
  font-size: 0.6875rem; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase;
  padding: 0.34rem 0.68rem;
  color: var(--ink-2); background: var(--paper-2);
  border: 1px solid var(--rule); border-radius: var(--r-pill);
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease), background-color 0.3s var(--ease);
}
.card:hover .chip { border-color: var(--claret-line); color: var(--ink); background: var(--paper); }
.card--dark { background: var(--claret); border-color: oklch(100% 0 0 / 0.10); box-shadow: var(--sh-2); }
.card--dark h3, .card--dark .card__idx { color: var(--on-claret); }
.card--dark .card__idx { color: var(--citron); }
.card--dark p { color: var(--on-claret-2); }
.card--dark .card__dots { background-image: radial-gradient(oklch(100% 0 0 / 0.14) 1px, transparent 1px); opacity: 1; }
.card--dark::before { background: var(--claret-card); }
.card--dark .chip { background: oklch(100% 0 0 / 0.06); border-color: oklch(100% 0 0 / 0.14); color: var(--on-claret-2); }
.card--dark:hover .chip { border-color: oklch(92% 0.19 122 / 0.5); color: var(--on-claret); }
.card--dark .card__fig { color: var(--citron); }
/* Diagram captions that float on the figure's own ground (rather than sitting
   inside a filled box) need to follow the ground. Remapping --ink-* wholesale
   would break the labels inside the light-filled boxes, so captions get their
   own token instead. */
:root { --fig-caption: var(--ink-3); }
.card--dark .card__fig { --fig-caption: var(--on-claret-2); }
.card--dark .card__idx svg { color: var(--on-claret-3); }
.card--dark:hover .card__idx svg { color: var(--citron); }

/* ---------- 13. Ledger rows (replaces repeated card grids) -------------- */
.rows { border-top: 1px solid var(--rule); }
.row {
  --mx: 50%;
  position: relative; display: grid; gap: 0.55rem 1.75rem;
  grid-template-columns: 1fr auto;
  padding: clamp(1.35rem, 2.6vw, 1.9rem) 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none; color: inherit;
  transition: background-color 0.4s var(--ease), padding-inline 0.45s var(--ease);
}
.row::before {
  content: ''; position: absolute; inset: 0 -1.25rem; z-index: -1;
  background: var(--claret-tint);
  opacity: 0; transition: opacity 0.4s var(--ease);
}
.row:hover::before { opacity: 1; }
.row:hover { padding-inline: 1.25rem; }
.row__idx {
  grid-row: span 2; font-family: var(--font-mono); font-size: 0.6875rem;
  font-weight: 600; color: var(--olive); letter-spacing: 0.04em; padding-top: 0.5em;
}
.row__main { display: grid; gap: 0.4rem; }
.row__t {
  font-size: var(--fs-h4); font-weight: 640;
  letter-spacing: -0.014em; line-height: 1.25; color: var(--ink);
}
.row__d { font-size: var(--fs-sm); color: var(--ink-2); max-width: 62ch; line-height: 1.6; }
.row__go {
  align-self: center; width: 42px; height: 42px; flex: none;
  display: grid; place-items: center; color: var(--ink-3);
  border: 1px solid var(--rule); border-radius: 50%; background: var(--paper);
  transition: transform 0.45s var(--ease), background-color 0.35s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.row:hover .row__go {
  background: var(--citron); border-color: var(--citron); color: var(--claret-dark);
  transform: rotate(-45deg);
}
.rows--idx .row { grid-template-columns: auto 1fr auto; }

/* Numbered feature rows with mono index gutter */
.frow {
  display: grid; gap: 0.7rem 1.9rem;
  padding: clamp(1.5rem, 3vw, 2.15rem) 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}
@media (min-width: 820px) { .frow { grid-template-columns: 3.5rem minmax(0, 22rem) minmax(0, 1fr); } }
.frow__idx { font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 600; color: var(--olive); letter-spacing: 0.04em; padding-top: 0.55em; }
.frow h3 { letter-spacing: -0.016em; }
.frow p { color: var(--ink-2); font-size: var(--fs-sm); line-height: 1.62; }
.frow:hover { background: var(--claret-tint); }
.frow { transition: background-color 0.4s var(--ease); }

/* ---------- 14. Accordion ----------------------------------------------- */
.acc { border-top: 1px solid oklch(100% 0 0 / 0.09); }
.acc__item { border-bottom: 1px solid oklch(100% 0 0 / 0.09); }
.acc__sum {
  display: grid; grid-template-columns: 2.5rem 1fr auto; gap: 1rem; align-items: center;
  padding: clamp(1.1rem, 2.2vw, 1.5rem) 0;
  cursor: pointer; list-style: none;
  font-size: var(--fs-h4); font-weight: 620;
  letter-spacing: -0.014em; line-height: 1.3;
  color: var(--on-claret-2);
  transition: color 0.3s var(--ease);
}
.acc__sum::-webkit-details-marker { display: none; }
.acc__sum:hover { color: var(--on-claret); }
.acc__item[open] .acc__sum { color: var(--on-claret); }
.acc__num { font-family: var(--font-mono); font-size: 0.6875rem; font-weight: 600; color: var(--on-claret-3); letter-spacing: 0.04em; }
.acc__item[open] .acc__num { color: var(--citron); }
.acc__ico { position: relative; width: 15px; height: 15px; flex: none; }
.acc__ico i {
  position: absolute; background: var(--on-claret-2); border-radius: 2px;
  transition: transform 0.45s var(--ease), background-color 0.3s var(--ease);
}
.acc__ico i:first-child { top: 6.75px; left: 0; width: 15px; height: 1.5px; }
.acc__ico i:last-child  { left: 6.75px; top: 0; width: 1.5px; height: 15px; }
.acc__item[open] .acc__ico i { background: var(--citron); }
.acc__item[open] .acc__ico i:last-child { transform: rotate(90deg); }
.acc__body {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows 0.5s var(--ease);
}
.acc__item[open] .acc__body { grid-template-rows: 1fr; }
.acc__inner { overflow: hidden; }
.acc__inner p {
  padding: 0 0 clamp(1.25rem, 2.4vw, 1.75rem) 3.5rem;
  color: var(--on-claret-2); font-size: var(--fs-sm); line-height: 1.72; max-width: 74ch;
}
@media (max-width: 640px) { .acc__inner p { padding-left: 0; } }

/* ---------- 15. Scroll text reveal (21st.dev "Text Reveal") ------------- */
.reveal-text { font-size: clamp(1.375rem, 1rem + 1.9vw, 2.25rem); line-height: 1.42; font-weight: 500; letter-spacing: -0.02em; max-width: 46ch; }
.reveal-text .rw { color: var(--ink-3); transition: color 0.5s var(--ease); }
.reveal-text .rw.on { color: var(--ink); }

/* ---------- 16. Orbit diagram (21st.dev "Orbiting Circles") ------------- */
.orbit { position: relative; aspect-ratio: 1; width: 100%; max-width: 30rem; margin-inline: auto; }
.orbit__ring {
  position: absolute; inset: var(--in, 0); border: 1px dashed var(--rule); border-radius: 50%;
  animation: spin var(--dur, 30s) linear infinite;
}
.orbit__ring--rev { animation-direction: reverse; }
@keyframes spin { to { transform: rotate(360deg); } }
/* Each node sits on a static slot rotated by --a; the node counter-spins so
   the label stays upright while the ring rotates. */
.orbit__slot { position: absolute; inset: 0; transform: rotate(var(--a, 0deg)); }
.orbit__node {
  position: absolute; top: 0; left: 50%; margin-left: -0.05rem;
  translate: -50% -50%;
  display: grid; place-items: center;
  padding: 0.36rem 0.58rem;
  background: var(--paper); border: 1px solid var(--rule); border-radius: var(--r-pill);
  font-size: 0.6875rem; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink); white-space: nowrap;
  box-shadow: var(--sh-1);
  transform: rotate(calc(var(--a, 0deg) * -1));
  animation: node-upright var(--dur, 30s) linear infinite;
}
@keyframes node-upright {
  from { transform: rotate(calc(var(--a, 0deg) * -1)); }
  to   { transform: rotate(calc(var(--a, 0deg) * -1 - 360deg)); }
}
.orbit__core {
  position: absolute; inset: 34%;
  display: grid; place-items: center; text-align: center;
  background: var(--claret-dark); color: var(--on-claret);
  border-radius: 50%;
  box-shadow: 0 0 0 1px oklch(100% 0 0 / 0.12), 0 20px 50px -22px oklch(17.5% 0.008 265 / 0.55);
}
.orbit__core b { font-family: var(--font-sans); font-size: 0.9375rem; font-weight: 700; letter-spacing: -0.02em; }
.orbit__core em { font-style: normal; display: block; font-family: var(--font-mono); font-size: 0.5625rem; color: var(--citron); letter-spacing: 0.13em; text-transform: uppercase; margin-top: 0.2rem; }
.orbit__pulse { position: absolute; inset: 34%; border-radius: 50%; border: 1px solid var(--citron); animation: orb-ping 3.2s var(--ease-io) infinite; }
@keyframes orb-ping { 0% { transform: scale(1); opacity: 0.8; } 100% { transform: scale(1.85); opacity: 0; } }

/* ---------- 17. Gauge --------------------------------------------------- */
.gauge { display: grid; place-items: center; gap: 1rem; text-align: center; }
.gauge__ring { position: relative; width: clamp(9rem, 20vw, 12rem); aspect-ratio: 1; }
.gauge__ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.gauge__track { fill: none; stroke: oklch(100% 0 0 / 0.10); stroke-width: 7; }
.gauge__val {
  fill: none; stroke: var(--citron); stroke-width: 7; stroke-linecap: round;
  stroke-dasharray: var(--len); stroke-dashoffset: var(--len);
  transition: stroke-dashoffset 2s var(--ease) 0.25s;
}
.is-in .gauge__val { stroke-dashoffset: var(--off); }
.gauge__mid {
  position: absolute; inset: 0; display: grid; place-content: center; gap: 0.15rem;
}
.gauge__num { font-family: var(--font-mono); font-size: clamp(1.5rem, 3.4vw, 2rem); font-weight: 600; color: var(--on-claret); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.gauge__lab { font-size: 0.625rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--on-claret-3); }

/* ---------- 18. Page hero (inner pages) -------------------------------- */
.phero {
  position: relative; background: var(--claret-dark); color: var(--on-claret);
  overflow: clip; isolation: isolate;
  padding-block: clamp(3.25rem, 7vw, 5.5rem) clamp(3rem, 6vw, 4.75rem);
}
.phero__grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, oklch(100% 0 0 / 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, oklch(100% 0 0 / 0.05) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(110% 100% at 12% 0%, oklch(0% 0 0) 8%, transparent 70%);
}
.phero > .wrap { position: relative; z-index: 2; }
.phero h1 { font-size: var(--fs-h1); letter-spacing: -0.038em; max-width: 24ch; }
.phero .lead { color: var(--on-claret-2); margin-top: 1.15rem; }
.crumb { display: flex; align-items: center; gap: 0.6rem; margin-bottom: clamp(1.25rem, 2.6vw, 1.85rem); flex-wrap: wrap; }
.crumb a, .crumb span {
  font-size: var(--fs-label); font-weight: 700; letter-spacing: 0.11em;
  text-transform: uppercase; color: var(--on-claret-3); text-decoration: none;
}
.crumb a:hover { color: var(--citron); }
.crumb i { color: var(--claret-edge); font-style: normal; }
.crumb [aria-current] { color: var(--on-claret-2); }

/* ---------- 19. Split / media ------------------------------------------ */
.split { display: grid; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
@media (min-width: 940px) {
  .split { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .split--wide { grid-template-columns: minmax(0,1.15fr) minmax(0,0.85fr); }
  .split--flip > :first-child { order: 2; }
}
.panel {
  background: var(--paper-2); border: 1px solid var(--rule); border-radius: var(--r-lg);
  padding: clamp(1.4rem, 3vw, 2.25rem); position: relative; overflow: hidden;
  box-shadow: var(--sh-1);
}
.panel--claret {
  background: var(--claret); border-color: oklch(100% 0 0 / 0.10); color: var(--on-claret);
  box-shadow: var(--sh-2);
}
.panel--claret h3, .panel--claret h4 { color: var(--on-claret); }
.panel--claret p { color: var(--on-claret-2); }
.panel__lab { display: flex; align-items: baseline; gap: 0.75rem; margin-bottom: 1rem; }
.dl { display: grid; gap: 0; }
.dl > div {
  display: grid; grid-template-columns: 1fr auto; gap: 1rem; align-items: baseline;
  padding: 0.72rem 0; border-bottom: 1px solid var(--rule);
}
.dl > div:last-child { border-bottom: 0; }
.dl dt { font-size: var(--fs-sm); color: var(--ink-2); }
.dl dd { font-family: var(--font-mono); font-size: var(--fs-sm); font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.panel--claret .dl > div { border-bottom-color: oklch(100% 0 0 / 0.09); }
.panel--claret .dl dt { color: var(--on-claret-2); }
.panel--claret .dl dd { color: var(--citron); }

/* Value tiles (about) */
.values { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sh-1); }
@media (min-width: 640px)  { .values { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .values { grid-template-columns: repeat(4, 1fr); } }
.value {
  background: var(--paper); padding: clamp(1.35rem, 2.8vw, 1.9rem);
  display: grid; gap: 0.6rem; align-content: start;
  transition: background-color 0.4s var(--ease);
}
.value:hover { background: var(--claret-tint); }
.value__ico { color: var(--olive); margin-bottom: 0.35rem; }
.value h3 { font-size: var(--fs-h4); }
.value p { font-size: var(--fs-sm); color: var(--ink-2); }

/* ---------- 20. Careers ------------------------------------------------- */
/* Four roles read as a 2x2 grid; three columns left an orphan on its own row. */
.jobs { display: grid; gap: clamp(0.85rem, 1.6vw, 1.15rem); }
@media (min-width: 780px) { .jobs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.job {
  --mx: 50%; --my: 50%;
  position: relative; overflow: hidden;
  background: var(--paper); border: 1px solid var(--rule); border-radius: var(--r-lg);
  padding: clamp(1.35rem, 2.8vw, 1.9rem);
  display: flex; flex-direction: column;
  box-shadow: var(--sh-1);
  transition: border-color 0.4s var(--ease), box-shadow 0.5s var(--ease), transform 0.5s var(--ease);
}
.job:hover { border-color: var(--ink-3); transform: translateY(-3px); box-shadow: var(--sh-2); }
.job::before {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: var(--claret-tint);
  opacity: 0; transition: opacity 0.35s var(--ease);
}
.job:hover::before { opacity: 1; }
.job > * { position: relative; z-index: 1; }

.job__role { display: block; margin-bottom: 0.5rem; }
.job h3 { font-size: var(--fs-h3); margin-bottom: 1.35rem; }

/* Label left, value right, one row each: the previous three-column grid broke
   the salary range across four lines. */
.job__specs { display: grid; margin-bottom: 1.6rem; border-top: 1px solid var(--rule); }
.job__spec {
  display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr);
  gap: 0.35rem 1.25rem; align-items: baseline;
  padding: 0.72rem 0; border-bottom: 1px solid var(--rule);
}
.job__spec dt {
  font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.11em;
  text-transform: uppercase; color: var(--ink-3);
}
.job__spec dd {
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink);
  text-align: right; justify-self: end;
}
.job__spec dd.mono {
  font-family: var(--font-mono); font-weight: 500; letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.job__cv { align-self: start; margin-top: auto; }

/* ---------- 21. Contact + form ----------------------------------------- */
.ccards { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sh-1); }
@media (min-width: 780px) { .ccards { grid-template-columns: repeat(2, 1fr); } }
.ccard {
  background: var(--paper); padding: clamp(1.35rem, 2.8vw, 1.85rem);
  display: grid; gap: 0.5rem; align-content: start; text-decoration: none; color: inherit;
  transition: background-color 0.4s var(--ease);
}
.ccard:hover { background: var(--claret-tint); }
.ccard__ico { color: var(--olive); margin-bottom: 0.4rem; }
.ccard h3 { font-size: var(--fs-h4); }
.ccard__v { font-family: var(--font-mono); font-size: var(--fs-sm); color: var(--ink-2); word-break: break-word; font-variant-numeric: tabular-nums; }
.ccard:hover .ccard__v { color: var(--ink); }

.form { display: grid; gap: 1.1rem; }
.field { display: grid; gap: 0.42rem; }
.field label { font-size: var(--fs-label); font-weight: 700; letter-spacing: 0.11em; text-transform: uppercase; color: var(--ink-2); }
.field label b { color: var(--olive); font-weight: 700; }
.field input, .field textarea {
  width: 100%; padding: 0.85rem 0.95rem;
  background: var(--paper);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-md);
  font-size: var(--fs-body); color: var(--ink);
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.field textarea { resize: vertical; min-height: 8.5rem; line-height: 1.6; }
.field input::placeholder, .field textarea::placeholder { color: var(--ink-3); opacity: 1; }
.field input:hover, .field textarea:hover { border-color: var(--ink-3); }
.field input:focus-visible, .field textarea:focus-visible { border-color: var(--ink); background: var(--paper); }
.field__err {
  display: none; align-items: center; gap: 0.4rem;
  font-size: var(--fs-xs); font-weight: 600; color: var(--olive);
}
.field__err svg { flex: none; }
.field[data-invalid='true'] .field__err { display: flex; }
.field[data-invalid='true'] input, .field[data-invalid='true'] textarea { border-color: var(--olive); box-shadow: 0 0 0 3px oklch(48% 0.115 133 / 0.16); }
.form__note { font-size: var(--fs-xs); color: var(--ink-3); }
.form__ok {
  display: none; gap: 0.75rem; align-items: start;
  padding: 1rem 1.1rem; background: var(--claret-tint);
  border: 1px solid var(--claret-line); border-radius: var(--r-md);
  font-size: var(--fs-sm); color: var(--ink);
}
.form__ok svg { color: var(--olive); flex: none; margin-top: 0.15em; }
.form[data-sent='true'] .form__ok { display: flex; }

/* ---------- 22. CTA + footer ------------------------------------------- */
.cta {
  position: relative; overflow: clip; isolation: isolate;
  background: var(--claret-deep); color: var(--on-claret);
  padding-block: clamp(3.25rem, 7vw, 5.5rem);
}
.cta__inner { position: relative; z-index: 2; display: grid; gap: clamp(1.75rem, 4vw, 3rem); align-items: center; }
@media (min-width: 940px) { .cta__inner { grid-template-columns: minmax(0,1fr) auto; } }
.cta h2 { font-size: var(--fs-h2); max-width: 34ch; letter-spacing: -0.032em; }
.cta .label { color: var(--on-claret-3); margin-bottom: 0.9rem; display: block; }

.ftr { background: var(--claret-dark); color: var(--on-claret-2); padding-block: clamp(3rem, 6vw, 4.5rem) 0; }
.ftr__top { display: grid; gap: clamp(2rem, 5vw, 3.5rem); padding-bottom: clamp(2.5rem, 5vw, 3.5rem); }
@media (min-width: 900px) { .ftr__top { grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr)); } }
.ftr__blurb { font-size: var(--fs-sm); color: var(--on-claret-2); max-width: 42ch; margin-top: 1.1rem; line-height: 1.7; }
.ftr__legal-name {
  margin-top: 1.35rem; padding-top: 1.1rem; border-top: 1px solid oklch(100% 0 0 / 0.09);
  font-size: var(--fs-xs); line-height: 1.7;
  color: var(--on-claret-3); letter-spacing: 0.02em;
}
.ftr__legal-name b { display: block; color: var(--on-claret); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; font-size: 0.6875rem; margin-bottom: 0.25rem; font-family: var(--font-sans); }
.ftr h2 { font-size: var(--fs-label); font-weight: 700; letter-spacing: 0.11em; text-transform: uppercase; color: var(--on-claret-3); margin-bottom: 1.1rem; }
.ftr__list { display: grid; gap: 0.15rem; }
.ftr__list a {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.32rem 0; font-size: var(--fs-sm); color: var(--on-claret-2);
  text-decoration: none; width: fit-content;
  transition: color 0.25s var(--ease), gap 0.35s var(--ease);
}
.ftr__list a::before {
  content: ''; width: 0; height: 1px; background: var(--citron);
  transition: width 0.35s var(--ease);
}
.ftr__list a:hover { color: var(--on-claret); }
.ftr__list a:hover::before { width: 14px; }
.ftr__bot {
  display: flex; flex-wrap: wrap; gap: 0.85rem 1.75rem; align-items: center;
  padding-block: 1.4rem; border-top: 1px solid oklch(100% 0 0 / 0.09);
}
.ftr__cr { font-size: var(--fs-xs); color: var(--on-claret-3); }
.ftr__pol { display: flex; flex-wrap: wrap; gap: 0.5rem 1.35rem; margin-left: auto; }
.ftr__pol a { font-size: var(--fs-xs); color: var(--on-claret-3); text-decoration: none; transition: color 0.25s var(--ease); }
.ftr__pol a:hover { color: var(--citron); }

/* ---------- 23. Reveal orchestration ----------------------------------- */
/* Reveals are opt-in: without JS (or if the observer never fires) content is
   simply visible. The .js class is set by site.js before paint. */
.js [data-rv] { opacity: 0; transform: translateY(22px); }
.js [data-rv].is-in {
  opacity: 1; transform: none;
  transition: opacity 0.85s var(--ease), transform 0.95s var(--ease);
  transition-delay: calc(var(--d, 0) * 60ms);
}

/* ---------- 24. Reduced motion ----------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js [data-rv] { opacity: 1 !important; transform: none !important; }
  .hero h1 .w > span { transform: none; opacity: 1; }
  .hero__actions, .hero__note, .console { opacity: 1; }
  .ledger__bar i { transform: scaleX(1); }
  .gauge__val { stroke-dashoffset: var(--off); }
  .reveal-text .rw { color: var(--ink); }
  .marq__group { animation: none; }
  .hero__aurora, .cta__glow { animation: none; }
}

/* ---------- 25. Print -------------------------------------------------- */
@media print {
  .hdr, .drawer, .cta, .marq, .hero__rails, .hero__aurora, .console { display: none !important; }
  body { background: #fff; color: #000; }
  .hero, .phero, .ftr { background: #fff !important; color: #000 !important; }
  /* Citron is 1.22:1 on white — the footer lockup must print in ink. */
  .ftr .logo__m, .ftr .logo__word, .ftr .logo__word em { color: var(--ink); }
  a::after { content: ' (' attr(href) ')'; font-size: 0.8em; color: #555; }
}

/* ---------- no-JS: the drawer is clip-path-hidden until JS runs, so without it
   a phone had no navigation at all. Render it as a plain in-flow list and hide
   the burger, which cannot work. ---------------------------------------- */
html:not(.js) .burger { display: none; }
html:not(.js) .drawer {
  position: static; inset: auto; clip-path: none; visibility: visible;
  opacity: 1; transform: none; height: auto; overflow: visible;
  border-top: 1px solid var(--claret-edge);
}
html:not(.js) .drawer__list a { opacity: 1; transform: none; }

/* contact form, live send (2026-10-09): sending and error states for the fetch
   handler in site.js, and the no-JS fallback targets contact.php redirects to. */
.form__static { display: none; padding: 0.85rem 1rem; margin-bottom: 1rem; border: 1px solid currentColor; border-radius: 6px; font-size: 0.9rem; }
.form__static:target { display: block; }
.form__err { display: none; gap: 0.6rem; align-items: flex-start; padding: 0.85rem 1rem; margin-bottom: 1rem; border: 1px solid currentColor; border-radius: 6px; font-size: 0.9rem; }
.form[data-sent='error'] .form__err { display: flex; }
.form[data-sent='sending'] button[type='submit'] { opacity: 0.65; cursor: progress; }
