 :root {
     --bg: #f6f2ea;
     --bg-card: #ffffff;
     --ink: #14283d;
     --ink-soft: #4a5a73;
     --muted: #8a95a7;
     --line: #e4ded2;
     --accent: #0f6b6b;
     --accent-deep: #094848;
     --accent-soft: #e6f1f0;
     --risk-low: #3d7a4e;
     --risk-low-bg: #eaf3ec;
     --risk-mid: #b8791f;
     --risk-mid-bg: #fbf1de;
     --risk-high: #b0453a;
     --risk-high-bg: #f8e5e1;
     --radius: 14px;
     --radius-sm: 8px;
     --shadow: 0 1px 2px rgba(20, 40, 61, .04), 0 8px 24px rgba(20, 40, 61, .06);
 }

 * {
     box-sizing: border-box;
 }

 html,
 body {
     margin: 0;
     padding: 0;
     background: var(--bg);
     color: var(--ink);
     font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
     font-size: 16px;
     line-height: 1.55;
     -webkit-font-smoothing: antialiased;
 }

 .wrap {
     max-width: 720px;
     margin: 0 auto;
     padding: 48px 24px 80px;
 }

 /* ---------- Header ---------- */
 .eyebrow {
     font-family: 'DM Sans', sans-serif;
     font-size: 12px;
     font-weight: 500;
     letter-spacing: 0.18em;
     text-transform: uppercase;
     color: var(--accent);
     margin-bottom: 14px;
 }

 h1 {
     font-family: 'Fraunces', Georgia, serif;
     font-weight: 500;
     font-size: clamp(32px, 5vw, 46px);
     line-height: 1.1;
     letter-spacing: -0.02em;
     margin: 0 0 16px;
     color: var(--ink);
 }

 h1 em {
     font-style: italic;
     font-weight: 400;
     color: var(--accent);
 }

 .lead {
     font-size: 16px;
     color: var(--ink-soft);
     max-width: 560px;
     margin: 0 0 40px;
 }

 /* ---------- Card ---------- */
 .card {
     background: var(--bg-card);
     border: 1px solid var(--line);
     border-radius: var(--radius);
     padding: 32px;
     box-shadow: var(--shadow);
 }

 @media (max-width: 540px) {
     .wrap {
         padding: 32px 16px 60px;
     }

     .card {
         padding: 22px;
     }
 }

 .progress {
     display: flex;
     align-items: center;
     justify-content: space-between;
     margin-bottom: 28px;
     font-size: 13px;
     color: var(--muted);
     letter-spacing: 0.04em;
 }

 .progress-bar {
     flex: 1;
     height: 3px;
     background: var(--line);
     margin: 0 14px;
     border-radius: 2px;
     overflow: hidden;
 }

 .progress-fill {
     height: 100%;
     background: var(--accent);
     width: 0%;
     transition: width .4s ease;
 }

 /* ---------- Question ---------- */
 .question {
     padding: 22px 0;
     border-bottom: 1px solid var(--line);
 }

 .question:first-of-type {
     padding-top: 4px;
 }

 .question:last-of-type {
     border-bottom: none;
 }

 .q-head {
     display: flex;
     gap: 14px;
     align-items: baseline;
     margin-bottom: 14px;
 }

 .q-num {
     font-family: 'Fraunces', serif;
     font-style: italic;
     font-weight: 500;
     color: var(--accent);
     font-size: 15px;
     min-width: 24px;
 }

 .q-letter {
     display: inline-block;
     font-family: 'Fraunces', serif;
     font-weight: 600;
     color: var(--accent-deep);
     background: var(--accent-soft);
     padding: 2px 8px;
     border-radius: 4px;
     font-size: 12px;
     letter-spacing: 0.1em;
     margin-right: 8px;
     vertical-align: 2px;
 }

 .q-text {
     font-size: 16px;
     line-height: 1.5;
     color: var(--ink);
     font-weight: 500;
 }

 .q-hint {
     font-size: 13.5px;
     color: var(--muted);
     margin-top: 4px;
     font-weight: 400;
 }

 /* ---------- Options ---------- */
 .options {
     display: flex;
     gap: 10px;
     margin-left: 38px;
 }

 .opt {
     flex: 1;
     max-width: 120px;
 }

 .opt input {
     position: absolute;
     opacity: 0;
     pointer-events: none;
 }

 .opt label {
     display: block;
     text-align: center;
     padding: 10px 16px;
     border: 1px solid var(--line);
     border-radius: var(--radius-sm);
     font-size: 14px;
     font-weight: 500;
     color: var(--ink-soft);
     cursor: pointer;
     user-select: none;
     transition: all .18s ease;
     background: #fdfbf7;
 }

 .opt label:hover {
     border-color: var(--accent);
     color: var(--accent-deep);
 }

 .opt input:checked+label {
     background: var(--accent);
     border-color: var(--accent);
     color: #fff;
 }

 /* ---------- Submit ---------- */
 .actions {
     margin-top: 32px;
     display: flex;
     gap: 12px;
     align-items: center;
     flex-wrap: wrap;
 }

 .btn {
     font-family: inherit;
     font-size: 15px;
     font-weight: 500;
     padding: 12px 26px;
     border-radius: var(--radius-sm);
     border: none;
     cursor: pointer;
     transition: all .18s ease;
 }

 .btn-primary {
     background: var(--ink);
     color: #fff;
 }

 .btn-primary:hover {
     background: var(--accent-deep);
 }

 .btn-primary:disabled {
     background: var(--muted);
     cursor: not-allowed;
     opacity: 0.6;
 }

 .btn-ghost {
     background: transparent;
     color: var(--ink-soft);
     border: 1px solid var(--line);
 }

 .btn-ghost:hover {
     border-color: var(--ink-soft);
     color: var(--ink);
 }

 .status {
     font-size: 13px;
     color: var(--muted);
 }

 /* ---------- Result ---------- */
 .result {
     display: none;
 }

 .result.show {
     display: block;
 }

 .result-hero {
     text-align: center;
     padding: 32px 20px 28px;
     border-radius: var(--radius);
     margin-bottom: 24px;
 }

 .result-hero.low {
     background: var(--risk-low-bg);
     color: var(--risk-low);
 }

 .result-hero.mid {
     background: var(--risk-mid-bg);
     color: var(--risk-mid);
 }

 .result-hero.high {
     background: var(--risk-high-bg);
     color: var(--risk-high);
 }

 .score-label {
     font-size: 12px;
     letter-spacing: 0.18em;
     text-transform: uppercase;
     font-weight: 500;
     opacity: 0.8;
     margin-bottom: 6px;
 }

 .score {
     font-family: 'Fraunces', serif;
     font-weight: 500;
     font-size: 72px;
     line-height: 1;
     letter-spacing: -0.03em;
 }

 .score span {
     font-size: 28px;
     opacity: 0.5;
     font-style: italic;
 }

 .risk-name {
     font-family: 'Fraunces', serif;
     font-size: 26px;
     font-weight: 500;
     margin-top: 10px;
     letter-spacing: -0.01em;
 }

 .risk-desc {
     font-size: 15px;
     color: var(--ink-soft);
     margin: 0 0 20px;
     line-height: 1.6;
 }

 .answers-summary {
     border-top: 1px solid var(--line);
     padding-top: 20px;
     margin-top: 20px;
 }

 .answers-summary h3 {
     font-family: 'Fraunces', serif;
     font-weight: 500;
     font-size: 18px;
     margin: 0 0 14px;
     color: var(--ink);
 }

 .summary-row {
     display: flex;
     justify-content: space-between;
     align-items: center;
     padding: 8px 0;
     font-size: 14px;
     border-bottom: 1px dashed var(--line);
 }

 .summary-row:last-child {
     border-bottom: none;
 }

 .summary-row .label {
     color: var(--ink-soft);
 }

 .summary-row .val {
     font-weight: 500;
     padding: 2px 10px;
     border-radius: 4px;
     font-size: 12.5px;
 }

 .summary-row .val.yes {
     background: var(--accent-soft);
     color: var(--accent-deep);
 }

 .summary-row .val.no {
     background: #f0ede6;
     color: var(--muted);
 }

 .disclaimer {
     margin-top: 24px;
     padding: 16px 18px;
     background: #faf7f0;
     border-left: 3px solid var(--accent);
     border-radius: 4px;
     font-size: 13.5px;
     color: var(--ink-soft);
     line-height: 1.55;
 }

 .disclaimer strong {
     color: var(--ink);
     font-weight: 600;
 }

 /* ---------- Footer ---------- */
 .footer {
     text-align: center;
     margin-top: 28px;
     font-size: 12px;
     color: var(--muted);
     letter-spacing: 0.04em;
 }

 .footer a {
     color: var(--accent);
     text-decoration: none;
 }

 .footer a:hover {
     text-decoration: underline;
 }

 /* Hide number spinners if any */
 .error-shake {
     animation: shake .3s;
 }

 @keyframes shake {

     0%,
     100% {
         transform: translateX(0);
     }

     25% {
         transform: translateX(-4px);
     }

     75% {
         transform: translateX(4px);
     }
 }