/* =====================================================================
   Unbuilt Lab — GLOBAL THEME (Radar design system)
   Loaded LAST on every page: canonical tokens + typography guarantees
   so every surface shares one visual system. 2026-07-12 Workstream C.
   ===================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600&family=Instrument+Serif:ital@0;1&family=DM+Sans:ital,opsz,wght@0,9..40,300..700;1,9..40,300..700&display=swap');

:root {
  /* canonical Radar palette — space-navy · indigo · electric-cyan */
  --bg-primary: #05070f;
  --bg-elevated: #090c18;
  --bg-card: #0d1120;
  --bg-card-hover: #131a30;
  --text-primary: #f1f3fa;
  --text-secondary: #97a0bd;
  --text-muted: #5d6683;
  --accent: #6366f1;
  --accent-soft: rgba(99, 102, 241, 0.15);
  --accent-glow: rgba(99, 102, 241, 0.3);
  --accent-secondary: #22d3ee;
  --emerald: #34d399;
  --emerald-soft: rgba(52, 211, 153, 0.12);
  --amber: #fbbf24;
  --border: rgba(241, 243, 250, 0.08);
  --border-accent: rgba(99, 102, 241, 0.24);
  --surface-glow: rgba(99, 102, 241, 0.08);
  --font-display: 'Space Grotesk', 'DM Sans', sans-serif;
  --font-serif: 'Instrument Serif', Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --font-body: 'DM Sans', -apple-system, sans-serif;
}

html { background-color: #05070f; }
body { background-color: #05070f; }

/* one heading voice everywhere */
h1, h2, h3, h4 {
  font-family: 'Space Grotesk', 'DM Sans', -apple-system, sans-serif;
  letter-spacing: -0.02em;
}
h1 em, h2 em, h3 em {
  font-family: 'Instrument Serif', Georgia, serif;
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
}

::selection { background: rgba(99, 102, 241, 0.45); color: #fff; }

/* scrollbar */
* { scrollbar-width: thin; scrollbar-color: rgba(99, 102, 241, 0.4) rgba(9, 12, 24, 0.6); }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: rgba(9, 12, 24, 0.6); }
*::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(99, 102, 241, 0.5), rgba(34, 211, 238, 0.4));
  border-radius: 6px;
}

:focus-visible { outline: 2px solid rgba(34, 211, 238, 0.6); outline-offset: 2px; }

/* =====================================================================
   UNIFICATION SCAFFOLD v2 — maps every page family's existing markup
   onto ONE layout system: page-head, kicker, card recipe, buttons.
   Families: features · support · legal · newsletter · blog (index+posts)
   · learn/* · free/* · tools · case-studies. Loads last → wins.
   ===================================================================== */

/* ---------- 1. one KICKER voice (mono, cyan, tracked) ---------- */
.eyebrow, .csi-eyebrow, .hero-eyebrow, .learn-eyebrow,
.card-eyebrow, .pillar-tag, .blog-card-tag, .post-meta .published-on {
  font-family: 'JetBrains Mono', ui-monospace, monospace !important;
  font-size: 0.7rem !important;
  font-weight: 500 !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  color: #22d3ee !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
}

/* ---------- 2. one PAGE-HEAD scale ---------- */
main > .container > h1, .container > h1,
.blog-hero h1, .section-hero h1, .csi-hero h1,
.hero-title, .learn-hero h1, .glossary-hero h1 {
  font-family: 'Space Grotesk', 'DM Sans', sans-serif !important;
  font-size: clamp(2.1rem, 4.6vw, 3.1rem) !important;
  font-weight: 700 !important;
  line-height: 1.08 !important;
  letter-spacing: -0.03em !important;
}
.lede, .subtitle, .hero-sub, .blog-hero p, .csi-hero p,
.section-hero .lede, .signup-sub {
  color: #97a0bd !important;
  font-size: 1.05rem !important;
  line-height: 1.7 !important;
}
.last-updated, .reading-time, .article-meta, .post-meta {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: #5d6683;
}

/* back-links + breadcrumbs → one pill voice */
.back-link, .breadcrumb, .breadcrumbs {
  font-family: 'JetBrains Mono', ui-monospace, monospace !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.06em !important;
  color: #97a0bd !important;
}
.back-link {
  display: inline-flex !important; align-items: center; gap: 6px;
  border: 1px solid rgba(241,243,250,0.1) !important;
  border-radius: 999px !important;
  padding: 7px 15px !important;
  background: rgba(13,17,32,0.6) !important;
  text-decoration: none !important;
  transition: border-color .2s, color .2s;
}
.back-link:hover { color: #f1f3fa !important; border-color: rgba(99,102,241,0.45) !important; }
.breadcrumbs a, .breadcrumb a { color: #22d3ee !important; text-decoration: none; }

/* ---------- 3. one CARD recipe ---------- */
.card, .faq-item, .sample-card, .signup-card, .form-card,
.pillar-card, .blog-card, .csi-card, .learn-article .article-tldr,
.free-page .card, .learn-page .card {
  background: linear-gradient(180deg, #0e1224, #090c18) !important;
  border: 1px solid rgba(241, 243, 250, 0.08) !important;
  border-radius: 20px !important;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease !important;
}
.card:hover, .faq-item:hover, .sample-card:hover,
.pillar-card:hover, .blog-card:hover, .csi-card:hover,
.free-page .card:hover, .learn-page .card:hover {
  transform: translateY(-4px);
  border-color: rgba(99, 102, 241, 0.42) !important;
  box-shadow: 0 22px 60px -20px rgba(99, 102, 241, 0.35) !important;
}
/* cards with images keep their media flush */
.pillar-card img, .blog-card img { border-radius: 20px 20px 0 0 !important; }

/* FAQ items were a flat list (padding: 20px 0, border-bottom separators)
   before becoming cards — give them proper card padding + spacing. */
.faq-item {
  padding: 4px 26px !important;
  margin-bottom: 12px !important;
  border-bottom: 1px solid rgba(241, 243, 250, 0.08) !important; /* recipe border, all sides */
}
.faq-item .faq-answer { padding-bottom: 22px !important; padding-right: 8px; }

/* card titles → Grotesk */
.card-title, .faq-question, .pillar-card h3, .pillar-card h2,
.blog-card h3, .blog-card h2, .csi-card h3, .card h2, .card h3,
.signup-headline, .result-title {
  font-family: 'Space Grotesk', 'DM Sans', sans-serif !important;
  letter-spacing: -0.015em !important;
}

/* ---------- 4. one BUTTON recipe ---------- */
.sample-cta, .submit-btn, .signup-btn, .csi-card-link,
.card-cta, .read-more {
  font-family: 'Space Grotesk', 'DM Sans', sans-serif !important;
  font-weight: 600 !important;
}
.submit-btn, .signup-btn {
  background: linear-gradient(135deg, #6366f1, #4f46e5) !important;
  border: 0 !important;
  border-radius: 12px !important;
  color: #fff !important;
  box-shadow: 0 10px 30px -10px rgba(99, 102, 241, 0.6) !important;
  transition: transform .16s ease, box-shadow .16s ease !important;
}
.submit-btn:hover, .signup-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 42px -10px rgba(99, 102, 241, 0.75) !important;
}

/* ---------- 5. links + inline accents ---------- */
main a:not([class]), article a:not([class]), .faq-answer a, .card p a {
  color: #22d3ee;
}

/* ---------- 6. site-wide scroll reveal (progressive: .trv added by JS) ---------- */
.trv {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s cubic-bezier(.2,.7,.25,1), transform .7s cubic-bezier(.2,.7,.25,1);
}
.trv.trv-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .trv { opacity: 1 !important; transform: none !important; transition: none !important; }
}
