/* ─── Tokens ─────────────────────────────────────────────── */
:root {
  --bg: #07070d;
  --bg-soft: #0d0d18;
  --surface: rgba(255, 255, 255, 0.03);
  --surface-2: rgba(255, 255, 255, 0.05);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);

  --text: #e6e7ee;
  --text-dim: #a3a8b8;
  --text-muted: #7a8094;

  --violet: #a78bfa;
  --indigo: #818cf8;
  --blue: #60a5fa;
  --cyan: #22d3ee;
  --pink: #f472b6;

  --grad: linear-gradient(135deg, #a78bfa 0%, #60a5fa 50%, #22d3ee 100%);

  --radius: 16px;
  --radius-lg: 22px;

  --shadow-soft: 0 10px 40px -10px rgba(99, 102, 241, 0.25);
  --shadow-strong: 0 30px 80px -30px rgba(99, 102, 241, 0.5);

  --max: 1180px;
  --pad: clamp(20px, 4vw, 56px);
}

/* ─── Reset / base ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
}
a { color: inherit; text-decoration: none; }
a:hover { color: #fff; }
img, svg { display: block; max-width: 100%; }
code {
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  background: rgba(167, 139, 250, 0.12);
  color: #d8c7ff;
  padding: 1px 6px;
  border-radius: 5px;
}

/* ─── Background aurora ──────────────────────────────────── */
.bg-aurora {
  position: fixed; inset: 0; z-index: -1; overflow: hidden;
  pointer-events: none;
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(110px);
  opacity: 0.55;
  animation: float 22s ease-in-out infinite;
}
.orb-1 { width: 620px; height: 620px; top: -120px; left: -160px; background: #6d28d9; animation-delay: 0s; }
.orb-2 { width: 540px; height: 540px; top: 240px; right: -180px; background: #1d4ed8; animation-delay: -7s; }
.orb-3 { width: 460px; height: 460px; bottom: -140px; left: 30%; background: #0891b2; animation-delay: -14s; }

@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50%      { transform: translate3d(40px, -30px, 0) scale(1.07); }
}

.grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse at center, rgba(0,0,0,0.9), transparent 70%);
}

/* ─── Nav ────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--pad);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  background: rgba(7, 7, 13, 0.55);
  border-bottom: 1px solid var(--border);
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; letter-spacing: -0.01em; font-size: 18px;
}
.brand-mark {
  width: 28px; height: 28px;
  border-radius: 7px;
  filter: drop-shadow(0 4px 12px rgba(99, 102, 241, 0.35));
}
.brand-text {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.nav-links { display: flex; gap: 26px; font-size: 14px; color: var(--text-dim); }
.nav-links a { transition: color .2s ease; }

@media (max-width: 640px) { .nav-links { display: none; } }

/* ─── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 14px;
  letter-spacing: 0.01em;
  transition: transform .2s ease, box-shadow .25s ease, background .2s ease, border-color .2s ease, color .2s ease;
  border: 1px solid transparent; cursor: pointer; user-select: none;
  white-space: nowrap;
}
.btn-primary {
  color: #0b0b18;
  background: var(--grad);
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-strong);
  color: #0b0b18;
}
.btn-ghost {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border-strong);
}
.btn-ghost:hover {
  background: var(--surface-2);
  border-color: rgba(255,255,255,0.25);
  color: #fff;
}
.btn-disabled {
  color: var(--text-muted);
  background: rgba(255,255,255,0.025);
  border-color: var(--border);
  cursor: not-allowed;
}

/* ─── Layout helpers ─────────────────────────────────────── */
section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 96px var(--pad);
  position: relative;
}
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}

/* ─── Hero ───────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding-top: 56px;
  padding-bottom: 40px;
}
.hero-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 28px;
  position: relative;
}
.hero-logo img {
  width: clamp(96px, 12vw, 128px);
  height: auto;
  border-radius: 26px;
  filter:
    drop-shadow(0 20px 40px rgba(99, 102, 241, 0.45))
    drop-shadow(0 0 60px rgba(167, 139, 250, 0.25));
  animation: hero-float 6s ease-in-out infinite;
}
@keyframes hero-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 16px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font-size: 13px;
  color: var(--text-dim);
  background: rgba(255,255,255,0.025);
  backdrop-filter: blur(8px);
  margin-bottom: 26px;
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 12px #34d399;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.5; transform: scale(0.85); }
}

.hero-title {
  font-size: clamp(40px, 7vw, 84px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 800;
  margin: 0 0 22px;
}
.hero-sub {
  max-width: 680px; margin: 0 auto 36px;
  font-size: clamp(16px, 1.5vw, 19px);
  color: var(--text-dim);
  line-height: 1.6;
}
.hero-cta {
  display: flex; gap: 12px; justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

.hero-visual {
  position: relative;
  margin: 0 auto;
  max-width: 1100px;
  filter: drop-shadow(0 30px 80px rgba(99,102,241,0.25));
}
.ecosystem { width: 100%; height: auto; }

.ecosystem .pulses circle { filter: drop-shadow(0 0 6px currentColor); }
.ecosystem .node { transition: transform .4s ease; }
.ecosystem .line-input,
.ecosystem .line-capture,
.ecosystem .line-agent {
  animation: dash 22s linear infinite;
}
@keyframes dash { to { stroke-dashoffset: -300; } }

/* ─── Section headings ───────────────────────────────────── */
.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 12px;
  font-weight: 600;
  color: var(--violet);
  margin-bottom: 18px;
  text-align: center;
}
.section-title {
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 800;
  text-align: center;
  margin: 0 0 18px;
}
.section-lede {
  max-width: 680px; margin: 0 auto 60px;
  text-align: center;
  font-size: 17px;
  color: var(--text-dim);
}

/* ─── Philosophy / Pillars ──────────────────────────────── */
.pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.pillar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
  position: relative; overflow: hidden;
}
.pillar::before {
  content: ""; position: absolute; inset: 0;
  background: var(--grad);
  opacity: 0; transition: opacity .3s ease;
  mix-blend-mode: overlay;
}
.pillar:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  background: var(--surface-2);
}
.pillar:hover::before { opacity: 0.06; }
.pillar-icon {
  width: 42px; height: 42px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: rgba(167,139,250,0.12);
  color: var(--violet);
  margin-bottom: 14px;
}
.pillar-icon svg { width: 22px; height: 22px; }
.pillar h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }
.pillar p { margin: 0; color: var(--text-dim); font-size: 14.5px; line-height: 1.55; }

/* ─── Open Source ────────────────────────────────────────── */
.open-source { padding-top: 60px; padding-bottom: 60px; }
.os-card {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-strong);
  background:
    linear-gradient(140deg, rgba(167,139,250,0.10) 0%, rgba(96,165,250,0.06) 50%, rgba(34,211,238,0.10) 100%),
    rgba(13, 13, 24, 0.55);
  backdrop-filter: blur(10px);
  padding: clamp(28px, 5vw, 56px);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.os-glow {
  position: absolute; inset: -2px;
  background:
    radial-gradient(circle at 0% 0%, rgba(167,139,250,0.25), transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(34,211,238,0.18), transparent 45%);
  pointer-events: none;
  opacity: 0.9;
}
.os-content { position: relative; text-align: center; }
.os-icon {
  width: 56px; height: 56px;
  margin: 0 auto 18px;
  border-radius: 16px;
  background: var(--grad);
  color: #0b0b18;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 14px 36px -12px rgba(167,139,250,0.6);
}
.os-icon svg { width: 28px; height: 28px; }
.os-eyebrow { margin-bottom: 12px; }
.os-title { margin-bottom: 14px; }
.os-lede { margin-bottom: 28px; }

.os-chips {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 10px;
  margin-bottom: 26px;
}
.os-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 13.5px; font-weight: 600;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-strong);
  color: var(--text);
  transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease;
}
.os-chip:hover {
  transform: translateY(-1px);
  background: rgba(255,255,255,0.07);
  border-color: rgba(255,255,255,0.25);
  color: #fff;
}
.os-chip svg { opacity: 0.9; }
.os-chip-soft {
  background: rgba(34,211,238,0.10);
  border-color: rgba(34,211,238,0.3);
  color: #a5f3fc;
  cursor: default;
}
.os-chip-soft:hover { transform: none; background: rgba(34,211,238,0.10); border-color: rgba(34,211,238,0.3); color: #a5f3fc; }

.os-fineprint {
  max-width: 640px;
  margin: 0 auto;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  padding-top: 22px;
  border-top: 1px dashed var(--border);
}
.os-fineprint strong { color: var(--text); }

/* ─── Cloud membership block ─────────────────────────────── */
.product-membership {
  margin: 4px 0 22px;
  padding: 16px 18px;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(34,211,238,0.08), rgba(129,140,248,0.06));
  border: 1px dashed rgba(34,211,238,0.35);
}
.product-membership p {
  margin: 8px 0 0;
  font-size: 13.5px;
  color: var(--text-dim);
  line-height: 1.55;
}
.membership-pill {
  display: inline-flex; align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #67e8f9;
  background: rgba(34,211,238,0.12);
  border: 1px solid rgba(34,211,238,0.4);
}

/* ─── Products ───────────────────────────────────────────── */
.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  margin-bottom: 72px;
}
.product.reverse .product-meta { order: 2; }
.product.reverse .product-art  { order: 1; }

@media (max-width: 880px) {
  .product { grid-template-columns: 1fr; gap: 28px; }
  .product.reverse .product-meta { order: 1; }
  .product.reverse .product-art  { order: 2; }
}

.product-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  background: rgba(52, 211, 153, 0.12);
  color: #6ee7b7;
  border: 1px solid rgba(52, 211, 153, 0.3);
  margin-bottom: 16px;
}
.product-badge.soon {
  background: rgba(34, 211, 238, 0.10);
  color: #67e8f9;
  border-color: rgba(34, 211, 238, 0.3);
}
.product-name {
  display: flex; align-items: center; gap: 14px;
  font-size: clamp(28px, 3.4vw, 40px);
  letter-spacing: -0.025em;
  font-weight: 800;
  margin: 0 0 10px;
  line-height: 1.1;
}
.product-icon {
  flex: none;
  width: 48px; height: 48px;
  border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 12px 30px -12px rgba(99,102,241,0.6);
}
.product-icon svg { width: 26px; height: 26px; }

.product-tagline {
  font-size: 18px;
  color: var(--text);
  margin: 0 0 14px;
  font-weight: 500;
}
.product-desc {
  font-size: 15.5px;
  color: var(--text-dim);
  margin: 0 0 18px;
}
.product-features {
  list-style: none; padding: 0; margin: 0 0 24px;
  display: grid; gap: 9px;
}
.product-features li {
  position: relative;
  padding-left: 22px;
  font-size: 14.5px;
  color: var(--text-dim);
}
.product-features li::before {
  content: "";
  position: absolute; left: 0; top: 9px;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--grad);
}
.product-cta { display: flex; flex-wrap: wrap; gap: 10px; }

.product-art {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: linear-gradient(135deg, rgba(167,139,250,0.06), rgba(34,211,238,0.04));
  border: 1px solid var(--border);
  padding: 14px;
  transition: transform .35s ease, box-shadow .35s ease;
  box-shadow: var(--shadow-soft);
}
.product-art:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-strong);
}
.product-art svg { width: 100%; height: auto; border-radius: calc(var(--radius-lg) - 8px); }

/* ─── Always growing card ───────────────────────────────── */
.growing {
  margin-top: 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-strong);
  background:
    linear-gradient(135deg, rgba(167,139,250,0.10), rgba(34,211,238,0.06)),
    rgba(255,255,255,0.02);
  padding: 32px;
  position: relative; overflow: hidden;
}
.growing::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 90% 0%, rgba(167,139,250,0.18), transparent 50%);
  pointer-events: none;
}
.growing-inner {
  display: flex; gap: 20px; align-items: center;
  position: relative;
  flex-wrap: wrap;
}
.growing-glyph {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--grad);
  display: inline-flex; align-items: center; justify-content: center;
  color: #0b0b18;
  flex: none;
  box-shadow: 0 12px 30px -10px rgba(167, 139, 250, 0.6);
}
.growing-glyph svg { width: 26px; height: 26px; }
.growing h3 {
  margin: 0 0 6px;
  font-size: 22px; letter-spacing: -0.02em; font-weight: 700;
}
.growing p { margin: 0; color: var(--text-dim); font-size: 15px; }
.growing a { color: #c4b5fd; border-bottom: 1px dashed rgba(196,181,253,0.5); }
.growing a:hover { color: #fff; border-color: #fff; }

/* ─── Footer ─────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  background: rgba(7,7,13,0.6);
  backdrop-filter: blur(10px);
  margin-top: 60px;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 36px var(--pad);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 18px;
  font-size: 14px; color: var(--text-dim);
}
.footer-brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; color: var(--text);
}
.footer-brand .brand-mark { width: 24px; height: 24px; border-radius: 6px; }
.footer-tag { margin: 0; flex: 1; text-align: center; min-width: 200px; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a { transition: color .2s ease; }
.footer-links a:hover { color: #fff; }

/* ─── Reveal-on-scroll ──────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
}
.reveal.in { opacity: 1; transform: none; }

/* ─── Reduced motion ─────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
