:root {
  --bg: #fbfaf8;
  --surface: #ffffff;
  --ink: #16130f;
  --muted: #6b645c;
  --line: #e9e4dd;
  --accent: #ea580c;
  --accent-ink: #ffffff;
  --accent-soft: #fff1e8;
  --code-bg: #1c1917;
  --code-ink: #f5f5f4;
  --ok: #15803d;
  --radius: 14px;
  --max: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12100e;
    --surface: #1c1916;
    --ink: #f3efe9;
    --muted: #a8a097;
    --line: #2f2a25;
    --accent-soft: #2a1a10;
    --code-bg: #0b0a09;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img { max-width: 100%; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; text-decoration: none; font-size: 18px; }
.brand img { width: 28px; height: 28px; border-radius: 7px; }
.nav-links { display: flex; gap: 22px; margin-left: auto; font-size: 15px; }
.nav-links a { text-decoration: none; color: var(--muted); }
.nav-links a:hover { color: var(--ink); }
@media (max-width: 760px) { .nav-links { display: none; } .nav .btn { margin-left: auto; } }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 20px; border-radius: 10px;
  font: 600 16px/1 inherit; text-decoration: none; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
}
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.06); }
.btn-small { min-height: 38px; padding: 0 14px; font-size: 14px; }

/* hero */
.hero { padding: 72px 0 56px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; } .hero { padding-top: 40px; } }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .02em; color: var(--accent); background: var(--accent-soft); padding: 5px 10px; border-radius: 999px; }
h1 { font-size: clamp(36px, 5.4vw, 60px); line-height: 1.05; letter-spacing: -0.03em; margin: 18px 0; }
h2 { font-size: clamp(28px, 3.6vw, 40px); line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 14px; }
h3 { font-size: 19px; margin: 0 0 6px; }
.lede { font-size: 19px; color: var(--muted); max-width: 34em; margin: 0 0 28px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.fine { font-size: 14px; color: var(--muted); margin-top: 14px; }

/* chat demo */
.demo { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 30px 60px -30px rgba(0,0,0,.25); overflow: hidden; font-size: 14.5px; }
.demo-bar { display: flex; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.demo-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.demo-body { padding: 18px; display: grid; gap: 14px; }
.msg-user { justify-self: end; background: var(--accent); color: var(--accent-ink); padding: 10px 14px; border-radius: 14px 14px 4px 14px; max-width: 85%; }
.tool { font: 12.5px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--muted); border: 1px dashed var(--line); border-radius: 8px; padding: 8px 10px; }
.tool b { color: var(--ok); font-weight: 600; }
.msg-ai { line-height: 1.5; }
.msg-ai ol { margin: 6px 0 0; padding-left: 20px; }
.msg-ai li { margin-bottom: 6px; }
.quote { color: var(--muted); font-style: italic; }

/* sections */
section { padding: 72px 0; }
.section-head { max-width: 40em; margin-bottom: 36px; }
.section-head p { color: var(--muted); margin: 0; }
.alt { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
@media (max-width: 860px) { .grid3, .grid2 { grid-template-columns: 1fr; } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.alt .card { background: var(--bg); }
.card p { color: var(--muted); margin: 0; font-size: 16px; }
.step-n { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; margin-bottom: 10px; }

.sources { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 8px 14px; font-size: 15px; font-weight: 500; }
.chip small { color: var(--muted); font-weight: 400; }

/* pricing */
.toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 4px; background: var(--surface); margin-bottom: 26px; }
.toggle button { border: 0; background: none; font: 600 14px/1 inherit; color: var(--muted); padding: 9px 16px; border-radius: 999px; cursor: pointer; }
.toggle button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.toggle .save { color: var(--accent); font-weight: 600; }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 1000px) { .plans { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .plans { grid-template-columns: 1fr; } }
.plan { display: flex; flex-direction: column; gap: 14px; }
.plan.featured { border: 2px solid var(--accent); position: relative; }
.plan .badge { position: absolute; top: -12px; left: 20px; background: var(--accent); color: var(--accent-ink); font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.price { font-size: 38px; font-weight: 750; letter-spacing: -0.02em; }
.price small { font-size: 15px; font-weight: 500; color: var(--muted); }
.plan ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 15px; flex: 1; }
.plan li::before { content: "✓"; color: var(--accent); font-weight: 700; margin-right: 8px; }
.plan .btn { width: 100%; }
.lifetime { margin-top: 16px; display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; border-style: dashed; }
.lifetime p { max-width: 34em; }
.lifetime-buy { display: flex; align-items: center; gap: 18px; }
.billed { font-size: 13px; color: var(--muted); min-height: 1.4em; margin-top: -8px; }

/* install */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tabs button { border: 1px solid var(--line); background: var(--surface); color: var(--muted); border-radius: 8px; padding: 8px 14px; font: 600 14px/1 inherit; cursor: pointer; }
.tabs button[aria-selected="true"] { color: var(--ink); border-color: var(--ink); }
pre { margin: 0; background: var(--code-bg); color: var(--code-ink); border-radius: 10px; padding: 16px 18px; overflow-x: auto; font: 14px/1.55 ui-monospace, SFMono-Regular, Menlo, monospace; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .9em; }
.copyable { position: relative; }
.copy-btn { position: absolute; top: 8px; right: 8px; background: rgba(255,255,255,.1); color: #fff; border: 0; border-radius: 6px; padding: 5px 9px; font: 600 12px/1 inherit; cursor: pointer; }

/* faq */
details.faq { border-bottom: 1px solid var(--line); padding: 16px 0; }
details.faq summary { font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
details.faq summary::after { content: "+"; color: var(--muted); }
details.faq[open] summary::after { content: "–"; }
details.faq p { color: var(--muted); margin: 10px 0 0; }

/* table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 15.5px; background: var(--surface); border-radius: var(--radius); overflow: hidden; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 14px; color: var(--muted); font-weight: 600; }

.final { text-align: center; }
.final .cta-row { justify-content: center; }
footer { border-top: 1px solid var(--line); padding: 32px 0; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; gap: 20px; flex-wrap: wrap; justify-content: space-between; }
footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
footer a { text-decoration: none; }

.narrow { max-width: 760px; }
.prose p, .prose li { color: var(--muted); }
.notice { background: var(--accent-soft); border-radius: 10px; padding: 14px 16px; font-size: 15px; }
.keybox { display: flex; gap: 8px; align-items: stretch; }
.keybox input, .field { flex: 1; min-height: 46px; padding: 0 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); font: 15px ui-monospace, SFMono-Regular, Menlo, monospace; width: 100%; }
.grid2 > *, .grid3 > * { min-width: 0; }
