/* =========================================================================
   KI-Sprint — premium dark SaaS design system
   Modeled on Reforge (near-black base, one indigo accent, grey logo-row
   social proof, zero noise) + Superhuman (atmospheric gradient hero with
   floating interface cards, cinematic depth). Single font family (Inter),
   single global accent — no per-page hue swap, only hero atmosphere tint
   varies via body.theme-*.
   ========================================================================= */

:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* base surfaces — near-black premium, Reforge-style */
  --dark: #08080a;
  --bg: #0b0b0e;
  --bg-alt: #101013;
  --surface: #151519;
  --surface-2: #1b1b21;
  --surface-tint: #17171c;
  --border: rgba(255, 255, 255, 0.1);
  --border-soft: rgba(255, 255, 255, 0.06);

  --ink: #f5f5f7;
  --ink-soft: #cbccd3;
  --muted: #91929c;
  --faint: #5b5c66;

  /* legacy on-dark aliases kept so existing markup (hero/footer) still works */
  --on-dark: #f5f5f7;
  --on-dark-muted: rgba(245, 245, 247, 0.64);
  --on-dark-faint: rgba(245, 245, 247, 0.4);

  /* single global accent — soft indigo/periwinkle */
  --accent: #8886ff;
  --accent-dark: #5f5cf0;
  --accent-ink: #d3d2ff;
  --accent-soft: rgba(136, 134, 255, 0.14);
  --accent-soft-2: rgba(136, 134, 255, 0.26);

  --good: #34d399;
  --bad: #f87171;

  --radius-xl: 22px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-soft: 0 40px 90px -40px rgba(0, 0, 0, 0.75);
  --shadow-card: 0 26px 60px -32px rgba(0, 0, 0, 0.6);
}

/* hero atmosphere tint per page — colour of the blurred aura only,
   NOT the UI accent (buttons/links/icons stay the single global indigo) */
body.theme-neutral { --aura-1: #6d6af6; --aura-2: #c9679a; --aura-3: #3a3ef2; }
body.theme-b2b     { --aura-1: #5f7bf6; --aura-2: #46c2c2; --aura-3: #2e3ef0; }
body.theme-b2c     { --aura-1: #8a6af6; --aura-2: #f0a86a; --aura-3: #d1548f; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink-soft);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; color: var(--ink); }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 780px; }
.container--mid { max-width: 940px; }

@media (min-width: 768px) { .container { padding: 0 40px; } }

/* grain texture dropped — clean flat surfaces match the reference sites */
.grain { display: none; }

/* ---------- type ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.1rem;
}
.eyebrow::before {
  content: '';
  width: 22px;
  height: 1px;
  background: currentColor;
  opacity: 0.55;
}
.eyebrow--light { color: var(--accent); opacity: 0.95; }

h1, .h1 {
  font-weight: 700;
  font-size: clamp(2.4rem, 1.5rem + 3.6vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}
h1 em, .h1 em { font-style: normal; font-weight: 700; color: var(--accent); }
h1.on-dark, .h1.on-dark { color: var(--on-dark); }

h2, .h2 {
  font-weight: 700;
  font-size: clamp(1.8rem, 1.4rem + 1.6vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.025em;
}
h2.on-dark { color: var(--on-dark); }

h3, .h3 {
  font-weight: 700;
  font-size: 1.08rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.lede { font-size: clamp(1.03rem, 0.98rem + 0.3vw, 1.2rem); line-height: 1.65; color: var(--ink-soft); }
.lede.on-dark { color: var(--on-dark-muted); }
p.on-dark { color: var(--on-dark-muted); }

.section-head { max-width: 620px; margin: 0 0 3.2rem; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { margin-top: 1rem; font-size: 1.05rem; color: var(--muted); }

.pill-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.38rem 0.85rem;
  border-radius: 999px;
  background: var(--accent-dark);
  color: #fff;
}
.pill-tag--soft { background: var(--accent-soft); color: var(--accent-ink); }
.pill-tag--note { background: rgba(255, 255, 255, 0.06); color: var(--muted); border: 1px solid var(--border); }

/* ---------- sections — everything lives on the dark base now ---------- */
section { position: relative; }
.py { padding: 6.5rem 0; }
.py-lg { padding: 8.5rem 0; }
.py-sm { padding: 3.4rem 0; }
.bg-alt { background: var(--bg-alt); }
.bg-surface { background: var(--bg); }
.divider-top { border-top: 1px solid var(--border-soft); }
.divider-y { border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); }

.dark-section { background: var(--dark); }
.dark-section h2, .dark-section h3 { color: var(--on-dark); }

/* ---------- nav — dark glass pill ---------- */
.nav-wrap { position: fixed; top: 0; inset-inline: 0; z-index: 100; display: flex; justify-content: center; padding-top: 18px; pointer-events: none; }
.nav {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 2rem;
  width: 100%;
  max-width: min(940px, calc(100vw - 32px));
  background: rgba(11, 11, 14, 0.72);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.5rem 0.6rem 0.5rem 1.3rem;
  box-shadow: 0 24px 50px -28px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.nav-brand { display: flex; align-items: center; gap: 0.6rem; font-weight: 700; font-size: 1.05rem; color: var(--ink); flex-shrink: 0; letter-spacing: -0.01em; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--accent-dark); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.nav-links { display: none; align-items: center; gap: 1.9rem; font-size: 0.88rem; font-weight: 600; color: var(--ink-soft); margin: 0 auto; }
.nav-links a { transition: color 0.3s var(--ease); white-space: nowrap; }
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--accent); }
.nav-cta { display: none; flex-shrink: 0; }
.nav-toggle { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 50%; border: none; background: transparent; color: var(--ink); margin-left: auto; }
@media (min-width: 900px) {
  .nav-links { display: flex; }
  .nav-cta { display: inline-flex; }
  .nav-toggle { display: none; }
}
.nav-mobile {
  pointer-events: auto;
  display: none;
  margin-top: 10px;
  width: calc(100vw - 32px);
  max-width: 420px;
  background: rgba(11, 11, 14, 0.96);
  backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.1rem 1.3rem;
  box-shadow: var(--shadow-soft);
}
.nav-mobile.open { display: block; }
.nav-mobile a { display: block; padding: 0.65rem 0.2rem; font-weight: 600; color: var(--ink-soft); border-bottom: 1px solid var(--border-soft); font-size: 0.95rem; }
.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile a.cta { color: var(--accent); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 0.6rem 0.85rem 1.55rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.92rem;
  border: none;
  transition: transform 0.5s var(--ease), background 0.4s var(--ease), box-shadow 0.4s var(--ease), color 0.3s var(--ease);
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-arrow { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: transform 0.5s var(--ease); }
.btn:hover .btn-arrow { transform: translateX(3px); }
.btn-primary { background: var(--accent-dark); color: #fff; box-shadow: 0 16px 34px -14px var(--accent-soft-2); }
.btn-primary .btn-arrow { background: rgba(255, 255, 255, 0.18); }
.btn-primary:hover { background: #4c49df; }
.btn-ghost-dark { background: transparent; color: var(--on-dark); border: 1.5px solid rgba(245, 245, 247, 0.22); padding: 0.83rem 1.5rem; }
.btn-ghost-dark:hover { background: rgba(245, 245, 247, 0.06); border-color: rgba(245, 245, 247, 0.4); }
.btn-outline { background: transparent; color: var(--ink); border: 1.5px solid var(--border); padding: 0.83rem 1.5rem; }
.btn-outline:hover { background: rgba(255, 255, 255, 0.04); border-color: var(--accent); color: var(--accent); }
.btn-block { display: flex; width: 100%; justify-content: center; }
.btn-sm { padding: 0.6rem 1.2rem; font-size: 0.84rem; }

/* ---------- double-bezel card ---------- */
.bezel {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-soft);
  border-radius: calc(var(--radius-lg) + 6px);
  padding: 6px;
}
.bezel-inner {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 2.3rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), var(--shadow-card);
  height: 100%;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.9rem;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease), border-color 0.5s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card); border-color: rgba(136, 134, 255, 0.35); }

.icon-tile {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 1.3rem;
}
.icon-tile svg { width: 21px; height: 21px; }
.icon-circle {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 0.92rem;
  background: var(--accent-dark); color: #fff;
  margin-bottom: 1.2rem;
}

/* ---------- grid ---------- */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-12 { grid-template-columns: repeat(12, 1fr); gap: 2rem; }
@media (max-width: 860px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } .grid-12 { grid-template-columns: 1fr; } }
@media (min-width: 640px) and (max-width: 860px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }

/* ---------- hero — Superhuman-style atmospheric gradient ---------- */
.hero { position: relative; overflow: hidden; padding: 9.5rem 0 5.5rem; }
.hero-aura { position: absolute; inset: 0; overflow: hidden; z-index: 0; }
.hero-aura::before, .hero-aura::after { content: ''; position: absolute; border-radius: 50%; filter: blur(110px); }
.hero-aura::before {
  width: 62vw; height: 62vw; max-width: 820px; max-height: 820px;
  background: radial-gradient(circle at 35% 35%, var(--aura-1, #6d6af6), transparent 70%);
  opacity: 0.34; top: -26%; left: -16%;
}
.hero-aura::after {
  width: 44vw; height: 44vw; max-width: 600px; max-height: 600px;
  background: radial-gradient(circle at 60% 40%, var(--aura-2, #c9679a), transparent 70%);
  opacity: 0.24; bottom: -22%; right: -10%;
}
.hero-aura__mid {
  position: absolute; z-index: 0;
  width: 34vw; height: 34vw; max-width: 460px; max-height: 460px;
  background: radial-gradient(circle, var(--aura-3, #3a3ef2), transparent 72%);
  filter: blur(100px); opacity: 0.22; top: 30%; left: 42%;
}
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr 0.85fr; gap: 3rem; align-items: center; }
@media (max-width: 940px) { .hero-grid { grid-template-columns: 1fr; } .hero-visual { margin-top: 3rem; } }
.hero-copy .lede { max-width: 46ch; margin: 1.5rem 0 2.4rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }

/* ---------- floating interface cards (replaces the old "seal" emblem) ---------- */
.hero-visual { position: relative; display: flex; align-items: center; justify-content: center; min-height: 380px; }
.float-stage { position: relative; width: min(420px, 92vw); height: 340px; }
.float-card {
  position: absolute;
  background: rgba(21, 21, 25, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  box-shadow: 0 30px 60px -24px rgba(0, 0, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  padding: 1.1rem 1.3rem;
  animation: float-bob 7s var(--ease) infinite;
  animation-delay: var(--fdelay, 0s);
}
@keyframes float-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-11px); }
}
.float-card__head { display: flex; align-items: center; gap: 0.55rem; margin-bottom: 0.7rem; }
.float-card__dot { width: 22px; height: 22px; border-radius: 7px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.float-card__dot svg { width: 12px; height: 12px; }
.float-card__label { font-size: 0.72rem; font-weight: 700; color: var(--muted); letter-spacing: 0.02em; }
.float-card__list { display: flex; flex-direction: column; gap: 0.55rem; }
.float-card__list li { display: flex; align-items: flex-start; gap: 0.5rem; font-size: 0.82rem; font-weight: 600; color: var(--ink-soft); line-height: 1.35; }
.float-card__list svg { width: 14px; height: 14px; margin-top: 2px; color: var(--good); flex-shrink: 0; }

.float-card--stat { display: flex; align-items: center; gap: 0.9rem; padding: 1rem 1.3rem; }
.float-ring { position: relative; width: 46px; height: 46px; flex-shrink: 0; }
.float-ring svg { width: 100%; height: 100%; }
.float-ring .ring-bg { fill: none; stroke: rgba(255, 255, 255, 0.1); stroke-width: 3; }
.float-ring .ring-fg { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; }
.float-card__big { font-size: 1.5rem; font-weight: 800; color: var(--ink); letter-spacing: -0.02em; line-height: 1; }
.float-card__small { font-size: 0.75rem; color: var(--muted); font-weight: 600; margin-top: 0.15rem; }

.float-pill {
  position: absolute;
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: rgba(21, 21, 25, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-radius: 999px;
  padding: 0.55rem 1rem 0.55rem 0.55rem;
  box-shadow: 0 24px 50px -24px rgba(0, 0, 0, 0.6);
  font-size: 0.78rem; font-weight: 700; color: var(--ink-soft);
  animation: float-bob 8s var(--ease) infinite;
  animation-delay: var(--fdelay, 0s);
}
.float-pill__icon { width: 26px; height: 26px; border-radius: 50%; background: var(--accent-dark); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.float-pill__icon svg { width: 13px; height: 13px; }

.card-a { top: 4%; left: 0; width: 240px; --fdelay: 0s; }
.card-b { bottom: 6%; right: 2%; width: 190px; --fdelay: 1.4s; }
.card-c { top: 46%; right: -4%; --fdelay: 2.6s; }
@media (max-width: 480px) {
  .card-a { left: 2%; width: 200px; }
  .card-b { right: 0; width: 170px; }
  .card-c { right: 4%; }
}

/* ---------- reveal-on-scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); filter: blur(6px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease), filter 0.9s var(--ease); transition-delay: var(--delay, 0ms); }
.reveal.in-view { opacity: 1; transform: none; filter: blur(0); }

/* ---------- monochrome trust/proof row (Reforge logo-row pattern) ---------- */
.stat-strip { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 2.2rem 3rem; }
.stat-strip .stat { display: flex; align-items: center; gap: 0.6rem; font-size: 0.86rem; font-weight: 600; color: var(--faint); letter-spacing: 0.01em; transition: color 0.3s var(--ease); }
.stat-strip .stat:hover { color: var(--muted); }
.stat svg { width: 17px; height: 17px; color: var(--faint); flex-shrink: 0; }
.note-line { text-align: center; font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); margin-bottom: 1.8rem; opacity: 0.8; }

/* ---------- pricing ---------- */
.price-card { position: relative; }
.price-card .featured-tag { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); }
.price-card.featured { border-color: rgba(136, 134, 255, 0.4); box-shadow: var(--shadow-card); }
.price-value { font-size: 2.3rem; font-weight: 800; color: var(--ink); margin: 0.4rem 0 0.2rem; letter-spacing: -0.02em; }
.price-note { font-size: 0.8rem; color: var(--muted); margin-bottom: 1.6rem; }
.check-list { display: flex; flex-direction: column; gap: 0.7rem; margin: 1.6rem 0 2rem; }
.check-list li { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 0.92rem; color: var(--ink-soft); }
.check-list svg { width: 16px; height: 16px; margin-top: 3px; color: var(--accent); flex-shrink: 0; }

/* ---------- forms ---------- */
.form-field { margin-bottom: 1.1rem; text-align: left; }
.form-field label { display: block; font-size: 0.85rem; font-weight: 700; color: var(--ink); margin-bottom: 0.4rem; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-tint);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.form-field input::placeholder, .form-field textarea::placeholder { color: var(--faint); }
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft);
}
.form-error { display: none; font-size: 0.78rem; color: var(--bad); margin-top: 0.35rem; }
.form-error.show { display: block; }
.form-success { display: none; font-size: 0.9rem; font-weight: 600; color: var(--good); background: rgba(52, 211, 153, 0.1); border: 1px solid rgba(52, 211, 153, 0.28); border-radius: 10px; padding: 0.9rem 1.1rem; margin-top: 1rem; }
.form-success.show { display: block; }

/* ---------- footer ---------- */
footer.site-footer { background: var(--dark); color: var(--on-dark-muted); padding: 4.5rem 0 2.5rem; border-top: 1px solid var(--border-soft); }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2.6rem; margin-bottom: 3rem; }
.footer-brand { font-size: 1.2rem; font-weight: 700; color: var(--on-dark); margin-bottom: 0.6rem; }
.footer-desc { max-width: 320px; font-size: 0.9rem; }
.footer-links { display: flex; gap: 1.8rem; font-size: 0.9rem; font-weight: 600; flex-wrap: wrap; }
.footer-links a:hover { color: var(--on-dark); }
.footer-legal { font-size: 0.78rem; color: var(--on-dark-faint); margin-top: 0.6rem; }
.footer-bottom { border-top: 1px solid rgba(245, 245, 247, 0.1); padding-top: 1.6rem; font-size: 0.76rem; color: var(--on-dark-faint); }

/* ---------- misc ---------- */
.center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.mt-6 { margin-top: 1.5rem; }
.mt-10 { margin-top: 2.6rem; }
.text-muted { color: var(--muted); }
.text-faint { color: var(--faint); font-size: 0.85rem; }
hr.rule { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }
