/* ============================================================
   Sytful Minds — flagship stylesheet
   Default theme: dark-green "field-lab noir" (#070b0a family).
   Light theme: warm paper, deep-green ink — every color token is
   redefined under :root[data-theme="light"].
   Zero external requests: system font stacks, inline-SVG textures.
   ============================================================ */

:root {
  /* --- canvas (dark default) --- */
  --bg: #070b0a;
  --bg2: #0b1210;
  --bg3: #040706;
  --surface: rgba(230, 255, 244, 0.03);
  --line: rgba(230, 255, 244, 0.09);
  --line2: rgba(60, 230, 164, 0.18);

  /* --- signature accent: signal mint --- */
  --accent: #3ce6a4;
  --accent-rgb: 60, 230, 164;
  --accent-dim: #1fae79;
  --accent-soft: rgba(60, 230, 164, 0.09);

  /* --- scarce secondary: amber (numerals, currency) --- */
  --amber: #e0b84c;
  --amber-rgb: 224, 184, 76;

  /* --- ink --- */
  --text: #e9f4ee;
  --muted: #9db3a9;
  --ghost: rgba(233, 244, 238, 0.05);

  --btn-ink: #04110b;
  --nav-bg: rgba(4, 7, 6, 0.88);
  --grid-stroke: rgba(230, 255, 244, 0.045);
  --grain-opacity: 0.035;
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.5), 0 14px 44px rgba(0, 0, 0, 0.35);

  /* --- type (zero external fonts) --- */
  --serif: 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, 'Times New Roman', serif;
  --sans: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --radius: 14px;
  --radius-sm: 8px;
  --wrap: 1120px;
  --gutter: clamp(1.25rem, 4.5vw, 3.5rem);
}

/* Light theme — warm paper ground, deep-green ink, accents re-tuned
   so every text/background pair clears WCAG AA on the paper ground. */
:root[data-theme="light"] {
  --bg: #f5f7f9;                /* cool near-white, not beige */
  --bg2: #e7ebef;               /* light silver */
  --bg3: #fcfdfe;               /* near-pure white */
  --surface: rgba(22, 28, 36, 0.045);
  --line: rgba(22, 28, 36, 0.15);
  --line2: rgba(9, 92, 62, 0.32);

  --accent: #095c3e;            /* deep signal green — >7:1 on cool white */
  --accent-rgb: 9, 92, 62;
  --accent-dim: #0b6b4a;
  --accent-soft: rgba(9, 92, 62, 0.08);

  --amber: #75590f;             /* ochre — 5.9:1 on paper */
  --amber-rgb: 117, 89, 15;

  --text: #161a1f;              /* cool charcoal "oreo dark" */
  --muted: #4b555f;             /* cool slate — AA on near-white */
  --ghost: rgba(22, 28, 36, 0.055);

  --btn-ink: #f6fbf7;
  --nav-bg: rgba(247, 249, 251, 0.9);
  --grid-stroke: rgba(22, 28, 36, 0.06);
  --grain-opacity: 0.045;
  /* metallic card: inset white sheen top edge + cool silver drop */
  --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 1px 2px rgba(30, 38, 48, 0.08), 0 16px 44px rgba(30, 38, 48, 0.12);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* fixed radial mesh, behind everything */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 50% at 82% -10%, rgba(var(--accent-rgb), 0.05) 0%, transparent 60%),
    radial-gradient(ellipse 60% 45% at -10% 40%, rgba(var(--accent-rgb), 0.03) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 60% 110%, rgba(var(--amber-rgb), 0.025) 0%, transparent 60%);
}

/* light theme = "metallic oreo": near-white with silver + charcoal glows over a cool gradient */
:root[data-theme="light"] body::before {
  background:
    radial-gradient(ellipse 72% 52% at 84% -12%, rgba(122, 138, 155, 0.16) 0%, transparent 62%),
    radial-gradient(ellipse 64% 48% at -12% 42%, rgba(38, 48, 62, 0.07) 0%, transparent 62%),
    radial-gradient(ellipse 52% 42% at 60% 112%, rgba(var(--accent-rgb), 0.045) 0%, transparent 62%),
    linear-gradient(178deg, #fbfcfd 0%, #eef1f4 62%, #e6eaee 100%);
}

/* full-page grain — inline feTurbulence SVG data-URI, no binary asset */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: rgba(var(--accent-rgb), 0.3); color: var(--text); }

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

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

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

/* skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 200;
  padding: 0.6rem 1.2rem;
  background: var(--accent);
  color: var(--btn-ink);
  font-family: var(--mono);
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 1rem; }

/* ---------------- the meridian spine ----------------
   A single hairline that runs the full height of the page with
   mono index ticks — the editorial thread every section hangs off. */
.meridian {
  display: none;
}
@media (min-width: 1100px) {
  .meridian {
    display: block;
    position: fixed;
    top: 0;
    bottom: 0;
    left: max(calc((100vw - var(--wrap)) / 2 - 3.5rem), 1.25rem);
    width: 1px;
    background: linear-gradient(180deg, transparent, var(--line2) 4%, var(--line2) 96%, transparent);
    z-index: 1;
    pointer-events: none;
  }
}

/* ---------------- nav ---------------- */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding-block: 0.95rem;
  border-bottom: 1px solid transparent;
  transition: background 0.35s, border-color 0.35s;
}
.site-nav.scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border-bottom-color: var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--text);
  font-family: var(--serif);
  font-size: 1.18rem;
  letter-spacing: 0.01em;
}
.brand .brand-mark {
  width: 10px; height: 10px;
  border-radius: 2px;
  background: var(--accent);
  align-self: center;
  transform: rotate(45deg);
  flex: none;
}
.brand em { font-style: italic; color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  list-style: none;
}
.nav-links a {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -5px;
  width: 0; height: 1px;
  background: var(--accent);
  transition: width 0.3s var(--ease);
}
.nav-links a:hover::after { width: 100%; }

.theme-toggle {
  min-width: 44px; min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: 1px solid var(--line);
  border-radius: 100px;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.25s;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
:root[data-theme="light"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="light"] .theme-toggle .icon-moon { display: none; }

@media (max-width: 860px) {
  .nav-links { display: none; }
}

/* ---------------- shared section furniture ---------------- */
section[data-module] {
  position: relative;
  padding-block: clamp(4.5rem, 10vw, 8.5rem);
}
section[data-module] + section[data-module] { border-top: 1px solid var(--line); }

.eyebrow {
  display: flex;
  align-items: baseline;
  gap: 0.8rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.6rem;
}
.eyebrow .idx { color: var(--muted); letter-spacing: 0.1em; }
.eyebrow::after {
  content: '';
  flex: 1;
  max-width: 6rem;
  height: 1px;
  background: var(--line2);
  align-self: center;
}

.section-title {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 4.6vw, 3.3rem);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.02em;
  max-width: 22ch;
}
.section-title em { font-style: italic; color: var(--accent); }

.lede {
  color: var(--muted);
  max-width: 58ch;
  margin-top: 1.2rem;
  font-size: 1.04rem;
}
.lede strong { color: var(--text); font-weight: 600; }

/* ---------------- buttons ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  padding: 0.6rem 1.5rem;
  border-radius: 100px;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s;
}
.btn-primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-dim));
  color: var(--btn-ink);
  border: none;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 32px rgba(var(--accent-rgb), 0.25);
}
.btn-ghost {
  background: none;
  border: 1px solid var(--line2);
  color: var(--accent);
}
.btn-ghost:hover { border-color: var(--accent); transform: translateY(-2px); }

/* ---------------- hero ---------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-block: 7.5rem 4rem;
  overflow: hidden;
}
#contour-field {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
/* blueprint grid over the canvas, masked toward center-top */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48'%3E%3Cpath d='M48 .5H.5V48' fill='none' stroke='rgba(128,148,140,.14)'/%3E%3C/svg%3E");
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 15%, black 25%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 15%, black 25%, transparent 75%);
}
.hero .wrap { position: relative; z-index: 2; width: 100%; }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 0.9fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
}
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; align-items: start; }
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--line2);
  border-radius: 100px;
  padding: 0.45rem 1.05rem;
  background: var(--accent-soft);
  margin-bottom: 2rem;
}
.hero-tag::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
  animation: ping 2.4s ease-in-out infinite;
}
@keyframes ping {
  0%, 100% { box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0.5); }
  50% { box-shadow: 0 0 0 6px rgba(var(--accent-rgb), 0); }
}

.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.7rem, 6.8vw, 5.4rem);
  line-height: 1.0;
  letter-spacing: -0.03em;
  /* padding guard so italic ascenders + terminal period never clip */
  padding: 0.08em 0.12em 0.06em 0;
  margin: -0.08em -0.12em -0.06em 0;
}
.hero h1 em { font-style: italic; color: var(--accent); }

.hero-sub {
  margin-top: 1.7rem;
  color: var(--muted);
  max-width: 52ch;
  font-size: 1.06rem;
}
.hero-sub strong { color: var(--text); font-weight: 600; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.4rem;
}

/* hero side readout — mono field-notes column */
.hero-readout {
  font-family: var(--mono);
  font-size: 0.74rem;
  line-height: 2.1;
  color: var(--muted);
  border-left: 1px solid var(--line2);
  padding-left: 1.4rem;
}
.hero-readout .ro-title {
  color: var(--accent);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-size: 0.62rem;
  margin-bottom: 0.6rem;
}
.hero-readout .ro-row {
  display: flex;
  justify-content: space-between;
  gap: 1.4rem;
  border-bottom: 1px dashed var(--line);
}
.hero-readout .ro-row b { color: var(--amber); font-weight: 600; }
.hero-readout .ro-row .ok { color: var(--accent); }
@media (max-width: 900px) {
  .hero-readout { max-width: 26rem; }
}

/* ---------------- 02 · what we do — editorial ledger ---------------- */
.practice-list { list-style: none; margin-top: 3rem; }
.practice {
  display: grid;
  grid-template-columns: 5.5rem minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1rem, 3vw, 3rem);
  align-items: baseline;
  padding-block: 2.2rem;
  border-top: 1px solid var(--line);
}
.practice:last-child { border-bottom: 1px solid var(--line); }
/* asymmetric drift — each row steps a little further in */
.practice:nth-child(2) { padding-left: clamp(0rem, 3vw, 2.5rem); }
.practice:nth-child(3) { padding-left: clamp(0rem, 6vw, 5rem); }
.practice:nth-child(4) { padding-left: clamp(0rem, 9vw, 7.5rem); }

.practice .p-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  color: var(--amber);
  line-height: 1;
}
.practice h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.25rem, 2.4vw, 1.7rem);
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.practice h3 span {
  display: block;
  font-family: var(--mono);
  font-style: normal;
  font-size: 0.64rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-top: 0.5rem;
}
.practice p { color: var(--muted); font-size: 0.97rem; }
@media (max-width: 780px) {
  .practice { grid-template-columns: 3rem 1fr; }
  .practice p { grid-column: 2; }
  .practice:nth-child(n) { padding-left: 0; }
}

/* ---------------- terminal cards (calculator, pricing, demo) ------- */
.term-card {
  background: var(--bg3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.term-head {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.8rem 1.2rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.term-dots { display: flex; gap: 0.4rem; }
.term-dots i {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--line2);
}
.term-dots i:first-child { background: var(--accent); }
.term-name {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--muted);
}
.term-body { padding: clamp(1.3rem, 3vw, 2.2rem); }

/* ---------------- 03 · ROI calculator ---------------- */
.roi-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  margin-top: 3rem;
  align-items: start;
}
@media (max-width: 900px) { .roi-layout { grid-template-columns: 1fr; } }

.roi-fields { display: grid; gap: 1.5rem; }
.roi-field label {
  display: block;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.45rem;
}
.roi-field input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line2);
  padding: 0.45rem 0.1rem;
  font-family: var(--mono);
  font-size: 1.35rem;
  color: var(--text);
  transition: border-color 0.25s;
}
.roi-field input:focus { border-bottom-color: var(--accent); outline: none; }
.roi-field input:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.roi-field .hint { font-family: var(--mono); font-size: 0.68rem; color: var(--muted); margin-top: 0.35rem; }

.roi-formula {
  font-family: var(--mono);
  font-size: 0.76rem;
  line-height: 2;
  color: var(--muted);
  border: 1px dashed var(--line2);
  border-radius: var(--radius-sm);
  padding: 0.9rem 1.1rem;
  margin-top: 0.5rem;
}
.roi-formula b { color: var(--accent); font-weight: 600; }

.roi-out { display: grid; gap: 0; }
.roi-out-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding-block: 1rem;
  border-bottom: 1px dashed var(--line);
  font-family: var(--mono);
}
.roi-out-row span { font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.roi-out-row output { font-size: 1.35rem; color: var(--accent); }
.roi-out-row.big output { font-size: clamp(1.9rem, 4vw, 2.7rem); color: var(--amber); }

.fine-note {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--muted);
  margin-top: 1.3rem;
  line-height: 1.8;
}

noscript .noscript-example {
  border: 1px solid var(--line2);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.3rem;
  margin-top: 1.4rem;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 2;
  color: var(--muted);
}
noscript .noscript-example b { color: var(--amber); }

/* ---------------- 04 · model pricing ---------------- */
.pricing-scroll { overflow-x: auto; margin-top: 3rem; }
.pricing-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.pricing-table caption {
  caption-side: top;
  text-align: left;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding-bottom: 1rem;
  line-height: 1.9;
}
.pricing-table th {
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: left;
  padding: 0.7rem 1rem 0.7rem 0;
  border-bottom: 1px solid var(--line2);
}
.pricing-table th.num, .pricing-table td.num { text-align: right; }
.pricing-table td {
  padding: 0.85rem 1rem 0.85rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  vertical-align: top;
}
.pricing-table td.num { font-family: var(--mono); color: var(--amber); white-space: nowrap; }
.pricing-table .vendor-row td {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  border-bottom: none;
  padding-top: 1.6rem;
}
.pricing-table .model-note { display: block; font-size: 0.78rem; color: var(--muted); }

/* ---------------- 05 · demo ---------------- */
.demo-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  margin-top: 3rem;
  align-items: start;
}
@media (max-width: 900px) { .demo-layout { grid-template-columns: 1fr; } }

.chat-log {
  min-height: 14rem;
  display: grid;
  gap: 1rem;
  align-content: start;
}
.chat-msg { max-width: 92%; }
.chat-msg .who {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.chat-msg.from-user { justify-self: end; text-align: right; }
.chat-msg.from-user .bubble {
  background: var(--accent-soft);
  border: 1px solid var(--line2);
}
.chat-msg .bubble {
  display: inline-block;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.7rem 1rem;
  font-size: 0.92rem;
  line-height: 1.7;
}
.chat-questions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.4rem;
  padding-top: 1.4rem;
  border-top: 1px dashed var(--line);
}
.chat-q {
  background: none;
  border: 1px solid var(--line2);
  border-radius: 100px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.72rem;
  padding: 0.5rem 1rem;
  min-height: 44px;
  cursor: pointer;
  transition: border-color 0.25s, background 0.25s;
}
.chat-q:hover:not(:disabled) { border-color: var(--accent); background: var(--accent-soft); }
.chat-q:disabled { opacity: 0.4; cursor: default; }

.chat-tools {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.2rem;
}
.voice-btn {
  background: none;
  border: 1px solid var(--line2);
  border-radius: 100px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 1.1rem;
  min-height: 44px;
  cursor: pointer;
  transition: border-color 0.25s;
}
.voice-btn:hover { border-color: var(--accent); }
.voice-btn[aria-pressed="true"] { background: var(--accent-soft); }

.demo-note { font-family: var(--mono); font-size: 0.7rem; color: var(--muted); line-height: 1.9; }

/* ---------------- 06 · ecosystem strip ---------------- */
.eco-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 3rem;
}
@media (max-width: 700px) { .eco-strip { grid-template-columns: 1fr; } }
.eco-cell {
  background: var(--bg2);
  padding: clamp(1.6rem, 3.5vw, 2.6rem);
  text-decoration: none;
  color: var(--text);
  display: block;
  transition: background 0.3s;
  position: relative;
}
.eco-cell:hover { background: var(--surface); }
.eco-cell .eco-kind {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
}
.eco-cell h3 {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 600;
  margin-block: 0.6rem 0.4rem;
}
.eco-cell h3 .arrow { color: var(--accent); font-style: normal; }
.eco-cell p { color: var(--muted); font-size: 0.94rem; }

/* ---------------- 07 · philosophy ---------------- */
.philosophy { position: relative; overflow: hidden; }
/* Ghost display words are decorative: the text is injected via CSS
   `content: attr(data-word)` so it is never a DOM text node (invisible
   to AT, exempt from text-contrast — it is texture, not copy). */
.ghost-word::before, .footer-word::before { content: attr(data-word); }
.ghost-word {
  position: absolute;
  right: -2rem;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(8rem, 24vw, 20rem);
  color: var(--ghost);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
  line-height: 1;
}
.philosophy blockquote {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3.4vw, 2.4rem);
  font-style: italic;
  line-height: 1.35;
  max-width: 26ch;
  border-left: 2px solid var(--accent);
  padding-left: clamp(1.2rem, 3vw, 2.2rem);
  margin-top: 3rem;
  position: relative;
  z-index: 1;
}
.philosophy blockquote em { color: var(--accent); }
.phil-points {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
  margin-top: 3.5rem;
  position: relative;
  z-index: 1;
}
.phil-points h3 {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.phil-points h3::before {
  content: '// ';
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  vertical-align: 2px;
}
.phil-points p { color: var(--muted); font-size: 0.94rem; }

/* ---------------- 08 · engagement rail ---------------- */
.engage-rail { list-style: none; margin-top: 3rem; position: relative; }
.engage-rail::before {
  content: '';
  position: absolute;
  left: 0.55rem;
  top: 0.9rem;
  bottom: 0.9rem;
  width: 1px;
  background: var(--line2);
}
.engage-step {
  position: relative;
  padding: 0 0 2.6rem 2.8rem;
  max-width: 46rem;
}
.engage-step:last-child { padding-bottom: 0; }
.engage-step::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.4rem;
  width: 1.1rem; height: 1.1rem;
  border-radius: 50%;
  border: 1px solid var(--accent);
  background: var(--bg);
}
.engage-step::after {
  content: '';
  position: absolute;
  left: 0.36rem;
  top: 0.76rem;
  width: 0.4rem; height: 0.4rem;
  border-radius: 50%;
  background: var(--accent);
}
.engage-step h3 {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 600;
}
.engage-step h3 .phase {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--amber);
  display: block;
  margin-bottom: 0.35rem;
}
.engage-step p { color: var(--muted); font-size: 0.95rem; margin-top: 0.4rem; }

/* ---------------- 09 · contact ---------------- */
.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  margin-top: 3rem;
  align-items: start;
}
@media (max-width: 860px) { .contact-layout { grid-template-columns: 1fr; } }

.contact-form { display: grid; gap: 1.4rem; }
.contact-form .placeholder-flag {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px dashed var(--line2);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.9rem;
}
.contact-form label {
  display: block;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.45rem;
}
.contact-form input, .contact-form textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line2);
  padding: 0.5rem 0.1rem;
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--text);
  resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus {
  border-bottom-color: var(--accent);
  outline: none;
}
.contact-form input:focus-visible, .contact-form textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.contact-info { font-size: 0.97rem; color: var(--muted); }
.contact-info dt {
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-top: 1.6rem;
}
.contact-info dd { margin-top: 0.3rem; color: var(--text); }
.contact-info dd.pending { color: var(--muted); font-style: italic; }

/* ---------------- footer ---------------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: 3rem 2.5rem;
  position: relative;
  overflow: hidden;
}
.footer-word {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(3rem, 10vw, 7rem);
  color: var(--ghost);
  line-height: 1;
  user-select: none;
  pointer-events: none;
  margin-bottom: 1.5rem;
  white-space: nowrap;
}
.footer-cols {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 2.1;
}
.footer-cols a { color: var(--muted); }
.footer-cols a:hover { color: var(--accent); }

/* ---------------- reveal (progressive enhancement) ----------------
   Base state = fully visible. Only when JS has stamped html.js do we
   set the pre-animation state, so no-JS visitors see everything. */
.reveal { opacity: 1; transform: none; }
html.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
html.js .reveal.in { opacity: 1; transform: none; }
html.js .reveal.d1 { transition-delay: 0.08s; }
html.js .reveal.d2 { transition-delay: 0.16s; }
html.js .reveal.d3 { transition-delay: 0.24s; }

/* ---------------- reduced motion ---------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  html.js .reveal { opacity: 1; transform: none; }
}

/* ---------------- legal pages ---------------- */
.legal-main { padding-block: 9rem 5rem; max-width: 46rem; }
.legal-main h1 {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.6rem;
}
.legal-main .stamp {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 2.5rem;
}
.legal-main h2 {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 2.2rem 0 0.6rem;
}
.legal-main p, .legal-main li { color: var(--muted); font-size: 0.97rem; }
.legal-main ul { padding-left: 1.3rem; margin-top: 0.5rem; }
.legal-main strong { color: var(--text); }
