:root {
  color-scheme: dark;
  --ink: #11100e;
  --cream: #f4eddf;
  --cream-muted: #bdb3a1;
  --gold: #c9a66b;
  --gold-light: #d8b97f;
  --gold-soft: rgba(201, 166, 107, 0.18);
  --line: rgba(244, 237, 223, 0.17);
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--ink); scroll-behavior: smooth; }
body {
  min-height: 100vh;
  margin: 0;
  color: var(--cream);
  background: radial-gradient(circle at 72% 18%, rgba(201, 166, 107, 0.13), transparent 25rem), linear-gradient(135deg, #0d0c0a 0%, #17140f 55%, #0e0d0b 100%);
  font-family: var(--sans);
}
button, a, input { font: inherit; }
button, label { -webkit-tap-highlight-color: transparent; }
.site-header, footer { width: min(1180px, calc(100% - 40px)); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; }
.site-header { min-height: 84px; border-bottom: 1px solid var(--line); position: relative; z-index: 2; }
.brand { color: var(--cream); text-decoration: none; text-transform: uppercase; letter-spacing: .14em; font-size: .76rem; font-weight: 700; display: flex; align-items: center; gap: 12px; }
.brand-mark { width: 36px; aspect-ratio: 1; border: 1px solid var(--gold); display: grid; place-items: center; color: var(--gold); letter-spacing: .04em; font-size: .68rem; }
.header-actions { display: flex; align-items: center; gap: 18px; }
.header-link { border: 0; padding: 10px 0; color: var(--cream-muted); background: transparent; cursor: pointer; text-transform: uppercase; letter-spacing: .12em; font-size: .68rem; font-weight: 700; }
.header-link:hover { color: var(--gold-light); }
.install-button { border: 1px solid var(--line); color: var(--cream); background: transparent; padding: 10px 15px; cursor: pointer; }
.hero { width: min(1180px, calc(100% - 40px)); margin: 0 auto; min-height: calc(100vh - 120px); padding: clamp(70px, 11vw, 150px) 0 72px; }
.eyebrow { color: var(--gold); text-transform: uppercase; letter-spacing: .28em; font-size: .72rem; font-weight: 700; margin-bottom: 26px; }
h1, h2 { font-family: var(--serif); }
h1 { margin: 0; max-width: 980px; font-size: clamp(3.8rem, 10vw, 8.8rem); font-weight: 600; line-height: .88; letter-spacing: -.055em; }
h1 em { color: var(--gold); font-weight: 600; }
.hero-copy { width: min(580px, 100%); margin: 40px 0 0; color: var(--cream-muted); font-size: clamp(1rem, 1.6vw, 1.24rem); line-height: 1.7; }
.hero-actions, .result-actions, .next-actions { margin-top: 38px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.primary-button, .secondary-button { border: 0; min-height: 52px; padding: 15px 21px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 30px; transition: transform 160ms ease, background 160ms ease, border-color 160ms ease; }
.primary-button { color: var(--ink); background: var(--gold); }
.secondary-button { color: var(--cream); background: transparent; border: 1px solid var(--line); }
.primary-button:hover, .secondary-button:hover { transform: translateY(-2px); }
.primary-button:hover { background: var(--gold-light); }
.secondary-button:hover { border-color: var(--gold); }
.secondary-button:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.light { border-color: rgba(17,16,14,.25); color: var(--ink); }
.primary-button:focus-visible, .secondary-button:focus-visible, .install-button:focus-visible, .header-link:focus-visible, .text-button:focus-visible, input:focus-visible + span { outline: 3px solid rgba(244,237,223,.62); outline-offset: 3px; }
.link-button { text-decoration: none; }
.text-button { color: inherit; background: transparent; border: 0; cursor: pointer; padding: 10px 0; text-decoration: underline; text-underline-offset: 5px; }
.time-note { color: var(--cream-muted); font-size: .82rem; }
.code-preview { margin-top: clamp(70px, 10vw, 120px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: grid; grid-template-columns: repeat(6, 1fr); }
.code-preview div { min-height: 112px; display: flex; flex-direction: column; justify-content: center; gap: 8px; padding: 18px; border-right: 1px solid var(--line); }
.code-preview div:last-child { border-right: 0; }
.code-preview b { color: var(--gold); font-family: var(--serif); font-size: 1.7rem; }
.code-preview span { font-size: .68rem; text-transform: uppercase; letter-spacing: .11em; color: var(--cream-muted); }
.promise { padding: clamp(60px, 8vw, 100px) 20px; text-align: center; background: var(--cream); color: var(--ink); font-family: var(--serif); font-size: clamp(1.6rem, 3.2vw, 3.1rem); line-height: 1.2; }
.promise p { margin: 0; }
.promise em { color: #8d6935; }
.about-code { width: min(1040px, calc(100% - 40px)); margin: 0 auto; padding: clamp(76px, 10vw, 140px) 0; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 8vw, 120px); }
.section-number { color: var(--gold); font-weight: 700; font-size: .78rem; letter-spacing: .14em; }
.about-code h2, .section-heading h2, .next-move h2 { font-size: clamp(2.4rem, 5vw, 4.8rem); line-height: .98; margin: 20px 0 0; letter-spacing: -.04em; }
.about-copy { color: var(--cream-muted); line-height: 1.8; font-size: 1.06rem; }
.about-copy p:first-child { color: var(--cream); font-size: 1.24rem; }
.book-section { position: relative; overflow: hidden; background: var(--cream); color: var(--ink); padding: clamp(76px, 10vw, 140px) 20px; }
.book-section::before { content: ""; position: absolute; width: 34rem; aspect-ratio: 1; border: 1px solid rgba(141,105,53,.16); border-radius: 50%; top: -18rem; right: -10rem; box-shadow: 0 0 0 5rem rgba(201,166,107,.05), 0 0 0 10rem rgba(201,166,107,.035); }
.book-inner { position: relative; width: min(1040px, 100%); margin: 0 auto; display: grid; grid-template-columns: minmax(240px, 360px) 1fr; align-items: center; gap: clamp(48px, 9vw, 120px); }
.book-cover-wrap { position: relative; width: min(330px, 84vw); margin: 0 auto; }
.book-cover-wrap::after { content: ""; position: absolute; inset: 7% -7% -5% 9%; background: #8d6935; opacity: .24; filter: blur(20px); z-index: 0; }
.book-cover { position: relative; z-index: 1; display: block; width: 100%; height: auto; border: 1px solid rgba(17,16,14,.2); box-shadow: 0 28px 55px rgba(17,16,14,.28); }
.book-copy { position: relative; z-index: 1; }
.book-copy .eyebrow { color: #8d6935; margin-bottom: 20px; }
.book-copy h2 { margin: 0; font-size: clamp(3rem, 6.5vw, 6.2rem); line-height: .9; letter-spacing: -.055em; }
.book-tagline { max-width: 620px; margin: 28px 0 0; color: #5f574b; font: italic clamp(1.25rem, 2.3vw, 1.8rem)/1.35 var(--serif); }
.book-description { max-width: 620px; margin: 24px 0 0; color: #635d54; line-height: 1.8; }
.book-retailers { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.retailer-link { min-height: 48px; padding: 13px 17px; border: 1px solid rgba(17,16,14,.24); color: var(--ink); text-decoration: none; font-size: .76rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; transition: background 160ms ease, color 160ms ease, transform 160ms ease; }
.retailer-link:first-child { background: var(--ink); color: var(--cream); border-color: var(--ink); }
.retailer-link:hover { transform: translateY(-2px); background: #8d6935; color: var(--cream); border-color: #8d6935; }
.book-note { margin-top: 17px; color: #7a7267; font-size: .72rem; line-height: 1.5; }
footer { min-height: 90px; color: var(--cream-muted); font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; border-top: 1px solid var(--line); }

.assessment-shell { width: min(930px, calc(100% - 34px)); margin: 0 auto; padding: 45px 0 90px; }
.assessment-topline { display: flex; justify-content: space-between; align-items: center; color: var(--cream-muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; }
.progress-track { height: 3px; background: var(--line); margin-top: 16px; }
.progress-track span { display: block; height: 100%; background: var(--gold); transition: width 250ms ease; }
.question-intro { margin: clamp(56px, 8vw, 90px) 0 40px; }
.question-intro h2 { margin: 0; max-width: 820px; font-size: clamp(2.4rem, 6vw, 5.4rem); line-height: 1.02; letter-spacing: -.045em; }
.question-intro p { color: var(--cream-muted); margin-top: 22px; }
.rating-list, .choice-list { border: 0; padding: 0; margin: 0; }
.rating-row { border: 1px solid var(--line); border-bottom: 0; padding: 22px; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 24px; }
.rating-row:first-child { border-radius: 10px 10px 0 0; }
.rating-row:nth-last-child(2) { border-bottom: 1px solid var(--line); border-radius: 0 0 10px 10px; }
.rating-row legend { display: contents; color: var(--cream); line-height: 1.45; }
.type-chip, .choice-letter { width: 34px; height: 34px; flex: 0 0 34px; border: 1px solid var(--gold); color: var(--gold); display: inline-grid; place-items: center; margin-right: 14px; font-family: var(--serif); font-weight: 700; }
.rating-scale { display: grid; grid-template-columns: repeat(5, 42px); gap: 7px; }
.rating-scale label { cursor: pointer; }
.rating-scale input { position: absolute; opacity: 0; pointer-events: none; }
.rating-scale span { width: 42px; aspect-ratio: 1; display: grid; place-items: center; border: 1px solid var(--line); color: var(--cream-muted); transition: all 140ms ease; }
.rating-scale label:hover span { border-color: var(--gold); color: var(--cream); }
.rating-scale input:checked + span { color: var(--ink); background: var(--gold); border-color: var(--gold); font-weight: 700; }
.scale-key { display: flex; justify-content: flex-end; gap: 60px; color: var(--cream-muted); font-size: .7rem; padding-top: 12px; }
.choice-card { position: relative; display: flex; align-items: center; gap: 4px; border: 1px solid var(--line); border-bottom: 0; padding: 22px; cursor: pointer; color: var(--cream); line-height: 1.45; transition: background 140ms ease, border-color 140ms ease; }
.choice-card:first-of-type { border-radius: 10px 10px 0 0; }
.choice-card:last-of-type { border-bottom: 1px solid var(--line); border-radius: 0 0 10px 10px; }
.choice-card:hover { border-color: rgba(201,166,107,.6); background: rgba(255,255,255,.025); }
.choice-card input { position: absolute; opacity: 0; pointer-events: none; }
.choice-card:has(input:checked) { background: var(--gold-soft); border-color: var(--gold); }
.choice-check { margin-left: auto; opacity: 0; color: var(--gold); font-weight: 700; }
.choice-card:has(input:checked) .choice-check { opacity: 1; }
.form-note { min-height: 24px; color: #e7bf7f; }
.question-actions { display: flex; justify-content: space-between; gap: 14px; margin-top: 24px; }

.results-hero { min-height: calc(100vh - 84px); padding: clamp(70px, 10vw, 130px) max(20px, calc((100% - 1000px)/2)); background: var(--cream); color: var(--ink); display: flex; flex-direction: column; align-items: center; text-align: center; }
.results-hero .eyebrow { color: #8d6935; }
.result-code { font-family: var(--serif); font-size: clamp(5.5rem, 18vw, 12rem); line-height: .9; letter-spacing: -.07em; }
.result-code i { color: #a98249; font-weight: 400; }
.results-hero h1 { font-size: clamp(3rem, 7vw, 6.4rem); line-height: .98; max-width: 1000px; margin-top: 28px; color: #8d6935; }
.results-hero > p { max-width: 720px; font-size: 1.1rem; line-height: 1.8; margin: 28px 0 0; }
.result-types { margin-top: 22px; display: flex; gap: 14px; align-items: center; text-transform: uppercase; letter-spacing: .12em; font-size: .74rem; }
.result-types b { color: #8d6935; }
.close-result { margin-top: 28px; max-width: 600px; padding: 13px 17px; border: 1px solid rgba(17,16,14,.18); font-size: .84rem; }
.share-status { min-height: 25px; font-size: .82rem !important; margin-top: 12px !important; }
.score-section { width: min(1080px, calc(100% - 40px)); margin: 0 auto; padding: clamp(80px, 11vw, 150px) 0; }
.section-heading { display: grid; grid-template-columns: 70px 1fr; }
.section-heading .eyebrow { margin-bottom: 18px; }
.score-list { margin-top: 70px; border-top: 1px solid var(--line); }
.score-row { position: relative; display: grid; grid-template-columns: 170px 1fr 70px; gap: 24px; align-items: center; min-height: 92px; border-bottom: 1px solid var(--line); }
.score-label { display: flex; align-items: center; gap: 14px; }
.score-label b { color: var(--gold); font: 700 1.6rem var(--serif); }
.score-label span { text-transform: uppercase; letter-spacing: .1em; font-size: .7rem; color: var(--cream-muted); }
.score-bar { height: 7px; background: var(--line); overflow: hidden; }
.score-bar span { display: block; height: 100%; background: linear-gradient(90deg, #92713f, var(--gold-light)); }
.score-value { font: 600 1.3rem var(--serif); text-align: right; }
.score-value small { color: var(--cream-muted); font: 400 .68rem var(--sans); }
.rank-label { position: absolute; right: 0; top: 10px; color: var(--gold); text-transform: uppercase; letter-spacing: .12em; font-size: .58rem; }
.type-deep-dive { display: grid; grid-template-columns: 1fr 1fr; }
.type-card { padding: clamp(52px, 8vw, 100px); background: var(--cream); color: var(--ink); }
.type-card + .type-card { background: var(--gold); }
.type-card-top { display: flex; justify-content: space-between; align-items: center; text-transform: uppercase; letter-spacing: .12em; font-size: .68rem; }
.type-card-top b { font: 600 4rem var(--serif); }
.type-card h2 { font-size: clamp(2.6rem, 5vw, 5.5rem); line-height: .95; letter-spacing: -.05em; margin: 60px 0 14px; }
.type-card blockquote { margin: 0 0 32px; color: #795b30; font: italic 1.35rem/1.4 var(--serif); }
.type-card > p { line-height: 1.7; }
.type-card dl { margin: 45px 0 0; border-top: 1px solid rgba(17,16,14,.2); }
.type-card dl div { display: grid; grid-template-columns: 150px 1fr; gap: 20px; padding: 15px 0; border-bottom: 1px solid rgba(17,16,14,.2); }
.type-card dt { text-transform: uppercase; letter-spacing: .1em; font-size: .62rem; font-weight: 700; }
.type-card dd { margin: 0; font-size: .9rem; }
.next-move { width: min(920px, calc(100% - 40px)); margin: 0 auto; padding: clamp(90px, 13vw, 170px) 0; text-align: center; }
.next-move .eyebrow { margin-bottom: 20px; }
.next-move h2 { margin-top: 0; }
.next-move > p { max-width: 650px; margin: 28px auto 0; color: var(--cream-muted); line-height: 1.8; }
.next-actions { justify-content: center; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 760px) {
  .site-header, footer, .hero { width: min(100% - 28px, 1180px); }
  .hero { padding-top: 68px; }
  .header-actions { gap: 10px; }
  .header-link { display: none; }
  h1 { font-size: clamp(3.5rem, 19vw, 5.8rem); }
  .code-preview { grid-template-columns: repeat(3, 1fr); }
  .code-preview div:nth-child(3) { border-right: 0; }
  .code-preview div:nth-child(-n + 3) { border-bottom: 1px solid var(--line); }
  .about-code { grid-template-columns: 1fr; }
  .book-inner { grid-template-columns: 1fr; text-align: center; }
  .book-tagline, .book-description { margin-inline: auto; }
  .book-retailers { justify-content: center; }
  .rating-row { grid-template-columns: 1fr; padding: 20px 16px; gap: 16px; }
  .rating-scale { grid-template-columns: repeat(5, 1fr); }
  .rating-scale span { width: 100%; min-width: 42px; }
  .scale-key { justify-content: space-between; gap: 8px; }
  .question-actions .primary-button { flex: 1; gap: 12px; }
  .result-types { flex-wrap: wrap; justify-content: center; }
  .score-row { grid-template-columns: 110px 1fr 52px; gap: 12px; }
  .score-label { gap: 8px; }
  .score-label span { font-size: .58rem; }
  .type-deep-dive { grid-template-columns: 1fr; }
  .type-card dl div { grid-template-columns: 1fr; gap: 6px; }
  footer { align-items: flex-start; padding: 28px 0; gap: 12px; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
