/* Level "scan" figures (group G1). Every rule is scoped to #scan. */
#scan svg.dg.t15 { font-size: 15px; }
#scan .dg .halo { stroke: var(--surface); stroke-width: 5px; stroke-linejoin: round; paint-order: stroke; }
#scan .scan-fig { max-width: 36rem; }
/* The scanner diagram: faint rays, with a highlight that sweeps round once every 3.6 s (one ray per 0.1 s, in firing order).
   figs.css switches the animation off for readers who prefer reduced motion, which leaves the faint rays. */
#scan .scan-rays line { opacity: 0.22; animation: scan-sweep 3.6s linear infinite; }
@keyframes scan-sweep { 0% { opacity: 0.95; } 7% { opacity: 0.22; } 100% { opacity: 0.22; } }
/* Colour and depth side by side, with the depth colour scale under the depth image. */
#scan .scan-real .fig-row { margin: 0; grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr)); }
#scan .scan-real .depth-bar { display: block; width: 100%; height: 10px; border: 0; border-radius: 3px; margin-top: 6px; background: none; }
#scan .scan-real .depth-scale { display: flex; justify-content: space-between; gap: 8px; font-family: var(--f-mono); font-size: 0.72rem; color: var(--muted); margin-top: 2px; }
/* The 3D-points image sits beside its caption wherever the column is wide enough. */
@media (min-width: 1100px), (min-width: 560px) and (max-width: 899px) {
  #scan .scan-cloud { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 12px; align-items: center; }
  #scan .scan-cloud figcaption { margin-top: 0; }
}
/* The ray diagram is drawn narrow, so its labels stay large on a phone; centred in its column. */
#scan .scan-frame { max-width: 21rem; margin-inline: auto; }
/* On wide screens the idea diagram sits beside the text, as in the next levels, so the activity stays near the top. */
@media (min-width: 900px) {
  #scan .idea { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 30rem); grid-template-rows: auto 1fr; column-gap: 28px; align-items: start; }
  #scan .idea > h3, #scan .idea > .brief { grid-column: 1; }
  #scan .idea > .fig { grid-column: 2; grid-row: 1 / span 2; margin: 0; max-width: none; }
}
