/* ==========================================================================
   LIQUID GLASS LANDING — styles
   1. Design tokens  ← change colors, glass, radius and fonts here
   2. Base
   3. Glass & buttons
   4. Nav
   5. Hero & product mockup
   6. Sections (logos, features, steps, stats, quotes, pricing, FAQ, CTA, footer)
   7. Scroll reveal
   8. Responsive
   9. Accessibility & fallbacks
   ========================================================================== */

/* ---------- 1. Design tokens ---------- */
/* The Inter font is loaded by fonts/inter.css (linked in index.html). */

:root {
  /* Type (fluid: smaller on phones, bigger on desktop) */
  --font: "Inter", ui-sans-serif, system-ui, "Segoe UI", Roboto, sans-serif;
  --text-xs: 0.8125rem;                                  /* 13 */
  --text-sm: 0.9375rem;                                  /* 15 */
  --text-md: 1rem;                                       /* 16 */
  --text-lg: 1.25rem;                                    /* 20 */
  --text-lead: clamp(1.0625rem, 0.95rem + 0.5vw, 1.25rem);
  --text-h2: clamp(1.85rem, 1.2rem + 3vw, 3.25rem);
  --text-display: clamp(2.6rem, 1.3rem + 5.4vw, 5.25rem);

  /* Shape & spacing */
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 26px;
  --gap: 20px;
  --container: 1160px;
  --section-space: clamp(80px, 10vw, 140px);

  /* Glass recipe */
  --blur: 28px;
  --saturate: 180%;

  /* Motion */
  --ease: cubic-bezier(.2, .8, .2, 1);
  --dur: 400ms;

  /* Accent palette */
  --c1: #2f6bff;
  --c2: #8b5cf6;
  --c3: #e2458f;
  --c4: #0e9f8e;
  --c5: #e8930c;
}

/* Light theme (default) */
:root,
[data-theme="light"] {
  color-scheme: light;
  --bg: #eef1f8;
  --blob-1: #8fb4ff;
  --blob-2: #c6a8ff;
  --blob-3: #ffb3d1;
  --blob-4: #8fe3d6;

  --text: #15161c;
  --text-muted: #4a4d5c;
  --border-soft: rgba(20, 22, 40, .09);

  --glass-bg: rgba(255, 255, 255, .58);
  --glass-solid: #f7f8fc;             /* used when blur isn't available */
  --glass-edge: rgba(255, 255, 255, .9);
  --glass-edge-2: rgba(255, 255, 255, .25);
  --glass-shadow: 0 1px 1px rgba(16, 24, 64, .04), 0 18px 40px -12px rgba(16, 24, 64, .16);
  --glass-inner: inset 0 1px 0 rgba(255, 255, 255, .85);
  --chip-bg: rgba(255, 255, 255, .65);
  --hover: rgba(20, 22, 40, .05);

  --accent: #2557e0;
  --accent-text: #fff;
  --accent-strong: #1a44b8;           /* accent text sitting right on the colorful background */
  --accent-soft: rgba(47, 107, 255, .12);
  --positive: #0a6542;
  --positive-soft: rgba(16, 160, 100, .14);
  --negative: #a8211e;
  --star: #b86a00;

  --grid-line: rgba(20, 22, 40, .08);
  --focus: #2557e0;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #07080d;
  --blob-1: #1d3fb0;
  --blob-2: #5524a8;
  --blob-3: #8a1f5c;
  --blob-4: #0d6b66;

  --text: #f4f5f8;
  --text-muted: #aeb1c2;
  --border-soft: rgba(255, 255, 255, .09);

  --glass-bg: rgba(22, 24, 34, .55);
  --glass-solid: #161822;
  --glass-edge: rgba(255, 255, 255, .22);
  --glass-edge-2: rgba(255, 255, 255, .04);
  --glass-shadow: 0 1px 1px rgba(0, 0, 0, .3), 0 20px 48px -12px rgba(0, 0, 0, .6);
  --glass-inner: inset 0 1px 0 rgba(255, 255, 255, .08);
  --chip-bg: rgba(255, 255, 255, .07);
  --hover: rgba(255, 255, 255, .06);

  --accent: #6d97ff;
  --accent-text: #07080d;
  --accent-strong: #9db8ff;
  --accent-soft: rgba(109, 151, 255, .16);
  --positive: #4fd6a0;
  --positive-soft: rgba(79, 214, 160, .14);
  --negative: #ff8a80;
  --star: #fbbf24;

  --c1: #6d97ff;
  --c2: #a98bff;
  --c3: #f472b6;
  --c4: #2dd4bf;
  --c5: #fbbf24;

  --grid-line: rgba(255, 255, 255, .07);
  --focus: #8fb0ff;
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  font-family: var(--font);
  font-size: var(--text-md);
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
h1, h2, h3, p, figure, blockquote { margin: 0; }
h1, h2 { text-wrap: balance; }
p { text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
.icon {
  width: 20px; height: 20px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.75;
  stroke-linecap: round; stroke-linejoin: round;
}
main { outline: none; }

/* Animated color blobs behind everything */
.backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.backdrop span {
  position: absolute;
  width: 60vmax; height: 60vmax;
  border-radius: 50%;
  opacity: .7;
  will-change: transform;
  animation: drift 40s var(--ease) infinite alternate;
}
.backdrop span:nth-child(1) { background: radial-gradient(closest-side, var(--blob-1), transparent); top: -20vmax; left: -10vmax; }
.backdrop span:nth-child(2) { background: radial-gradient(closest-side, var(--blob-2), transparent); top: -10vmax; right: -20vmax; animation-duration: 50s; animation-delay: -10s; }
.backdrop span:nth-child(3) { background: radial-gradient(closest-side, var(--blob-3), transparent); bottom: -30vmax; left: 20vmax; animation-duration: 46s; animation-delay: -20s; }
.backdrop span:nth-child(4) { background: radial-gradient(closest-side, var(--blob-4), transparent); bottom: -25vmax; right: -15vmax; animation-duration: 55s; animation-delay: -5s; }
@keyframes drift {
  to { transform: translate3d(8vmax, 6vmax, 0) scale(1.15); }
}

/* ---------- 3. Glass & buttons ---------- */
.glass {
  position: relative;
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--saturate));
  backdrop-filter: blur(var(--blur)) saturate(var(--saturate));
  border-radius: var(--radius-lg);
  box-shadow: var(--glass-inner), var(--glass-shadow);
  transition: background-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
/* The shiny 1px edge: bright at top-left, fading out, catching light again bottom-right */
.glass::before {
  content: "";
  position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(140deg, var(--glass-edge), var(--glass-edge-2) 35%, transparent 60%, var(--glass-edge-2) 85%, var(--glass-edge));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 40px; padding: 0 18px;
  border: 0; border-radius: 99px;
  font-size: var(--text-sm); font-weight: 600; white-space: nowrap;
  transition: transform 150ms var(--ease), filter 150ms, background-color 150ms;
}
.btn .icon { width: 18px; height: 18px; transition: transform 200ms var(--ease); }
.btn:hover .icon { transform: translateX(3px); }
.btn:active { transform: scale(.97); }
.btn-lg { min-height: 50px; padding: 0 24px; font-size: var(--text-md); }
.btn-primary {
  background: var(--accent); color: var(--accent-text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 8px 20px -8px color-mix(in srgb, var(--accent) 70%, transparent);
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-glass {
  background: var(--chip-bg);
  box-shadow: var(--glass-inner), 0 0 0 1px var(--border-soft);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.btn-glass:hover { background: var(--glass-bg); }
.btn-ghost { background: transparent; color: var(--text); }
.btn-ghost:hover { background: var(--hover); }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 40px; height: 40px;
  border: 0; border-radius: 12px;
  background: transparent;
  color: var(--text-muted);
  transition: background-color 150ms, color 150ms;
}
.icon-btn:hover { background: var(--hover); color: var(--text); }
.icon-btn .icon { grid-area: 1 / 1; transition: transform 500ms var(--ease), opacity 300ms; }
[data-theme="light"] #theme-toggle .icon-sun,
[data-theme="dark"]  #theme-toggle .icon-moon,
.menu-btn[aria-expanded="false"] .icon-shut,
.menu-btn[aria-expanded="true"] .icon-open { opacity: 0; transform: rotate(-90deg) scale(.5); }

/* ---------- 4. Nav ---------- */
.nav-wrap { position: sticky; top: 12px; z-index: 50; padding: 0 16px; }
.nav {
  max-width: var(--container); margin: 0 auto;
  display: flex; align-items: center; gap: 12px;
  min-height: 60px; padding: 8px 8px 8px 16px;
  border-radius: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; border-radius: 10px; }
.brand-mark { width: 30px; height: 30px; flex: none; }
.brand-name { font-size: var(--text-lg); font-weight: 650; letter-spacing: -0.02em; }
.nav-links { display: flex; align-items: center; gap: 4px; margin: 0 auto; }
.nav-links a:not(.btn) {
  display: inline-flex; align-items: center;
  min-height: 40px; padding: 0 14px; border-radius: 12px;
  color: var(--text-muted); font-size: var(--text-sm); font-weight: 500;
  transition: color 150ms, background-color 150ms;
}
.nav-links a:not(.btn):hover { color: var(--text); background: var(--hover); }
.nav-links-cta { display: none; }
.nav-actions { display: flex; align-items: center; gap: 6px; }
.menu-btn { display: none; }

/* ---------- 5. Hero & product mockup ---------- */
.hero {
  max-width: var(--container); margin: 0 auto;
  padding: clamp(56px, 9vw, 104px) 20px 0;
  text-align: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 5px 14px 5px 5px;
  border-radius: 99px;
  font-size: var(--text-xs); font-weight: 500; color: var(--text-muted);
}
.eyebrow:hover { color: var(--text); }
.eyebrow .icon { width: 16px; height: 16px; transition: transform 200ms var(--ease); }
.eyebrow:hover .icon { transform: translateX(3px); }
.eyebrow-tag {
  padding: 3px 10px; border-radius: 99px;
  background: var(--accent); color: var(--accent-text);
  font-weight: 650; font-size: 0.75rem;
}
.hero h1 {
  margin-top: 28px;
  font-size: var(--text-display); font-weight: 700;
  letter-spacing: -0.045em; line-height: 1.02;
}
.grad {
  color: var(--accent);
  background: linear-gradient(100deg, var(--c1), var(--c2) 55%, var(--c3));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  padding-bottom: .06em; /* keeps descenders from being clipped */
}
.lead {
  max-width: 40rem; margin: 22px auto 0;
  font-size: var(--text-lead); color: var(--text-muted); line-height: 1.55;
}
.hero-ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 36px; }
.trust { margin-top: 18px; font-size: var(--text-xs); color: var(--text-muted); }

.mock-stage { position: relative; max-width: 1040px; margin: clamp(48px, 7vw, 80px) auto 0; text-align: left; }
.mock { overflow: hidden; border-radius: 22px; animation: rise 1s 150ms var(--ease) both; }
.mock-bar {
  display: flex; align-items: center; gap: 7px;
  height: 42px; padding: 0 16px;
  border-bottom: 1px solid var(--border-soft);
}
.mock-bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--grid-line); box-shadow: inset 0 0 0 1px var(--border-soft); }
.mock-bar span {
  margin: 0 auto; padding: 4px 16px; border-radius: 8px;
  background: var(--chip-bg); color: var(--text-muted); font-size: 12px;
}
.mock-body { display: grid; grid-template-columns: 64px minmax(0, 1fr); }
.mock-side {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 18px 0; border-right: 1px solid var(--border-soft);
}
.mock-side .brand-mark { margin-bottom: 8px; }
.mock-side b { width: 30px; height: 30px; border-radius: 9px; background: var(--hover); }
.mock-side b.on { background: var(--accent-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 30%, transparent); }
.mock-main { display: grid; gap: 16px; padding: 20px; }
.mock-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.mock-kpis > div, .mock-chart, .mock-rows {
  padding: 14px 16px; border-radius: 16px;
  background: var(--chip-bg); box-shadow: var(--glass-inner), 0 0 0 1px var(--border-soft);
}
.mock-kpis small { display: block; color: var(--text-muted); font-size: 12px; }
.mock-kpis strong { font-size: 1.5rem; font-weight: 650; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.mock-kpis em {
  margin-left: 8px; padding: 2px 7px; border-radius: 99px;
  font-style: normal; font-size: 12px; font-weight: 600;
  color: var(--positive); background: var(--positive-soft);
}
.mock-chart { height: 200px; padding: 16px 0 0; overflow: hidden; }
.mock-chart svg, .art-chart svg { display: block; width: 100%; height: 100%; }
.mc-grid { stroke: var(--grid-line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.mc-area { fill: url(#g-area); }
.mc-line {
  fill: none; stroke: var(--c1); stroke-width: 2.5; vector-effect: non-scaling-stroke;
  stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 1; stroke-dashoffset: 1;
  animation: draw 1.6s 500ms var(--ease) forwards;
}
.mock-rows { display: grid; gap: 10px; }
.mock-rows div { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-muted); }
.mock-rows .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--d); }
.mock-rows b { position: relative; width: 50%; height: 8px; margin-left: auto; border-radius: 99px; background: var(--hover); }
.mock-rows b::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); border-radius: inherit; background: var(--d); }

.float {
  position: absolute; display: flex; align-items: flex-start; gap: 12px;
  max-width: 290px; padding: 14px 16px;
  border-radius: var(--radius-md);
  font-size: var(--text-xs); line-height: 1.4;
  animation: rise 900ms var(--ease) both, bob 6s ease-in-out infinite alternate;
}
.float strong { display: block; font-size: var(--text-sm); }
.float small { color: var(--text-muted); font-size: var(--text-xs); }
.float-a { left: -36px; top: 46%; animation-delay: 700ms, 1.6s; }
.float-b { right: -32px; bottom: 9%; animation-delay: 900ms, 2.4s; }
.float-icon {
  display: inline-grid; place-items: center; flex: none;
  width: 36px; height: 36px; border-radius: 11px;
  background: var(--accent-soft); color: var(--accent);
}
.float-icon.ok { background: var(--positive-soft); color: var(--positive); }
.float-icon .icon { width: 18px; height: 18px; }

@keyframes rise { from { opacity: 0; transform: translateY(24px) scale(.985); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes bob { to { translate: 0 -10px; } }

/* ---------- 6. Sections ---------- */
.section { max-width: var(--container); margin: 0 auto; padding: var(--section-space) 20px 0; }
.section-narrow { max-width: 820px; }
.section-head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.kicker { color: var(--accent-strong); font-size: var(--text-sm); font-weight: 600; margin-bottom: 14px; }
.section-head h2, .cta h2 { font-size: var(--text-h2); font-weight: 700; letter-spacing: -0.035em; line-height: 1.08; }
.section-head .lead { margin-top: 18px; }

/* Logos */
.logos { max-width: var(--container); margin: 0 auto; padding: 88px 20px 0; text-align: center; }
.logos p { font-size: var(--text-xs); font-weight: 500; color: var(--text-muted); }
.logos ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px 44px; margin-top: 24px; }
.logos li {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 1.3rem; font-weight: 650; letter-spacing: -0.03em; color: var(--text-muted);
}
.logos svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linejoin: round; stroke-linecap: round; }

/* Features (bento) */
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.span-2 { grid-column: span 2; }
.tile { display: flex; flex-direction: column; min-height: 320px; padding: 28px; overflow: hidden; }
.tile h3 { margin-top: 16px; font-size: var(--text-lg); font-weight: 650; letter-spacing: -0.02em; }
.tile > p { margin-top: 6px; color: var(--text-muted); font-size: var(--text-sm); max-width: 46ch; }
.tile-icon {
  display: inline-grid; place-items: center;
  width: 42px; height: 42px; border-radius: 13px;
  background: var(--chip-bg); color: var(--accent);
  box-shadow: var(--glass-inner), 0 0 0 1px var(--border-soft);
}
.tile-art { flex: 1; min-height: 120px; margin-bottom: 24px; display: grid; place-items: center; }
.art-chart { place-items: stretch; margin: -28px -28px 24px; }
.art-chart svg { height: 100%; min-height: 150px; }
.art-insight p, .art-alerts span, .bubble {
  padding: 12px 14px; border-radius: 14px;
  background: var(--chip-bg); box-shadow: var(--glass-inner), 0 0 0 1px var(--border-soft);
  font-size: var(--text-xs);
}
.art-insight p { display: flex; gap: 10px; max-width: 260px; }
.art-insight .icon { color: var(--accent); width: 18px; height: 18px; }
.art-alerts { display: flex; flex-direction: column; gap: 10px; place-items: start; justify-content: center; }
.art-alerts span { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; }
.art-alerts span + span { margin-left: 28px; }
.art-alerts i { width: 8px; height: 8px; border-radius: 50%; }
.tone-neg { background: var(--negative); }
.tone-pos { background: var(--positive); }
.art-apps { display: flex; flex-wrap: wrap; justify-content: center; align-content: center; gap: 14px; }
.art-apps span {
  display: inline-grid; place-items: center;
  width: 54px; height: 54px; border-radius: 16px;
  background: hsl(var(--hue) 85% 60% / .16); color: hsl(var(--hue) 70% 48%);
  box-shadow: var(--glass-inner), 0 0 0 1px hsl(var(--hue) 70% 50% / .18);
}
[data-theme="dark"] .art-apps span { color: hsl(var(--hue) 85% 72%); }
.art-lock span, .art-lock .icon { width: 44px; height: 44px; color: var(--accent); stroke-width: 1.5; }
.art-lock {
  width: 108px; height: 108px; margin: 0 auto 24px; flex: none; align-self: center;
  border-radius: 50%; background: radial-gradient(closest-side, var(--accent-soft), transparent);
  box-shadow: 0 0 0 1px var(--border-soft), 0 0 0 14px color-mix(in srgb, var(--accent-soft) 40%, transparent);
}
.art-lock + .tile-icon { display: none; }
.art-team { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.stack { display: flex; }
.stack .avatar { width: 44px; height: 44px; margin-left: -10px; box-shadow: 0 0 0 3px var(--glass-solid); }
.stack .avatar:first-child { margin-left: 0; }
.avatar.more { background: var(--glass-solid); color: var(--text-muted); text-shadow: none; }
.bubble b { font-weight: 600; }

.avatar {
  --hue: 220;
  display: inline-grid; place-items: center; flex: none;
  width: 40px; height: 40px; border-radius: 50%;
  background: linear-gradient(135deg, hsl(var(--hue) 85% 62%), hsl(calc(var(--hue) + 50) 80% 55%));
  color: #fff;
  font-size: 0.75rem; font-weight: 650; letter-spacing: .02em;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35);
  text-shadow: 0 1px 1px rgba(0, 0, 0, .25);
}

@media (hover: hover) {
  .tile, .step, .quote, .plan { transition: transform 300ms var(--ease), background-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
  .tile:hover, .step:hover, .quote:hover { transform: translateY(-4px); }
}

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.step { padding: 28px; }
.step-num {
  display: inline-grid; place-items: center;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--accent); color: var(--accent-text); font-weight: 650;
}
.step > .icon { position: absolute; top: 28px; right: 28px; width: 28px; height: 28px; color: var(--text-muted); stroke-width: 1.5; }
.step h3 { margin-top: 22px; font-size: var(--text-lg); font-weight: 650; letter-spacing: -0.02em; }
.step p { margin-top: 6px; color: var(--text-muted); font-size: var(--text-sm); }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 40px 12px; text-align: center; }
.stats li { padding: 4px 16px; }
.stats li + li { border-left: 1px solid var(--border-soft); }
.stats strong {
  display: block;
  font-size: clamp(2.1rem, 1.5rem + 2.2vw, 3.25rem); font-weight: 700; letter-spacing: -0.045em; line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.stats span { display: block; margin-top: 6px; color: var(--text-muted); font-size: var(--text-sm); }

/* Testimonials */
.quotes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.quote { display: flex; flex-direction: column; gap: 18px; padding: 28px; }
.stars { display: flex; gap: 2px; color: var(--star); }
.stars .icon { width: 18px; height: 18px; fill: currentColor; stroke: none; }
.quote blockquote { flex: 1; font-size: 1.0625rem; line-height: 1.55; letter-spacing: -0.005em; }
.quote figcaption { display: flex; align-items: center; gap: 12px; }
.quote figcaption strong { display: block; font-size: var(--text-sm); font-weight: 600; }
.quote figcaption small { display: block; color: var(--text-muted); font-size: var(--text-xs); }

/* Pricing */
.billing {
  display: inline-flex; gap: 2px; margin-top: 32px; padding: 4px;
  border-radius: 99px;
  background: var(--chip-bg); box-shadow: var(--glass-inner), 0 0 0 1px var(--border-soft);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.billing button {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 38px; padding: 0 18px;
  border: 0; border-radius: 99px; background: transparent;
  color: var(--text-muted); font-size: var(--text-sm); font-weight: 600;
  transition: background-color 200ms var(--ease), color 200ms, box-shadow 200ms;
}
.billing button:hover { color: var(--text); }
.billing button[aria-pressed="true"] {
  background: var(--glass-solid); color: var(--text);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .1), 0 2px 8px -2px rgba(0, 0, 0, .14);
}
.save { padding: 2px 8px; border-radius: 99px; font-size: 0.75rem; color: var(--positive); background: var(--positive-soft); }

.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); align-items: stretch; }
.plan { display: flex; flex-direction: column; padding: 32px; }
.plan h3 { font-size: var(--text-lg); font-weight: 650; letter-spacing: -0.02em; }
.plan-desc { margin-top: 6px; color: var(--text-muted); font-size: var(--text-sm); min-height: calc(2 * 1.55em); }
.price { display: flex; align-items: baseline; gap: 6px; margin-top: 20px; }
.amount { font-size: 3rem; font-weight: 700; letter-spacing: -0.045em; line-height: 1; font-variant-numeric: tabular-nums; }
.per, .billed { color: var(--text-muted); font-size: var(--text-sm); }
.billed { margin: 8px 0 24px; }
.plan .btn { width: 100%; min-height: 46px; }
.checks { display: grid; gap: 12px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--border-soft); }
.checks li { display: flex; gap: 10px; font-size: var(--text-sm); }
.checks .icon { width: 18px; height: 18px; margin-top: 2px; color: var(--accent); stroke-width: 2.25; }
.plan-featured {
  background:
    radial-gradient(120% 60% at 50% 0%, color-mix(in srgb, var(--c1) 16%, transparent), transparent 70%),
    var(--glass-bg);
  box-shadow: var(--glass-inner), 0 0 0 2px color-mix(in srgb, var(--accent) 55%, transparent), 0 30px 60px -20px color-mix(in srgb, var(--accent) 45%, transparent);
}
.badge {
  position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%);
  padding: 5px 14px; border-radius: 99px;
  background: var(--accent); color: var(--accent-text);
  font-size: 0.75rem; font-weight: 650; white-space: nowrap;
}

/* FAQ */
.faq { display: grid; gap: 12px; }
.faq details { border-radius: var(--radius-md); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 24px; border-radius: inherit;
  font-size: 1.0625rem; font-weight: 600; letter-spacing: -0.01em;
  cursor: pointer; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 12px; height: 12px;
  background:
    linear-gradient(currentColor 0 0) center / 100% 2px no-repeat,
    linear-gradient(currentColor 0 0) center / 2px 100% no-repeat;
  color: var(--text-muted);
  transition: transform 300ms var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 24px 22px; color: var(--text-muted); max-width: 62ch; }

/* Final CTA */
.cta {
  padding: clamp(48px, 7vw, 88px) 24px; text-align: center;
  background:
    radial-gradient(70% 90% at 15% 0%, color-mix(in srgb, var(--c1) 18%, transparent), transparent 70%),
    radial-gradient(70% 90% at 85% 100%, color-mix(in srgb, var(--c3) 16%, transparent), transparent 70%),
    var(--glass-bg);
}
.signup { display: flex; gap: 10px; max-width: 480px; margin: 32px auto 0; }
.signup input {
  flex: 1; min-width: 0; height: 50px; padding: 0 22px;
  border: 1px solid var(--border-soft); border-radius: 99px;
  background: var(--chip-bg); outline: none;
  transition: border-color 150ms, box-shadow 150ms;
}
.signup input::placeholder { color: var(--text-muted); opacity: 1; }
.signup input:focus-visible { border-color: var(--focus); box-shadow: 0 0 0 3px var(--accent-soft); }
.signup input[aria-invalid="true"] { border-color: var(--negative); }
.signup-msg { margin-top: 14px; font-size: var(--text-xs); color: var(--text-muted); }
.signup-msg.is-error { color: var(--negative); font-weight: 500; }
.signup-msg.is-ok { color: var(--positive); font-weight: 500; }

/* Footer */
.footer { max-width: var(--container); margin: var(--section-space) auto 0; padding: 0 20px 40px; }
.footer-top { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; padding-top: 48px; border-top: 1px solid var(--border-soft); }
.footer-brand p { margin-top: 12px; color: var(--text-muted); font-size: var(--text-sm); }
.footer-cols { display: grid; grid-template-columns: repeat(3, auto); gap: 24px 64px; }
.footer-cols h3 { font-size: var(--text-sm); font-weight: 600; }
.footer-cols ul { display: grid; gap: 2px; margin-top: 10px; }
.footer-cols a, .footer-bottom a { display: inline-block; padding: 4px 0; color: var(--text-muted); font-size: var(--text-sm); transition: color 150ms; }
.footer-cols a:hover, .footer-bottom a:hover { color: var(--text); }
.footer-bottom { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 48px; color: var(--text-muted); font-size: var(--text-xs); }
.footer-bottom a { font-size: var(--text-xs); }

/* ---------- 7. Scroll reveal ----------
   Only hides content when JS is running (app.js adds .js to <html>), so nothing is ever lost without JS. */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 800ms var(--ease), transform 800ms var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal:not(.is-in) .mc-line { animation: none; }  /* feature chart draws when it scrolls in */
.js .bento .reveal:nth-child(3n + 2), .js .steps .reveal:nth-child(2), .js .quotes .reveal:nth-child(2), .js .plans .reveal:nth-child(2) { transition-delay: 90ms; }
.js .bento .reveal:nth-child(3n), .js .steps .reveal:nth-child(3), .js .quotes .reveal:nth-child(3), .js .plans .reveal:nth-child(3) { transition-delay: 180ms; }

/* ---------- 8. Responsive ---------- */
@media (max-width: 1100px) {
  .float-a { left: -12px; }
  .float-b { right: -12px; }
}

/* Tablet */
@media (max-width: 960px) {
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps, .quotes, .plans { grid-template-columns: minmax(0, 1fr); max-width: 560px; margin-inline: auto; }
  .plans { gap: 32px; }
  .plan-desc { min-height: 0; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
  .stats li:nth-child(3) { border-left: 0; }

  /* Nav collapses into a dropdown panel */
  .menu-btn { display: inline-grid; }
  .nav-links {
    position: absolute; top: calc(100% + 8px); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    margin: 0; padding: 10px;
    border-radius: 20px;
    background: var(--glass-solid);
    box-shadow: 0 0 0 1px var(--border-soft), 0 24px 48px -12px rgba(0, 0, 0, .3);
    visibility: hidden; opacity: 0; transform: translateY(-8px) scale(.98);
    transition: opacity 250ms var(--ease), transform 300ms var(--ease), visibility 0s 300ms;
  }
  .nav-links.is-open { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
  .nav-links a:not(.btn) { min-height: 48px; font-size: var(--text-md); }
  .nav-actions { margin-left: auto; }
}

/* Phone */
@media (max-width: 720px) {
  :root { --gap: 14px; }
  .nav-wrap { top: 8px; padding: 0 10px; }
  .nav { padding-left: 12px; }
  .bento { grid-template-columns: minmax(0, 1fr); }
  .span-2 { grid-column: auto; }
  .tile { min-height: 0; padding: 24px; }
  .art-chart { margin: -24px -24px 20px; }
  .tile-art { margin-bottom: 20px; }
  .float { display: none; }
  .mock-body { grid-template-columns: minmax(0, 1fr); }
  .mock-side { display: none; }
  .mock-main { padding: 12px; gap: 10px; }
  .mock-kpis { gap: 10px; }
  .mock-kpis > div { padding: 10px 12px; }
  .mock-kpis strong { font-size: 1.05rem; }
  .mock-kpis em { display: none; }
  .mock-chart { height: 140px; }
  .mock-bar span { display: none; }
  .step, .quote, .plan { padding: 24px; }
  .faq summary { padding: 18px 20px; font-size: var(--text-md); }
  .faq details p { padding: 0 20px 20px; }
  .footer-cols { grid-template-columns: repeat(2, auto); }
}

@media (max-width: 560px) {
  .nav-login, .nav-cta { display: none; }
  .nav-links-cta { display: block; margin-top: 8px; }
  .nav-links-cta .btn { width: 100%; min-height: 48px; font-size: var(--text-md); }
  .hero-ctas .btn { width: 100%; }
  .section-head h2 br, .cta h2 br { display: none; }  /* let long headings wrap naturally */
  .mock-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mock-kpis > div:nth-child(3), .mock-rows { display: none; }
  .signup { flex-direction: column; }
  .signup input { flex: none; }
  .signup .btn { width: 100%; }
  .stats { padding: 28px 8px; }
  .stats li { padding: 4px 8px; }
}

@media (max-width: 360px) {
  .eyebrow { font-size: 0.75rem; }
  .brand-name { font-size: 1.125rem; }
  .footer-cols { grid-template-columns: 1fr 1fr; gap: 24px 32px; }
}

/* ---------- 9. Accessibility & fallbacks ---------- */
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 100;
  padding: 10px 16px; border-radius: 12px;
  background: var(--accent); color: var(--accent-text); font-weight: 600;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.signup input:focus-visible { outline: none; }

/* No blur support (or the user asked for less transparency): solid panels */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  :root, [data-theme] { --glass-bg: var(--glass-solid); }
}
@media (prefers-reduced-transparency: reduce) {
  :root, [data-theme] { --glass-bg: var(--glass-solid); --chip-bg: var(--hover); }
  .glass, .billing, .btn-glass { -webkit-backdrop-filter: none; backdrop-filter: none; }
}

/* High contrast / forced colors (Windows) */
@media (forced-colors: active) {
  .glass { border: 1px solid CanvasText; }
  .glass::before, .backdrop { display: none; }
  .grad { background: none; -webkit-text-fill-color: currentColor; color: CanvasText; }
  .billing button[aria-pressed="true"] { outline: 2px solid Highlight; }
}

/* Calm mode: no movement, content shown right away */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 1ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }
  .backdrop span, .float { animation: none; }
  .js .reveal { opacity: 1; transform: none; }
  .mc-line { stroke-dashoffset: 0; }
}
