/* ============================================================
   Tinqer.ai landing — obsidian lab aesthetic
   ============================================================ */

/* Quantifier NBP by Nate Halley (Total FontGeek), CC BY-SA 3.0 — see fonts/QuantifierNBP-LICENSE.txt */
@font-face {
  font-family: "Quantifier NBP";
  src: url("../fonts/QuantifierNBP.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}

:root {
  --bg: #fbfbfb;
  --bg-soft: #f4f5f9;
  --panel: #ffffff;
  --panel-edge: rgba(19, 66, 255, 0.18);
  --ink: #15171a;
  --ink-dim: #5b5e66;
  --ink-faint: #9a9da8;
  --accent: #1342ff;
  --accent-soft: rgba(19, 66, 255, 0.09);
  --accent-2: #e8590c;
  --danger: #ff6b6b;
  --font-mag: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-logo: "Bungee", "Quantifier NBP", "Arial Black", sans-serif;
  --font-body: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --nav-h: 76px;
  --rail: clamp(20px, 5vw, 96px);
  --radius: 14px;
}

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

html { scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: inherit; text-decoration: none; }
em { font-style: normal; }

/* ---------- film grain ---------- */
.noise {
  position: fixed; inset: -50%;
  pointer-events: none; z-index: 80;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 8s steps(10) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -2%); }
  80% { transform: translate(3%, 3%); }
}


/* ---------- scroll progress ---------- */
.progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 120; }
.progress__bar {
  height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform-origin: 0 50%;
  transform: scaleX(0);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-weight: 700; font-size: 13px;
  letter-spacing: 0.07em; text-transform: uppercase;
  padding: 12px 20px; border-radius: 9px;
  white-space: nowrap;
  border: 1px solid transparent;
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), background 0.25s, color 0.25s, border-color 0.25s;
  will-change: transform;
}
.btn svg { width: 15px; height: 15px; transition: transform 0.25s; }
.btn--solid { background: var(--accent); color: #ffffff; }
.btn--solid:hover { background: #3a63ff; }
.btn--solid:hover svg { transform: translateX(3px); }
.btn--ghost { border-color: var(--panel-edge); color: var(--ink); background: rgba(21, 23, 26,0.02); }
.btn--ghost:hover { border-color: rgba(19, 66, 255, 0.4); color: var(--accent); }
.btn--lg { padding: 16px 26px; font-size: 14px; }

/* ---------- nav ---------- */
/* magazine masthead bar — thick rule lives on the nav itself */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--rail);
  transition: background 0.4s, backdrop-filter 0.4s;
  border-bottom: 4px solid var(--ink);
}
.nav.is-scrolled {
  background: rgba(251, 251, 251, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.nav__logo {
  display: inline-flex; align-items: baseline; gap: 0;
  font-family: var(--font-logo); font-weight: 400;
  font-size: 27px; /* 2x the 13.5px nav links */
  letter-spacing: 0;
  color: var(--ink);
}
.nav__logo em { color: var(--accent); }
.nav__mark { display: none; }
.nav__links {
  display: flex; gap: 32px;
  font-weight: 700; font-size: 13.5px;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--ink);
}
.nav__links a { position: relative; padding: 4px 0; transition: color 0.25s; }
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%;
  background: var(--accent); transform: scaleX(0); transform-origin: 100% 50%;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: 0 50%; }
.nav__actions { display: flex; align-items: center; gap: 12px; }
.nav__burger {
  display: none; position: relative; width: 42px; height: 42px;
  background: rgba(21, 23, 26,0.04); border: 1px solid var(--panel-edge);
  border-radius: 12px; cursor: pointer;
}
.nav__burger span {
  position: absolute; left: 11px; right: 11px; height: 2px; border-radius: 2px;
  background: var(--ink); transition: transform 0.3s, top 0.3s;
}
.nav__burger span:nth-child(1) { top: 16px; }
.nav__burger span:nth-child(2) { top: 24px; }
.nav__burger.is-open span:nth-child(1) { top: 20px; transform: rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { top: 20px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(251, 251, 251, 0.97);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.35s;
}
.mobile-menu.is-open { opacity: 1; pointer-events: auto; }
.mobile-menu nav { display: flex; flex-direction: column; gap: 8px; text-align: center; }
.mobile-menu a {
  font-family: var(--font-mag); font-size: clamp(30px, 8vw, 44px); font-weight: 800;
  text-transform: uppercase; letter-spacing: -0.01em;
  padding: 10px 24px; color: var(--ink);
  transform: translateY(16px); opacity: 0;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s, color 0.25s;
}
.mobile-menu.is-open a { transform: translateY(0); opacity: 1; }
.mobile-menu a:hover { color: var(--accent); }
.mobile-menu a:nth-child(2) { transition-delay: 0.05s; }
.mobile-menu a:nth-child(3) { transition-delay: 0.1s; }
.mobile-menu a:nth-child(4) { transition-delay: 0.15s; }
.mobile-menu a:nth-child(5) { transition-delay: 0.2s; }
.mobile-menu__cta { color: var(--accent) !important; }

/* ---------- hero (white paper; the mural is the showpiece below the text) ---------- */
.hero {
  position: relative; min-height: 92svh; overflow: hidden;
  display: grid; place-items: center; text-align: center;
  padding: calc(var(--nav-h) + 20px) var(--rail) 56px;
  background: var(--bg);
}
.hero__text { position: relative; z-index: 2; max-width: 900px; }

/* the blueprint mural — full-bleed ASCII background behind the hero */
.hero__scene {
  position: absolute; inset: 0; z-index: 0; overflow: hidden;
  display: grid; place-items: center; pointer-events: none;
  opacity: 0.45;
}
.hero__scene .mural { width: 100%; height: 100%; display: block; }
.hero__scene .mural-ascii {
  margin: 0; white-space: pre; user-select: none;
  font-family: var(--font-mono); font-weight: 500; color: var(--accent);
  /* 249 cols x ~0.601 advance -> 0.668vw fills the full screen width */
  font-size: 0.668vw; line-height: 1.04; letter-spacing: 0;
}
/* readability scrim so the headline always wins over the lines */
.hero__veil {
  display: block; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(62% 52% at 50% 46%,
    rgba(251, 251, 251, 0.92) 0%, rgba(251, 251, 251, 0.55) 52%, rgba(251, 251, 251, 0) 100%);
}

/* eyebrow — the plain category line ("what is this?") */
.hero__eyebrow {
  position: relative; z-index: 2;
  font-family: var(--font-mono); font-weight: 700; font-size: clamp(11.5px, 1.3vw, 14px);
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent);
  margin-bottom: 20px;
}
.hero__content { position: relative; z-index: 2; max-width: 860px; margin: 0 auto; }
@media (max-width: 860px) {
  .hero { min-height: auto; }
}
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2);
  box-shadow: 0 0 0 0 rgba(232, 89, 12, 0.5);
  animation: pulse 2.2s infinite;
}
.pulse-dot--sm { width: 6px; height: 6px; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(232, 89, 12, 0.45); }
  70% { box-shadow: 0 0 0 9px rgba(232, 89, 12, 0); }
  100% { box-shadow: 0 0 0 0 rgba(232, 89, 12, 0); }
}
.hero__title {
  font-family: var(--font-mag); font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(42px, 7vw, 92px);
  line-height: 1.0; letter-spacing: -0.025em;
  margin-bottom: 16px;
  color: var(--ink);
}
.hero__line { display: block; overflow: hidden; }
.hero__line > span { display: block; }
.hero__line--accent { color: var(--accent); }
.hero__sub { max-width: 560px; margin: 0 auto 22px; color: var(--ink-dim); font-size: clamp(16px, 2vw, 19px); }
.hero__cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-bottom: 24px; }
.hero__meta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px;
  font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.06em;
  color: var(--ink-faint); text-transform: uppercase;
}
.hero__meta-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--ink-faint); }
.hero__meta-star { color: var(--accent-2); font-size: 12px; }
.hero__scroll {
  position: absolute; right: var(--rail); bottom: 34px; z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.3em;
  text-transform: uppercase; color: var(--ink-faint);
  writing-mode: vertical-rl;
}
.hero__scroll-track {
  width: 1px; height: 64px; background: rgba(21, 23, 26,0.12);
  position: relative; overflow: hidden;
}
.hero__scroll-thumb {
  position: absolute; left: 0; top: -40%; width: 100%; height: 40%;
  background: var(--accent); animation: scrollThumb 2s ease-in-out infinite;
}
@keyframes scrollThumb { 0% { top: -40%; } 100% { top: 110%; } }

/* ---------- marquee ---------- */
.marquee {
  border-top: 1px solid var(--panel-edge);
  border-bottom: 1px solid var(--panel-edge);
  padding: 18px 0; overflow: hidden;
  background: var(--bg-soft);
}
.marquee__inner { display: flex; width: max-content; will-change: transform; }
.marquee__group {
  display: flex; align-items: center; gap: 28px; padding-right: 28px;
  font-family: var(--font-mono); font-size: 14px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-dim); white-space: nowrap;
}
.marquee__group i { color: var(--accent); font-style: normal; font-size: 11px; }

/* ---------- section heads ---------- */
section { position: relative; }
.section-head { padding: clamp(90px, 12vw, 150px) var(--rail) clamp(40px, 6vw, 70px); max-width: 1060px; }
/* datasheet section label — bold lowercase like "logic diagram" */
.section-head__kicker {
  display: flex; align-items: baseline; gap: 16px;
  font-family: var(--font-body); font-weight: 700; font-size: 16px;
  letter-spacing: 0.02em; text-transform: lowercase;
  color: var(--ink); margin-bottom: 18px;
}
.kicker-fig {
  font-family: var(--font-mono); font-weight: 400; font-size: 12px;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent);
}
/* datasheet leader line running off the figure label */
.section-head__kicker::after {
  content: ""; flex: 1; max-width: 260px;
  border-top: 2px dotted rgba(19, 66, 255, 0.45);
}
.section-head { position: relative; }

.section-head__title {
  font-family: var(--font-mag); font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(26px, 4vw, 48px); line-height: 1.06; letter-spacing: -0.025em;
}
.section-head__sub { margin-top: 22px; max-width: 600px; color: var(--ink-dim); font-size: 17.5px; }
.split-words .w { display: inline-block; overflow: hidden; vertical-align: top; }
.split-words .w > span { display: inline-block; }

/* ---------- illustrated assembly strip (logic diagram) ---------- */
.loop__strip {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 22px;
  padding: 0 var(--rail) clamp(60px, 8vw, 110px);
}
.lstep {
  position: relative; margin: 0;
  background: var(--panel);
  border: 1px solid var(--panel-edge); border-radius: var(--radius);
  box-shadow: 0 12px 26px -18px rgba(19, 40, 120, 0.22);
  padding: 14px 16px 20px;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.35s;
}
.lstep:hover { transform: translateY(-4px); border-color: rgba(19, 66, 255, 0.3); }
.lstep::before {
  content: "+"; position: absolute; top: 8px; left: 12px;
  font-family: var(--font-mono); font-size: 13px;
  color: rgba(19, 66, 255, 0.45); pointer-events: none;
}
/* flow arrows between panels */
.lstep:not(:last-child)::after {
  content: "→"; position: absolute; right: -19px; top: 34%;
  font-family: var(--font-mono); font-weight: 700; font-size: 15px;
  color: var(--accent); z-index: 1;
}
.lstep__art svg { width: 100%; height: auto; display: block; }
.lstep figcaption { padding: 6px 4px 0; text-align: center; }
.lstep__num {
  display: block; margin-bottom: 8px;
  font-family: var(--font-mono); font-weight: 700; font-size: 11px;
  letter-spacing: 0.16em; color: var(--accent);
}
.lstep h3 {
  font-family: var(--font-body); font-weight: 700;
  font-size: 21px; letter-spacing: -0.01em; line-height: 1.15; margin-bottom: 7px;
}
.lstep p { color: var(--ink-dim); font-size: 15px; line-height: 1.55; }

@media (max-width: 1100px) {
  .loop__strip { grid-template-columns: repeat(3, 1fr); }
  .lstep:not(:last-child)::after { content: none; }
}
@media (max-width: 760px) {
  .loop__strip { grid-template-columns: 1fr 1fr; gap: 12px; }
  .lstep:last-child { grid-column: span 2; }
  .lstep:last-child .lstep__art { max-width: 260px; margin: 0 auto; }
  .lstep h3 { font-size: 18px; }
  .lstep p { font-size: 14px; }
}

/* ---------- function table (datasheet) ---------- */
.ftable {
  margin: 0 var(--rail) 34px;
  border-collapse: collapse;
  font-family: var(--font-mono); font-size: 12.5px;
  background: var(--panel);
}
@media (min-width: 1100px) {
  .ftable { margin-left: auto; margin-right: auto; transform: translateX(0); width: 980px; max-width: calc(100% - 2 * var(--rail)); }
}
.ftable caption {
  caption-side: top; text-align: left;
  font-family: var(--font-body); font-weight: 700; font-size: 12px;
  text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--ink); padding-bottom: 8px;
}
.ftable th, .ftable td {
  border: 1.5px solid var(--ink);
  padding: 9px 18px; text-align: left;
}
.ftable th {
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
  background: rgba(21, 23, 26, 0.05);
}
.ftable td:last-child { color: var(--accent); }

/* ---------- terminal ---------- */
.playground { background: var(--bg-soft); border-top: 1px solid var(--panel-edge); border-bottom: 1px solid var(--panel-edge); }
.terminal {
  margin: 0 var(--rail); max-width: 980px;
  background: #17120d; border: 1px solid rgba(21, 23, 26, 0.55); border-radius: 14px;
  box-shadow: 0 36px 70px -28px rgba(19, 40, 120, 0.35);
  overflow: hidden;
}
@media (min-width: 1100px) { .terminal { margin-inline: auto; } }
.terminal__bar {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 18px; border-bottom: 1px solid rgba(255, 240, 220, 0.08);
  background: rgba(255, 240, 220, 0.04);
}
.terminal__dot { width: 11px; height: 11px; border-radius: 50%; }
.terminal__dot--r { background: #ff5f57; }
.terminal__dot--y { background: #febc2e; }
.terminal__dot--g { background: #28c840; }
.terminal__title {
  margin-left: 12px; font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-faint);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.terminal__live {
  margin-left: auto; display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em; color: var(--accent);
}
.terminal__body {
  padding: clamp(18px, 3vw, 30px); font-family: var(--font-mono);
  font-size: clamp(12.5px, 1.5vw, 14.5px); line-height: 1.9;
  min-height: 320px;
}
.t-line { opacity: 0; transform: translateY(8px); overflow-wrap: anywhere; }
.t-line.is-on { opacity: 1; transform: none; transition: opacity 0.4s, transform 0.4s; }
.t-prompt { color: var(--ink-faint); margin-right: 8px; }
.t-line--user { color: #f2ece2; }
.t-line--agent { color: var(--accent-2); }
.t-line--file { color: #a89c8b; }
.t-line--build { color: #a89c8b; }
.t-line--serial { color: #e0a763; }
.t-dim { color: var(--ink-faint); }
.t-ok { color: var(--accent); }
.t-caret {
  display: inline-block; width: 8px; height: 15px; vertical-align: -2px;
  background: var(--accent); animation: caret 1s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }
.playground__note {
  padding: 26px var(--rail) clamp(80px, 10vw, 130px);
  font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.06em;
  color: var(--ink-faint); max-width: 980px;
}
@media (min-width: 1100px) { .playground__note { margin-inline: auto; padding-left: 0; padding-right: 0; max-width: 980px; } }

/* ---------- operating principles: four spec-card compartments ---------- */
/* Each principle gets its own datasheet card (mono index + headline + fact)
   so the section scans instead of reading as a flat list. The fourth card
   is the "0 guesses" result, in the accent fill. */
/* centered layout for the accuracy + loop sections (Replit-style) */
.features .section-head, .loop .section-head { margin-inline: auto; text-align: center; max-width: 880px; }
.features .section-head__kicker { justify-content: center; }
.features .section-head__kicker::after { display: none; }
.features .section-head__sub, .loop .section-head__sub { margin-inline: auto; }
/* bigger headings, pulled up */
.loop .section-head, .features .section-head { padding-top: clamp(38px, 5vw, 62px); }
.loop .section-head__title, .features .section-head__title { font-size: clamp(38px, 6.2vw, 78px); line-height: 1.02; }

.principles {
  padding: 0 var(--rail) clamp(70px, 9vw, 120px);
  margin-inline: auto;
  display: grid; grid-template-columns: repeat(12, 1fr);
  gap: 16px; max-width: 1160px;
}
.principle {
  position: relative; overflow: hidden;
  background: var(--panel); border: 1.5px solid var(--panel-edge);
  border-radius: 28px; padding: clamp(26px, 3vw, 40px);
  display: flex; flex-direction: column; gap: 14px;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.principle:hover { transform: translateY(-5px); }
/* bento spans — big/small alternation like the reference */
.principle--lg   { grid-column: span 7; }
.principle--tint { grid-column: span 5; background: #edf1ff; border-color: transparent; }
.principle--dark { grid-column: span 5; background: var(--ink); border-color: transparent; }
.principle--mark { grid-column: span 7; background: var(--accent); border-color: transparent; justify-content: space-between; }

.principle__idx {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent);
}
.principle__head {
  font-family: var(--font-body); font-weight: 800;
  font-size: clamp(26px, 3vw, 40px); letter-spacing: -0.02em;
  line-height: 1.03; color: var(--ink);
}
.principle__body { color: var(--ink-dim); font-size: 15.5px; line-height: 1.55; max-width: 42ch; }

/* dark "unknowns" card recolors */
.principle--dark .principle__idx { color: #8aa0ff; }
.principle--dark .principle__head { color: #fff; }
.principle--dark .principle__body { color: #aab2c5; }

/* datasheets card: text block + inline spec excerpt */
.principle--lg .principle__txt { display: flex; flex-direction: column; gap: 12px; }
.principle__spec {
  margin-top: auto; display: grid;
  font-family: var(--font-mono); font-size: 13px;
  border: 1.5px solid var(--panel-edge); border-radius: 14px; overflow: hidden;
  background: var(--bg-soft);
}
.principle__spec span {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 10px 16px; color: var(--ink-dim);
  border-top: 1px solid var(--panel-edge);
}
.principle__spec span:first-child { border-top: 0; }
.principle__spec em { font-style: normal; color: var(--accent); font-weight: 700; }

/* math card: inline calc chip */
.principle__calc {
  margin-top: auto; align-self: flex-start;
  font-family: var(--font-mono); font-size: 13.5px; color: var(--ink);
  background: #fff; border: 1.5px solid rgba(19, 66, 255, 0.25);
  border-radius: 11px; padding: 9px 15px;
}
.principle__calc em { font-style: normal; color: var(--accent); font-weight: 700; }

/* result card: oversized mark on cobalt */
.principle--mark .principle__idx { color: rgba(255, 255, 255, 0.72); }
.principle__bignum {
  font-family: var(--font-body); font-weight: 800;
  font-size: clamp(60px, 9vw, 124px); line-height: 0.88;
  letter-spacing: -0.04em; color: #fff;
}
.principle__bignum em { font-style: normal; color: rgba(255, 255, 255, 0.5); }

@media (max-width: 860px) {
  .principles { grid-template-columns: 1fr; }
  .principle--lg, .principle--tint, .principle--dark, .principle--mark { grid-column: 1 / -1; }
}

/* ---------- stats ---------- */
.stats {
  border-top: 1px solid var(--panel-edge); border-bottom: 1px solid var(--panel-edge);
  background: var(--bg-soft);
}
.stats__label {
  display: flex; align-items: baseline; gap: 14px;
  max-width: 1280px; margin: 0 auto;
  padding: clamp(28px, 4vw, 44px) var(--rail) 0;
  font-family: var(--font-body); font-weight: 700; font-size: 16px;
  letter-spacing: 0.02em; text-transform: lowercase; color: var(--ink);
}
.stats__grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  max-width: 1280px; margin: 0 auto;
}
.stat {
  padding: clamp(40px, 6vw, 70px) 24px; text-align: center;
  border-left: 1px solid var(--panel-edge);
}
.stat:first-child { border-left: 0; }
.stat__num {
  font-family: var(--font-mag); font-weight: 800;
  font-size: clamp(44px, 6vw, 80px); line-height: 1; color: var(--accent);
}
.stat__label {
  margin-top: 12px; font-family: var(--font-mono); font-size: 12.5px;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint);
}

/* ---------- CTA ---------- */
.cta {
  position: relative; text-align: center;
  padding: clamp(36px, 5vw, 72px) var(--rail) clamp(96px, 13vw, 180px);
  overflow: hidden;
}
.cta__glow {
  position: absolute; left: 50%; top: 55%;
  width: 90vmax; height: 60vmax; transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(19, 66, 255, 0.1), transparent 65%);
  pointer-events: none;
}
.cta__title {
  position: relative;
  font-family: var(--font-mag); font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(32px, 5.6vw, 74px); line-height: 1.04; letter-spacing: -0.025em;
}
.cta__accent { color: var(--accent); }
.cta__sub { position: relative; margin-top: 24px; color: var(--ink-dim); font-size: 18px; }
.cta__form {
  position: relative;
  margin: 38px auto 0; max-width: 520px;
  display: flex; gap: 10px;
}
.cta__form input {
  flex: 1; min-width: 0;
  background: rgba(21, 23, 26,0.04); border: 1px solid var(--panel-edge);
  border-radius: 10px; padding: 16px 24px;
  color: var(--ink); font-family: var(--font-body); font-size: 16px;
  outline: none; transition: border-color 0.25s;
}
.cta__form input::placeholder { color: var(--ink-faint); }
.cta__form input:focus { border-color: rgba(19, 66, 255, 0.5); }
.cta__fine {
  position: relative; margin-top: 20px;
  font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-faint);
}
/* ---------- footer (datasheet back page) ---------- */
.footer { position: relative; border-top: 1px solid var(--panel-edge); background: var(--bg-soft); padding-bottom: 40px; }
.footer__inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 22px;
  padding: 52px var(--rail) 20px;
  /* thick datasheet rule under the logo row, matching the nav bar */
  border-bottom: 4px solid var(--ink);
}
.footer__logo {
  font-family: var(--font-logo); font-weight: 400; font-size: 24px;
  letter-spacing: 0; color: var(--ink);
}
.footer__logo em { color: var(--accent); }
.footer__links { display: flex; flex-wrap: wrap; gap: 24px; font-size: 14px; color: var(--ink-dim); }
.footer__links a:hover { color: var(--accent); }
.footer__copy { margin-left: auto; font-family: var(--font-mono); font-size: 12px; color: var(--ink-faint); }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat { border-top: 1px solid var(--panel-edge); }
  .stat:nth-child(-n + 2) { border-top: 0; }
}

@media (max-width: 920px) {
  .nav__links, .nav__signin { display: none; }
  .nav__burger { display: block; }
}

@media (max-width: 760px) {
  .nav__actions .btn--solid { font-size: 11.5px; padding: 10px 14px; }
  .hero { padding-bottom: 90px; }
  .hero::before { width: 16px; height: 90px; }
  .nav { border-bottom-width: 3px; }
  .nav__logo { font-size: 22px; }
  .masthead { flex-direction: column; gap: 10px; }
  .masthead__head { text-align: left; }
  .masthead__title { font-size: 12px; }
  .masthead__strap { font-size: 9.5px; letter-spacing: 0.2em; }
  .ftable { font-size: 11px; }
  .ftable th, .ftable td { padding: 7px 10px; }
  .hero__scroll { display: none; }
  .hero__cta .btn { width: 100%; justify-content: center; }
  .cta__form { flex-direction: column; }
  .cta__form .btn { width: 100%; justify-content: center; }
  .footer__copy { margin-left: 0; }
  .terminal__body { min-height: 0; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  html { scroll-behavior: auto; }
  .t-line { opacity: 1; transform: none; }
  .hero__line > span, .split-words .w > span { transform: none !important; opacity: 1 !important; }
  .wb [data-step], .wb-caret, .wb-dots i, .wb__playfield { opacity: 1 !important; animation: none !important; }
}

/* ============ WORKBENCH MOCKUP ============ */
/* tinted "stage" the workbench rises from, Kiro-style peek above the fold */
.wbsec {
  padding: clamp(28px, 4vw, 56px) var(--rail) clamp(50px, 8vw, 100px);
  background: linear-gradient(180deg, rgba(19, 66, 255, 0.06), rgba(19, 66, 255, 0) 60%), var(--bg-soft);
  border-top: 1px solid var(--panel-edge);
  border-radius: 28px 28px 0 0;
}
.wbsec__cue {
  text-align: center; margin-bottom: 18px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--accent);
}

/* the app window — dark, like the real product on the light page */
.wb {
  --wb-bg: #0c0e13; --wb-panel: #12151c; --wb-edge: rgba(255,255,255,0.08);
  --wb-ink: #e7ecf4; --wb-dim: #8b94a6; --wb-faint: #5d6677;
  --wb-green: #3fb950; --wb-cobalt: #6b9bff; --wb-orange: #ff8a3c;
  max-width: 1288px; margin: 0 auto;
  background: var(--wb-bg); color: var(--wb-ink);
  border: 1px solid var(--wb-edge); border-radius: 16px; overflow: hidden;
  box-shadow: 0 40px 90px -40px rgba(19,40,120,0.45), 0 0 0 1px rgba(19,66,255,0.04);
  font-size: 13px;
}
.wb__bar {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 16px; border-bottom: 1px solid var(--wb-edge);
  background: #0e1118;
}
.wb__chip { color: var(--wb-green); }
.wb__proj { font-weight: 700; }
.wb__crumb { color: var(--wb-faint); font-family: var(--font-mono); font-size: 11px; }
.wb__badge {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em;
  color: #c7b3ff; border: 1px solid rgba(160,140,255,0.4); border-radius: 5px; padding: 3px 7px;
}
.wb__bar-spacer { flex: 1; }
.wb__board { color: var(--wb-dim); font-size: 11.5px; border: 1px solid var(--wb-edge); border-radius: 6px; padding: 4px 9px; }
.wb__avatar {
  width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent); color: #fff; font-size: 10px; font-weight: 700;
}
.wb__body { display: grid; grid-template-columns: 38% 62%; min-height: 460px; }

/* chat */
.wb__chat { display: flex; flex-direction: column; border-right: 1px solid var(--wb-edge); min-width: 0; }
.wb__chat-head {
  display: flex; justify-content: space-between; padding: 10px 16px;
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.16em; color: var(--wb-faint);
  border-bottom: 1px solid var(--wb-edge);
}
.wb__copy { color: var(--wb-dim); }
.wb__feed { flex: 1; padding: 16px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.wb [data-step] { opacity: 0; }
.wb-msg.wb-user {
  align-self: flex-end; max-width: 85%;
  background: var(--accent); color: #fff; border-radius: 12px 12px 4px 12px;
  padding: 10px 14px; line-height: 1.45;
}
.wb-think { display: flex; align-items: center; gap: 8px; color: var(--wb-dim); font-style: italic; }
.wb-spark { color: var(--accent); font-style: normal; }
.wb-dots { display: inline-flex; gap: 3px; }
.wb-dots i { width: 4px; height: 4px; border-radius: 50%; background: var(--wb-dim); animation: wbDot 1.4s infinite; }
.wb-dots i:nth-child(2) { animation-delay: 0.2s; }
.wb-dots i:nth-child(3) { animation-delay: 0.4s; }
@keyframes wbDot { 0%,60%,100% { opacity: 0.25; } 30% { opacity: 1; } }

.wb-card { background: var(--wb-panel); border: 1px solid var(--wb-edge); border-radius: 10px; overflow: hidden; }
.wb-card__bar {
  display: flex; align-items: center; gap: 8px; padding: 9px 12px;
  border-bottom: 1px solid var(--wb-edge); font-family: var(--font-mono); font-size: 12px;
}
.wb-card__ico { color: var(--wb-green); }
.wb-card__ico--spin { color: var(--wb-cobalt); display: inline-block; animation: wbSpin 1.1s linear infinite; }
@keyframes wbSpin { to { transform: rotate(360deg); } }
.wb-card__lines { margin-left: auto; color: var(--wb-faint); font-size: 10.5px; }
.wb-card__code {
  margin: 0; padding: 11px 13px; font-family: var(--font-mono); font-size: 11.5px; line-height: 1.7;
  color: var(--wb-dim); white-space: pre; overflow: hidden;
}
.c-key { color: var(--wb-cobalt); } .c-str { color: #6fd1a6; } .c-num { color: var(--wb-orange); }
.c-id { color: #4ec9b0; } .c-cmt { color: var(--wb-faint); } .c-pun { color: #9aa3b5; } .c-dim { color: var(--wb-dim); }
.wb-caret { color: var(--accent); animation: wbBlink 1s steps(1) infinite; }
@keyframes wbBlink { 50% { opacity: 0; } }

.wb__input { border-top: 1px solid var(--wb-edge); padding: 12px 16px; }
.wb__input-ph { color: var(--wb-faint); }
.wb__input-row { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.wb__pill {
  font-family: var(--font-mono); font-size: 10.5px; color: var(--wb-dim);
  border: 1px solid var(--wb-edge); border-radius: 6px; padding: 4px 9px;
}
.wb__pill--on { color: var(--wb-ink); border-color: rgba(160,140,255,0.4); }
.wb__stop { width: 22px; height: 22px; border-radius: 6px; background: #b3372e; margin-left: auto; }

/* simulator */
.wb__sim { display: flex; flex-direction: column; min-width: 0; background: #0a0c11; }
.wb__sim-tabs { display: flex; align-items: center; gap: 14px; padding: 10px 16px; border-bottom: 1px solid var(--wb-edge); }
.wb__tab { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; color: var(--wb-faint); }
.wb__tab--on { color: var(--wb-ink); }
.wb__status {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.14em; color: var(--wb-dim);
  border: 1px solid var(--wb-edge); border-radius: 99px; padding: 2px 9px;
}
.wb__status.is-run { color: var(--wb-green); border-color: rgba(63,185,80,0.5); }
.wb__status.is-compile { color: var(--wb-orange); border-color: rgba(255,138,60,0.55); }
.wb__run.is-compile { background: transparent; color: var(--wb-orange); border: 1px solid rgba(255,138,60,0.6); }
.wbspin { display: inline-block; animation: wbSpin 1.1s linear infinite; }
.wb__zoom { font-family: var(--font-mono); font-size: 11px; color: var(--wb-faint); }
.wb__run {
  font-family: var(--font-mono); font-size: 12px; font-weight: 700;
  background: var(--wb-green); color: #06210b; border-radius: 7px; padding: 5px 14px;
}
.wb__run.is-run { background: var(--wb-orange); color: #2a1404; }
.wb__canvas {
  flex: 1; display: flex; gap: 18px; padding: 22px;
  background:
    radial-gradient(circle at 1px 1px, rgba(255,255,255,0.05) 1px, transparent 0) 0 0 / 22px 22px;
}
.wb__device { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.wb__oled {
  position: relative; width: 116px; height: 232px; border-radius: 10px;
  background: #070a10; border: 1px solid var(--wb-edge); overflow: hidden;
}
.wb__oled-off { position: absolute; inset: 0; display: grid; place-items: center; color: var(--wb-faint); font-size: 11px; transition: opacity 0.4s; }
.wb__playfield {
  position: absolute; inset: 6px; opacity: 0;
  display: grid; grid-template-columns: repeat(10, 1fr); grid-template-rows: repeat(20, 1fr); gap: 1px;
  transition: opacity 0.4s;
}
.wb__playfield i { border-radius: 1px; }
.wb__playfield i.on { background: var(--wb-cobalt); box-shadow: 0 0 4px rgba(107,155,255,0.7); }
.wb__playfield i.hot { background: var(--wb-orange); box-shadow: 0 0 5px rgba(255,138,60,0.8); }
.wb__pins { font-family: var(--font-mono); font-size: 9.5px; color: var(--wb-faint); letter-spacing: 0.04em; }
.wb__btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-content: start; flex: 1; }
.wb-btn {
  border: 1px solid var(--wb-edge); border-radius: 9px; padding: 12px 12px 10px; background: var(--wb-panel);
  display: flex; flex-direction: column; gap: 4px; transition: border-color 0.2s, box-shadow 0.2s, transform 0.1s;
}
.wb-btn span { font-family: var(--font-mono); font-size: 9.5px; color: var(--wb-faint); letter-spacing: 0.08em; }
.wb-btn em { font-style: normal; color: var(--wb-dim); font-size: 12.5px; }
.wb-btn.is-hit { border-color: var(--wb-orange); box-shadow: 0 0 0 1px var(--wb-orange), 0 0 16px -4px var(--wb-orange); transform: translateY(1px); }
.wb-btn.is-hit em { color: var(--wb-ink); }

.wb__serial { border-top: 1px solid var(--wb-edge); }
.wb__serial-head {
  display: flex; align-items: center; gap: 10px; padding: 8px 16px;
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.14em; color: var(--wb-faint);
}
.wb__serial-out {
  margin: 0; padding: 0 16px 14px; font-family: var(--font-mono); font-size: 11px; line-height: 1.7;
  color: #8fb9ff; height: 78px; overflow: hidden; white-space: pre-wrap;
}
.wb__serial-out .c-ok { color: var(--wb-green); }

@media (max-width: 860px) {
  .wb__body { grid-template-columns: 1fr; }
  .wb__chat { border-right: 0; border-bottom: 1px solid var(--wb-edge); }
  .wb__feed { max-height: 360px; }
  .wb__crumb, .wb__board { display: none; }
}
