/*
 * alwyse.ai — site stylesheet.
 *
 * Hand-authored on the alwyse design system ("The Quiet Extension").
 * Tokens mirror the product's canonical token source
 * (alwyse repo: src/web/src/app/tokens.css); when the product palette
 * changes, re-sync the primitive/semantic values here.
 *
 * Rules honoured from DESIGN.md:
 *  - One family (Fira Sans), hierarchy by weight/size/space.
 *  - Near-pure cool surface; warmth lives in the brand hue and type.
 *  - One Voice Rule: the accent on <=10% of any screen.
 *  - Flat by default; hairlines and tone, shadows only on state.
 *  - Unhurried prose: 65-75ch measure, generous leading.
 *  - Motion is state and feedback only; reduced-motion honoured.
 */

/* ===================== Fonts — Fira Sans (SIL OFL), self-hosted ===================== */

@font-face {
  font-family: "Fira Sans";
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url("fonts/fira-sans-300.woff2") format("woff2");
}

@font-face {
  font-family: "Fira Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/fira-sans-400.woff2") format("woff2");
}

@font-face {
  font-family: "Fira Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/fira-sans-500.woff2") format("woff2");
}

@font-face {
  font-family: "Fira Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/fira-sans-700.woff2") format("woff2");
}

/* ===================== Tokens ===================== */

:root {
  color-scheme: light;

  /* Primitive cool-slate ramp (hue ~212, low chroma). */
  --slate-50: #f6f8fb;
  --slate-100: #eef2f7;
  --slate-150: #e6ecf4;
  --slate-200: #d7dfea;
  --slate-300: #c3cedd;
  --slate-400: #9aa8be;
  --slate-500: #5e80ac;
  --slate-600: #4a6e96;
  --slate-700: #2e4a63;
  --slate-800: #223443;
  --slate-900: #18242f;
  --slate-950: #0e1318;

  --ink-strong: #1b2a38;
  --pure-white: #ffffff;

  /* The logo's warm note — brand-mark use only. */
  --amber: #e6a95c;

  /* Semantic — light. */
  --surface: var(--slate-50);
  --surface-raised: var(--pure-white);
  --surface-sunken: var(--slate-100);

  --ink: var(--ink-strong);
  --ink-soft: #3f4f66;
  --ink-muted: #58677b;
  --ink-on-brand: var(--pure-white);

  --brand: var(--slate-700);
  --brand-hover: var(--slate-800);
  --brand-active: var(--slate-900);
  --brand-tint: var(--slate-150);

  --link: var(--slate-700);

  --border: var(--slate-200);
  --border-strong: var(--slate-300);
  --divider: var(--slate-150);

  --focus-ring: var(--slate-700);

  --danger: #8a2f33;
  --danger-bg: #fbeaec;
  --positive: #2f6a4e;
  --positive-bg: #e7f1ec;

  /* Trust-status hues (paired with text — the Color-Plus Rule). */
  --status-building: #7a5b23;
  --status-building-bg: #f7efdd;

  /* Immersive — the full-bleed dark voice surface; theme-independent. */
  --immersive-1: #2a3a4d;
  --immersive-2: #16202b;
  --on-immersive: #ffffff;
  --on-immersive-muted: rgb(255 255 255 / 0.55);

  /* Logo mark (theme-adaptive; flattened weave values from docs/brand/logo.md). */
  --logo-a: #425260;
  --logo-b: #4d647b;
  --logo-c: #6483a5;
  --logo-d: #7591b8;
  --logo-overlap: #0a1321;
  --logo-ground: var(--surface);
  --wordmark: #243b53;

  /* Glass chrome. */
  --glass-surface: rgb(246 248 251 / 0.72);
  --glass-blur: blur(22px) saturate(180%);
  --glass-edge: rgb(27 42 56 / 0.06);

  /* Type. */
  --font-sans: "Fira Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --text-hero: 2.875rem;
  --text-title: 1.625rem;
  --text-headline: 1.1875rem;
  --text-body: 1.0625rem;
  --text-small: 0.9375rem;
  --text-meta: 0.8125rem;
  --leading-tight: 1.15;
  --leading-snug: 1.35;
  --leading-prose: 1.65;
  --measure: 68ch;

  /* Space, radius, shadow, motion. */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;

  --page-pad: 1.5rem;
  --content-width: 66rem;

  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgb(27 42 56 / 0.06), 0 2px 8px rgb(27 42 56 / 0.05);
  --shadow-md: 0 4px 12px rgb(27 42 56 / 0.1), 0 8px 28px rgb(27 42 56 / 0.08);

  --motion-fast: 150ms;
  --motion: 200ms;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;

    --surface: var(--slate-950);
    --surface-raised: #161d25;
    --surface-sunken: #1b242e;

    --ink: #e7ecf2;
    --ink-soft: #b0bbc9;
    --ink-muted: #8492a3;
    --ink-on-brand: var(--pure-white);

    --brand: var(--slate-600);
    --brand-hover: #557eae;
    --brand-active: var(--slate-500);
    --brand-tint: #1b2a3a;

    --link: #7ca0ce;

    --border: #28323f;
    --border-strong: #36434f;
    --divider: #202934;

    --focus-ring: #7ca0ce;

    --danger: #ef9a9d;
    --danger-bg: #2a1719;
    --positive: #8fccab;
    --positive-bg: #15241d;

    --status-building: #d9b56a;
    --status-building-bg: #2a2314;

    /* Reversed mark — the deepened dark weave (logo.md, colour — dark). */
    --logo-a: #4a6e96;
    --logo-b: #5e80ac;
    --logo-c: #7393bb;
    --logo-d: #8aa3c6;
    --logo-overlap: #2e4a63;
    --logo-ground: var(--surface);
    --wordmark: #c9d6e6;

    --glass-surface: rgb(11 15 20 / 0.68);
    --glass-edge: rgb(0 0 0 / 0.4);

    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.3), 0 2px 8px rgb(0 0 0 / 0.25);
    --shadow-md: 0 4px 12px rgb(0 0 0 / 0.35), 0 8px 28px rgb(0 0 0 / 0.3);
  }
}

/* ===================== Base ===================== */

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--text-body);
  font-weight: 400;
  line-height: var(--leading-prose);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd {
  margin: 0;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
  border-radius: 2px;
}

::selection {
  background: var(--brand-tint);
}

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

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -3rem;
  z-index: 100;
  background: var(--surface-raised);
  color: var(--ink);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  transition: top var(--motion-fast) var(--ease);
}

.skip-link:focus {
  top: var(--space-4);
}

/* ===================== Layout ===================== */

.shell {
  max-width: var(--content-width);
  margin: 0 auto;
  padding-left: var(--page-pad);
  padding-right: var(--page-pad);
}

.section {
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

.section + .section {
  border-top: 1px solid var(--divider);
}

.section--sunken {
  background: var(--surface-sunken);
}

@media (min-width: 51.25rem) {
  .section {
    padding-top: var(--space-9);
    padding-bottom: var(--space-9);
  }
}

/* ===================== Header ===================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--glass-surface);
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--glass-edge);
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

.site-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  min-height: 3.75rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--wordmark);
}

.brand:hover {
  text-decoration: none;
}

.brand .logo-mark {
  width: 2rem;
  height: 2rem;
  flex: none;
}

.brand__word {
  font-size: 1.375rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--wordmark);
  line-height: 1;
  /* Optical: x-height of the wordmark ~ the mark's inner `a` (logo.md lockup). */
  padding-bottom: 0.1em;
}

.logo-mark .lp-a { fill: var(--logo-a); }
.logo-mark .lp-b { fill: var(--logo-b); }
.logo-mark .lp-c { fill: var(--logo-c); }
.logo-mark .lp-d { fill: var(--logo-d); }
.logo-mark .lp-o { fill: var(--logo-overlap); }
.logo-mark .lp-g { fill: var(--logo-ground); }
.logo-mark .lp-t { fill: var(--amber); }

/* On the immersive panel the knockout reads as the panel, not the page. */
.hero-moments .logo-mark .lp-g { fill: var(--immersive-2); }

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-5);
}

.site-nav__links {
  display: none;
  align-items: center;
  gap: var(--space-5);
}

.site-nav__link {
  color: var(--ink-soft);
  font-size: var(--text-small);
  font-weight: 500;
}

.site-nav__link:hover {
  color: var(--ink);
  text-decoration: none;
}

.site-nav__link[aria-current="page"] {
  color: var(--ink);
}

.menu-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--ink-soft);
  font: inherit;
  font-size: var(--text-small);
  font-weight: 500;
  cursor: pointer;
}

.menu-panel {
  display: none;
  flex-direction: column;
  padding: var(--space-2) var(--page-pad) var(--space-4);
  border-top: 1px solid var(--divider);
}

.menu-panel.is-open {
  display: flex;
}

.menu-panel a:not(.button) {
  padding: var(--space-3) var(--space-2);
  color: var(--ink-soft);
  font-weight: 500;
  border-radius: var(--radius-sm);
}

.menu-panel a:not(.button):hover {
  background: var(--surface-sunken);
  text-decoration: none;
}

.menu-panel .button {
  margin-top: var(--space-3);
  justify-content: center;
}

@media (min-width: 51.25rem) {
  .site-nav__links {
    display: flex;
  }

  .menu-button,
  .menu-panel {
    display: none;
  }

  .menu-panel.is-open {
    display: none;
  }
}

/* ===================== Buttons ===================== */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0.55rem 1.35rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font: inherit;
  font-size: var(--text-body);
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease);
}

.button:hover {
  text-decoration: none;
}

.button--primary {
  background: var(--brand);
  color: var(--ink-on-brand);
}

.button--primary:hover {
  background: var(--brand-hover);
}

.button--primary:active {
  background: var(--brand-active);
}

.button--secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--border-strong);
}

.button--secondary:hover {
  border-color: var(--ink-muted);
}

.button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

/* ===================== Type ===================== */

.hero-title {
  font-size: 2.25rem;
  font-weight: 300;
  line-height: var(--leading-tight);
  letter-spacing: -0.01em;
  max-width: 22ch;
  text-wrap: balance;
}

.page-title {
  font-size: 2rem;
  font-weight: 300;
  line-height: var(--leading-tight);
  letter-spacing: -0.01em;
  max-width: 24ch;
  text-wrap: balance;
}

@media (min-width: 40rem) {
  .hero-title {
    font-size: var(--text-hero);
  }

  .page-title {
    font-size: 2.25rem;
  }
}

.section-title {
  font-size: var(--text-title);
  font-weight: 500;
  line-height: var(--leading-snug);
  max-width: 30ch;
  text-wrap: balance;
}

.item-title {
  font-size: var(--text-headline);
  font-weight: 500;
  line-height: var(--leading-snug);
}

.lead {
  font-size: 1.25rem;
  font-weight: 300;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 56ch;
}

.prose {
  max-width: var(--measure);
}

.prose p,
.prose ul,
.prose ol {
  margin: 0 0 var(--space-4);
}

.prose > :last-child {
  margin-bottom: 0;
}

.prose ul,
.prose ol {
  padding-left: 1.4rem;
}

.prose li {
  margin-bottom: var(--space-2);
}

.prose h2 {
  font-size: var(--text-title);
  font-weight: 500;
  line-height: var(--leading-snug);
  margin: var(--space-7) 0 var(--space-4);
}

.prose h3 {
  font-size: var(--text-headline);
  font-weight: 500;
  margin: var(--space-6) 0 var(--space-3);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose blockquote {
  margin: 0 0 var(--space-4);
  padding-left: var(--space-4);
  border-left: 2px solid var(--border-strong);
  color: var(--ink-soft);
  font-style: italic;
}

.muted {
  color: var(--ink-muted);
}

.soft {
  color: var(--ink-soft);
}

.small {
  font-size: var(--text-small);
}

.meta {
  font-size: var(--text-meta);
  color: var(--ink-muted);
}

/* Section header block: title + optional lead, spaced before content. */
.section-head {
  margin-bottom: var(--space-6);
}

.section-head .lead {
  margin-top: var(--space-3);
  font-size: var(--text-body);
  font-weight: 400;
}

/* ===================== Hero ===================== */

.hero {
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

.hero__grid {
  display: grid;
  gap: var(--space-7);
  align-items: center;
}

.hero__kicker {
  font-size: var(--text-headline);
  font-weight: 500;
  color: var(--ink-soft);
  margin-bottom: var(--space-3);
}

.hero .lead {
  margin-top: var(--space-5);
}

@media (min-width: 51.25rem) {
  .hero {
    padding-top: var(--space-9);
    padding-bottom: var(--space-9);
  }

  .hero__grid {
    grid-template-columns: 1.05fr 0.95fr;
  }
}

/* The moments panel — the immersive voice surface, borrowed for the one
 * quiet piece of motion on the site: remembered lines surfacing and fading. */
.hero-moments {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-6);
  min-height: 20rem;
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, var(--immersive-1), var(--immersive-2) 62%);
  /* A whisper of an edge so the panel keeps its shape on the dark ground. */
  border: 1px solid rgb(255 255 255 / 0.07);
  overflow: hidden;
}

.hero-moments canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-moments__line {
  position: relative;
  font-size: 1.4rem;
  font-weight: 300;
  line-height: 1.45;
  color: var(--on-immersive);
  max-width: 24ch;
  margin: auto 0;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 1.4s var(--ease), transform 1.4s var(--ease);
}

.hero-moments__line.is-hidden {
  opacity: 0;
  transform: translateY(8px);
}

.hero-moments__caption {
  position: relative;
  font-size: var(--text-meta);
  color: var(--on-immersive-muted);
}

@media (min-width: 51.25rem) {
  .hero-moments {
    min-height: 24rem;
    padding: var(--space-7);
  }
}

/* ===================== Content patterns ===================== */

/* A quiet grid of titled items — hairline structure, no boxes. */
.item-grid {
  display: grid;
  gap: var(--space-6) var(--space-7);
}

.item-grid--2 {
  grid-template-columns: 1fr;
}

.item-grid--3 {
  grid-template-columns: 1fr;
}

@media (min-width: 40rem) {
  .item-grid--2,
  .item-grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 64rem) {
  .item-grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.item {
  border-top: 1px solid var(--border);
  padding-top: var(--space-4);
}

.item p {
  margin: var(--space-2) 0 0;
  color: var(--ink-soft);
}

/* A raised card — for the few genuinely contained things (forms, asides). */
.card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

/* Two-column prose split. */
.split {
  display: grid;
  gap: var(--space-7);
  align-items: start;
}

@media (min-width: 51.25rem) {
  .split {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

/* The creed band — the one full-bleed dark moment on the site. Borrows the
 * immersive voice surface so the outside quote lands as its own breath
 * rather than as a footnote to the section above it. */
.creed {
  background: var(--immersive-2);
  color: var(--on-immersive);
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

/* .section + .section draws a hairline; in light the band's own darkness is
 * the edge. In dark the band sits within a few points of the sunken surface
 * above it, so it needs real rules to stay a band and not a colour shift. */
.section + .creed {
  border-top: 0;
}

@media (prefers-color-scheme: dark) {
  .creed,
  .section + .creed {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
  }
}

.creed blockquote {
  margin: 0;
}

.creed blockquote p {
  margin: 0;
  font-weight: 300;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: var(--on-immersive);
}

/* Verse, not prose: the poem's line breaks are the author's, so each line runs
 * the full content measure and a wrapped line hangs rather than posing as a
 * line that was written. No text-wrap: balance — it would fight the breaks. */
.creed__verse {
  font-size: clamp(1.0625rem, 0.98rem + 0.36vw, 1.25rem);
}

/* Each line is its own block so a line too long for the measure hangs under
 * itself instead of posing as the next line the poet wrote. */
.creed__line {
  display: block;
  padding-left: 1.4em;
  text-indent: -1.4em;
  text-wrap: pretty;
}

/* The line the whole passage turns on. It gets the size and the silence. */
.creed blockquote .creed__turn {
  margin-top: var(--space-5);
  font-size: clamp(1.375rem, 1.15rem + 0.95vw, 1.875rem);
  font-weight: 400;
  text-wrap: balance;
}

/* Not the poem — the card the film closes on. The rule and the italic keep it
 * from reading either as a last verse line or as alwyse's own voice. */
.creed__card {
  margin: var(--space-6) 0 0;
  padding-top: var(--space-6);
  border-top: 1px solid rgb(255 255 255 / 0.14);
  font-size: clamp(1.125rem, 1.05rem + 0.3vw, 1.25rem);
  font-weight: 300;
  font-style: italic;
  line-height: var(--leading-snug);
  color: var(--on-immersive);
  text-wrap: pretty;
}

.creed figcaption {
  margin-top: var(--space-5);
  font-size: var(--text-small);
  color: var(--on-immersive-muted);
}

.creed figcaption a {
  color: var(--on-immersive);
  text-decoration-color: var(--on-immersive-muted);
}

.creed figcaption a:hover {
  text-decoration-color: var(--on-immersive);
}

.creed figcaption a:focus-visible {
  outline-color: var(--on-immersive);
}

/* The principles, grouped by the question each one answers. The grouping is
 * the argument — four questions, not a numbered inventory of fifteen. */
.principle-group + .principle-group {
  margin-top: var(--space-8);
  padding-top: var(--space-8);
  border-top: 1px solid var(--divider);
}

.principle-group__ask {
  margin-bottom: var(--space-6);
}

.principle-group__ask h2 {
  font-size: var(--text-title);
  font-weight: 500;
  line-height: var(--leading-snug);
  margin: 0;
}

.principle-group__ask p {
  margin: var(--space-2) 0 0;
  color: var(--ink-muted);
  max-width: 34ch;
}

.principle-group ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-5);
}

.principle-group li {
  max-width: var(--measure);
}

.principle-group h3 {
  font-size: var(--text-headline);
  font-weight: 500;
  line-height: var(--leading-snug);
  margin: 0 0 var(--space-1);
}

.principle-group p {
  margin: 0;
  color: var(--ink-soft);
}

/* Wide: the question holds the left column while its answers run beside it. */
@media (min-width: 51.25rem) {
  .principle-group {
    display: grid;
    grid-template-columns: minmax(0, 19rem) minmax(0, 1fr);
    gap: var(--space-7);
    align-items: start;
  }

  .principle-group__ask {
    position: sticky;
    top: var(--space-8);
    margin-bottom: 0;
  }

  .principle-group ol {
    gap: var(--space-6);
  }
}

@media (prefers-reduced-motion: reduce) {
  .principle-group__ask {
    position: static;
  }
}

/* Homepage: the fifteen named, nothing more. The gloss lives on /principles. */
.commitments {
  list-style: none;
  margin: 0;
  padding: 0;
  columns: 1;
  column-gap: var(--space-7);
}

.commitments li {
  break-inside: avoid;
  padding: var(--space-3) 0;
  border-top: 1px solid var(--divider);
  color: var(--ink-soft);
  font-size: var(--text-small);
}

@media (min-width: 40rem) {
  .commitments {
    columns: 2;
  }
}

@media (min-width: 64rem) {
  .commitments {
    columns: 3;
  }
}

/* Narrated-connection example. */
.narrated dt {
  font-size: var(--text-meta);
  color: var(--ink-muted);
  margin-bottom: var(--space-2);
}

.narrated dd {
  margin: 0 0 var(--space-5);
}

.narrated dd:last-child {
  margin-bottom: 0;
}

.narrated .as-graph {
  font-size: var(--text-small);
  color: var(--ink-muted);
  text-decoration: line-through;
}

.narrated .as-words {
  font-size: var(--text-body);
  color: var(--ink);
}

/* CTA band. */
.cta-band {
  text-align: center;
}

.cta-band .section-title,
.cta-band .lead,
.cta-band .small {
  margin-left: auto;
  margin-right: auto;
}

.cta-band .small {
  max-width: 56ch;
}

.cta-band .button-row {
  justify-content: center;
}

/* ===================== Trust matrix ===================== */

.status {
  display: inline-block;
  padding: 0.1rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--text-meta);
  font-weight: 500;
  white-space: nowrap;
}

.status--shipped {
  color: var(--positive);
  background: var(--positive-bg);
}

.status--building,
.status--designed {
  color: var(--status-building);
  background: var(--status-building-bg);
}

/* "Never" and "No target" are muted, not alarming: on this page a closed door
 * stated plainly is a feature. The word carries the meaning, not the colour. */
.status--planned,
.status--none,
.status--never,
.status--no-target {
  color: var(--ink-muted);
  background: var(--surface-sunken);
}

.trust-matrix-wrap {
  overflow-x: auto;
  margin-top: var(--space-6);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
}

.trust-matrix-wrap + .trust-matrix-wrap {
  margin-top: var(--space-6);
}

.trust-matrix {
  width: 100%;
  min-width: 48rem;
  border-collapse: collapse;
  font-size: var(--text-small);
}

.trust-matrix th,
.trust-matrix td {
  text-align: left;
  vertical-align: top;
  padding: var(--space-4) var(--space-5);
  border-top: 1px solid var(--divider);
}

.trust-matrix thead th {
  border-top: none;
  font-weight: 500;
}

.trust-matrix tbody th {
  font-weight: 400;
  color: var(--ink);
  max-width: 22rem;
}

.tier-note {
  display: block;
  font-size: var(--text-meta);
  font-weight: 400;
  color: var(--ink-muted);
}

.cell-note {
  display: block;
  margin-top: var(--space-1);
  font-size: var(--text-meta);
  color: var(--ink-muted);
}

.trust-claim {
  padding: var(--space-6) 0;
  border-top: 1px solid var(--divider);
}

.trust-claim:first-of-type {
  border-top: none;
  padding-top: 0;
}

.claim-tiers {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-5);
  padding: 0;
  margin: var(--space-3) 0 var(--space-4);
}

.claim-tiers li {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-small);
  color: var(--ink-soft);
}

.trust-legend {
  list-style: none;
  padding: 0;
  margin: var(--space-4) 0 0;
}

.trust-legend li {
  display: flex;
  align-items: baseline;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
  color: var(--ink-soft);
}

/* ===================== Forms ===================== */

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

.field__label {
  display: block;
  font-size: var(--text-small);
  font-weight: 500;
  color: var(--ink-soft);
  margin-bottom: var(--space-2);
}

.field__hint {
  font-weight: 400;
  color: var(--ink-muted);
}

.input {
  width: 100%;
  min-height: 44px;
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface-raised);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
}

.input:focus {
  outline: 2px solid var(--focus-ring);
  outline-offset: 0;
  border-color: var(--focus-ring);
}

.form-note {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-sunken);
  color: var(--ink-soft);
  font-size: var(--text-small);
  padding: var(--space-3) var(--space-4);
  margin-bottom: var(--space-5);
}

.form-status {
  display: none;
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-small);
  font-weight: 500;
  margin-bottom: var(--space-3);
}

.form-status.is-visible {
  display: block;
}

.form-status--error {
  color: var(--danger);
  background: var(--danger-bg);
}

.form-status--info {
  color: var(--ink-soft);
  background: var(--surface-sunken);
}

.field-error {
  display: none;
  color: var(--danger);
  font-size: var(--text-meta);
  margin-top: var(--space-1);
}

.field-error.is-visible {
  display: block;
}

/* Honeypot: visually hidden but not display:none so bots fill it. */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ===================== Footer ===================== */

.site-footer {
  border-top: 1px solid var(--divider);
  padding: var(--space-7) 0 var(--space-8);
  margin-top: var(--space-8);
}

.site-footer__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-6);
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-5);
}

.site-footer nav a {
  color: var(--ink-muted);
  font-size: var(--text-small);
}

.site-footer nav a:hover {
  color: var(--ink);
}

.site-footer__legal {
  margin-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  font-size: var(--text-meta);
  color: var(--ink-muted);
}

.site-footer__legal a {
  color: var(--ink-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.by-cvoya {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.by-cvoya img {
  height: 1.1rem;
  width: auto;
  opacity: 0.75;
}

@media (prefers-color-scheme: dark) {
  .by-cvoya img {
    background: #f4f4f4;
    padding: 2px 4px;
    border-radius: 3px;
  }
}

.ext-icon {
  width: 0.65em;
  height: 0.65em;
  margin-left: 0.15em;
  vertical-align: baseline;
}

/* ===================== Accessibility media prefs ===================== */

@media (prefers-reduced-transparency: reduce) {
  :root {
    --glass-surface: var(--surface);
    --glass-blur: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --motion-fast: 0.01ms;
    --motion: 0.01ms;
  }

  .hero-moments__line {
    transition: none;
  }
}
