@font-face { font-family: Nunito; src: url(/fonts/nunito-400.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: Nunito; src: url(/fonts/nunito-700.woff2) format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: Nunito; src: url(/fonts/nunito-800.woff2) format('woff2'); font-weight: 800; font-display: swap; }

:root {
  --cream: #FBF6EF;
  --sand: #F1E6D6;
  --sand-2: #E8D9C4;
  --paper: #FFFDF9;
  --ink: #2B2320;
  --muted: #74645A;
  --accent: #C8553D;
  --accent-ink: #FFFFFF;
  --accent-soft: #F6DED6;
  --sage: #7A9E7E;
  --sage-soft: #E2ECE0;
  --gold-soft: #F5E7C8;
  --line: #E4D6C3;
  --radius: 24px;
  --radius-s: 16px;
  --shadow: 0 1px 0 rgba(43, 35, 32, .04), 0 8px 24px rgba(43, 35, 32, .06);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--cream); color: var(--ink);
  font: 400 17px/1.5 Nunito, ui-rounded, system-ui, -apple-system, sans-serif;
  min-height: 100vh; padding-bottom: env(safe-area-inset-bottom);
}
h1, h2, h3 { line-height: 1.15; margin: 0 0 .4em; font-weight: 800; letter-spacing: -.01em; }
h1 { font-size: 2.3rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
b { font-weight: 800; }
a { color: inherit; }

.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 980px; margin: 0 auto; padding: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; text-decoration: none; color: var(--accent); font-size: 1.05rem; }
.brand-dot { width: 18px; height: 18px; border-radius: 50%; background: var(--accent); box-shadow: 8px 0 0 -2px var(--sage); margin-right: 8px; }

main { max-width: 560px; margin: 0 auto; padding: 8px 16px 48px; }
main.wide { max-width: 980px; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.center { text-align: center; }
.stack > * + * { margin-top: 14px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.spacer { height: 12px; }

.btn {
  appearance: none; border: 0; border-radius: 999px; padding: 15px 24px; min-height: 52px;
  font: inherit; font-weight: 800; background: var(--accent); color: var(--accent-ink); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none;
}
.btn:hover { filter: brightness(.96); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.block { width: 100%; }
.btn.soft { background: var(--sand); color: var(--ink); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); }
.link { appearance: none; background: none; border: 0; padding: 6px 2px; font: inherit; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 12px; }

.card { background: var(--paper); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.card.sand { background: var(--sand); box-shadow: none; }

/* Landing */
.hero { padding: 24px 0 8px; }
.hero h1 { font-size: 2.6rem; }
.hero .lede { font-size: 1.15rem; color: var(--muted); }
.steps { display: grid; gap: 10px; counter-reset: s; padding: 0; margin: 20px 0; list-style: none; }
.steps li { counter-increment: s; display: flex; gap: 12px; align-items: baseline; }
.steps li::before { content: counter(s); flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--sand); display: inline-grid; place-items: center; font-weight: 800; }
.sample .who { font-weight: 800; }
.landing-grid { display: grid; gap: 24px; }

/* Choices */
.options { display: grid; gap: 10px; }
.option {
  appearance: none; text-align: left; font: inherit; color: inherit; cursor: pointer;
  background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius-s); padding: 14px 16px; min-height: 56px;
  display: flex; gap: 12px; align-items: center;
}
.option:hover { border-color: var(--sand-2); }
.option[aria-checked="true"], .option[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.option .letter { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--sand); display: grid; place-items: center; font-weight: 800; font-size: .9rem; text-transform: uppercase; }
.option[aria-checked="true"] .letter { background: var(--accent); color: #fff; }
.option .meta { display: block; color: var(--muted); font-size: .9rem; }
.option b { display: block; }

label.field { display: block; font-weight: 700; }
label.field span { display: block; margin-bottom: 6px; }
input[type=text], textarea {
  width: 100%; font: inherit; color: inherit; background: var(--paper); border: 2px solid var(--line);
  border-radius: var(--radius-s); padding: 13px 15px; min-height: 52px;
}
textarea { min-height: 140px; resize: vertical; }
input:focus, textarea:focus { border-color: var(--accent); outline: none; }
.note { border-radius: var(--radius-s); padding: 12px 14px; background: var(--gold-soft); font-size: .95rem; }
.note.bad { background: var(--accent-soft); }
.note.good { background: var(--sage-soft); }

.progress { height: 10px; background: var(--sand); border-radius: 99px; overflow: hidden; margin: 6px 0 18px; }
.progress > i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.qtext { font-size: 1.45rem; font-weight: 800; line-height: 1.25; margin-bottom: 18px; }

.prompt { white-space: pre-wrap; font-size: .85rem; max-height: 200px; overflow: auto; background: var(--sand); border-radius: var(--radius-s); padding: 14px; }
details summary { cursor: pointer; font-weight: 700; }

/* Aura card */
.aura { position: relative; overflow: hidden; text-align: left; }
.aura .orb { width: 92px; height: 92px; border-radius: 50%; margin-bottom: 14px; }
.aura .orb.pair { position: relative; width: 140px; }
.aura .orb.pair i { position: absolute; top: 0; width: 92px; height: 92px; border-radius: 50%; }
.aura .orb.pair i + i { left: 48px; opacity: .85; }
.aura-name { font-size: 1.05rem; font-weight: 800; color: var(--muted); }
.quote { border-left: 4px solid var(--sand-2); padding: 2px 0 2px 12px; margin: 10px 0; }
.quote .q { display: block; font-size: .85rem; color: var(--muted); }

.packs { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.packs .option { flex-direction: column; align-items: flex-start; gap: 2px; }

.linkbox { display: flex; gap: 8px; align-items: center; background: var(--paper); border: 2px dashed var(--sand-2); border-radius: var(--radius-s); padding: 10px 10px 10px 14px; }
.linkbox code { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 700 .95rem/1.4 ui-monospace, Menlo, monospace; }
.linkbox .btn { min-height: 42px; padding: 8px 16px; }

/* Result */
.headline { font-size: 1.6rem; font-weight: 800; line-height: 1.25; }
.scenario { display: grid; gap: 10px; }
.chip { display: inline-block; font-size: .8rem; font-weight: 800; padding: 4px 12px; border-radius: 99px; background: var(--sand); }
.chip.agree { background: var(--sage-soft); }
.chip.clash { background: var(--accent-soft); }
.says { display: grid; gap: 8px; grid-template-columns: 1fr 1fr; }
.says > div { background: var(--cream); border-radius: var(--radius-s); padding: 10px 12px; font-size: .95rem; }
.says .who { display: block; font-weight: 800; font-size: .85rem; color: var(--muted); }

dialog { border: 0; border-radius: var(--radius); padding: 24px; max-width: min(520px, calc(100vw - 32px)); background: var(--paper); color: var(--ink); box-shadow: var(--shadow); }
dialog::backdrop { background: rgba(43, 35, 32, .35); }
ul.plain { padding-left: 18px; }
ul.plain li { margin-bottom: 8px; }

.spinner { width: 44px; height: 44px; border-radius: 50%; border: 5px solid var(--sand); border-top-color: var(--accent); animation: spin 1s linear infinite; margin: 40px auto 16px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }

@media (min-width: 820px) {
  body { font-size: 18px; }
  .hero h1 { font-size: 3.4rem; }
  .landing-grid { grid-template-columns: 1.1fr .9fr; align-items: center; gap: 48px; }
  main { padding-top: 24px; }
}
@media (max-width: 380px) {
  .says { grid-template-columns: 1fr; }
  .packs { grid-template-columns: 1fr; }
}
