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

:root {
  --bg:       #0a0a0a;
  --bg-2:     #111;
  --bg-3:     #181818;
  --border:   #222;
  --text:     #e8e8e8;
  --text-dim: #888;
  --accent:   #4ade80;
  --font:     system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono:     "SF Mono", "Fira Code", "Cascadia Code", monospace;
  --radius:   8px;
  --max-w:    1100px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }

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

h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.section-sub {
  color: var(--text-dim);
  font-size: 1.1rem;
  margin-bottom: 3rem;
  max-width: 600px;
}

/* ── Buttons ──────────────────────────────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  white-space: nowrap;
}
.btn:hover { opacity: 0.85; transform: translateY(-1px); text-decoration: none; }

.btn-primary  { background: var(--accent); color: #000; }
.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-lg { padding: 0.85rem 2rem; font-size: 1.05rem; }

/* ── Hero ─────────────────────────────────────────────────────────────────── */
.hero {
  min-height: 90vh;
  display: flex;
  align-items: center;
  padding: 5rem 0 4rem;
  background: radial-gradient(ellipse at 50% 0%, #0d2010 0%, var(--bg) 70%);
}

.hero-badge {
  display: inline-block;
  background: #0d2010;
  border: 1px solid #1a4a25;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  letter-spacing: 0.03em;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
}

.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.accent { color: var(--accent); }

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--text-dim);
  max-width: 560px;
  margin-bottom: 2rem;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }

.hero-snippet {
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  max-width: 100%;
  box-sizing: border-box;
}

.hero-snippet pre { margin: 0; overflow: auto; }
.hero-snippet code { font-family: var(--mono); font-size: 0.85rem; color: #a3e4b5; }

.snippet-label {
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.75rem;
}

/* ── Pipeline ─────────────────────────────────────────────────────────────── */
.pipeline {
  padding: 5rem 0;
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.pipeline-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin-bottom: 3rem;
}

.pipe-step {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  max-width: 420px;
  padding: 1.25rem 1.25rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.pipe-step.visible { opacity: 1; transform: translateY(0); }

.pipe-icon { font-size: 1.75rem; flex-shrink: 0; }
.pipe-content { flex: 1; }
.pipe-label { font-weight: 700; font-size: 0.9rem; }
.pipe-detail { font-size: 0.75rem; color: var(--text-dim); margin-top: 0.2rem; }

.pipe-arrow {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  max-width: 420px;
  padding: 0 1.25rem;
  opacity: 0;
  transition: opacity 0.4s ease 0.2s;
}
.pipe-arrow.visible { opacity: 1; }

.pipe-arrow svg { width: 16px; height: 40px; flex-shrink: 0; }
.pipe-arrow .arrow-path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  transition: stroke-dashoffset 0.6s ease;
}
.pipe-arrow.visible .arrow-path { stroke-dashoffset: 0; }

.pipe-arrow span { font-size: 0.65rem; color: var(--text-dim); white-space: nowrap; }

.pipeline-timing {
  display: flex;
  gap: 1px;
  background: var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 600px;
  margin: 0 auto;
}

.timing-item {
  flex: 1;
  text-align: center;
  padding: 1rem;
  background: var(--bg-3);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.timing-featured { background: #0d2010; }

.timing-label { font-size: 0.8rem; color: var(--text-dim); }
.timing-value { font-size: 1.4rem; font-weight: 700; color: var(--accent); }
.timing-steps { font-size: 0.75rem; color: var(--text-dim); }

/* ── Use Cases ────────────────────────────────────────────────────────────── */
.usecases { padding: 6rem 0; }

.usecase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(440px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 3rem;
}

.usecase-card {
  background: var(--bg-2);
  padding: 2.75rem 2.5rem;
}

.usecase-icon { font-size: 2.5rem; margin-bottom: 1.1rem; }

.usecase-card h3 { font-size: 1.2rem; font-weight: 700; margin-bottom: 0.75rem; }
.usecase-card p { font-size: 0.95rem; color: var(--text-dim); margin-bottom: 1.5rem; line-height: 1.7; }

.usecase-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.usecase-card ul li {
  font-size: 0.9rem;
  color: var(--text-dim);
  padding-left: 1.25rem;
  position: relative;
}
.usecase-card ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
}

.saas-note {
  text-align: center;
  font-size: 0.95rem;
  color: var(--text-dim);
}

/* ── Specs ────────────────────────────────────────────────────────────────── */
.specs {
  padding: 6rem 0;
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.specs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(440px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.spec-block {
  background: var(--bg-3);
  padding: 2.75rem 2.5rem;
}

.spec-block h3 {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dim);
  margin-bottom: 1.25rem;
}

.spec-table { width: 100%; border-collapse: collapse; }
.spec-table td {
  padding: 0.65rem 0;
  font-size: 0.93rem;
  border-bottom: 1px solid var(--border);
}
.spec-table td:first-child { color: var(--text-dim); width: 45%; }
.spec-table td:last-child { color: var(--text); font-weight: 500; }
.spec-table tr:last-child td { border-bottom: none; }

/* ── CTA ──────────────────────────────────────────────────────────────────── */
.cta {
  padding: 6rem 0;
  text-align: center;
  background: radial-gradient(ellipse at 50% 100%, #0d2010 0%, var(--bg) 70%);
}

.cta-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; margin-bottom: 3rem; }

.cta-code {
  max-width: 560px;
  margin: 0 auto;
  text-align: left;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.code-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
}

.code-tab {
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-family: var(--font);
}
.code-tab.active { color: var(--accent); border-bottom-color: var(--accent); }

.code-block {
  display: none;
  padding: 1.25rem 1.5rem;
  margin: 0;
  overflow: auto;
}
.code-block.active { display: block; }
.code-block code { font-family: var(--mono); font-size: 0.82rem; color: #a3e4b5; }

/* ── Footer ───────────────────────────────────────────────────────────────── */
footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-dim);
}
footer a { color: var(--text-dim); }
footer a:hover { color: var(--text); }

/* ── CTA2 ─────────────────────────────────────────────────────────────────── */
.cta2 {
  padding: 5rem 0;
  background: var(--bg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cta2-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  align-items: center;
}

.cta2-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 0;
}

.cta2-bullets li {
  font-size: 0.95rem;
  color: var(--text-dim);
  padding-left: 1.5rem;
  position: relative;
}

.cta2-bullets li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

.cta2-right { display: flex; align-items: center; }

.cta2-actions { display: flex; flex-direction: column; gap: 1rem; white-space: nowrap; }

/* ── Contact ──────────────────────────────────────────────────────────────── */
.contact {
  padding: 5rem 0;
  border-top: 1px solid var(--border);
  text-align: center;
}

.contact .section-sub { margin-left: auto; margin-right: auto; }

.contact-form-wrap { max-width: 560px; margin: 0 auto; }

.form-group { margin-bottom: 1rem; }

.form-group input,
.form-group textarea {
  width: 100%;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s;
}

.form-group input:focus,
.form-group textarea:focus { border-color: var(--accent); }

.form-group textarea { resize: vertical; }

.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-dim); }

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 700px) {
  .timing-value { font-size: 1.1rem; }
  .cta2-grid { grid-template-columns: 1fr; }
  .cta2-actions { flex-direction: row; flex-wrap: wrap; }
}
