:root { --ink: #1b1a2e; --paper: #f6f1e7; --card: #fffdf8; --line: #e2d9c6; --accent: #e4572e; --accent2: #17768f; --muted: #6b6878; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.55 Georgia, 'Iowan Old Style', 'Times New Roman', serif; }
a { color: var(--accent2); }
h1, h2, h3, legend, .brand, button, .tier, .steps, nav, footer, label, select, input, .bar, small, .ctx { font-family: -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; }
header.top { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; max-width: 1080px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; color: var(--ink); text-decoration: none; letter-spacing: -.02em; }
.brand img { width: 30px; height: 30px; }
nav a { margin-left: 16px; text-decoration: none; color: var(--ink); font-size: 14px; padding: 12px 0; display: inline-block; }
main { max-width: 1080px; margin: 0 auto; padding: 0 20px 60px; }
.hero { display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; align-items: center; padding: 10px 0 22px; }
h1 { font-size: clamp(30px, 5vw, 50px); line-height: 1.05; margin: 0 0 12px; letter-spacing: -.03em; }
h1 em { font-style: normal; color: var(--accent); }
.lede { font-size: 18px; margin: 0 0 16px; max-width: 34em; }
.steps { background: var(--ink); color: #fff; border-radius: 14px; padding: 14px 18px; margin: 0; list-style: none; counter-reset: s; display: grid; gap: 6px; font-size: 15px; }
.steps li { counter-increment: s; }
.steps li::before { content: counter(s); display: inline-block; width: 22px; height: 22px; line-height: 22px; text-align: center; border-radius: 50%; background: var(--accent); margin-right: 10px; font-weight: 700; font-size: 13px; }
.cta { display: inline-block; margin-top: 16px; background: var(--accent); color: #fff; text-decoration: none; font: 700 16px -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; padding: 13px 22px; border-radius: 999px; }
.dial { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 18px; text-align: center; }
.dial svg { width: 100%; max-width: 260px; height: auto; }
#score { font: 800 54px -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; fill: var(--ink); }
.tier { font-weight: 700; font-size: 20px; margin-top: -4px; }
.ctx { color: var(--muted); font-size: 13px; margin-top: 4px; }
.layout { display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; align-items: start; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; margin: 0 0 16px; min-width: 0; }
legend, .card h2 { font-weight: 800; font-size: 17px; padding: 0 6px; margin: 0; }
.card h2 { padding: 0; margin-bottom: 10px; }
.q { margin: 12px 0; }
.q label { display: block; font-weight: 600; font-size: 15px; }
.q small, .note { display: block; color: var(--muted); font-size: 13px; }
.note { margin-top: 6px; }
.slide { display: flex; align-items: center; gap: 12px; }
.slide output { width: 26px; text-align: right; font: 700 16px -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; }
input[type=range] { flex: 1; height: 40px; accent-color: var(--accent); margin: 0; }
select, input[type=number] { width: 100%; height: 44px; border: 1px solid var(--line); border-radius: 10px; background: #fff; padding: 0 10px; font-size: 16px; color: var(--ink); margin-top: 4px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.seg { display: flex; gap: 8px; margin-top: 4px; }
.seg label { flex: 1; text-align: center; border: 1px solid var(--line); border-radius: 10px; height: 44px; line-height: 44px; cursor: pointer; background: #fff; }
.seg input { position: absolute; opacity: 0; }
.seg input:checked + span { color: var(--accent); font-weight: 800; }
.seg label:has(input:checked) { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.result { position: sticky; top: 12px; }
.bar { display: grid; grid-template-columns: 118px 1fr 30px; gap: 8px; align-items: center; font-size: 13px; margin: 7px 0; }
.track { background: #ece4d3; height: 9px; border-radius: 9px; overflow: hidden; }
.fill { background: var(--accent2); height: 100%; border-radius: 9px; transition: width .2s; }
.bv { text-align: right; font-weight: 700; }
.kv { font-size: 14px; margin: 8px 0 0; font-family: -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; }
.kv b { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
button { height: 44px; border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: #fff; font-weight: 700; font-size: 15px; padding: 0 18px; cursor: pointer; }
button.ghost { background: transparent; color: var(--ink); }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; align-items: center; }
details summary { cursor: pointer; font: 800 17px -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; min-height: 40px; line-height: 40px; }
.fine { font-size: 13px; color: var(--muted); }
.prose { max-width: 720px; }
.prose h1 { font-size: 36px; margin-top: 16px; }
.prose h2 { font-size: 20px; margin: 26px 0 6px; }
footer { border-top: 1px solid var(--line); padding: 22px 20px 40px; text-align: center; font-size: 13px; color: var(--muted); }
footer a { color: var(--ink); margin: 0 8px; display: inline-block; padding: 10px 0; }
@media (max-width: 820px) {
  .hero, .layout { grid-template-columns: 1fr; }
  .result { position: static; }
  nav a { margin-left: 12px; font-size: 13px; }
  .dial svg { max-width: 200px; }
}
.bar.skip { color: var(--muted); }
