:root {
  --bg: #070b16;
  --bg-2: #0c1324;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.09);
  --text: #e6ebf5;
  --muted: #9aa6bf;
  --teal: #22d3ee;
  --indigo: #6366f1;
  --glow: linear-gradient(120deg, #22d3ee 0%, #6366f1 60%, #a855f7 100%);
  --radius: 18px;
  --max: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; }
h1, h2, h3, h4 { font-family: "Space Grotesk", "Inter", sans-serif; line-height: 1.15; margin: 0 0 .6em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.grad { background: var(--glow); -webkit-background-clip: text; background-clip: text; color: transparent; }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--teal); margin-bottom: 14px; }
.muted { color: var(--muted); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(14px); background: rgba(7, 11, 22, 0.72); border-bottom: 1px solid var(--border); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-family: "Space Grotesk", sans-serif; font-weight: 700; font-size: 1.2rem; }
.brand:hover { text-decoration: none; }
.brand img { width: 32px; height: 32px; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { color: var(--muted); font-size: .95rem; font-weight: 500; }
.nav-links a:hover, .nav-links a.active { color: var(--text); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border); color: var(--text); border-radius: 10px; padding: 8px 10px; cursor: pointer; }

.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: .95rem; border: 1px solid transparent; cursor: pointer; transition: transform .2s, box-shadow .2s, background .2s; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--glow); color: #06101f; box-shadow: 0 8px 30px rgba(34, 211, 238, .25); }
.btn-primary:hover { box-shadow: 0 10px 40px rgba(99, 102, 241, .4); }
.btn-ghost { border-color: var(--border); color: var(--text); background: var(--surface); }
.nav-links .btn { color: #06101f; padding: 9px 18px; }

/* Hero */
.hero { position: relative; padding: 110px 0 90px; overflow: hidden; }
.hero::before, .hero::after { content: ""; position: absolute; border-radius: 50%; filter: blur(90px); opacity: .45; z-index: -1; }
.hero::before { width: 520px; height: 520px; background: #0891b2; top: -160px; left: -120px; }
.hero::after { width: 480px; height: 480px; background: #4f46e5; bottom: -200px; right: -100px; }
.hero p.lead { font-size: 1.2rem; color: var(--muted); max-width: 640px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 30px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 50px; align-items: center; }
.phone { position: relative; margin: 0 auto; width: 260px; height: 520px; border-radius: 42px; border: 1px solid var(--border); background: linear-gradient(160deg, #111a30, #0a0f1d); box-shadow: 0 30px 80px rgba(0,0,0,.5), 0 0 0 8px rgba(255,255,255,.03); padding: 22px 18px; }
.phone .notch { width: 90px; height: 24px; border-radius: 0 0 14px 14px; background: #05080f; margin: -22px auto 18px; }
.chat { display: flex; flex-direction: column; gap: 12px; font-size: .85rem; }
.bubble { padding: 10px 14px; border-radius: 16px; max-width: 85%; }
.bubble.user { align-self: flex-end; background: var(--indigo); color: #fff; border-bottom-right-radius: 4px; }
.bubble.ai { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.wave { display: flex; gap: 4px; align-items: flex-end; height: 40px; margin-top: 18px; justify-content: center; }
.wave span { width: 6px; border-radius: 4px; background: var(--glow); animation: wave 1.2s ease-in-out infinite; }
.wave span:nth-child(2n) { animation-delay: .2s; } .wave span:nth-child(3n) { animation-delay: .4s; }
@keyframes wave { 0%,100% { height: 8px; } 50% { height: 36px; } }

/* Sections */
section { padding: 90px 0; }
.section-head { max-width: 720px; margin-bottom: 50px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.alt { background: var(--bg-2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.grid { display: grid; gap: 22px; }
.grid > * { min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; transition: border-color .25s, transform .25s; }
.card:hover { border-color: rgba(34, 211, 238, .35); transform: translateY(-3px); }
.card p { color: var(--muted); margin: 0; }
.icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: rgba(34, 211, 238, .1); color: var(--teal); margin-bottom: 18px; font-size: 1.4rem; }
.icon svg { width: 24px; height: 24px; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; text-align: center; }
.stat strong { display: block; font-family: "Space Grotesk", sans-serif; font-size: 2.4rem; }
.stat span { color: var(--muted); font-size: .92rem; }

.pill { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: .75rem; font-weight: 600; background: var(--surface-2); border: 1px solid var(--border); color: var(--muted); margin: 0 6px 6px 0; }

.steps { counter-reset: step; }
.step { position: relative; padding-left: 64px; margin-bottom: 30px; }
.step::before { counter-increment: step; content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 0; font-family: "Space Grotesk", sans-serif; font-weight: 700; font-size: 1.4rem; color: var(--teal); }
.step p { color: var(--muted); margin: 0; }

.cta { text-align: center; border-radius: 28px; padding: 64px 28px; background: radial-gradient(circle at 20% 0%, rgba(34, 211, 238, .25), transparent 55%), radial-gradient(circle at 90% 100%, rgba(99, 102, 241, .3), transparent 55%), var(--bg-2); border: 1px solid var(--border); }

/* Publications */
.pub { padding: 24px 0; border-bottom: 1px solid var(--border); }
.pub:last-child { border-bottom: 0; }
.pub h3 { margin-bottom: 6px; }
.pub .meta { color: var(--muted); font-size: .9rem; margin-bottom: 8px; }

/* Page header (legal etc.) */
.page-hero { padding: 80px 0 40px; border-bottom: 1px solid var(--border); background: radial-gradient(circle at 10% 0%, rgba(34, 211, 238, .14), transparent 50%); }
.prose { max-width: 820px; padding: 50px 20px 90px; margin: 0 auto; }
.prose h2 { font-size: 1.5rem; margin-top: 2.2em; }
.prose h3 { margin-top: 1.6em; }
.prose p, .prose li { color: #c8d0e0; }
.prose ul { padding-left: 1.3em; }
.prose li { margin-bottom: .4em; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0 1.6em; font-size: .93rem; }
.prose th, .prose td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; vertical-align: top; }
.prose th { background: var(--surface-2); }
.toc { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 26px; }
.toc ol { margin: 0; padding-left: 1.2em; columns: 2; }

/* Forms */
.form { display: grid; gap: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label { display: block; font-size: .88rem; font-weight: 600; margin-bottom: 6px; }
input, select, textarea { width: 100%; padding: 13px 15px; border-radius: 12px; border: 1px solid var(--border); background: rgba(255,255,255,.03); color: var(--text); font: inherit; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(34, 211, 238, .15); }
select option { background: var(--bg-2); }
textarea { min-height: 150px; resize: vertical; }
.form-note { font-size: .85rem; color: var(--muted); }
.contact-item { display: flex; gap: 14px; margin-bottom: 22px; }
.contact-item .icon { margin: 0; flex: none; }
.contact-item p { margin: 0; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 60px 0 30px; background: #050812; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 36px; }
.site-footer h4 { font-size: .95rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: var(--muted); font-size: .92rem; }
.site-footer a:hover { color: var(--text); }
.footer-bottom { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; color: var(--muted); font-size: .85rem; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } .wave span { animation: none; height: 20px; } }

@media (max-width: 960px) {
  .hero-grid, .grid-2 { grid-template-columns: 1fr; }
  .grid-3, .grid-4, .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .phone { display: none; }
}
@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--bg-2); border-bottom: 1px solid var(--border); padding: 10px 20px 20px; }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 0; width: 100%; }
  .grid-3, .grid-4, .stats, .form-row, .footer-grid { grid-template-columns: 1fr; }
  .toc ol { columns: 1; }
  section { padding: 64px 0; }
  .hero { padding: 70px 0 60px; }
}
