:root {
  --paper: #f3f2fa;
  --surface: #fff;
  --ink: #1a1733;
  --muted: #5b5873;
  --rule: #dcdae9;
  --violet: #6c63ff;
  --violet-ink: #4a42d4;
  --saved: #00796b;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #12101f;
    --surface: #1c1a2e;
    --ink: #f1f0f8;
    --muted: #aeabc4;
    --rule: #2e2b45;
    --violet-ink: #a9a4ff;
    --saved: #03dac6;
  }
}

* { box-sizing: border-box; }
html { color-scheme: light dark; }
body {
  margin: 0;
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  font-optical-sizing: auto;
  font-size: 18px;
  line-height: 1.55;
  background: var(--paper);
  color: var(--ink);
}
a { color: var(--violet-ink); }
:focus-visible { outline: 3px solid var(--violet); outline-offset: 3px; border-radius: 4px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

.top { display: flex; align-items: center; justify-content: space-between; padding: 22px 24px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 21px; color: var(--ink); text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.top nav a { color: var(--muted); text-decoration: none; margin-left: 24px; font-size: 16px; }
.top nav a:hover { color: var(--ink); }

.hero > * { min-width: 0; }
.hero { display: grid; grid-template-columns: 1fr 1.1fr; gap: 64px; align-items: center; padding: 56px 24px 96px; }
.hero h1 {
  font-size: clamp(40px, 5.6vw, 68px);
  line-height: 1.02;
  font-weight: 760;
  letter-spacing: -.028em;
  margin: 0 0 24px;
  max-width: 11ch;
}
.hero .lede { font-size: 21px; color: var(--muted); margin: 0 0 36px; max-width: 30em; }
.cta {
  display: inline-block; padding: 16px 26px; border-radius: 999px;
  background: var(--ink); color: var(--paper); font-weight: 600; text-decoration: none;
}
.cta:hover { background: var(--violet); color: #fff; }

.demo { background: var(--surface); border: 1px solid var(--rule); border-radius: 28px; padding: 18px; box-shadow: 0 30px 60px -30px rgb(74 66 212 / .45); }
.demo canvas { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 16px; background: var(--rule); image-rendering: auto; }
.readout { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px; padding: 18px 6px 6px; font-variant-numeric: tabular-nums; }
.readout .from { color: var(--muted); text-decoration: line-through; font-size: 20px; }
.readout .to { font-size: 34px; font-weight: 800; letter-spacing: -.02em; }
.readout .saved { margin-left: auto; color: var(--saved); font-weight: 700; font-size: 20px; }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 10px 6px 4px; border: 0; margin: 0; }
.controls legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.controls input { position: absolute; opacity: 0; }
.controls label, .controls button {
  font: inherit; font-size: 15px; font-weight: 600; cursor: pointer;
  padding: 8px 16px; border-radius: 999px; border: 1px solid var(--rule); background: transparent; color: var(--ink);
}
.controls input:checked + label { background: var(--violet); border-color: var(--violet); color: #fff; }
.controls input:focus-visible + label { outline: 3px solid var(--violet); outline-offset: 2px; }
.controls button { margin-left: auto; color: var(--violet-ink); border-style: dashed; }
.demo .note { font-size: 14px; color: var(--muted); margin: 10px 6px 2px; }

.features { padding: 40px 24px 96px; }
.features h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.1; letter-spacing: -.025em; font-weight: 800; margin: 0 0 48px; max-width: 18ch; }
.list { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: 64px; margin: 0; }
.list div { border-top: 1px solid var(--rule); padding: 22px 0 30px; }
.list dt { font-weight: 700; font-size: 21px; margin-bottom: 6px; }
.list dd { margin: 0; color: var(--muted); max-width: 34em; }

footer { border-top: 1px solid var(--rule); padding: 28px 24px; color: var(--muted); font-size: 15px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; }

.doc { max-width: 720px; padding: 24px 24px 80px; }
.doc h1 { font-size: 48px; font-weight: 800; letter-spacing: -.03em; line-height: 1.05; margin: 24px 0 8px; }
.doc h2 { font-size: 22px; margin: 40px 0 8px; }
.doc p { color: var(--muted); }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: 40px; padding-top: 24px; padding-bottom: 64px; }
  .list { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .wrap, .top, .hero, .features, footer { padding-left: 16px; padding-right: 16px; }
  .top nav a:not(:last-child) { display: none; }
  .controls button { margin-left: 0; }
}
