:root {
  --bg: #0a0a0f;
  --bg-soft: #10111a;
  --bg-card: rgba(19, 24, 34, 0.56);
  --stroke: rgba(255, 255, 255, 0.13);
  --text: #f4f6ff;
  --muted: #a7acc3;
  --mint: #00e5b0;
  --blue: #3d6aff;
  --danger: #7c1f2d;
  --success: #114331;
  --radius: 18px;
  --radius-sm: 12px;
  --container: 1140px;
}

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

html,
body {
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: "DM Sans", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 15% 10%, rgba(61, 106, 255, 0.2), transparent 30%),
    radial-gradient(circle at 82% 4%, rgba(0, 229, 176, 0.18), transparent 36%), var(--bg);
  line-height: 1.5;
  position: relative;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
}

.section {
  padding: 4rem 0;
  position: relative;
}

.section-kicker {
  color: var(--mint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  margin-bottom: 0.75rem;
}

.section-title {
  font-family: "Syne", sans-serif;
  font-size: clamp(1.75rem, 4vw, 2.8rem);
  line-height: 1.1;
  margin-bottom: 1.8rem;
}

.muted {
  color: var(--muted);
  margin-top: 1rem;
}

.navbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  transition: background-color 220ms ease, border-color 220ms ease, backdrop-filter 220ms ease;
  border-bottom: 1px solid transparent;
}

.navbar.scrolled {
  background: rgba(7, 8, 14, 0.68);
  backdrop-filter: blur(12px);
  border-color: var(--stroke);
}

.nav-inner {
  min-height: 76px;
  padding: 0.9rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
}

.logo-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(61, 106, 255, 0.2), rgba(0, 229, 176, 0.18));
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.logo-icon svg {
  width: 18px;
  height: 18px;
  stroke: var(--mint);
  stroke-width: 1.8;
  animation: shieldPulse 2.7s ease-in-out infinite;
}

.nav-links {
  width: 100%;
  display: flex;
  gap: 1.1rem;
  order: 3;
  overflow-x: auto;
  white-space: nowrap;
  padding-bottom: 0.2rem;
  color: var(--muted);
}

.nav-links a {
  transition: color 180ms ease;
}

.nav-links a:hover {
  color: #fff;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.94rem;
  padding: 0.72rem 1.15rem;
  border: 1px solid transparent;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(120deg, var(--mint), #34ffc8);
  color: #03291f;
  box-shadow: 0 10px 28px rgba(0, 229, 176, 0.34);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--stroke);
  color: #f8faff;
}

.hero {
  padding-top: 9rem;
}

.hero-grid {
  display: grid;
  gap: 1.6rem;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  border: 1px solid rgba(61, 106, 255, 0.45);
  background: rgba(61, 106, 255, 0.12);
  color: #c8d4ff;
  border-radius: 999px;
  font-size: 0.83rem;
  padding: 0.44rem 0.82rem;
  margin-bottom: 1rem;
}

.badge-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 5px rgba(0, 229, 176, 0.16);
}

h1,
h2,
h3 {
  font-family: "Syne", sans-serif;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2rem, 5vw, 3.7rem);
  line-height: 1.03;
  margin-bottom: 1rem;
}

.hero-subtitle {
  color: var(--muted);
  max-width: 64ch;
}

.hero-ctas {
  margin-top: 1.6rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.cta-note {
  color: var(--muted);
  font-size: 0.92rem;
}

.hero-doc-link {
  display: inline-block;
  color: #a8bcff;
  margin-top: 0.75rem;
}

.hero-doc-link:hover {
  color: #d6e0ff;
}

.hero-terminal {
  position: relative;
  border: 1px solid rgba(61, 106, 255, 0.42);
  background: linear-gradient(180deg, rgba(17, 22, 38, 0.95), rgba(10, 12, 20, 0.92));
  border-radius: var(--radius);
  box-shadow: 0 32px 46px rgba(0, 0, 0, 0.38), 0 0 0 1px rgba(0, 229, 176, 0.08);
  overflow: hidden;
}

.terminal-head {
  padding: 0.65rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  display: flex;
  align-items: center;
  gap: 0.42rem;
}

.terminal-head span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.terminal-head span:nth-child(1) {
  background: #ff6d79;
}

.terminal-head span:nth-child(2) {
  background: #ffd661;
}

.terminal-head span:nth-child(3) {
  background: #2ee7a5;
}

.terminal-head p {
  margin-left: 0.6rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.terminal-code {
  min-height: 330px;
  padding: 1.15rem;
  font-size: 0.82rem;
  color: #d9ecff;
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.social-proof .section-kicker {
  margin-bottom: 0.95rem;
}

.logo-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.logo-pill {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--stroke);
  color: #d5d9ea;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  font-weight: 600;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.44rem;
}

.logo-pill svg {
  width: 14px;
  height: 14px;
  stroke: #9bb3ff;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.compare-grid {
  display: grid;
  gap: 1rem;
}

.compare-card {
  border-radius: var(--radius);
  padding: 1.3rem;
  border: 1px solid var(--stroke);
}

.compare-card h2 {
  font-size: 1.4rem;
  margin-bottom: 0.85rem;
}

.compare-card ul {
  list-style: none;
  display: grid;
  gap: 0.65rem;
  color: #f0f2ff;
}

.compare-card li {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.75rem;
}

.compare-card.before {
  background: linear-gradient(150deg, rgba(124, 31, 45, 0.35), rgba(124, 31, 45, 0.08));
  box-shadow: inset 0 0 0 1px rgba(255, 84, 107, 0.18);
}

.compare-card.after {
  background: linear-gradient(150deg, rgba(17, 67, 49, 0.46), rgba(17, 67, 49, 0.12));
  box-shadow: inset 0 0 0 1px rgba(0, 229, 176, 0.23);
}

.counter {
  color: var(--mint);
  font-weight: 700;
}

.feature-grid {
  display: grid;
  gap: 1rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 1.1rem;
  backdrop-filter: blur(12px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.feature-card:hover,
.price-card:hover,
.arch-card:hover,
.snippet-card:hover {
  transform: translateY(-5px) scale(1.01);
  border-color: rgba(0, 229, 176, 0.35);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.32), 0 0 22px rgba(0, 229, 176, 0.13);
}

.icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(61, 106, 255, 0.15);
  border: 1px solid rgba(61, 106, 255, 0.35);
  margin-bottom: 0.78rem;
}

.icon svg {
  width: 22px;
  height: 22px;
  stroke: #84a1ff;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.42rem;
}

.feature-card p {
  color: var(--muted);
}

.feature-card code {
  color: #94c8ff;
}

.agent-grid {
  display: grid;
  gap: 1rem;
}

.flow {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
  align-items: center;
}

.flow-node {
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.85rem;
}

.flow-arrow {
  color: var(--mint);
  font-weight: 700;
}

.snippet-card {
  background: var(--bg-card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 1.15rem;
  backdrop-filter: blur(10px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.snippet-title {
  color: #bcffe8;
  margin-bottom: 0.6rem;
}

.snippet-card pre {
  background: rgba(8, 11, 20, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 13px;
  padding: 1rem;
  overflow-x: auto;
}

.snippet-card code {
  font-size: 0.88rem;
  color: #dbe7ff;
}

.arch-grid {
  display: grid;
  gap: 0.9rem;
}

.arch-card {
  background: var(--bg-card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  padding: 0.95rem;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.arch-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.arch-card p {
  color: var(--muted);
}

.arch-performance {
  margin-top: 1rem;
  color: #d2fff1;
  background: rgba(0, 229, 176, 0.12);
  border: 1px solid rgba(0, 229, 176, 0.3);
  border-radius: var(--radius-sm);
  padding: 0.8rem 0.95rem;
}

.pricing-grid {
  display: grid;
  gap: 1rem;
}

.pricing-grid-5 {
  align-items: start;
}

.price-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 1.25rem;
  backdrop-filter: blur(11px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
  display: flex;
  flex-direction: column;
}

.price-card.featured {
  border-color: var(--mint);
  box-shadow: 0 0 40px rgba(0, 229, 176, 0.18), 0 0 80px rgba(0, 229, 176, 0.06);
}

.plan-badge {
  display: inline-block;
  margin-bottom: 0.7rem;
  background: rgba(61, 106, 255, 0.2);
  border: 1px solid rgba(61, 106, 255, 0.5);
  color: #b5c8ff;
  border-radius: 999px;
  padding: 0.24rem 0.6rem;
  font-size: 0.74rem;
  width: fit-content;
}

.badge-dev {
  background: rgba(61, 106, 255, 0.15);
  border-color: rgba(61, 106, 255, 0.4);
  color: #a8bcff;
}

.badge-popular {
  background: linear-gradient(135deg, rgba(0, 229, 176, 0.25), rgba(0, 229, 176, 0.12));
  border-color: rgba(0, 229, 176, 0.6);
  color: #b8ffe8;
  animation: badgePulse 2.5s ease-in-out infinite;
}

@keyframes badgePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0, 229, 176, 0.3); }
  50% { box-shadow: 0 0 12px 2px rgba(0, 229, 176, 0.2); }
}

.price {
  font-family: "Syne", sans-serif;
  font-size: 1.82rem;
  margin: 0.32rem 0 0.2rem;
}

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

.price-subtitle {
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

.price-card ul {
  list-style: none;
  display: grid;
  gap: 0.44rem;
  color: var(--muted);
  margin-bottom: 1rem;
  flex: 1;
}

.price-card ul li::before {
  content: "\2713 ";
  color: var(--mint);
  margin-right: 0.3rem;
}

.price-card .btn {
  width: 100%;
}

.btn-accent {
  background: linear-gradient(120deg, var(--mint), #34ffc8);
  color: #03291f;
  box-shadow: 0 10px 28px rgba(0, 229, 176, 0.34);
  font-size: 1rem;
  padding: 0.82rem 1.15rem;
}

.plan-mention {
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.5rem;
}

.pricing-note {
  margin-top: 1rem;
  color: var(--muted);
  text-align: center;
}

.pricing-note-features {
  margin-top: 0.5rem;
  font-size: 0.85rem;
}

/* Pricing fade-up staggered animation */
.pricing.in-view .price-card.fade-up {
  animation: priceFadeUp 0.5s ease forwards;
  animation-delay: calc(var(--stagger, 0) * 100ms);
  opacity: 0;
}

@keyframes priceFadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.sources-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.source-pill {
  border-radius: 999px;
  padding: 0.45rem 0.78rem;
  font-size: 0.84rem;
  border: 1px solid rgba(0, 229, 176, 0.32);
  background: rgba(0, 229, 176, 0.09);
  color: #c6fff0;
}

.faq-list {
  display: grid;
  gap: 0.72rem;
}

.faq-item {
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  border: 0;
  background: transparent;
  color: #eef2ff;
  font-family: "DM Sans", sans-serif;
  font-size: 1rem;
  padding: 1rem;
  cursor: pointer;
}

.faq-question span {
  color: var(--mint);
  font-size: 1.3rem;
  transition: transform 180ms ease;
}

.faq-item.open .faq-question span {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 280ms ease;
}

.faq-answer p {
  color: var(--muted);
  padding: 0 1rem 1rem;
}

.final-cta {
  padding-bottom: 5rem;
}

.cta-box {
  border-radius: 26px;
  border: 1px solid rgba(61, 106, 255, 0.35);
  background: linear-gradient(135deg, rgba(61, 106, 255, 0.18), rgba(0, 229, 176, 0.12));
  padding: 1.4rem;
  text-align: center;
}

.cta-box h2 {
  font-size: clamp(1.6rem, 3vw, 2.45rem);
}

.cta-box p {
  margin-top: 0.6rem;
  color: #d2def9;
}

.cta-actions {
  margin-top: 1.05rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.82rem;
  flex-wrap: wrap;
}

.footer {
  border-top: 1px solid var(--stroke);
  background: rgba(6, 8, 14, 0.88);
  padding: 2rem 0 1rem;
}

.footer-grid {
  display: grid;
  gap: 1.2rem;
}

.footer-title {
  font-family: "Syne", sans-serif;
  margin-bottom: 0.5rem;
}

.footer-grid a {
  display: block;
  color: var(--muted);
  margin: 0.25rem 0;
}

.footer-grid a:hover {
  color: #fff;
}

.footer-tagline {
  color: var(--muted);
  margin-top: 0.6rem;
}

.footer-badges {
  margin-top: 0.8rem;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.footer-badges span {
  font-size: 0.76rem;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 0.28rem 0.56rem;
  color: #ccd2e9;
}

.copyright {
  text-align: center;
  font-size: 0.84rem;
  color: #8f95ad;
  margin-top: 1rem;
}

.bg-orb {
  position: fixed;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  filter: blur(68px);
  opacity: 0.26;
  z-index: -2;
  pointer-events: none;
}

.orb-1 {
  background: #3d6aff;
  top: -70px;
  left: -70px;
}

.orb-2 {
  background: #00e5b0;
  bottom: 2%;
  right: -120px;
}

.bg-grid {
  position: fixed;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at 50% 40%, black 30%, transparent 75%);
  pointer-events: none;
  z-index: -3;
}

@media (min-width: 768px) {
  .section {
    padding: 5.3rem 0;
  }

  .nav-inner {
    flex-wrap: nowrap;
    gap: 1.2rem;
  }

  .nav-links {
    width: auto;
    order: 2;
    padding-bottom: 0;
    margin-left: auto;
    margin-right: 0.6rem;
  }

  .hero {
    padding-top: 10.6rem;
  }

  .hero-grid,
  .agent-grid {
    grid-template-columns: 1.05fr 0.95fr;
  }

  .hero-terminal {
    transform: perspective(1000px) rotateY(-5deg) rotateX(2deg);
  }

  .compare-grid {
    grid-template-columns: 1fr 1fr;
  }

  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .arch-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .pricing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pricing-grid-5 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pricing-grid-5 .price-card.featured {
    transform: scale(1.03);
  }

  .footer-grid {
    grid-template-columns: 1.45fr 1fr 1fr 1fr;
  }
}

/* Mobile: Pro card first */
@media (max-width: 767px) {
  .pricing-grid-5 {
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }

  .pricing-grid-5 .price-card.featured {
    order: -1;
  }
}

/* Large screens: 5-column pricing */
@media (min-width: 1200px) {
  :root {
    --container: 1320px;
  }

  .pricing-grid-5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.8rem;
  }

  .pricing-grid-5 .price-card.featured {
    transform: scale(1.05);
    z-index: 2;
  }

  .pricing-grid-5 .price-card.featured:hover {
    transform: scale(1.07) translateY(-5px);
  }
}

/* Medium screens: 3+2 layout */
@media (min-width: 768px) and (max-width: 1199px) {
  .pricing-grid-5 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
