:root {
  --bg: #ffffff;
  --bg-soft: #f6f7fb;
  --text: #16182b;
  --muted: #5b6078;
  --line: #e4e6ef;
  --brand: #4f46e5;
  --brand-dark: #3f37c9;
  --accent: #fbbf24;
  --card: #ffffff;
  --radius: 14px;
  --max: 1080px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1020;
    --bg-soft: #16182c;
    --text: #eceefa;
    --muted: #a3a7c2;
    --line: #2a2d47;
    --brand: #8b85ff;
    --brand-dark: #a5a0ff;
    --card: #17192e;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); }
a:hover { color: var(--brand-dark); }
img { max-width: 100%; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 10; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 20px; color: var(--text); text-decoration: none; }
.logo img { width: 30px; height: 30px; }
.nav { display: flex; gap: 22px; }
.nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }

/* Hero */
.hero { padding: 88px 0 72px; background: linear-gradient(180deg, var(--bg-soft), var(--bg)); }
.hero h1 { font-size: clamp(34px, 5vw, 54px); line-height: 1.1; margin: 0 0 18px; letter-spacing: -0.02em; max-width: 780px; }
.hero p.lead { font-size: 20px; color: var(--muted); max-width: 640px; margin: 0 0 30px; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--brand); margin-bottom: 14px; }

.buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-block; padding: 12px 22px; border-radius: 10px; font-weight: 600; text-decoration: none; border: 1px solid transparent; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; }
.btn-ghost { border-color: var(--line); color: var(--text); }
.btn-ghost:hover { border-color: var(--muted); color: var(--text); }

/* Sections */
section { padding: 64px 0; }
section.soft { background: var(--bg-soft); }
h2 { font-size: clamp(26px, 3.4vw, 34px); line-height: 1.2; margin: 0 0 12px; letter-spacing: -0.01em; }
.section-intro { color: var(--muted); max-width: 640px; margin: 0 0 36px; }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { margin: 0 0 8px; font-size: 18px; }
.card p { margin: 0; color: var(--muted); font-size: 16px; }
.icon { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--brand) 14%, transparent); color: var(--brand); display: grid; place-items: center; font-size: 20px; margin-bottom: 14px; }

/* App card on home */
.app-card { display: grid; grid-template-columns: auto 1fr; gap: 24px; align-items: start; }
.app-card .app-icon { width: 72px; height: 72px; border-radius: 18px; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 34px; font-weight: 800; }
.badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--accent) 25%, transparent); color: var(--text); margin-left: 8px; vertical-align: middle; }

/* Steps */
.steps { counter-reset: step; display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.step { position: relative; padding-top: 52px; }
.step::before { counter-increment: step; content: counter(step); position: absolute; top: 0; left: 0; width: 38px; height: 38px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 700; display: grid; place-items: center; }
.step h3 { margin: 0 0 6px; font-size: 18px; }
.step p { margin: 0; color: var(--muted); font-size: 16px; }

/* Example price */
.price-example { display: inline-block; margin: 32px 0 0; padding: 16px 20px; border: 1px dashed var(--line); border-radius: var(--radius); background: var(--card); }
.price-example figcaption { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.price-example-product { font-weight: 600; }
.price-example-note { font-size: 14px; color: var(--muted); margin-top: 4px; }
.price-demo { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; font-size: 24px; font-weight: 700; margin: 2px 0 0; }
.price-demo s { color: var(--muted); font-weight: 500; font-size: 20px; }

/* Video embed */
.video { position: relative; aspect-ratio: 16 / 9; max-width: 880px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #000; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* FAQ */
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
details summary { cursor: pointer; font-weight: 600; list-style: none; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: "+"; float: right; color: var(--muted); }
details[open] summary::after { content: "−"; }
details p { color: var(--muted); margin: 10px 0 0; }

/* Long-form pages (privacy, support) */
.doc { max-width: 760px; padding: 56px 20px 72px; margin: 0 auto; }
.doc h1 { font-size: clamp(30px, 4vw, 42px); margin: 0 0 8px; letter-spacing: -0.02em; }
.doc .updated { color: var(--muted); margin: 0 0 32px; }
.doc h2 { font-size: 22px; margin: 36px 0 10px; }
.doc li { margin-bottom: 6px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 15px; margin: 12px 0; }
.doc th, .doc td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.doc th { background: var(--bg-soft); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 32px 0; color: var(--muted); font-size: 15px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

@media (max-width: 640px) {
  .nav { gap: 14px; }
  .nav a.hide-sm { display: none; }
  .hero { padding: 56px 0 48px; }
  .app-card { grid-template-columns: 1fr; }
  section { padding: 48px 0; }
}

/* Custom apps pricing */
.card .price { font-size: 26px; font-weight: 700; color: var(--text); margin: 4px 0 10px; }
.note { margin: 24px 0 0; padding: 14px 18px; border-left: 3px solid var(--accent); background: var(--card); border-radius: 8px; color: var(--muted); max-width: 760px; }
.note strong { color: var(--text); }

/* Four menu links don't fit next to the logo on phones: let the menu drop to its own row */
@media (max-width: 640px) {
  .site-header .wrap { height: auto; flex-wrap: wrap; row-gap: 6px; padding-top: 12px; padding-bottom: 12px; }
  .nav { flex-wrap: wrap; row-gap: 4px; }
  .nav a { white-space: nowrap; font-size: 14px; }
}
.card .price small { font-size: 14px; font-weight: 500; color: var(--muted); }
