/* Lab activities (the second Years 5 and 6 set): lamp solar candle balloon dissolve mould
   core filter (site/js/science/lab-bench.js). The frame and results chart are lab-kit.css. */

/* The shelf of things to test, above the drawing. */
.bx-shelf { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.2cqmin; flex: none; }
.bx-shelf .card { width: clamp(84px, 11cqw, 128px); padding-block: 0.4em; }
.bx-shelf .card-emoji { font-size: clamp(24px, 5cqmin, 38px); }
.bx-shelf .card-label { font-size: clamp(13px, 2.4cqmin, 17px); }
.lab-bench .lx-scene { flex: 1 1 0; width: 100%; height: auto; min-height: 0; max-height: 100%; }
.lab-bench .bx-go { font-size: clamp(16px, 3cqmin, 22px); }
.lab-bench .bx-go:disabled { opacity: 0.45; }

/* Upright on a phone: one column that grows as tall as it needs (sized by its width only, so the
   Try step scrolls rather than squeezing the drawing). */
@media (max-width: 600px) {
  .lab-bench { container-type: inline-size; height: auto; min-height: 0; grid-template-rows: auto auto; }
  .lab-bench .lx-wrap { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; height: auto; justify-items: center; gap: 16px; }
  .lab-bench .lx-rig { height: auto; width: 100%; }
  .lab-bench .lx-chart { width: 100%; }
  .lab-bench .lx-scene { flex: none; max-height: none; }
}

/* ---- Lamp ---- */
.lp-room { fill: #f6f0e2; transition: fill 0.5s; }
.lab-lamp.dark .lp-room { fill: #1c1f29; }
.lp-table { fill: #c89b6d; transition: fill 0.5s; }
.lab-lamp.dark .lp-table { fill: #3a2f27; }
.lp-beam { pointer-events: none; }
.lp-thing { stroke: rgb(29 36 51 / 0.35); stroke-width: 2.5; }
.lp-vein { fill: none; stroke: rgb(0 0 0 / 0.25); stroke-width: 3; stroke-linecap: round; }
.lp-label { fill: #1d2433; font: 600 24px var(--ui); text-anchor: middle; }
.lab-lamp.dark .lp-label { fill: #e8ecf4; }
.lp-torch-body { fill: #5d6b82; }
.lp-torch-head { fill: #3e4a5e; }
.lp-torch-button { fill: #e0453a; }
.lp-filter { stroke: #1d2433; stroke-width: 2; transition: fill 0.3s; }

/* ---- Solar ---- */
.so-sky { fill: #cfeaff; }
.so-grass { fill: #8fcf6e; }
.so-sun { fill: #ffc93a; stroke: #ff9d1c; stroke-width: 4; }
.so-glow { fill: rgb(255 201 58 / 0.3); }
.so-rays line { stroke: #ffb21c; stroke-width: 4; stroke-dasharray: 10 10; animation: so-run 1s linear infinite; }
.so-rays.dim line { opacity: 0.25; }
@keyframes so-run { to { stroke-dashoffset: -20; } }
.so-cloud { fill: #fff; stroke: #c6d3e2; stroke-width: 2; }
.so-cells { fill: #1f3f8a; stroke: #9fb4d8; stroke-width: 2; }
.so-grid { stroke: #9fb4d8; stroke-width: 1.5; }
.so-back { fill: #8a94a6; }
.so-stand { fill: none; stroke: #6a7c94; stroke-width: 7; stroke-linecap: round; }
.so-wire { fill: none; stroke: #e0453a; stroke-width: 4; stroke-linecap: round; }
.so-box { fill: #fff; stroke: #6a7c94; stroke-width: 4; }
.so-dial { fill: none; stroke: #c6d3e2; stroke-width: 10; }
.so-tick { stroke: #1d2433; stroke-width: 3; }
.so-needle { stroke: #e0453a; stroke-width: 4; stroke-linecap: round; }
.so-pin { fill: #1d2433; }
.so-reading { fill: #1d2433; font: 700 28px var(--ui); text-anchor: middle; }
.so-pole { fill: #8a94a6; }
.so-blades ellipse { fill: #3aa6d8; stroke: #22769e; stroke-width: 2; }

/* ---- Candle ---- */
.cd-room { fill: #f4ecdc; }
.cd-table { fill: #b98a5e; }
.cd-plate { fill: #fff; stroke: #d6dce6; stroke-width: 3; }
.cd-cup { fill: #d6dce6; stroke: #9aa6b8; stroke-width: 2; }
.cd-wick { stroke: #1d2433; stroke-width: 3; }
.cd-flame { fill: #ffb21c; stroke: #ff7a1c; stroke-width: 2; }
.cd-smoke { fill: none; stroke: #9aa6b8; stroke-width: 5; stroke-linecap: round; }
.cd-glass { fill: rgb(207 233 255 / 0.35); stroke: #7fa6c8; stroke-width: 5; }
.cd-dial { fill: #fff; stroke: #1d2433; stroke-width: 5; }
.cd-crown { fill: #1d2433; }
.cd-watch { fill: #1d2433; font: 700 30px var(--ui); text-anchor: middle; dominant-baseline: middle; }

/* ---- Balloon ---- */
.bl-room { fill: #f4f6fb; }
.bl-table { fill: #c89b6d; }
.bl-tub { fill: none; stroke: #6a7c94; stroke-width: 7; stroke-linejoin: round; }
.bl-water { fill: #bfe3f7; opacity: 0.85; transition: fill 0.4s; }
.bl-ice rect { fill: #fff; stroke: #8fb8d8; stroke-width: 2; }
.bl-steam path { fill: none; stroke: #c6d3e2; stroke-width: 5; stroke-linecap: round; }
.bl-glass { fill: rgb(207 233 255 / 0.3); stroke: #5a8fb8; stroke-width: 5; stroke-linejoin: round; }
.bl-balloon { fill: #e5484d; stroke: #b82d32; stroke-width: 3; }
.bl-tube { fill: #fff; stroke: #6a7c94; stroke-width: 3; }
.bl-bulb { fill: #e0453a; }
.bl-temp { fill: #1d2433; font: 700 24px var(--ui); text-anchor: middle; }

/* ---- Dissolve ---- */
.ds-room { fill: #f6f0e2; }
.ds-table { fill: #c89b6d; }
.ds-water { fill: #cfe9ff; transition: fill 0.3s; }
.ds-glass { fill: none; stroke: #6a7c94; stroke-width: 7; stroke-linejoin: round; }
.ds-sugar, .ds-grains rect { fill: #fff; stroke: #c6d3e2; stroke-width: 2; }
.ds-spoon line { stroke: #8a94a6; stroke-width: 8; stroke-linecap: round; }
.ds-spoon ellipse { fill: #8a94a6; }
.ds-steam path { fill: none; stroke: #c6d3e2; stroke-width: 5; stroke-linecap: round; }
.ds-clock { fill: #fff; stroke: #1d2433; stroke-width: 5; }
.ds-hand { stroke: #e0453a; stroke-width: 5; stroke-linecap: round; }
.ds-pin { fill: #1d2433; }
.ds-time { fill: #1d2433; font: 700 28px var(--ui); text-anchor: middle; }

/* ---- Mould ---- */
.ml-room { fill: #f6f0e2; transition: fill 0.4s; }
.lab-mould[data-place="cold"] .ml-room { fill: #dcecfb; }
.ml-bag { fill: rgb(255 255 255 / 0.5); stroke: #9aa6b8; stroke-width: 3; }
.ml-zip { fill: #3a86d8; }
.ml-crust { fill: #b9773a; }
.ml-bread { fill: #f3dcb0; }
.ml-spots circle { fill: #4f7f52; }
.ml-spots circle:nth-child(3n) { fill: #7a8a4a; }
.ml-spots circle:nth-child(4n) { fill: #2f5d6e; }
.ml-drops path { fill: #5aa9f0; opacity: 0.8; }
.ml-calendar { fill: #fff; stroke: #1d2433; stroke-width: 3; }
.ml-calendar-top { fill: #e0453a; }
.ml-day { fill: #1d2433; font: 700 24px var(--ui); text-anchor: middle; }
.ml-place { fill: #1d2433; font: 600 22px var(--ui); text-anchor: middle; }

/* ---- Core ---- */
.cr-sky { fill: #d8efff; }
.cr-grass { fill: #6fb34f; }
.cr-band { stroke: rgb(0 0 0 / 0.12); stroke-width: 2; cursor: pointer; transition: filter 0.2s; }
.cr-band.on { stroke: var(--gold, #f2b01e); stroke-width: 5; }
.cr-rock { fill: rgb(29 36 51 / 0.75); font: 600 17px var(--ui); text-anchor: end; dominant-baseline: middle; pointer-events: none; }
.cr-hole { fill: rgb(40 28 18 / 0.45); pointer-events: none; }
.cr-fossil { font: 40px/1 var(--emoji); text-anchor: middle; dominant-baseline: middle; pointer-events: none; }
.cr-ruler line { stroke: #1d2433; stroke-width: 2.5; }
.cr-ruler text { fill: #1d2433; font: 600 15px var(--ui); text-anchor: end; dominant-baseline: middle; }
.cr-tape { stroke: #f2b01e; stroke-width: 6; stroke-linecap: round; }
.cr-tape-text { fill: #1d2433; font: 700 22px var(--ui); dominant-baseline: middle; }
.cr-pick { font: 38px/1 var(--emoji); pointer-events: none; }

/* ---- Filter ---- */
.fl-room { fill: #f4f6fb; }
.fl-bottle { fill: rgb(207 233 255 / 0.25); stroke: #5a8fb8; stroke-width: 5; stroke-linejoin: round; }
.fl-glass { fill: rgb(207 233 255 / 0.25); stroke: #6a7c94; stroke-width: 6; stroke-linejoin: round; }
.fl-layer { stroke: rgb(0 0 0 / 0.15); stroke-width: 1.5; }
.fl-layer.cotton { stroke: #aab6c8; stroke-width: 3; stroke-dasharray: 3 5; stroke-linecap: round; }
.fl-layer.gravel { stroke-dasharray: 6 4; stroke: #6f6f6a; stroke-width: 3; }
.fl-mud { fill: #7a5230; opacity: 0.9; }
.fl-drip { fill: #9fb4c8; }
.fl-jug-body { fill: #e7d4bd; stroke: #8d6235; stroke-width: 3; stroke-linejoin: round; }
