:root {
  --bg: #ffffff;
  --fg: #0f1117;
  --muted: #5a6072;
  --card: #ffffff;
  --border: #e7e9f0;
  --subtle: #f6f7fb;
  --brand: #4f46e5;
  --brand-2: #8b5cf6;
  --brand-ink: #ffffff;
  --glow-a: rgba(99, 102, 241, 0.18);
  --glow-b: rgba(139, 92, 246, 0.14);
  --shadow-card: 0 1px 2px rgba(15, 17, 23, 0.04), 0 8px 24px -12px rgba(15, 17, 23, 0.12);
  --shadow-phone: 0 2px 8px rgba(15, 17, 23, 0.08), 0 32px 64px -24px rgba(15, 17, 23, 0.35);
  --max: 72rem;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0c10;
    --fg: #f3f4f8;
    --muted: #9aa0b2;
    --card: #131520;
    --border: #232636;
    --subtle: #11131b;
    --brand: #8b85f0;
    --brand-2: #c4b5fd;
    --brand-ink: #0b0c10;
    --glow-a: rgba(99, 102, 241, 0.26);
    --glow-b: rgba(168, 85, 247, 0.18);
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-phone: 0 2px 8px rgba(0, 0, 0, 0.5), 0 32px 64px -24px rgba(0, 0, 0, 0.8);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; letter-spacing: -0.025em; line-height: 1.1; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 1rem; }
.narrow { max-width: 48rem; }
.muted { color: var(--muted); }
.link { color: var(--brand); text-decoration: underline; text-underline-offset: 4px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: .75rem; padding-bottom: .75rem; }
.brand { display: flex; align-items: center; gap: .625rem; font-weight: 600; letter-spacing: -0.01em; }
.brand img { width: 34px; height: 34px; border-radius: 10px; box-shadow: var(--shadow-card); }
.nav-links { display: none; gap: .25rem; }
.nav-links a { padding: .375rem .75rem; border-radius: .5rem; font-size: .875rem; color: var(--muted); transition: background .15s, color .15s; }
.nav-links a:hover { background: var(--subtle); color: var(--fg); }
.btn-brand { border-radius: .75rem; background: var(--brand); color: var(--brand-ink); padding: .5rem 1rem; font-size: .875rem; font-weight: 600; transition: opacity .15s; }
.btn-brand:hover { opacity: .9; }
@media (min-width: 768px) { .nav-links { display: flex; } }

/* Hero */
.hero { position: relative; isolation: isolate; overflow: hidden; }
.aurora {
  position: absolute; inset: -20% 0 auto 0; height: 620px; pointer-events: none; z-index: -1;
  background:
    radial-gradient(48rem 24rem at 22% 18%, var(--glow-a), transparent 60%),
    radial-gradient(38rem 22rem at 82% 4%, var(--glow-b), transparent 62%);
}
.grid-veil {
  position: absolute; inset: 0; pointer-events: none; z-index: -1; opacity: .5;
  background-image: linear-gradient(to right, var(--border) 1px, transparent 1px), linear-gradient(to bottom, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(60% 50% at 50% 0%, #000 20%, transparent 75%);
  mask-image: radial-gradient(60% 50% at 50% 0%, #000 20%, transparent 75%);
}
.hero .wrap { padding-top: 4rem; padding-bottom: 6rem; display: grid; gap: 4rem; align-items: center; }
@media (min-width: 640px) { .hero .wrap { padding-top: 6rem; } }
@media (min-width: 1024px) { .hero .wrap { grid-template-columns: 1fr auto; } }
.pill {
  display: inline-flex; align-items: center; gap: .5rem; border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 80%, transparent); border-radius: 999px;
  padding: .375rem .875rem; font-size: .875rem; color: var(--muted);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.hero h1 { margin-top: 1.5rem; font-size: clamp(2.6rem, 6vw, 3.75rem); line-height: 1.05; font-weight: 750; }
.gradient { background: linear-gradient(100deg, var(--brand), var(--brand-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { margin-top: 1.5rem; max-width: 36rem; font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--muted); }
.fine { margin-top: 1.25rem; font-size: .875rem; color: var(--muted); }
.phones { display: flex; justify-content: center; align-items: flex-start; gap: 1.25rem; }
.phones .second { display: none; padding-top: 3.5rem; }
@media (min-width: 640px) { .phones .second { display: block; } }
@media (min-width: 1024px) {
  .phones { justify-content: flex-end; }
  .phones .tilt-l { transform: rotate(-2deg); }
  .phones .tilt-r { transform: rotate(2deg); }
}
.phone {
  flex-shrink: 0; border: 1px solid var(--border); background: var(--card);
  border-radius: 2.25rem; padding: 5px; box-shadow: var(--shadow-phone);
}
.phone img { width: 220px; height: auto; aspect-ratio: 720 / 1564; border-radius: 1.95rem; background: var(--subtle); }
@media (min-width: 640px) { .phone img { width: 260px; } }

/* Store buttons */
.stores { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.25rem; }
.stores.center { justify-content: center; }
.store {
  display: flex; align-items: center; gap: .75rem; border-radius: 1rem; padding: .875rem 1.25rem;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.store:hover { transform: translateY(-2px); box-shadow: var(--shadow-phone); }
.store svg { width: 20px; height: 20px; fill: currentColor; flex-shrink: 0; }
.store span { display: block; line-height: 1.2; text-align: left; }
.store small { display: block; font-size: .65rem; opacity: .7; }
.store b { font-size: 1rem; font-weight: 600; }
.store.dark { background: var(--fg); color: var(--bg); }
.store.light { border: 1px solid var(--border); background: var(--card); }

/* Stats */
.band { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--subtle); }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; padding: 2.5rem 1rem; margin: 0 auto; max-width: var(--max); }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stats div { text-align: center; }
.stats dt { font-size: clamp(1.9rem, 4vw, 2.25rem); font-weight: 750; letter-spacing: -0.025em; }
.stats dd { margin: .375rem 0 0; font-size: .875rem; color: var(--muted); }

/* Sections */
.section { padding: 6rem 0; }
.eyebrow { font-size: .875rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--brand); }
.section h2 { margin-top: .75rem; font-size: clamp(2.1rem, 5vw, 3rem); font-weight: 750; max-width: 42rem; text-wrap: balance; }
.section .intro { margin-top: 1.25rem; max-width: 42rem; font-size: 1.125rem; color: var(--muted); }

.features { margin-top: 3.5rem; display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .features { grid-template-columns: repeat(3, 1fr); } }
.card {
  border: 1px solid var(--border); background: var(--card); border-radius: 1.5rem; padding: 1.75rem;
  box-shadow: var(--shadow-card); transition: transform .3s, border-color .3s;
}
.card:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--brand) 40%, transparent); }
.icon {
  display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; border-radius: 1rem;
  background: color-mix(in srgb, var(--brand) 12%, transparent); color: var(--brand); transition: background .2s, color .2s;
}
.card:hover .icon { background: var(--brand); color: var(--brand-ink); }
.icon svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.card h3 { margin-top: 1.25rem; font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; }
.card p { margin-top: .625rem; color: var(--muted); }

/* Screenshot rail */
.rail {
  margin-top: 3.5rem; display: flex; gap: 2rem; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 0 1rem 1rem; scrollbar-width: none;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 3rem, #000 calc(100% - 3rem), transparent);
  mask-image: linear-gradient(to right, transparent, #000 3rem, #000 calc(100% - 3rem), transparent);
}
.rail::-webkit-scrollbar { display: none; }
@media (min-width: 640px) { .rail { padding-left: max(1rem, calc((100vw - var(--max)) / 2)); padding-right: max(1rem, calc((100vw - var(--max)) / 2)); } }
.rail figure { margin: 0; scroll-snap-align: center; }
.rail figcaption { margin-top: 1.25rem; width: 220px; font-size: .875rem; color: var(--muted); }
@media (min-width: 640px) { .rail figcaption { width: 260px; } }

.chips { margin: 3rem 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: .625rem; }
.chips li {
  border: 1px solid var(--border); background: var(--card); border-radius: 999px; padding: .5rem 1rem;
  font-size: .875rem; box-shadow: var(--shadow-card);
}

/* FAQ */
.faq { margin-top: 3rem; display: flex; flex-direction: column; gap: .75rem; }
.faq details {
  border: 1px solid var(--border); background: var(--card); border-radius: 1rem; padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-card);
}
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; cursor: pointer; list-style: none; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; display: grid; place-items: center; width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%;
  background: var(--subtle); color: var(--muted); font-size: 1.125rem; transition: transform .3s, background .3s, color .3s;
}
.faq details[open] summary::after { transform: rotate(45deg); background: var(--brand); color: var(--brand-ink); }
.faq details p { margin-top: 1rem; color: var(--muted); }

/* CTA */
.cta {
  position: relative; isolation: isolate; overflow: hidden; max-width: 64rem; margin: 0 auto; text-align: center;
  border: 1px solid var(--border); background: var(--card); border-radius: 2rem; padding: 4rem 1.5rem; box-shadow: var(--shadow-card);
}
.cta h2 { margin: 0 auto; }
.cta .intro { margin-left: auto; margin-right: auto; }
.mail {
  display: inline-block; margin-top: 2rem; border: 1px solid var(--border); background: var(--subtle); border-radius: 1rem;
  padding: .75rem 1.5rem; font-weight: 600; transition: color .15s, border-color .15s;
}
.mail:hover { color: var(--brand); }

/* Footer */
footer { border-top: 1px solid var(--border); background: var(--subtle); }
footer .wrap { display: flex; flex-direction: column; gap: 2rem; padding-top: 3rem; padding-bottom: 3rem; }
@media (min-width: 640px) { footer .wrap { flex-direction: row; justify-content: space-between; align-items: flex-start; } }
footer .brand img { width: 30px; height: 30px; border-radius: 8px; }
footer p { margin-top: .75rem; max-width: 20rem; font-size: .875rem; color: var(--muted); }
.cols { display: flex; flex-wrap: wrap; gap: .5rem 2.5rem; font-size: .875rem; }
.cols div { display: flex; flex-direction: column; gap: .625rem; }
.cols b { font-weight: 600; }
.cols a { color: var(--muted); }
.cols a:hover { color: var(--fg); }

/* Prose pages */
.prose { padding: 4rem 1rem; }
.prose h1 { font-size: 2.25rem; font-weight: 750; }
.prose .updated { margin-top: .5rem; font-size: .875rem; color: var(--muted); }
.prose .body { margin-top: 2.5rem; display: flex; flex-direction: column; gap: 2rem; }
.prose .body > p:first-child { font-size: 1.125rem; }
.prose h2 { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.01em; }
.prose section > p { margin-top: .75rem; color: var(--muted); }
.prose strong { color: var(--fg); }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.rise { animation: rise .7s cubic-bezier(.16, 1, .3, 1) both; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise { animation: none; }
}
