:root {
  --bg: #070b14;
  --bg-2: #0d1424;
  --card: #111827;
  --border: #243044;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #2dd4bf;
  --accent-2: #38bdf8;
  --danger: #f87171;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

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

a:hover {
  text-decoration: underline;
}

.bg-glow {
  position: fixed;
  inset: -20% auto auto 50%;
  width: 70vw;
  height: 50vh;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(45, 212, 191, 0.16), transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.nav,
main,
.footer {
  position: relative;
  z-index: 1;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  position: sticky;
  top: 0;
  backdrop-filter: blur(12px);
  background: rgba(7, 11, 20, 0.8);
  border-bottom: 1px solid rgba(36, 48, 68, 0.8);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

.brand-orb {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 32% 28%, #fff9, transparent 30%),
    radial-gradient(circle at 50% 50%, #5eead4, #0ea5e9 60%, #0369a1);
  box-shadow: 0 0 12px rgba(45, 212, 191, 0.5);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--muted);
  font-size: 0.92rem;
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--text);
}

main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 24px 20px 80px;
}

.hero {
  padding: 48px 0 28px;
  text-align: center;
}

.eyebrow {
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.8rem;
}

h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.1;
  margin: 12px 0 16px;
  letter-spacing: -0.03em;
}

.gradient-text {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  max-width: 720px;
  margin: 0 auto 24px;
  color: var(--muted);
  font-size: 1.08rem;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.hero-actions.center {
  margin-top: 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  color: var(--text);
  background: var(--card);
}

.btn-small {
  padding: 8px 14px;
  font-size: 0.9rem;
}

.btn-primary {
  background: linear-gradient(135deg, #0f766e, #0284c7);
  border-color: transparent;
  color: white;
}

.btn-primary:hover,
.btn-ghost:hover {
  text-decoration: none;
  filter: brightness(1.08);
}

.btn-ghost {
  background: transparent;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
}

.hero-stats div {
  display: flex;
  flex-direction: column;
  min-width: 100px;
}

.hero-stats strong {
  font-size: 1.4rem;
}

.hero-stats span {
  color: var(--muted);
  font-size: 0.85rem;
}

.features,
.site-grid,
.install-grid {
  display: grid;
  gap: 14px;
}

.features {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  margin: 36px 0 56px;
}

.feature-card,
.install-card,
.privacy-card,
.site-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}

.feature-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(45, 212, 191, 0.12);
  color: var(--accent);
  margin-bottom: 10px;
  font-weight: 700;
}

.feature-card h3,
.install-card h3 {
  margin: 0 0 8px;
}

.feature-card p,
.install-card p,
.install-card li,
.privacy-card li,
.fineprint,
.demo-legend p {
  color: var(--muted);
  margin: 0;
}

.section-head {
  text-align: center;
  margin-bottom: 22px;
}

.section-head h2 {
  margin: 0 0 8px;
  font-size: 1.8rem;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.how {
  margin-bottom: 56px;
}

.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.steps li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.step-num {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #0f766e, #0284c7);
  font-weight: 800;
  flex-shrink: 0;
}

.steps h3 {
  margin: 0 0 4px;
}

.steps p {
  margin: 0;
  color: var(--muted);
}

.demo {
  margin-bottom: 56px;
}

.demo-shell {
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.demo-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: rgba(17, 24, 39, 0.8);
}

.demo-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.demo-tab {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
  font-weight: 600;
}

.demo-tab.is-active {
  color: var(--text);
  border-color: var(--accent);
  background: rgba(45, 212, 191, 0.12);
}

.demo-status {
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 600;
}

.demo-chat {
  min-height: 260px;
  max-height: 340px;
  overflow: auto;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bubble {
  max-width: min(520px, 92%);
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 0.95rem;
}

.bubble.user {
  align-self: flex-end;
  background: #164e63;
}

.bubble.ai {
  align-self: flex-start;
  background: #1f2937;
  border: 1px solid var(--border);
}

.bubble.system {
  align-self: center;
  background: rgba(45, 212, 191, 0.1);
  border: 1px dashed rgba(45, 212, 191, 0.35);
  color: var(--accent);
  font-size: 0.85rem;
}

.demo-composer {
  border-top: 1px solid var(--border);
  padding: 12px;
  background: #0b1220;
}

.chip-row {
  margin-bottom: 8px;
}

.file-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #1f2937;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px 10px;
}

.file-badge {
  font-size: 0.7rem;
  font-weight: 800;
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.15);
  padding: 2px 6px;
  border-radius: 6px;
}

.file-name {
  font-size: 0.88rem;
  font-weight: 600;
}

.chip-x {
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 1rem;
}

.composer-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

#demoInput {
  flex: 1;
  border: 1px solid var(--border);
  background: #111827;
  color: var(--text);
  border-radius: 999px;
  padding: 12px 14px;
  outline: none;
}

#demoInput:focus {
  border-color: var(--accent);
}

.orb-btn,
.send-btn {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  position: relative;
}

.orb-btn {
  background:
    radial-gradient(circle at 32% 28%, #fff9, transparent 30%),
    radial-gradient(circle at 50% 50%, #5eead4, #0ea5e9 55%, #0369a1);
  box-shadow: 0 0 16px rgba(45, 212, 191, 0.45);
}

.orb-btn.has-active {
  box-shadow:
    0 0 0 2px rgba(45, 212, 191, 0.95),
    0 0 18px rgba(14, 165, 233, 0.55);
}

.orb-core {
  display: block;
  width: 10px;
  height: 10px;
  margin: 0 auto;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 8px #fff;
}

.orb-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #34d399;
  border: 2px solid #0b1220;
}

.send-btn {
  background: #2563eb;
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
}

.orb-menu {
  position: absolute;
  right: 16px;
  bottom: 78px;
  width: min(280px, calc(100% - 32px));
  background: #111827;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 5;
}

.orb-menu[hidden],
.chip-row[hidden],
.orb-dot[hidden],
.orb-menu-active[hidden] {
  display: none !important;
}

.orb-menu-active {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
}

.orb-menu-active .dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.orb-menu button {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  text-align: left;
  border: none;
  background: transparent;
  color: var(--text);
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}

.orb-menu button:hover {
  background: #1f2937;
}

.orb-menu .mi {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(45, 212, 191, 0.14);
  color: var(--accent);
  flex-shrink: 0;
}

.orb-menu strong {
  display: block;
}

.orb-menu small {
  display: block;
  color: var(--muted);
  margin-top: 2px;
}

.demo-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.sites,
.privacy,
.install {
  margin-bottom: 56px;
}

.site-grid {
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.site-card {
  text-align: center;
  font-weight: 700;
}

.fineprint {
  text-align: center;
  margin-top: 14px;
  font-size: 0.9rem;
}

.privacy-card ul {
  margin: 12px 0 16px;
  padding-left: 1.1rem;
}

.install-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.install-card ol {
  margin: 8px 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.install-card code,
.privacy-card code {
  background: #0b1220;
  padding: 1px 6px;
  border-radius: 6px;
  font-size: 0.88em;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 20px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.9rem;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(12px);
  background: #111827;
  border: 1px solid #0d9488;
  color: var(--text);
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transition: 0.2s ease;
  z-index: 20;
  max-width: min(420px, calc(100vw - 24px));
  text-align: center;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 720px) {
  .nav-links a:not(.btn) {
    display: none;
  }
  .hero {
    padding-top: 28px;
  }
}
