:root {
  --ink: #282622;
  --muted: #6e685f;
  --paper: #f4f0ea;
  --stone: #766d62;
  --stone-dark: #4f4a43;
  --brand-taupe: #9B8E86;
  --bronze: #9b795b;
  --line: rgba(40, 38, 34, 0.17);
  --white: #fffdfa;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: var(--sans); font-size: 16px; line-height: 1.5; }
body.dialog-open { overflow: hidden; }
button, a { font: inherit; }
button { color: inherit; }

.site-header {
  position: relative;
  z-index: 10;
  min-height: 112px;
  padding: 8px clamp(20px, 5vw, 72px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid rgba(40,38,34,.18);
  background: var(--brand-taupe);
  backdrop-filter: blur(14px);
}

.wordmark { display: inline-flex; color: var(--white); text-decoration: none; }
.brand-logo-crop { position: relative; width: clamp(164px, 17vw, 216px); aspect-ratio: 1.86; display: block; overflow: hidden; background: transparent; }
.brand-logo-crop img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center 67%; mix-blend-mode: screen; }
.header-actions { display: flex; align-items: center; gap: 22px; }
.text-link { color: #29231f; font-size: .85rem; text-underline-offset: 5px; }
.header-book { padding: 11px 16px; color: var(--white); background: #312b27; font-size: .82rem; text-decoration: none; }

.finder-shell { min-height: calc(100svh - 112px); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(320px, .8fr); }
.finder-copy { min-height: 720px; padding: clamp(48px, 7vw, 104px) clamp(24px, 7vw, 112px); display: flex; flex-direction: column; justify-content: center; }
.eyebrow { margin: 0 0 18px; color: var(--bronze); font-size: .75rem; font-weight: 650; letter-spacing: .22em; text-transform: uppercase; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 400; letter-spacing: -.035em; line-height: 1.05; }
h1 { max-width: 760px; font-size: clamp(2.5rem, 5vw, 5.7rem); }
h2 { font-size: clamp(2.2rem, 4vw, 4.6rem); }
h3 { font-size: 1.65rem; }
.intro { max-width: 620px; margin: 24px 0 30px; color: var(--muted); font-size: 1.05rem; }

.progress-row { width: min(100%, 620px); display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; margin-bottom: 20px; color: var(--muted); font-size: .7rem; letter-spacing: .08em; }
.progress-track { height: 1px; background: var(--line); }
.progress-track span { display: block; width: 34%; height: 100%; background: var(--ink); transition: width .35s ease; }

.choice-grid { width: min(100%, 760px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.choice-card { min-height: 116px; padding: 20px; display: grid; grid-template-columns: auto 1fr; gap: 18px; text-align: left; background: transparent; border: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); cursor: pointer; transition: background .2s ease, color .2s ease, transform .2s ease; }
.choice-card:hover, .choice-card:focus-visible { color: var(--white); background: var(--stone); outline: none; }
.choice-card:active { transform: scale(.992); }
.choice-wide { grid-column: 1 / -1; }
.choice-index { padding-top: 2px; color: var(--bronze); font-size: .72rem; }
.choice-card:hover .choice-index, .choice-card:focus-visible .choice-index { color: #ddc3a8; }
.choice-card strong, .choice-card small { display: block; }
.choice-card strong { font-family: var(--serif); font-size: 1.18rem; font-weight: 400; line-height: 1.2; }
.choice-card small { margin-top: 7px; color: var(--muted); font-size: .8rem; line-height: 1.35; }
.choice-card:hover small, .choice-card:focus-visible small { color: rgba(255,253,250,.74); }

.finder-image { position: relative; min-height: 620px; overflow: hidden; }
.finder-image img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.82) contrast(.94); }
.finder-image::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(30,26,21,.52)); }
.image-note { position: absolute; z-index: 1; right: 28px; bottom: 30px; max-width: 410px; color: var(--white); font-size: .75rem; font-weight: 550; letter-spacing: .14em; line-height: 1.7; text-align: right; text-transform: uppercase; }
.image-note b, .footer-brand b { color: #d7c4b0; font-weight: 400; }

.second-step[hidden], .results[hidden] { display: none; }
.second-step, .results { animation: rise .42s ease both; }
.back-button { margin: 0 0 25px; padding: 0; color: var(--muted); background: none; border: 0; text-decoration: underline; text-underline-offset: 5px; cursor: pointer; }
.step-kicker { margin: 0 0 12px; color: var(--bronze); font-size: .75rem; font-weight: 650; letter-spacing: .18em; text-transform: uppercase; }
.second-step h2 { max-width: 680px; margin-bottom: 32px; }
.second-choice-grid .choice-card { min-height: 126px; }

.result-primary { max-width: 760px; padding: clamp(28px, 5vw, 52px); color: var(--white); background: var(--stone); }
.result-label { margin: 0 0 16px; color: #dec5ad; font-size: .7rem; font-weight: 650; letter-spacing: .18em; text-transform: uppercase; }
.result-primary h2 { max-width: 620px; }
.result-meta { margin: 16px 0 24px; display: flex; flex-wrap: wrap; gap: 9px; }
.meta-pill { padding: 7px 10px; border: 1px solid rgba(255,255,255,.24); color: rgba(255,255,255,.82); font-size: .76rem; }
.result-primary p { max-width: 620px; color: rgba(255,255,255,.78); }
.result-actions { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.primary-button, .secondary-button { min-height: 48px; padding: 13px 18px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer; }
.primary-button { color: var(--stone-dark); background: var(--white); border: 1px solid var(--white); }
.secondary-button { color: var(--white); background: transparent; border: 1px solid rgba(255,255,255,.4); }
.alternatives { max-width: 760px; padding: 26px 0 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.alternative-card { padding: 20px; border: 1px solid var(--line); }
.alternative-card .result-label { color: var(--bronze); }
.alternative-card h3 { margin-bottom: 10px; }
.alternative-card p { margin: 0 0 15px; color: var(--muted); font-size: .86rem; }
.alternative-card button { padding: 0; background: none; border: 0; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.result-note { max-width: 720px; margin: 24px 0 0; color: var(--muted); font-size: .78rem; }

.editorial-strip { padding: clamp(64px, 8vw, 112px) clamp(20px, 5vw, 72px); display: grid; grid-template-columns: 1.35fr .65fr; gap: clamp(14px, 2vw, 28px); background: var(--stone-dark); }
.editorial-card { min-height: 540px; margin: 0; position: relative; overflow: hidden; }
.editorial-card img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.82); }
.editorial-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 58%, rgba(20,18,16,.62)); }
.editorial-card figcaption { position: absolute; z-index: 1; left: 24px; right: 24px; bottom: 22px; display: flex; gap: 14px; color: var(--white); font-family: var(--serif); font-size: 1.2rem; }
.editorial-card figcaption span { color: #dec5ad; font-family: var(--sans); font-size: .68rem; }

.full-menu { padding: clamp(78px, 10vw, 148px) clamp(20px, 7vw, 112px); }
.menu-heading { display: grid; grid-template-columns: 1fr minmax(260px, 440px); gap: 36px; align-items: end; }
.menu-heading > p { margin: 0; color: var(--muted); }
.filter-row { margin: 48px 0 34px; display: flex; flex-wrap: wrap; gap: 8px; }
.filter-button { padding: 10px 14px; color: var(--muted); background: transparent; border: 1px solid var(--line); cursor: pointer; }
.filter-button:hover, .filter-button:focus-visible, .filter-button.active { color: var(--white); background: var(--stone); border-color: var(--stone); outline: none; }
.treatment-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.treatment-card { min-height: 315px; padding: 26px; display: flex; flex-direction: column; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.treatment-card[hidden] { display: none; }
.treatment-category { margin: 0 0 30px; color: var(--bronze); font-size: .68rem; font-weight: 650; letter-spacing: .16em; text-transform: uppercase; }
.treatment-card h3 { margin-bottom: 10px; }
.treatment-card .card-meta { margin: 0 0 16px; color: var(--ink); font-size: .78rem; font-weight: 650; }
.treatment-card .card-copy { margin: 0; color: var(--muted); font-size: .9rem; }
.card-actions { margin-top: auto; padding-top: 24px; display: flex; gap: 18px; }
.card-actions button, .card-actions a { padding: 0; color: var(--ink); background: none; border: 0; font-size: .78rem; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.tax-note { margin: 28px 0 0; color: var(--muted); font-size: .78rem; }

.site-footer { padding: 38px clamp(20px, 7vw, 112px) 48px; display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: end; color: #29231f; background: var(--brand-taupe); }
.footer-logo { width: clamp(190px, 22vw, 270px); }
.footer-brand p { max-width: 520px; margin: 8px 0 0; color: rgba(41,35,31,.8); font-size: .75rem; letter-spacing: .1em; line-height: 1.7; text-transform: uppercase; }
.site-footer p { margin-top: 8px; }
.footer-action { text-align: right; }
.footer-action a { display: inline-block; margin-top: 8px; color: #29231f; font-weight: 650; text-underline-offset: 5px; }

.treatment-dialog { width: min(92vw, 620px); max-height: 88vh; padding: clamp(28px, 5vw, 56px); color: var(--ink); background: var(--paper); border: 0; box-shadow: 0 30px 90px rgba(26,23,20,.28); }
.treatment-dialog::backdrop { background: rgba(34,30,27,.67); backdrop-filter: blur(4px); }
.dialog-close { position: absolute; top: 14px; right: 18px; width: 42px; height: 42px; background: transparent; border: 0; font-size: 1.8rem; cursor: pointer; }
.dialog-category { margin: 0 0 16px; color: var(--bronze); font-size: .72rem; font-weight: 650; letter-spacing: .18em; text-transform: uppercase; }
.treatment-dialog h2 { margin-right: 34px; }
.dialog-meta { margin: 18px 0 24px; color: var(--muted); }
.dialog-best { margin: 24px 0; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dialog-best strong { display: block; margin-bottom: 5px; font-size: .76rem; letter-spacing: .12em; text-transform: uppercase; }
.dialog-book { display: inline-flex; padding: 14px 18px; color: var(--white); background: var(--stone); text-decoration: none; }

@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 980px) {
  .finder-shell { grid-template-columns: 1fr; }
  .finder-image { min-height: 44svh; grid-row: 1; }
  .finder-copy { min-height: auto; grid-row: 2; padding-top: 54px; }
  .treatment-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .site-header { min-height: 92px; padding: 7px 18px; }
  .brand-logo-crop { width: 142px; }
  .header-actions { gap: 12px; }
  .text-link { display: none; }
  .header-book { padding: 9px 12px; font-size: .75rem; }
  .finder-copy { padding: 42px 20px 56px; }
  h1 { font-size: clamp(2.55rem, 13vw, 4rem); }
  .choice-grid { grid-template-columns: 1fr; }
  .choice-wide { grid-column: auto; }
  .choice-card { min-height: 104px; }
  .alternatives { grid-template-columns: 1fr; }
  .editorial-strip { grid-template-columns: 1fr; }
  .editorial-card { min-height: 480px; }
  .editorial-card-wide { min-height: 600px; }
  .menu-heading { grid-template-columns: 1fr; align-items: start; }
  .treatment-grid { grid-template-columns: 1fr; }
  .treatment-card { min-height: 275px; }
  .site-footer { grid-template-columns: 1fr; }
  .footer-logo { width: 210px; }
  .footer-action { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
