:root {
  --bg: #0c1210;
  --surface: #131c18;
  --surface-2: #192420;
  --border: #243530;
  --text: #e4ede9;
  --text-muted: #8ba89a;
  --accent: #1a8a6e;
  --accent-light: #34d399;
  --accent-glow: rgba(26,138,110,0.15);
  --teal: #1a5c50;
  --teal-light: #2d9b82;
  --green: #34d399;
  --green-bg: rgba(52,211,153,0.08);
  --orange: #fb923c;
  --orange-bg: rgba(251,146,60,0.08);
  --blue: #5cb8a5;
  --blue-bg: rgba(92,184,165,0.08);
  --pink: #e879a0;
  --pink-bg: rgba(232,121,160,0.08);
  --yellow: #e6c65a;
  --yellow-bg: rgba(230,198,90,0.08);
  --red: #e87171;
  --red-bg: rgba(232,113,113,0.08);
  --purple: #a78bfa;
  --purple-bg: rgba(167,139,250,0.08);
  --radius: 12px;
  --radius-sm: 8px;
}

html.light {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-2: #f1f5f9;
  --border: #e2e8f0;
  --text: #1e293b;
  --text-muted: #64748b;
  --accent: #0d9488;
  --accent-light: #0f766e;
  --accent-glow: rgba(13,148,136,0.08);
  --teal: #99f6e4;
  --teal-light: #0d9488;
  --green: #16a34a;
  --green-bg: rgba(22,163,74,0.06);
  --orange: #ea580c;
  --orange-bg: rgba(234,88,12,0.06);
  --blue: #0284c7;
  --blue-bg: rgba(2,132,199,0.06);
  --pink: #db2777;
  --pink-bg: rgba(219,39,119,0.06);
  --yellow: #ca8a04;
  --yellow-bg: rgba(202,138,4,0.06);
  --red: #dc2626;
  --red-bg: rgba(220,38,38,0.06);
  --purple: #7c3aed;
  --purple-bg: rgba(124,58,237,0.06);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 15px;
  transition: background 0.3s, color 0.3s;
}

/* NAV */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(15,17,23,0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem; height: 56px;
  display: flex; align-items: center; justify-content: space-between;
  transition: background 0.3s;
}
html.light nav { background: rgba(248,250,252,0.9); }
nav .logo { font-weight: 700; font-size: 15px; letter-spacing: -0.01em; color: var(--text); display: flex; align-items: center; gap: 0.5rem; text-decoration: none; }
nav .logo img { width: 28px; height: 28px; border-radius: 6px; }
nav .logo .coditect { color: var(--accent-light); font-size: 15px; font-weight: 700; }
nav .logo span { color: var(--text-muted); font-weight: 400; }
nav .nav-right { display: flex; align-items: center; gap: 0.75rem; }
nav .nav-links { display: flex; gap: 0.25rem; }
nav .nav-links a {
  color: var(--text-muted); text-decoration: none; font-size: 13px;
  padding: 6px 12px; border-radius: 6px; transition: all 0.2s;
}
nav .nav-links a:hover { color: var(--text); background: var(--surface); }
nav .nav-links a.active { color: var(--accent-light); background: var(--accent-glow); }
.theme-toggle {
  background: none; border: 1px solid var(--border); border-radius: 8px;
  color: var(--text-muted); cursor: pointer; padding: 6px 8px;
  display: flex; align-items: center; transition: all 0.2s;
}
.theme-toggle:hover { color: var(--text); border-color: var(--accent); }

/* CONTAINER */
.container { max-width: 960px; margin: 0 auto; padding: 0 2rem; }
.page-content { padding-top: 80px; padding-bottom: 4rem; min-height: 100vh; }

/* HERO */
.hero { padding: 2rem 2rem 2rem; text-align: center; max-width: 900px; margin: 0 auto; }
.hero .badge {
  display: inline-block; padding: 4px 14px;
  background: var(--accent-glow); border: 1px solid rgba(26,138,110,0.3);
  border-radius: 20px; font-size: 12px; font-weight: 600;
  color: var(--accent-light); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 1.5rem;
}
.hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.15; margin-bottom: 1rem; }
.hero h1 .gradient { background: linear-gradient(135deg, #1a5c50, #34d399, #6ee7b7); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
html.light .hero h1 .gradient { background: linear-gradient(135deg, #0d9488, #059669, #047857); -webkit-background-clip: text; background-clip: text; }
.hero p { font-size: 1.15rem; color: var(--text-muted); max-width: 600px; margin: 0 auto; }

/* SECTIONS */
section { padding: 2rem 0; }
section + section { border-top: 1px solid var(--border); }
.section-badge {
  display: inline-block; padding: 3px 10px; border-radius: 4px;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.75rem;
}
h2 { font-size: 1.75rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 1rem; line-height: 1.25; }
h3 { font-size: 1.1rem; font-weight: 700; margin: 1.5rem 0 0.75rem; color: var(--text); }
p { margin-bottom: 1rem; color: var(--text-muted); }
p strong { color: var(--text); }

/* TABLES */
table { width: 100%; border-collapse: collapse; margin: 1rem 0; font-size: 13px; }
th {
  text-align: left; padding: 0.75rem 1rem; background: var(--surface-2);
  color: var(--text-muted); font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em; border-bottom: 1px solid var(--border);
}
td { padding: 0.75rem 1rem; border-bottom: 1px solid var(--border); color: var(--text-muted); }
td strong { color: var(--text); }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,0.02); }
html.light tr:hover td { background: rgba(0,0,0,0.02); }

/* CARDS */
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem; margin: 1rem 0;
  transition: border-color 0.2s;
}
.card:hover { border-color: var(--accent); }

/* HIGHLIGHT BOX */
.highlight-box { padding: 1.5rem; border-radius: var(--radius); margin: 1.5rem 0; }
.highlight-box.accent { background: var(--accent-glow); border: 1px solid rgba(26,138,110,0.2); }
.highlight-box.green { background: var(--green-bg); border: 1px solid rgba(52,211,153,0.2); }
.highlight-box.orange { background: var(--orange-bg); border: 1px solid rgba(251,146,60,0.2); }
.highlight-box.red { background: var(--red-bg); border: 1px solid rgba(232,113,113,0.2); }
.highlight-box h4 { font-size: 14px; font-weight: 700; margin-bottom: 0.5rem; }
.highlight-box.accent h4 { color: var(--accent-light); }
.highlight-box.green h4 { color: var(--green); }
.highlight-box.orange h4 { color: var(--orange); }
.highlight-box.red h4 { color: var(--red); }
.highlight-box p { font-size: 13px; margin: 0; }

blockquote {
  margin: 1.25rem 0; padding: 1rem 1.5rem;
  background: var(--surface); border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic; font-size: 14px; color: var(--text-muted);
}
blockquote p { margin: 0; }
blockquote cite { display: block; margin-top: 0.5rem; font-size: 11px; color: var(--accent-light); font-style: normal; }

/* METRICS */
.metrics-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.75rem; margin: 1rem 0; }
.metric {
  padding: 1.25rem; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); text-align: center;
}
.metric .value { font-size: 1.5rem; font-weight: 800; color: var(--accent-light); margin-bottom: 0.25rem; }
.metric .label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; }

/* CALL STEPS */
.call-steps { margin: 1rem 0; display: flex; flex-direction: column; gap: 0.5rem; }
.call-step {
  display: flex; gap: 1rem; padding: 1rem 1.25rem;
  background: var(--surface); border-radius: var(--radius-sm); border: 1px solid var(--border);
}
.call-step .time { min-width: 55px; font-size: 11px; font-weight: 700; color: var(--accent-light); padding-top: 2px; }
.call-step .step-title { font-weight: 700; font-size: 14px; color: var(--text); }
.call-step .step-desc { font-size: 13px; color: var(--text-muted); margin-top: 0.25rem; }
.call-step .script {
  margin-top: 0.5rem; padding: 0.75rem 1rem;
  background: rgba(26,138,110,0.06); border-radius: 6px;
  font-style: italic; font-size: 13px; color: var(--text-muted); border-left: 2px solid var(--accent);
}

/* PIPELINE */
.pipeline-wrapper { position: relative; max-width: 1100px; margin: 0 auto; padding: 2rem 1rem 1rem; }
.pipeline-line { position: absolute; top: calc(2rem + 20px); left: 12%; right: 12%; height: 2px; background: var(--border); z-index: 1; }
.pipeline { display: flex; gap: 0; justify-content: center; align-items: stretch; position: relative; z-index: 2; }
.pipeline-step { flex: 1; min-width: 110px; max-width: 150px; position: relative; text-align: center; padding: 0 0.4rem; }
.pipeline-step .step-num {
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px; margin: 0 auto 0.6rem;
  position: relative; z-index: 2; border: 3px solid var(--bg);
}
.pipeline-step:nth-child(1) .step-num { background: var(--accent); color: #fff; box-shadow: 0 0 0 2px var(--accent); }
.pipeline-step:nth-child(2) .step-num { background: var(--blue); color: #fff; box-shadow: 0 0 0 2px var(--blue); }
.pipeline-step:nth-child(3) .step-num { background: var(--green); color: #0c1210; box-shadow: 0 0 0 2px var(--green); }
.pipeline-step:nth-child(4) .step-num { background: var(--orange); color: #0c1210; box-shadow: 0 0 0 2px var(--orange); }
.pipeline-step:nth-child(5) .step-num { background: var(--purple); color: #fff; box-shadow: 0 0 0 2px var(--purple); }
.pipeline-step:nth-child(6) .step-num { background: var(--pink); color: #fff; box-shadow: 0 0 0 2px var(--pink); }
.pipeline-step .step-label { font-weight: 700; font-size: 12px; margin-bottom: 0.2rem; text-transform: uppercase; letter-spacing: 0.04em; }
.pipeline-step .step-time { font-size: 11px; color: var(--text-muted); }

ul { padding-left: 1.5rem; margin: 0.5rem 0 1rem; }
li { color: var(--text-muted); font-size: 13px; margin-bottom: 0.25rem; }
li strong { color: var(--text); }

/* FOOTER */
footer {
  text-align: center; padding: 3rem 2rem;
  border-top: 1px solid var(--border); color: var(--text-muted); font-size: 12px;
}
footer .brand { font-weight: 700; color: var(--accent-light); font-size: 14px; }

/* NAV PAGE CARDS (index) */
.nav-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin: 2rem 0; }
.nav-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.75rem; text-decoration: none;
  transition: all 0.2s; display: block;
}
.nav-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.15); }
.nav-card .card-icon { font-size: 1.75rem; margin-bottom: 0.75rem; }
.nav-card .card-title { font-weight: 700; font-size: 16px; color: var(--text); margin-bottom: 0.35rem; }
.nav-card .card-desc { font-size: 13px; color: var(--text-muted); line-height: 1.5; }

/* RESPONSIVE */
@media (max-width: 768px) {
  .pipeline { flex-wrap: wrap; gap: 0.5rem; }
  .pipeline-line { display: none; }
  .pipeline-step { min-width: 90px; }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
  nav .nav-links { display: none; }
  .nav-cards { grid-template-columns: 1fr; }
}
