/* Persistently: design system */
:root {
  --paper: #f6f1e6;
  --card: #fffdf8;
  --ink: #1b3437;
  --ink-soft: #55676a;
  --line: #e3d9c4;
  --gold: #b8862b;
  --gold-deep: #8a6212;
  --gold-soft: #f3e3bd;
  --moss: #5d7a3a;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 14px;
  --shadow: 0 24px 48px -28px rgba(27, 52, 55, 0.35);
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 1.0625rem; line-height: 1.55; }
img, canvas { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.08; letter-spacing: -0.015em; margin: 0; }
p { margin: 0; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 40px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 1.5px solid transparent; font-weight: 700; text-decoration: none; cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--ink); color: #fdf8ec; box-shadow: 0 14px 24px -14px rgba(27, 52, 55, 0.7); }
.btn-primary:hover { background: #244548; }
.btn-gold { background: var(--gold); color: #1d1503; }
.btn-gold:hover { background: #c79332; }
.btn-ghost { background: transparent; border-color: rgba(27, 52, 55, 0.3); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-small { min-height: 40px; padding: 0 16px; font-size: 0.95rem; }
.link-btn { background: none; border: 0; padding: 0; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; color: var(--ink); }
.link-btn.soft { color: var(--ink-soft); font-weight: 500; }

/* ---------- header ---------- */
.p-header { position: sticky; top: 0; z-index: 50; background: rgba(246, 241, 230, 0.9); backdrop-filter: blur(10px); border-bottom: 1px solid rgba(227, 217, 196, 0.8); }
.p-header .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }
.p-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--serif); font-weight: 600; font-size: 1.35rem; letter-spacing: -0.01em; }
.p-brand img { height: 36px; width: auto; }
.p-nav { display: flex; align-items: center; gap: 22px; }
.p-nav a:not(.btn) { text-decoration: none; font-weight: 600; color: var(--ink-soft); }
.p-nav a:not(.btn):hover, .p-nav a[aria-current="page"] { color: var(--ink); }
@media (max-width: 560px) { .p-nav .nav-why { display: none; } .p-brand { font-size: 1.2rem; } }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: url("images/poster/hero.webp") center 62% / cover no-repeat; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(246, 241, 230, 0.97) 0%, rgba(246, 241, 230, 0.9) 38%, rgba(246, 241, 230, 0.25) 68%, rgba(246, 241, 230, 0) 100%), linear-gradient(0deg, rgba(246, 241, 230, 1) 0%, rgba(246, 241, 230, 0) 22%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); align-items: center; gap: 40px; padding: clamp(44px, 7vw, 88px) 0 clamp(52px, 7vw, 96px); }
.eyebrow { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 14px; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.4rem); max-width: 11ch; }
.hero-sub { font-size: clamp(1.08rem, 1.6vw, 1.25rem); color: var(--ink-soft); max-width: 34ch; margin: 18px 0 26px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-note { margin-top: 16px; font-size: 0.92rem; color: var(--ink-soft); }
.hero-poster { justify-self: center; width: min(100%, 380px); transform: rotate(2.2deg); }
.poster-frame { background: #fff; padding: 10px; border-radius: 6px; box-shadow: 0 40px 60px -30px rgba(20, 30, 30, 0.55), 0 2px 6px rgba(20, 30, 30, 0.12); }
.poster-frame canvas { width: 100%; border-radius: 2px; aspect-ratio: 2 / 3; background: #efe6d2; }
@media (max-width: 860px) {
  .hero::after { background: linear-gradient(180deg, rgba(246, 241, 230, 0.95) 0%, rgba(246, 241, 230, 0.88) 52%, rgba(246, 241, 230, 0.55) 78%, rgba(246, 241, 230, 1) 100%); }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 34px; padding-top: 36px; }
  .hero-poster { width: min(78%, 320px); }
}

/* ---------- sections ---------- */
.section { padding: clamp(48px, 7vw, 88px) 0; }
.section-head { text-align: center; margin-bottom: clamp(26px, 4vw, 44px); }
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.7rem); }
.section-head p { color: var(--ink-soft); margin-top: 10px; }
.def { font-family: var(--serif); font-style: italic; color: var(--ink-soft); }
.def b { font-style: normal; color: var(--ink); }

.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.idea { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px 24px; text-align: center; }
.idea img { height: 92px; width: auto; margin: 0 auto 14px; }
.idea h3 { font-size: 1.3rem; margin-bottom: 8px; }
.idea p { color: var(--ink-soft); font-size: 1rem; }
.idea .step { display: block; font-size: 0.74rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 6px; }
@media (max-width: 760px) { .three { grid-template-columns: minmax(0, 1fr); gap: 14px; } .idea { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 4px 16px; text-align: left; padding: 18px; align-items: center; } .idea img { height: 68px; margin: 0; grid-row: span 3; } .idea h3 { margin: 0; } }

/* ---------- builder ---------- */
.build { background: linear-gradient(180deg, rgba(255, 253, 248, 0) 0%, #fbf6ea 30%); }
.wizard { width: min(760px, 100%); margin-inline: auto; background: var(--card); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: clamp(20px, 4vw, 36px); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 26px; padding: 0; list-style: none; }
.steps li { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #a39a85; padding-top: 10px; border-top: 3px solid var(--line); }
.steps li.is-on { color: var(--ink); border-color: var(--gold); }
.steps li.is-done { color: var(--gold-deep); border-color: var(--gold); }
.wiz-q { font-size: clamp(1.45rem, 3.2vw, 1.95rem); margin-bottom: 6px; }
.wiz-hint { color: var(--ink-soft); margin-bottom: 18px; }
.crumb { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; font-weight: 600; color: var(--ink-soft); }
.crumb button { background: none; border: 0; padding: 4px 0; cursor: pointer; font-weight: 700; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.sub-q { font-weight: 700; margin: 18px 0 10px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: 12px; }
.tile { display: grid; justify-items: center; gap: 8px; padding: 18px 10px 14px; background: #fbf5e7; border: 1.5px solid var(--line); border-radius: var(--radius); cursor: pointer; font-weight: 700; text-align: center; transition: border-color 0.15s ease, transform 0.15s ease, background 0.15s ease; }
.tile:hover { border-color: var(--gold); background: #fff9ea; transform: translateY(-2px); }
.tile img { height: 58px; width: auto; }
.tile small { font-weight: 500; color: var(--ink-soft); font-size: 0.84rem; }
.opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.opt { display: flex; align-items: center; gap: 12px; padding: 10px 14px; min-height: 56px; background: #fbf5e7; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; font-weight: 600; text-align: left; transition: border-color 0.15s ease, background 0.15s ease; }
.opt:hover { border-color: var(--gold); background: #fff9ea; }
.opt img { height: 36px; width: 36px; object-fit: contain; flex: none; }
.opt.is-on, .chip.is-on, .day.is-on { background: var(--ink); border-color: var(--ink); color: #fdf8ec; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 9px 16px; min-height: 42px; background: #fbf5e7; border: 1.5px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 600; }
.chip:hover { border-color: var(--gold); }
.days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.day { min-height: 46px; background: #fbf5e7; border: 1.5px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 700; }
.day:hover { border-color: var(--gold); }
.field { display: grid; gap: 6px; margin-top: 18px; }
.field label { font-weight: 700; font-size: 0.95rem; }
.field input, .field select { min-height: 48px; padding: 0 14px; background: #fff; border: 1.5px solid #cfc4aa; border-radius: 10px; width: 100%; }
.field input:focus, .field select:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px rgba(184, 134, 43, 0.3); }
.note { border-left: 3px solid var(--gold); padding: 2px 0 2px 12px; color: var(--ink-soft); margin: 14px 0 4px; }
.wiz-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 26px; flex-wrap: wrap; }
.wiz-foot .right { display: flex; gap: 14px; align-items: center; margin-left: auto; }
.wiz-err { color: #9a3412; font-weight: 600; min-height: 1.4em; margin-top: 10px; }
@media (max-width: 520px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .tile { padding: 14px 6px 10px; } .tile img { height: 48px; } .opts { grid-template-columns: minmax(0, 1fr); } .day { font-size: 0.85rem; } }

/* ---------- trail (result) ---------- */
.trail-grid { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; justify-content: center; }
.trail-poster { position: sticky; top: 88px; }
.trail-side h2 { font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: 6px; }
.trail-side > p { color: var(--ink-soft); margin-bottom: 22px; }
.rows { display: grid; gap: 0; border-top: 1px solid var(--line); margin-bottom: 22px; }
.row { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.row img { width: 46px; height: 46px; object-fit: contain; }
.row .lab { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-deep); }
.row .val { display: block; font-family: var(--serif); font-weight: 600; font-size: 1.2rem; line-height: 1.25; }
.row .sub { display: block; font-size: 0.9rem; color: var(--ink-soft); }
.row.empty .val { font-family: var(--sans); font-weight: 500; font-size: 1rem; color: var(--ink-soft); }
.trail-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.trail-more { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 0.95rem; }
.status { min-height: 1.4em; color: var(--ink-soft); font-size: 0.95rem; margin-top: 8px; }
@media (max-width: 860px) { .trail-grid { grid-template-columns: minmax(0, 1fr); } .trail-poster { position: static; width: min(100%, 420px); margin-inline: auto; } }

/* ---------- prose pages ---------- */
.page-hero { padding: clamp(40px, 6vw, 72px) 0 10px; text-align: center; }
.page-hero h1 { font-size: clamp(2.3rem, 5vw, 3.4rem); }
.page-hero p { color: var(--ink-soft); font-size: 1.15rem; margin-top: 14px; }
.prose { display: grid; gap: 16px; font-size: 1.1rem; }
.prose h2 { font-size: 1.6rem; margin-top: 14px; }
.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.duo .card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.duo .card.good { border-color: var(--gold); box-shadow: var(--shadow); }
.duo h3 { font-size: 1.25rem; margin-bottom: 8px; }
.duo p { color: var(--ink-soft); }
@media (max-width: 700px) { .duo { grid-template-columns: minmax(0, 1fr); } }
.loop { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; counter-reset: loop; }
.loop li { counter-increment: loop; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.loop li::before { content: counter(loop); display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--gold-soft); color: var(--gold-deep); font-family: var(--serif); font-weight: 700; font-size: 1.2rem; }
.loop b { display: block; font-family: var(--serif); font-size: 1.15rem; }
.loop span { color: var(--ink-soft); }
.findings { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.finding { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: grid; gap: 8px; align-content: start; }
.finding .num { font-size: 0.76rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-deep); }
.finding h3 { font-size: 1.2rem; }
.finding p { color: var(--ink-soft); font-size: 0.98rem; }
.finding .src { font-size: 0.85rem; }
.fineprint { color: var(--ink-soft); font-size: 0.92rem; text-align: center; margin-top: 26px; }
.cta-band { text-align: center; padding: clamp(40px, 6vw, 72px) 0; }
.cta-band h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin-bottom: 18px; }
.photo-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 8px; }
.photo-row img { border-radius: 10px; aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }

/* ---------- footer ---------- */
.p-footer { border-top: 1px solid var(--line); padding: 34px 0 40px; margin-top: 20px; }
.p-footer .wrap { display: grid; gap: 18px; }
.p-footer .top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 28px; }
.p-footer ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 24px; margin: 0; padding: 0; }
.p-footer a { color: var(--ink-soft); text-decoration: none; font-weight: 500; }
.p-footer a:hover { color: var(--ink); text-decoration: underline; }
.p-footer small { color: var(--ink-soft); font-size: 0.88rem; }

/* ---------- print: the poster alone ---------- */
#print-poster { display: none; }
@media print {
  @page { margin: 0.4in; }
  body > *:not(#print-poster) { display: none !important; }
  #print-poster { display: block; }
  #print-poster img { width: 100%; max-height: 10.2in; object-fit: contain; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }

#build, #how { scroll-margin-top: 72px; }

/* the taller 2:3 poster */
.hero-poster { width: min(100%, 340px); }
.trail-grid { grid-template-columns: minmax(0, 420px) minmax(0, 1fr); }
@media (max-width: 860px) { .trail-grid { grid-template-columns: minmax(0, 1fr); } .trail-poster { width: min(100%, 380px); } .hero-poster { width: min(72%, 290px); } }
@media print { #print-poster img { max-height: 10in; width: auto; margin: 0 auto; } }

/* the main button waits, greyed, until the question is answered; a click shows what's missing */
.btn-primary.is-waiting { background: #b9bdb6; color: #f4f2ec; box-shadow: none; }
.btn-primary.is-waiting:hover { background: #aeb3ab; }
.need-block { border-radius: 14px; }
.needs { outline: 2.5px solid var(--gold); outline-offset: 6px; border-radius: 14px; animation: need-nudge 0.5s ease 1; }
.needs > .sub-q, .field.needs > label { color: var(--gold-deep); }
@keyframes need-nudge { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
@media (prefers-reduced-motion: reduce) { .needs { animation: none; } }

.row-acts { display: flex; gap: 16px; align-items: center; }
@media (max-width: 420px) { .row-acts { flex-direction: column; align-items: flex-end; gap: 6px; } }
