:root {
  --paper: #efe7d2;
  --paper-deep: #e5dbc1;
  --bone: #f7f1e3;
  --ink: #15140f;
  --muted: #6d695f;
  --line: rgba(21, 20, 15, .22);
  --coral: #ed6f5c;
  --mustard: #e9b94a;
  --olive: #6e7448;
  --serif: Georgia, "Songti SC", "STSong", serif;
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, monospace;
  --shadow: 0 24px 70px rgba(34, 29, 18, .18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--paper); }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--paper); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
button, a { color: inherit; font: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
.paper-noise { position: fixed; inset: 0; pointer-events: none; z-index: 30; opacity: .22; mix-blend-mode: multiply; background-image: repeating-radial-gradient(circle at 17% 21%, rgba(40,32,18,.16) 0 1px, transparent 1px 4px), repeating-linear-gradient(93deg, transparent 0 11px, rgba(255,255,255,.22) 12px, transparent 13px); background-size: 37px 41px, 71px 83px; }
.screen { display: none; min-height: 100svh; animation: pageIn .65s cubic-bezier(.2,.8,.2,1); }
.screen.is-active { display: block; }
@keyframes pageIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.site-header { height: 78px; padding: 0 clamp(20px,4vw,64px); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; position: relative; z-index: 3; }
.brand { font: 800 18px/1 var(--mono); letter-spacing: .28em; text-decoration: none; display: inline-flex; align-items: center; }
.brand i { width: 7px; height: 7px; margin-left: 3px; border-radius: 50%; background: var(--coral); }
.brand.small { font-size: 15px; }
.edition, .eyebrow, .section-kicker { font: 600 11px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.edition { color: var(--muted); }

.home-hero { min-height: calc(100svh - 78px); display: grid; grid-template-columns: minmax(390px,.85fr) minmax(520px,1.15fr); border-bottom: 1px solid var(--line); overflow: hidden; }
.hero-copy { padding: clamp(54px,7vw,110px) clamp(24px,6vw,96px); display: flex; flex-direction: column; justify-content: center; position: relative; z-index: 2; }
.hero-copy::before { content: "01"; position: absolute; left: clamp(24px,6vw,96px); top: 24px; font: italic 130px/.8 var(--serif); color: rgba(21,20,15,.055); }
.eyebrow { display: flex; align-items: center; gap: 14px; color: var(--muted); }
.eyebrow b { color: var(--ink); font-weight: 600; }
.eyebrow span::after { content: ""; display: inline-block; width: 34px; height: 1px; background: currentColor; margin-left: 14px; vertical-align: middle; }
.hero-copy h1 { margin: 22px 0 24px; font-size: clamp(66px,7.4vw,138px); line-height: .86; letter-spacing: -.075em; font-weight: 850; }
.hero-copy h1 em { font-family: var(--serif); font-weight: 400; color: var(--coral); }
.hero-copy h1 span, .test-manifesto h2 span, .share-panel h2 span { color: var(--coral); }
.hero-lead { margin: 0; font: 400 clamp(19px,2vw,28px)/1.65 var(--serif); }
.hero-actions { margin-top: clamp(34px,5vw,70px); }
.hero-actions p { margin: 15px 0 0; font-size: 12px; color: var(--muted); }
.hero-actions p strong { color: var(--ink); }
.primary-btn, .outline-btn { min-height: 58px; border: 1px solid var(--ink); padding: 0 22px; display: inline-flex; align-items: center; justify-content: space-between; gap: 30px; font-weight: 700; transition: transform .2s, box-shadow .2s, background .2s; }
.primary-btn { background: var(--ink); color: var(--bone); min-width: 240px; box-shadow: 7px 7px 0 var(--coral); }
.primary-btn b { font-size: 22px; }
.primary-btn:hover { transform: translate(-2px,-2px); box-shadow: 10px 10px 0 var(--coral); }
.outline-btn { background: transparent; }
.outline-btn:hover { background: var(--bone); }

.hero-art { margin: 0; position: relative; min-height: 620px; background: var(--ink); overflow: hidden; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(.92) contrast(1.03); }
.hero-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(239,231,210,.12), transparent 18%), linear-gradient(0deg, rgba(21,20,15,.6), transparent 28%); pointer-events: none; }
.hero-art figcaption { position: absolute; left: 28px; bottom: 24px; z-index: 2; color: var(--bone); font: 600 10px/1 var(--mono); letter-spacing: .12em; }
.hero-art figcaption b { color: var(--mustard); margin-right: 10px; }
.image-note { position: absolute; right: 28px; top: 26px; z-index: 2; color: var(--bone); font: 12px/1.7 var(--serif); text-align: right; }
.corner { position: absolute; width: 30px; height: 30px; z-index: 3; pointer-events: none; }
.corner::before, .corner::after { content: ""; position: absolute; background: var(--bone); }
.corner::before { width: 30px; height: 1px; }
.corner::after { width: 1px; height: 30px; }
.corner-a { left: 18px; top: 18px; }
.corner-b { right: 18px; bottom: 18px; transform: rotate(180deg); }

.test-manifesto { padding: clamp(70px,9vw,140px) clamp(24px,6vw,96px); display: grid; grid-template-columns: 80px 1fr 1fr; gap: clamp(22px,4vw,70px); align-items: start; }
.roman { font: italic 68px/1 var(--serif); color: var(--coral); }
.section-kicker { margin: 0 0 14px; color: var(--olive); }
.test-manifesto h2, .share-panel h2 { margin: 0; max-width: 740px; font-size: clamp(36px,4.8vw,76px); line-height: .98; letter-spacing: -.055em; }
.test-manifesto > p { margin: 28px 0 0; max-width: 600px; color: #39372f; font-size: 16px; line-height: 2; }
.dimension-strip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: grid; grid-template-columns: repeat(5,1fr); }
.dimension-strip span { padding: 25px 18px; border-right: 1px solid var(--line); text-align: center; font: 600 13px/1 var(--mono); }
.dimension-strip span:last-child { border-right: 0; }
.dimension-strip b { color: var(--coral); margin-right: 8px; }
.home-footer { min-height: 110px; padding: 30px clamp(24px,6vw,96px); display: flex; justify-content: space-between; align-items: center; font: 10px/1 var(--mono); letter-spacing: .12em; color: var(--muted); }
.text-btn { border: 0; background: none; padding: 12px 0; font-weight: 700; text-decoration: underline; text-underline-offset: 5px; }

/* Quiz */
.quiz-screen { background: var(--bone); }
.quiz-header { height: 72px; padding: env(safe-area-inset-top) clamp(18px,4vw,48px) 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.icon-btn { width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: transparent; font: 300 27px/1 var(--sans); }
.counter { justify-self: end; font: 700 15px/1 var(--mono); }
.counter i { color: var(--coral); margin: 0 6px; font-style: normal; }
.counter span:last-child { color: var(--muted); }
.progress-track { height: 4px; background: var(--paper-deep); }
.progress-track i { display: block; width: 4.16%; height: 100%; background: var(--coral); transition: width .45s ease; }
.question-shell { width: min(820px,100%); min-height: calc(100svh - 150px); margin: auto; padding: clamp(42px,8vh,96px) clamp(20px,5vw,60px) 36px; display: flex; flex-direction: column; justify-content: center; }
.question-shell.is-changing { animation: questionTurn .45s ease; }
@keyframes questionTurn { 0% { opacity: .15; transform: translateX(18px) rotate(.3deg); } 100% { opacity: 1; transform: none; } }
.question-meta { display: flex; align-items: center; gap: 18px; margin-bottom: 24px; }
.question-meta span { font: italic 52px/1 var(--serif); color: var(--coral); }
.question-meta b { font: 600 11px/1 var(--mono); letter-spacing: .14em; color: var(--olive); }
.question-scenario { color: var(--muted); font: italic 17px/1.7 var(--serif); margin: 0 0 8px; }
.question-shell h2 { max-width: 720px; margin: 0 0 32px; font-size: clamp(28px,4.6vw,48px); line-height: 1.34; letter-spacing: -.035em; }
.options { display: grid; gap: 12px; }
.option { width: 100%; min-height: 66px; padding: 15px 18px; border: 1px solid var(--line); background: var(--paper); text-align: left; display: grid; grid-template-columns: 30px 1fr; gap: 13px; align-items: center; line-height: 1.55; transition: border-color .2s, transform .2s, background .2s; }
.option span { font: italic 19px/1 var(--serif); color: var(--coral); }
.option:hover, .option:focus-visible { border-color: var(--ink); transform: translateX(4px); outline: none; }
.option.is-selected { color: var(--bone); background: var(--ink); border-color: var(--ink); }
.quiz-footer { width: min(820px,100%); margin: auto; padding: 0 clamp(20px,5vw,60px) calc(22px + env(safe-area-inset-bottom)); display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 11px; }
.back-btn { min-height: 44px; padding: 0; background: none; border: 0; font-weight: 700; }

/* Result */
.reset-link { background: none; border: 0; padding: 0; }
.result-article { overflow: hidden; }
.result-cover { min-height: calc(100svh - 78px); display: grid; grid-template-columns: minmax(420px,.9fr) minmax(520px,1.1fr); border-bottom: 1px solid var(--line); }
.result-cover-image { min-height: 650px; position: relative; background: var(--ink); overflow: hidden; }
.result-cover-image img { width: 100%; height: 100%; object-fit: cover; }
.result-cover-image::after { content: ""; position: absolute; inset: 0; box-shadow: inset 0 0 0 16px rgba(239,231,210,.12); pointer-events: none; }
.result-index { position: absolute; left: 26px; bottom: 20px; color: var(--bone); z-index: 2; font: italic 86px/.8 var(--serif); text-shadow: 0 3px 20px rgba(0,0,0,.3); }
.result-cover-copy { padding: clamp(52px,7vw,112px) clamp(26px,7vw,110px); display: flex; flex-direction: column; justify-content: center; }
.result-pretitle { margin: 50px 0 14px; color: var(--muted); font: italic 18px/1 var(--serif); }
.result-cover-copy h1 { margin: 0; font-size: clamp(64px,8vw,138px); line-height: .88; letter-spacing: -.075em; }
.result-mirror { margin: 24px 0 34px; color: var(--olive); font: italic clamp(18px,2vw,28px)/1.45 var(--serif); }
.result-cover blockquote { margin: 0; padding-left: 22px; border-left: 5px solid var(--coral); max-width: 650px; font: 400 clamp(21px,2vw,31px)/1.55 var(--serif); }
.tag-row { margin-top: 32px; display: flex; gap: 9px; flex-wrap: wrap; }
.tag-row span { border: 1px solid var(--line); padding: 9px 14px; border-radius: 99px; font-size: 12px; }
.report-section { padding: clamp(72px,9vw,140px) clamp(22px,8vw,130px); border-bottom: 1px solid var(--line); }
.section-heading { display: flex; gap: 18px; align-items: flex-start; margin-bottom: clamp(36px,5vw,70px); }
.section-heading > span { min-width: 46px; color: var(--coral); font: italic 50px/1 var(--serif); }
.section-heading p { margin: 1px 0 5px; color: var(--olive); font: 600 10px/1 var(--mono); letter-spacing: .13em; }
.section-heading h2 { margin: 0; font-size: clamp(34px,4vw,58px); line-height: 1; letter-spacing: -.04em; }
.lead-paragraph { max-width: 980px; margin: auto; font: 400 clamp(20px,2.3vw,32px)/1.9 var(--serif); text-align: justify; }
.lead-paragraph::first-letter { float: left; margin: .1em .14em 0 0; color: var(--coral); font: italic 4.2em/.72 var(--serif); }
.coordinates { background: var(--bone); }
.radar-wrap { display: grid; grid-template-columns: minmax(320px,.9fr) minmax(420px,1.1fr); gap: clamp(40px,7vw,110px); align-items: center; max-width: 1150px; margin: auto; }
#radarChart { width: 100%; overflow: visible; }
.score-grid { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.score-card { min-height: 144px; padding: 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.score-card > div { display: flex; justify-content: space-between; align-items: baseline; }
.score-card h3 { margin: 0; font-size: 18px; }
.score-card strong { color: var(--coral); font: italic 30px/1 var(--serif); }
.score-card p { margin: 16px 0 0; color: var(--muted); font-size: 13px; line-height: 1.7; }
.report-grid { display: grid; grid-template-columns: 1fr 1fr; padding-top: clamp(72px,9vw,140px); }
.section-heading.wide { grid-column: 1/-1; }
.report-grid article { position: relative; min-height: 300px; padding: clamp(30px,4vw,58px); border-top: 1px solid var(--line); border-right: 1px solid var(--line); }
.report-grid article:nth-of-type(even) { border-right: 0; }
.report-grid article > b { color: var(--coral); font: italic 24px/1 var(--serif); }
.report-grid h3 { margin: 22px 0 18px; font-size: clamp(25px,3vw,38px); }
.report-grid article p { margin: 0; color: #3b3932; font-size: 16px; line-height: 2; }
.shadow-card { background: var(--ink); color: var(--bone); }
.shadow-card p { color: #d8d0bd !important; }
.hidden-persona { background: var(--mustard); }
.hidden-card { max-width: 980px; margin: auto; background: var(--paper); display: grid; grid-template-columns: minmax(260px,.8fr) minmax(340px,1.2fr); box-shadow: var(--shadow); transform: rotate(-.4deg); }
.hidden-card img { width: 100%; height: 100%; min-height: 420px; object-fit: cover; }
.hidden-card > div { padding: clamp(30px,5vw,70px); display: flex; flex-direction: column; justify-content: center; }
.hidden-card > div > p:first-child { margin: 0 0 12px; color: var(--muted); font: italic 17px/1.4 var(--serif); }
.hidden-card h3 { margin: 0; font-size: clamp(38px,5vw,68px); line-height: 1; letter-spacing: -.055em; }
.hidden-card b { margin: 15px 0 26px; color: var(--coral); font: 600 11px/1 var(--mono); letter-spacing: .12em; }
.hidden-card p:last-child { margin: 0; line-height: 1.9; }
.growth { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px,8vw,120px); }
.growth .section-heading { grid-column: 1/-1; }
.growth-quote { display: grid; grid-template-columns: 46px 1fr; }
.growth-quote span { color: var(--coral); font: italic 70px/.8 var(--serif); }
.growth-quote p { margin: 0; font: 400 clamp(21px,2.5vw,34px)/1.7 var(--serif); }
.reading-list { border-left: 1px solid var(--line); padding-left: clamp(28px,5vw,68px); }
.reading-list > p { margin: 0 0 22px; font: 600 11px/1 var(--mono); color: var(--olive); letter-spacing: .12em; }
.reading-list ol { margin: 0; padding: 0; list-style: none; counter-reset: books; }
.reading-list li { counter-increment: books; padding: 17px 0; border-bottom: 1px solid var(--line); font: 600 17px/1.5 var(--serif); }
.reading-list li::before { content: "0" counter(books); margin-right: 18px; color: var(--coral); font: 11px/1 var(--mono); }
.share-panel { background: var(--olive); color: var(--bone); text-align: center; }
.share-panel .section-kicker { color: var(--mustard); }
.share-panel h2 { margin: auto; }
.share-actions { margin-top: 45px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px; }
.share-panel .primary-btn { background: var(--bone); color: var(--ink); border-color: var(--bone); }
.share-panel .outline-btn { color: var(--bone); border-color: var(--bone); }

.analysis-overlay { position: fixed; inset: 0; z-index: 100; background: var(--ink); color: var(--bone); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.analysis-overlay[hidden] { display: none; }
.analysis-overlay p { margin: 32px 0 8px; font: italic clamp(25px,5vw,46px)/1 var(--serif); }
.analysis-overlay span { color: #aaa492; font: 11px/1 var(--mono); letter-spacing: .1em; }
.analysis-mark { display: flex; gap: 12px; }
.analysis-mark i { width: 18px; height: 70px; display: block; background: var(--coral); animation: bars 1s ease-in-out infinite; }
.analysis-mark i:nth-child(2) { background: var(--mustard); animation-delay: .15s; }
.analysis-mark i:nth-child(3) { background: var(--olive); animation-delay: .3s; }
@keyframes bars { 0%,100% { transform: scaleY(.4); } 50% { transform: scaleY(1); } }
.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); z-index: 120; transform: translate(-50%,20px); padding: 12px 18px; background: var(--ink); color: var(--bone); opacity: 0; pointer-events: none; transition: .25s; font-size: 13px; box-shadow: var(--shadow); }
.toast.is-visible { opacity: 1; transform: translate(-50%,0); }

@media (max-width: 900px) {
  .home-hero, .result-cover { grid-template-columns: 1fr; }
  .hero-copy { min-height: 74svh; }
  .hero-art { min-height: 72svh; }
  .test-manifesto { grid-template-columns: 56px 1fr; }
  .test-manifesto > p { grid-column: 2; }
  .dimension-strip { grid-template-columns: 1fr 1fr; }
  .dimension-strip span { border-bottom: 1px solid var(--line); }
  .dimension-strip span:last-child { grid-column: 1/-1; }
  .result-cover-image { min-height: 78svh; order: 2; }
  .result-cover-copy { min-height: 74svh; order: 1; }
  .radar-wrap { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .site-header { height: 62px; padding: 0 18px; }
  .edition { font-size: 9px; }
  .home-hero { min-height: auto; }
  .hero-copy { min-height: calc(100svh - 62px); padding: 58px 20px 42px; justify-content: space-between; }
  .hero-copy::before { left: auto; right: 12px; top: 52px; font-size: 94px; }
  .hero-copy h1 { margin: auto 0 26px; font-size: clamp(58px,17.2vw,82px); }
  .hero-lead { font-size: 18px; }
  .hero-actions { margin-top: 32px; }
  .primary-btn { width: calc(100% - 8px); min-width: 0; }
  .hero-art { min-height: 78svh; }
  .hero-art img { object-position: 62% center; }
  .image-note { top: auto; bottom: 50px; }
  .test-manifesto { padding: 70px 20px; grid-template-columns: 42px 1fr; gap: 16px; }
  .roman { font-size: 48px; }
  .test-manifesto h2 { font-size: 38px; }
  .test-manifesto > p { margin-top: 10px; font-size: 14px; }
  .dimension-strip span { font-size: 11px; padding: 21px 8px; }
  .dimension-strip b { display: block; margin: 0 0 7px; }
  .home-footer { min-height: 92px; padding: 24px 20px; display: block; line-height: 1.5; }
  .home-footer .text-btn { margin-top: 8px; }
  .quiz-header { height: 62px; padding-left: 14px; padding-right: 14px; }
  .progress-track { height: 3px; }
  .question-shell { min-height: calc(100svh - 120px); padding: 34px 18px 22px; justify-content: flex-start; }
  .question-meta { margin: 8px 0 21px; }
  .question-meta span { font-size: 42px; }
  .question-scenario { font-size: 15px; }
  .question-shell h2 { font-size: 27px; margin-bottom: 26px; }
  .option { min-height: 62px; padding: 13px 14px; font-size: 14px; }
  .quiz-footer { padding: 0 18px calc(16px + env(safe-area-inset-bottom)); }
  .quiz-footer p { display: none; }
  .result-header .edition { max-width: 150px; text-align: right; }
  .result-cover { min-height: auto; }
  .result-cover-copy { min-height: auto; padding: 42px 20px 54px; order: 2; }
  .result-cover-copy .eyebrow { font-size: 9px; }
  .result-pretitle { margin-top: 34px; }
  .result-cover-copy h1 { font-size: clamp(58px,17vw,82px); }
  .result-mirror { font-size: 19px; margin: 18px 0 27px; }
  .result-cover blockquote { font-size: 20px; }
  .result-cover-image { min-height: 82vw; order: 1; }
  .report-section { padding: 70px 20px; }
  .section-heading { margin-bottom: 38px; }
  .section-heading > span { min-width: 35px; font-size: 40px; }
  .section-heading h2 { font-size: 34px; }
  .lead-paragraph { font-size: 19px; line-height: 1.85; text-align: left; }
  #radarChart { margin: -10px 0; }
  .score-grid { grid-template-columns: 1fr; }
  .score-card { min-height: 124px; }
  .report-grid { grid-template-columns: 1fr; }
  .report-grid article { min-height: 0; padding: 38px 4px; border-right: 0; }
  .hidden-card { grid-template-columns: 1fr; transform: none; }
  .hidden-card img { min-height: 86vw; }
  .hidden-card > div { padding: 30px 24px 38px; }
  .growth { grid-template-columns: 1fr; gap: 46px; }
  .reading-list { border-left: 0; border-top: 1px solid var(--line); padding: 34px 0 0; }
  .share-panel h2 { font-size: 43px; }
  .share-actions { display: grid; }
  .share-actions .outline-btn { width: calc(100% - 8px); }
}

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