:root {
  --blue: #3B6EE8;
  --blue-dark: #2855C4;
  --blue-light: #EEF3FD;
  --blue-mid: #6B93F0;
  --ink: #0F1523;
  --ink-2: #2D3748;
  --ink-3: #64748B;
  --ink-4: #94A3B8;
  --border: #E2E8F0;
  --bg: #FAFBFD;
  --white: #FFFFFF;
  --green: #10B981;
  --amber: #F59E0B;
  --red: #EF4444;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(15,21,35,.06), 0 4px 16px rgba(15,21,35,.04);
  --shadow-md: 0 4px 24px rgba(59,110,232,.12), 0 1px 4px rgba(15,21,35,.08);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* ── HEADER ──────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250,251,253,.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
}
.nav-inner {
  max-width: 1140px; margin: 0 auto;
  display: flex; align-items: center;
  height: 60px; gap: 2rem;
}
.logo {
  display: flex; align-items: center; gap: .6rem;
  text-decoration: none; color: var(--blue);
  flex-shrink: 0;
}
.logo-text {
  font-size: 18px; font-weight: 600;
  letter-spacing: .04em; color: var(--ink);
}
.logo-text span { color: var(--blue); }
.nav-links {
  display: flex; gap: .25rem; margin-left: auto;
  list-style: none;
}
.nav-links a {
  display: block; padding: .4rem .85rem;
  font-size: 14px; font-weight: 500; color: var(--ink-3);
  text-decoration: none; border-radius: 6px;
  transition: color .15s, background .15s;
}
.nav-links a:hover { color: var(--blue); background: var(--blue-light); }
.nav-right { display: flex; gap: .75rem; margin-left: 1.5rem; }
.btn-sm {
  display: inline-flex; align-items: center;
  padding: .45rem 1rem; border-radius: 8px;
  font-size: 14px; font-weight: 500; cursor: pointer;
  text-decoration: none; transition: all .15s;
  border: none;
}
.btn-outline {
  border: 1.5px solid var(--border);
  color: var(--ink-2); background: transparent;
}
.btn-outline:hover { border-color: var(--blue); color: var(--blue); }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }

.lang-switcher { display: flex; gap: .25rem; margin-left: .5rem; }
.lang-btn {
  padding: .3rem .55rem; font-size: 12px; font-weight: 500;
  color: var(--ink-4); background: none; border: none; cursor: pointer;
  border-radius: 4px; transition: all .15s;
}
.lang-btn.active { color: var(--blue); background: var(--blue-light); }
.lang-btn:hover { color: var(--ink-2); }

/* ── HERO ─────────────────────────────────────────────── */
.hero {
  padding: 7rem 2rem 5rem;
  max-width: 1140px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 4rem; align-items: center;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .3rem .9rem; border-radius: 999px;
  background: var(--blue-light); color: var(--blue);
  font-size: 13px; font-weight: 500; margin-bottom: 1.5rem;
}
.hero-badge::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--blue); animation: pulse 2s infinite;
}
@keyframes pulse {
  0%,100% { opacity: 1; transform: scale(1); }
  50% { opacity: .5; transform: scale(1.4); }
}
.hero h1 {
  font-size: clamp(2.2rem, 4vw, 3.25rem);
  font-weight: 600; line-height: 1.15;
  letter-spacing: -.03em; margin-bottom: 1.25rem;
  color: var(--ink);
}
.hero h1 em { font-style: normal; color: var(--blue); }
.hero p {
  font-size: 1.1rem; color: var(--ink-3);
  line-height: 1.7; margin-bottom: 2rem;
  max-width: 480px;
}
.hero-actions { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.btn-lg {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .85rem 1.8rem; border-radius: var(--radius-sm);
  font-size: 15px; font-weight: 600; cursor: pointer;
  text-decoration: none; transition: all .18s; border: none;
}
.btn-lg.btn-primary { background: var(--blue); color: #fff; }
.btn-lg.btn-primary:hover { background: var(--blue-dark); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(59,110,232,.3); }
.btn-lg.btn-ghost { color: var(--ink-2); font-weight: 500; }
.btn-lg.btn-ghost:hover { color: var(--blue); }
.hero-note { font-size: 13px; color: var(--ink-4); margin-top: .75rem; }

/* Hero visual */
.hero-visual { position: relative; }
.result-card {
  background: var(--white); border-radius: var(--radius);
  border: 1px solid var(--border); padding: 1.5rem;
  box-shadow: var(--shadow);
}
.result-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.25rem;
}
.result-title { font-size: 13px; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: .06em; }
.convergence {
  font-family: 'DM Mono', monospace;
  font-size: 2rem; font-weight: 500; color: var(--ink);
}
.convergence span { color: var(--blue); }
.result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.result-cell {
  padding: .9rem 1rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.result-cell-label { font-size: 11px; color: var(--ink-4); font-weight: 500; text-transform: uppercase; letter-spacing: .05em; margin-bottom: .3rem; }
.result-cell-value { font-family: 'DM Mono', monospace; font-size: 1.5rem; font-weight: 500; }
.c-green { color: var(--green); }
.c-amber { color: var(--amber); }
.c-red { color: var(--red); }
.result-footer { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); display: flex; gap: .5rem; }
.tag {
  font-size: 12px; font-weight: 500; padding: .25rem .65rem;
  border-radius: 4px; background: var(--blue-light); color: var(--blue);
}
.tag.gray { background: #F1F5F9; color: var(--ink-3); }

/* Floating labels on hero */
.hero-visual .float-label {
  position: absolute; background: var(--white);
  border: 1px solid var(--border); border-radius: 8px;
  padding: .5rem .85rem; font-size: 12px; font-weight: 500;
  box-shadow: var(--shadow); display: flex; align-items: center; gap: .4rem;
  animation: floatUp 6s ease-in-out infinite;
}
.float-label-1 { top: -1.5rem; right: 1rem; animation-delay: 0s; }
.float-label-2 { bottom: -1rem; left: .5rem; animation-delay: 3s; }
@keyframes floatUp { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.dot { width: 8px; height: 8px; border-radius: 50%; }

/* ── LOGOS BAR ────────────────────────────────────────── */
.logos-bar {
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 2rem; text-align: center;
}
.logos-bar-label { font-size: 13px; color: var(--ink-4); margin-bottom: 1.5rem; font-weight: 500; text-transform: uppercase; letter-spacing: .08em; }
.logos-list { display: flex; justify-content: center; align-items: center; gap: 3rem; flex-wrap: wrap; }
.logos-list span { font-size: 13px; font-weight: 600; color: var(--ink-4); letter-spacing: .03em; }

/* ── SECTION BASE ─────────────────────────────────────── */
.section { padding: 5rem 2rem; }
.section-inner { max-width: 1140px; margin: 0 auto; }
.section-label {
  font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em;
  color: var(--blue); margin-bottom: .75rem;
}
.section-title {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 600; letter-spacing: -.025em;
  line-height: 1.2; margin-bottom: 1rem; color: var(--ink);
}
.section-sub { font-size: 1.05rem; color: var(--ink-3); max-width: 520px; line-height: 1.7; }

/* ── HOW IT WORKS ─────────────────────────────────────── */
.how-bg { background: var(--white); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; margin-top: 3rem; position: relative; }
.steps::before {
  content: ''; position: absolute; top: 28px; left: 10%; right: 10%;
  height: 1px; background: var(--border); z-index: 0;
}
.step { text-align: center; padding: 0 1rem; position: relative; z-index: 1; }
.step-num {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--white); border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem; font-family: 'DM Mono', monospace;
  font-size: 15px; font-weight: 500; color: var(--ink-3);
  transition: all .2s; position: relative; z-index: 2;
}
.step:hover .step-num { background: var(--blue); border-color: var(--blue); color: #fff; transform: scale(1.08); }
.step-title { font-size: 14px; font-weight: 600; margin-bottom: .4rem; color: var(--ink); }
.step-desc { font-size: 13px; color: var(--ink-3); line-height: 1.6; }

/* ── FEATURES ─────────────────────────────────────────── */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin-top: 3rem; }
.feature-card {
  padding: 1.75rem; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--white);
  transition: all .2s;
}
.feature-card:hover { border-color: var(--blue); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.feature-icon {
  width: 44px; height: 44px; border-radius: 10px;
  background: var(--blue-light); display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem; font-size: 20px;
}
.feature-title { font-size: 15px; font-weight: 600; margin-bottom: .5rem; color: var(--ink); }
.feature-desc { font-size: 14px; color: var(--ink-3); line-height: 1.6; }

/* ── PRICING ──────────────────────────────────────────── */
.pricing-bg { background: var(--white); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin-top: 3rem; }
.plan {
  padding: 2rem; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--bg);
  position: relative;
}
.plan.popular {
  border-color: var(--blue); background: var(--white);
  box-shadow: var(--shadow-md);
}
.plan-badge {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--blue); color: #fff; font-size: 11px; font-weight: 600;
  padding: .25rem .8rem; border-radius: 999px; letter-spacing: .04em; white-space: nowrap;
}
.plan-name { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); margin-bottom: .75rem; }
.plan-price { margin-bottom: .25rem; }
.plan-price-val {
  font-family: 'DM Mono', monospace; font-size: 2.5rem; font-weight: 500; color: var(--ink);
}
.plan-price-period { font-size: 14px; color: var(--ink-3); margin-left: .25rem; }
.plan-desc { font-size: 13px; color: var(--ink-4); margin-bottom: 1.5rem; line-height: 1.5; }
.plan-features { list-style: none; margin-bottom: 2rem; display: flex; flex-direction: column; gap: .6rem; }
.plan-features li { font-size: 14px; color: var(--ink-2); display: flex; align-items: flex-start; gap: .6rem; }
.plan-features li::before { content: '✓'; color: var(--green); font-weight: 700; flex-shrink: 0; margin-top: .1rem; }
.plan-features li.dim::before { content: '—'; color: var(--ink-4); }
.plan-features li.dim { color: var(--ink-4); }
.btn-plan {
  display: block; width: 100%; padding: .75rem;
  border-radius: var(--radius-sm); font-size: 14px; font-weight: 600;
  text-align: center; text-decoration: none; cursor: pointer;
  border: none; transition: all .15s;
}
.btn-plan.outline { border: 1.5px solid var(--border); color: var(--ink-2); background: transparent; }
.btn-plan.outline:hover { border-color: var(--blue); color: var(--blue); }
.btn-plan.filled { background: var(--blue); color: #fff; }
.btn-plan.filled:hover { background: var(--blue-dark); }

/* ── API SECTION ──────────────────────────────────────── */
.api-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; margin-top: 3rem; }
.api-code {
  background: #0F1523; border-radius: var(--radius);
  padding: 1.5rem; overflow-x: auto;
  border: 1px solid rgba(255,255,255,.06);
}
.api-code pre { font-family: 'DM Mono', monospace; font-size: 13px; line-height: 1.7; color: #CBD5E1; }
.api-code .k { color: #6B93F0; }
.api-code .s { color: #86EFAC; }
.api-code .c { color: #64748B; }
.api-code .n { color: #FCA5A5; }
.api-points { display: flex; flex-direction: column; gap: 1rem; margin-top: 1.75rem; }
.api-point { display: flex; gap: 1rem; align-items: flex-start; }
.api-point-icon {
  width: 36px; height: 36px; border-radius: 8px;
  background: var(--blue-light); display: flex; align-items: center;
  justify-content: center; font-size: 16px; flex-shrink: 0;
}
.api-point-title { font-size: 14px; font-weight: 600; color: var(--ink); margin-bottom: .2rem; }
.api-point-desc { font-size: 13px; color: var(--ink-3); line-height: 1.5; }

/* ── CTA ──────────────────────────────────────────────── */
.cta-section {
  padding: 5rem 2rem;
  background: linear-gradient(135deg, #1E3A8A 0%, #2855C4 40%, #3B6EE8 100%);
  text-align: center; position: relative; overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(107,147,240,.25) 0%, transparent 60%),
              radial-gradient(circle at 70% 50%, rgba(59,110,232,.15) 0%, transparent 60%);
}
.cta-section > * { position: relative; z-index: 1; }
.cta-title { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 600; color: #fff; letter-spacing: -.025em; margin-bottom: .75rem; }
.cta-sub { font-size: 1.05rem; color: rgba(255,255,255,.75); margin-bottom: 2.5rem; }
.cta-actions { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }
.btn-cta-white { background: #fff; color: var(--blue); }
.btn-cta-white:hover { background: rgba(255,255,255,.9); transform: translateY(-2px); }
.btn-cta-outline { border: 2px solid rgba(255,255,255,.4); color: #fff; }
.btn-cta-outline:hover { border-color: rgba(255,255,255,.8); background: rgba(255,255,255,.08); }

/* ── FOOTER ───────────────────────────────────────────── */
footer {
  padding: 3rem 2rem 2rem;
  border-top: 1px solid var(--border); background: var(--white);
}
.footer-inner { max-width: 1140px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 3rem; margin-bottom: 3rem; }
.footer-brand p { font-size: 14px; color: var(--ink-3); margin-top: .75rem; max-width: 260px; line-height: 1.6; }
.footer-col-title { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-4); margin-bottom: 1rem; }
.footer-links { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.footer-links a { font-size: 14px; color: var(--ink-3); text-decoration: none; transition: color .15s; }
.footer-links a:hover { color: var(--blue); }
.footer-bottom { padding-top: 1.5rem; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.footer-bottom p { font-size: 13px; color: var(--ink-4); }
.footer-bottom-links { display: flex; gap: 1.5rem; }
.footer-bottom-links a { font-size: 13px; color: var(--ink-4); text-decoration: none; }
.footer-bottom-links a:hover { color: var(--ink-2); }

/* ── RESPONSIVE ───────────────────────────────────────── */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 2.5rem; padding: 4rem 1.25rem 3rem; }
  .steps { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .steps::before { display: none; }
  .features { grid-template-columns: 1fr 1fr; }
  .plans { grid-template-columns: 1fr; max-width: 440px; margin-left: auto; margin-right: auto; }
  .api-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .nav-links { display: none; }
}
@media (max-width: 600px) {
  .features { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-visual .float-label { display: none; }
  .section { padding: 3rem 1.25rem; }
  .logos-list { gap: 1.5rem; }
}

/* ── FADE IN ON SCROLL ────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .5s ease, transform .5s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }