/* Force Multiplier AI — site stylesheet
   Source of truth: redesign_inputs/FxM Website — Visual Style Guide.md
   Mobile is the base layout. Wider layouts live under min-width queries only. */

/* ── Tokens ─────────────────────────────────────────────────────────── */
:root {
  color-scheme: light;
  /* color — light */
  --paper: #FAF9F6;  --paper-2: #FFFFFF;
  --ink: #171512;    --ink-2: #5C5852;
  --rule: #E4E0D7;   --edge: #857F75;
  --gold: #F7B500;   --gold-hover: #E5A800;  --gold-active: #D49C00;  --gold-ink: #171512;
  --band: #171512;   --band-ink: #F1EEE8;    --band-ink-2: #B5B0A6;   --band-rule: #2B2926;
  --band-edge: transparent;
  --backdrop: rgba(23, 21, 18, 0.4);

  /* type */
  --sans: 'IBM Plex Sans', 'Plex Sans Fallback', 'Helvetica Neue', Arial, sans-serif;
  --mono: 'IBM Plex Mono', 'SF Mono', Menlo, Consolas, monospace;
  --fs-h1: clamp(44px, 6.5vw, 72px);
  --fs-h2: clamp(28px, 4vw, 40px);
  --fs-h3: 20px;  --fs-sub: 18px;  --fs-body: 18px;  --fs-small: 16px;
  --fs-mono: 16px;  --fs-label: 14px;  --fs-button: 17px;

  /* space (4px base) */
  --s1: 4px;  --s2: 8px;  --s3: 12px;  --s4: 16px;  --s6: 24px;
  --s8: 32px; --s12: 48px; --s16: 64px; --s24: 96px; --s32: 128px;

  /* layout */
  --container: 1120px;  --gutter: 24px;  --radius: 2px;
  --measure: 62ch;  --measure-sub: 48ch;  --measure-rules: 34ch;
  --shadow-gate: 0 24px 48px rgba(23, 21, 18, 0.18);
  --t-fast: 150ms;  --t-open: 180ms;  --t-close: 120ms;  --t-swap: 200ms;
  --nav-h: 64px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #121110;  --paper-2: #1A1917;
    --ink: #ECE9E2;    --ink-2: #A9A49B;
    --rule: #2B2926;   --edge: #75716A;
    --band: #1A1917;   --band-ink: #ECE9E2;  --band-ink-2: #A9A49B;  --band-rule: #2B2926;
    --band-edge: #75716A;
    --backdrop: rgba(0, 0, 0, 0.55);
    --shadow-gate: 0 24px 48px rgba(0, 0, 0, 0.5);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #121110;  --paper-2: #1A1917;
  --ink: #ECE9E2;    --ink-2: #A9A49B;
  --rule: #2B2926;   --edge: #75716A;
  --band: #1A1917;   --band-ink: #ECE9E2;  --band-ink-2: #A9A49B;  --band-rule: #2B2926;
  --band-edge: #75716A;
  --backdrop: rgba(0, 0, 0, 0.55);
  --shadow-gate: 0 24px 48px rgba(0, 0, 0, 0.5);
}

/* Metric-matched fallback so the layout holds while Plex loads. */
@font-face {
  font-family: 'Plex Sans Fallback';
  src: local('Helvetica Neue'), local('Arial');
  size-adjust: 101%;
  ascent-override: 102%;
  descent-override: 27%;
  line-gap-override: 0%;
}

/* ── Base ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  scroll-padding-top: var(--nav-h);
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: 1.55;
  overflow-x: hidden;
}
h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
::selection { background: var(--gold); color: var(--gold-ink); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
@media (min-width: 768px)  { :root { --gutter: 40px; } }
@media (min-width: 1200px) { :root { --gutter: 48px; } }

/* ── Type roles ─────────────────────────────────────────────────────── */
.h1 {
  font-size: var(--fs-h1); font-weight: 500; line-height: 1.02;
  letter-spacing: -0.02em; max-width: 16ch; text-wrap: balance;
}
.h2 {
  font-size: var(--fs-h2); font-weight: 500; line-height: 1.15;
  letter-spacing: -0.015em; max-width: 24ch; text-wrap: balance;
}
.h3 { font-size: var(--fs-h3); font-weight: 600; line-height: 1.3; }
.sub { font-size: var(--fs-sub); line-height: 1.5; max-width: var(--measure-sub); }
@media (min-width: 768px) { .sub { font-size: 20px; } }
.body { font-size: var(--fs-body); line-height: 1.55; }
.small { font-size: var(--fs-small); line-height: 1.5; }
.muted { color: var(--ink-2); }
.measure { max-width: var(--measure); }
.eyebrow {
  font-family: var(--mono); font-size: var(--fs-label); font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase; line-height: 1;
  color: var(--ink-2); margin-bottom: var(--s4);
}
.prose-link { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--edge); }
.prose-link:hover { text-decoration-color: currentColor; }

/* ── Button (the only button style) ─────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; min-height: 48px; height: 52px; padding: 0 28px;
  background: var(--gold); color: var(--gold-ink);
  font-family: var(--sans); font-size: var(--fs-button); font-weight: 500; line-height: 1;
  border: 0; border-radius: var(--radius); cursor: pointer;
  text-align: center; white-space: nowrap;
  transition: background-color var(--t-fast) ease-out;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { background: var(--gold-hover); }
.btn:active { background: var(--gold-active); }
.btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
@media (min-width: 768px) { .btn { width: auto; } }

/* ── Nav ────────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: var(--paper-2);
  border-bottom: 1px solid var(--rule);
}
.nav .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s4); height: var(--nav-h);
}
.nav .btn { position: relative; width: auto; height: 44px; min-height: 44px; padding: 0 16px; }
.nav .btn::before { content: ''; position: absolute; inset: -2px; }
.brand { display: inline-flex; align-items: center; gap: var(--s3); color: var(--ink); min-height: 48px; }
.brand__mark { display: block; height: 22px; width: auto; }
.brand__mark .letters { fill: currentColor; }
.brand__mark .x { stroke: var(--gold); }
.brand__rule { display: none; width: 1px; height: 20px; background: var(--rule); }
.brand__name { display: none; font-size: 14px; letter-spacing: 0.06em; line-height: 1; white-space: nowrap; }
@media (min-width: 768px) {
  .brand__mark { height: 24px; }
  .brand__rule, .brand__name { display: block; }
}

/* ── Sections ───────────────────────────────────────────────────────── */
.section { padding-block: var(--s16); }
@media (min-width: 768px) { .section { padding-block: var(--s24); } }
.section > .container > .h2 { margin-bottom: var(--s8); }

/* ── Hero ───────────────────────────────────────────────────────────── */
.hero { padding-block: var(--s12) var(--s16); }
.hero__copy .h1 { margin-bottom: 20px; }
.hero__copy .sub { margin-bottom: 28px; }
.hero__note { margin-top: var(--s3); }
.hero__chips { margin-top: var(--s6); }
@media (min-width: 768px) {
  .hero { padding-block: var(--s24) var(--s16); }
}
@media (min-width: 1024px) {
  .hero__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--s6); align-items: start; }
  .hero__copy { grid-column: 1 / 8; }
}
/* Working now sits 48px under the hero. */
.hero + .section { padding-top: 0; }
.hero { padding-bottom: var(--s12); }

/* ── Proof chips ────────────────────────────────────────────────────── */
.chips { display: flex; flex-direction: column; gap: var(--s2); }
.chip {
  display: block; width: 100%;
  font-family: var(--mono); font-size: var(--fs-label); font-weight: 400;
  letter-spacing: 0.01em; line-height: 1; white-space: nowrap;
  color: var(--ink); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 12px 12px;
}
@media (min-width: 768px) {
  .chips { flex-direction: row; flex-wrap: wrap; }
  .chip { width: auto; }
}

/* ── Media (sizzle) ─────────────────────────────────────────────────── */
.media { position: relative; }
.media__frame {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden;
  border: 1px solid var(--rule); border-radius: var(--radius);
  background: #0a0a0a;
}
.media__frame video { display: block; width: 100%; height: 100%; object-fit: cover; }
.media__controls { position: absolute; right: var(--s2); bottom: var(--s2); display: flex; gap: var(--s2); }
.media__controls button {
  min-width: 44px; height: 44px; padding: 0 12px;
  font-family: var(--mono); font-size: var(--fs-label); line-height: 1;
  background: var(--paper-2); color: var(--ink);
  border: 1px solid var(--edge); border-radius: var(--radius); cursor: pointer;
}
.media__frame:fullscreen { border: 0; border-radius: 0; }
.media__frame:fullscreen video { object-fit: contain; }
.media__caption { margin-top: var(--s3); font-size: var(--fs-small); line-height: 1.5; color: var(--ink-2); max-width: var(--measure); }
.how-works .media { margin-top: var(--s8); }

/* ── Quotes ─────────────────────────────────────────────────────────── */
.quotes { display: grid; }
.quote { padding-block: var(--s8); border-top: 1px solid var(--rule); }
.quote:first-child { padding-top: 0; border-top: 0; }
.quote__text { font-size: var(--fs-body); line-height: 1.55; max-width: var(--measure); }
.quote__who {
  margin-top: var(--s4);
  font-family: var(--mono); font-size: var(--fs-label); line-height: 1.5;
  color: var(--ink-2);
}
.quote__who span { display: block; }
.quotes-note { margin-top: var(--s8); }
.quotes-note p + p { margin-top: 1em; }
@media (min-width: 768px) {
  .quotes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .quote { padding: 0 var(--s8); border-top: 0; border-left: 1px solid var(--rule); }
  .quote:first-child, .quote:nth-child(3n + 1) { padding-left: 0; border-left: 0; }
  .quote:nth-child(3n) { padding-right: 0; }
  .quote:nth-child(n + 4) { margin-top: var(--s12); }
}

/* ── Three-column block ─────────────────────────────────────────────── */
.cols-3 { display: grid; }
.col { padding-block: var(--s8); border-top: 1px solid var(--rule); }
.col:first-child { padding-top: 0; border-top: 0; }
.col .h3 { margin-bottom: var(--s4); }
.col li { margin-bottom: var(--s2); line-height: 1.55; }
.col li:last-child { margin-bottom: 0; }
@media (min-width: 1024px) {
  .cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .col { padding: 0 var(--s8); border-top: 0; border-left: 1px solid var(--rule); }
  .col:first-child { padding-left: 0; border-left: 0; }
  .col:last-child { padding-right: 0; }
}
.section-sub { margin-top: calc(-1 * var(--s4)); margin-bottom: var(--s8); }

/* The Difference: the FMA column is the obvious one. Gold top rule plus the x mark. */
.col--fma { border-top: 3px solid var(--gold); }
.x-mark { width: 0.8em; height: 0.8em; vertical-align: -0.06em; margin-right: 0.35em; }
.x-mark g { stroke: var(--gold); }
@media (min-width: 1024px) {
  .difference .col { border-top: 3px solid transparent; padding-top: var(--s4); }
  .difference .col--fma { border-top-color: var(--gold); }
}

/* ── The Rules band ─────────────────────────────────────────────────── */
.band {
  background: var(--band); color: var(--band-ink);
  border-block: 1px solid var(--band-edge);
}
.band .eyebrow { color: var(--band-ink-2); }
.band .rules-sub {
  font-family: var(--mono); font-size: var(--fs-label); line-height: 1.5;
  color: var(--band-ink-2);
}
.band .col { border-color: var(--band-rule); }
.band .col li { font-family: var(--mono); font-size: var(--fs-mono); line-height: 1.6; max-width: var(--measure-rules); }
.band .muted { color: var(--band-ink-2); }
.band__after { margin-top: var(--s12); }

/* ── Role chips ─────────────────────────────────────────────────────── */
.roles { display: flex; flex-wrap: wrap; gap: 10px; margin-top: var(--s8); }
.chip--role {
  display: inline-flex; align-items: center; width: auto;
  font-family: var(--sans); font-size: var(--fs-small); line-height: 1.2; letter-spacing: 0;
  white-space: normal; min-height: 48px; padding: 10px 14px;
}
button.chip--role {
  width: 100%; background: transparent; border-color: var(--edge); cursor: pointer;
  transition: border-color var(--t-fast) ease-out;
  -webkit-tap-highlight-color: transparent;
}
button.chip--role:hover, button.chip--role:active { border-color: var(--ink); }
@media (min-width: 768px) { button.chip--role { width: auto; } }

/* ── Steps ──────────────────────────────────────────────────────────── */
.steps { display: grid; gap: var(--s6); max-width: var(--measure); }
.step { display: grid; grid-template-columns: 40px minmax(0, 1fr); }
.step__n {
  font-family: var(--mono); font-size: var(--fs-label); font-weight: 500;
  letter-spacing: 0.06em; line-height: 1; color: var(--ink-2); padding-top: 7px;
}
.steps-note { margin-top: var(--s8); }
@media (min-width: 768px) { .step { grid-template-columns: 48px minmax(0, 1fr); } }

/* ── Final CTA ──────────────────────────────────────────────────────── */
.final { padding-top: var(--s24); }
.final .h2 { margin-bottom: var(--s8); }
.final .chips { margin-top: var(--s6); }
@media (min-width: 768px) { .final { padding-top: var(--s32); } }

/* ── Founder line ───────────────────────────────────────────────────── */
.founder { padding-bottom: var(--s12); }

/* ── Footer ─────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--rule); padding-block: var(--s12);
  font-size: var(--fs-small); line-height: 1.5; color: var(--ink-2);
}
.footer .container { display: flex; flex-direction: column; gap: var(--s6); }
.footer .brand__mark { height: 20px; }
.footer__links { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s6); }
.footer__links a, .footer__links button {
  display: inline-flex; align-items: center; min-height: 48px;
  background: none; border: 0; padding: 0; cursor: pointer; color: var(--ink-2);
  font-size: var(--fs-small); line-height: 1.5;
}
.footer__links a:hover, .footer__links button:hover { text-decoration: underline; text-underline-offset: 3px; }
@media (min-width: 768px) {
  .footer .container { flex-direction: row; align-items: center; justify-content: space-between; }
  .footer__links a, .footer__links button { min-height: 0; }
}

/* ── Sticky mobile bar ──────────────────────────────────────────────── */
.bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: var(--s1) var(--gutter) calc(var(--s1) + env(safe-area-inset-bottom, 0px));
  background: var(--paper-2); border-top: 1px solid var(--rule);
  opacity: 0; pointer-events: none; visibility: hidden;
  transition: opacity var(--t-fast) ease-out, visibility 0s linear var(--t-fast);
}
.bar .btn { height: 48px; }
html.bar-on .bar { opacity: 1; pointer-events: auto; visibility: visible; transition-delay: 0s; }
html.bar-on .nav .btn { visibility: hidden; }
html.bar-on body { padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px)); }
@media (min-width: 768px) {
  .bar { display: none; }
  html.bar-on .nav .btn { visibility: visible; }
  html.bar-on body { padding-bottom: 0; }
}

/* ── Gate ───────────────────────────────────────────────────────────── */
.gate {
  position: fixed; inset: 0; width: 100%; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0; border-radius: 0;
  background: var(--paper-2); color: var(--ink);
  overflow: auto; overscroll-behavior: contain;
}
.gate::backdrop { background: var(--backdrop); }
.gate__panel {
  position: relative;
  padding: calc(var(--s16) + env(safe-area-inset-top, 0px)) var(--s6) calc(var(--s8) + env(safe-area-inset-bottom, 0px));
  min-height: 100%;
}
.gate__close {
  position: absolute; top: var(--s2); right: var(--s2);
  width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center;
  background: none; border: 0; border-radius: var(--radius); cursor: pointer;
  font-size: 28px; line-height: 1; color: var(--ink);
}
.gate .h3 { margin-bottom: var(--s3); }
.gate__body { margin-bottom: var(--s6); }
.field + .field { margin-top: var(--s4); }
.field label { display: block; font-size: var(--fs-small); line-height: 1.5; margin-bottom: var(--s2); }
.field label .opt { color: var(--ink-2); }
.field input {
  display: block; width: 100%; height: 52px; padding: 0 16px;
  font-family: var(--sans); font-size: 16px; color: var(--ink);
  background: var(--paper-2); border: 1px solid var(--edge); border-radius: var(--radius);
  appearance: none;
}
.field input::placeholder { color: var(--ink-2); }
.gate__form .btn { width: 100%; margin-top: var(--s6); }
.gate__micro { margin-top: var(--s3); font-size: var(--fs-small); line-height: 1.5; color: var(--ink-2); }
.gate__error { margin-top: var(--s2); font-size: var(--fs-small); line-height: 1.5; color: var(--ink); min-height: 0; }
.gate__error:empty { display: none; }
.gate__swap { position: relative; }
.gate__done { display: none; }
.gate__done .lead { font-family: var(--mono); font-size: var(--fs-mono); line-height: 1.6; }
.gate__done p + p { margin-top: 1em; }
.gate.is-sent .gate__form { display: none; }
.gate.is-sent .gate__done { display: block; }
.gate__form, .gate__done { transition: opacity var(--t-swap) ease-out; }
.gate.is-fading .gate__form { opacity: 0; }
.gate__done.is-in { animation: gate-in var(--t-swap) ease-out; }
.gate[open] .gate__panel { animation: gate-rise var(--t-open) ease-out; }
.gate[open]::backdrop { animation: gate-in var(--t-open) ease-out; }
.gate.is-closing { animation: gate-out var(--t-close) ease-in forwards; }
.gate.is-closing::backdrop { animation: gate-out var(--t-close) ease-in forwards; }
@keyframes gate-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes gate-out { from { opacity: 1; } to { opacity: 0; } }
@keyframes gate-rise { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }
@media (min-width: 768px) {
  .gate {
    inset: 0; width: min(480px, calc(100% - 48px)); height: auto; max-height: calc(100dvh - 48px);
    margin: auto; border: 1px solid var(--rule); border-radius: var(--radius);
    box-shadow: var(--shadow-gate);
  }
  .gate__panel { padding: var(--s12) 40px 40px; min-height: 0; }
}

/* ── X bloom overlay ────────────────────────────────────────────────── */
.bloom {
  position: fixed; inset: 0; width: 100%; height: 100%;
  pointer-events: none; z-index: 60; overflow: visible;
}
.bloom rect { fill: none; stroke: var(--gold); stroke-linejoin: miter; }

/* ── Secondary pages (privacy, terms, join us, roles, partners) ────── */
.page { padding-block: var(--s12) var(--s16); }
.page__head { margin-bottom: var(--s12); }
.page__head .h1 { font-size: var(--fs-h2); margin-top: var(--s4); }
.page__head .sub { margin-top: var(--s4); color: var(--ink-2); }
.prose { max-width: var(--measure); }
.prose > * + * { margin-top: 1em; }
.prose h2 { font-size: var(--fs-h3); font-weight: 600; line-height: 1.3; margin-top: var(--s12); }
.prose h3 { font-size: var(--fs-body); font-weight: 600; line-height: 1.4; margin-top: var(--s8); }
.prose h2 + *, .prose h3 + * { margin-top: var(--s3); }
.prose ul, .prose ol { padding-left: 1.25em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: var(--s2); }
.prose ul.plain { list-style: none; padding-left: 0; }
.prose a { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--edge); }
.prose a:hover { text-decoration-color: currentColor; }
.prose strong { font-weight: 600; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--fs-small); }
.prose th, .prose td { text-align: left; vertical-align: top; padding: var(--s3) var(--s3) var(--s3) 0; border-top: 1px solid var(--rule); }
.prose th { font-family: var(--mono); font-size: var(--fs-label); font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-2); }
.prose .meta { font-family: var(--mono); font-size: var(--fs-label); color: var(--ink-2); }
.prose hr { border: 0; border-top: 1px solid var(--rule); margin-block: var(--s12); }
.page .btn { margin-top: var(--s8); }
@media (min-width: 768px) { .page { padding-block: var(--s16) var(--s24); } }

/* ── Reduced motion ─────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0ms !important;
    animation-duration: 0ms !important;
    transition-delay: 0ms !important;
  }
}
