/* ============================================================
   FFS — ffsdms.com v2 proof of concept
   Ink / paper / gold design language, dark theme.
   Self-hosted Fraunces for headlines; system sans for body.
   ============================================================ */

@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/fraunces-var.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/fraunces-var-italic.woff2') format('woff2');
}

:root {
  /* ink */
  --ink-950: #060b14;
  --ink-900: #0a1220;
  --ink-850: #0d1729;
  --ink-800: #101d33;
  --ink-700: #182742;
  /* paper */
  --paper: #f2efe6;
  --paper-dim: #b9bfc9;
  --paper-faint: #7e8798;
  /* gold */
  --gold: #c8a35e;
  --gold-bright: #e3c98f;
  --gold-deep: #a07f3a;
  /* rules + surfaces */
  --line: rgba(185, 191, 201, 0.13);
  --line-strong: rgba(185, 191, 201, 0.22);
  --gold-line: rgba(200, 163, 94, 0.28);
  --card: rgba(16, 29, 51, 0.55);
  --max: 1120px;
  --radius: 14px;
  --sans: 'Segoe UI', 'Segoe UI Variable Text', -apple-system, BlinkMacSystemFont, 'Inter', 'Helvetica Neue', Arial, sans-serif;
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  background: var(--ink-950);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--gold-bright); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 28px; }

::selection { background: rgba(200, 163, 94, 0.35); color: var(--paper); }

/* ---------- header / nav ---------- */

.site-head {
  position: sticky; top: 0; z-index: 50;
  background: rgba(6, 11, 20, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-head .bar {
  display: flex; align-items: center; gap: 28px;
  height: 68px;
}
/* Brand = large coin + quiet wordmark. No "FFS" text — the coin carries it. */
.brand { display: flex; align-items: center; gap: 14px; }
.brand:hover { text-decoration: none; }
.brand img { width: 46px; height: 46px; border-radius: 50%; }
.wordmark {
  text-transform: uppercase; font-weight: 600;
  font-size: 12px; letter-spacing: 0.22em; line-height: 1.5;
  color: var(--paper-dim);
}
.nav { display: flex; align-items: center; gap: 26px; margin-left: auto; }
.nav a {
  color: var(--paper-dim); font-size: 14.5px; font-weight: 500;
}
.nav a:hover { color: var(--paper); text-decoration: none; }
.nav a.active { color: var(--gold-bright); }
.nav .login { color: var(--paper-faint); font-size: 13.5px; }
.btn {
  display: inline-block;
  background: var(--gold); color: #14100a;
  font-weight: 700; font-size: 14.5px; letter-spacing: 0.01em;
  padding: 10px 20px; border-radius: 9px;
  border: 1px solid var(--gold-deep);
  cursor: pointer; transition: background 140ms ease;
}
.btn:hover { background: var(--gold-bright); text-decoration: none; }
/* `.nav a` / `.nav a:hover` outrank `.btn` on specificity, washing the nav CTA
   out to light-on-gold — re-assert dark ink for buttons inside the nav. */
.nav a.btn, .nav a.btn:hover, .nav a.btn:focus-visible { color: #14100a; }
.btn:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 2px; }
.btn.big { padding: 14px 28px; font-size: 16px; border-radius: 11px; }
.btn.ghost {
  background: transparent; color: var(--paper);
  border: 1px solid var(--line-strong);
}
.btn.ghost:hover { background: rgba(185, 191, 201, 0.07); border-color: var(--paper-faint); }

.nav-toggle { display: none; }

@media (max-width: 860px) {
  .site-head .bar { height: 62px; }
  .site-head .brand img { width: 40px; height: 40px; }
}
@media (max-width: 640px) {
  /* the wordmark won't fit beside a hamburger at phone widths — coin stands alone */
  .site-head .wordmark { display: none; }
}
@media (max-width: 860px) {
  .nav {
    display: none;
    position: absolute; top: 62px; left: 0; right: 0;
    background: var(--ink-900);
    border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: flex-start;
    padding: 18px 28px 22px; gap: 16px;
  }
  .nav.open { display: flex; }
  .nav-toggle {
    display: inline-flex; flex-direction: column; gap: 5px;
    margin-left: auto; background: none; border: 0; cursor: pointer; padding: 8px;
  }
  .nav-toggle span {
    width: 22px; height: 2px; background: var(--paper-dim); border-radius: 2px;
  }
}

/* ---------- typography ---------- */

.eyebrow {
  font-weight: 700; font-size: 12px; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--gold-deep);
}
h1, h2, h3 { font-family: var(--serif); color: var(--paper); }
h1 { font-size: clamp(34px, 5vw, 54px); line-height: 1.12; font-weight: 620; letter-spacing: -0.015em; }
h2 { font-size: clamp(26px, 3.4vw, 36px); line-height: 1.18; font-weight: 600; letter-spacing: -0.01em; }
h3 { font-size: 20px; font-weight: 600; line-height: 1.3; }
.lede { color: var(--paper-dim); font-size: clamp(17px, 2vw, 19.5px); line-height: 1.6; }
.gold-rule { width: 58px; height: 3px; background: var(--gold); border-radius: 2px; }

section { padding: 84px 0; }
section.tight { padding: 58px 0; }
.sec-head { max-width: 760px; margin-bottom: 44px; }
.sec-head .eyebrow { display: block; margin-bottom: 14px; }
.sec-head p { margin-top: 14px; }

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

.hero {
  position: relative; overflow: hidden;
  padding: 96px 0 72px;
  background:
    radial-gradient(1100px 500px at 78% -10%, rgba(200, 163, 94, 0.10), transparent 60%),
    radial-gradient(900px 420px at 12% 8%, rgba(24, 39, 66, 0.55), transparent 65%),
    var(--ink-950);
  border-bottom: 1px solid var(--line);
}
.hero .eyebrow { display: block; margin-bottom: 18px; }
.hero h1 { max-width: 900px; }
.hero h1 em {
  font-style: italic; color: var(--gold-bright); font-weight: 600;
}
/* Display scale for the short hero headline — sized to break as two balanced lines. */
.hero h1.display {
  font-size: clamp(38px, 5.6vw, 66px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  max-width: 1020px;
}
.hero .lede { max-width: 680px; margin-top: 22px; }
.hero .cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero .quiet-note { margin-top: 18px; color: var(--paper-faint); font-size: 13.5px; }

/* Abstract editorial artwork — no product UI is ever shown on the public site.
   Images render at intrinsic ratio; crops use aspect-ratio + object-fit: cover
   (never width+height stretching). */
.art-frame {
  margin-top: 58px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--ink-900);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 30px 80px -20px rgba(0, 0, 0, 0.75);
}
.art-frame img { width: 100%; height: auto; display: block; }
/* cinematic crops for full-width slots */
.art-frame.wide img { aspect-ratio: 16 / 9; object-fit: cover; }
.art-frame.band img { aspect-ratio: 16 / 7; object-fit: cover; }
.feature-row .art-frame { margin-top: 0; }

/* ---------- lifecycle strip ---------- */

.lifecycle { border-bottom: 1px solid var(--line); background: var(--ink-900); }
.life-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: var(--ink-850);
}
.life-step { padding: 26px 26px 30px; position: relative; border-left: 1px solid var(--line); }
.life-step:first-child { border-left: 0; }
.life-step .num {
  font-family: var(--serif); font-style: italic;
  color: var(--gold); font-size: 15px; margin-bottom: 10px; display: block;
}
.life-step h3 { font-size: 18.5px; margin-bottom: 8px; }
.life-step p { color: var(--paper-dim); font-size: 14.5px; line-height: 1.55; }
.life-step::after {
  content: "\2192";
  position: absolute; right: -9px; top: 30px; z-index: 2;
  color: var(--gold); font-size: 15px;
  background: var(--ink-850);
  border: 1px solid var(--gold-line); border-radius: 50%;
  width: 24px; height: 24px; line-height: 22px; text-align: center;
}
.life-step:last-child::after { display: none; }
@media (max-width: 860px) {
  .life-grid { grid-template-columns: 1fr; }
  .life-step { border-left: 0; border-top: 1px solid var(--line); }
  .life-step:first-child { border-top: 0; }
  .life-step::after { display: none; }
}

/* ---------- pillars ---------- */

.pillar-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.pillar {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 26px 30px;
  transition: border-color 160ms ease, transform 160ms ease;
}
.pillar:hover { border-color: var(--gold-line); }
.pillar .glyph {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(200, 163, 94, 0.10);
  border: 1px solid var(--gold-line);
  color: var(--gold-bright); font-size: 18px;
  margin-bottom: 16px;
}
.pillar h3 { margin-bottom: 9px; font-size: 19px; }
.pillar p { color: var(--paper-dim); font-size: 14.8px; line-height: 1.6; }
.pillar p b { color: var(--paper); font-weight: 600; }
@media (max-width: 960px) { .pillar-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .pillar-grid { grid-template-columns: 1fr; } }

/* ---------- comparison band ---------- */

.compare {
  background:
    radial-gradient(900px 400px at 85% 0%, rgba(200, 163, 94, 0.08), transparent 60%),
    var(--ink-900);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.tools-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 34px;
  margin-top: 34px; max-width: 880px;
}
.tool-row {
  display: flex; align-items: baseline; gap: 12px;
  padding: 11px 2px; border-bottom: 1px dotted var(--line-strong);
  font-size: 15.5px; color: var(--paper-dim);
}
.tool-row .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--gold); flex: 0 0 7px; transform: translateY(-2px);
}
.tool-row .cap { color: var(--paper); font-weight: 600; }
.tools-note {
  margin-top: 30px; max-width: 720px;
  font-family: var(--serif); font-style: italic;
  font-size: clamp(18px, 2.4vw, 22px); line-height: 1.5;
  color: var(--paper);
}
.tools-note b { color: var(--gold-bright); font-weight: 600; }
@media (max-width: 720px) { .tools-grid { grid-template-columns: 1fr; } }

/* ---------- security strip ---------- */

.sec-strip .cols {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 8px;
}
.sec-item {
  border-top: 2px solid var(--gold-line);
  padding-top: 18px;
}
.sec-item h3 { font-size: 17px; margin-bottom: 8px; }
.sec-item p { color: var(--paper-dim); font-size: 14.2px; line-height: 1.58; }
@media (max-width: 960px) { .sec-strip .cols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .sec-strip .cols { grid-template-columns: 1fr; } }

/* ---------- split feature rows (product page) ---------- */

.feature-row {
  display: grid; grid-template-columns: 5fr 6fr; gap: 54px;
  align-items: center; padding: 54px 0;
  border-top: 1px solid var(--line);
}
.feature-row:first-of-type { border-top: 0; }
.feature-row.flip .txt { order: 2; }
.feature-row .txt .eyebrow { display: block; margin-bottom: 12px; }
.feature-row .txt h2 { font-size: clamp(24px, 3vw, 30px); margin-bottom: 14px; }
.feature-row .txt p { color: var(--paper-dim); margin-bottom: 12px; }
.feature-row .txt ul { margin: 14px 0 0 18px; color: var(--paper-dim); }
.feature-row .txt li { margin-bottom: 8px; font-size: 15px; }
.feature-row .txt li b { color: var(--paper); font-weight: 600; }
@media (max-width: 900px) {
  .feature-row { grid-template-columns: 1fr; gap: 26px; }
  .feature-row.flip .txt { order: 0; }
}

/* ---------- tables (security page) ---------- */

.matrix {
  width: 100%; border-collapse: collapse; margin-top: 10px;
  font-size: 15px;
}
.matrix th, .matrix td {
  text-align: left; padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.matrix th {
  color: var(--gold-deep); font-size: 12px; letter-spacing: 0.16em;
  text-transform: uppercase; font-weight: 700;
}
.matrix td:first-child { color: var(--paper); font-weight: 600; white-space: nowrap; }
.matrix td { color: var(--paper-dim); }
@media (max-width: 700px) {
  .matrix td:first-child { white-space: normal; }
}

/* ---------- callout ---------- */

.callout {
  background: var(--ink-850);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 10px;
  padding: 22px 26px;
  margin: 34px 0;
}
.callout h4 {
  font-weight: 700; font-size: 11.5px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--gold-deep); margin-bottom: 8px;
}
.callout p {
  font-family: var(--serif); font-weight: 500;
  font-size: 17.5px; line-height: 1.5; color: var(--paper);
}

/* ---------- stats band (deployment) ---------- */

.stat-band { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 40px 0 10px; }
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; text-align: left;
}
.stat .n {
  font-family: var(--serif); font-size: 34px; font-weight: 620; color: var(--gold-bright);
  line-height: 1.1;
}
.stat .l { color: var(--paper-dim); font-size: 14px; margin-top: 8px; line-height: 1.5; }
@media (max-width: 760px) { .stat-band { grid-template-columns: 1fr; } }

/* ---------- demo form ---------- */

.demo-grid { display: grid; grid-template-columns: 6fr 5fr; gap: 60px; align-items: center; }
@media (max-width: 900px) { .demo-grid { grid-template-columns: 1fr; } }

.form-card {
  background: var(--ink-900);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 34px;
}
.form-card .row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .form-card .row2 { grid-template-columns: 1fr; } }
.field { margin-bottom: 18px; }
.field label {
  display: block; font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
  color: var(--paper-dim); margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%;
  background: var(--ink-950);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--paper);
  font-family: var(--sans); font-size: 15px;
  padding: 11px 14px;
  outline: none;
  transition: border-color 130ms ease;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--gold);
}
.field textarea { min-height: 110px; resize: vertical; }
.form-note { color: var(--paper-faint); font-size: 13px; margin-top: 14px; line-height: 1.5; }
.form-ok {
  display: none;
  margin-top: 16px; padding: 14px 18px;
  background: rgba(200, 163, 94, 0.10);
  border: 1px solid var(--gold-line); border-radius: 9px;
  color: var(--gold-bright); font-size: 14.5px;
}
.form-ok.show { display: block; }
.form-fail {
  display: none;
  margin-top: 16px; padding: 14px 18px;
  background: rgba(224, 138, 122, 0.08);
  border: 1px solid rgba(224, 138, 122, 0.38); border-radius: 9px;
  color: #e2988a; font-size: 14.5px;
}
.form-fail a { color: #e2b3a8; text-decoration: underline; }
.form-fail.show { display: block; }
/* Honeypot: removed from view and tab order but present for bots to autofill. */
.hp-field {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden;
}
.btn:disabled { opacity: 0.65; cursor: default; }
.btn:disabled:hover { background: var(--gold); }

/* ---------- CTA band ---------- */

.cta-band {
  background:
    radial-gradient(700px 300px at 50% 0%, rgba(200, 163, 94, 0.12), transparent 65%),
    var(--ink-900);
  border-top: 1px solid var(--line);
  text-align: center;
}
.cta-band h2 { max-width: 640px; margin: 0 auto 16px; }
.cta-band .lede { max-width: 560px; margin: 0 auto 30px; }

/* ---------- footer ---------- */

.site-foot {
  border-top: 1px solid var(--line);
  background: var(--ink-950);
  padding: 44px 0 54px;
  color: var(--paper-faint); font-size: 13.5px;
}
.site-foot .top {
  display: flex; flex-wrap: wrap; gap: 26px; align-items: center;
  padding-bottom: 26px; border-bottom: 1px solid var(--line); margin-bottom: 22px;
}
.site-foot .brand img { width: 34px; height: 34px; }
.site-foot .wordmark { font-size: 10.5px; letter-spacing: 0.2em; }
.site-foot nav { display: flex; flex-wrap: wrap; gap: 22px; margin-left: auto; }
.site-foot a { color: var(--paper-dim); }
.site-foot .fine { max-width: 860px; line-height: 1.6; }

/* ---------- reveal motion (restrained) ---------- */

.reveal { opacity: 0; transform: translateY(14px); transition: opacity 480ms ease, transform 480ms ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- mission statement band ---------- */
/* The long-form thesis, relocated from the hero: full-width, set large in the
   serif so it reads as the deliberate philosophical anchor of the page. */
.mission {
  background: var(--ink-900);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
  padding: 96px 0;
}
.mission-line {
  font-family: var(--serif);
  font-size: clamp(25px, 3.4vw, 40px);
  line-height: 1.32;
  font-weight: 620;
  letter-spacing: -0.012em;
  color: var(--paper);
  max-width: 1000px;
  margin: 0 auto;
}
.mission-line em { font-style: italic; color: var(--gold-bright); font-weight: 600; }