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

/* ─── Design tokens — matches partner-portal app.css theme ──── */
:root {
  /* Brand */
  --brand-blue:        #1F5FBF;
  --brand-blue-dark:   #174a99;
  --brand-blue-light:  #2d70d9;
  --brand-green:       #8BC34A;
  --brand-green-dark:  #7cb342;
  --brand-green-soft:  #f1f8e9;

  /* Neutrals */
  --dark-blue-gray:    #1F2A37;
  --text-body:         #334155;
  --text-muted:        #64748B;
  --light-bg:          #F8FAFC;
  --card-surface:      #FFFFFF;
  --border:            #CBD5E1;
  --border-strong:     #64748B;

  /* Status */
  --success:           #2E7D32;
  --success-light:     #e8f5e9;
  --warning:           #F59E0B;
  --warning-light:     #fef3c7;
  --error:             #DC2626;
  --error-light:       #fee2e2;

  /* Layout */
  --max-w:     900px;
  --radius:    8px;
  --radius-sm: 4px;
  --shadow:    0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px rgba(31,95,191,0.10);

  --sans: "Inter", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", "Fira Mono", "Cascadia Code", monospace;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-body);
  background: var(--light-bg);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--brand-blue); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── Layout ─────────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border);
}
section:last-of-type { border-bottom: none; }

/* ─── Nav ─────────────────────────────────────────────────────
   Mirrors the partner portal header:
   bg-white border-b-2 border-[#CBD5E1] shadow-sm shadow-[0_2px_6px_rgba(31,95,191,0.06)]
────────────────────────────────────────────────────────────── */
nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--card-surface);
  border-bottom: 2px solid var(--border);
  box-shadow: 0 2px 6px rgba(31,95,191,0.06);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  height: 56px; /* matches portal h-14 */
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: 24px;
  list-style: none;
  font-size: 0.875rem;
}
.nav-links a { color: var(--text-muted); font-weight: 500; }
.nav-links a:hover { color: var(--brand-blue); text-decoration: none; }

/* ─── Buttons — mirrors portal .btn-primary / .btn-secondary ── */
.btn-primary {
  display: inline-block;
  background: var(--brand-blue);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 10px 22px;
  border-radius: var(--radius);
  transition: background 0.15s;
}
.btn-primary:hover { background: var(--brand-blue-dark); text-decoration: none; }

.btn-ghost {
  display: inline-block;
  color: var(--brand-blue);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 10px 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card-surface);
  transition: border-color 0.15s, background 0.15s;
}
.btn-ghost:hover { border-color: var(--brand-blue); background: #eff4ff; text-decoration: none; }

.btn-outline {
  display: inline-block;
  color: var(--text-muted);
  font-size: 0.875rem;
  border: 1px solid var(--border);
  padding: 10px 22px;
  border-radius: var(--radius);
  background: var(--card-surface);
  transition: border-color 0.15s, color 0.15s;
}
.btn-outline:hover { border-color: var(--brand-blue); color: var(--brand-blue); text-decoration: none; }

/* ─── Hero ───────────────────────────────────────────────────── */
#hero {
  background: var(--card-surface);
  padding: 80px 0;
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-blue);
  background: #eff4ff;
  border: 1px solid #c7d9f7;
  border-radius: var(--radius-sm);
  padding: 3px 10px;
  margin-bottom: 20px;
}

h1 {
  font-size: clamp(1.85rem, 4vw, 2.6rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: var(--dark-blue-gray);
  max-width: 660px;
  margin-bottom: 20px;
}

.subheadline {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 560px;
  line-height: 1.8;
  margin-bottom: 36px;
}

.cta-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* ─── Section headings ───────────────────────────────────────── */
.section-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand-blue);
  margin-bottom: 10px;
}

h2 {
  font-size: clamp(1.35rem, 3vw, 1.8rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.25;
  color: var(--dark-blue-gray);
  margin-bottom: 16px;
}

/* ─── Problem ────────────────────────────────────────────────── */
.problem-intro {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 560px;
  margin-bottom: 32px;
}

.problem-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 580px;
}

.problem-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 0.95rem;
  background: var(--card-surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--error);
  border-radius: var(--radius);
  padding: 14px 18px;
  box-shadow: var(--shadow);
  color: var(--text-body);
}

/* ─── Document type grid ─────────────────────────────────────── */
.doctype-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.doctype-group {
  background: var(--card-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow);
}

.doctype-group-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--brand-blue);
  margin-bottom: 10px;
}

.doctype-group ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.doctype-group ul li {
  font-size: 0.82rem;
  color: var(--text-body);
  padding-left: 12px;
  position: relative;
}

.doctype-group ul li::before {
  content: "·";
  position: absolute;
  left: 0;
  color: var(--brand-green-dark);
  font-weight: 700;
}

/* ─── Pipeline ───────────────────────────────────────────────── */
.pipeline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  row-gap: 10px;
  column-gap: 0;
  margin: 36px 0;
}

.pipeline-step { display: flex; flex-direction: column; align-items: flex-start; }

.step-box {
  background: var(--card-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 20px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dark-blue-gray);
  white-space: nowrap;
  box-shadow: var(--shadow);
}

.step-box .step-num {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--brand-blue);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.pipeline-arrow {
  color: var(--text-muted);
  font-size: 1.1rem;
  padding: 0 10px;
  flex-shrink: 0;
}

/* .btn-primary palette for the terminal step */
.step-box.final {
  background: var(--brand-blue);
  border-color: var(--brand-blue-dark);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.step-box.final .step-num { color: rgba(255,255,255,0.75); }

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.95rem;
  color: var(--text-body);
}

.feature-list li::before {
  content: "✓";
  color: var(--brand-green-dark);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ─── Code block ─────────────────────────────────────────────── */
.code-wrapper {
  background: var(--dark-blue-gray);
  border: 1px solid #293548;
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 32px;
  box-shadow: var(--shadow-md);
}

.code-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  border-bottom: 1px solid #293548;
  font-size: 0.75rem;
  color: #94a3b8;
  background: #16202e;
}

.code-dots { display: flex; gap: 6px; }
.code-dots span { width: 10px; height: 10px; border-radius: 50%; background: #3a4a5e; }

pre {
  margin: 0;
  padding: 22px 24px;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.8;
  overflow-x: auto;
  color: #e2e8f0;
}

.j-key  { color: #7dd3fc; }
.j-str  { color: #86efac; }
.j-num  { color: #fdba74; }
.j-punc { color: #94a3b8; }
.j-risk-m { color: #fbbf24; }
.j-risk-h { color: #f87171; }

/* ─── Pricing ────────────────────────────────────────────────── */
.pricing-card {
  background: var(--card-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  max-width: 420px;
  margin-top: 32px;
  box-shadow: var(--shadow-md);
}

.price-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 28px;
}

.price-amount {
  font-size: 2.8rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--dark-blue-gray);
}

.price-unit { font-size: 0.9rem; color: var(--text-muted); }

.pricing-items {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 13px;
  border-top: 1px solid var(--border);
  padding-top: 24px;
  margin-bottom: 28px;
}

.pricing-items li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-body);
}

.pricing-items li::before {
  content: "✓";
  color: var(--brand-green-dark);
  font-weight: 700;
  flex-shrink: 0;
}

/* ─── Trust grid ─────────────────────────────────────────────── */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
  margin-top: 32px;
}

/* mirrors portal .card */
.trust-item {
  background: var(--card-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 20px;
  box-shadow: var(--shadow);
}

.trust-icon { font-size: 1.2rem; margin-bottom: 10px; }

.trust-item strong {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dark-blue-gray);
  margin-bottom: 6px;
}

.trust-item p { font-size: 0.8rem; color: var(--text-muted); line-height: 1.5; }

/* ─── Final CTA ──────────────────────────────────────────────── */
#final-cta {
  text-align: center;
  padding: 80px 0;
  background: var(--card-surface);
}

#final-cta h2 { max-width: 520px; margin: 0 auto 14px; }

#final-cta p {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 36px;
  line-height: 1.75;
}

.cta-stack { display: flex; flex-direction: column; align-items: center; gap: 12px; }

/* ─── Footer ─────────────────────────────────────────────────── */
footer {
  background: var(--card-surface);
  border-top: 1px solid var(--border);
  padding: 24px;
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 640px) {
  .pipeline { flex-direction: column; align-items: flex-start; }
  .pipeline-arrow { transform: rotate(90deg); padding: 4px 0; }
  .trust-grid { grid-template-columns: 1fr 1fr; }
  .nav-links { display: none; }
}
