main { padding-block: clamp(1.6rem, 4vw, 3rem); }
h1 { max-width: none; font-size: clamp(2.1rem, 5vw, 3.5rem); margin: 0 0 .45rem; }
main > p, #task { max-width: 68ch; margin: .5rem 0; }
#trial, #results { margin-top: 1.5rem; }
.progress-line { display: flex; align-items: center; gap: 1rem; margin-bottom: .65rem; color: #205953; font-weight: 650; }
progress { accent-color: #24766b; width: 9rem; height: .6rem; }
.experiment-bench { margin-top: 1rem; }
#test-controls, #measurement, #results { padding: clamp(1rem, 2.5vw, 1.5rem); background: #fff; border: 1px solid #c6d2d5; border-radius: .6rem; }
#settings { padding: 0; margin: 0; min-width: 0; border: 0; }
#settings legend { padding: 0; font-weight: 700; }
#test-controls label, .switch-row { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .5rem 0 .1rem; }
#settings strong { font-variant-numeric: tabular-nums; color: #1b625b; }
#settings input[type=range] { width: 100%; margin: 0; min-height: 32px; accent-color: #22695f; }
#settings input[type=number] { width: 100%; font: inherit; border: 1px solid #718b88; border-radius: .3rem; min-height: 44px; }
#test-controls button, #results button, #measurement button { min-height: 44px; border-radius: .3rem; }
#test-switch { display: inline-flex; align-items: center; gap: .45rem; padding: .3rem .55rem; background: #eff4f3; color: #1f433f; }
#test-switch i { position: relative; width: 2.1rem; height: 1.15rem; border-radius: 1rem; background: #617572; }
#test-switch i::after { content: ''; position: absolute; inset: .16rem auto auto .16rem; width: .82rem; height: .82rem; border-radius: 50%; background: white; }
#test-switch[aria-checked=true] i { background: #217568; }
#test-switch[aria-checked=true] i::after { transform: translateX(.96rem); }
#measure, #next, #restart { margin-top: .8rem; background: #1d6059; }
#setup-error { color: #843426; margin: .6rem 0 0; }
#setup-error:empty { margin: 0; }
#measurement { background: #edf5f3; border-inline-start: 4px solid #267768; }
#measurement h3 { margin: 0; }
#measurement p, #results p { margin: .5rem 0; }
#review { padding-inline-start: 1.5rem; }
#review li { padding: .5rem 0; border-bottom: 1px solid #d7e1de; }
.back-link { display: inline-block; margin: 1rem 0; padding-block: .4rem; }
@media (prefers-reduced-motion: no-preference) {
  #test-switch i::after { transition: transform .18s ease; }
  #measurement:not([hidden]) { animation: reveal .28s ease-out; }
  @keyframes reveal { from { opacity: .3; transform: translateY(4px); } to { opacity: 1; transform: none; } }
}
