:root {
  --bg: #f6f1e7;
  --surface: #fffdf8;
  --ink: #1d2420;
  --muted: #5b655f;
  --line: #e3dccd;
  --brand: #234e3d;
  --brand-ink: #f6f1e7;
  --accent: #c5793a;
  --soon: #e8f0ea;
  --soon-ink: #234e3d;
  --warn: #f7e6d6;
  --warn-ink: #8a4a17;
  --shadow: 0 1px 2px rgb(29 36 32 / 6%), 0 12px 32px -12px rgb(29 36 32 / 18%);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #141916;
    --surface: #1c2320;
    --ink: #ece7dc;
    --muted: #a3ada6;
    --line: #2d3631;
    --brand: #8cc5a8;
    --brand-ink: #10201a;
    --accent: #e2a06a;
    --soon: #22362c;
    --soon-ink: #a9d8bf;
    --warn: #3a2a1c;
    --warn-ink: #f0b989;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 12px 32px -12px rgb(0 0 0 / 60%);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 Inter, system-ui, -apple-system, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: Fraunces, Georgia, serif; font-weight: 600; line-height: 1.15; margin: 0; }
p { margin: 0; }
a { color: inherit; }

.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* Nav */
.nav { display: flex; align-items: center; justify-content: space-between; padding-block: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 600 20px Fraunces, Georgia, serif; text-decoration: none; }
.brand svg { width: 30px; height: 30px; }
.brand rect { fill: var(--brand); }
.brand path { fill: var(--brand-ink); }
.nav-cta { font-weight: 500; font-size: 15px; text-decoration: none; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; }
.nav-cta:hover { border-color: var(--brand); }

/* Hero */
.hero { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; padding-block: 48px 88px; }
.eyebrow { color: var(--accent); font-weight: 600; font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 18px; }
h1 { font-size: clamp(36px, 5.2vw, 60px); letter-spacing: -0.01em; }
.lede { color: var(--muted); font-size: 19px; margin-top: 22px; max-width: 34em; }

/* Form */
.signup { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; max-width: 520px; position: relative; }
.signup input[type='email'] {
  flex: 1 1 240px; min-width: 0; font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px;
}
.signup input[type='email']:focus { outline: 2px solid var(--brand); outline-offset: 1px; border-color: transparent; }
button {
  font: 600 16px Inter, system-ui, sans-serif; color: var(--brand-ink); background: var(--brand);
  border: 0; border-radius: 12px; padding: 14px 20px; cursor: pointer;
}
button:hover { filter: brightness(1.08); }
button:disabled { opacity: 0.6; cursor: default; }
button.ghost { background: transparent; color: var(--muted); }
.form-note { flex-basis: 100%; font-size: 14px; color: var(--muted); }
.form-note.error { color: #b3261e; }
.form-note.ok { color: var(--brand); font-weight: 500; }

/* Preview card */
.preview { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 20px; }
.preview-head { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); padding: 2px 4px 14px; border-bottom: 1px solid var(--line); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }
.preview ul { list-style: none; margin: 0; padding: 0; }
.preview li { display: flex; gap: 14px; align-items: flex-start; padding: 14px 4px; border-bottom: 1px solid var(--line); }
.preview li:last-child { border-bottom: 0; }
.preview strong { display: block; font-weight: 600; font-size: 16px; }
.preview small { display: block; color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.preview em { font-style: normal; color: var(--ink); }
.when { flex: 0 0 70px; text-align: center; font-size: 13px; font-weight: 600; padding: 5px 0; border-radius: 8px; background: var(--bg); color: var(--muted); }
.when.soon { background: var(--soon); color: var(--soon-ink); }
.when.warn { background: var(--warn); color: var(--warn-ink); }
.preview figcaption { font-size: 12.5px; color: var(--muted); padding: 10px 4px 0; }

/* Steps */
.steps { padding-block: 72px; border-top: 1px solid var(--line); }
.steps h2, .faq h2 { font-size: clamp(28px, 3.4vw, 38px); margin-bottom: 36px; }
.steps ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.steps li { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 26px; }
.num { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-weight: 600; margin-bottom: 18px; }
.steps h3 { font-size: 21px; margin-bottom: 10px; }
.steps p { color: var(--muted); }

/* FAQ */
.faq { padding-block: 24px 72px; max-width: 760px; }
details { border-bottom: 1px solid var(--line); padding: 18px 0; }
summary { cursor: pointer; font-weight: 600; font-size: 18px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::after { content: '+'; color: var(--muted); font-weight: 400; }
details[open] summary::after { content: '–'; }
details p { color: var(--muted); margin-top: 10px; }

/* Closing CTA */
.closing { background: var(--brand); color: var(--brand-ink); border-radius: 24px; padding: 56px; margin-bottom: 56px; text-align: center; }
.closing h2 { font-size: clamp(28px, 3.6vw, 40px); }
.closing .signup { margin-inline: auto; justify-content: center; }
.closing button { background: var(--brand-ink); color: var(--brand); }
.closing .form-note { color: color-mix(in srgb, var(--brand-ink) 75%, transparent); }
.closing .form-note.ok { color: var(--brand-ink); }
.closing .form-note.error { color: #ffd2cc; }

/* Follow-up dialog */
dialog.details { border: 1px solid var(--line); border-radius: 20px; background: var(--surface); color: var(--ink); padding: 28px; width: min(480px, 100% - 32px); box-shadow: var(--shadow); }
dialog::backdrop { background: rgb(20 25 22 / 50%); }
dialog h2 { font-size: 26px; margin-bottom: 6px; }
dialog p { color: var(--muted); margin-bottom: 18px; }
fieldset { border: 0; padding: 0; margin: 0 0 18px; }
legend, dialog label[for] { font-weight: 600; font-size: 15px; margin-bottom: 8px; display: block; }
.choices { display: flex; gap: 8px; flex-wrap: wrap; }
.choices label { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 14px; cursor: pointer; }
.choices label:has(input:checked) { border-color: var(--brand); background: var(--soon); }
textarea { width: 100%; font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px; resize: vertical; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }

/* Footer */
.footer { display: flex; justify-content: space-between; padding-block: 28px 40px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }

/* Plain pages (privacy, 404) */
.page { max-width: 720px; padding-block: 32px 80px; }
.page h1 { font-size: clamp(32px, 4vw, 44px); margin-bottom: 24px; }
.page h2 { font-size: 22px; margin: 32px 0 8px; }
.page p, .page li { color: var(--muted); }
.page p + p { margin-top: 12px; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: 40px; padding-block: 24px 64px; }
  .steps ol { grid-template-columns: 1fr; }
  .closing { padding: 40px 20px; }
}

@media (max-width: 480px) {
  body { font-size: 16px; }
  .nav-cta { display: none; }
  .signup button { flex: 1 1 100%; }
  .when { flex-basis: 62px; }
}
