/* Chapter 4: scene text, quiz diagrams, the mirror lab and the echo calculator. */

.rf-text { font: 600 32px system-ui, sans-serif; fill: #e8eefc; }
.rf-text.bold { font-weight: 800; fill: #ffd166; }
.rf-note { font: 600 24px system-ui, sans-serif; fill: #9fb4dd; }
.rf-tag { font: 800 36px system-ui, sans-serif; fill: #fff; }
.rf-tag.gold { fill: #ffd166; }
.rf-tag.orange { font-size: 28px; fill: #ff9f68; }

.quiz-svg { display: block; width: min(100%, 34cqw); height: auto; margin: max(6px, .8cqw) auto 0; }
.quiz-letter { font: 800 24px system-ui, sans-serif; fill: #ffd166; }

.lab-stage { align-self: center; }
.lab-svg-text { font: 700 24px system-ui, sans-serif; fill: #fff; }
.lab-svg-text.orange { fill: #ff9f68; }
.lab-svg-text.blue { fill: #74c0fc; }
.lab-svg-note { font: 600 20px system-ui, sans-serif; fill: #9fb4dd; }
.lab-controls { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; }
.lab-field { display: flex; align-items: center; gap: 8px; font-weight: 700; color: #cfd9ef; }
.lab-slider { width: max(140px, 18cqw); accent-color: #ffd166; height: 28px; }
.lab-readout { min-width: 3.6em; font-weight: 800; color: var(--gold); }

.calc-question { margin: 0; font-size: 1.1em; line-height: 1.45; text-align: center; }
.calc-question b { color: var(--gold); }
.calc-body { display: flex; flex-direction: column; gap: max(8px, 1.2cqw); width: 100%; align-items: center; }
.calc-step { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.calc-step[hidden] { display: none; }
.calc-values { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 14px; }
.calc-field { display: flex; align-items: center; gap: 6px; font-weight: 700; color: #cfd9ef; }
.calc-input {
  width: 8em;
  font: 700 1em ui-monospace, SFMono-Regular, Menlo, monospace;
  padding: .45em .6em;
  border-radius: .6em;
  border: 2px solid #3a4f7d;
  background: #0f1a33;
  color: #fff;
}
.calc-input.short { width: 4.5em; }
.calc-input:focus { outline: none; border-color: var(--gold); }
.calc-input:disabled { opacity: .85; }
.calc-input.wrong { border-color: var(--bad); }
.calc-input.correct { border-color: var(--ok); background: #143a28; }
.calc-unit { font-weight: 700; color: #cfd9ef; }

.echo-picture { width: min(100%, 44cqw); align-self: center; }
.echo-picture svg { display: block; width: 100%; height: auto; }
.echo-svg-text { font: 700 20px system-ui, sans-serif; fill: #9fb4dd; }
.echo-svg-you { font: 800 15px system-ui, sans-serif; fill: #14213d; }

@container (max-width: 620px) {
  .quiz-svg { width: 70%; }
  .echo-picture { width: 100%; }
  .lab-slider { width: 40vw; }
}
