/* ==========================================================================
   Make Lab — dark machine workspace (scoped by .sm-lab tokens from app.css)
   One loud thing: the print bed + layer scrubber. Everything else stays quiet.
   ========================================================================== */
.sm-lab-page .sm-main { padding-bottom: 0; }
.lab [hidden]:not(.lab-scrim) { display: none !important; } /* the scrim has its own [hidden] rule so it can fade out */
.lab { --ok: var(--mint); --warn: var(--butter); --bad: color-mix(in srgb, var(--err) 55%, #fff); --glass: color-mix(in srgb, var(--lab) 84%, transparent); position: relative; }
.lab-head { padding-top: 18px; padding-bottom: 14px; }
.lab-h1 { font-size: clamp(1.5rem, 5.4vw, 2.75rem); font-weight: 850; line-height: 1.02; letter-spacing: -.028em; max-width: 19em; margin: 0 0 8px; }
.lab-lede { color: var(--ink-2); max-width: 46em; margin: 0; font-size: 15px; line-height: 1.5; }

/* ---------- workspace ---------- */
.lab-ws { display: grid; grid-template-columns: minmax(0, 1fr); }
.lab-stage { position: relative; height: clamp(420px, 60svh, 560px); background: var(--lab); }
.lab.has-parts .lab-stage { position: sticky; top: var(--top-h); z-index: 20; height: 45vh; height: 45svh; min-height: 280px; box-shadow: 0 1px 0 var(--lab-line); }
/* No touch-action here: OrbitControls sets touch-action:none on its own canvas, so touches on the model
   turn it while the empty bed and the 2D preview still scroll the page on phones. */
.lab-view { position: absolute; inset: 0; overflow: hidden; }
/* The holders stack on top of each other; only the visible canvas takes input (the empty 2D holder used to eat every drag). */
.lab-glh, .lab-2dh { position: absolute; inset: 0; pointer-events: none; }
.lab-gl, .lab-2d { position: absolute; inset: 0; display: block; outline: none; pointer-events: auto; }
.lab-gl { cursor: grab; }
.lab-gl:active { cursor: grabbing; }
.lab-gl:focus-visible { outline: 2px solid var(--laser); outline-offset: -2px; }
/* one-time "you can move this" chip over the model */
.lab-hint { position: absolute; left: 50%; bottom: 78px; transform: translateX(-50%); z-index: 3; margin: 0; padding: 6px 14px; border-radius: var(--pill); background: var(--glass); box-shadow: inset 0 0 0 1px var(--lab-line); color: #fff; font-size: 13px; font-weight: 650; white-space: nowrap; pointer-events: none; animation: lab-fade .2s var(--ease); }
@keyframes lab-fade { from { opacity: 0; } }
/* phones: under the camera buttons, left of the Overlays column, so it never covers the (framed-small) model or its sizes */
@media (max-width: 599px) { .lab-hint { top: auto; bottom: 104px; left: 50%; padding: 5px 12px; font-size: 12px; white-space: nowrap; } }
.lab-gl-labels { position: absolute; inset: 0; pointer-events: none; }
.lab-dim { padding: 2px 7px; border-radius: var(--r-xs); background: var(--glass); color: #fff; font-size: 12px; white-space: nowrap; box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-none { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 6px; text-align: center; padding: 24px; color: var(--ink-2); }
.lab-none__ic svg { width: 44px; height: 44px; fill: none; stroke: var(--ink-3); stroke-width: 1.4; }
.lab-none strong { color: #fff; font-size: 17px; word-break: break-all; }

/* empty state: the print bed is the drop zone */
.lab-empty { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px 16px; }
.lab-bed { position: absolute; inset: 0; perspective: 800px; overflow: hidden; pointer-events: none; }
.lab-bed__plate { position: absolute; left: 50%; top: 74%; width: min(150vw, 1100px); aspect-ratio: 1; transform: translate(-50%, -50%) rotateX(64deg);
  background:
    repeating-linear-gradient(0deg, rgba(160,190,230,.13) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(90deg, rgba(160,190,230,.13) 0 1px, transparent 1px 44px),
    radial-gradient(closest-side, var(--lab-2), var(--lab));
  -webkit-mask-image: radial-gradient(closest-side, #000 55%, transparent 100%); mask-image: radial-gradient(closest-side, #000 55%, transparent 100%);
  transition: filter var(--dur-1) var(--ease-out); }
.lab-bed__x { position: absolute; left: 50%; top: 92%; width: 36px; height: 36px; transform: translate(-50%, -50%) scaleY(.45); opacity: .7;
  background: linear-gradient(var(--laser), var(--laser)) center / 100% 2px no-repeat, linear-gradient(var(--laser), var(--laser)) center / 2px 100% no-repeat; }
.lab-drop { position: relative; display: grid; justify-items: center; gap: 10px; text-align: center; max-width: 30em; margin-top: -8%; }
.lab-drop__t { margin: 0; font-size: clamp(1.35rem, 4.6vw, 2rem); font-weight: 850; font-variation-settings: 'wdth' 118; letter-spacing: -.02em; color: #fff; }
.lab-drop__s { margin: 0 0 6px; color: var(--ink-2); font-size: 15px; }
.lab-filepick { position: relative; overflow: hidden; }
.lab-filepick input[type="file"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.lab-filepick:focus-within { outline: 2px solid #fff; outline-offset: 3px; }
.lab-filepick__hint { margin: -4px 0 0; color: var(--ink-3); font-size: 12px; line-height: 1.35; }
@media (min-width: 768px) { .lab-filepick__hint { display: none; } }
.lab-samples { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px; margin: 10px 0 0; font-size: 14px; color: var(--ink-3); }
.lab-samples > span { width: 100%; }
.lab-samples button, .lab-alt button { min-height: 40px; padding: 6px 14px; border: 0; border-radius: var(--pill); background: var(--lab-2); color: #dfe8f5; font-weight: 650; font-size: 14px; box-shadow: inset 0 0 0 1px var(--lab-line); }
@media (hover: hover) and (pointer: fine) { .lab-samples button:hover, .lab-alt button:hover { box-shadow: inset 0 0 0 1.5px var(--laser-2); color: #fff; } }
.lab-samples small { font-size: 11px; font-weight: 700; color: var(--ink-3); margin-left: 2px; font-variation-settings: 'wdth' 75; }
.lab-alt { margin: 2px 0 0; font-size: 14px; color: var(--ink-3); }
.lab-alt button { background: transparent; box-shadow: none; padding: 6px 4px; text-decoration: underline; text-underline-offset: 3px; color: var(--ink-2); }
@media (hover: hover) and (pointer: fine) { .lab-alt button:hover { box-shadow: none; } }

/* file dragged anywhere over the page: the bed lights up */
.lab-veil { position: absolute; inset: 10px; display: grid; place-items: center; border-radius: calc(var(--r-lg) - 10px); pointer-events: none; opacity: 0;
  box-shadow: inset 0 0 0 2px var(--laser); transition: opacity var(--dur-2) var(--ease-out); }
.lab-veil span { padding: 10px 18px; border-radius: var(--pill); background: #fff; color: var(--lab); font-weight: 750; }
.lab.is-drag .lab-veil { opacity: 1; }
.lab.is-drag .lab-bed__plate { filter: hue-rotate(185deg) saturate(2.4) brightness(1.25); }

/* loading */
.lab-load { position: absolute; inset: 0; z-index: 4; display: grid; place-content: center; justify-items: center; gap: 12px; background: var(--glass); color: #fff; font-weight: 650; }
.lab-load p { margin: 0; }
.lab-load__track { display: block; width: min(240px, 60vw); height: 3px; border-radius: 3px; background: var(--lab-line); overflow: hidden; }
#labLoadBar { display: block; height: 100%; background: var(--laser); transform-origin: left; transition: transform .2s linear; }

/* viewer tools */
.lab-tools { position: absolute; top: 10px; left: 10px; right: 10px; z-index: 3; display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; pointer-events: none; }
.lab-tools__g { display: flex; gap: 2px; padding: 3px; border-radius: var(--pill); background: var(--glass); box-shadow: inset 0 0 0 1px var(--lab-line); pointer-events: auto; }
.lab-tools__g + .lab-tools__g { flex-direction: column; border-radius: var(--r-lg); } /* a tall column: a pill end would be a dome */
@media (min-width: 600px) { .lab-tools__g + .lab-tools__g { flex-direction: row; border-radius: var(--pill); } }
.lab-tool { min-width: 44px; min-height: 40px; padding: 0 11px; border: 0; border-radius: var(--pill); background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 700; }
@media (hover: hover) and (pointer: fine) { .lab-tool:hover { color: #fff; background: rgba(255,255,255,.06); } }
.lab-tool[aria-pressed="true"] { background: #fff; color: var(--lab); }

/* layer scrubber — the signature moment */
.lab-slice { position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 3; display: grid; grid-template-columns: 44px 1fr; grid-template-areas: "play range" "out out"; align-items: center; gap: 2px 10px;
  padding: 6px 12px 8px 6px; border-radius: var(--r-lg); background: var(--glass); box-shadow: inset 0 0 0 1px var(--lab-line); }
@media (min-width: 600px) { .lab-slice { grid-template-columns: 44px 1fr auto; grid-template-areas: "play range out"; left: 50%; right: auto; width: min(620px, calc(100% - 20px)); transform: translateX(-50%); } }
.lab-slice__play { grid-area: play; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: #fff; color: var(--lab); }
.lab-slice__play svg { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; fill: none; }
.lab-slice input { grid-area: range; width: 100%; height: 44px; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; box-shadow: none !important; padding: 0; min-height: 0; }
.lab-slice input::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: repeating-linear-gradient(90deg, rgba(223,232,245,.28) 0 2px, transparent 2px 5px); }
.lab-slice input::-moz-range-track { height: 6px; border-radius: 3px; background: repeating-linear-gradient(90deg, rgba(223,232,245,.28) 0 2px, transparent 2px 5px); }
.lab-slice input::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border-radius: 50%; background: #fff; border: 5px solid var(--laser); box-shadow: 0 2px 10px rgba(0,0,0,.5); }
.lab-slice input::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 5px solid var(--laser); }
.lab-slice input:focus-visible { outline: 2px solid var(--laser); outline-offset: 2px; }
.lab-slice__out { grid-area: out; font-size: 13px; color: #fff; white-space: nowrap; padding-left: 4px; }
.lab-slice__out span { color: var(--ink-3); margin-left: 8px; }

/* ---------- rail ---------- */
.lab-rail { padding: 0 max(16px, var(--safe-r)) calc(var(--tab-h) + 170px + var(--safe-b)) max(16px, var(--safe-l)); min-width: 0; }
.lab-parts { margin: 0 -16px; padding: 12px 16px 4px; overflow-x: auto; scrollbar-width: none; }
.lab-parts::-webkit-scrollbar { display: none; }
.lab-parts ul { display: flex; gap: 8px; margin: 0; padding: 0; list-style: none; }
.lab-part { display: grid; grid-template-columns: 48px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 10px; align-items: center; width: 190px; min-height: 60px; padding: 6px 10px 6px 6px; border: 0; border-radius: var(--r); background: var(--lab-2); color: #dfe8f5; text-align: left; box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-part.is-on { box-shadow: inset 0 0 0 2px var(--laser); }
.lab-part__th { grid-row: 1 / 3; display: grid; place-items: center; width: 48px; height: 48px; border-radius: var(--r-sm); overflow: hidden; background: var(--lab); }
.lab-part__th img { width: 100%; height: 100%; object-fit: cover; }
.lab-part__ic svg { width: 22px; height: 22px; fill: none; stroke: var(--ink-3); stroke-width: 1.6; }
.lab-part__plus { font-size: 26px; font-weight: 400; color: var(--ink-2); line-height: 1; }
.lab-part__n { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; align-self: end; }
.lab-part__s { font-size: 12px; color: var(--ink-3); align-self: start; }
.lab-part--add { width: auto; min-width: 150px; background: transparent; box-shadow: inset 0 0 0 1.5px dashed var(--lab-line); border: 1.5px dashed var(--edge-2); }

.lab-intro { padding: 24px 0 8px; }
.lab-intro__h { font-size: 18px; font-variation-settings: 'wdth' 110; margin-bottom: 14px; }
.lab-kinds { display: grid; gap: 16px; margin: 0; padding: 0; list-style: none; }
.lab-kinds li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.lab-kinds strong { display: block; color: #fff; font-size: 15.5px; }
.lab-kinds span { color: var(--ink-2); font-size: 14.5px; line-height: 1.45; }
.lab-intro__foot { margin: 20px 0 0; padding-top: 16px; border-top: 1px solid var(--lab-line); color: var(--ink-3); font-size: 14px; }

/* part header + service picker */
.lab-ph { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 16px 0 10px; }
.lab-ph__name { margin: 0; font-weight: 800; font-size: 17px; color: #fff; word-break: break-all; font-variation-settings: 'wdth' 108; }
.lab-ph__meta { margin: 2px 0 0; font-size: 13px; color: var(--ink-3); }
.lab-ic { display: inline-grid; place-items: center; flex: none; width: 44px; height: 44px; border: 0; border-radius: var(--pill); background: transparent; color: var(--ink-2); font-size: 20px; font-weight: 600; }
@media (hover: hover) and (pointer: fine) { .lab-ic:hover { background: rgba(255,255,255,.07); color: #fff; } }
.lab-ic svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.lab-svc { padding: 4px 0 16px; border-bottom: 1px solid var(--lab-line); }
.lab-svc__g { display: grid; gap: 8px; }
.lab-svc__c { display: grid; grid-template-columns: 18px 1fr; column-gap: 12px; align-items: start; width: 100%; padding: 12px 14px; border: 0; border-radius: var(--r); background: var(--lab-2); color: #dfe8f5; text-align: left; box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-svc__c::before { content: ''; grid-row: 1 / 3; width: 18px; height: 18px; margin-top: 2px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--ink-3); }
.lab-svc__c strong { font-size: 15.5px; color: #fff; }
.lab-svc__c span { font-size: 13.5px; color: var(--ink-2); line-height: 1.4; }
.lab-svc__c[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--laser); background: color-mix(in srgb, var(--laser) 8%, var(--lab-2)); }
.lab-svc__c[aria-pressed="true"]::before { box-shadow: inset 0 0 0 5px var(--laser); background: #fff; }
.lab-svc__more { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.lab-svc__one { margin: 0; display: grid; gap: 2px; }
.lab-svc__one strong { color: #fff; font-size: 16px; }
.lab-svc__one span { color: var(--ink-2); font-size: 14px; }
/* phones: only the chosen way keeps its one-line why, so the settings rows come into view sooner */
@media (max-width: 599px) { .lab-svc__g { gap: 6px; } .lab-svc__c { padding: 10px 14px; align-items: center; } .lab-svc__c:not([aria-pressed="true"]) span { display: none; } .lab-svc__c::before { margin-top: 0; } }
@media (min-width: 600px) and (max-width: 959px), (min-width: 1280px) { .lab-svc__g { grid-template-columns: repeat(3, 1fr); } }

/* option groups */
.lab-grp { padding: 16px 0; border-bottom: 1px solid var(--lab-line); }
.lab-grp__t { margin: 0 0 10px; font-size: 15px; font-weight: 750; font-variation-settings: 'wdth' 108; letter-spacing: 0; color: #fff; }
.lab-grp--sheet { padding: 0; }
.lab-grp__open { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 0; border: 0; background: transparent; color: #fff; text-align: left; cursor: pointer; }
.lab-grp__open .lab-grp__t { margin: 0; flex: none; }
.lab-grp__sum { flex: 1; min-width: 0; text-align: right; color: #dfe8f5; font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
@media (hover: hover) and (pointer: fine) {
  .lab-grp__open:hover .lab-grp__sum { color: #fff; }
  .lab-grp__open:hover .lab-chev { stroke: var(--laser); }
}
.lab-grp__open:focus-visible { outline: 2px solid var(--laser); outline-offset: 2px; border-radius: var(--r-sm); }
.lab-chev { width: 18px; height: 18px; fill: none; stroke: var(--ink-3); stroke-width: 2; flex: none; transition: transform var(--dur-1) var(--ease-out); }
.lab-grp.is-open .lab-chev { transform: rotate(90deg); stroke: var(--laser); }
.lab-grp__bar { display: none; }
.lab-grp--sheet .lab-grp__b { display: none; }
/* scale with steppers + live size readout */
.lab-scale { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lab-scale .lab-qty { grid-template-columns: 44px 76px 44px; }
.lab-fields.lab-fields--size { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 18px; }
.lab-fields--size > .lab-f:first-child { flex: 1 1 auto; min-width: 0; }
.lab-fields--size > .lab-f:last-child { flex: 0 0 132px; }
.lab-scale__out { font-size: 13.5px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.lab-sub { margin: 12px 0 8px; font-size: 13px; font-weight: 700; color: var(--ink-2); }
.lab-sub:first-child { margin-top: 0; }
.lab-help { margin: 8px 0 0; font-size: 13.5px; color: var(--ink-3); line-height: 1.45; }
.lab-note { color: var(--ink-2); }
.lab-row, .lab-chips, .lab-sws { display: flex; flex-wrap: wrap; gap: 8px; }
.lab-chip { min-height: 44px; }
.lab-chip__s { font-size: 12px; font-weight: 600; opacity: .7; }
.lab-row .sm-btn--line, .lab-own .sm-btn--line { color: #dfe8f5 !important; box-shadow: inset 0 0 0 1.5px var(--edge-2); min-height: 44px; }
@media (hover: hover) and (pointer: fine) { .lab-row .sm-btn--line:hover, .lab-own .sm-btn--line:hover { background: var(--lab-2); box-shadow: inset 0 0 0 1.5px #fff; } }
.lab-sws { margin-top: 14px; gap: 10px; }
.lab-sw { width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--c); box-shadow: inset 0 -6px 10px rgba(0,0,0,.25), inset 0 3px 6px rgba(255,255,255,.3), 0 0 0 1px var(--lab-line); position: relative; }
.lab-sw[aria-pressed="true"] { box-shadow: inset 0 -6px 10px rgba(0,0,0,.25), inset 0 3px 6px rgba(255,255,255,.3), 0 0 0 3px var(--lab), 0 0 0 5px var(--laser); }
.lab-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; }
.lab-f { display: grid; gap: 6px; font-size: 13px; font-weight: 700; color: var(--ink-2); }
.lab-f > span:first-child { font-weight: 700; }
.lab-f2 { display: grid; gap: 12px; }
@media (min-width: 520px) { .lab-f2 { grid-template-columns: 1fr 1fr; } }
.lab-unit { position: relative; display: block; }
.lab-unit input { padding-right: 44px; }
.lab-unit em { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); font-style: normal; color: var(--ink-3); font-weight: 600; pointer-events: none; }
.lab-out { display: flex; align-items: center; min-height: 50px; padding: 0 14px; border-radius: var(--r-sm); background: color-mix(in srgb, var(--lab-2) 50%, transparent); color: #fff; font-size: 16px; }
.lab-qty { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; border-radius: var(--r-sm); box-shadow: inset 0 0 0 1.5px var(--edge); background: var(--lab-2); }
.lab-qty input { min-height: 48px; padding: 0; text-align: center; box-shadow: none !important; background: transparent; font-weight: 750; -moz-appearance: textfield; }
.lab-qty input::-webkit-inner-spin-button, .lab-qty input::-webkit-outer-spin-button { -webkit-appearance: none; }
.lab-switch { display: flex; align-items: center; gap: 12px; margin-top: 14px; min-height: 44px; font-size: 14.5px; font-weight: 600; color: #dfe8f5; cursor: pointer; }
.lab-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.lab-switch span { flex: none; width: 44px; height: 26px; border-radius: var(--pill); background: var(--lab-line); box-shadow: inset 0 0 0 1px var(--edge-2); position: relative; transition: background-color var(--dur-1) ease; }
.lab-switch span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform var(--dur-1) var(--ease-out); }
.lab-switch input:checked + span { background: var(--laser); }
.lab-switch input:checked + span::after { transform: translateX(18px); }
.lab-switch input:focus-visible + span { outline: 2.5px solid var(--laser); outline-offset: 3px; }

/* printability checks */
.lab-checks { display: grid; gap: 2px; margin: 0; padding: 12px 0; list-style: none; border-bottom: 1px solid var(--lab-line); }
.lab-checks:empty { display: none; }
.lab-ck { display: grid; grid-template-columns: 22px 1fr auto; gap: 10px; align-items: start; padding: 8px 0; font-size: 14.5px; line-height: 1.4; }
.lab-ck__i svg { width: 22px; height: 22px; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.lab-ck.is-ok .lab-ck__i svg { stroke: var(--ok); }
.lab-ck.is-warn .lab-ck__i svg { stroke: var(--warn); }
.lab-ck.is-bad .lab-ck__i svg { stroke: var(--bad); }
.lab-ck.is-ok .lab-ck__t { color: var(--ink-2); }
.lab-ck__b { min-height: 36px; padding: 4px 10px; margin: -6px 0; border: 0; border-radius: var(--pill); background: transparent; color: var(--laser-2); font-weight: 700; font-size: 13.5px; white-space: nowrap; text-decoration: underline; text-underline-offset: 3px; }
@media (hover: hover) and (pointer: fine) { .lab-ck__b:hover { background: rgba(255,122,47,.1); } }
.lab-ck__bs { grid-column: 2 / 4; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.lab-ck__bs .lab-ck__b { margin: 0; min-height: 40px; text-decoration: none; box-shadow: inset 0 0 0 1.5px var(--edge-2); color: #dfe8f5; }
.lab-ck__bs .lab-ck__b.is-go { background: #fff; box-shadow: none; color: var(--lab); }
.lab-ck--ask { padding: 12px; margin-bottom: 6px; border-radius: var(--r); background: color-mix(in srgb, var(--butter) 9%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--butter) 35%, transparent); }
.lab-msg { margin: 14px 0; padding: 14px 16px; border-radius: var(--r); background: var(--lab-2); color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-msg p { margin: 0; }
.lab-msg.is-bad { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--err) 60%, transparent); }

/* color legend (vector files) */
.lab-legend { display: grid; gap: 10px; margin: 12px 0 0; padding: 0; list-style: none; }
.lab-legend li { display: grid; grid-template-columns: 20px minmax(0, 1fr); grid-template-areas: "c t" "s s"; gap: 6px 10px; align-items: center; }
@media (min-width: 420px) { .lab-legend li { grid-template-columns: 20px minmax(0, 1fr) auto; grid-template-areas: "c t s"; } }
.lab-legend__c { grid-area: c; width: 20px; height: 20px; border-radius: var(--r-xs); background: var(--c); box-shadow: inset 0 0 0 1px rgba(255,255,255,.25); }
.lab-legend__t { grid-area: t; font-size: 14px; font-weight: 650; color: #fff; }
.lab-legend__t small { display: block; font-size: 12.5px; color: var(--ink-3); font-weight: 600; }
.lab-seg { grid-area: s; display: inline-flex; padding: 3px; border-radius: var(--pill); background: var(--lab); box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-seg button { min-height: 38px; min-width: 64px; padding: 0 10px; border: 0; border-radius: var(--pill); background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 700; }
.lab-seg button[aria-pressed="true"] { background: #fff; color: var(--lab); }

/* stats */
.lab-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 16px 0 0; border-radius: var(--r); overflow: hidden; background: var(--lab-line); }
.lab-stats div { padding: 10px 12px; background: var(--lab); }
.lab-stats dt { font-size: 12px; font-weight: 650; color: var(--ink-3); }
.lab-stats dd { margin: 2px 0 0; font-size: 15px; color: #fff; }
.lab-stats:empty { display: none; }

/* ---------- price bar ---------- */
.lab-bar { position: fixed; left: calc(8px + var(--safe-l)); right: calc(8px + var(--safe-r)); bottom: calc(var(--tab-h) + 16px + var(--safe-b)); z-index: 55; display: grid; gap: 8px;
  padding: 10px 10px 10px 16px; border-radius: var(--r-lg); background: color-mix(in srgb, var(--lab-2) 94%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 0 0 1px var(--lab-line), 0 18px 40px -12px rgba(0,0,0,.7); grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "row go" "break break" "alt alt"; align-items: center; }
.lab-bar[hidden] { display: none; }
.lab-bar__row { grid-area: row; display: flex; align-items: center; gap: 4px; min-width: 0; }
/* number, "+₱40" chip and "about ₱N each" share one line (centred, not baseline) so the bar height never changes on an edit */
.lab-bar__price { display: grid; grid-template-columns: auto auto minmax(0, 1fr); grid-template-areas: "lbl lbl lbl" "tot delta each"; align-items: center; column-gap: 8px; min-width: 0; }
.lab-bar__lbl { grid-area: lbl; }
.lab-bar__tot { grid-area: tot; }
.lab-bar__each { grid-area: each; }
.lab-bar__each:empty { display: none; }
/* "+₱40" next to the number whenever an edit changes it */
.lab-bar__delta { grid-area: delta; justify-self: start; padding: 2px 8px; border-radius: var(--pill); background: color-mix(in srgb, var(--laser) 22%, transparent); color: #fff; font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; animation: lab-fade .2s var(--ease); }
.lab-bar__delta.is-down { background: color-mix(in srgb, var(--mint) 22%, transparent); }
.lab-bar__tot.is-changed { animation: lab-pulse .5s var(--ease); }
@keyframes lab-pulse { 0% { background: color-mix(in srgb, var(--laser) 18%, transparent); color: #fff; } 100% { background: transparent; } }
.lab-bar__lbl { font-size: 12px; font-weight: 700; color: var(--ink-3); }
.lab-bar__tot { margin: 0 -4px; padding: 0 4px; border-radius: var(--r-sm); font-size: 28px; line-height: 1; font-weight: 900; font-variation-settings: 'wdth' 112; font-variant-numeric: tabular-nums; color: var(--laser); letter-spacing: -.02em; }
.lab-bar__tot.is-text { font-size: 17px; color: #fff; font-weight: 750; }
.lab-bar__each { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lab-bar__break .lab-each { display: none; } /* phones only: the bar has no room for it there */
.lab-bar__more { align-self: end; min-height: 36px; margin-left: 2px; padding: 0 8px; border: 0; border-radius: var(--pill); background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.lab-bar__go { grid-area: go; width: auto; min-height: 52px; padding: 12px 18px; white-space: nowrap; }
.lab-bar__go:disabled { opacity: .55; cursor: progress; }
.lab-bar__break { grid-area: break; display: none; }
.lab-bar__break.is-open { display: block; max-height: 42dvh; overflow: auto; overscroll-behavior: contain; padding-top: 4px; border-top: 1px solid var(--lab-line); }
.lab-bar__alt { grid-area: alt; justify-self: center; min-height: 32px; padding: 0 8px; border: 0; background: transparent; color: var(--ink-2); font-size: 13.5px; font-weight: 650; text-decoration: underline; text-underline-offset: 3px; display: none; }
.lab-bar__break.is-open ~ .lab-bar__alt:not([hidden]) { display: block; }
.lab-bar__chat { grid-area: auto; grid-column: 1 / -1; display: none; line-height: 32px; } /* implicit row: no empty gap while hidden */
.lab-chat a { color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.lab-chat a:hover { color: var(--laser); }
p.lab-chat a { display: inline-flex; align-items: center; min-height: 44px; }
.lab-intro__foot.lab-chat { margin-top: 4px; padding-top: 0; border-top: 0; }
@media (min-width: 960px) { .lab-drop .lab-chat { display: none; } } /* desktop: the intro column beside the bed carries this link; phones keep it by the drop zone */
.lab-break { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 8px 0 4px; padding: 0; list-style: none; font-size: 13.5px; color: var(--ink-2); }
.lab-break b { color: #fff; font-weight: 700; margin-left: 2px; }
.lab-why { margin: 8px 0; font-size: 13.5px; color: var(--warn); }
.lab-ready { margin: 8px 0 0; font-size: 13.5px; color: var(--ink-2); }
.lab-bar__break .lab-note { margin: 8px 0 0; font-size: 13.5px; }
.lab-bar .lab-switch { margin-top: 6px; }

/* bottom sheets for option groups (phones): slide by transform only, out the way they came in.
   Without allow-discrete / @starting-style a browser just shows and hides them, as before. */
.lab-scrim { position: fixed; inset: 0; z-index: 85; background: rgba(5,10,20,.55); opacity: 1; transition: opacity var(--dur-3) var(--ease-out), display var(--dur-3) allow-discrete; }
.lab-scrim[hidden] { display: none; opacity: 0; pointer-events: none; transition-duration: var(--dur-2); } /* no taps eaten while it fades */
@starting-style { .lab-scrim:not([hidden]) { opacity: 0; } }
@media (max-width: 959px) {
  /* --kb: keyboard height from lab.js, so a focused field stays above the keyboard */
  .lab-grp--sheet .lab-grp__b { position: fixed; left: 0; right: 0; bottom: var(--kb, 0px); z-index: 90; max-height: calc(78dvh - var(--kb, 0px)); overflow: auto; overscroll-behavior: contain; padding: 0 16px calc(24px + var(--safe-b));
    border-radius: var(--r-lg) var(--r-lg) 0 0; background: var(--lab-2); box-shadow: 0 -20px 50px rgba(0,0,0,.5); transform: translateY(100%); transition: transform var(--dur-2) var(--ease-drawer), display var(--dur-2) allow-discrete; }
  .lab-grp--sheet.is-open .lab-grp__b { display: block; transform: none; transition-duration: var(--dur-3); }
  @starting-style { .lab-grp--sheet.is-open .lab-grp__b { transform: translateY(100%); } }
  /* not tied to .is-open: the header stays on the sheet while it slides away */
  .lab-grp--sheet .lab-grp__bar { display: flex; position: sticky; top: 0; z-index: 1; align-items: center; justify-content: space-between; gap: 12px; margin: 0 -16px 12px; padding: 14px 16px 10px; background: var(--lab-2); color: #fff; font-size: 16px; }
  /* the page behind an open sheet stays put */
  html:has(.lab-grp--sheet.is-open) { overflow: hidden; }
  /* body has overflow-x: hidden: with html no longer visible, body would become the scroller and unstick the header and the bed */
  html:has(.lab-grp--sheet.is-open) body { overflow: visible; }
}
.lab-grp__est { margin-left: auto; color: var(--laser); font-size: 18px; font-weight: 900; font-variant-numeric: tabular-nums; border-radius: var(--r-sm); padding: 0 4px; }
.lab-grp__est[data-delta]::after { content: attr(data-delta); margin-left: 6px; padding: 2px 7px; border-radius: var(--pill); background: color-mix(in srgb, var(--laser) 22%, transparent); color: #fff; font-size: 12px; font-weight: 800; vertical-align: 2px; }
.lab-grp__est.is-changed { animation: lab-pulse .5s var(--ease); }

/* dialogs: a card that fades and settles in, faster out; phones get a bottom sheet */
.lab-dlg { width: 100%; max-width: 100%; max-height: 92vh; margin: auto 0 0; padding: 18px 16px calc(20px + var(--safe-b)); border: 0; border-radius: var(--r-lg) var(--r-lg) 0 0; background: var(--lab-2); color: #dfe8f5; box-shadow: 0 -20px 60px rgba(0,0,0,.6); overflow: auto; overscroll-behavior: contain;
  opacity: 0; transform: scale(.96); transition: opacity var(--dur-1) var(--ease-out), transform var(--dur-1) var(--ease-out), overlay var(--dur-1) allow-discrete, display var(--dur-1) allow-discrete; }
.lab-dlg[open] { opacity: 1; transform: none; transition-duration: var(--dur-2); }
@starting-style { .lab-dlg[open] { opacity: 0; transform: scale(.96); } }
.lab-dlg::backdrop { background: rgba(5,10,20,.6); opacity: 0; transition: opacity var(--dur-2) var(--ease-out), overlay var(--dur-2) allow-discrete, display var(--dur-2) allow-discrete; }
.lab-dlg[open]::backdrop { opacity: 1; }
@starting-style { .lab-dlg[open]::backdrop { opacity: 0; } }
@media (max-width: 639px) {
  .lab-dlg { opacity: 1; transform: translateY(100%); transition-timing-function: var(--ease-drawer); max-height: calc(92dvh - var(--kb, 0px)); margin: auto 0 var(--kb, 0px); }
  .lab-dlg[open] { transform: none; transition-duration: var(--dur-3); }
  @starting-style { .lab-dlg[open] { opacity: 1; transform: translateY(100%); } } /* a sheet slides, it doesn't fade */
}
@media (min-width: 640px) { .lab-dlg { max-width: 520px; margin: auto; border-radius: var(--r-lg); padding: 24px; } }
/* touch: the page behind stays put (body: see the sheet lock above). Not for mouse pointers: Chrome drops the
   scrollbar gutter of a hidden root, so the page would jump sideways; a wheel over the backdrop is harmless there. */
@media (pointer: coarse) { html:has(.lab-dlg[open]) { overflow: hidden; } html:has(.lab-dlg[open]) body { overflow: visible; } }
.lab-dlg__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.lab-dlg__h { margin: 0; font-size: 22px; color: #fff; }
.lab-form { display: grid; gap: 12px; }
.lab-form .lab-f--svc { display: none; }
.lab-form.is-describe .lab-f--svc { display: grid; }
.lab-form textarea { min-height: 90px; resize: vertical; }
.lab-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lab-check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; font-size: 13.5px; font-weight: 500; color: var(--ink-2); }
.lab-check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--laser); }
.lab-check a { color: var(--laser-2); text-decoration: underline; }
.lab-done p { color: var(--ink-2); }
/* what you are sending, above the form */
.lab-rv { margin: 6px 0 0; padding: 10px 12px 4px; border-radius: var(--r); background: var(--lab); box-shadow: inset 0 0 0 1px var(--lab-line); }
.lab-rv__sum { margin: 0; color: #dfe8f5; font-size: 13.5px; line-height: 1.5; }
.lab-rv__edit { min-height: 36px; padding: 0; border: 0; background: none; color: var(--laser-2); font-weight: 700; font-size: 13.5px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* owner panel (manage_woocommerce only; injected by lab.js after a server capability check) */
.lab-own { margin: 16px 8px 24px; padding: 18px 16px 20px; border-radius: var(--r-lg); background: var(--lab-2); color: #dfe8f5; box-shadow: 0 0 0 1.5px var(--laser); }
.lab-own__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.lab-own__h { margin: 0; font-size: 20px; color: #fff; }
.lab-own__tag { padding: 3px 10px; border-radius: var(--pill); background: var(--laser); color: #fff; font-size: 12px; font-weight: 750; }
.lab-own__job { margin: 8px 0 14px; font-size: 14px; color: var(--ink-2); }
.lab-own__job a, .lab-own__out a { color: var(--laser-2); text-decoration: underline; }
.lab-own__cols { display: grid; gap: 20px; }
.lab-own__stats { margin-top: 8px; }
.lab-own__base { grid-column: 1 / -1; }
.lab-own__base dd { color: var(--laser) !important; font-size: 20px !important; font-weight: 800; }
.lab-own__out p { margin: 8px 0 0; font-size: 14px; }
.lab-own__link { display: flex; gap: 8px; margin-top: 8px; }
.lab-own__link input { flex: 1; min-width: 0; font-size: 16px; }
@media (min-width: 960px) {
  .lab-own { max-width: 1536px; margin: 0 auto 40px; padding: 24px 28px; }
  .lab-own__cols { grid-template-columns: minmax(0, 1fr) minmax(320px, 440px); gap: 32px; align-items: start; }
}

/* ---------- desktop ---------- */
@media (min-width: 960px) {
  .lab-head { padding-top: 28px; padding-bottom: 20px; width: 100%; max-width: 1240px; margin: 0 auto; padding-left: 32px; padding-right: 32px; } /* same 1240px column as .sm-container: title and bed line up with the header logo */
  .lab-ws { grid-template-columns: minmax(0, 60fr) minmax(380px, 40fr); gap: 24px; width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 32px 40px; align-items: start; }
  /* whole workspace (title + bed + options) fits one desktop screen; the info sections come after */
  .sm-lab.lab { display: flex; flex-direction: column; height: calc(100vh - var(--top-h) - var(--bar-h)); height: calc(100svh - var(--top-h) - var(--bar-h)); min-height: 600px; max-height: 1040px; }
  /* owner mode: the Owner panel sits inside #lab, so the Lab grows and the workspace keeps its one-screen height */
  .sm-lab.lab:has(> .lab-own) { height: auto; max-height: none; }
  .sm-lab.lab:has(> .lab-own) > .lab-ws { flex: none; height: calc(100svh - var(--top-h) - var(--bar-h) - 100px); min-height: 500px; max-height: 940px; }
  .lab-h1 { font-size: clamp(1.6rem, 2.4vw, 2.4rem); max-width: none; margin-bottom: 4px; }
  .lab-head { padding-top: 16px !important; padding-bottom: 14px !important; }
  .lab-ws { flex: 1; min-height: 0; grid-template-rows: minmax(0, 1fr); align-items: stretch !important; padding-bottom: 20px !important; }
  .lab-stage, .lab.has-parts .lab-stage { position: relative; top: auto; height: auto; min-height: 0; max-height: none; border-radius: var(--r-lg); overflow: hidden; box-shadow: 0 0 0 1px var(--lab-line); }
  /* "magnet": a scroll that ends near the workspace settles on it */
  html:has(.sm-lab-page) { scroll-snap-type: y proximity; }
  .sm-lab.lab, .lab-info { scroll-snap-align: start; scroll-margin-top: var(--top-h); }
  .lab-view { border-radius: var(--r-lg); }
  .lab-rail { position: relative; height: auto; min-height: 0; padding: 0; display: flex; flex-direction: column; }
  .lab-parts { flex: none; margin: 0; padding: 0 0 6px; }
  .lab-intro { padding-top: 8px; }
  .lab-panel:empty { display: none; }
  /* no overscroll containment: once the rail reaches its end, the wheel scrolls the page */
  .lab-intro, .lab-panel { flex: 1; min-height: 0; overflow-y: auto; padding-right: 8px; scrollbar-width: thin; scrollbar-color: var(--edge-2) transparent; }
  .lab-ph { padding-top: 10px; }
  /* settings rows open inline, one at a time (lab.js openSheet) */
  .lab-grp--sheet .lab-grp__b { display: none; }
  .lab-grp--sheet.is-open .lab-grp__b { display: block; position: static; padding: 0 0 12px; transition: opacity var(--dur-1) var(--ease-out), translate var(--dur-1) var(--ease-out); }
  @starting-style { .lab-grp--sheet.is-open .lab-grp__b { opacity: 0; translate: 0 -4px; } } /* no height animation: the rows below just move */
  .lab-grp--sheet .lab-grp__bar { display: none; }
  .lab-stats { grid-template-columns: repeat(3, 1fr); }
  /* compact estimate strip: the settings above stay in view */
  .lab-bar { position: static; z-index: auto; /* a flex item keeps z-index even when static: 55 would paint over the sticky header */ flex: none; margin-top: 10px; padding: 8px 14px; column-gap: 14px; row-gap: 2px; grid-template-areas: "row go" "break break"; }
  .lab-bar__more { display: none; }
  .lab-bar__break, .lab-bar__break.is-open { display: flex; flex-wrap: wrap; gap: 2px 14px; align-items: center; max-height: none; border-top: 0; padding-top: 2px; }
  .lab-bar__break p, .lab-bar .lab-switch { margin: 0; font-size: 12.5px; line-height: 1.35; }
  .lab-bar .lab-switch { min-height: 24px; gap: 8px; }
  /* one line of copy under the price: the fuller sentence lives in the phone Details sheet and in the quote dialog */
  .lab-bar__break .lab-note, .lab-bar .lab-where { display: none; }
  .lab-scale { flex-wrap: nowrap; }
  .lab-bar .lab-switch span { width: 34px; height: 20px; }
  .lab-bar .lab-switch span::after { top: 3px; left: 3px; width: 14px; height: 14px; }
  .lab-bar .lab-switch input:checked + span::after { transform: translateX(14px); }
  .lab-bar__go { min-height: 44px; padding: 10px 16px; }
  .lab-bar__alt, .lab-bar__break.is-open ~ .lab-bar__alt:not([hidden]) { display: none; }
}

/* ---------- below the tool (shop side, light) ---------- */
.lab-info { padding: 8px 0 24px; }
.lab-sec { padding-top: var(--sec); padding-bottom: calc(var(--sec) * .75); }
.lab-sec > .sm-h2 { max-width: 20em; }
/* the questions themselves are .sm-acc (app.css, dark in pages.css): no per-page cards here */
.lab-faq__list { margin-top: 20px; max-width: 820px; }
/* one joined stack (app.css squares the inner corners); overlap the two 1px inset borders into one hairline seam */
.lab-faq .sm-acc + .sm-acc { margin-top: -1px; }
.lab-trust { display: grid; gap: 24px; }
@media (min-width: 900px) { .lab-trust { grid-template-columns: repeat(3, 1fr); } }
.lab-trust > div { padding-top: 18px; border-top: 2px solid var(--ink); }
.lab-trust p { color: var(--ink-2); margin: 0 0 12px; }
.lab-pay { display: flex; flex-wrap: wrap; gap: 6px; }
.lab-pay span { padding: 5px 10px; border-radius: var(--r-xs); background: var(--paper); box-shadow: inset 0 0 0 1px var(--edge); font-weight: 700; font-size: 12.5px; color: var(--ink); }

/* ---------- touch: press feedback, no text selection on controls, bigger hit areas ---------- */
:is(.lab-tool, .lab-ic, .lab-sw, .lab-seg button, .lab-ck__b, .lab-samples button, .lab-slice__play, .lab-svc__c, .lab-part) { transition: scale var(--dur-press) var(--ease-out), background-color var(--dur-1) ease, color var(--dur-1) ease, box-shadow var(--dur-1) ease; }
:is(.lab-tool, .lab-ic, .lab-seg button, .lab-ck__b, .lab-samples button, .lab-slice__play):active { scale: .97; }
.lab-sw:active { scale: .92; }
:is(.lab-svc__c, .lab-part):active { scale: .98; }
.lab-grp__open:active { background: rgba(255,255,255,.04); }
:is(.lab-tool, .lab-ic, .lab-sw, .lab-seg button, .lab-ck__b, .lab-samples button, .lab-grp__open, .lab-part, .lab-svc__c), .lab-stage { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
/* 4px of invisible hit area; less where neighbours sit closer than 8px (segments touch, samples are 6px apart).
   .lab-tool gets none: its groups are 2px apart in both directions. */
:is(.lab-bar__more, .lab-bar__alt, .lab-ck__b, .lab-rv__edit, .lab-seg button, .lab-sw, .lab-samples button) { position: relative; }
:is(.lab-bar__more, .lab-bar__alt, .lab-ck__b, .lab-rv__edit, .lab-seg button, .lab-sw, .lab-samples button)::after { content: ''; position: absolute; inset: -4px; }
.lab-seg button::after { inset: -4px 0; }
.lab-samples button::after { inset: -3px; }

/* ---------- phones: give the options room while a file is on the bed (fe-02, fe-05) ---------- */
@media (max-width: 959px) {
  /* the estimate bar rises in when the first file lands (hidden -> shown only) */
  .lab-bar { transition: transform var(--dur-3) var(--ease-drawer), opacity var(--dur-2) var(--ease-out); }
  @starting-style { .lab-bar:not([hidden]) { transform: translateY(calc(100% + 16px)); opacity: 0; } }
  .sm-lab-page:has(.lab.has-parts) .sm-tabbar { display: none; }
  .lab.has-parts .lab-bar { bottom: calc(8px + var(--safe-b)); }
  .lab.has-parts .lab-rail { padding-bottom: calc(96px + var(--safe-b)); }
  .lab.has-parts .lab-stage { height: 36svh; min-height: 240px; }
  /* one-row estimate bar: price, Details, button */
  .lab-bar { padding: 8px 10px 8px 14px; row-gap: 0; grid-template-areas: "row go" "break break"; }
  .lab-bar__break.is-open { margin-top: 8px; }
  .lab-bar__row { flex-direction: row; align-items: center; gap: 6px; }
  .lab-bar__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; }
  .lab-bar__lbl { font-size: 12px; } /* sentence case, like every other label */
  .lab-bar__tot { font-size: 24px; white-space: nowrap; }
  /* one fixed-height row: "each" moves into Details, the "+₱40" chip floats above the bar instead of wrapping inside it */
  .lab-bar__each { display: none; }
  .lab-bar__break .lab-each { display: block; margin: 8px 0 0; font-size: 13.5px; font-weight: 700; color: #fff; }
  .lab-bar__price { position: relative; }
  .lab-bar__delta { position: absolute; left: -4px; bottom: calc(100% + 16px); background: color-mix(in srgb, var(--laser) 35%, var(--lab-2)); box-shadow: 0 0 0 1px var(--lab-line), 0 8px 20px -6px rgba(0,0,0,.6); }
  .lab-bar__delta.is-down { background: color-mix(in srgb, var(--mint) 35%, var(--lab-2)); }
  .lab-bar__more { min-height: 36px; margin: 0; padding: 0 6px; white-space: nowrap; }
  .lab-bar__go { min-height: 44px; padding: 0 14px; font-size: 14px; }
}
@media (max-width: 959px) and (max-height: 760px) {
  .lab.has-parts .lab-stage { height: 34svh; min-height: 200px; }
}

/* links inside muted Lab copy must look like links */
.sm-lab .sm-muted a, .lab-info a:not(.sm-btn) { color: var(--laser-2); text-decoration: underline; text-underline-offset: 3px; }
