/* ============================================================
   ThreatRecall — Neural Dark brand theme
   Colors, typography, spacing per Neural Dark brand guide
   ============================================================ */

/* ── Palette ────────────────────────────────────────────── */
:root {
  --bg:         #0A0E17;
  --bg-card:    #161B22;
  --border:     #30363D;
  --accent:     #5EAE78;
  --accent-dim: #5EAE7818;
  --fg:         #C9D1D9;
  --fg-muted:   #8B949E;
  --link-hover: #58A6FF;

  /* code/token palette */
  --code-green:  #8ED1A0;
  --code-blue:   #79C0FF;
  --code-yellow: #E3B341;
  --code-muted:  #6B737D;

  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', monospace;

  --radius-card:   8px;
  --radius-input:  6px;
  --radius-inline: 4px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Typography scale ───────────────────────────────────── */
h1, h2, h3 {
  font-family: var(--font-sans);
  font-weight: 600;
  line-height: 1.25;
  color: var(--fg);
}

/* ── Navigation ─────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
  letter-spacing: -0.3px;
  text-decoration: none;
}
.nav-cta {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  padding: 7px 16px;
  border-radius: var(--radius-input);
  border: 1px solid var(--accent);
  color: var(--accent);
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}
.nav-cta:hover {
  border-color: var(--link-hover);
  color: var(--link-hover);
}

/* ── Hero ───────────────────────────────────────────────── */
.hero {
  max-width: 1200px;
  margin: 0 auto;
  padding: 128px 32px 80px;
}
.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-inline);
  padding: 5px 12px;
  margin-bottom: 32px;
}
.label-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}
.hero-headline {
  font-family: var(--font-sans);
  font-size: clamp(32px, 5.5vw, 52px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  max-width: 680px;
}
.hero-lede {
  font-size: 18px;
  color: var(--fg-muted);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 48px;
}

/* ── Terminal ────────────────────────────────────────────── */
.hero-terminal {
  background: #0D1117;
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  overflow: hidden;
  max-width: 680px;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: #161B22;
  border-bottom: 1px solid var(--border);
}
.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.terminal-dot:nth-child(1) { background: #FF5F57; }
.terminal-dot:nth-child(2) { background: #FEBC2E; }
.terminal-dot:nth-child(3) { background: #28C840; }
.terminal-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  margin-left: 8px;
}
.terminal-body { padding: 24px; }
.terminal-query {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
}
.terminal-prompt {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 16px;
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 2px;
}
.terminal-input {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--fg);
  line-height: 1.6;
}
.terminal-divider {
  height: 1px;
  background: var(--border);
  margin: 16px 0;
}
.terminal-results {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.terminal-result {
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  padding: 14px 16px;
  background: #0D1117;
}
.result-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--accent);
  display: block;
  margin-bottom: 6px;
}
.result-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  display: block;
  margin-bottom: 8px;
}
.result-body {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--fg);
  line-height: 1.6;
  margin-bottom: 10px;
}
.result-body.synthesis {
  color: var(--code-green);
  background: var(--accent-dim);
  border: 1px solid #5EAE7830;
  border-radius: var(--radius-inline);
  padding: 8px 12px;
}
.result-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.link-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 3px;
  background: var(--bg-card);
  color: var(--code-blue);
  border: 1px solid var(--border);
}

/* ── Section eyebrow ─────────────────────────────────────── */
.section-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

/* ── Section heading (reused across sections) ───────────── */
.section-heading {
  font-size: clamp(22px, 3.5vw, 34px);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
  max-width: 640px;
}
.section-sub {
  color: var(--fg-muted);
  font-size: 17px;
  max-width: 560px;
  line-height: 1.7;
}

/* ── Tagline bar ─────────────────────────────────────────── */
.tagline {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.tagline-inner {
  padding: 16px 0;
  display: flex;
  align-items: center;
  gap: 0;
}
.tagline-segment {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--fg-muted);
}
.tagline-sep {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--border);
  margin: 0 16px;
}

/* ── Problem ─────────────────────────────────────────────── */
.problem {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px;
  border-bottom: 1px solid var(--border);
}
.problem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  overflow: hidden;
  margin-top: 40px;
}
.problem-card {
  background: var(--bg);
  padding: 36px 32px;
}
.problem-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 1px;
  margin-bottom: 16px;
}
.problem-card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
}
.problem-card p {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.7;
}

/* ── How It Works ─────────────────────────────────────────── */
.hiw-section {
  background: #0D1117;
}
.hiw-section-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px;
  border-bottom: 1px solid var(--border);
}
.hiw-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: 48px;
}
.hiw-step {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 32px;
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
}
.hiw-step:last-child { border-bottom: none; }
.hiw-step-num {
  font-family: var(--font-mono);
  font-size: 28px;
  font-weight: 700;
  color: var(--border);
  line-height: 1;
  padding-top: 4px;
}
.hiw-step-content h3 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 12px;
}
.hiw-step-content p {
  color: var(--fg-muted);
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 20px;
}
.hiw-code {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  padding: 16px 20px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  line-height: 1.7;
  overflow-x: auto;
}
.code-comment { color: var(--code-muted); }
.code-str { color: var(--code-yellow); }
.code-arrow { color: var(--accent); }
.code-sep { color: var(--code-muted); }

/* ── Pipeline visual (neural chain) ──────────────────────── */
.hiw-graph {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: nowrap;
  padding: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  overflow-x: auto;
}
.graph-node {
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 6px 12px;
  border-radius: var(--radius-inline);
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
}
.graph-node.actor { background: #5EAE7815; color: var(--accent); border: 1px solid #5EAE7830; }
.graph-node.ttp   { background: #79C0FF15;  color: var(--code-blue); border: 1px solid #79C0FF30; }
.graph-node.cve   { background: #E3B34115;  color: var(--code-yellow); border: 1px solid #E3B34130; }
.graph-arrow { color: var(--fg-muted); font-family: var(--font-mono); font-size: 11px; flex-shrink: 0; }
.graph-conn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 0 4px;
  flex-shrink: 0;
}
.graph-dashed {
  width: 40px;
  height: 0;
  border-top: 1.5px dashed var(--border);
  margin-bottom: 12px;
}
.graph-label {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--code-muted);
  text-align: center;
  white-space: nowrap;
}

/* ── Differentiators ─────────────────────────────────────── */
.differentiators {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px;
  border-bottom: 1px solid var(--border);
}
.diff-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  overflow: hidden;
  margin-top: 40px;
}
.diff-card {
  background: var(--bg);
  padding: 32px;
}
.diff-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  background: var(--accent-dim);
  border-radius: var(--radius-card);
  margin-bottom: 20px;
}
.diff-card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 10px;
}
.diff-card p {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.7;
  margin-bottom: 12px;
}
.diff-vs {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--code-muted);
  border-left: 2px solid var(--border);
  padding-left: 10px;
  line-height: 1.6;
}

/* ── Why Built ───────────────────────────────────────────── */
.whybuilt {
  background: #0D1117;
  border-bottom: 1px solid var(--border);
  padding: 80px 32px;
}
.whybuilt-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.whybuilt-quote {
  font-size: 19px;
  line-height: 1.65;
  color: var(--fg);
  max-width: 600px;
  margin: 16px 0 20px;
}
.whybuilt-quote strong {
  color: var(--fg);
  font-weight: 600;
}
.whybuilt-links {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--fg-muted);
  margin-bottom: 24px;
}
.whybuilt-links a {
  color: var(--code-blue);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 13px;
}
.whybuilt-links a:hover { text-decoration: underline; }
.whybuilt-links span { color: var(--code-muted); font-family: var(--font-mono); font-size: 13px; }
.whybuilt-stack {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--fg-muted);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-inline);
  padding: 6px 12px;
}
.whybuilt-stack strong { color: var(--fg); }
.gh-stars {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--code-muted);
}

/* ── Closing CTA ────────────────────────────────────────── */
.closing {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px;
  border-bottom: 1px solid var(--border);
}
.closing-inner h2 {
  font-size: clamp(26px, 4vw, 42px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 16px;
  max-width: 580px;
}
.closing-inner p {
  font-size: 16px;
  color: var(--fg-muted);
  margin-bottom: 24px;
}
.cta-primary {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: var(--radius-input);
  background: var(--accent);
  color: #0A0E17;
  text-decoration: none;
  transition: opacity 0.15s;
  margin-bottom: 32px;
}
.cta-primary:hover { opacity: 0.82; }
.closing-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: var(--radius-inline);
  background: var(--bg-card);
  color: var(--fg-muted);
  border: 1px solid var(--border);
}

/* ── Footer ──────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 32px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--fg-muted);
}
.footer-right a {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
  text-decoration: none;
}
.footer-right a:hover { color: var(--fg); }

/* ── Hover states ───────────────────────────────────────── */
a:hover { color: var(--link-hover); }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 768px) {
  .hero         { padding: 100px 20px 60px; }
  .hero-headline { font-size: 30px; }
  .problem-grid  { grid-template-columns: 1fr; }
  .diff-grid     { grid-template-columns: 1fr; }
  .hiw-step      { grid-template-columns: 32px 1fr; gap: 16px; }
  .hiw-step-num  { font-size: 22px; }
  .tagline       { display: none; }
  .hiw-graph     { gap: 4px; }
  .graph-dashed  { width: 24px; }
  .footer-inner  { flex-direction: column; gap: 12px; }
}

@media (max-width: 480px) {
  .problem-card, .diff-card { padding: 24px 20px; }
  .section-heading { font-size: 20px; }
}