/* /webcam-mic-test: three steps, one open at a time. Tokens and components
   come from site.css; this file only lays out the steps. */

.mt-steps { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.mt-step { min-width: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); }
.mt-step.is-open { border-color: var(--line-strong); }
.mt-step[data-state="pass"] { border-color: color-mix(in srgb, var(--ok) 45%, var(--line)); }
.mt-step[data-state="fail"] { border-color: color-mix(in srgb, var(--crit) 45%, var(--line)); }

/* The step's heading is a button that opens it (the accordion pattern). */
.mt-h { font: inherit; }
.mt-toggle { width: 100%; justify-content: flex-start; gap: 12px; padding: 12px 14px; border: 0; border-radius: var(--radius-sm);
  background: transparent; color: var(--ink); font: 600 17px/1.3 var(--f-body); text-align: left; }
.mt-toggle:hover { background: var(--sunk); }
.mt-title { flex: 1 1 auto; min-width: 0; }

.mt-mark { display: grid; place-items: center; width: 30px; height: 30px; flex: none; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font: 600 15px/1 var(--f-body); }
.mt-mark .ico { display: none; width: 18px; height: 18px; stroke-width: 2.4; }
.mt-step[data-state="pass"] .mt-mark { background: var(--ok); color: var(--accent-ink); }
.mt-step[data-state="fail"] .mt-mark { background: var(--crit); color: var(--panel); }
.mt-step[data-state="pass"] .mt-num, .mt-step[data-state="fail"] .mt-num { display: none; }
.mt-step[data-state="pass"] .mt-ok, .mt-step[data-state="fail"] .mt-bad { display: block; }

.mt-body { display: grid; gap: 14px; min-width: 0; padding: 4px 14px 16px; }
.mt-device { flex: 1 1 220px; }
.mt-body .toolbar > button { flex: none; }

/* The video and the message share the stage's one cell. */
.mt-stage { max-height: 50vh; }
.mt-stage > * { grid-area: 1 / 1; }
.mt-stage > p { max-width: 44ch; }

.mt-q { margin: 0; font-weight: 600; }
.mt-msg { display: grid; gap: 8px; }
.mt-msg:empty { display: none; }
.mt-small { font-size: clamp(26px, 4vw, 34px); }

/* The microphone bar and the line the voice has to cross. */
.mt-level { position: relative; padding-block: 6px; }
.mt-line { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--ink); opacity: .6; }

.mt-help { display: grid; gap: 8px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--sunk); font-size: 15px; }
.mt-help p { margin: 0; }
.mt-help ul { display: grid; gap: 6px; margin: 0; padding-left: 20px; }

.mt-next .ico { order: 2; }

.mt-done { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--ok-soft); }
.mt-done.is-warn { background: var(--warn-soft); }
.mt-done p { flex: 1 1 240px; margin: 0; font-weight: 600; }
