/* Answer cards use the app's shared box style (--box-* in design.css, from Rune's mockup 2026-10-16).
   Fallbacks keep the same look until those variables are on main. Hover and selected stay page-specific. */
:root{--q-hover:#fdf1e8;--q-on:#fbe0cf;--q-on-border:#efb894}

/* Question page in the mockup style: segmented progress, soft answer cards with a chevron,
   quiet Back link and the test chips with icons. Layout and fit rules stay in design.css. */
.d-progress .d-segs{display:grid;grid-template-columns:repeat(5,1fr);gap:8px;min-width:0}
.d-segs i{display:block;height:10px;border-radius:6px;background:linear-gradient(90deg,#7ea6c8 calc(var(--f) * 100%),#e6eaef 0);transition:background .3s ease}
.d-segs i.is-now{background:linear-gradient(90deg,#7ea6c8 calc(var(--f) * 100%),#c9dbea 0)}
.d-progress>span:first-child{color:#4e6a8a}
.d-pct,.d-qnum{color:#4e6a8a!important;font-variant-numeric:tabular-nums}

.d-question-title{letter-spacing:-.025em}

.d-choice{border:1px solid var(--box-border,#e1e7ee);border-radius:var(--box-radius,12px);background:var(--box-bg,#fffefb);box-shadow:var(--box-shadow,0 1px 2px rgba(16,39,71,.04),0 6px 18px rgba(16,39,71,.05));color:var(--title);transition:background .18s ease,border-color .18s ease,transform .18s ease,box-shadow .18s ease}
.d-chev{flex:none;width:22px;height:22px;fill:none;stroke:#7c95b3;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
@media(hover:hover){.d-choice:hover{background:var(--q-hover);border-color:#ecd2c0;transform:translateY(-2px);box-shadow:0 8px 18px rgba(16,39,71,.08)}}
.d-choice:has(input:checked){background:var(--q-on);border-color:var(--q-on-border);transform:translateY(-2px);box-shadow:0 8px 18px rgba(16,39,71,.09)}
.d-choice:has(input:checked) .d-chev{stroke:var(--title)}
.d-choice:has(input:focus-visible){outline:3px solid #b2542a;outline-offset:3px}

.d-back{color:#4e6a8a;display:inline-flex;align-items:center;gap:10px}

.d-dev-row{position:relative;z-index:1;display:flex;flex-wrap:wrap;justify-content:center;gap:12px;margin-top:14px}
.d-dev-random{display:inline-flex;align-items:center;gap:8px;margin:0;padding:7px 16px;border:1px solid var(--box-border,#e1e7ee);border-radius:10px;background:var(--box-bg,#fffefb);color:#4e6a8a;font-size:14px;opacity:1;box-shadow:var(--box-shadow,0 1px 2px rgba(16,39,71,.04),0 6px 18px rgba(16,39,71,.05))}
.d-dev-random:hover{border-color:#b9c8d6;color:var(--title)}
.d-dev-icon{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linejoin:round}
.d-dev-icon circle{fill:currentColor;stroke:none}
.d-dev-icon circle[r="4"]{fill:none;stroke:currentColor}

/* Desktop and tablet: five cards in a row, text centred with the chevron under it */
@media(min-width:761px){
  .d-choice{padding:16px 10px 30px}
  .d-choice .d-chev{position:absolute;left:50%;bottom:10px;width:18px;height:18px;margin-left:-9px}
}

/* Phones: one card per line, text left and the chevron right, like the mockup */
@media(max-width:760px){
  .d-progress .d-segs{gap:6px}
  .d-segs i{height:8px}
  .d-choice{flex-direction:row;justify-content:space-between;gap:12px;padding:8px 14px 8px 20px;text-align:left}
  .d-dev-row{margin-top:8px}
  .d-dev-random{padding:6px 14px}
}
@media(max-width:760px) and (min-height:740px){
  .d-progress{margin-bottom:10px}
  .d-title-slot{min-height:calc(3 * 1.12 * clamp(28px,8.4vw,36px));margin:14px auto 18px}
  .d-title-slot .d-question-title,.d-title-slot .d-question-title.is-long{font-size:clamp(28px,8.4vw,36px)}
  .d-choices{gap:10px}
  .d-choice{min-height:56px;font-size:18px}
  .d-actions{margin-top:20px}
  .d-back,.d-next{font-size:18px}
  .d-note{margin-top:14px;font-size:14px}
}
