/* Inside Bootstrap 6's custom layer: beats v6 components, never a v6 utility. */
@layer custom {
/* tryon.css - /try-on page. Flow-1 equation feel (operator chips + generating animation + a blurred
   result image) merged with the ORIGINAL EzUpload dropzones (cards 1 & 2 are untouched). App-specific
   styling (not a platform theme); colours resolve through --bs-* tokens so it adapts to light/dark. */

.to-presets { display: flex; justify-content: center; margin-bottom: 1.25rem; }
.to-presets-inner { width: 100%; max-width: 22rem; }

.to-op { flex: none; align-self: center; display: inline-flex; align-items: center; justify-content: center;
    width: 2rem; height: 2rem; border-radius: 50%; font-size: 0.85rem; color: var(--bs-fg-2);
    background: var(--bs-bg-1); border: 1px solid var(--bs-border-color); }

/* Sweep-beam keyframe, shared by the live studio-track and hair/makeup generating animations below. */
@keyframes to-scany { to { top: 104%; } }

/* centred status line (scan mode): fill the box and centre both axes instead of pinning to the bottom */
.to-cap.to-cap--center { top: 0; bottom: 0; display: flex; align-items: center; justify-content: center;
    white-space: normal; font-size: 0.85rem; color: var(--bs-fg-body); }

/* result area (card 3): blurred image / generating / idle - identical box shape to an EzUpload tile */
.to-rbox { position: relative; width: 100%; aspect-ratio: 3 / 4; min-height: 15rem; max-height: 60vh;
    border-radius: var(--bs-radius-5); overflow: hidden; border: 1px solid var(--bs-border-color); background: var(--bs-bg-1);
    display: flex; align-items: center; justify-content: center; text-align: center; }
/* idle/failed click-zone styling is the shared .to-zone class, defined after .mv-card below (it must
   follow both card bases in the cascade). */

/* blur backdrop (the flow-1 fill) - shows the result's own colours behind the letterbox */
/* Darker than the platform's upload tile (0.55): the backdrop's job here is to make the model stand
   out, and at 0.55 a grey studio wall blurred into a grey band the same value as the photo. */
.to-rbox--fill::before { content: ""; position: absolute; inset: 0; background-image: var(--fill);
    background-size: cover; background-position: center; transform: scale(1.2); filter: blur(24px) brightness(0.32) saturate(1.2); }
.to-rbox-open { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: center;
    padding: 0.5rem; border: 0; background: none; cursor: zoom-in; }
.to-rbox img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: var(--bs-radius-4); }
/* Flat design: a crisp primary ring (0-blur "flat shadow"), no soft glow. */
.to-rbox--done { border-color: var(--bs-primary-base); box-shadow: 0 0 0 2px color-mix(in oklch, var(--bs-primary-base) 35%, transparent); }


/* status strip pinned to the bottom of a result box (video creating / created / failed, look under review).
   Rendered for a long time with no base rule at all, so it landed as an unstyled block AFTER the box and
   stole photo height; this is the "flat strip pinned to the bottom" the markup comment always described. */
.to-slot-status { position: absolute; inset-inline-start: 0; inset-inline-end: 0; bottom: 0; z-index: 2;
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    padding: 0.4rem 0.6rem; font-size: 0.8rem; line-height: 1.2;
    background: var(--bs-bg-body); color: var(--bs-fg-body); border-top: 1px solid var(--bs-border-color); }
.to-slot-status--creating { color: var(--bs-primary-base); }
.to-slot-status--created { color: var(--bs-success-base); }
.to-slot-status--error { color: var(--bs-danger-base); }
/* a look under staff review: the result is withheld, so the strip is the whole message - fill the frame */
.to-slot-status--held { top: 0; flex-direction: column; gap: 0.5rem; padding: 1.25rem; border-top: 0;
    font-size: 0.9rem; color: var(--bs-fg-2); }
.to-slot-status--held i { font-size: 1.5rem; }

.to-idle { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.8rem; padding: 1.25rem; }
.to-fail i { color: #e8637c; }
/* The price of the action. It was 0.72rem in the secondary ink, which is the treatment this theme
   gives throwaway metadata - and what a look costs is the one number a user checks before pressing
   anything. Body size, body ink. */
/* Body font: this is the price and the user's balance, plain facts, and it was the only line on the
   card set in the monospace face - which made it read like a debug readout. */
.to-credit { font-size: 0.8125rem; color: var(--bs-fg-body); }

.to-cap { position: absolute; bottom: 0.9rem; inset-inline-start: 0; inset-inline-end: 0; z-index: 2; text-align: center;
    font-family: var(--bs-font-mono); font-size: 0.76rem; color: var(--bs-fg-2);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 1.5rem; }

/* ---- history: "Your looks" feed of kept looks (person + garment = result), newest first ----
   Same equation shape as the form, one row per saved look. Keep flies the trio down into a new row
   here (tryon.js FLIP flight), which then pops with a sparkle burst. */
/* history is grouped by the day each look was kept: a small sticky-free date heading over each day's
   rows, with generous separation between days. Flat - a hairline rule carries the divide, no panel. */
.to-daygroup + .to-daygroup { margin-top: 3.25rem; }
.to-dayhead { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase;
    color: var(--bs-fg-2); margin: 0 0 1.5rem; padding-bottom: 0.6rem;
    border-bottom: 1px solid var(--bs-border-color); }
.to-rows { display: flex; flex-direction: column; gap: 2.75rem; }
/* the outfit-notes button carries a small dot when the look has any recorded notes (like an unread mark) */
.to-note-dot { position: absolute; top: -1px; inset-inline-end: -1px; width: 0.5rem; height: 0.5rem; border-radius: 50%;
    background: var(--bs-primary-base); border: 1px solid var(--bs-bg-body); pointer-events: none; }
/* Flat: no row card (no border/background/panel) - the whitespace between rows and the action-bar
   divider separate each look; the photos carry the row. */
.to-row { position: relative; display: grid; grid-template-columns: 1fr auto 1fr auto 1.2fr; gap: 0.7rem;
    align-items: center; justify-items: center; }
.to-row .to-op { width: 1.65rem; height: 1.65rem; font-size: 0.72rem; align-self: center; }
.to-slot { position: relative; width: 100%; aspect-ratio: 3 / 4; max-height: 42vh; border-radius: var(--bs-radius-5);
    overflow: hidden; border: 1px solid var(--bs-border-color); background: var(--bs-bg-1);
    display: flex; align-items: center; justify-content: center; }
.to-slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; z-index: 1; }
/* Blurred backdrop fills the letterbox with a darkened blow-up of the photo (matches the form cards).
   Driven by --fill:url(...); when unset, var(--fill) is invalid so no backdrop shows. */
.to-slot::before { content: ""; position: absolute; inset: 0; z-index: 0;
    background-image: var(--fill); background-size: cover; background-position: center;
    transform: scale(1.2); filter: blur(24px) brightness(0.55) saturate(1.25); }
.to-slot--result { border-color: var(--bs-primary-base);
    box-shadow: 0 0 0 2px color-mix(in oklch, var(--bs-primary-base) 35%, transparent); }
/* cards: bundled example photos under an EMPTY upload card - a one-tap way to fill the card without
   hunting for an image. Flat (no depth shadows); the brand colour is the only hover affordance. */
/* Shared studio "try one of ours" strip (SampleCarousel, used on outfits/makeup/hair). A horizontal,
   scroll-snapping row of example thumbnails with chevron arrows (shown only when the row overflows,
   disabled at each end) and an optional Women | Men filter toggle. Namespaced .ss-* and loaded globally
   with tryon.css, so it works on the styling studios too. Arrow/scroll logic is in sampleStrip.js. */
.ss { margin-top: 0.75rem; }
.ss-head { display: flex; align-items: center; justify-content: center; gap: 0.6rem;
    margin-bottom: 0.4rem; flex-wrap: wrap; }
.ss-label { font-size: 0.78rem; color: var(--bs-fg-2); }
/* (The Women | Men filter was removed - see SampleCarousel.razor. The photos communicate who an
   example suits faster than a control does, and the toggle cost a whole row of a card where vertical
   space is scarce; that space went to bigger thumbnails instead.) */

.ss-strip { position: relative; display: flex; align-items: center; justify-content: center; }
/* overscroll-behavior-x: contain - scrolling the strip past its end must stop there. Without it the
   leftover scroll chained out to the studio's card track and moved the whole card off screen. */
.ss-track { display: flex; gap: 0.4rem; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity;
    scroll-behavior: smooth; scrollbar-width: none; padding: 2px; }
.ss-track::-webkit-scrollbar { display: none; }
/* An EzButton (the platform has one button component; a tile is a button whose content is a picture).
   Bootstrap's .btn paints hover, active and disabled at a specificity this single-class rule cannot
   reach, so the tile's fill, border and radius are handed to it through Bootstrap's OWN custom
   properties rather than fought for. display:block keeps the fitted image laying out exactly as it did
   inside the old inline-block <button>, instead of becoming a flex item of .btn's inline-flex box. */
.ss-thumb { position: relative; flex: 0 0 auto; display: block; width: 3.25rem; aspect-ratio: 0.72; padding: 0; overflow: hidden;
    scroll-snap-align: start; border: 1px solid var(--bs-border-color); border-radius: var(--bs-radius-4, 10px);
    background: var(--bs-bg-1); cursor: pointer; transition: border-color 0.15s ease;
    --bs-btn-padding-x: 0; --bs-btn-padding-y: 0;
    --bs-btn-border-radius: var(--bs-radius-4, 10px);
    --bs-btn-bg: var(--bs-bg-1); --bs-btn-hover-bg: var(--bs-bg-1);
    --bs-btn-active-bg: var(--bs-bg-1); --bs-btn-disabled-bg: var(--bs-bg-1);
    --bs-btn-border-color: var(--bs-border-color); --bs-btn-hover-border-color: var(--bs-primary-base);
    --bs-btn-active-border-color: var(--bs-primary-base); --bs-btn-disabled-border-color: var(--bs-border-color); }
/* Same treatment as the big photo frames: the whole image is fitted (never cropped), and a blurred,
   stretched copy of it fills whatever is left over - so a portrait and a square sample both read as
   complete pictures instead of tight centre-crops. --ss-fill is set per thumb by SampleCarousel. */
.ss-thumb::before { content: ""; position: absolute; inset: -15%; z-index: 0;
    background-image: var(--ss-fill); background-size: cover; background-position: center;
    filter: blur(6px) saturate(1.1); opacity: 0.55; }
.ss-thumb img { position: relative; z-index: 1; display: block; width: 100%; height: 100%; object-fit: contain; }
.ss-thumb:hover:not(:disabled) { border-color: var(--bs-primary-base); }
.ss-thumb:disabled { opacity: 0.45; cursor: default; }
.ss-thumb-busy { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    background: color-mix(in oklch, var(--bs-bg-body) 70%, transparent); }

/* Arrows sit outside the track; hidden unless the row overflows, dimmed + inert at each end. */
.ss-arrow { display: none; flex: 0 0 auto; width: 1.6rem; height: 1.6rem; align-items: center; justify-content: center;
    padding: 0; border: 1px solid var(--bs-border-color); border-radius: var(--bs-radius-pill); background: var(--bs-bg-body);
    color: var(--bs-fg-body); cursor: pointer; font-size: 0.7rem;
    transition: opacity 0.15s ease, border-color 0.15s ease, color 0.15s ease; }
.ss--overflow .ss-arrow { display: inline-flex; }
.ss-arrow:hover:not(.ss-arrow--disabled) { border-color: var(--bs-primary-base); color: var(--bs-primary-base); }
.ss-arrow--disabled { opacity: 0.3; cursor: default; pointer-events: none; }
.ss-arrow-prev { margin-inline-end: 0.25rem; }
.ss-arrow-next { margin-inline-start: 0.25rem; }

/* Admin sample-image list: a small portrait thumbnail beside each row. */
.ss-adminthumb { display: inline-flex; flex: 0 0 auto; width: 2.6rem; aspect-ratio: 0.72; overflow: hidden;
    border-radius: var(--bs-radius-4); border: 1px solid var(--bs-border-color); background: var(--bs-bg-1); }
.ss-adminthumb img { width: 100%; height: 100%; object-fit: contain; }

/* history: ONE simple tip (EzAlert) at the top of the feed, pointing at the per-row modelling buttons.
   No CTA of its own - the play icon under each look is the action. The wrapper owns the spacing
   (the alert's built-in bottom margin is zeroed so the gap is exact). */
/* (.to-histtip, the standing "bring your looks to life" banner above the feed, went with the banner
   itself, and so did the just-kept "Create modelling video" bubble that replaced it.) */

/* modelling-videos manager: a responsive grid of portrait tiles. Each video tile is [pose name on top]
   / [thumbnail] / [share + delete]. With no videos the grid holds only the create card (the empty
   state); otherwise the create BAR (.mv-createbar) sits above it. The first frame shows via
   preload=metadata + a #t seek; pressing play sends the video fullscreen (tryon.js). */
.mv-grid { display: flex; flex-wrap: wrap; gap: 1.1rem;
    align-items: flex-start; justify-content: center; padding-bottom: 1.5rem; }

/* The create bar: the same place at every size, above the grid. Styles (when the admin configured more
   than one) on the left, the button and its cost on the right; below Bootstrap md they stack, the
   button full width under the styles. A hairline under it separates "make one" from "what you have". */
.mv-createbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.5rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--bs-border-color);
}
.mv-createbar-styles { flex: 1 1 18rem; min-width: 0; }
/* An empty picker (one style renders nothing) must not leave a gap before the button. */
.mv-createbar-styles:empty { display: none; }
.mv-createbar-go { display: flex; align-items: center; gap: 0.75rem; margin-inline-start: auto; }
/* Bootstrap < md */
@media (width < 768px) {
    .mv-createbar-go { flex: 1 1 100%; margin-inline-start: 0; }
    .mv-createbar-go .btn { flex: 1 1 auto; }
}
.mv-tile { display: flex; flex-direction: column; gap: 0.4rem; width: 12rem; min-width: 0; }
.mv-pose { font-size: 0.8rem; color: var(--bs-fg-2); text-align: center;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mv-thumb { width: 100%; aspect-ratio: 3 / 4; border-radius: var(--bs-radius-5); overflow: hidden;
    border: 1px solid var(--bs-border-color); background: var(--bs-bg-1); }
/* Contain, like every photo: the whole frame, letterboxed on black, never cropped (owner, 2026-09-30).
   A video cannot carry the photos' blurred self-backdrop without decoding itself twice, so black it is. */
.mv-thumb video { width: 100%; height: 100%; object-fit: contain; display: block; background: #000; }
.mv-video:fullscreen { object-fit: contain; background: #000; }
.mv-video:-webkit-full-screen { object-fit: contain; background: #000; }
.mv-actions { display: flex; align-items: center; justify-content: center; gap: 0.4rem; }
/* The per-video "Include in shares" switch: centred under its video, one size down. */
/* Bootstrap hangs a switch in the wrapper's left padding with a negative margin; laid out as a flex row
   instead, so the gap - not a hand-tuned offset - is what separates the switch from its words. */
.mv-share { display: flex; align-items: center; justify-content: center; gap: 0.5rem; padding-inline-start: 0;
    font-size: 0.875rem; }
.mv-share .form-check-input { flex-shrink: 0; margin: 0; }
/* create card: the SAME fixed 3/4 box as a video thumbnail, but styled like the card-3 result card -
   it hosts .to-idle (pose picker + Create + credit), .to-cap (creating) or .to-fail (failed),
   so every state matches card 3 and lines up with the video tiles. */
.mv-card { position: relative; width: 100%; aspect-ratio: 3 / 4; border-radius: var(--bs-radius-5); overflow: hidden;
    border: 1px solid var(--bs-border-color); background: var(--bs-bg-1);
    display: flex; align-items: center; justify-content: center; text-align: center; }
.mv-card .to-idle { padding: 0.9rem; gap: 0.6rem; }
/* The sweep beam over a modelling-video card while it generates. Only the reduced-motion switch-off
   for it was ever declared, so the card showed the caption and the spinner with nothing sweeping
   behind them - the same three-part signal every other generating surface gives. Same beam as the
   studio track's .st-photo::after; .mv-card already clips it and is the positioning context. */
.mv-card--scan::after { content: ""; position: absolute; inset-inline-start: 0; inset-inline-end: 0; top: -20%; height: 16%;
    z-index: 4; pointer-events: none;
    background: linear-gradient(to bottom, transparent, color-mix(in oklch, var(--bs-primary-base) 35%, transparent), transparent);
    border-bottom: 2px solid var(--bs-primary-base); animation: to-scany 1.6s linear infinite; }

/* full-card click zone (card 3's idle + failed states, the modelling create card's failed state):
   looks and acts like an empty EzUpload dropzone - dashed border, brand highlight on hover, dimmed
   + neutral while disabled. Defined AFTER .to-rbox/.mv-card so it wins their solid 1px border.
   A zone hosting the style picker cannot BE a button (below), so it carries .is-off instead of
   :disabled - every zone rule below has to answer to both spellings. */
.to-zone { padding: 0; cursor: pointer; color: inherit; border: 2px dashed var(--bs-border-color);
    transition: border-color 0.15s ease-in-out, background-color 0.15s ease-in-out; }
.to-zone:hover:not(:disabled):not(.is-off) { border-color: var(--bs-primary-base); }
/* hovering ANYWHERE on the zone puts the visual action chip into its normal button hover state (the
   chip is a span, so its own :hover never fires for the rest of the card) */
.to-zone:hover:not(:disabled):not(.is-off) .btn-primary { color: var(--bs-btn-hover-color);
    background-color: var(--bs-btn-hover-bg); border-color: var(--bs-btn-hover-border-color); }
.to-zone:disabled,
.to-zone.is-off { cursor: default; opacity: 0.65; }

/* ---- a click-zone card that HOSTS a control (the style picker) --------------------------------
   Once a card contains a real control it cannot be a <button> - one cannot nest in another - so the
   whole-card click zone becomes a transparent button laid underneath, and the content on top is
   click-through. Only the picker takes its own clicks back. Used by card 3's idle result box and by
   the create card in the modelling-videos manager. */
.to-hit { position: absolute; inset: 0; z-index: 0; padding: 0; border: 0; background: transparent;
    cursor: pointer; }
.to-hit:disabled { cursor: default; }
.to-idle--hosted { width: 100%; pointer-events: none; }
.to-idle--hosted .st-wf { pointer-events: auto; }

/* ---- workflow picker (StylePicker.razor) -------------------------------------------------------
   Always-visible rows on the card, not a pill that opens a menu: the facts that decide the choice
   were behind a click, so the user chose before seeing them. Design 08t from the step 3 mockups.

   NO per-fact glyphs, on purpose. VCR renders on pure black, and a 0.65rem glyph there has almost no
   ink and no ground of its own - it reads as lint. The brand rule down the fact block does the
   grouping the icons were meant to do, at one mark per row rather than three. */
.st-wf { display: flex; flex-direction: column; gap: 0.35rem; width: 100%; max-width: 22rem;
    text-align: start; }

.st-wf-row { display: grid; grid-template-columns: auto 1fr; gap: 0.15rem 0.5rem;
    align-items: start; width: 100%; margin: 0; padding: 0.45rem 0.6rem;
    background: var(--bs-bg-body); border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-5); cursor: pointer;
    transition: border-color 0.15s, background 0.15s; }
.st-wf-row:hover { border-color: var(--bs-primary-base); }
.st-wf-row.is-on { border-color: var(--bs-primary-base); background: color-mix(in oklch, var(--bs-primary-base) 8%, transparent); }
.st-wf-row:has(:disabled) { cursor: default; opacity: 0.55; }
.st-wf-row:has(:focus-visible) { outline: 2px solid var(--bs-primary-base); outline-offset: 2px; }

/* The real radio carries keyboard and assistive-tech behaviour; the ring is what is actually seen. */
.st-wf-radio { position: absolute; opacity: 0; pointer-events: none; }
.st-wf-ring { grid-row: 1; width: 0.85rem; height: 0.85rem; margin-top: 0.15rem;
    border: 2px solid var(--bs-border-color); border-radius: 50%; background: var(--bs-bg-body);
    transition: border-color 0.15s, box-shadow 0.15s; }
.st-wf-row.is-on .st-wf-ring { border-color: var(--bs-primary-base);
    box-shadow: inset 0 0 0 0.18rem var(--bs-primary-base); }

/* Wraps rather than clipping: the row is 156px wide inside a phone-width card, so an ellipsis cut most
   workflow names off at the point where they start to differ from each other. */
.st-wf-name { grid-row: 1; font-size: 0.82rem; line-height: 1.35; color: var(--bs-fg-body);
    min-width: 0; overflow-wrap: anywhere; }
.st-wf-row.is-on .st-wf-name { color: var(--bs-primary-base); }

/* 08t: one rule instead of three glyphs. Sits in the name's column so it lines up under the label
   rather than under the radio. */
.st-wf-facts { grid-column: 2; display: flex; flex-direction: column; gap: 0.1rem;
    padding-inline-start: 0.5rem; border-inline-start: 2px solid color-mix(in oklch, var(--bs-primary-base) 55%, transparent);
    font-size: 0.7rem; line-height: 1.35; color: var(--bs-fg-2); }
/* Same reason as the name above: a fact that does not fit wraps onto a second line rather than being
   cut short, which is the only failure mode that loses information. */
.st-wf-fact { min-width: 0; overflow-wrap: anywhere; }

/* A single workflow is not a choice, so it is not drawn as a selectable row: no box, no ring, no
   hover. Just the name over one line of facts, centred like the rest of the idle card. */
.st-wf--single .st-wf-row { grid-template-columns: 1fr; justify-items: center; text-align: center;
    cursor: default; border-color: transparent; background: transparent; padding-block: 0; }
.st-wf--single .st-wf-row:hover { border-color: transparent; }
.st-wf--single .st-wf-facts { grid-column: 1; flex-direction: row; flex-wrap: wrap; justify-content: center;
    gap: 0.1rem 0.4rem; padding-inline-start: 0; border-inline-start: 0; }
/* The dot trails the fact before it, so when the line wraps (a large text size on a phone) it ends the first
   line rather than starting the second one. */
.st-wf--single .st-wf-fact:not(:last-child)::after { content: "\00B7"; margin-inline-start: 0.4rem; }
.st-wf--single.is-off { opacity: 0.55; }

/* Facts stay STACKED at every count - one line per fact is the whole point of 08t, and running them
   inline at three or four options would have meant the design changed shape exactly when there was
   most to compare. Height is handled by scrolling instead: four stacked options exceed the card, so
   the list scrolls rather than the layout degrading.

   The cap has to follow --st-cap, the measured photo frame the picker sits inside. A fixed 17rem is
   taller than the frame on a short phone, so the picker pushed the Generate chip and the price out of
   the card entirely - the two things the choice is made against. Leave room for those (about 7rem of
   chip, caption and price) and never go below a readable two rows. */
.st-wf { max-height: min(17rem, max(8rem, calc(var(--st-cap, 24rem) - 7rem))); overflow-y: auto; }

/* Room for the scrollbar so it never sits on top of a row border, and a little inset so a scrolled
   row does not touch the card edge. */
.st-wf { scrollbar-width: thin; padding-inline-end: 0.15rem; }

/* Bootstrap < md: the equation stacks to one card per row - each card fills the page width (capped
   so a landscape phone doesn't get a giant portrait card) and centres, with the operator chips
   rotated to read downward. The history rows stack identically: one image per row, same width cap,
   centred, with each image immediately followed by its own action bar and the +/-> chips kept
   between the image groups so each look still reads as photo + outfit = result. */
@media (width < 768px) {
    .to-op i { transform: rotate(90deg); }
    /* .to-row is a 2-row grid on desktop (images on row 1, per-image action bars on row 2). At phone
       width switch it to a single-column flex stack and use `order` to interleave the fixed-order
       children into image -> its bar -> operator groups. Child order in the DOM is stable:
       1 person img, 2 (+) chip, 3 outfit img, 4 (->) chip, 5 result img, 6 person bar (--a),
       7 outfit bar (--b), 8 result bar. The delete-confirmation modal reuses .to-row with only the
       first five (no bars), which the same rules stack correctly. */
    .to-row { display: flex; flex-direction: column; align-items: center; }
    .to-row .to-slot { width: 100%; max-width: 26rem; }
    .to-row > :nth-child(1) { order: 1; }  /* person image */
    .to-row > :nth-child(6) { order: 2; }  /* person action bar (--a) */
    .to-row > :nth-child(2) { order: 3; }  /* + chip */
    .to-row > :nth-child(3) { order: 4; }  /* outfit image */
    .to-row > :nth-child(7) { order: 5; }  /* outfit action bar (--b) */
    .to-row > :nth-child(4) { order: 6; }  /* -> chip */
    .to-row > :nth-child(5) { order: 7; }  /* result image */
    .to-row > :nth-child(8) { order: 8; }  /* result action bar */
    /* .mv-grid descendant selector (not bare .mv-tile): the Styling module ships its own
       styling.css that also defines a plain `.mv-tile { width: 12rem }` and loads after this
       file, so a bare `.mv-tile` override here loses the cross-sheet tie. The extra class wins
       it (and gives the Styling modelling modal the same full-width tiles on phones). */
    .mv-grid .mv-tile { width: 100%; max-width: 26rem; }
}
@media (prefers-reduced-motion: reduce) {
    .mv-card--scan::after { display: none; }
    .to-slot-status { animation: none; }
}

/* =====================================================================================
   KEEP CELEBRATION (star shower) - the effect that erupts on a look as it lands in the
   feed; the trio-flies-down flight itself is separate and always runs. Rendered by the
   shared TryOnKeepFx component. Particles carry --dx/--dy (px), --i (index). Overlay
   fills the row; pointer-events off.
   ===================================================================================== */
/* A flight TARGET image, hidden until the ghost lands on it. visibility, not display: the element must
   still lay out, because the flight measures the slot it is going to land in. Only the image is
   hidden - the slot's blurred backdrop stays on, so the row never reads as a gap. */
.to-await { visibility: hidden; }

/* A size container, so each star's travel (--dx/--dy) is a share of the frame it plays on (cqw) rather
   than fixed pixels: fixed travel was tuned on a desktop card and crossed a whole phone card almost at
   once, so the stars left the photo before they could be seen. The overlay is absolutely positioned
   and sized by its frame, so size containment costs nothing here. */
.to-keepfx { position: absolute; inset: 0; z-index: 30; pointer-events: none; container-type: size; }
.kf-p { position: absolute; width: 9px; height: 9px; border-radius: 50%; }
/* shooting stars streak with trails */
.to-keepfx--star-shower .kf-p { width: 4px; height: 4px; border-radius: 50%; opacity: 0; background: #fff;
    box-shadow: 0 0 6px 2px rgba(255, 255, 255, 0.9); animation: kf-star 1s ease-in forwards; animation-delay: calc(var(--i) * 0.06s); }
.to-keepfx--star-shower .kf-p::after { content: ""; position: absolute; inset-inline-start: 2px; top: 1px; width: 40px; height: 2px;
    transform-origin: left center; transform: rotate(150deg); background: linear-gradient(to right, #fff, transparent); }
@keyframes kf-star { 0% { transform: translate(0, 0); opacity: 0; } 15% { opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)); opacity: 0; } }
/* The fourteen stars. Their start point, travel and delay used to be drawn at random in C# and written
   onto each span as a style attribute - the one thing this codebase never does. The set is fixed here
   instead: fourteen authored variants read exactly like fourteen random ones (nobody counts a shower
   twice), and the component is left with nothing to emit but a class. */
/* Travel in cqw on BOTH axes (not cqh for --dy), so every streak keeps the 150deg angle its trail is
   drawn at whatever the frame's shape. The values are the old desktop pixels over a 26rem card. */
.to-keepfx--star-shower .kf-p--1  { inset-inline-start: 44%; top: -6%; --dx: -57cqw; --dy: 37cqw; --i: 0; }
.to-keepfx--star-shower .kf-p--2  { inset-inline-start: 58%; top: 12%; --dx: -68cqw; --dy: 47cqw; --i: 4; }
.to-keepfx--star-shower .kf-p--3  { inset-inline-start: 71%; top: -2%; --dx: -51cqw; --dy: 32cqw; --i: 1; }
.to-keepfx--star-shower .kf-p--4  { inset-inline-start: 86%; top: 20%; --dx: -76cqw; --dy: 54cqw; --i: 7; }
.to-keepfx--star-shower .kf-p--5  { inset-inline-start: 52%; top: 27%; --dx: -60cqw; --dy: 42cqw; --i: 2; }
.to-keepfx--star-shower .kf-p--6  { inset-inline-start: 95%; top:  5%; --dx: -71cqw; --dy: 35cqw; --i: 9; }
.to-keepfx--star-shower .kf-p--7  { inset-inline-start: 63%; top: -9%; --dx: -54cqw; --dy: 50cqw; --i: 5; }
.to-keepfx--star-shower .kf-p--8  { inset-inline-start: 78%; top: 31%; --dx: -80cqw; --dy: 39cqw; --i: 3; }
.to-keepfx--star-shower .kf-p--9  { inset-inline-start: 41%; top: 16%; --dx: -63cqw; --dy: 56cqw; --i: 8; }
.to-keepfx--star-shower .kf-p--10 { inset-inline-start: 90%; top: -4%; --dx: -49cqw; --dy: 45cqw; --i: 6; }
.to-keepfx--star-shower .kf-p--11 { inset-inline-start: 67%; top: 24%; --dx: -74cqw; --dy: 30cqw; --i: 0; }
.to-keepfx--star-shower .kf-p--12 { inset-inline-start: 49%; top:  8%; --dx: -66cqw; --dy: 52cqw; --i: 9; }
.to-keepfx--star-shower .kf-p--13 { inset-inline-start: 82%; top: 34%; --dx: -56cqw; --dy: 38cqw; --i: 2; }
.to-keepfx--star-shower .kf-p--14 { inset-inline-start: 74%; top: 10%; --dx: -70cqw; --dy: 48cqw; --i: 6; }


/* honour reduced-motion: no keep celebration (the caption and the flight still read fine) */
@media (prefers-reduced-motion: reduce) {
    .to-keepfx *, .to-keepfx *::before, .to-keepfx *::after {
        animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
    .to-keepfx { display: none; }
}

/* ===== public share page (/s/{token}) - .sp-* ==================================================
   Anonymous, public-facing gallery / poll page rendered inside PublicShareLayout. One normalised
   structure for every state: hero header (.sp-head), framed look tiles (.sp-tile, same blurred
   self-fill letterbox as .to-rbox--fill), poll option cards, ranked results, and the about-us
   pitch banner (.sp-promo). Flat design: crisp primary rings, no depth shadows. */

.sp-head { max-width: 36rem; margin: 0 auto 2rem; }
.sp-eyebrow { display: inline-flex; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem;
    padding: 0.25rem 0.75rem; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.12em;
    text-transform: uppercase; color: var(--bs-primary-base); border-radius: var(--bs-radius-pill);
    background: color-mix(in oklch, var(--bs-primary-base) 10%, transparent); border: 1px solid color-mix(in oklch, var(--bs-primary-base) 35%, transparent); }
.sp-title { margin-bottom: 0.25rem; }
/* The caption is whatever the sharer typed, and people paste URLs into it. An unbreakable 60-character
   token has no wrap opportunity, so at 320px it pushed the whole public page sideways. */
.sp-lede { color: var(--bs-fg-2); margin: 0; overflow-wrap: anywhere; }
.sp-alert { max-width: 36rem; margin-inline-start: auto; margin-inline-end: auto; }

/* look tile: fixed portrait frame; the image is contained (never cropped) over a blurred copy of
   itself so odd aspect ratios still fill the frame edge-to-edge - the established try-on look. */
.sp-tile { position: relative; display: block; width: 100%; aspect-ratio: 3 / 4; margin: 0;
    overflow: hidden; border-radius: var(--bs-radius-5); border: 1px solid var(--bs-border-color);
    background: var(--bs-bg-1); }
.sp-tile::before { content: ""; position: absolute; inset: 0; background-image: var(--fill);
    background-size: cover; background-position: center; transform: scale(1.2);
    filter: blur(24px) brightness(0.55) saturate(1.25); }
.sp-tile img { position: absolute; inset: 0; margin: auto; max-width: 100%; max-height: 100%;
    width: auto; height: auto; object-fit: contain; }

/* One card per look (Deck in Pages/S/Public.razor): the framed 3:4 tile, with the look's photo as the
   first slide and each shared video as another, side by side in a native scroll-snap track - so a
   swipe works with no script, and a look with videos takes exactly the room of one without. The tile's
   blurred self-fill sits behind every slide, so a video letterboxes into the same backdrop. */
/* The CARD: one bordered box around the look and everything that belongs to it - its photo / video
   strip, its vote tally, its "Pick this" - so nobody has to guess which look a row of buttons or a
   percentage refers to. The photo frame inside keeps its own rounded corners. */
.sp-card { padding: 0.5rem; background: var(--bs-bg-body); border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-9); transition: border-color 0.15s ease, box-shadow 0.15s ease; }
.sp-card .sp-deck-frame { border-color: transparent; }
.sp-card .sp-result-meta { padding: 0 0.25rem 0.25rem; }
.sp-deck-track { position: absolute; inset: 0; z-index: 1; display: flex; overflow-x: auto;
    overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
.sp-deck-track::-webkit-scrollbar { display: none; }
.sp-deck-track:focus-visible { outline: 2px solid var(--bs-primary-base); outline-offset: -2px; }
.sp-slide { position: relative; flex: 0 0 100%; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.sp-slide-video { display: block; width: 100%; height: 100%; object-fit: contain; background: transparent; }
.sp-deck-frame .sp-flag { z-index: 2; }
/* Arrows for a mouse: a finger swipes, so they only appear where there is hover. */
.sp-deck-nav { position: absolute; top: 50%; z-index: 2; display: none; align-items: center; justify-content: center;
    width: 2.25rem; height: 2.25rem; border: 0; border-radius: 50%; color: #fff; background: rgba(0, 0, 0, 0.45);
    transform: translateY(-50%); transition: opacity 0.2s ease; }
.sp-deck-nav--prev { inset-inline-start: 0.5rem; }
.sp-deck-nav--next { inset-inline-end: 0.5rem; }
.sp-deck-nav:disabled { opacity: 0; pointer-events: none; }
@media (hover: hover) {
    .sp-deck-nav { display: inline-flex; opacity: 0; }
    .sp-deck:hover .sp-deck-nav:not(:disabled),
    .sp-deck-nav:focus-visible { opacity: 1; }
}
/* The strip under the card is the explanation: a photo icon, then a play icon per video. The lit one is
   the slide on screen; tapping one goes there. A photo-only card in a share that has videos reserves the
   same height (--empty), so every card and what sits under it stays level. */
.sp-deck-strip { display: flex; justify-content: center; gap: 0.4rem; min-height: 1.75rem; margin-top: 0.5rem; }
.sp-deck-dot { display: inline-flex; align-items: center; justify-content: center; width: 1.75rem; height: 1.75rem;
    padding: 0; font-size: 0.7rem; color: var(--bs-fg-2); background: transparent;
    border: 1px solid var(--bs-border-color); border-radius: var(--bs-radius-pill);
    transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease; }
.sp-deck-dot:hover { color: var(--bs-primary-base); border-color: var(--bs-primary-base); }
/* The theme's ink on the brand fill, so the active dot stays readable whichever theme is on. */
.sp-deck-dot.is-active { color: var(--bs-primary-contrast); background: var(--bs-primary-base); border-color: var(--bs-primary-base); }

/* poll option card: the PHOTO slide is a submit button (name="option" value="{id}"), so one tap on the
   look casts the vote, and "Pick this" under the card is a second submit for the same option. The video
   slides sit outside any button. .is-choosing (on the card) marks the tapped option while
   poll-captcha.js solves the challenge. */
.sp-option { position: absolute; inset: 0; display: block; width: 100%; height: 100%; padding: 0; border: 0;
    background: none; color: inherit; font: inherit; cursor: pointer; }
.sp-option-card:hover { border-color: var(--bs-primary-base); }
.sp-option-pick { display: flex; align-items: center; justify-content: center; gap: 0.5rem; width: 100%;
    margin-top: 0.5rem; padding: 0.25rem 0.5rem; font: inherit; font-size: 0.85rem; font-weight: 500; cursor: pointer;
    color: var(--bs-fg-2); background: none; border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-pill);
    transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease; }
.sp-option-pick:hover { color: var(--bs-primary-base); border-color: var(--bs-primary-base); }
.sp-option-card.is-choosing { border-color: var(--bs-primary-base);
    box-shadow: 0 0 0 2px color-mix(in oklch, var(--bs-primary-base) 35%, transparent); }
.sp-option-card.is-choosing .sp-option-pick, .sp-option-pick:active { color: var(--bs-primary-contrast);
    background: var(--bs-primary-base); border-color: var(--bs-primary-base); }
.sp-option:focus-visible { outline: 2px solid var(--bs-primary-base); outline-offset: -2px; }
.sp-option-pick:focus-visible { outline: 2px solid var(--bs-primary-base); outline-offset: 2px; }

/* poll results: ranked tiles with a share-of-votes bar; the leader gets the flat primary ring */
/* The leader's whole card is ringed, not just its photo: the tally under it belongs to it too. */
.sp-result--winner { border-color: var(--bs-primary-base);
    box-shadow: 0 0 0 2px color-mix(in oklch, var(--bs-primary-base) 35%, transparent); }
.sp-result-meta { margin-top: 0.5rem; }
.sp-result-bar { height: 0.5rem; }
.sp-result-votes { display: flex; align-items: baseline; justify-content: center; gap: 0.5rem; margin-top: 0.25rem;
    font-size: 0.85rem; color: var(--bs-fg-2); }
.sp-result-pct { font-weight: 600; color: var(--bs-fg-body); }
.sp-flag { position: absolute; top: 0.5rem; z-index: 1; display: inline-flex; align-items: center;
    gap: 0.5rem; padding: 0.25rem 0.5rem; font-size: 0.72rem; font-weight: 600; border-radius: var(--bs-radius-pill);
    background: var(--bs-bg-body); border: 1px solid var(--bs-border-color); color: var(--bs-fg-body); }
.sp-flag--winner { inset-inline-start: 0.5rem; border-color: var(--bs-primary-base); color: var(--bs-primary-base); }
.sp-flag--mine { inset-inline-end: 0.5rem; }

/* unavailable / expired link */
.sp-empty { max-width: 26rem; margin: 2rem auto 0; }
.sp-empty-icon { display: flex; align-items: center; justify-content: center; width: 4rem; height: 4rem;
    margin: 0 auto 1rem; font-size: 1.5rem; border-radius: 50%; color: var(--bs-fg-2);
    background: var(--bs-bg-1); border: 1px solid var(--bs-border-color); }

/* about-us pitch banner: flat primary-tinted panel with the CTA back to the app */
.sp-promo { max-width: 36rem; margin: 3rem auto 0; padding: 2rem 1.5rem;
    border: 1px solid color-mix(in oklch, var(--bs-primary-base) 35%, transparent); border-radius: var(--bs-radius-9);
    background: color-mix(in oklch, var(--bs-primary-base) 6%, transparent); }
.sp-promo-icon { display: flex; align-items: center; justify-content: center; width: 3rem; height: 3rem;
    margin: 0 auto 1rem; font-size: 1.25rem; border-radius: 50%; background: var(--bs-primary-base); color: var(--bs-primary-contrast); }
.sp-promo-title { margin-bottom: 0.5rem; }
.sp-promo-pitch { color: var(--bs-fg-2); margin-bottom: 1.5rem; }
.sp-promo-cta i { margin-inline-end: 0.25rem; }
/* The free-start offer, on a quiet line under the CTA. Rendered only when the admin's promo copy
   has not placed the {{FreeOffer}} token itself, so the offer is stated exactly once. */
.sp-promo-offer { display: flex; align-items: center; justify-content: center; gap: 0.375rem;
    margin: 0.75rem 0 0; font-size: 0.875rem; color: var(--bs-fg-2); }
.sp-promo-offer i { color: var(--bs-primary-base); }

/* ---- studio mobile-economy pass (2026-07) ---------------------------------------------------- */
/* The one guidance line, under the card-1 heading where it is actionable. */
.to-cardhint { color: var(--bs-fg-2); font-size: 0.8125rem; text-align: center; margin: 0 0 0.5rem; }
/* (The mobile sticky generate bar - .to-sticky / -btn / -cost - went with the equation layout it was
   written for. The studio card track scrolls card 3 into view itself, so nothing floats over the tab
   bar any more and no markup references those classes. Do not re-add them.) */

/* ============================================================================================
   Studio card track (2026-07) - the responsive three-card studio, shared VERBATIM by all three
   studios (/outfits, /makeup, /hair) and by every kept look on /looks.
   ONE track, three modes:
     below md   focus - one full-width card at a time, swipe or arrows
     md to lg   peek  - the current card centred, neighbours peeking and dimmed
     lg and up  row   - all three cards side by side, no scrolling, no arrows
   The photo cap (--st-cap) is MEASURED AT RUNTIME by studio.js (real chrome above the track, the
   card's own header/bar, the bottom tab bar) - the rem values here are only the no-JS fallback,
   because a fixed budget under-measures tall chrome (MAUI WebView header, safe-area insets). The
   card WIDTH derives from the cap, so on short screens the whole card shrinks rather than clipping.
   The 3/4 photo frame is the common phone-camera aspect ratio, which is why every studio uses it.
   ============================================================================================ */

.st-studio {
    --st-cap: max(18.75rem, calc(100svh - 22.5rem));
    /* What a card reserves under its photo, budgeted into the photo cap by studio.js. 0: every action
       now sits ON the photo (.st-media-actions top right, .st-decide along the bottom), so the three
       photos are the same height in every state. Kept as a token rather than deleted so the JS budget
       and this file cannot disagree if anything is ever put back under the photo. */
    --st-barh: 0px;
    /* Radius scale, largest on the outside: card > inset elements > controls (the icon buttons bring
       their own 8px). Inner values come from the platform --bs-radius-4 token rather than being invented
       per element. Anything OPAQUE that fills the photo area edge to edge gets no radius at all - the
       card already clips it, and rounding it again just notches card background into the photo. */
    --st-radius-card: var(--bs-radius-9);
    --st-radius-inner: var(--bs-radius-4, 10px);
    --st-avail: calc(100vw - 2.5rem);
    /* A ceiling on the card, because every other term grows with the WINDOW: on a tall ultra-wide
       screen the cap-derived width ran past any size a portrait photo is worth showing at, and the
       three cards spread to the edges of the room. 26rem is the same cap the stacked history rows
       have always used for one photo. */
    --st-wmax: 26rem;
    --st-w: min(var(--st-avail), calc(var(--st-cap) * 0.75), var(--st-wmax));
    /* Both measured by studio.js and published as custom properties (it writes no style declarations):
       --st-band is the height of the band the card centres in, --st-overpull the residual overflow
       under the fixed tab bar that has to be absorbed. Both are 0 at lg+, where nothing is stretched. */
    --st-band: 0px;
    --st-overpull: 0px;
    margin-bottom: calc(var(--st-overpull) * -1);
}
/* The studio starts flush under the header at xl+ (where the header carries the page heading), so it
   drops the generic .page top margin. Doubled class so this wins over .page whatever order the two
   stylesheets load in. */
.page.st-studio { margin-top: 0; }
/* Bootstrap sm to md: the phone rule hands the card the whole viewport, which on a 600-760px tablet
   leaves the neighbours completely off screen and no hint that the track scrolls. This range was
   simply missing between the phone rule and the md-to-lg peek below, so it fell back to full width. */
@media (width >= 576px) and (width < 768px) {
    .st-studio { --st-w: min(calc(var(--st-avail) * 0.84), calc(var(--st-cap) * 0.75), var(--st-wmax)); }
}
@media (width >= 768px) and (width < 1024px) {
    .st-studio { --st-w: min(calc(var(--st-avail) * 0.72), calc(var(--st-cap) * 0.75), var(--st-wmax)); }
}
@media (width >= 1280px) {
    .st-studio { --st-cap: max(12rem, calc(100svh - 19rem)); }
}

/* Below xl the header is VCR's mark, then the page title, on every page (owner, 2026-11-19): the menu that
   carries the logo on a desktop is off screen, and a studio page used to hide its title here, which left the
   bar with no name at all. The platform keeps the header's logo for the top-bar layout only
   (ez-v6.css, .ez-app:not([data-nav="top"]) .ez-header-logo), so VCR puts it back below xl; the body prefix
   outranks that rule. The mark alone at every width below xl (EzLogo Collapsible draws the mark first and the
   wordmark second), so the title keeps its room. On a staff session the menu button stays first. */
/* The narrowest phones (under 400px, the platform's own step for the bar): beside the staff menu button, the
   search, the credits, the bell and the account there is no room for the mark AND the title (at 320px the title
   was squeezed out and the account cut off), so the title wins and the mark gives way. A member's bar has no
   menu button and keeps its mark. */
@media (width < 400px) {
    body .ez-app:not([data-nav="top"]) .ez-app-header:has(.ez-burger) .ez-header-logo { display: none !important; }
}
@media (400px <= width < 1280px) {
    body .ez-app:not([data-nav="top"]) .ez-app-header:has(.ez-burger) .ez-header-logo { display: flex !important; flex: none; }
}
@media (width < 1280px) {
    body .ez-app:not([data-nav="top"]) .ez-app-header:not(:has(.ez-burger)) .ez-header-logo { display: flex !important; flex: none; }
    .ez-app-header .ez-header-logo a > img:first-child:not(:last-child) { display: inline-block !important; }
    .ez-app-header .ez-header-logo a > img + img { display: none !important; }
    /* The mark sized to the bar's controls (the bell and the account are 2.5rem), not the menu's logo height. */
    .ez-app-header .ez-header-logo img { height: 2.25rem; width: auto; }
    /* The step strip IS this page's header rule: the header is just the bar, so the strip is pulled up
       over the main area's top padding to sit on the bar's bottom rule.
       Pure CSS on purpose: this used to be measured by studio.js after first paint, which painted the
       strip lower and then jumped it up on every load. */
    .page.st-studio { margin-top: calc(var(--ez-m-page-py, var(--bs-spacer-7)) * -1); }
    /* Edge to edge, like the header and footer rules it replaces: the negative margin cancels the main
       area's side padding, so the first and last segments meet the screen edges. Scoped to the studio's
       own strip; the looks feed renders the same strip inside a card, where it stays inset. */
    .st-studio > .st-progress { margin-inline: calc(var(--ez-page-px, var(--bs-spacer-7)) * -1); }
}

/* studio.js gives this the exact height of the band between the header's ink and the tab bar (below
   lg only), so the card centres in it - the leftover splits evenly above and below whether the cap
   or the viewport width is the binding constraint. */
.st-wrap { position: relative; display: flex; flex-direction: column; justify-content: center;
    min-height: var(--st-band, 0px); }
/* Bootstrap < md: the card is WIDTH-bound on a phone (full width, 3:4), so centring split a tall band's
   leftover evenly and parked a wide gap between the strip and its card - the strip read as detached
   from what it labels. Drop the band so the wrap is just the card, hung under the strip; the leftover
   goes to the bottom, above the tab bar. Shrinking the wrap (rather than top-aligning inside the band)
   keeps the .st-nav arrows, which centre on the wrap, on the card's midpoint. The strip's own bottom
   margin is the gap. */
@media (width < 768px) {
    .st-wrap { min-height: 0; }
}

/* Do not show the card until studio.js has measured it. --st-band and --st-cap both start at
   the fallbacks declared on .st-studio and are then replaced with measured pixel values a frame later,
   so the unmeasured card sits in a different PLACE and at a different SIZE to the one the user is
   meant to see. Painting it first and correcting it afterwards is a visible jump on every load - and
   it happens twice, because the circuit taking over re-renders the card and studio.js re-fits it.
   Hiding that first frame costs nothing: the reveal is the same frame the measured layout lands on.

   The animation is a dead-man's switch, not decoration. If studio.js never runs (module blocked, a JS
   error, an old WebView), nothing would ever add .st-ready - so after 400ms the card reveals itself
   anyway and falls back to the rem-based sizes in .st-studio. The studio can never end up permanently
   invisible because of this rule. */
.st-studio:not(.st-ready) .st-wrap {
    visibility: hidden;
    animation: st-reveal-unmeasured 0s linear 0.4s forwards;
}
@keyframes st-reveal-unmeasured { to { visibility: visible; } }
/* Card width comes from the viewport, NOT container percentages: a %-based width used in both
   grid-auto-columns and the centring padding resolves against two different boxes (the padding
   shrinks the grid content box) and compounds. */
.st-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: var(--st-w);
    /* Cards differ in height (an empty card collapses its action bar), so centre them on each other
       rather than letting the grid stretch the short one and re-open a dead band inside it. */
    align-items: center;
    gap: 0.65rem;
    padding-inline: max(0rem, calc((100% - var(--st-w)) / 2));
    scroll-padding-inline: max(0rem, calc((100% - var(--st-w)) / 2));
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.st-track::-webkit-scrollbar { display: none; }
.st-track > * { scroll-snap-align: center; }
@media (width >= 1024px) {
    .st-track {
        grid-auto-flow: row;
        /* --st-wmax applies here too: the column is cap-derived, so without it a tall window makes
           each card grow without limit. */
        grid-template-columns: repeat(3, minmax(0, min(calc(var(--st-cap) * 0.75), var(--st-wmax, 26rem))));
        justify-content: center !important;
        gap: 0.9rem;
        overflow: visible;
        scroll-snap-type: none;
        padding-inline: 0;
    }
}

/* One-colour slab: the card header, photo frame, and action bar all share a single surface.
   body-bg is the raised-surface token in BOTH themes (white on the light lavender wash; #141416 on
   the dark wash) - tertiary/secondary melt into the page. The resting border stays transparent (but
   present, so the active ring never shifts layout); only the active card draws its brand outline. */
.st-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    border: 1px solid transparent;
    border-radius: var(--st-radius-card);
    overflow: hidden;
    background: var(--bs-bg-body);
}
@media (width < 1024px) {
    .st-card {
        opacity: 0.55;
        transform: scale(0.975);
        transition: opacity 0.25s ease, transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    }
    .st-card.is-active {
        opacity: 1;
        transform: none;
        border-color: var(--bs-primary-base);
        box-shadow: 0 0 0 3px color-mix(in oklch, var(--bs-primary-base) 14%, transparent);
    }
    /* Until studio.js has marked the snapped card, show every card at full strength - otherwise the
       first paint (and the frame after any Blazor re-render that rewrites a card's class) flashes
       all three dimmed. */
    .st-studio:not(.st-ready) .st-card { opacity: 1; transform: none; }
}
@media (width >= 1024px) {
    /* Desktop needs a resting outline: nothing is dimmed here and no card carries the brand ring by
       default, so without one the three cards dissolve into the page. The current card still lights
       up - the old equation layout highlighted it at every width, and it is just as useful here as a
       "what to do next" cue. */
    .st-card { border-color: var(--bs-border-color); }
    .st-card.is-active {
        border-color: var(--bs-primary-base);
        box-shadow: 0 0 0 3px color-mix(in oklch, var(--bs-primary-base) 14%, transparent);
    }
}

/* Card strip: three slim segments above the track, one per card - the story-bar pattern from the
   design mocks, promoted out of the cards. The cards themselves carry NO heading now: the photos say
   what they are, and the strip says where you are in making a look. It reads left to right like
   progress, which a per-card label never could, and it costs one 30px row for all three cards
   instead of a row inside each card. */
/* NOTE the class names: styling.css (also loaded globally) owns the .st-picker / .st-tile / .st-swatch
   family for the makeup + hair style picker. Keep every rule in this block .st-progress-* / .st-card /
   .st-photo so the two stylesheets never collide - a bare .st-card here once silently
   restyled the styling studios' own headings. */
.st-progress {
    --st-progress-gap: 0.4rem;
    position: relative;
    display: flex;
    gap: var(--st-progress-gap);
    margin: 0 0 0.55rem;
    padding: 0;
}
/* One lit bar that SLIDES between the three faded tracks, rather than three bars switching on and
   off - the movement itself is what says "you moved". studio.js owns data-card (it follows the card
   actually on screen, so swiping, the arrows and tapping a label all drive it). */
.st-progress-slider {
    position: absolute;
    top: 0;
    inset-inline-start: 0;
    height: 3px;
    width: calc((100% - var(--st-progress-gap) * 2) / 3);
    border-radius: 3px;
    background: var(--bs-primary-base);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--bs-primary-base) 14%, transparent);
    transform: translateX(0);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}
/* translateX is a % of the SLIDER's own width, which is exactly one segment - so each card is one
   segment plus one gap further along. */
.st-progress[data-card="2"] .st-progress-slider {
    transform: translateX(calc(100% + var(--st-progress-gap)));
}
.st-progress[data-card="3"] .st-progress-slider {
    transform: translateX(calc(200% + var(--st-progress-gap) * 2));
}
@media (prefers-reduced-motion: reduce) {
    .st-progress-slider { transition: none; }
}
.st-progress-card {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    padding: 0;
    margin: 0;
    border: 0;
    background: none;
    cursor: pointer;
}
.st-progress-bar {
    display: block;
    height: 3px;
    border-radius: 3px;
    /* Dull = the brand colour at low alpha, not a grey: one hue across the strip, so the lit segment
       reads as the same bar turned up rather than a different thing. A solid dark grey vanished
       against the page. */
    background: color-mix(in oklch, var(--bs-primary-base) 22%, transparent);
    transition: background-color 0.25s ease, box-shadow 0.25s ease;
}
.st-progress-lbl {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    line-height: 1.25;
    color: var(--bs-fg-2);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.25s ease;
}
/* The bars themselves stay faded on EVERY card - the sliding indicator above is the only lit one.
   (A middle "completed" tint was tried first and read as a legend to decode rather than an answer
   to "where am I".) Only the label brightens with the current card. */
.st-progress-card.is-current .st-progress-lbl { color: var(--bs-fg-body); font-weight: 700; }
.st-progress-card:hover .st-progress-lbl { color: var(--bs-fg-body); }
/* Per-step checklist beside the label (StudioTrack data-state, set by the studio): an empty checkbox on
   every step still to do, a filled, ticked one in the brand colour once it is filled. On every step from the
   first visit, so a label never shifts sideways when its mark appears. Marks on the LABEL, not the bars -
   the bars stay one faded hue so the sliding indicator remains the only lit one (see above). Shape
   carries the state as well as colour, and screen readers get it as hidden text. */
.st-progress-state { margin-inline-end: 0.35em; color: var(--bs-fg-2); }
.st-progress-card[data-state="done"] .st-progress-state { color: var(--bs-primary-base); }
/* Bootstrap < md: one card fills the screen, so the strip is the only wayfinding and has room to spare
   - the labels are one word each, so they can be read at arm's length instead of squinted at. */
@media (width < 768px) {
    /* A little more air under the labels than the 0.55rem default, now that the card hangs straight
       under the strip instead of being centred away from it. */
    .st-progress { margin-bottom: 1rem; }
    .st-progress-card { gap: 0.5rem; }
    .st-progress-lbl { font-size: 0.9375rem; letter-spacing: 0.01em; }
}

/* The photo frame: a 3/4 box capped by --st-cap. Cards 1-2 stack the EzUpload tile (which grows)
   over the sample strip (natural height, gone once a photo is set); card 3 holds the result box. */
.st-photo {
    position: relative;
    display: flex;
    flex-direction: column;
    aspect-ratio: 3 / 4;
    max-height: var(--st-cap);
    overflow: hidden;
}
.st-up { flex: 1 1 auto; min-height: 0; display: flex; }
/* Empty only: the dashed zone is a control, so it sits inset from the card edges - matching the
   sample strip's inset below it - while a real photo still bleeds edge to edge. No bottom inset:
   the sample strip supplies that gap itself. */
.st-card:not([data-filled]) .st-up { padding: 0.55rem 0.55rem 0; }
/* ONE photo treatment on every card, tile and dialog photo: the image is contain-fitted EDGE TO EDGE
   over a dark blurred blow-up of itself (.to-rbox--fill / EzUpload's .ez-img-fill). A 3:4 photo fills
   the frame completely; the backdrop only shows where a photo of another shape leaves space. The
   frame's own clipping owns the corners, so the image carries no radius. --st-inset is 0 today and is
   kept as the one knob that would bring a band back on every surface at once. */
.st-up .ez-upload-tile-link { padding: var(--st-inset, 0); }
.st-up .ez-upload-tile-img,
.st-photo .to-rbox img,
.lk-tile .to-rbox img { border-radius: 0; }
/* ONE frame per card: the card's own rounded border. The photo boxes inside it (the filled upload tile,
   the result box with its brand ring, the style tile) each drew a square-cornered border of their own
   1px inside the card's, which read as the photo stopping short of the edge and as broken corners where
   the square inner line met the card's curve. Inside a card they draw nothing; the card clips them. */
.st-photo .ez-upload-zone--tile.ez-upload-zone--filled,
.st-photo .to-rbox:not(.to-zone) {
    border: 0;
    box-shadow: none;
}
/* Every photo is framed the same way, results included: the whole image, contain-fitted, over the dark
   blurred blow-up of itself (.to-rbox--fill / .lk-detail-bg). Results used to be cover-cropped so a
   "3:4-ish" model output (896x1200 is 0.747) filled the card without a thin band - but that cropped the
   edges of the look and made card 3 read differently from cards 1 and 2 beside it (owner, 2026-09-30).
   One treatment everywhere; the backdrop fills whatever band a result leaves. */
.st-up .ez-upload { flex: 1; min-height: 0; display: flex; flex-direction: column; }
/* Mix and match: card 2 holds one upload tile per piece (six), inside the same frame as every card, with one
   note under them. Each tile is only an icon and the piece's name (owner, 2026-11-19): the full upload wording
   wrapped word by word in tiles this narrow and left the icons at six different heights.
   The grid splits whatever box the card gives it evenly, so it reads its own box as a size container: taller
   than wide it goes two across and three down, wider than tall three across and two down, which keeps every
   tile near square at any screen size (a 3 x 2 grid in a 3:4 card made tiles twice as tall as wide). The name
   scales with the box (the icon keeps its own fs-xl). Why custom: v6 has no container-query or even-split grid utility. The card is
   padded whether or not a piece is in, so the tiles never touch its edge. */
.st-up:has(> .st-mix) { padding: 0.55rem 0.55rem 0; }
.st-mix { flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.st-pieces { flex: 1; min-height: 0; container: st-pieces / size; }
.st-pieces-grid {
    height: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 0.4rem;
}
@container st-pieces (aspect-ratio < 1) {
    .st-pieces-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: repeat(3, minmax(0, 1fr));
    }
}
.st-piece { position: relative; display: flex; min-width: 0; min-height: 0; }
.st-pieces .ez-upload { min-width: 0; }
/* !important: the zone's own py-7 px-5 are v6 utilities, which outrank this layer. A tile can be under
   6rem across on a phone, and that padding alone would leave no room for its name. */
.st-pieces .ez-upload-zone--tile:not(.ez-upload-zone--filled) {
    padding: 0.25rem !important;
    gap: clamp(0.2rem, 2cqmin, 0.5rem) !important;
}
.st-pieces .ez-upload-zone .fw-medium {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: clamp(0.8125rem, 4cqmin, 1rem);
}
/* "+ Hat": the plus says the tile adds one, in both pointer copies of the name (hooked on the structure, not the
   name's colour class, which the page sets). */
.st-pieces .ez-upload-copy-full > span::before,
.st-pieces .ez-upload-copy-touch::before { content: "+\00a0"; }
/* A filled tile keeps its rounded corners inside the grid (a full-card photo bleeds square, below). */
.st-up .st-pieces .ez-upload-zone--tile.ez-upload-zone--filled { border-radius: var(--st-radius-inner); }
/* The piece's name on its photo, bottom left, clear of the X top right. */
.st-piece-chip {
    position: absolute;
    inset-inline-start: 0.4rem;
    bottom: 0.4rem;
    z-index: 3;
    max-width: calc(100% - 0.8rem);
    padding: 0.1rem 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--bs-fg-body, inherit);
    background: color-mix(in oklch, var(--bs-bg-body) 82%, transparent);
    pointer-events: none;
}
.st-pieces-note {
    flex: 0 0 auto;
    margin: 0;
    padding: 0.6rem 0.25rem 0.65rem;
    text-align: center;
    text-wrap: balance;
    font-size: 0.75rem;
    color: var(--bs-fg-2);
}
/* The shared tile carries its own aspect-ratio/min-height; inside the card the frame governs. */
.st-up .ez-upload-zone--tile {
    flex: 1;
    aspect-ratio: auto;
    min-height: 0;
    max-height: none;
    /* Empty: a transparent dashed zone, so it reads as an inset control and keeps its corners. */
    border-radius: var(--st-radius-inner);
}
/* --result is the outfit/styling result card; --pick is the styling studios' card 2 (the chosen style's
   catalog tile, which opens the picker). Both fill their frame with a .to-rbox instead of an upload
   tile, so they share this whole block. */
.st-photo--result .to-rbox,
.st-photo--pick .to-rbox {
    flex: 1;
    aspect-ratio: auto;
    min-height: 0;
    max-height: none;
    /* Opaque and edge to edge (the photo, the blurred fill, the generating box): the card's own
       clipping owns the corners here - rounding again would cut card background into the image. */
    border-radius: 0;
}
.st-up .ez-upload-zone--tile.ez-upload-zone--filled { border-radius: 0; }
/* Same inset as the upload tile above (see --st-inset), so card 3 and the styling pick card frame their
   photo exactly like cards 1 and 2. */
.st-photo--result .to-rbox-open,
.st-photo--pick .to-rbox-open { padding: var(--st-inset, 0); }
/* The idle / failed click zones are transparent dashed boxes, not filled ones - same inset and
   corners as the upload dropzone, so all three cards read alike before anything is in them. They
   fill the card's full height, so the inset runs on all four sides (the upload zone gets its bottom
   gap from the sample strip instead). */
.st-photo--result .to-rbox.to-zone,
.st-photo--pick .to-rbox.to-zone {
    border-radius: var(--st-radius-inner);
    margin: 0.55rem;
    /* The base .to-rbox is width:100%; left as-is the margins would push it past the right edge. */
    width: auto;
}
/* (Card 2 used to wait on card 1 - that lock is gone: either input can be filled first, and the
   cards only go inert while a generation runs. State still comes from Blazor as the data-filled
   ATTRIBUTE rather than a class, because studio.js owns the is-active class on the same elements
   and Blazor rewrites the whole class attribute when its own expression changes.) */

/* Sample strip inside the card: the shared SampleCarousel, tightened for the narrower frame. */
/* Top padding runs slightly larger than the bottom so the visible gaps match: the bottom one is
   measured to the card's outer edge and so picks up its 1px border. */
.st-samples { flex: 0 0 auto; padding: 0.7rem 0.55rem 0.6rem; }
.st-samples .ss { margin-top: 0; }
.st-samples .ss-head { margin-bottom: 0.35rem; }
.st-samples .ss-label { font-size: 0.68rem; text-wrap: balance; text-align: center; }
/* The removed filter row went here: thumbnails are the content a user actually has to judge (is that
   outfit worth a credit / is that the photo of me I want), and they get harder to read as the strip
   fills with the user's own saved photos rather than catalog shots. */
.st-samples .ss-thumb { width: 4.9rem; }

/* ---- Card actions ride the photo ------------------------------------------------------------
   There is no action bar under the photo any more. It was an empty strip on cards 1 and 2 (one menu
   holding two items) and a taller, wrapping one on card 3, so the three photos were never the same
   height. Now every card is photo-only, and its actions sit on the photo.
   THE placement standard, the same on every studio card, History tile and dialog photo. Everything is
   measured from the photo's own edge (--st-edge), so every control sits the same distance in on every
   card:
     top left     - ONE action menu (.st-photo-menu) holding every tool for that photo: view, download
                    or replace, change, admin QA. Outline trigger at full strength - never faint.
     top right    - selection (History tiles only), the lone remove on cards 1-2 (card 1 is EzUpload's
                    tile X; card 2's is the same button, and tapping its tile changes the pick), or
                    the result's thumbs
   Every button on a photo is the same object: an outline-secondary sm EzButton under .ez-on-media, at
   full strength. None is faint at rest.
     bottom       - the card's purpose, centred: Keep / Discard, Cancel, or a look's videos / share /
                    notes (labels that grow on hover, .lk-grow); a caption or status chip sits above it
   The photo frame is the positioning context for all of them. */
.st-studio,
.lk-feed,
.lk-detail { --st-inset: 0px; --st-edge: calc(var(--st-inset) + 0.5rem); }
.st-photo-menu {
    position: absolute;
    top: var(--st-edge, 0.5rem);
    inset-inline-start: var(--st-edge, 0.5rem);
    z-index: 3;
}
.st-up .ez-upload-tile-close {
    top: var(--st-edge, 0.5rem);
    inset-inline-end: var(--st-edge, 0.5rem);
}

/* Thumbs up / down on the fresh result, top right - the corner the History gives to selection, which
   card 3 does not have. Two icon buttons styled exactly like every other button on a photo (.ez-on-media),
   each lighting up on its own hover; quiet beside the filled Keep / Discard because they are outline. */
.st-rate {
    position: absolute;
    top: var(--st-edge, 0.5rem);
    inset-inline-end: var(--st-edge, 0.5rem);
    z-index: 3;
    display: flex;
    gap: 0.25rem;
}

/* Buttons over a photo that GROW their label: icon-only at rest (a square, like EzButton's own icon
   buttons), the word sliding open on hover or keyboard focus. Replaced floating tooltips, which sat over
   the neighbouring button's count badge and the tile's status line. The label is a real EzButton Label
   the whole time - only its width animates - so it stays the button's accessible name. Touch screens
   have no hover, and the icon stays a square there. */
/* The motion: the button widens on a soft ease-out, then the word fades and slides in a beat later, so
   it arrives into space that is already there instead of being squeezed out of a closing gap. Closing
   runs the other way round - the word leaves first, quickly, then the button tucks back in. */
.lk-grow {
    --lk-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --bs-btn-padding-x: 0;
    min-width: calc(var(--bs-btn-line-height) * 1em + var(--bs-btn-padding-y) * 2 + var(--bs-btn-border-width) * 2);
    gap: 0;
    /* Keeps the button's own colour transitions, which a bare "transition: padding" would drop. */
    transition:
        padding 0.3s var(--lk-ease) 0.05s,
        color 0.15s ease-in-out,
        background-color 0.15s ease-in-out,
        border-color 0.15s ease-in-out;
}
.lk-grow > span:not(.ez-btn-badge) {
    max-width: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-0.3rem);
    transition:
        max-width 0.3s var(--lk-ease) 0.05s,
        margin 0.3s var(--lk-ease) 0.05s,
        opacity 0.1s ease-in,
        transform 0.1s ease-in;
}
.lk-grow:is(:hover, :focus-visible) {
    transition-delay: 0s, 0s, 0s, 0s;
}
.lk-grow:is(:hover, :focus-visible) > span:not(.ez-btn-badge) {
    transition:
        max-width 0.3s var(--lk-ease),
        margin 0.3s var(--lk-ease),
        opacity 0.2s ease-out 0.1s,
        transform 0.25s var(--lk-ease) 0.1s;
}
@media (hover: hover) {
    .lk-grow:hover { --bs-btn-padding-x: 0.65rem; }
    .lk-grow:hover > span:not(.ez-btn-badge) { max-width: 6rem; opacity: 1; transform: none; margin-inline-start: 0.4rem; }
}
.lk-grow:focus-visible { --bs-btn-padding-x: 0.65rem; }
.lk-grow:focus-visible > span:not(.ez-btn-badge) { max-width: 6rem; opacity: 1; transform: none; margin-inline-start: 0.4rem; }
@media (prefers-reduced-motion: reduce) {
    .lk-grow,
    .lk-grow:is(:hover, :focus-visible),
    .lk-grow > span:not(.ez-btn-badge),
    .lk-grow:is(:hover, :focus-visible) > span:not(.ez-btn-badge) { transition: none; }
}
.st-decide {
    position: absolute;
    inset-inline-start: 0;
    inset-inline-end: 0;
    bottom: var(--st-edge, 1.15rem);
    z-index: 5;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding-inline: 0.5rem;
}
/* Step 3's row under Keep / Discard ([Create video] [Share / Poll] [Prints / Frames], 1-3 of them) sizes its
   labels to its OWN width, not the screen's: a desktop card is about as narrow as a phone. Each button holds a
   long and a one-word label (StudioPage.MoreButtonBody); when the long ones would wrap onto a second row over
   the photo, the words show instead ([Video] [Share] [Print]), and on the narrowest cards the icons go too.
   The widths are the measured sums of the buttons plus their gaps (2026-11-19). Only the spans and the icon
   inside the button are ours to show or hide - the button's own size stays Bootstrap's - and the icon goes
   through Font Awesome's own --fa-display, because its unlayered display rule beats any of ours. */
.st-decide-more { container-type: inline-size; }
.st-decide-more .st-short { display: none; }
@container (width < 410px) {
    .st-decide-more--3 .st-long { display: none; }
    .st-decide-more--3 .st-short { display: inline; }
}
@container (width < 262px) {
    .st-decide-more--3 .btn { --fa-display: none; }
}
@container (width < 280px) {
    .st-decide-more--2 .st-long { display: none; }
    .st-decide-more--2 .st-short { display: inline; }
}
@container (width < 175px) {
    .st-decide-more--2 .btn { --fa-display: none; }
}
@container (width < 160px) {
    .st-decide-more--1 .st-long { display: none; }
    .st-decide-more--1 .st-short { display: inline; }
}
/* While a look renders the scan beam and the status caption own the lower part of the box; the
   Cancel button sits under the caption rather than on top of it. */
.st-card--result[data-generating] .to-cap { bottom: calc(var(--st-edge, 1.15rem) + 2.5rem); }
.st-card--result[data-generating] .st-genspin { bottom: calc(var(--st-edge, 1.15rem) + 4.5rem); }

@media (width >= 1024px) {
    /* The row stretches every card to the tallest, and an empty card's photo grows into it - so the
       sample strip sits at the card's base rather than above a dead band. */
    .st-track { align-items: stretch; }
    .st-card:not([data-filled]):not(.st-card--result) .st-photo { flex: 1 1 auto; max-height: none; }
}
@media (width < 1024px) {
    /* An empty card 1 or 2 holds the dropzone AND the sample strip, so it is given the full photo
       height explicitly (the 3/4 ratio would squeeze the dropzone by the strip's height). */
    .st-card:not([data-filled]):not(.st-card--result) .st-photo {
        aspect-ratio: auto;
        max-height: none;
        height: calc(min((var(--st-w) - 2px) * 4 / 3, var(--st-cap)) + var(--st-barh));
        /* Its height is set here, so the sample strip inside can size itself to it (below). */
        container: st-photo / size;
    }
}
/* A short card (a small phone) gives the sample strip less of its height, so the upload tile above it keeps room
   for its title, rules and button (owner, 2026-11-21: the tiles overflowed on a Galaxy S24). Why custom: v6 has no
   container-query utilities. */
@container st-photo (height < 26rem) {
    .st-samples .ss-thumb { width: 4.1rem; }
}
@container st-photo (height < 21rem) {
    .st-samples { padding-block: 0.5rem 0.45rem; }
    .st-samples .ss-thumb { width: 3.5rem; }
}
/* Arrows (scrolling modes only), on the card's vertical midpoint either side of the track (owner
   decision 2026-09-27: kept here, not beside the strip). */
.st-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 50%;
    border: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 1rem;
    /* Prefixed too: Safari before 18 (the iOS 17.5 floor) knows only the -webkit- spelling. */
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
    transition: opacity 0.2s ease;
}
.st-nav:disabled { opacity: 0.25; }
.st-nav--prev { inset-inline-start: 0.4rem; }
.st-nav--next { inset-inline-end: 0.4rem; }
/* The card on screen is filled: the next arrow takes the brand colour and pulses twice, as the cue to
   move on now that filling a card no longer slides the track (studio.js setArrows). `scale`, not
   `transform`, so the pulse does not fight the translateY that centres the arrow. */
.st-nav.is-ready {
    background: var(--bs-primary-base);
    color: var(--bs-white);
    transition: opacity 0.2s ease, background-color 0.2s ease;
    animation: st-nav-ready 0.7s ease-in-out 2;
}
@keyframes st-nav-ready {
    50% { scale: 1.18; }
}
@media (prefers-reduced-motion: reduce) {
    .st-nav.is-ready { animation: none; }
}
/* Card 3 while an input is still missing (StudioPage FirstMissingCard): the same dashed box as the idle
   zone, inert like it, but at full strength - it is a message with a button, not a disabled control. */
.to-zone.is-off.st-missing { opacity: 1; }
/* Its button's answer where every card is already on screen and there is nothing to scroll to: the
   missing card pulses (studio.js showCard). `scale`, so it never fights a transform the layout sets. */
.st-card.is-flash { animation: st-card-flash 0.45s ease-in-out 2; }
@keyframes st-card-flash {
    50% { scale: 1.03; border-color: var(--bs-primary-base); }
}
@media (prefers-reduced-motion: reduce) {
    .st-card.is-flash { animation: none; }
}
@media (width >= 1024px) { .st-nav { display: none; } }

/* Phone in landscape: short and wide (~410px tall). There is no vertical room to give a card the
   screen one at a time, but plenty of width - so all three sit side by side like the desktop row,
   and the chrome that only exists to support swiping (arrows, dimmed neighbours) goes away. Keyed
   on height + orientation so a real tablet or desktop is untouched. Placed after the max-width
   rules above so it wins on source order. */
@media (orientation: landscape) and (max-height: 32rem) {
    .st-track {
        grid-auto-flow: row;
        grid-template-columns: repeat(3, minmax(0, min(calc(var(--st-cap) * 0.75), var(--st-wmax, 26rem))));
        justify-content: center !important;
        align-items: stretch;
        gap: 0.6rem;
        overflow: visible;
        scroll-snap-type: none;
        padding-inline: 0;
    }
    .st-nav { display: none; }
    .st-card { opacity: 1; transform: none; border-color: var(--bs-border-color); }
    .st-card.is-active {
        border-color: var(--bs-primary-base);
        box-shadow: 0 0 0 3px color-mix(in oklch, var(--bs-primary-base) 14%, transparent);
    }
    /* Same empty-card treatment as the desktop row: the collapsed bar's height goes to the photo so
       the samples reach the card's base. The explicit height the portrait rule sets is replaced by
       flex growth, since the row's card width no longer comes from --st-w. */
    .st-card:not([data-filled]):not(.st-card--result) .st-photo {
        aspect-ratio: auto;
        height: auto;
        flex: 1 1 auto;
        max-height: none;
        container-type: normal;
    }
    /* A third of a phone's width each: the smaller sample strip, as on a short portrait card, without its caption
       (it wrapped to two lines in a card this narrow and took the upload tile's room). */
    .st-samples { padding-block: 0.5rem 0.45rem; }
    .st-samples .ss-head { display: none; }
    .st-samples .ss-thumb { width: 3.25rem; }
}

/* Generating spinner on card 3: sits just above the status caption (.to-cap owns bottom 0.9rem), so
   it never collides with the centred effect whichever animation the admin picked. */
.st-genspin {
    position: absolute;
    inset-inline-start: 0;
    inset-inline-end: 0;
    bottom: 2.9rem;
    z-index: 2;
    display: flex;
    justify-content: center;
    color: var(--bs-primary-base);
    pointer-events: none;
}
/* Sized well above Bootstrap's default so it reads as the card's "working" signal from across the
   room, not a footnote under the caption. */
.st-genspin .spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.3em;
}
/* Same three-part signal (beam + caption + spinner) inside a modelling-video tile, which is a fraction
   of a studio card's size - so the spinner is scaled to the tile instead of filling it. */
.mv-card .st-genspin { bottom: 2.4rem; }
.mv-card .st-genspin .spinner-border { width: 1.9rem; height: 1.9rem; border-width: 0.22em; }

/* ============================================================================================
   History (the kept looks under each studio): a GRID of result tiles.
   Each look used to render the studio's whole three-card track, a full screen per look on a phone.
   Now a look is one 3/4 tile of its result - two across on a phone, three from md, four from lg -
   with every action on the photo: the select tick top left, the menu top right (.st-media-actions,
   shared with the studio cards), and the look's three purposes along its foot (.lk-tile-foot). The
   two inputs live in the tile's detail dialog (.lk-detail).
   ============================================================================================ */
.lk-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}
/* Bootstrap md */
@media (width >= 768px) {
    .lk-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
}
/* Bootstrap lg */
@media (width >= 1024px) {
    .lk-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.lk-tile { position: relative; min-width: 0; }
/* The tile's photo: the shared .to-rbox letterbox (the whole image over a blurred blow-up of itself),
   filling the tile edge to edge. The fixed 3/4 frame is what keeps every tile the same height whatever
   shape the result came out. */
/* Same corner radius as a studio card (--st-radius-card), so a kept look reads as the card it came from. */
.lk-tile .to-rbox {
    aspect-ratio: 3 / 4;
    min-height: 0;
    max-height: none;
    border-radius: var(--bs-radius-9);
}
.lk-tile .to-rbox-open { padding: var(--st-inset, 0); }
/* The foot: the video status strip (static here, not pinned like the studio's) over the icon row. */
.lk-tile-foot {
    position: absolute;
    inset-inline-start: var(--st-edge, 0.5rem);
    inset-inline-end: var(--st-edge, 0.5rem);
    bottom: calc(var(--st-edge, 0.5rem) - 0.4rem);
    z-index: 3;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
/* The status strip becomes a rounded chip inside the photo's edge, above the actions, rather than a
   bar across the whole frame - same "everything inside the image" rule as the clusters. */
.lk-tile-foot .to-slot-status {
    position: static;
    align-self: center;
    font-size: 0.75rem;
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-pill);
}
/* The gap and top padding leave room for the video count pill, which straddles its button's corner. */
.lk-tile-actions {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    padding: 0.5rem 0 0.4rem;
}
/* The video-count pill riding the modelling button: smaller than a stock Bootstrap badge, which
   overwhelms a sm icon button, and lifted above the neighbouring button so it is never painted over. */
.lk-count {
    z-index: 2;
    font-size: 0.6rem;
    pointer-events: none;
}

/* The look's detail dialog: the three photos side by side, as a scroll-snap row on a phone. */
.lk-detail {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}
/* Bootstrap < md */
@media (width < 768px) {
    .lk-detail {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: 78%;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        overscroll-behavior-x: contain;
    }
    .lk-detail-fig { scroll-snap-align: center; }
}
.lk-detail-fig { margin: 0; min-width: 0; }
.lk-detail-photo {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: 3 / 4;
    /* Capped to what the viewport leaves after the dialog's chrome (margins, header, labels, the kept
       line), so the three photos fit without the dialog body scrolling. A capped frame goes wider than
       3:4 and the blurred backdrop fills the band, the same as any other off-ratio photo. */
    max-height: calc(100dvh - 16rem);
    min-height: 12rem;
    overflow: hidden;
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-9);
    background: var(--bs-bg-1);
}
/* The backdrop: a blown-up, darkened blur of the same image - the .to-rbox--fill treatment, done with
   an element instead of a per-image custom property. */
.lk-detail-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.2);
    filter: blur(24px) brightness(0.32) saturate(1.2);
    pointer-events: none;
}
.lk-detail-open {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--st-inset, 0);
    border: 0;
    background: none;
    cursor: zoom-in;
}
.lk-detail-open img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.lk-detail-photo--result .lk-detail-open { padding: 0; }
.lk-detail-photo--result { border-color: var(--bs-primary-base); }
.lk-detail-photo--ph { font-size: 2rem; color: var(--bs-fg-2); }
/* Mix and match's pieces in the dialog: all of them inside the same frame one photo takes, two to a row,
   the rows sharing its height, so the three columns still line up. */
.lk-detail-pieces {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: minmax(0, 1fr);
    gap: 0.5rem;
    aspect-ratio: 3 / 4;
    max-height: calc(100dvh - 16rem);
    min-height: 12rem;
}
.lk-detail-pieces .lk-detail-photo {
    aspect-ratio: auto;
    height: 100%;
    min-height: 0;
    max-height: none;
}
/* The label over each dialog photo: the studio strip's own bar + label (.st-progress-bar /
   .st-progress-lbl), with the look itself lit, exactly as the studio shows it. */
.lk-detail-head {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: 0.55rem;
}
.lk-detail-head.is-current .st-progress-bar { background: var(--bs-primary-base); }
.lk-detail-head.is-current .st-progress-lbl { color: var(--bs-fg-body); font-weight: 700; }

/* The line above the My saves feed: the saved count and the live shares link side by side. Outside
   .lk-feed so it is not affected by the feed's tokens; tight to the page heading and the tiles. */
.lk-histhead {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: baseline;
    gap: 0.25rem 1rem;
    margin: 0 0 0.75rem;
}
.lk-histhead h2 { margin: 0; }

/* Room above a look when it is scrolled to. The History heading and the tail of the studio's own steps
   stay in frame, so the look that just arrived reads as having ARRIVED somewhere rather than as the
   page having jumped to an unlabelled photo. */
.lk-tile { scroll-margin-top: 4.5rem; }

/* The just-kept look, for the couple of seconds after Keep: the look the user just made sits at the top
   of their history, where the share, video and notes buttons are, and the ring leads the eye there.
   Photos deliberately have NO entrance animation (owner decision, 2026-10-05) - neither here nor on the
   studio's result. A photo that fades or scales in replays that every time Blazor re-creates its
   element, which is what made the studio flash on open. */
.lk-tile[data-kept] .to-rbox {
    outline: 2px solid var(--bs-primary-base);
    outline-offset: 2px;
}

/* When the look was kept, under the photos in its detail dialog. */
.lk-time {
    margin: 0.75rem 0 0;
    text-align: center;
    font-size: 0.75rem;
    color: var(--bs-fg-2);
}

/* Empty feed: the you + outfit = look equation in placeholder form, centred, with the headline under
   it. Flat by design - dashed neutral tiles, the result tile carrying the same hairline brand ring the
   real result cards get, no panel and no shadow. The operator chips are the studio's own .to-op. */
.lk-empty { max-width: 26rem; margin: 0 auto; padding: 2.5rem 0 3.5rem; text-align: center; }
.lk-empty-eq { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin-bottom: 1.75rem; }
.lk-empty-tile { display: flex; align-items: center; justify-content: center; width: 3.5rem;
    aspect-ratio: 3 / 4; border-radius: var(--bs-radius-5); font-size: 1.05rem; color: var(--bs-fg-2);
    border: 1px dashed var(--bs-border-color); background: var(--bs-bg-1); }
.lk-empty-tile--result { color: var(--bs-primary-base); border-style: solid;
    border-color: color-mix(in oklch, var(--bs-primary-base) 50%, transparent); background: color-mix(in oklch, var(--bs-primary-base) 6%, transparent); }
.lk-empty-title { margin: 0 0 0.5rem; }
.lk-empty-text { margin: 0; color: var(--bs-fg-2); font-size: 0.9rem; line-height: 1.6; }

/* Generating: all three cards are scanned at once, continuously - one beam per card, same timing,
   no delay and a linear curve so there is no pause at either end and they stay in sync. (The old
   equation layout staggered them into a 1-2-3 sequence.) The beam is clipped by .st-photo's
   overflow:hidden, and on card 3 it sweeps over the spinner and the generating effect. */
.st-track.is-busy .st-photo::after {
    content: "";
    position: absolute;
    inset-inline-start: 0;
    inset-inline-end: 0;
    top: -20%;
    height: 16%;
    z-index: 4;
    pointer-events: none;
    background: linear-gradient(to bottom, transparent, color-mix(in oklch, var(--bs-primary-base) 35%, transparent), transparent);
    border-bottom: 2px solid var(--bs-primary-base);
    animation: to-scany 1.6s linear infinite;
}
@media (prefers-reduced-motion: reduce) {
    .st-track.is-busy .st-photo::after { animation: none; opacity: 0; }
}

/* ---- /shares: the owner's view of their public galleries and polls ----------------------
   Rows deliberately reuse the PUBLIC page's .sp-tile / .sp-result / .sp-result-bar family so the owner
   sees exactly what a visitor sees; only the surrounding chrome (header, meta, actions) is .sh-*. */
/* The list: one full-width card per share, stacked, at every screen size (owner decision 2026-09-28 -
   side-by-side columns were tried and read as unrelated boxes). The card's tiles grid is what uses the
   extra width on a wide screen. */
.sh-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.sh-card {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-width: 0;
    padding: 1rem;
    background: var(--bs-bg-body);
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-9);
}
/* A dead share (expired or stopped) steps back: its looks dim, its controls stay at full strength so
   "Share again" is still the obvious thing to do. */
.sh-card--ended .sh-tiles { opacity: 0.55; }

/* Menu, then Link. */
.sh-toolbar { display: flex; align-items: center; gap: 0.5rem; }
.sh-confirm { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem; }
.sh-confirm-actions { display: inline-flex; gap: 0.5rem; margin-inline-start: auto; }

/* Same caption, same pasted URLs - see .sp-lede. */
.sh-title { margin-bottom: 0; overflow-wrap: anywhere; }
/* Bootstrap < sm: one step down, the same as the modal titles, so a share name stays on one line. */
@media (width < 576px) {
    .sh-title { font-size: 1.25rem; line-height: 1.2; letter-spacing: -0.02em; }
}

/* The link's lifetime: the two dates side by side at either end, the bar spanning the full width under
   them, and the time left beneath it. (A three-column version with the words squeezed BETWEEN the dates
   truncated to "30 day..." on a phone.) No frame: three small facts do not need a box of their own, and
   the box made them the tallest thing on the card. */
.sh-life {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}
.sh-life-ends { display: flex; justify-content: space-between; gap: 1rem; }
.sh-life-end { display: flex; flex-direction: column; gap: 0.125rem; min-width: 0; }
.sh-life-end--right { text-align: end; }
.sh-life-label {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--bs-fg-2);
}
.sh-life-date { font-size: 0.875rem; font-weight: 600; white-space: nowrap; }
.sh-life-left { font-size: 0.8125rem; font-weight: 600; text-align: center; }

/* "No votes yet", said once above an unvoted poll's photos instead of "0% 0 votes" under each. */
.sh-novotes { display: flex; align-items: center; gap: 0.5rem; margin: 0; font-size: 0.875rem;
    color: var(--bs-fg-2); }
/* The unfilled track in the brand colour at low alpha, the same treatment as the studio strip's bars -
   the stock track is near-black on this theme, so a young link's sliver of fill had nothing to sit on. */
.sh-life-bar { height: 0.375rem; background: color-mix(in oklch, var(--bs-primary-base) 22%, transparent); }

/* The looks, sized by the CARD rather than the viewport: two across in a phone-width card, more as the
   card widens. The public page's own .sp-card / .sp-tile treatment inside. */
.sh-tiles {
    display: grid;
    /* 8rem, not 9: a phone card's inner width (~18.5rem) only fit ONE 9rem column plus the gap. */
    grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
    gap: 0.75rem;
}
/* Bootstrap md+: the card is full width, so an 8rem floor would line up ten stamp-sized looks across a
   desktop. 13rem keeps them photo-sized (about four to six across). */
@media (width >= 768px) {
    .sh-tiles { grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: 1rem; }
}

/* The public link in the share dialog. A share URL is longer than any field the dialog can give it,
   and this dialog exists precisely BECAUSE the clipboard was unavailable - so the link is shown as
   selectable text that wraps, not a readonly field showing its first third. */
.sh-link {
    display: block;
    margin-bottom: 0.5rem;
    padding: 0.5rem;
    font-family: var(--bs-font-mono);
    font-size: 0.8125rem;
    color: var(--bs-fg-body);
    overflow-wrap: anywhere;
    word-break: break-all;
    background: var(--bs-bg-1);
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-4);
}

.sh-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0;
    font-size: 0.875rem;
    color: var(--bs-fg-2);
}

.sh-search { max-width: 14rem; }

/* The share's own settings at the top of the link dialog (poll, show my name): switches, boxed so they
   read as settings OF this link rather than more text about it. */
.sh-settings {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-radius-5);
}
/* The filter strip itself. It was written with separators and a trailing search box but never had a
   rule of its own, so the chips ran together with no gaps, the 1px separators had nothing to stretch
   against (zero height, invisible) and the search input dropped onto a line of its own. */
.lk-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
/* Divides the studio / mode / status groups in the filter strip. */
.lk-filter-sep {
    width: 1px;
    align-self: stretch;
    min-height: 1.5rem;
    background: var(--bs-border-color);
}

/* ---- History selection: always-visible tick + selected ring + the action bar ---------------
   The tick sits TOP-RIGHT of the tile (top-left is the action menu on every photo in the app, and the
   foot is the look's own actions). Selected state is driven by [data-selected] on
   .lk-tile, never a class expression. */
.lk-pick {
    position: absolute;
    top: var(--st-edge, 0.5rem);
    inset-inline-end: var(--st-edge, 0.5rem);
    z-index: 3;
    display: inline-flex;
    padding: 0.25rem;
    border-radius: var(--bs-radius-4);
    background: color-mix(in oklch, var(--bs-bg-body) 75%, transparent);
    cursor: pointer;
}
.lk-pick .check {
    margin: 0;
    cursor: pointer;
    width: 1.25rem;
    height: 1.25rem;
}

/* The day heading's own tick, at the right end of the heading so it lines up over the tiles' ticks
   (each sits 0.75rem in from its tile's right edge: the 0.5rem edge plus the chip's 0.25rem padding). */
.lk-dayhead { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.lk-daypick { position: relative; display: inline-flex; margin-inline-end: 0.75rem; cursor: pointer; }
.lk-daypick .check {
    margin: 0;
    cursor: pointer;
    width: 1.25rem;
    height: 1.25rem;
}

.lk-tile[data-selected] .to-rbox {
    outline: 2px solid var(--bs-primary-base);
    outline-offset: 2px;
}

/* FIXED to the bottom of the viewport while anything is selected, so the actions stay under the thumb
   that is doing the ticking however far down the History it has gone. (It was a sticky row at the top
   and scrolled away with the page.) Below xl it sits on top of the bottom tab bar - the same 4.25rem
   clearance the app surface reserves for that bar - and the History reserves its own height at the end
   so the last row of tiles can still scroll clear of it. */
/* Phone (below md): docked full width straight on top of the tab bar (its 3.75rem, --ez-tab-bar-h in
   ez-v6.css), like a photo app's selection bar - what is selected on one line, then the actions as an
   equal row of labelled buttons (owner, 2026-11-29: the floating box wrapped into three cramped rows). */
.lk-selbar {
    position: fixed;
    inset-inline: 0;
    bottom: calc(3.75rem + env(safe-area-inset-bottom));
    z-index: 1040;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bs-bg-1);
    border-top: 1px solid var(--bs-border-color);
    box-shadow: 0 -0.5rem 1rem rgb(0 0 0 / 0.3);
}
.lk-selhead { display: flex; align-items: center; gap: 0.75rem; min-height: 2rem; }
.lk-selactions { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 0.5rem; }
.lk-selactions > .btn { min-width: 0; padding-inline: 0.5rem; }
/* From md up: one row floating over the feed, centred on the FEED COLUMN rather than the window: looks.js
   publishes the column's left edge and width (--lk-col-*), physical by nature, so left stays left here.
   Sticky cannot do this - an ancestor of the feed clips - and before the script measures, it centres on
   the window. Below xl the tab bar is still on screen, so it floats just above it. */
@media (width >= 768px) {
    .lk-selbar {
        inset-inline: auto;
        left: calc(var(--lk-col-left, 0px) + var(--lk-col-width, 100vw) / 2);
        bottom: calc(3.75rem + env(safe-area-inset-bottom) + 0.75rem);
        transform: translateX(-50%);
        width: min(44rem, calc(var(--lk-col-width, 100vw) - 2rem));
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
        gap: 0.5rem 1rem;
        padding: 0.5rem 0.75rem;
        border: 1px solid var(--bs-primary-base);
        border-radius: var(--bs-radius-5);
    }
    .lk-selhead { flex: 1 1 auto; }
    .lk-selactions { display: flex; flex: 0 0 auto; }
    .lk-selactions > .btn { padding-inline: revert-layer; }
}
@media (width >= 1280px) {
    .lk-selbar { bottom: calc(1rem + env(safe-area-inset-bottom)); }
}
/* Room under the last row so the bar never covers it (the phone bar is two rows). */
body:has(.lk-selbar) .lk-feed { padding-bottom: 7rem; }
/* Toasts also live at the bottom (ez-platform.css .ez-toast-host), so while this bar floats there
   they stack just ABOVE it instead of covering it - a Delete's Undo toast lands right by the bar that
   raised it. The anchor() line wins wherever anchor positioning is supported; the calc before it is
   the fallback, sized for a one-line bar above the tab bar. The leading `html` outranks the platform's
   own tab-bar lift (same shape, and stylesheet order between the two is not guaranteed). */
.lk-selbar { anchor-name: --lk-selbar; }
html body:has(.lk-selbar) .ez-toast-host {
    bottom: calc(4.25rem + env(safe-area-inset-bottom) + 5rem);
    bottom: calc(anchor(--lk-selbar top) + 0.5rem);
}
.lk-selcount { font-weight: 600; }
/* The share-name switch sits inline with the buttons: no field-stack margin, and smaller, muted text so
   the two actions stay the loudest things in the bar. */
.lk-selname { margin-bottom: 0; font-size: 0.875rem; color: var(--bs-fg-2); }
.lk-selnote {
    font-size: 0.875rem;
    color: var(--bs-fg-2);
}
@media (width >= 768px) { .lk-selnote { flex-basis: 100%; } }

/* The History tile's video button, which the video-count pill hangs off (.lk-count). The "Create
   modelling video" bubble that also hung here after a Keep was removed (owner decision 2026-09-28). */
.kfb-anchor { position: relative; display: inline-flex; }

/* ---- 44px touch targets (WCAG 2.2 AA, 2.5.8) -------------------------------------------------
   Three controls here are drawn smaller than a finger: the sample-strip chevrons (1.6rem), the studio
   card arrows (2rem) and the look-selection tick (its chip is 30px). Each keeps the size it is DRAWN
   at and grows an invisible, centred 44px target instead - padding would have inflated the circle and
   the chip along with it, and these sit over photographs where the visible mark is deliberately small.
   (Only the statically positioned ones are given position:relative - .st-nav and .lk-pick are already
   absolute, and overriding that here would drop them out of their frames.) */
.ss-arrow { position: relative; }
.ss-arrow::after,
.st-nav::after,
.lk-pick::after,
.lk-daypick::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 44px;
    height: 44px;
    transform: translate(-50%, -50%);
}
/* On a touch screen the arrows are drawn larger and reach further still, and buttons over a photo reach up and
   down (owner, 2026-11-25: hard to hit on both phones; ez-v6.css "Touch targets" has the platform's share). */
@media (pointer: coarse) {
    .st-nav { width: 3rem; height: 3rem; }
    .st-nav::after { width: 64px; height: 72px; }
    .ss-arrow { width: 2.25rem; height: 2.25rem; }
    .ss-arrow::after { width: 48px; height: 56px; }
    .st-progress-card { position: relative; }
    .st-progress-card::after { content: ""; position: absolute; inset: -0.625rem 0; }
    .st-rate { gap: 0.5rem; }
    :is(.st-rate, .st-decide, .lk-tile-actions) .btn { --ez-tap-y: 8px; }
    .st-photo-menu .btn { --ez-tap-x: 10px; --ez-tap-y: 10px; }
}

/* ── studio choice (/clothing, /beauty, /pets, /portraits) ────────────────────────────────────────── */
/* The list StudioChoicePage shows before a studio is picked: one poster per studio (the posters are further
   down), and the words every poster shares - the studio's name and the line on what it does. */
.st-choices { display: grid; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.st-choices > li { display: flex; }
.st-choice-title { font-size: 1.75rem; font-weight: 700; line-height: 1.15; }
.st-choice-desc { max-width: 22rem; color: var(--bs-fg-2); }
/* ── Studio switch (StudioSwitch.razor) ───────────────────────────────────────────────────────────
   The studios inside one menu entry as one segmented control (owner pick, 2026-11-18): a rounded track,
   the open studio lit in the brand colour with a brand ring - the same "chosen" look on every screen.
   Bootstrap 6 has no segmented control (its btn-group is joined square buttons), hence a rule of ours.
   Drawn twice by StudioChoicePage and shown once: beside the page title in the header at xl and up
   (--header), and below xl, where the header title is hidden on a studio page, above the step strip
   (--body): centred on a tablet, full width with equal segments and thumb-sized height on a phone. */
.st-switch { display: inline-flex; gap: 2px; max-width: 100%; padding: 3px; border-radius: 999px;
    background: var(--bs-bg-2); border: 1px solid var(--bs-border-color); }
.st-switch-item { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
    min-width: 0; min-height: 2.125rem; padding: 0 1rem; border: 1px solid transparent; border-radius: 999px;
    color: var(--bs-fg-2); font-size: 0.8125rem; font-weight: 600; line-height: 1.2; white-space: nowrap;
    text-decoration: none; transition: background-color 0.15s ease, color 0.15s ease; }
.st-switch-item:hover { color: var(--bs-fg-body); }
.st-switch-item[aria-current="page"] { color: var(--bs-fg-body);
    background: color-mix(in oklch, var(--bs-primary-base) 22%, transparent);
    border-color: var(--bs-primary-base); }
.st-switch-item[aria-current="page"] > i { color: var(--bs-primary-fg); }
.st-switch-item > span { overflow: hidden; text-overflow: ellipsis; }
.st-switch--header { margin-inline-start: 0.75rem; vertical-align: middle; }
.st-switch--body { display: none; }
@media (width < 1280px) {
    /* The switch now sits on the header rule's line where the step strip used to (see the strip's rule
       above), so it takes the strip's pull-up and the strip follows it in normal flow. */
    .st-switch--body { display: flex; width: fit-content; margin-block: calc(var(--ez-m-page-py, auto; margin-inline: 0.75rem var(--bs-spacer-7)) * -1 + 0.75rem); }
    /* The header shows the page title here; its copy of the switch gives way to this one. */
    .st-switch--header { display: none; }
    .st-switch--body + .page.st-studio { margin-top: 0; }
}
@media (width < 768px) {
    .st-switch--body { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); width: 100%; }
    .st-switch--body .st-switch-item { min-height: 2.75rem; padding: 0 0.5rem; }
    /* Four studios (Pets since 2026-11-21) leave a quarter of a phone each, too narrow for an icon beside a name
       ("Try-...", "Dre..."): the icon goes above the name there, so every name shows whole. */
    .st-switch--body:has(.st-switch-item:nth-child(4)) { border-radius: 1.25rem; }
    .st-switch--body:has(.st-switch-item:nth-child(4)) .st-switch-item { flex-direction: column; gap: 0.125rem;
        min-height: 3.25rem; padding: 0.25rem; border-radius: 1rem; font-size: 0.75rem; }
}
@media (prefers-reduced-motion: reduce) {
    .st-switch-item { transition: none; }
}

/* ── The studio cards as posters (StudioChoicePage) ─────────────────────────────────────────────────
   Owner pick, 2026-11-18: the result is the advert. Each card is a big 3:4 picture with the studio's name and
   headline on its darkened foot, and under it the line on what it does. Every poster tells the same
   story the same way (owner decisions, 2026-11-18 and -19): one column down the right of the "before" sample
   photo, an arrow pointing down and up to three results, and the big picture playing the before for 2 s and
   then each result for 3 s, the one on show ringed in violet. Resting on a thumbnail shows it big at once (no click: the whole poster is the
   link into the studio). A studio with no pictures shows its glyph on the poster instead.
   One layout at every width from a tablet up (owner, 2026-11-19: the upright-tablet rows left half the screen
   empty, and a short desktop window squeezed the posters to slivers): side by side, each poster as tall as the
   window allows under the header, its own foot and the page's bottom margin (--st-poster-room), as wide as its
   share of the row, and never narrower than --st-poster-min whatever the window's height. On a phone they stack
   (below). The hover answer is the studio's own: a violet border, a lift, the picture
   leaning in. Reduced motion holds the first result still; resting on a thumbnail still shows it. */
.st-choices--poster { --st-poster-room: 14.5rem; --st-poster-min: 13rem; --st-n: 3; --st-gap: 2rem;
    --st-fit: max(var(--st-poster-min), calc((100svh - var(--st-poster-room)) * 0.75));
    --st-share: calc((100% - (var(--st-n) - 1) * var(--st-gap)) / var(--st-n));
    grid-auto-flow: column; gap: var(--st-gap); justify-content: center;
    grid-auto-columns: min(var(--st-fit), max(var(--st-poster-min), var(--st-share))); }
.st-choices--n1 { --st-n: 1; }
.st-choices--n2 { --st-n: 2; }
/* Four studios (Pets since 2026-11-21: Try-On, Royalty, Paintings, Dress Up): one row on a wide screen, with a smaller
   floor so four fit; two by two on a tablet, where four in a row would be slivers. */
.st-choices--n4 { --st-n: 4; --st-poster-min: 10rem; --st-gap: 1.5rem; }
@media (768px <= width < 1280px) {
    .st-choices--n4 { --st-n: 2; grid-auto-flow: row; grid-template-columns: repeat(2, min(var(--st-fit), var(--st-share))); }
}
.st-choices--poster > li:nth-child(4n) { --st-offset: 3s; }
.st-choices--poster > li { justify-content: center; min-width: 0; }
.st-poster { display: flex; flex-direction: column; gap: 0.9rem; width: 100%; min-width: 0;
    color: var(--bs-fg-body); text-decoration: none; border-radius: 1.25rem; }
.st-poster:hover { color: var(--bs-fg-body); }
.st-poster:focus-visible { outline: 3px solid var(--bs-primary-base); outline-offset: 4px; }
.st-poster-frame { position: relative; isolation: isolate; display: block; flex: none; width: 100%; aspect-ratio: 3 / 4;
    container-type: inline-size;
    overflow: hidden; border-radius: 1.125rem; background: var(--bs-bg-2);
    border: 1px solid color-mix(in oklch, var(--bs-primary-base) 32%, var(--bs-border-color));
    box-shadow: 0 1.1rem 3rem rgba(0, 0, 0, 0.5); transition: border-color 0.2s ease, transform 0.2s ease; }
.st-poster:hover .st-poster-frame { border-color: var(--bs-primary-base); transform: translateY(-3px); }
/* The foot darkens so the name reads on any picture, in either theme. */
.st-poster-frame::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
    background: linear-gradient(to top, rgba(8, 4, 16, 0.92) 0%, rgba(8, 4, 16, 0.55) 26%, transparent 52%); }

/* The big picture plays its pictures in turn: each after the first fades in on top for its turn; the first never
   fades, so the poster is never blank. With a before photo (st-poster--flow) the first is the before, on show for
   2 s, then each result for 3 s; without one the results play 3 s each. */
.st-poster--n2 { --st-loop: 6s; --st-turn: st-turn-2; --st-mark: st-mark-2; }
.st-poster--n3 { --st-loop: 9s; --st-turn: st-turn-3; --st-mark: st-mark-3; }
.st-poster--flow.st-poster--n1 { --st-loop: 5s; --st-last: st-flow-last-1; --st-mark: st-flow-mark-1; --st-mark-before: st-flow-before-1; }
.st-poster--flow.st-poster--n2 { --st-loop: 8s; --st-turn: st-flow-turn-2; --st-last: st-flow-last-2; --st-mark: st-flow-mark-2; --st-mark-before: st-flow-before-2; }
.st-poster--flow.st-poster--n3 { --st-loop: 11s; --st-turn: st-flow-turn-3; --st-last: st-flow-last-3; --st-mark: st-flow-mark-3; --st-mark-before: st-flow-before-3; }
.st-poster-hero { position: absolute; inset: 0; }
.st-poster-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.4s ease; }
/* The posters side by side do not change together (owner, 2026-11-19): each one starts a second after the one
   before it, so the changes run across the row like a wave and the eye can follow one at a time. */
.st-choices--poster > li:nth-child(3n+2) { --st-offset: 1s; }
.st-choices--poster > li:nth-child(3n) { --st-offset: 2s; }
.st-poster-turns > img:not(:first-child) { opacity: 0; animation: var(--st-turn) var(--st-loop) var(--st-offset, 0s) infinite; }
.st-poster-turns > img:nth-child(2), .st-poster-results > .st-poster-pick:nth-child(2) { animation-delay: calc(3s + var(--st-offset, 0s)); }
.st-poster-turns > img:nth-child(3), .st-poster-results > .st-poster-pick:nth-child(3) { animation-delay: calc(6s + var(--st-offset, 0s)); }
.st-poster--flow .st-poster-turns > img:not(:first-child) { animation: var(--st-turn) var(--st-loop) var(--st-offset, 0s) infinite; }
.st-poster--flow .st-poster-turns > img:last-child { animation-name: var(--st-last); }
.st-poster--flow .st-poster-turns > img:nth-child(2), .st-poster--flow .st-poster-results > .st-poster-pick:nth-child(1) { animation-delay: calc(2s + var(--st-offset, 0s)); }
.st-poster--flow .st-poster-turns > img:nth-child(3), .st-poster--flow .st-poster-results > .st-poster-pick:nth-child(2) { animation-delay: calc(5s + var(--st-offset, 0s)); }
.st-poster--flow .st-poster-turns > img:nth-child(4), .st-poster--flow .st-poster-results > .st-poster-pick:nth-child(3) { animation-delay: calc(8s + var(--st-offset, 0s)); }
.st-poster:hover .st-poster-hero > img { transform: scale(1.04); }
/* Each picture stays up until the next one (laid on top of it) has fully faded in, then goes, so only two
   pictures ever blend; the last one fades out over the first. With a before photo the last result fades out over
   it in its final 0.4 s, so the before is fully back as the loop starts again. */
@keyframes st-turn-2 { 0% { opacity: 0; } 6.7%, 56.7% { opacity: 1; } 63.4%, 100% { opacity: 0; } }
@keyframes st-turn-3 { 0% { opacity: 0; } 4.4%, 37.8% { opacity: 1; } 42.2%, 100% { opacity: 0; } }
@keyframes st-flow-turn-2 { 0% { opacity: 0; } 5%, 42.5% { opacity: 1; } 42.6%, 100% { opacity: 0; } }
@keyframes st-flow-turn-3 { 0% { opacity: 0; } 3.6%, 30.9% { opacity: 1; } 31%, 100% { opacity: 0; } }
@keyframes st-flow-last-1 { 0% { opacity: 0; } 8%, 52% { opacity: 1; } 60%, 100% { opacity: 0; } }
@keyframes st-flow-last-2 { 0% { opacity: 0; } 5%, 32.5% { opacity: 1; } 37.5%, 100% { opacity: 0; } }
@keyframes st-flow-last-3 { 0% { opacity: 0; } 3.6%, 23.6% { opacity: 1; } 27.3%, 100% { opacity: 0; } }
.st-poster-icon { position: absolute; inset: 0; display: grid; place-items: center; font-size: 7rem;
    color: var(--bs-primary-base);
    background: radial-gradient(120% 90% at 50% 30%, color-mix(in oklch, var(--bs-primary-base) 30%, transparent), transparent 70%); }

/* The thumbnails, the same place and size on every poster: one column down the right, the before photo, an
   arrow pointing down into the results, then the results, the one on show ringed in violet. Four thumbnails and
   the arrow have to clear the name on the foot, so they are a little smaller than the column once was. */
.st-poster-rail { position: absolute; z-index: 2; top: 5%; inset-inline-end: 5%; display: flex; flex-direction: column;
    align-items: center; gap: 0.4rem; width: 13%; min-width: 2rem; max-width: 3.25rem; }
.st-poster-pick { position: relative; display: block; flex: none; width: 100%; aspect-ratio: 3 / 4;
    overflow: hidden; border-radius: 0.5rem; border: 2px solid #fff; background: #fff;
    box-shadow: 0 0.4rem 1.1rem rgba(0, 0, 0, 0.5); outline: 3px solid transparent; outline-offset: 2px; }
.st-poster-pick > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.st-poster-before, .st-poster-results { display: flex; flex-direction: column; align-items: center; gap: 0.4rem; width: 100%; }
.st-poster-before > .st-poster-pick { animation: var(--st-mark-before) var(--st-loop) var(--st-offset, 0s) infinite; }
/* Before its first turn a later poster's before is on show, so it is ringed from the start. */
.st-poster--flow .st-poster-before > .st-poster-pick { outline-color: var(--bs-primary-base); }
.st-poster-arrow { display: grid; place-items: center; flex: none; width: 1.35rem; height: 1.35rem; border-radius: 50%;
    font-size: 0.7rem; color: var(--bs-primary-contrast, #150a2c); background: var(--bs-primary-base);
    box-shadow: 0 0.3rem 0.8rem rgba(0, 0, 0, 0.45); }
.st-poster-results > .st-poster-pick { animation: var(--st-mark) var(--st-loop) var(--st-offset, 0s) infinite; }
.st-poster--n1:not(.st-poster--flow) .st-poster-results > .st-poster-pick { outline-color: var(--bs-primary-base); }
@keyframes st-mark-2 { 0%, 50% { outline-color: var(--bs-primary-base); } 52%, 100% { outline-color: transparent; } }
@keyframes st-mark-3 { 0%, 33.3% { outline-color: var(--bs-primary-base); } 35%, 100% { outline-color: transparent; } }
/* With a before photo: the before ringed for its 2 s, each result for its 3 s. */
@keyframes st-flow-before-1 { 0%, 39% { outline-color: var(--bs-primary-base); } 40%, 100% { outline-color: transparent; } }
@keyframes st-flow-before-2 { 0%, 24.5% { outline-color: var(--bs-primary-base); } 25%, 100% { outline-color: transparent; } }
@keyframes st-flow-before-3 { 0%, 17.8% { outline-color: var(--bs-primary-base); } 18.2%, 100% { outline-color: transparent; } }
@keyframes st-flow-mark-1 { 0%, 59% { outline-color: var(--bs-primary-base); } 60%, 100% { outline-color: transparent; } }
@keyframes st-flow-mark-2 { 0%, 37% { outline-color: var(--bs-primary-base); } 37.5%, 100% { outline-color: transparent; } }
@keyframes st-flow-mark-3 { 0%, 26.9% { outline-color: var(--bs-primary-base); } 27.3%, 100% { outline-color: transparent; } }
/* Resting on a thumbnail stops the turns and shows that picture big. The first picture is always underneath, so
   resting on it (the before, or the first result without one) only has to stop the others. */
.st-poster-frame:has(.st-poster-pick:hover) .st-poster-turns > img:not(:first-child),
.st-poster-frame:has(.st-poster-pick:hover) .st-poster-pick { animation: none; }
.st-poster:not(.st-poster--flow) .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(2):hover) .st-poster-turns > img:nth-child(2),
.st-poster:not(.st-poster--flow) .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(3):hover) .st-poster-turns > img:nth-child(3),
.st-poster--flow .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(1):hover) .st-poster-turns > img:nth-child(2),
.st-poster--flow .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(2):hover) .st-poster-turns > img:nth-child(3),
.st-poster--flow .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(3):hover) .st-poster-turns > img:nth-child(4) { opacity: 1; }
.st-poster-frame:has(.st-poster-pick:hover) .st-poster-before > .st-poster-pick:not(:hover) { outline-color: transparent; }
.st-poster-frame .st-poster-pick:hover { outline-color: var(--bs-primary-base); }

/* The name and headline keep clear of the thumbnail column down the right (its right offset, its width and a gap),
   and size to the poster rather than the window, so a small poster's name never runs under the thumbnails. */
.st-poster-name { position: absolute; z-index: 2; inset: auto 0 0 0; display: flex; flex-direction: column; gap: 0.35rem;
    padding: 1.25rem calc(5% + clamp(2rem, 13%, 3.25rem) + 0.75rem) 1.25rem 1.4rem; color: #fff; }
.st-poster-name .st-choice-title { font-size: clamp(1.25rem, 11cqi, 2.125rem); color: #fff; overflow-wrap: anywhere; }
/* On the darkened picture the headline is always the light brand tint, whatever the theme's text colour. */
.st-poster-name .st-ad-tagline { font-size: clamp(0.875rem, 5.5cqi, 1.05rem); color: color-mix(in oklch, var(--bs-primary-base) 55%, #fff); }
.st-poster-foot { display: block; padding-inline: 0.25rem; }
.st-poster-foot .st-choice-desc { max-width: none; font-size: 0.875rem; line-height: 1.4; }
.st-ad-tagline { font-size: 1.05rem; font-weight: 600; color: var(--bs-primary-fg); line-height: 1.3; }

/* A phone: the studios stacked one under another, each the full width of the page and the same 3:4 poster as
   everywhere else (owner, 2026-11-20: the swipe row showed one poster and a sliver of the next; a wide-banner
   crop of the posters was tried the same day and rejected). The page scrolls to the next studio. */
@media (width < 768px) {
    .st-choices--poster { --st-gap: 1.5rem;
        grid-auto-flow: row; grid-auto-columns: auto; grid-template-columns: 100%; justify-content: stretch; }
    .st-poster-foot .st-choice-desc { font-size: 0.8125rem; }
}
@media (prefers-reduced-motion: reduce) {
    .st-poster-frame, .st-poster-hero > img { transition: none; }
    .st-poster:hover .st-poster-frame, .st-poster:hover .st-poster-hero > img { transform: none; }
    .st-poster-turns > img:not(:first-child), .st-poster-pick { animation: none; }
    /* With a before photo the first result is held on top of it. */
    .st-poster--flow .st-poster-turns > img:nth-child(2) { opacity: 1; }
    .st-poster--flow .st-poster-frame:has(.st-poster-pick:hover) .st-poster-turns > img:nth-child(2) { opacity: 0; }
    .st-poster--flow .st-poster-frame:has(.st-poster-results > .st-poster-pick:nth-child(1):hover) .st-poster-turns > img:nth-child(2) { opacity: 1; }
    .st-poster-results > .st-poster-pick:first-child { outline-color: var(--bs-primary-base); }
    .st-poster--flow .st-poster-before > .st-poster-pick:not(:hover) { outline-color: transparent; }
    .st-poster-frame:has(.st-poster-pick:hover) .st-poster-results > .st-poster-pick:first-child:not(:hover) { outline-color: transparent; }
}

/* ── The menu rail as round buttons, drawn like the first redesign ─────────────────────────────────
   VCR's app menu is the theme's icon rail (owner decision, 2026-11-18), each entry a round button over its
   label: the four studio groups and My looks. It is drawn to the first redesign's (the Mirror's) measures at
   a 16px type size: a 156px column, the logo 46px tall at the head of the column where the menu's own head
   sits, 52px round buttons with small labels under them, no rule between the menu and the page, and the whole
   frame on a dark violet ground with a soft brand glow behind the menu and the content. The chosen entry
   wears the same brand ring and tint as the studio switch, so "chosen" looks one way everywhere.
   App surface only (the admin console keeps its sidebar) and only at xl, the one width the rail shows (below
   it the phone's tab bar does the job). Both the plain rail and the rail with fly-outs (the theme's menu
   template) are covered; the "> .ez-app-nav" step outranks the platform's rail-flyout rules. */
@media (width >= 1280px) {
    .ez-app[data-surface="app"][data-nav="rail"] {
        --ez-rail-width: 9.75rem;
        --ez-flyout-rail-width: 9.75rem;
        /* The Mirror's ground: near-black with a violet cast, the brand glowing in from the top left and,
           fainter, the bottom right. color-mix keeps it right in a light theme too (a pale lavender wash). */
        border-color: color-mix(in oklch, var(--bs-primary-base) 28%, var(--bs-border-color));
        background:
            radial-gradient(60rem 42rem at 0% 0%, color-mix(in oklch, var(--bs-primary-base) 24%, transparent), transparent 70%),
            radial-gradient(48rem 36rem at 100% 100%, color-mix(in oklch, var(--bs-primary-base) 11%, transparent), transparent 70%),
            color-mix(in oklch, var(--bs-primary-base) 5%, var(--bs-bg-body));
        background-attachment: fixed;
    }
    /* The menu and the header lie on that ground: no colour of their own and no rule between menu and page. */
    .ez-app[data-surface="app"][data-nav="rail"] > :is(.ez-app-nav, .ez-app-header) {
        background: transparent;
        border-inline-end: 0;
        border-block-end: 0;
        box-shadow: none;
    }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav { padding: 0 var(--bs-spacer-3) var(--bs-spacer-7); }
    /* The logo heads the column, as on the first redesign: 46px tall, in a strip the header's height so the
       first button starts where the page does. The platform hides this head in a rail (and the header's copy
       of the logo with it); !important beats the platform's own !important, and the header's copy stays hidden. */
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .ez-nav-head {
        display: flex !important;
        justify-content: center !important;
        min-height: var(--ez-top-h, 4.8rem);
        margin: 0 0 var(--bs-spacer-5) !important;
        padding: 0;
    }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .ez-nav-head img { height: 2.875rem; width: auto; }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .ez-nav-head .ez-nav-close { display: none; }
    .ez-app[data-surface="app"][data-nav="rail"] .ez-header-logo { display: none !important; }

    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .nav { gap: var(--bs-spacer-5); }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown {
        gap: 0.5rem; padding: var(--bs-spacer-1); background-color: transparent; color: var(--bs-fg-1);
        font-size: 0.77rem; font-weight: 600; overflow-wrap: normal; hyphens: manual; }
    /* Font Awesome sizes its glyph from its own --fa-width / --fa-display (its sheet is unlayered, so a plain
       width here loses), hence the variables. A glass disc, as on the first redesign. */
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown .ez-nav-section-icon {
        --fa-width: 3.25rem; --fa-display: inline-flex;
        display: inline-flex; align-items: center; justify-content: center; width: 3.25rem; height: 3.25rem;
        border-radius: 50%; color: var(--bs-fg-body); font-size: 1.25rem;
        background: color-mix(in oklch, var(--bs-fg-body) 10%, transparent);
        border: 1px solid color-mix(in oklch, var(--bs-fg-body) 32%, transparent);
        transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease; }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown:hover .ez-nav-section-icon { border-color: var(--bs-primary-base); }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown:is(.active, [aria-current="page"]) {
        background-color: transparent; color: var(--bs-primary-fg); }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown:is(.active, [aria-current="page"]) .ez-nav-section-icon {
        background: color-mix(in oklch, var(--bs-primary-base) 24%, transparent);
        border-color: var(--bs-primary-base); color: var(--bs-primary-fg); }

    /* The studios on top, the person's own things (My saves, My shares) under a short rule (owner, 2026-11-19):
       "make something" over "your things", nothing hidden. Matched by address, on whichever of the two comes
       first: the rail has an entry per link, and giving the two a section of their own would fold the studios
       into one flyout entry (a single headed section shows as plain links, two do not). */
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .nav
        > .ez-nav-section:has(> .ez-nav-dropdown:is([href$="saves"], [href$="shares"])):not(.ez-nav-section:has(> .ez-nav-dropdown:is([href$="saves"], [href$="shares"])) ~ *)::before {
        content: "";
        display: block;
        width: 2.5rem;
        margin: 0 auto var(--bs-spacer-5);
        border-top: 1px solid color-mix(in oklch, var(--bs-fg-body) 24%, transparent);
    }
}
/* A short window (a laptop, a browser with its bars open): the rail's six entries and the rule would run past the
   bottom of the screen, so the discs, the gaps and the logo strip shrink. Labels stay: an icon alone is a guess. */
@media (width >= 1280px) and (height < 900px) {
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .ez-nav-head { margin-bottom: var(--bs-spacer-3) !important; }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .nav { gap: var(--bs-spacer-3); }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown { gap: 0.3rem; }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown .ez-nav-section-icon {
        --fa-width: 2.625rem; width: 2.625rem; height: 2.625rem; font-size: 1.05rem; }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .nav > .ez-nav-section::before { margin-bottom: var(--bs-spacer-3) !important; }
}
@media (width >= 1280px) and (height < 720px) {
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav > .nav { gap: var(--bs-spacer-2); }
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown .ez-nav-section-icon {
        --fa-width: 2.25rem; width: 2.25rem; height: 2.25rem; font-size: 0.95rem; }
}
@media (width >= 1280px) and (prefers-reduced-motion: reduce) {
    .ez-app[data-surface="app"][data-nav="rail"] > .ez-app-nav .ez-nav-dropdown .ez-nav-section-icon { transition: none; }
}
}
