/* ===========================================================================
   WYEA design system
   ---------------------------------------------------------------------------
   One stylesheet, shared by every page. Three layers, in this order:

     1. Tokens      primitives, then the semantic tokens components use.
     2. Base        element defaults, written against semantic tokens.
     3. Components  every reusable block on the site. Components read
                    semantic tokens only, never a primitive or a raw value.

   Direction B, 2026-10-20: modelled on the look and feel of ode.com. Warm
   paper ground, warm ink, light-weight Geist at display scale, dotted
   hairlines, small tracked pill buttons, and soft drifting light fields as
   the imagery. Light only. Replaces Direction A (indigo, rounded cards).
   Usage notes are in docs/design-system.md.

   Breakpoints: 375 (smallest supported), 768, 1024, 1280. Media queries use
   max-width 767px and 1023px. CSS cannot read custom properties inside a
   media query, so the values are written out here and recorded as --bp-*.
   ========================================================================= */

/* ---------------------------------------------------------------- fonts -- */

@font-face {
  font-family: "Geist";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/geist-var.woff2") format("woff2");
}

@font-face {
  font-family: "Geist Mono";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("/fonts/geist-mono-var.woff2") format("woff2");
}

/* ======================================================= 1. tokens ===== */

/* ---------------------------------------------------------- primitives -- */
/* Raw palette. Only the semantic tokens below may reference these. */

:root {
  --white: #ffffff;
  --paper-50: #fbfaf5;
  --paper-100: #f4f2ea;
  --paper-200: #ebe8dc;
  --paper-300: #d9d5c6;
  --ink-900: #2a2220;
  --ink-700: #4a3f3b;
  --ink-600: #5b504b;
  --ink-500: #6b5f59;
  --ink-200: #d6cfc8;

  --indigo-600: #3a3fe0;
  --indigo-300: #a5b4fc;
  --indigo-200: #c7c9ff;
  --indigo-50: #f1f1ff;

  --green-700: #166534;
  --green-100: #dcfce7;
  --orange-800: #9a3412;
  --orange-100: #ffedd5;
  --orange-50: #fff7ed;

  --glow-blush: #f2c4cf;
  --glow-periwinkle: #c4cbf3;
  --glow-peach: #f8d3b8;
  --glow-sage: #d3e0cf;
}

/* ------------------------------------------------------------ semantic -- */
/* Light only: dark text on a light ground reads better, most at small
   sizes (NN/g on polarity). The site does not follow the OS dark setting. */

:root {
  color-scheme: light;

  /* grounds */
  --color-bg: var(--paper-50);
  --color-surface: var(--paper-100);
  --color-surface-subtle: var(--paper-100);
  --color-surface-strong: var(--paper-200);
  --color-raised: var(--white);
  --color-header-bg: rgb(251 250 245 / 0.82);

  /* text */
  --color-text: var(--ink-900);
  --color-text-soft: var(--ink-700);
  --color-text-muted: var(--ink-600);
  --color-text-faint: var(--ink-500);

  /* rules */
  --color-border: var(--paper-200);
  --color-border-strong: var(--paper-300);
  --color-rule: var(--ink-900);

  /* accent */
  --color-accent: var(--indigo-600);
  --color-accent-strong: var(--indigo-600);
  --color-accent-wash: var(--indigo-50);
  --color-accent-line: var(--indigo-200);
  --color-on-accent: var(--white);
  --color-focus: var(--indigo-600);

  /* status */
  --color-ok: var(--green-700);
  --color-ok-wash: var(--green-100);
  --color-flag: var(--orange-800);
  --color-flag-wash: var(--orange-100);
  --color-flag-ground: var(--orange-50);
  --color-warning: var(--orange-800);
  --color-warning-wash: var(--orange-50);

  /* buttons */
  --color-btn-bg: var(--ink-900);
  --color-btn-text: var(--paper-50);

  /* the dark panel (vendor review, ink bands) */
  --color-inverse-bg: var(--ink-900);
  --color-on-inverse: var(--paper-50);
  --color-on-inverse-soft: var(--ink-200);
  --color-on-inverse-faint: var(--ink-200);
  --color-inverse-border: #4a3f3b;
  --color-inverse-accent: var(--indigo-300);

  /* the light fields behind the hero, the dark panel and the closing call */
  --gradient-glow: var(--paper-200);
  --field-a: var(--glow-blush);
  --field-b: var(--glow-sage);
  --field-c: var(--glow-peach);
  --field-d: var(--glow-sage);
}

/* ------------------------------------------------- type, space, form --- */

:root {
  /* faces */
  --font-display: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* one size scale; --text-base is the floor for body text */
  --text-2xs: 0.75rem;                                /* 12  labels */
  --text-xs: 0.8125rem;                               /* 13  figure detail, captions */
  --text-sm: 0.9375rem;                               /* 15  meta, nav, buttons */
  --text-base: 1.0625rem;                             /* 17  body */
  --text-md: 1.1875rem;                               /* 19  labels, h4 */
  --text-lg: 1.375rem;                                /* 22  h3, lede */
  --text-xl: clamp(1.5rem, 2.4vw, 2rem);              /* 24 to 32 */
  --text-2xl: clamp(2.1rem, 4.2vw, 3.5rem);           /* 34 to 56  h2 */
  --text-3xl: clamp(2.75rem, 6.4vw, 5.75rem);         /* 44 to 92  h1 */
  --text-hero: clamp(3rem, 7.4vw, 6.25rem);           /* 48 to 100 home h1 */
  --text-h1-sub: clamp(2.4rem, 4.6vw, 3.75rem);       /* 38 to 60  interior h1 */

  --leading-tight: 1.04;
  --leading-snug: 1.25;
  --leading-normal: 1.5;
  --leading-body: 1.6;

  --weight-regular: 400;
  --weight-display: 300;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  --tracking-display: -0.03em;
  --tracking-tight: -0.015em;
  --tracking-caps: 0.06em;
  --tracking-label: 0.12em;

  /* spacing on a 4px base */
  --space-0: 0;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 28px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-14: 56px;
  --space-16: 64px;
  --space-18: 72px;
  --space-20: 80px;
  --space-24: 96px;
  --space-28: 112px;
  --space-32: 128px;
  --space-36: 144px;

  /* section rhythm, built from the scale */
  --space-band: clamp(var(--space-20), 9vw, var(--space-32));
  --space-band-tight: clamp(var(--space-14), 6vw, var(--space-24));
  --space-gutter: var(--space-7);

  /* measures */
  --width-page: 1256px;
  --width-wide: 1256px;
  --width-text: 720px;
  --header-h: 72px;

  /* corners, rules, depth */
  --radius-0: 0;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-pill: 999px;
  --border-hair: 1px;
  --border-rule: 2px;
  --border-mark: 3px;
  --shadow-0: none;
  --shadow-card: 0 30px 70px rgb(60 40 40 / 0.14);
  --shadow-soft: 0 8px 22px rgb(60 40 40 / 0.07);
  --shadow-glow: 0 12px 30px rgb(58 63 224 / 0.22);

  /* motion */
  --duration-fast: 160ms;
  --duration-base: 240ms;
  --duration-slow: 450ms;
  --duration-reveal: 900ms;
  --ease-standard: ease;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-drift: 22s;
  --arrow-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.5'%3E%3Cpath d='M2 8h11M9 4l4 4-4 4'/%3E%3C/svg%3E");
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.16 0 0 0 0 0.13 0 0 0 0 0.12 0 0 0 0.55 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");

  /* breakpoints, for scripts; see the header comment */
  --bp-sm: 375px;
  --bp-md: 768px;
  --bp-lg: 1024px;
  --bp-xl: 1280px;
}

@media (max-width: 767px) {
  :root { --space-gutter: var(--space-5); }
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --duration-fast: 0ms;
    --duration-base: 0ms;
    --duration-slow: 0ms;
    --duration-reveal: 0ms;
    --duration-drift: 0s;
  }
}

/* ========================================================= 2. base ===== */

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--space-6));
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

img, svg { max-width: 100%; display: block; }

/* The hidden attribute always wins over a component's display value. */
[hidden] { display: none !important; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--weight-display);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-display);
  text-wrap: balance;
  color: var(--color-text);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-lg); font-weight: var(--weight-regular); line-height: var(--leading-snug); letter-spacing: var(--tracking-tight); }
h4 { font-size: var(--text-md); font-weight: var(--weight-regular); line-height: var(--leading-snug); }

h1 em, h2 em { font-style: normal; color: var(--color-accent); }

p { color: var(--color-text-muted); max-width: 68ch; }

a { color: inherit; }

/* Links inside running text are underlined, so they never rely on color
   alone. Standalone links (.arrow, nav, buttons, cards) are not.
   Zero specificity, so a component that sets text-decoration wins. */
:where(p, li, td, cite, small) a:where(:not(.arrow, .btn)) {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

strong, b { font-weight: var(--weight-medium); color: var(--color-text); }

::selection { background: var(--color-accent); color: var(--color-on-accent); }

:focus-visible {
  outline: var(--border-rule) solid var(--color-focus);
  outline-offset: var(--space-1);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--color-btn-bg);
  color: var(--color-btn-text);
  padding: var(--space-3) var(--space-5);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}

.skip-link:focus { left: 0; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* =================================================== 3. components ===== */

/* --------------------------------------------------------- layout ------ */
.wrap {
  width: 100%;
  max-width: var(--width-page);
  margin: 0 auto;
  padding: 0 var(--space-gutter);
}

.wrap-wide { max-width: var(--width-wide); }
.wrap-text { max-width: calc(var(--width-text) + var(--space-gutter) * 2); }

.band { padding: var(--space-band) 0; }
.band-tight { padding: var(--space-band-tight) 0; }
.band-paper { background: var(--color-surface); }

/* Cards on a surface band switch to white so they stay visible. */
.band-paper :is(.tile, .pillar, .stat, .price, .person, .explore a, .callout) { background: var(--color-raised); }
.band-rule { border-top: var(--border-hair) solid var(--color-border); }

/* The dark panel: an inset, rounded block rather than a full-bleed band. */
.band-ink { color: var(--color-on-inverse); }

.band-ink > .wrap {
  background: var(--color-inverse-bg);
  border-radius: var(--radius-xl);
  padding: clamp(var(--space-8), 5vw, var(--space-18));
  width: calc(100% - var(--space-gutter) * 2);
}

.band-ink h1, .band-ink h2, .band-ink h3, .band-ink h4 { color: var(--color-on-inverse); }
.band-ink p { color: var(--color-on-inverse-soft); }
.band-ink strong, .band-ink b { color: var(--color-on-inverse); }
.band-ink .eyebrow, .band-ink em { color: var(--color-inverse-accent); }

/* spacing helpers, so pages never need a style attribute */
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mt-10 { margin-top: var(--space-10); }
.mt-12 { margin-top: var(--space-12); }
.mb-8 { margin-bottom: var(--space-8); }
.center { text-align: center; }

/* ----------------------------------------------------- section head ---- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  letter-spacing: 0;
  color: var(--color-accent);
  margin-bottom: var(--space-4);
}

.head { max-width: 22ch; }

.h-sub { font-size: var(--text-xl); }

.lede {
  font-size: var(--text-lg);
  line-height: var(--leading-normal);
  color: var(--color-text-muted);
  max-width: 48ch;
  margin-top: var(--space-5);
}

.band-ink .lede { color: var(--color-on-inverse-soft); }

.head-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: var(--space-6) var(--space-16);
  align-items: end;
  margin-bottom: var(--space-12);
}

.head-split .lede { margin-top: 0; }

.head-stack { margin-bottom: var(--space-12); }

/* A centered section head: one heading, optionally one short line. */
.head-center { text-align: center; margin: 0 auto var(--space-14); }
.head-center .head, .head-center h2 { margin: 0 auto; max-width: 18ch; }
.head-center .lede { margin: var(--space-4) auto 0; }

@media (max-width: 1023px) {
  .head-split { grid-template-columns: 1fr; align-items: start; gap: var(--space-4); }
}

/* --------------------------------------------------------- buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  min-height: 48px;
  padding: 0 var(--space-7);
  border: 0;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--duration-base) var(--ease-out),
              color var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

/* The arrow is drawn, not typed, and slides on hover. */
.btn:not(.btn-sm)::after {
  content: "";
  width: 14px;
  height: 14px;
  background: currentColor;
  -webkit-mask: var(--arrow-mask) center / contain no-repeat;
  mask: var(--arrow-mask) center / contain no-repeat;
  transition: transform var(--duration-base) var(--ease-out);
}

.btn:not(.btn-sm):hover::after { transform: translateX(4px); }

.btn-primary { background: var(--color-btn-bg); color: var(--color-btn-text); }
.btn-primary:hover { background: var(--color-accent); color: var(--color-on-accent); }

.btn-ghost { background: transparent; color: var(--color-text); box-shadow: inset 0 0 0 1px var(--color-border-strong); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1px var(--color-text); }

.btn-light { background: var(--color-bg); color: var(--color-text); }
.btn-light:hover { background: var(--color-raised); }

.btn-outline-light { background: transparent; color: var(--color-on-inverse); box-shadow: inset 0 0 0 1px var(--color-on-inverse-faint); }
.btn-outline-light:hover { box-shadow: inset 0 0 0 1px var(--color-on-inverse); }

.btn-sm { min-height: 40px; padding: 0 var(--space-5); font-size: var(--text-2xs); }
.btn-sm.btn-primary { background: transparent; color: var(--color-text); box-shadow: inset 0 0 0 1px var(--color-border-strong); }
.btn-sm.btn-primary:hover { background: var(--color-text); color: var(--color-bg); box-shadow: inset 0 0 0 1px var(--color-text); }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-8);
}

.arrow {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45em;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--color-accent);
  text-decoration: none;
}

.arrow::after {
  content: "\2192";
  transition: transform var(--duration-fast) var(--ease-standard);
}

.arrow:hover::after { transform: translateX(3px); }
.arrow:hover { color: var(--color-text); }

.band-ink .arrow { color: var(--color-inverse-accent); }
.band-ink .arrow:hover { color: var(--color-on-inverse); }

/* ------------------------------------------------------ navigation ----- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--color-header-bg);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: var(--border-hair) solid var(--color-border);
  transition: background var(--duration-slow) var(--ease-out), border-color var(--duration-slow) var(--ease-out);
}

.js .site-header:not(.is-scrolled) { background: transparent; backdrop-filter: none; border-bottom-color: transparent; }

.site-header.is-scrolled {
  background: var(--color-header-bg);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom-color: var(--color-border);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: var(--space-8);
  height: var(--header-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-size: var(--text-lg);
  color: var(--color-text);
  text-decoration: none;
  line-height: 1;
  flex: none;
}

/* the mark is two linked documents, one of them the source */
.wordmark-mark { width: 1.7em; height: 1.7em; display: block; }
.wordmark-letters { width: 4.4em; height: 0.98em; display: block; }

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-left: auto;
}

.nav-item { position: relative; }

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 var(--space-3);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  color: var(--color-text-faint);
  text-decoration: none;
  background: none;
  border: 0;
  font-family: var(--font-body);
  cursor: pointer;
  white-space: nowrap;
}

.nav-link:hover, .nav-link[aria-expanded="true"] { color: var(--color-text); }

.nav-link[aria-current="page"] { color: var(--color-text); }

.nav-caret {
  width: 8px;
  height: 8px;
  border-right: 1.4px solid currentColor;
  border-bottom: 1.4px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform var(--duration-fast) var(--ease-standard);
}

.nav-link[aria-expanded="true"] .nav-caret { transform: translateY(1px) rotate(-135deg); }

.nav-cta { margin-left: var(--space-3); }

.mega {
  position: absolute;
  top: calc(100% + 9px);
  left: 50%;
  transform: translateX(-50%);
  width: min(720px, calc(100vw - var(--space-12)));
  background: var(--color-raised);
  border: var(--border-hair) solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: var(--space-2);
  animation: mega-in var(--duration-base) var(--ease-out);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}

.mega[hidden] { display: none; }

@keyframes mega-in { from { opacity: 0; transform: translate(-50%, -6px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* An invisible strip over the gap between the nav item and its panel, so
   the pointer stays inside the item on its way down to a link. */
.mega::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: var(--space-4);
}

.mega-link {
  display: block;
  padding: var(--space-3) var(--space-4);
  text-decoration: none;
  border-radius: var(--radius-sm);
}

.mega-link:hover { background: var(--color-surface); }

.mega-link b {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
}

.mega-link b::after {
  content: "\2192";
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-accent);
  opacity: 0;
  transition: opacity var(--duration-fast) var(--ease-standard), transform var(--duration-fast) var(--ease-standard);
}

.mega-link:hover b::after { opacity: 1; transform: translateX(2px); }

.mega-link span {
  display: block;
  margin-top: 3px;
  font-size: var(--text-sm);
  line-height: 1.42;
  color: var(--color-text-muted);
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 44px;
  height: 40px;
  border: var(--border-hair) solid var(--color-border-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  position: relative;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  position: absolute;
  left: 12px;
  width: 18px;
  height: 1.5px;
  background: var(--color-text);
  content: "";
}

.nav-toggle span { top: 19px; }
.nav-toggle span::before { top: -6px; left: 0; }
.nav-toggle span::after { top: 6px; left: 0; }

@media (max-width: 1023px) {
  .nav-toggle { display: block; }
  .mega::before { display: none; }

  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: calc(100vh - var(--header-h));
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: var(--space-3) var(--space-gutter) var(--space-10);
    background: var(--color-bg);
    border-top: var(--border-hair) solid var(--color-border);
    border-bottom: var(--border-hair) solid var(--color-rule);
    overflow-y: auto;
  }

  .nav.is-open { display: flex; }

  .nav-item { position: static; }

  .nav-link {
    width: 100%;
    justify-content: space-between;
    height: auto;
    padding: var(--space-4) 0;
    font-size: var(--text-md);
    border-bottom: var(--border-hair) solid var(--color-border);
  }

  .nav-link[aria-current="page"] { box-shadow: none; color: var(--color-accent-strong); }

  .mega {
    position: static;
    transform: none;
    width: 100%;
    grid-template-columns: 1fr;
    border: 0;
    border-bottom: var(--border-hair) solid var(--color-border);
    padding: var(--space-1) 0 var(--space-3);
  }

  .nav-cta { margin: var(--space-5) 0 0; }
}

/* ------------------------------------------------------------- hero ---- */
.hero { padding: clamp(var(--space-14), 7vw, var(--space-24)) 0 0; }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: var(--space-8) var(--space-18);
  align-items: end;
}

.hero-grid > * { min-width: 0; }

.hero h1 { max-width: 16ch; }
.hero .lede { max-width: 46ch; }

/* The homepage hero: centered headline, one line, two buttons. */
.hero-center { text-align: center; }
.hero-center h1 { margin: 0 auto; max-width: 14ch; }
.hero-center .lede { margin: var(--space-6) auto 0; max-width: 38em; }
.hero-center .actions { justify-content: center; }

.hero-note {
  margin-top: var(--space-8);
  padding-top: var(--space-5);
  border-top: var(--border-hair) solid var(--color-border);
  font-size: var(--text-sm);
  color: var(--color-text-faint);
  max-width: 46ch;
}

.hero-note span { white-space: nowrap; }

.hero-sub h1 { font-size: var(--text-h1-sub); max-width: 18ch; }
.hero-sub .hero-grid { align-items: start; }

@media (max-width: 1023px) {
  .hero-grid { grid-template-columns: 1fr; gap: var(--space-6); align-items: start; }
}

@media (max-width: 767px) {
  .hero-note span { white-space: normal; }
}

/* The soft gradient panel the product card floats on. */
.stage { margin-top: clamp(var(--space-12), 5vw, var(--space-18)); }

.stage > .wrap {
  background: var(--gradient-glow);
  border-radius: var(--radius-xl);
  padding: clamp(var(--space-5), 5vw, var(--space-16));
  width: calc(100% - var(--space-gutter) * 2);
}

.stage .app { max-width: 900px; margin: 0 auto; }
.stage .app-caption { justify-content: center; margin-left: auto; margin-right: auto; }

/* ------------------------------------------------------------ tiles ---- */
.grid-2, .grid-3, .grid-4 {
  display: grid;
  gap: var(--space-5);
}

.grid-2 > *, .grid-3 > *, .grid-4 > * { min-width: 0; }

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.tile {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
}

.tile h3 { margin-bottom: var(--space-2); }
.tile p { color: var(--color-text-muted); max-width: 44ch; }
.tile .arrow { margin-top: var(--space-5); }

.tile-num {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-accent);
  margin-bottom: var(--space-4);
}

.band-ink .tile { background: rgb(255 255 255 / 0.06); }
.band-ink .tile p { color: var(--color-on-inverse-soft); }
.band-ink .tile-num { color: var(--color-inverse-accent); }

@media (max-width: 1023px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------- mini snippets ---- */
/* A small piece of product UI inside a feature card. Invented content,
   aria-hidden, with an "Invented examples" caption under the set. */
.tile-ui { display: flex; flex-direction: column; gap: var(--space-5); }

.mini {
  background: var(--color-raised);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  padding: var(--space-4);
  font-size: var(--text-xs);
  line-height: var(--leading-normal);
  color: var(--color-text);
  display: grid;
  gap: var(--space-2);
}

.mini b { font-weight: var(--weight-semibold); }
.mini-row { display: flex; justify-content: space-between; gap: var(--space-2); }
.mini-old { color: var(--color-text-faint); text-decoration: line-through; }
.mini-ok { color: var(--color-ok); }
.mini-flag { color: var(--color-flag); }
.chip { display: inline-block; font-size: var(--text-2xs); color: var(--color-accent); background: var(--color-accent-wash); padding: 2px var(--space-2); border-radius: var(--radius-pill); }
.mini-actions { display: flex; gap: var(--space-2); }
.mini-btn { padding: 6px var(--space-3); border-radius: var(--radius-pill); background: var(--color-surface-strong); }
.mini-btn.is-primary { background: var(--color-accent); color: var(--color-on-accent); }

/* Where a result was read from: a neutral pill in the answer row. */
.src-tag {
  align-self: start;
  justify-self: start;
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  padding: 3px var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--color-raised);
  color: var(--color-text-soft);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  white-space: nowrap;
}

/* Three plain facts in a row under a figure. */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-3); max-width: 900px; margin: var(--space-6) auto 0; }
.facts > div { background: var(--color-raised); border-radius: var(--radius-md); padding: var(--space-5); }
.facts b { display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold); margin-bottom: var(--space-1); }
.facts span { display: block; font-size: var(--text-sm); color: var(--color-text-muted); }
.facts-wide { max-width: none; margin-top: var(--space-3); }
@media (max-width: 767px) { .facts { grid-template-columns: 1fr; } }

/* Two columns that stack below 1024px. */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-10) var(--space-16); align-items: start; }
@media (max-width: 1023px) { .split { grid-template-columns: 1fr; } }

/* --------------------------------------------------- trust pillars ----- */
/* Four commitments. On the homepage they sit in a ruled strip where other
   sites put customer logos (.pillars-strip); elsewhere as cards. */
.pillars {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.pillar {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
}

.pillar h3 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
.pillar p { color: var(--color-text-muted); }
.pillar .arrow { margin-top: var(--space-4); }

.pillars-strip {
  gap: 0;
  border-top: var(--border-hair) dotted var(--color-border-strong);
  border-bottom: var(--border-hair) dotted var(--color-border-strong);
}

.pillars-strip .pillar { background: none; border-radius: 0; padding: var(--space-7) var(--space-6) var(--space-7) 0; }
.pillars-strip .pillar h3 { font-size: var(--text-md); font-weight: var(--weight-semibold); letter-spacing: 0; }
.pillars-strip .pillar p { font-size: var(--text-sm); }

.band-ink .pillar { background: rgb(255 255 255 / 0.06); }
.band-ink .pillar p { color: var(--color-on-inverse-soft); }

@media (max-width: 1023px) { .pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) { .pillars { grid-template-columns: 1fr; } }

/* ------------------------------------------------- process timeline ---- */
/* The engagement as a row of step cards; the key step is highlighted. */
.timeline {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: var(--space-3);
}

.timeline li {
  min-width: 0;
  border: var(--border-hair) solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  background: var(--color-bg);
}

.timeline li.is-key { background: var(--color-accent-wash); border-color: var(--color-accent-line); }

.timeline-when {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  margin-bottom: var(--space-3);
}

.timeline li.is-key .timeline-when { color: var(--color-accent); }

.timeline h3 { font-size: var(--text-md); font-weight: var(--weight-semibold); letter-spacing: 0; margin-bottom: var(--space-1); }
.timeline p { font-size: var(--text-sm); color: var(--color-text-muted); }

@media (max-width: 1023px) { .timeline { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 767px) { .timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Price tiles under the timeline. */
.prices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); margin-top: var(--space-3); }
.price { background: var(--color-surface); border-radius: var(--radius-md); padding: var(--space-6); }
.price span { display: block; font-size: var(--text-sm); color: var(--color-text-faint); margin-bottom: var(--space-1); }
.price b { display: block; font-size: var(--text-xl); font-weight: var(--weight-medium); letter-spacing: var(--tracking-tight); }

@media (max-width: 767px) { .prices { grid-template-columns: 1fr; } }

/* ------------------------------------------------------- explorer ------ */
/* A ruled list, one entry open, with the matching figure beside it. */

.explorer {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: var(--space-14);
  align-items: start;
}

.explorer-list { display: block; min-width: 0; }

.explorer-item { border-top: var(--border-hair) solid var(--color-border-strong); }
.explorer-item.is-open { border-top-color: var(--color-accent); }

.explorer-trigger {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-5);
  width: 100%;
  padding: var(--space-5) 0;
  background: none;
  border: 0;
  cursor: default;
  text-align: left;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-display);
  letter-spacing: var(--tracking-tight);
  line-height: 1.2;
  color: var(--color-text-muted);
  transition: color var(--duration-base) var(--ease-standard);
}

.explorer-item.is-open .explorer-trigger,
.explorer-trigger:hover { color: var(--color-text); }

.js .explorer-trigger { cursor: pointer; }

.js .explorer-trigger::after {
  content: "+";
  flex: none;
  font-family: var(--font-body);
  font-size: var(--text-lg);
  font-weight: 300;
  line-height: 1;
  color: var(--color-accent);
}

.js .explorer-item.is-open .explorer-trigger::after { content: "\2212"; }

/* Collapsing is scoped to .js so that without scripting every entry stays
   readable. visibility follows the collapse to drop closed links from the
   tab order. */
.js .explorer-body {
  overflow: hidden;
  max-height: 0;
  visibility: hidden;
  transition: max-height var(--duration-slow) var(--ease-out), visibility 0s linear var(--duration-slow);
}

.js .explorer-item.is-open .explorer-body {
  max-height: 520px;
  visibility: visible;
  transition: max-height var(--duration-slow) var(--ease-out), visibility 0s linear 0s;
}

.explorer-body-inner { padding: 0 0 var(--space-6); }
.explorer-body p { color: var(--color-text-muted); max-width: 44ch; }
.explorer-body .arrow { margin-top: var(--space-5); }

.explorer-panels { display: grid; gap: var(--space-7); min-width: 0; }
.explorer-panel { min-width: 0; }

.js .explorer-panel {
  grid-area: 1 / 1;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--duration-slow) var(--ease-standard);
}

.js .explorer-panel.is-shown { opacity: 1; visibility: visible; }

@media (max-width: 1023px) {
  .explorer { grid-template-columns: 1fr; gap: var(--space-8); }
}

/* Ruled sub-list with a short dash marker, used inside the explorer and
   feature rows. */
.ticks {
  list-style: none;
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-5);
}

.ticks li {
  position: relative;
  padding-left: var(--space-5);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.66em;
  width: 8px;
  border-top: var(--border-hair) solid var(--color-accent);
}

.band-ink .ticks li { color: var(--color-on-inverse-soft); }

/* ------------------------------------------------------ value props ---- */
/* Parent claim in a ruled header, then named parts under hairlines. */

.vprops { display: grid; gap: clamp(var(--space-14), 6vw, var(--space-24)); }

.vprop-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-4) var(--space-14);
  align-items: baseline;
  padding: var(--space-6) 0;
  border-top: var(--border-hair) solid var(--color-border-strong);
  border-bottom: var(--border-hair) solid var(--color-border);
  margin-bottom: var(--space-10);
}

.vprop-head h3 { font-size: var(--text-xl); }
.vprop-head p { color: var(--color-text-muted); }

.vprop-body {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: var(--space-12);
  align-items: end;
}

.vprop-parts { display: grid; gap: var(--space-6); }
.vprop-part { border-top: var(--border-hair) solid var(--color-border-strong); padding-top: var(--space-4); min-width: 0; }
.vprop-part h4 { margin-bottom: var(--space-1); }
.vprop-part p { color: var(--color-text-muted); }

.vprop-body.is-plain { grid-template-columns: 1fr; }
.vprop-body.is-plain .vprop-parts { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--space-10); }

.band-ink .vprop-head { border-top-color: var(--color-on-inverse); border-bottom-color: var(--color-inverse-border); }
.band-ink .vprop-head p, .band-ink .vprop-part p { color: var(--color-on-inverse-soft); }
.band-ink .vprop-part { border-top-color: var(--color-inverse-border); }

@media (max-width: 1023px) {
  .vprop-head { grid-template-columns: 1fr; }
  .vprop-body { grid-template-columns: 1fr; gap: var(--space-8); align-items: start; }
  .vprop-body.is-plain .vprop-parts { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------------- feature ---- */
/* Prose on one side, a figure on the other, reversed on alternate rows. */

.feature {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: var(--space-10) var(--space-18);
  align-items: center;
  padding: clamp(var(--space-12), 6vw, var(--space-20)) 0;
  border-top: var(--border-hair) solid var(--color-border);
}

.feature-copy, .feature-figure { min-width: 0; }
.feature-flip .feature-copy { order: 2; }
.feature-flip .feature-figure { order: 1; }
.feature h3 { font-size: var(--text-xl); }
.feature-copy p { margin-top: var(--space-4); }
.feature-copy .arrow { margin-top: var(--space-6); }

.band-ink .feature { border-top-color: var(--color-inverse-border); }

@media (max-width: 1023px) {
  .feature { grid-template-columns: 1fr; gap: var(--space-8); }
  .feature-flip .feature-copy { order: 1; }
  .feature-flip .feature-figure { order: 2; }
}

/* ------------------------------------------------------- stat band ----- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}

.stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stats-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.stat { background: var(--color-surface); border-radius: var(--radius-lg); padding: var(--space-7); }

.stat b {
  display: block;
  font-size: var(--text-2xl);
  font-weight: var(--weight-medium);
  line-height: 1;
  letter-spacing: var(--tracking-display);
  color: var(--color-text);
}

.stat span {
  display: block;
  margin-top: var(--space-3);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text-muted);
}

.stat cite {
  display: block;
  margin-top: var(--space-3);
  font-style: normal;
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.stat cite a { color: var(--color-text-faint); }

.band-ink .stat { background: rgb(255 255 255 / 0.06); }
.band-ink .stat b { color: var(--color-on-inverse); }
.band-ink .stat span { color: var(--color-on-inverse-soft); }
.band-ink .stat cite, .band-ink .stat cite a { color: var(--color-on-inverse-faint); }

@media (max-width: 1023px) { .stats, .stats-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) { .stats, .stats-3, .stats-2 { grid-template-columns: 1fr; } }

/* -------------------------------------------------------- rule list ---- */
/* Label left, value right, hairline between. Spec sheets and commitments. */

.rulelist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--space-14);
  border-top: var(--border-hair) solid var(--color-border-strong);
}

.rulelist > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-5);
  padding: var(--space-5) 0;
  border-bottom: var(--border-hair) solid var(--color-border-strong);
}

.rulelist b { flex: 0 0 auto; max-width: 55%; font-weight: var(--weight-semibold); color: var(--color-text); }
.rulelist > div > span { font-size: var(--text-sm); color: var(--color-text-muted); text-align: right; }

.rulelist-1 { grid-template-columns: 1fr; }

.band-ink .rulelist, .band-ink .rulelist > div { border-color: var(--color-inverse-border); }
.band-ink .rulelist b { color: var(--color-on-inverse); }
.band-ink .rulelist > div > span { color: var(--color-on-inverse-faint); }

@media (max-width: 767px) {
  .rulelist { grid-template-columns: 1fr; column-gap: 0; }
  .rulelist > div { flex-direction: column; gap: var(--space-1); }
  .rulelist > div > span { text-align: left; }
  .rulelist b { max-width: none; }
}

/* ---------------------------------------------------- not-held list ---- */
/* What vendor review will ask for that WYEA does not have. Each entry is
   marked plainly; the list is published, not hidden. */

.notheld { list-style: none; border-top: var(--border-hair) solid var(--color-border-strong); }

.notheld li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-2) var(--space-6);
  align-items: baseline;
  padding: var(--space-5) 0;
  border-bottom: var(--border-hair) solid var(--color-border-strong);
}

.notheld b { display: block; }
.notheld p { grid-column: 1; font-size: var(--text-base); color: var(--color-text-muted); }
.notheld .pill { grid-column: 2; grid-row: 1; }

@media (max-width: 767px) {
  .notheld li { grid-template-columns: 1fr; }
  .notheld .pill { grid-column: 1; grid-row: auto; justify-self: start; }
}

/* ----------------------------------------------------------- tables ---- */
/* Shared by the vendor-review table and the comparison table. Below 768px
   each row becomes a block with its column names inline. */

.table-wrap { border: var(--border-hair) solid var(--color-border); border-radius: var(--radius-lg); padding: 0 var(--space-6); overflow: hidden; }

.dtable { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }

.dtable th {
  text-align: left;
  vertical-align: bottom;
  font-size: var(--text-2xs);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--color-text-faint);
  padding: var(--space-4) var(--space-4) var(--space-3) 0;
  border-bottom: var(--border-hair) solid var(--color-border-strong);
}

.dtable td {
  padding: var(--space-5) var(--space-4) var(--space-5) 0;
  border-bottom: var(--border-hair) solid var(--color-border-strong);
  vertical-align: top;
  color: var(--color-text-soft);
  line-height: var(--leading-normal);
}

.dtable th:last-child, .dtable td:last-child { padding-right: 0; }

.dtable tbody th {
  font-family: var(--font-display);
  font-size: var(--text-md);
  font-weight: var(--weight-display);
  letter-spacing: var(--tracking-tight);
  text-transform: none;
  color: var(--color-text);
  vertical-align: top;
  padding-top: var(--space-5);
  width: 24%;
}

.dtable small { display: block; margin-top: var(--space-1); color: var(--color-text-faint); font-size: var(--text-xs); }
.dtable a { color: var(--color-accent-strong); }

/* the column that carries WYEA's answer in a comparison */
.dtable .is-ours { background: var(--color-surface-subtle); padding-left: var(--space-4); }

@media (max-width: 767px) {
  .dtable thead { position: absolute; left: -10000px; }
  .dtable, .dtable tbody, .dtable tr, .dtable th, .dtable td { display: block; width: 100%; }
  .dtable tr { padding: var(--space-5) 0; border-bottom: var(--border-hair) solid var(--color-border-strong); }
  .dtable tbody th, .dtable td { border: 0; padding: 0; width: 100%; }
  .dtable td { margin-top: var(--space-3); }
  .dtable td::before {
    content: attr(data-label);
    display: block;
    font-size: var(--text-2xs);
    font-weight: var(--weight-bold);
    letter-spacing: var(--tracking-caps);
    text-transform: uppercase;
    color: var(--color-text-faint);
    margin-bottom: var(--space-1);
  }
  .dtable .is-ours { padding: var(--space-3); }
}

/* --------------------------------------------------------------- faq --- */
/* Native <details>, so answers are in the HTML and open without script. */

.faq { border-bottom: var(--border-hair) solid var(--color-border-strong); }
.faq details { border-top: var(--border-hair) solid var(--color-border-strong); }
.faq details[open] { border-top-color: var(--color-border-strong); }

.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-6);
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-display);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-snug);
  padding: var(--space-5) 0;
  color: var(--color-text-muted);
  transition: color var(--duration-fast) var(--ease-standard);
}

.faq summary:hover, .faq details[open] summary { color: var(--color-text); }
.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "+";
  font-family: var(--font-body);
  font-size: var(--text-lg);
  font-weight: 300;
  line-height: 1;
  color: var(--color-accent);
  flex: none;
}

.faq details[open] summary::after { content: "\2212"; }

.faq details p { padding: 0 0 var(--space-6); max-width: 74ch; color: var(--color-text-muted); }
.faq details p a { color: var(--color-accent-strong); }

.band-ink .faq, .band-ink .faq details { border-color: var(--color-inverse-border); }
.band-ink .faq details[open] { border-top-color: var(--color-on-inverse); }
.band-ink .faq summary { color: var(--color-on-inverse-soft); }
.band-ink .faq details[open] summary, .band-ink .faq summary:hover { color: var(--color-on-inverse); }
.band-ink .faq details p { color: var(--color-on-inverse-soft); }

/* ------------------------------------------------------- principals ---- */
/* The two principals stand where a customer logo wall would. */

.people {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--space-14);
  row-gap: var(--space-12);
}

.person { background: var(--color-surface); border-radius: var(--radius-lg); padding: var(--space-7); min-width: 0; }

.person-photo {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: var(--space-6);
  align-items: start;
}

.person img {
  width: 104px;
  height: 104px;
  object-fit: cover;
  border: var(--border-hair) solid var(--color-border);
  background: var(--color-surface);
}

.person h2, .person h3 { font-size: var(--text-xl); line-height: 1.2; }

.person .role {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--color-accent);
  margin: var(--space-1) 0 var(--space-3);
}

.person p { color: var(--color-text-muted); }
.person .arrow { margin-top: var(--space-4); }

.people-compact { max-width: 960px; margin: var(--space-10) auto; }

.principals-head { text-align: center; }

.principals-head p {
  margin: 0 auto;
  font-family: var(--font-display);
  font-size: var(--text-xl);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-display);
  color: var(--color-text);
  max-width: 36ch;
}

.principals-foot {
  text-align: center;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.principals-foot p { margin: 0 auto; max-width: none; }

@media (max-width: 767px) {
  .people { grid-template-columns: 1fr; }
  .person-photo { grid-template-columns: 80px minmax(0, 1fr); gap: var(--space-4); }
  .person-photo img { width: 80px; height: 80px; }
}

/* ------------------------------------------------------------ forms ---- */

.field { display: block; margin-bottom: var(--space-4); }

.field > span {
  display: block;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  margin-bottom: var(--space-2);
}

.field .optional { font-weight: var(--weight-regular); color: var(--color-text-faint); }

input[type="text"],
input[type="email"],
textarea {
  display: block;
  width: 100%;
  padding: var(--space-3) var(--space-4);
  border: var(--border-hair) solid var(--color-border-strong);
  border-radius: var(--radius-sm);
  background: var(--color-raised);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  resize: vertical;
}

input:focus, textarea:focus { outline: var(--border-rule) solid var(--color-focus); outline-offset: 1px; border-color: var(--color-rule); }

.band-ink .field > span { color: var(--color-on-inverse-soft); }
.band-ink .field .optional { color: var(--color-on-inverse-faint); }
.band-ink input[type="text"], .band-ink input[type="email"], .band-ink textarea {
  background: var(--color-inverse-bg);
  color: var(--color-on-inverse);
  border-color: var(--color-on-inverse-faint);
}
.band-ink input:focus, .band-ink textarea:focus { outline-color: var(--color-inverse-accent); border-color: var(--color-on-inverse); }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }

@media (max-width: 767px) { .field-row { grid-template-columns: 1fr; } }

button[disabled] { opacity: 0.55; cursor: default; }

/* honeypot: off-screen for people, present for bots */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.form-intro { font-size: var(--text-sm); margin-bottom: var(--space-6); }

.form-status { font-size: var(--text-sm); color: var(--color-flag); min-height: 1.5em; margin-top: var(--space-3); }
.band-ink .form-status { color: var(--color-inverse-accent); }

.contact-success { font-size: var(--text-md); margin-top: var(--space-6); }

/* ------------------------------------------------------- demo funnel --- */
/* /demo: a short step-by-step form before booking. Without scripting every
   step shows at once and the calendar link is offered directly. */
.funnel-band { padding-top: clamp(var(--space-12), 6vw, var(--space-20)); }
.funnel-wrap { max-width: calc(640px + var(--space-gutter) * 2); }
.funnel-head { text-align: center; margin-bottom: var(--space-10); }
.funnel-head h1 { font-size: var(--text-h1-sub); }
.funnel-head .lede { margin: var(--space-4) auto 0; }

.funnel {
  background: var(--color-raised);
  border: var(--border-hair) solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-soft);
  padding: clamp(var(--space-6), 4vw, var(--space-10));
}

.funnel-progress { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-text-faint); margin-bottom: var(--space-2); }
.funnel-bar { height: 4px; border-radius: var(--radius-pill); background: var(--color-surface-strong); margin-bottom: var(--space-8); overflow: hidden; }
.funnel-bar span { display: block; height: 100%; width: 25%; background: var(--color-accent); border-radius: var(--radius-pill); transition: width var(--duration-base) var(--ease-out); }

.funnel-step { border: 0; min-width: 0; }
.funnel-step + .funnel-step { margin-top: var(--space-8); }
.js .funnel-step { display: none; margin-top: 0; }
.js .funnel-step.is-current { display: block; }
.funnel-step legend { font-size: var(--text-xl); font-weight: var(--weight-medium); letter-spacing: var(--tracking-tight); margin-bottom: var(--space-5); padding: 0; }

.choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); }
.choice { position: relative; display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice span {
  display: block;
  padding: var(--space-4) var(--space-5);
  border: var(--border-hair) solid var(--color-border-strong);
  border-radius: var(--radius-md);
  font-weight: var(--weight-medium);
  transition: border-color var(--duration-fast) var(--ease-standard), background var(--duration-fast) var(--ease-standard);
}
.choice:hover span { border-color: var(--color-accent-line); }
.choice input:checked + span { border-color: var(--color-accent); background: var(--color-accent-wash); }
.choice input:focus-visible + span { outline: var(--border-rule) solid var(--color-focus); outline-offset: 2px; }

.funnel-nav { display: flex; justify-content: space-between; gap: var(--space-3); margin-top: var(--space-8); }
.funnel-nav [data-next], .funnel-nav [data-submit] { margin-left: auto; }
.funnel-done { text-align: center; }
.funnel-done .lede { margin: var(--space-3) auto 0; }
.funnel-done .actions { justify-content: center; }

@media (max-width: 767px) { .choices { grid-template-columns: 1fr; } }

/* --------------------------------------------------- call to action ---- */
/* The closing panel: the same soft gradient as the product stage. */
.cta-band { padding: 0 0 var(--space-band); }

.cta-band > .wrap {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: var(--gradient-glow);
  border-radius: var(--radius-xl);
  padding: clamp(var(--space-10), 6vw, var(--space-20));
  width: calc(100% - var(--space-gutter) * 2);
}

.cta-band .lede { color: var(--color-text-soft); }
.cta-band h2 { max-width: 14ch; font-size: clamp(2.4rem, 5vw, 4.5rem); }
.cta-band .eyebrow { color: var(--color-accent); }

.cta-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-10) var(--space-18);
  align-items: start;
}

.cta-split > * { min-width: 0; }

.cta-center { text-align: center; }
.cta-center h2 { margin: 0 auto; }
.cta-center .lede { margin-left: auto; margin-right: auto; }
.cta-center .actions { justify-content: center; }

.cta-band form {
  background: rgb(255 255 255 / 0.86);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
}

@media (max-width: 1023px) { .cta-split { grid-template-columns: 1fr; } }

/* ----------------------------------------------------------- footer ---- */
.site-footer {
  background: var(--color-bg);
  color: var(--color-text-faint);
  border-top: var(--border-hair) dotted var(--color-border-strong);
  padding: var(--space-20) 0 var(--space-7);
  font-size: var(--text-sm);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(4, minmax(0, 1fr));
  gap: var(--space-10) var(--space-8);
}

.footer-brand .wordmark { color: var(--color-text); }

.footer-brand p {
  margin-top: var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-text-faint);
  max-width: 30ch;
}

.footer-col h2 {
  font-family: var(--font-body);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: var(--space-4);
}

.footer-col ul { list-style: none; display: grid; gap: var(--space-3); }

.footer-col a { color: var(--color-text-muted); text-decoration: none; }
.footer-col a:hover { color: var(--color-text); }

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-6);
  margin-top: var(--space-12);
  padding-top: var(--space-5);
  border-top: var(--border-hair) dotted var(--color-border-strong);
  font-size: var(--text-xs);
}

.footer-legal a { color: var(--color-text-faint); text-decoration: none; }
.footer-legal a:first-of-type { margin-left: auto; }
.footer-legal a:hover { color: var(--color-text); }

@media (max-width: 1023px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 767px) { .footer-grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------- prose page ---- */

.page-head {
  padding: clamp(var(--space-12), 6vw, var(--space-20)) 0 clamp(var(--space-8), 4vw, var(--space-14));
  border-bottom: var(--border-hair) dotted var(--color-border-strong);
}

.crumb {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-6);
}

.crumb a { color: var(--color-accent-strong); }
.crumb a:hover { color: var(--color-text); }

.page-head h1 { font-size: var(--text-h1-sub); max-width: 20ch; }

.prose { padding: clamp(var(--space-12), 6vw, var(--space-20)) 0; }

.prose h2 { font-size: var(--text-xl); margin: var(--space-12) 0 var(--space-3); }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin: var(--space-10) 0 var(--space-2); }
.prose p, .prose li { line-height: 1.65; }
.prose p { margin-bottom: var(--space-5); }
.prose ul, .prose ol { margin: 0 0 var(--space-6) var(--space-5); }
.prose li { margin-bottom: var(--space-2); color: var(--color-text-soft); }
.prose a { color: var(--color-accent-strong); }
.prose table { margin: var(--space-6) 0 var(--space-8); }

.callout {
  background: var(--color-surface);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin: var(--space-6) 0 var(--space-8);
}

.callout p { margin: 0; }
.callout a { color: var(--color-accent-strong); }

/* --------------------------------------------------- article layout ---- */
/* Research and guide pages: byline, dates, body, sources. */

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-6);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: var(--border-hair) solid var(--color-border);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  max-width: var(--width-text);
}

.article-meta b { color: var(--color-text); font-weight: var(--weight-semibold); }

.sources {
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  border-top: var(--border-hair) solid var(--color-border-strong);
}

.sources h2 { font-size: var(--text-lg); margin: 0 0 var(--space-4); }

.sources ol { margin: 0 0 0 var(--space-5); }

.sources li { font-size: var(--text-sm); color: var(--color-text-muted); margin-bottom: var(--space-2); overflow-wrap: anywhere; }

.draft-banner {
  border: var(--border-hair) solid var(--color-warning);
  background: var(--color-warning-wash);
  color: var(--color-text);
  padding: var(--space-4) var(--space-5);
  font-size: var(--text-sm);
  margin-bottom: var(--space-8);
}

.draft-banner b { color: var(--color-warning); }

/* --------------------------------------------------- related links ----- */
.explore {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-4);
}

.explore a {
  display: block;
  background: var(--color-surface);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  text-decoration: none;
  transition: background var(--duration-fast) var(--ease-standard);
}

.explore a:hover { background: var(--color-surface-strong); }

.explore small {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-accent);
  margin-bottom: var(--space-3);
}

.explore b {
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-snug);
  display: block;
}

.explore a::after {
  content: "\2192";
  display: inline-block;
  margin-top: var(--space-3);
  color: var(--color-accent);
  transition: transform var(--duration-fast) var(--ease-standard);
}

.explore a:hover::after { transform: translateX(3px); }

@media (max-width: 767px) { .explore { grid-template-columns: 1fr; } }

/* ------------------------------------------------------- reveal -------- */
/* Scoped to .js so that without scripting every section is visible. The
   inline head script that sets .js removes it again after four seconds if
   site.js has not reported in, so a blocked or failed site.js leaves the
   page readable rather than transparent. */

.js .reveal { opacity: 0; transform: translateY(28px); filter: blur(6px); }

.js .reveal.is-in {
  opacity: 1;
  transform: none;
  filter: none;
  transition: opacity var(--duration-reveal) var(--ease-out), transform var(--duration-reveal) var(--ease-out), filter var(--duration-reveal) var(--ease-out);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .js .reveal.is-in { opacity: 1; transform: none; filter: none; transition: none; }
}

/* ===========================================================================
   Interface figures
   ---------------------------------------------------------------------------
   Drawn in HTML, not captured. Every figure shares one window (.app), is
   role="img" with a full aria-label, and every name and number in it is
   invented and labeled so.
   ========================================================================= */

.app {
  max-width: 100%;
  background: var(--color-raised);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: var(--color-text);
  overflow: hidden;
}

.app-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2) var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: var(--border-hair) solid var(--color-border);
  font-size: var(--text-base);
  font-weight: var(--weight-medium);
  color: var(--color-text);
}

.app-bar .dot { width: 10px; height: 10px; border-radius: var(--radius-pill); background: var(--color-accent); flex: none; animation: dot-pulse 2.4s var(--ease-standard) infinite; }

/* A slow pulse on the figure's status dot, so the product reads as live.
   Off under prefers-reduced-motion. */
@keyframes dot-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgb(58 63 224 / 0.35); }
  50% { opacity: 0.45; box-shadow: 0 0 0 6px rgb(58 63 224 / 0); }
}

@media (prefers-reduced-motion: reduce) {
  .app-bar .dot { animation: none; }
}

.app-meta {
  margin-left: auto;
  font-family: var(--font-mono);
  font-weight: var(--weight-regular);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.app-foot {
  padding: var(--space-3) var(--space-5);
  border-top: var(--border-hair) solid var(--color-border);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.app-foot b { color: var(--color-text); }

/* The visible label that every example on the site is invented. */
.tag-invented {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--color-text-faint);
}

.app-caption {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-3);
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  max-width: 70ch;
}

/* source-answer card: what a person gets back from a question */

.ans { padding: var(--space-2) 0; }

.ans-row {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: var(--space-4);
  padding: var(--space-4);
  margin: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
}

.ans-row:has(.ans-flag) { background: var(--color-flag-ground); }

.ans-mark {
  align-self: start;
  justify-self: start;
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  padding: 3px var(--space-3);
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.ans-ok { color: var(--color-ok); background: var(--color-ok-wash); }
.ans-now { color: var(--color-accent); background: var(--color-accent-wash); }
.ans-next { color: var(--color-text-muted); background: var(--color-surface-strong); }
.ans-row.is-now { background: var(--color-raised); box-shadow: inset 0 0 0 1px var(--color-accent-line); }
.ans-row.is-next { background: var(--color-raised); box-shadow: inset 0 0 0 1px var(--color-border); }
.ans-body .ans-src + .ans-src { margin-top: 0; }
.ans-flag { color: var(--color-flag); background: var(--color-flag-wash); }

.ans-body b { display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold); }

.ans-body q {
  display: block;
  margin-top: var(--space-1);
  font-size: var(--text-base);
  line-height: 1.45;
  color: var(--color-text-soft);
}

.ans-src {
  display: block;
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.ans-note {
  margin-top: var(--space-1);
  font-size: var(--text-sm);
  line-height: 1.45;
  color: var(--color-text-muted);
}

@media (max-width: 767px) {
  .ans-row { grid-template-columns: 1fr; gap: var(--space-2); padding: var(--space-4); }
}

/* connected-sources table inside a figure */

.fig-table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }

.fig-table th {
  text-align: left;
  font-size: var(--text-2xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-faint);
  padding: var(--space-3) var(--space-4);
  border-bottom: var(--border-hair) solid var(--color-border);
  white-space: nowrap;
}

.fig-table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: var(--border-hair) solid var(--color-border);
  vertical-align: top;
  color: var(--color-text-soft);
}

.fig-table tr:last-child td { border-bottom: 0; }
.fig-table td b { font-weight: var(--weight-semibold); display: block; }
.fig-table td small { display: block; color: var(--color-text-faint); font-size: var(--text-xs); line-height: 1.4; }

.fig-scroll { overflow-x: auto; }

@media (max-width: 767px) {
  .fig-table thead { position: absolute; left: -10000px; }
  .fig-table, .fig-table tbody, .fig-table tr, .fig-table td { display: block; width: 100%; }
  .fig-table tr { padding: var(--space-4); border-bottom: var(--border-hair) solid var(--color-border); }
  .fig-table tr:last-child { border-bottom: 0; }
  .fig-table td { border: 0; padding: 0; }
  .fig-table td + td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: var(--space-4);
    margin-top: var(--space-2);
  }
  .fig-table td + td::before {
    content: attr(data-label);
    font-size: var(--text-2xs);
    font-weight: var(--weight-bold);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-faint);
    flex: none;
  }
  .fig-scroll { overflow-x: visible; }
}

/* status pills */

.pill {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  padding: 3px var(--space-3);
  border-radius: var(--radius-pill);
  white-space: nowrap;
  line-height: var(--leading-normal);
}

.pill-ok { color: var(--color-ok); background: var(--color-ok-wash); }
.pill-flag { color: var(--color-flag); background: var(--color-flag-wash); }
.pill-mute { color: var(--color-text-muted); background: var(--color-surface); }
.pill-ask { color: var(--color-warning); background: var(--color-warning-wash); }

/* dated timeline inside a figure */

.fig-dates { padding: var(--space-1) 0; }

.date-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  gap: var(--space-4);
  align-items: baseline;
  padding: var(--space-3) var(--space-4);
  border-bottom: var(--border-hair) solid var(--color-border);
}

.date-row:last-child { border-bottom: 0; }

.date-when {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--color-text);
  white-space: nowrap;
}

.date-what b { display: block; font-weight: var(--weight-semibold); font-size: var(--text-sm); }
.date-what small { color: var(--color-text-muted); font-size: var(--text-xs); }

.date-row.is-near { background: var(--color-flag-wash); }
.date-row.is-near .date-when { color: var(--color-flag); }

@media (max-width: 767px) {
  .date-row { grid-template-columns: 1fr; gap: var(--space-1); }
  .date-row .pill { justify-self: start; }
}

/* one system per client */

.fig-deploy { padding: var(--space-6) var(--space-5); }

.boundary {
  border: var(--border-hair) solid var(--color-border-strong);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-4) var(--space-5);
  position: relative;
  background: var(--color-surface-subtle);
}

.boundary-label {
  position: absolute;
  top: -9px;
  left: var(--space-3);
  background: var(--color-raised);
  padding: 0 var(--space-2);
  font-size: var(--text-2xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text);
}

.node-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-3); }

.node {
  border: var(--border-hair) solid var(--color-border-strong);
  background: var(--color-raised);
  padding: var(--space-3);
  font-size: var(--text-xs);
}

.node b { display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold); margin-bottom: 2px; }
.node span { color: var(--color-text-muted); font-size: var(--text-xs); line-height: 1.4; display: block; }

.egress {
  margin-top: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  padding: var(--space-3);
  border: var(--border-hair) dashed var(--color-border-strong);
}

.egress .pill { flex: none; }

@media (max-width: 767px) { .node-row { grid-template-columns: 1fr; } }


/* ===========================================================================
   Light fields and the homepage
   ---------------------------------------------------------------------------
   The imagery of Direction B is light. A .lights block is a set of soft blurred
   shapes that drift on their own and follow the pointer and the scroll a
   little (site.js sets --px, --py, --sy and each shape's --d). Content sits
   above it. Everything here works with scripting off and with reduced motion.
   ========================================================================= */

.lights { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }

.blob {
  position: absolute;
  width: 46%;
  aspect-ratio: 1.15;
  border-radius: 62% 38% 55% 45% / 48% 58% 42% 52%;
  background: radial-gradient(closest-side, var(--field-a) 0%, transparent 100%);
  filter: blur(46px);
  opacity: 0.95;
  will-change: transform, translate;
  translate:
    calc(var(--px, 0) * var(--d, 0.5) * 36px)
    calc(var(--py, 0) * var(--d, 0.5) * 36px + var(--sy, 0) * var(--d, 0.5) * -90px);
  animation: drift var(--duration-drift) ease-in-out infinite alternate;
}

.blob-a { left: -6%; top: 6%; }
.blob-b { right: -8%; top: 22%; width: 52%; background: radial-gradient(closest-side, var(--field-b) 0%, transparent 100%); animation-duration: calc(var(--duration-drift) * 1.3); animation-delay: -6s; }
.blob-c { left: 28%; bottom: -14%; width: 44%; background: radial-gradient(closest-side, var(--field-c) 0%, transparent 100%); animation-duration: calc(var(--duration-drift) * 0.9); animation-delay: -11s; }
.blob-d { left: 34%; top: -10%; width: 40%; background: radial-gradient(closest-side, var(--field-d) 0%, transparent 100%); }

@keyframes drift {
  0%   { transform: rotate(0deg) scale(1); border-radius: 62% 38% 55% 45% / 48% 58% 42% 52%; }
  50%  { transform: rotate(14deg) scale(1.12) translateX(4%); border-radius: 44% 56% 38% 62% / 60% 42% 58% 40%; }
  100% { transform: rotate(-8deg) scale(0.96) translateY(5%); border-radius: 56% 44% 62% 38% / 42% 60% 40% 58%; }
}

.grain { position: absolute; inset: 0; background: var(--grain); background-size: 160px; opacity: 0.07; mix-blend-mode: multiply; }

.lights-dark .blob { opacity: 0.38; }
.lights-dark .grain { opacity: 0.2; mix-blend-mode: screen; }

/* ------------------------------------------------------------- hero ---- */

.hero2 {
  position: relative;
  isolation: isolate;
  overflow: clip;
  margin-top: calc(var(--header-h) * -1);
  padding: calc(var(--header-h) + var(--space-12)) 0 var(--space-16);
  min-height: min(100svh, 960px);
  display: flex;
  align-items: center;
}

.hero2 > .wrap { position: relative; z-index: 1; }

.hero2-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: var(--space-12) var(--space-14);
  align-items: center;
}

.hero2-grid > * { min-width: 0; }

.hero2 h1 {
  font-size: clamp(2.75rem, 5.7vw, 5.4rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  max-width: 12ch;
}

.hero2 .lede { max-width: 34ch; font-weight: var(--weight-regular); margin-top: var(--space-8); }

/* three sheets of paper that answer with their source */
.sheets { position: relative; min-height: 560px; margin: 0; }

.sheet {
  position: absolute;
  display: grid;
  gap: var(--space-2);
  align-content: start;
  padding: var(--space-5);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background: rgb(255 255 255 / 0.74);
  backdrop-filter: blur(14px);
  border: var(--border-hair) solid rgb(255 255 255 / 0.8);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  transform: rotate(var(--r, 0deg));
  translate:
    calc(var(--px, 0) * var(--d, 0.5) * 18px)
    calc(var(--py, 0) * var(--d, 0.5) * 18px + var(--sy, 0) * var(--d, 0.5) * -46px);
}

.sheet-back { --r: -5deg; left: 0; top: 2%; width: 60%; }
.sheet-mid { --r: 3.5deg; right: 0; top: 20%; width: 64%; }
.sheet-front { --r: -1.5deg; left: 10%; bottom: 7%; width: 76%; background: rgb(255 255 255 / 0.94); gap: var(--space-3); }

.sheet-title { font-size: var(--text-2xs); font-weight: var(--weight-medium); letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--color-text-faint); margin-bottom: var(--space-1); }

.bar { display: block; height: 6px; border-radius: var(--radius-pill); background: var(--color-border-strong); }
.w50 { width: 50%; } .w55 { width: 55%; } .w60 { width: 60%; } .w64 { width: 64%; } .w70 { width: 70%; }
.w76 { width: 76%; } .w78 { width: 78%; } .w82 { width: 82%; } .w84 { width: 84%; } .w88 { width: 88%; } .w90 { width: 90%; }

.clause { font-size: var(--text-sm); color: var(--color-text-faint); margin: var(--space-1) 0; }

.mark-line { font-size: var(--text-sm); color: var(--color-text-soft); margin: var(--space-1) 0; }

.mark-line mark {
  color: var(--color-text);
  background: linear-gradient(var(--field-c), var(--field-c)) 0 88% / 0% 78% no-repeat;
  animation: mark-in 1.4s var(--ease-out) 1.1s forwards;
  padding: 0 2px;
}

@keyframes mark-in { to { background-size: 100% 78%; } }

.sheet-front b { font-weight: var(--weight-medium); font-size: var(--text-sm); }
.sheet-front q { font-size: var(--text-lg); font-weight: var(--weight-display); letter-spacing: var(--tracking-tight); line-height: 1.25; color: var(--color-text); }
.sheet-front .src-tag { font-weight: var(--weight-regular); }
.sheet-front .ans-mark { justify-self: start; }
.sheet-flag { display: flex; align-items: center; gap: var(--space-3); padding-top: var(--space-3); border-top: var(--border-hair) dotted var(--color-border-strong); font-size: var(--text-xs); color: var(--color-text-muted); }

.sheets-caption { position: absolute; right: 0; bottom: -2px; margin: 0; }

@media (max-width: 1023px) {
  .hero2 { min-height: 0; padding-bottom: var(--space-12); }
  .hero2-grid { grid-template-columns: 1fr; }
  .sheets { min-height: 480px; max-width: 560px; }
}

@media (max-width: 767px) {
  .hero2 { padding-top: calc(var(--header-h) + var(--space-8)); }
  .sheets { min-height: 580px; }
  .sheet-back { width: 70%; }
  .sheet-mid { width: 78%; top: 17%; }
  .sheet-front { left: 0; width: 92%; bottom: 3%; }
  .statement-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ----------------------------------------------------------- ticker ---- */
.ticker {
  overflow: hidden;
  border-top: var(--border-hair) dotted var(--color-border-strong);
  border-bottom: var(--border-hair) dotted var(--color-border-strong);
  padding: var(--space-7) 0;
  -webkit-mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}

.ticker { position: relative; }
.ticker.is-paused .ticker-track { animation-play-state: paused; }

.ticker-pause {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  z-index: 2;
  translate: 0 -50%;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--color-bg);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  cursor: pointer;
}

.ticker-pause span { position: absolute; inset: 0; margin: auto; width: 8px; height: 10px; border-left: 2px solid var(--color-text); border-right: 2px solid var(--color-text); }
.ticker-pause[aria-pressed="true"] span { width: 0; height: 0; border: 0; border-left: 9px solid var(--color-text); border-top: 6px solid transparent; border-bottom: 6px solid transparent; left: 3px; }

.ticker-track { display: flex; width: max-content; animation: ticker 48s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker ul { display: flex; flex: none; list-style: none; }

.ticker li {
  display: flex;
  align-items: center;
  font-size: var(--text-xl);
  font-weight: var(--weight-display);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text-faint);
  white-space: nowrap;
}

.ticker li::before {
  content: "";
  width: 6px;
  height: 6px;
  margin: 0 var(--space-10);
  border-radius: var(--radius-pill);
  background: var(--color-border-strong);
}

@keyframes ticker { to { transform: translateX(-50%); } }

/* -------------------------------------------------------- statement ---- */
.band.statement { padding: clamp(var(--space-24), 14vw, 220px) 0; }

.statement-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 2.2fr); gap: var(--space-8) var(--space-14); align-items: start; }

.statement-label {
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-snug);
  color: var(--color-text-faint);
  max-width: 14ch;
  position: sticky;
  top: calc(var(--header-h) + var(--space-8));
}

.statement-text {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 3.25rem);
  font-weight: var(--weight-display);
  line-height: 1.16;
  letter-spacing: var(--tracking-display);
  color: var(--color-text);
  max-width: none;
  text-wrap: pretty;
}

.js .statement-text .w { opacity: 0.4; transition: opacity var(--duration-slow) var(--ease-out); }
.js .statement-text .w.is-lit { opacity: 1; }

@media (max-width: 1023px) {
  .statement-grid { grid-template-columns: 1fr; }
  .statement-label { position: static; }
}

/* ------------------------------------------------------------- caps ---- */
/* Three panels that stack as they scroll. */
.caps { padding-bottom: var(--space-band-tight); }

.cap {
  position: sticky;
  top: calc(var(--header-h) + var(--space-4));
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-8) var(--space-14);
  align-items: center;
  min-height: min(68vh, 540px);
  margin-bottom: var(--space-6);
  padding: clamp(var(--space-8), 5vw, var(--space-20));
  background: var(--color-raised);
  border-radius: var(--radius-xl);
}

.cap-2 { top: calc(var(--header-h) + var(--space-4) + 14px); }
.cap-2 .cap-ui { order: -1; }
.cap-2 .cap-copy { justify-self: end; }
.cap-3 { top: calc(var(--header-h) + var(--space-4) + 28px); }

.cap > :not(.lights) { position: relative; z-index: 1; }
.cap h3 { font-size: clamp(2rem, 3.8vw, 3.25rem); font-weight: var(--weight-display); line-height: 1.04; letter-spacing: var(--tracking-display); max-width: 12ch; }
.cap p { margin-top: var(--space-5); font-size: var(--text-lg); color: var(--color-text-soft); max-width: 30ch; }

.cap-ui {
  justify-self: center;
  width: min(100%, 400px);
  padding: var(--space-6);
  font-size: var(--text-sm);
  gap: var(--space-3);
  background: rgb(255 255 255 / 0.8);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-card);
  transition: transform var(--duration-slow) var(--ease-out);
}

.cap-ui { transform: rotate(-1.8deg); margin-right: calc(var(--space-8) * -1); }
.cap-2 .cap-ui { transform: rotate(1.6deg); margin-right: 0; margin-left: calc(var(--space-8) * -1); }
.cap:hover .cap-ui { transform: translateY(-6px) rotate(0deg); }
.cap .blob { opacity: 1; filter: blur(38px); }
.cap .grain { opacity: 0.04; mix-blend-mode: soft-light; }
.cap-1 .blob-a { --field-a: #f0b3c6; }
.cap-1 .blob-b { --field-b: var(--glow-sage); }
.cap-2 .blob-c { --field-c: #f6c39a; }
.cap-2 .blob-a { --field-a: #f4b8a8; }
.cap-3 .blob-b { --field-b: var(--glow-sage); }
.cap-3 .blob-d { --field-d: #b8dcc0; }

@media (max-width: 1023px) {
  .cap { position: relative; top: auto; grid-template-columns: 1fr; min-height: 0; }
  .cap-ui, .cap-2 .cap-ui { margin: 0; order: 0; }
  .cap-2 .cap-copy { justify-self: start; }
}

/* ------------------------------------------------- open section styles -- */
.open-head { margin-bottom: var(--space-14); }
.open-head h2 { max-width: 16ch; }

.stats-open { gap: 0 var(--space-8); }

.stats-open .stat {
  background: none;
  border-radius: 0;
  border-top: var(--border-hair) dotted var(--color-border-strong);
  padding: var(--space-8) 0 var(--space-6);
}

.stats-open .stat b { font-size: clamp(1.9rem, 2.9vw, 2.7rem); font-weight: var(--weight-display); line-height: 1.05; }

.tiles-open .tile {
  background: none;
  border-radius: 0;
  border-top: var(--border-hair) dotted var(--color-border-strong);
  padding: var(--space-6) var(--space-6) 0 0;
}

.prices-open { gap: var(--space-6) var(--space-8); }
.prices-open .price { background: none; border-radius: 0; border-top: var(--border-hair) dotted var(--color-border-strong); padding: var(--space-6) 0 0; }
.prices-open .price b { font-size: clamp(1.9rem, 3.4vw, 3rem); font-weight: var(--weight-display); line-height: 1.05; }

/* the engagement as a line that draws itself as you reach it */
.steps {
  position: relative;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0 var(--space-5);
  padding-top: var(--space-8);
  margin-bottom: var(--space-14);
}

.steps::before, .steps::after { content: ""; position: absolute; top: 4px; left: 0; right: 0; height: 0; }
.steps::before { border-top: var(--border-hair) dotted var(--color-border-strong); }
.steps::after { border-top: var(--border-hair) solid var(--color-text); transform-origin: left; transform: scaleX(var(--p, 1)); }

.steps li { position: relative; min-width: 0; }

.steps li::before {
  content: "";
  position: absolute;
  top: calc(var(--space-8) * -1 + 0px);
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: var(--radius-pill);
  background: var(--color-bg);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  transition: background var(--duration-base) var(--ease-out), box-shadow var(--duration-base) var(--ease-out);
}

.steps li::before { background: var(--color-text); box-shadow: none; }
.steps.is-tracked li:not(.is-on)::before { background: var(--color-bg); box-shadow: inset 0 0 0 1px var(--color-border-strong); }
.steps li.is-key::before { background: var(--color-accent); }
.steps.is-tracked li.is-key:not(.is-on)::before { background: var(--color-bg); }
.steps-n { display: block; font-size: var(--text-xs); letter-spacing: var(--tracking-label); color: var(--color-text-faint); margin-bottom: var(--space-2); }
.steps li.is-key .steps-n { color: var(--color-accent); }
.steps h3 { font-size: var(--text-xl); font-weight: var(--weight-display); letter-spacing: var(--tracking-display); }

@media (max-width: 1023px) { .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: var(--space-10); } .steps::before, .steps::after { display: none; } .steps li::before { display: none; } }
@media (max-width: 767px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.cta-band > .wrap > :not(.lights) { position: relative; z-index: 1; }

.band-ink :focus-visible { outline-color: var(--color-inverse-accent); }

/* the dark panel carries a faint field of its own */
.band-ink > .wrap { position: relative; overflow: hidden; isolation: isolate; }
.band-ink > .wrap > :not(.lights) { position: relative; z-index: 1; }

/* ----------------------------------------------------- reduced motion --- */
@media (prefers-reduced-motion: reduce) {
  .blob, .sheet { animation: none; translate: none; }
  .mark-line mark { animation: none; background-size: 100% 78%; }
  .ticker-track { animation: none; flex-wrap: wrap; width: auto; }
  .ticker ul[aria-hidden="true"], .ticker-pause { display: none; }
  .ticker ul { flex-wrap: wrap; row-gap: var(--space-3); }
  .ticker { -webkit-mask: none; mask: none; }
  .js .statement-text .w { opacity: 1; transition: none; }
  .cap { position: relative; top: auto; }
  .cap:hover .cap-ui { transform: none; }
}

/* ===========================================================================
   Firm memory explorer (/explore)
   ---------------------------------------------------------------------------
   An invented insurer's documents as a clickable map. The HTML is a plain
   list of documents and answered questions that reads fine with scripting
   off. site.js builds the map from that list and adds .is-live to the
   section. Nodes sit on a 160 by 100 grid (--x, --y); the lines are an SVG on
   the same grid, so a node and its lines always move together.
   ========================================================================= */

.mem-head { margin-bottom: var(--space-10); }
.mem-head .lede { max-width: 52ch; }

.js-only { display: none; }
.is-live .js-only { display: inline-flex; }

.mem-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-6);
  margin-bottom: var(--space-4);
}

.mem-bar[hidden], .mem-canvas[hidden] { display: none; }

.mem-modes { display: inline-flex; padding: var(--space-1); border-radius: var(--radius-pill); box-shadow: inset 0 0 0 1px var(--color-border-strong); background: var(--color-raised); }

.mem-mode {
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  min-height: 40px;
  padding: 0 var(--space-5);
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background var(--duration-base) var(--ease-out), color var(--duration-base) var(--ease-out);
}

.mem-mode:hover { color: var(--color-text); }
.mem-mode[aria-pressed="true"] { background: var(--color-btn-bg); color: var(--color-btn-text); }

.mem-search input {
  font: inherit;
  font-size: var(--text-sm);
  width: 240px;
  max-width: 100%;
  min-height: 48px;
  padding: 0 var(--space-5);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--color-raised);
  color: var(--color-text);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
}

.mem-search input:focus { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.mem-search input::placeholder { color: var(--color-text-faint); }

.mem-body { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: var(--space-6); align-items: start; }
.mem-body > * { min-width: 0; }

.mem-canvas {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  container-type: inline-size;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-xl);
  background: radial-gradient(var(--color-border-strong) 1px, transparent 1.5px) 0 0 / 24px 24px, rgb(255 255 255 / 0.72);
  box-shadow: inset 0 0 0 1px var(--color-border);
}

.mem-edges, .mem-nodes, .mem-zones { position: absolute; z-index: 1; }
.mem-edges { inset: 0; width: 100%; height: 100%; }
.mem-nodes, .mem-zones { inset: 0; }
.mem-nodes { pointer-events: none; }

.mem-edge {
  stroke: var(--color-border-strong);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
  transition: stroke var(--duration-base) var(--ease-out), opacity var(--duration-base) var(--ease-out);
}

.mem-edge.is-folder { stroke-dasharray: 2 4; opacity: 0.8; }
.is-meaning .mem-edge.is-folder { opacity: 0; }
.mem-edge.is-dim { opacity: 0.25; }
.mem-edge.is-hot { stroke: var(--color-accent); stroke-width: 2; opacity: 1; stroke-dasharray: 7 7; animation: edge-flow 1.1s linear infinite; }

@keyframes edge-flow { to { stroke-dashoffset: -14; } }

.mem-zone {
  position: absolute;
  left: calc(var(--zx) / 160 * 100%);
  top: 5%;
  translate: -50% -50%;
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--color-text-muted);
  opacity: 0;
  transition: opacity var(--duration-slow) var(--ease-out);
}

.is-meaning .mem-zone { opacity: 1; }
.mem-zone[data-zone="cover"] { --zx: 20; }
.mem-zone[data-zone="claims"] { --zx: 60; }
.mem-zone[data-zone="underwriting"] { --zx: 100; }
.mem-zone[data-zone="programs"] { --zx: 140; }

.mem-node {
  position: absolute;
  left: calc(var(--x) / 160 * 100%);
  top: calc(var(--y) / 100 * 100%);
  translate: -50% -50%;
  width: 20%;
  min-height: 52px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-2);
  align-items: center;
  padding: var(--space-2) var(--space-3);
  text-align: left;
  font: inherit;
  color: var(--color-text);
  background: var(--color-raised);
  border: 0;
  border-radius: var(--radius-md);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  cursor: pointer;
  pointer-events: auto;
  transition: opacity var(--duration-base) var(--ease-out), box-shadow var(--duration-base) var(--ease-out), background var(--duration-base) var(--ease-out);
}

.mem-node:hover { box-shadow: inset 0 0 0 1px var(--color-text); }
.mem-node:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.mem-node-icon { display: none; place-items: center; width: 28px; height: 28px; border-radius: var(--radius-sm); background: var(--color-surface); color: var(--color-text-soft); transition: background var(--duration-base) var(--ease-out), color var(--duration-base) var(--ease-out); }
.mem-node-icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.mem-node-text { display: grid; min-width: 0; }
.mem-node:hover .mem-node-icon, .mem-node[aria-pressed="true"] .mem-node-icon, .mem-node.is-source .mem-node-icon { background: var(--color-accent); color: var(--color-on-accent); }
@container (min-width: 680px) {
  .mem-node { grid-template-columns: auto minmax(0, 1fr); }
  .mem-node-icon { display: grid; }
}

@container (max-width: 559px) {
  .mem-node-title { font-size: var(--text-2xs); }
}

.is-files .mem-node-icon { display: none; }
.is-files .mem-node { grid-template-columns: minmax(0, 1fr); }
.mem-node-title { font-size: var(--text-xs); font-weight: var(--weight-medium); line-height: var(--leading-normal); overflow-wrap: break-word; }
.mem-node-sub { font-size: var(--text-2xs); color: var(--color-text-faint); line-height: var(--leading-normal); }
.is-files .mem-node-title { font-family: var(--font-mono); font-weight: var(--weight-regular); color: var(--color-text-soft); }
.mem-node.is-dim { opacity: 0.32; }
.mem-node.is-source, .mem-node.is-near { box-shadow: inset 0 0 0 1px var(--color-accent-line); background: var(--color-accent-wash); }
.mem-node[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--color-accent), var(--shadow-glow); background: var(--color-accent-wash); }
.mem-node.is-source { box-shadow: inset 0 0 0 1px var(--color-accent), var(--shadow-glow); }

.mem-caption { margin-top: var(--space-3); font-size: var(--text-sm); color: var(--color-text-muted); max-width: 60ch; }

.mem-panel {
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  background: var(--color-raised);
  box-shadow: inset 0 0 0 1px var(--color-border);
}

.mem-title { font-size: var(--text-lg); font-weight: var(--weight-regular); letter-spacing: var(--tracking-tight); margin-bottom: var(--space-4); }
.mem-hint { margin-top: var(--space-5); font-size: var(--text-sm); color: var(--color-text-faint); }

.qs { list-style: none; border-top: var(--border-hair) dotted var(--color-border-strong); }
.q { padding: var(--space-4) 0; border-bottom: var(--border-hair) dotted var(--color-border-strong); }

.q-btn {
  all: unset;
  box-sizing: border-box;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-4);
  width: 100%;
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  font-weight: var(--weight-medium);
  color: var(--color-text);
}

.is-live .q { padding: 0; }
.is-live .q-btn { padding: var(--space-4) 0; cursor: pointer; font-weight: var(--weight-regular); }
.is-live .q-btn::after { content: ""; flex: 0 0 14px; height: 14px; background: currentColor; mask: var(--arrow-mask) center / contain no-repeat; transition: translate var(--duration-base) var(--ease-out); }
.is-live .q-btn:hover { color: var(--color-accent); }
.is-live .q-btn:hover::after { translate: 4px 0; }
.is-live .q-btn:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; border-radius: var(--radius-sm); }
.is-live .q-answer { display: none; }

.q-answer, .mem-answer { margin-top: var(--space-3); display: grid; gap: var(--space-3); font-size: var(--text-sm); color: var(--color-text-soft); }
.a-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2) var(--space-3); }
.a-line q { font-size: var(--text-md); font-weight: var(--weight-display); line-height: var(--leading-normal); letter-spacing: var(--tracking-tight); color: var(--color-text); }
.a-note { color: var(--color-text-muted); }
.a-src { font-size: var(--text-xs); color: var(--color-text-faint); }

.mem-view a[data-link], .a-src a { color: var(--color-accent); text-decoration: underline; text-underline-offset: 3px; }
.mem-view a[data-link]:hover { color: var(--color-text); }

.mem-back {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  cursor: pointer;
}

.mem-back::before { content: ""; width: 14px; height: 14px; background: currentColor; mask: var(--arrow-mask) center / contain no-repeat; transform: scaleX(-1); }
.mem-back:hover { color: var(--color-text); }
.mem-back:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; border-radius: var(--radius-sm); }
.mem-asked { font-size: var(--text-md); line-height: var(--leading-normal); font-weight: var(--weight-regular); margin-bottom: var(--space-4); }

.a-signed[hidden] { display: none; }

/* the plain list of documents: the fallback, and the source of the panel */
.doc-list { list-style: none; margin-top: var(--space-12); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--space-12); }
.is-live .doc-list { display: none; }
.doc { display: grid; gap: var(--space-2); align-content: start; padding: var(--space-6) 0; border-top: var(--border-hair) dotted var(--color-border-strong); font-size: var(--text-sm); color: var(--color-text-soft); }
.doc h3 { font-size: var(--text-lg); font-weight: var(--weight-regular); letter-spacing: var(--tracking-tight); color: var(--color-text); }
.doc-kind { font-size: var(--text-xs); color: var(--color-text-faint); }
.doc-took { color: var(--color-text); }
.doc-passage { padding: var(--space-3) var(--space-4); border-radius: var(--radius-sm); background: var(--color-surface); font-size: var(--text-sm); color: var(--color-text-soft); }
.doc-passage-flag { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2) var(--space-3); background: var(--color-flag-ground); }
.doc-passage mark, .a-line mark { color: var(--color-text); background: var(--field-c); padding: 0 2px; }
.doc-src { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }
.doc-links { list-style: none; display: grid; gap: var(--space-1); font-size: var(--text-sm); }
.doc-links a { color: var(--color-accent); text-decoration: underline; text-underline-offset: 3px; }

/* what happens to a document */
/* the five steps, drawn as a line with a dot on each */
.flow-tabs { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin-bottom: var(--space-10); }
.flow-tabs::before { content: ""; position: absolute; left: 10%; right: 10%; top: 21px; border-top: var(--border-hair) dotted var(--color-border-strong); }


.flow-tab {
  position: relative;
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-2) var(--space-4);
  font: inherit;
  font-size: var(--text-base);
  border: 0;
  background: transparent;
  color: var(--color-text-faint);
  cursor: pointer;
  transition: color var(--duration-base) var(--ease-out);
}

.flow-tab::before {
  content: "";
  width: 14px;
  height: 14px;
  margin-top: var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--color-bg);
  box-shadow: inset 0 0 0 2px var(--color-border-strong);
  transition: background var(--duration-slow) var(--ease-out), box-shadow var(--duration-slow) var(--ease-out), scale var(--duration-slow) var(--ease-out);
}

.flow-tab.is-past::before { background: var(--color-text); box-shadow: inset 0 0 0 2px var(--color-text); }
.flow-tab[aria-selected="true"] { color: var(--color-text); }
.flow-tab[aria-selected="true"]::before { background: var(--color-accent); box-shadow: inset 0 0 0 2px var(--color-accent), 0 0 0 6px var(--color-accent-wash); scale: 1.25; }
.flow-tab:hover { color: var(--color-text); }
.flow-tab:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; border-radius: var(--radius-md); }

.flow-panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr); gap: var(--space-8) var(--space-16); align-items: center; padding: var(--space-10) 0; border-top: var(--border-hair) dotted var(--color-border-strong); }
.flow-panel[hidden] { display: none; }
.is-flow .flow-panel { border-top: 0; }
.flow-copy { display: grid; gap: var(--space-4); max-width: 52ch; }
.flow-copy h3 { font-size: var(--text-xl); font-weight: var(--weight-display); letter-spacing: var(--tracking-display); }
.flow-copy p { color: var(--color-text-soft); }
.flow-panel { position: relative; isolation: isolate; }
.flow-panel::after { content: ""; position: absolute; z-index: -1; right: 0; top: 50%; width: 46%; aspect-ratio: 1; translate: 0 -50%; background: radial-gradient(closest-side, var(--field-b) 0%, transparent 100%); opacity: 0.7; }
.is-flow .flow-panel:not([hidden]) { animation: flow-in var(--duration-slow) var(--ease-out); }
@keyframes flow-in { from { opacity: 0; translate: 0 12px; } }
.flow-ui { max-width: 420px; width: 100%; justify-self: end; transform: rotate(1.7deg); box-shadow: var(--shadow-card); }
.is-flow .flow-copy h3 { display: none; }
.flow-ui { font-size: var(--text-sm); padding: var(--space-6); gap: var(--space-3); }
.flow-copy p { font-size: var(--text-xl); line-height: var(--leading-normal); color: var(--color-text); }

@media (max-width: 1023px) {
  .mem-body { grid-template-columns: 1fr; }
  .flow-panel { grid-template-columns: 1fr; }
  .flow-ui { justify-self: start; transform: none; }
}

@media (max-width: 767px) {
  .doc-list { grid-template-columns: 1fr; }
  .mem-search, .mem-search input { width: 100%; }
  .mem-canvas { aspect-ratio: auto; padding: var(--space-4); }
  .mem-edges, .mem-zones { display: none; }
  .mem-nodes { position: relative; inset: auto; display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); }
  .mem-node { position: static; translate: none; width: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .flow-ui { transform: none; }
}

/* The hero drawing: documents joined by lines, one route lit to an answer. */
.const { position: relative; margin: 0; }
.const svg { display: block; width: 100%; height: auto; max-height: 640px; overflow: visible; }
.const-line { fill: none; stroke: var(--color-border-strong); stroke-width: 1.5; stroke-dasharray: 2 5; }
.const-route { fill: none; stroke: var(--color-accent); stroke-width: 2; stroke-dasharray: 7 7; animation: edge-flow 1.1s linear infinite; }
.const-card rect { fill: rgb(255 255 255 / 0.86); stroke: var(--color-border-strong); stroke-width: 1; filter: drop-shadow(0 18px 28px rgb(60 40 40 / 0.1)); }
.const-card use { fill: none; stroke: var(--color-text-soft); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; color: var(--color-text-soft); }
.const-card text { font-family: var(--font-body); font-size: 14px; font-weight: var(--weight-medium); fill: var(--color-text); }
.const-card .const-sub { font-size: 12px; font-weight: var(--weight-regular); fill: var(--color-text-faint); }
.const-flag rect { fill: var(--color-flag-ground); stroke: var(--color-flag-wash); }
.const-flag .const-sub { fill: var(--color-flag); font-weight: var(--weight-medium); }
.const-answer rect:first-child { fill: rgb(255 255 255 / 0.96); stroke: var(--color-accent-line); stroke-width: 1.5; }
.const-answer .const-ok { fill: var(--color-ok-wash); stroke: none; filter: none; }
.const-answer .const-oktext { font-size: 12px; font-weight: var(--weight-semibold); fill: var(--color-ok); text-anchor: middle; }
.const-answer .const-big { font-size: 24px; font-weight: var(--weight-display); letter-spacing: -0.02em; }
.const-answer .const-src { fill: var(--field-c); stroke: none; filter: none; transform-box: fill-box; transform-origin: left; animation: mark-grow 1.6s var(--ease-out) 0.8s both; }
@keyframes mark-grow { from { transform: scaleX(0); } }
.const-card { animation: card-in 900ms var(--ease-out) both; }
.const-card:nth-of-type(2) { animation-delay: 80ms; }
.const-card:nth-of-type(3) { animation-delay: 160ms; }
.const-card:nth-of-type(4) { animation-delay: 240ms; }
.const-card:nth-of-type(5) { animation-delay: 320ms; }
.const-card:nth-of-type(6) { animation-delay: 400ms; }
@keyframes card-in { from { opacity: 0; translate: 0 14px; } }
.const-caption { position: absolute; right: 0; bottom: -2px; margin: 0; }

@media (max-width: 1023px) {
  .const { max-width: 480px; }
}

@media (max-width: 767px) {
  .flow-tab { font-size: var(--text-sm); }
}

@media (prefers-reduced-motion: reduce) {
  .const-route, .mem-edge.is-hot { animation: none; }
  .const-card, .const-answer .const-src, .is-flow .flow-panel:not([hidden]) { animation: none; }
}

/* ===========================================================================
   Product window: the explorer inside a frame, with a role picker and the
   five steps lit as a question is answered.
   ========================================================================= */

.pw {
  border-radius: var(--radius-xl);
  background: var(--color-surface-strong);
  box-shadow: inset 0 0 0 1px var(--color-border-strong), var(--shadow-card);
  overflow: hidden;
}

.pw-chrome {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-3) var(--space-5);
  border-bottom: var(--border-hair) solid var(--color-border-strong);
}

.pw-dots { display: inline-flex; gap: var(--space-2); }
.pw-dots i { width: 10px; height: 10px; border-radius: var(--radius-pill); background: var(--color-border-strong); }

.pw-url {
  flex: 1;
  max-width: 360px;
  margin-inline: auto;
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--color-raised);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  text-align: center;
}

.pw-head[hidden] { display: none; }

.pw-head {
  display: grid;
  gap: var(--space-3);
  padding: var(--space-5) var(--space-6) 0;
}

.mem-roles { display: flex; flex-wrap: wrap; gap: var(--space-2); }

.mem-role {
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  min-height: 40px;
  padding: 0 var(--space-5);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--color-raised);
  color: var(--color-text-muted);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  cursor: pointer;
  transition: background var(--duration-base) var(--ease-out), color var(--duration-base) var(--ease-out);
}

.mem-role:hover { color: var(--color-text); }
.mem-role:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.mem-role[aria-pressed="true"] { background: var(--color-btn-bg); color: var(--color-btn-text); box-shadow: none; }

.pw-steps { list-style: none; display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); }

.pw-steps li {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  transition: color var(--duration-base) var(--ease-out);
}

.pw-steps li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: var(--radius-pill);
  box-shadow: inset 0 0 0 1px var(--color-border-strong);
  background: transparent;
  transition: background var(--duration-base) var(--ease-out), box-shadow var(--duration-base) var(--ease-out);
}

.pw-steps li.is-done { color: var(--color-text-soft); }
.pw-steps li.is-done::before { background: var(--color-accent); box-shadow: none; }
.pw-steps li.is-now { color: var(--color-accent); }

.pw-status { min-height: 1.5em; font-size: var(--text-xs); color: var(--color-text-muted); }

.pw-body { padding: var(--space-5) var(--space-6) var(--space-6); }
.pw-body .mem-panel { box-shadow: inset 0 0 0 1px var(--color-border-strong); }

@media (max-width: 767px) {
  .pw-head { padding: var(--space-4) var(--space-4) 0; }
  .pw-body { padding: var(--space-4); }
  .pw-url { display: none; }
}

/* the pinned booking pill */
.demo-pill {
  position: fixed;
  inset-inline: 0;
  bottom: var(--space-6);
  width: max-content;
  margin-inline: auto;
  z-index: 50;
  box-shadow: var(--shadow-card);
  opacity: 0;
  translate: 0 var(--space-4);
  pointer-events: none;
  transition: opacity var(--duration-slow) var(--ease-out), translate var(--duration-slow) var(--ease-out);
}

.demo-pill[hidden] { display: none; }
.demo-pill.is-shown { opacity: 1; translate: 0 0; pointer-events: auto; }
