/* print1026: the Print Studio, on top of site.css + home.css (body.home: the night room, the dark nav, .kick/.disp/.rise, the footer).
   One stage: the bench (canvas over a still poster) full-bleed, the copy top left, the slicer card on the right. */
body.print { --card-w: 340px; --pr-gap: clamp(16px, 2.2vw, 28px); }

/* --- the stage: a one-cell grid; the view spans it, the copy and the card sit over it -------------------------------------------- */
.pr-stage {
  height: 100svh; min-height: 600px; max-height: 1100px; overflow: hidden; background: var(--n0);
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto minmax(0, 1fr);
}
.pr-view { grid-area: 1 / 1 / -1 / -1; position: relative; overflow: hidden; background: var(--n1); }
.pr-poster, .pr-poster img, .pr-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.pr-poster img { object-fit: cover; }
.pr-poster { display: none; transition: opacity .6s ease; }
html[data-time='day'] .pr-day, html[data-time='night'] .pr-night { display: block; }
@media (scripting: none) { .pr-day { display: block; } .pr-act, .pr-card, .pr-corner { display: none; } }
.pr-stage.live .pr-poster { opacity: 0; }
.pr-stage.gone .pr-poster { display: none; }
.pr-canvas { display: block; touch-action: pan-y; outline: none; cursor: grab; -webkit-tap-highlight-color: transparent; }
.pr-canvas:active { cursor: grabbing; }
.pr-canvas:focus-visible { box-shadow: inset 0 0 0 3px var(--gd); }
.pr-stage.nogl .pr-canvas { display: none; }
/* the grade: night under the nav and the copy, feathered into the beat below */
.pr-vig { position: absolute; inset: 0; pointer-events: none; background:
  linear-gradient(180deg, rgba(8,10,28,.62) 0, rgba(8,10,28,.2) 16%, rgba(8,10,28,0) 30%, rgba(8,10,28,0) 82%, var(--n0) 100%),
  radial-gradient(60% 55% at 0% 0%, rgba(8,10,28,.55), rgba(8,10,28,0) 100%); }

/* --- the copy and the file row (top left, over the beams) -------------------------------------------------------------------------- */
.pr-copy, .pr-act { grid-column: 1; position: relative; z-index: 2; padding: 0 var(--pr-gap) 0 max(var(--in), env(safe-area-inset-left)); pointer-events: none; }
.pr-copy { grid-row: 1; padding-top: calc(var(--nav-h) + clamp(28px, 7vh, 90px)); }
.pr-act { grid-row: 2; padding-top: clamp(20px, 3vh, 30px); }
.pr-act > * { pointer-events: auto; width: fit-content; max-width: 100%; }
.pr-stage .disp { font-size: clamp(44px, 5vw, 88px); }
.pr-line { margin: clamp(14px, 2vh, 20px) 0 0; max-width: 26ch; font: 600 clamp(17px, 1.4vw, 21px)/1.35 var(--body); color: var(--cream); text-shadow: 0 2px 12px rgba(0,0,0,.65); text-wrap: balance; }
.pr-load-row { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.pr-load { display: inline-flex; align-items: center; min-height: 48px; padding: 0 26px; border-radius: 999px; cursor: pointer; background: var(--gd); color: var(--ink);
  font: 400 21px/1 var(--display); letter-spacing: .02em; box-shadow: 0 4px 0 var(--gd2), 0 12px 26px rgba(0,0,0,.35); user-select: none; -webkit-user-select: none; }
.pr-load:hover { filter: brightness(1.06); }
.pr-load:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--gd2), 0 6px 14px rgba(0,0,0,.35); }
.pr-file:focus-visible + .pr-load { outline: 3px solid var(--cream); outline-offset: 3px; }
.pr-hint { margin: 0; font: 500 15px/1.35 var(--body); color: rgba(255,247,230,.95); text-shadow: 0 1px 2px rgba(0,0,0,.6), 0 1px 10px rgba(0,0,0,.8); }
.pr-safe { margin: 12px 0 0; font: 500 14px/1.35 var(--body); color: rgba(255,247,230,.9); text-shadow: 0 1px 2px rgba(0,0,0,.6), 0 1px 10px rgba(0,0,0,.8); }
.pr-try { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: clamp(16px, 2.4vh, 24px); max-width: 420px; }
.pr-try-k { margin-right: 4px; font: 700 12px/1 var(--body); letter-spacing: .2em; text-transform: uppercase; color: var(--gd); text-shadow: 0 1px 2px rgba(0,0,0,.7), 0 1px 10px rgba(0,0,0,.85); }
.chip { min-height: 44px; padding: 0 15px; border-radius: 999px; border: 1px solid rgba(255,216,74,.38); background: rgba(8,10,28,.58); color: var(--cream);
  font: 600 15px/1 var(--body); cursor: pointer; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.chip:hover { border-color: var(--gd); color: var(--gd); }
.chip[aria-pressed='true'] { background: rgba(255,216,74,.16); border-color: var(--gd); color: var(--gd); }

/* --- the slicer card (the home's card: night gradient, one gold ring) ------------------------------------------------------------ */
.pr-card {
  grid-column: 2; grid-row: 1 / -1; align-self: start; position: relative; z-index: 2;
  width: var(--card-w); max-height: calc(100% - var(--nav-h) - 2 * var(--pr-gap)); overflow: auto;
  margin: calc(var(--nav-h) + var(--pr-gap)) max(var(--in), env(safe-area-inset-right)) var(--pr-gap) 0;
  padding: 20px 22px 18px; border: 1px solid rgba(255,216,74,.28); border-radius: 22px;
  background: linear-gradient(180deg, rgba(23,32,74,.86), rgba(13,18,48,.9)); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 24px 60px rgba(0,0,0,.4); color: var(--cream); scrollbar-width: thin; scrollbar-color: rgba(255,216,74,.3) transparent;
}
.pr-card-k, .pr-set legend, .pr-stats dt, .pr-sw-k { font: 700 11.5px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; color: #8f9bd0; }
.pr-card-k { margin: 0 0 8px; }
.pr-name { margin: 0; font: 400 28px/1.05 var(--display); color: var(--cream); overflow-wrap: anywhere; }
.pr-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; margin: 16px 0 0; padding: 14px 0 16px; border-top: 1px solid rgba(207,214,242,.14); border-bottom: 1px solid rgba(207,214,242,.14); }
.pr-stats div { min-width: 0; }
.pr-stats dt { margin-bottom: 6px; }
.pr-stats dd { margin: 0; font: 600 17px/1.2 var(--body); font-variant-numeric: tabular-nums; color: var(--cream); }
.pr-set { margin: 16px 0 0; padding: 0; border: 0; min-width: 0; }
.pr-set legend { padding: 0; margin-bottom: 10px; }
.pr-fil-name { margin-left: 6px; letter-spacing: .04em; text-transform: none; font-size: 13px; font-weight: 600; color: var(--cream); }
.pr-seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; border-radius: 999px; background: rgba(8,10,28,.6); box-shadow: inset 0 0 0 1px rgba(207,214,242,.14); }
.pr-seg label { position: relative; cursor: pointer; }
.pr-seg span { display: flex; align-items: center; justify-content: center; min-height: 36px; border-radius: 999px; font: 600 15px/1 var(--body); font-variant-numeric: tabular-nums; color: rgba(255,247,230,.8); }
.pr-seg small { font-size: 12px; opacity: .7; margin-left: 1px; }
.pr-seg input:checked + span { background: var(--gd); color: var(--ink); }
.pr-seg input:focus-visible + span, .sw input:focus-visible + i { outline: 3px solid var(--cream); outline-offset: 2px; }
.pr-sw { display: grid; grid-template-columns: 52px repeat(6, 1fr); align-items: center; gap: 10px 6px; }
.pr-sw-k { font-size: 10.5px; letter-spacing: .14em; }
.sw { position: relative; display: grid; place-items: center; min-height: 34px; cursor: pointer; }
.sw i { width: 28px; height: 28px; border-radius: 50%; box-shadow: inset 0 -3px 5px rgba(0,0,0,.25), inset 0 2px 3px rgba(255,255,255,.25), 0 0 0 1px rgba(255,255,255,.12); transition: box-shadow .15s ease, transform .15s ease; }
.sw input:checked + i { box-shadow: inset 0 -3px 5px rgba(0,0,0,.25), inset 0 2px 3px rgba(255,255,255,.25), 0 0 0 2px var(--n1), 0 0 0 4px var(--gd); }
.sw:hover i { transform: scale(1.08); }
.sw-cream { background: #f3e6c8; } .sw-yolk { background: #ffc93c; } .sw-barn { background: #b8432f; } .sw-leaf { background: #5f8f3a; } .sw-night { background: #283a7a; } .sw-coal { background: #2a2522; }
.silk i { background-image: linear-gradient(135deg, rgba(255,255,255,0) 22%, rgba(255,255,255,.55) 44%, rgba(255,255,255,0) 62%); }
.sw-gold { background-color: #e6b54a; } .sw-copper { background-color: #c8743a; } .sw-pearl { background-color: #c9ccd2; }

.pr-bar { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.pr-play { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--gd); color: var(--ink); cursor: pointer; box-shadow: 0 3px 0 var(--gd2); }
.pr-play svg { width: 20px; height: 20px; }
.pr-play .i-pause, .pr-play.on .i-play { display: none; }
.pr-play.on .i-pause { display: block; }
.pr-scrub { flex: 1; min-width: 0; height: 28px; margin: 0; background: transparent; cursor: pointer; -webkit-appearance: none; appearance: none; --p: 0%; }
.pr-scrub::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--gd) var(--p), rgba(207,214,242,.18) var(--p)); }
.pr-scrub::-moz-range-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--gd) var(--p), rgba(207,214,242,.18) var(--p)); }
.pr-scrub::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; margin-top: -6px; border-radius: 50%; border: 0; background: var(--cream); box-shadow: 0 0 0 3px rgba(255,216,74,.5), 0 2px 6px rgba(0,0,0,.4); }
.pr-scrub::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; border: 0; background: var(--cream); box-shadow: 0 0 0 3px rgba(255,216,74,.5), 0 2px 6px rgba(0,0,0,.4); }
.pr-scrub:focus-visible { outline: 3px solid var(--cream); outline-offset: 2px; border-radius: 6px; }
.pr-pct { flex: none; min-width: 4.2ch; text-align: right; font: 600 15px/1 var(--body); font-variant-numeric: tabular-nums; color: var(--cream); }

.pr-tools { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.pr-edit { display: flex; gap: 8px; flex: 1; }
.pr-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 40px; padding: 0 13px; border-radius: 999px; border: 1px solid rgba(255,247,230,.24);
  background: rgba(8,10,28,.35); color: var(--cream); font: 600 14.5px/1 var(--body); cursor: pointer; white-space: nowrap; }
.pr-edit .pr-btn { flex: 1; padding: 0 8px; }
.pr-btn svg { width: 18px; height: 18px; flex: none; }
.pr-btn:hover { border-color: var(--gd); color: var(--gd); }
.pr-btn[aria-pressed='true'] { border-color: var(--gd); background: rgba(255,216,74,.14); color: var(--gd); }
.pr-photo { width: 100%; }
.pr-btn:disabled, .pr-play:disabled, .pr-scrub:disabled { opacity: .42; cursor: default; filter: none; }
.pr-btn:disabled:hover { border-color: rgba(255,247,230,.24); color: var(--cream); }
.pr-status { min-height: 1.4em; margin-top: 14px; font: 500 14px/1.45 var(--body); color: rgba(255,247,230,.76); }
.pr-status p { margin: 0; }
.pr-status p + p { margin-top: 4px; }
.pr-status .err { color: #f3a682; }
.pr-undo { margin-top: 8px; padding: 0; border: 0; background: none; color: var(--gd); font: 600 14px/1.3 var(--body); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* --- the corner toggles and the drop overlay ---------------------------------------------------------------------------------- */
.pr-corner { position: absolute; z-index: 3; left: max(var(--in), env(safe-area-inset-left)); bottom: max(22px, env(safe-area-inset-bottom)); display: flex; gap: 10px; }
.pr-round { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%; border: 1px solid rgba(255,247,230,.22); background: rgba(8,10,28,.62);
  color: var(--cream); cursor: pointer; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.pr-round svg { width: 21px; height: 21px; }
.pr-round:hover { border-color: var(--gd); color: var(--gd); }
.pr-round[aria-pressed='true'] { color: var(--gd); border-color: rgba(255,216,74,.55); }
#pr-time .i-moon, #pr-time[aria-pressed='true'] .i-sun, #pr-sound .i-on, #pr-sound[aria-pressed='true'] .i-mute { display: none; }
#pr-time[aria-pressed='true'] .i-moon, #pr-sound[aria-pressed='true'] .i-on { display: block; }
.pr-drop { position: absolute; z-index: 4; inset: 0; display: none; place-items: center; pointer-events: none; background: rgba(8,10,28,.62); }
.pr-drop::before { content: ''; position: absolute; inset: clamp(14px, 2vw, 26px); border: 2px dashed rgba(255,216,74,.7); border-radius: 22px; }
.pr-drop p { margin: 0; font: 400 clamp(40px, 6vw, 88px)/1 var(--display); color: var(--cream); text-shadow: 0 .05em 0 var(--ink), 0 .12em .3em rgba(0,0,0,.55); }
.pr-stage.drag .pr-drop { display: grid; }
@media (prefers-reduced-motion: no-preference) {
  .chip, .pr-btn, .pr-round, .pr-load, .pr-seg span { transition: background .15s ease, border-color .15s ease, color .15s ease, transform .12s ease, filter .15s ease; }
}

/* --- Print Plans --------------------------------------------------------------------------------------------------------------- */
.pr-plans { background: var(--n0); padding: clamp(70px, 9vw, 130px) 0 clamp(40px, 5vw, 70px); }
.pr-plans .disp { font-size: clamp(40px, 5.4vw, 88px); }
.pr-plans-line { margin: 22px 0 0; max-width: 40ch; font: 600 clamp(17px, 1.5vw, 22px)/1.4 var(--body); color: rgba(255,247,230,.88); text-wrap: balance; }
.pr-tips { list-style: none; margin: clamp(34px, 4.4vw, 56px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.pr-tips li { padding: 18px 0 0; border-top: 2px solid rgba(255,216,74,.32); }
.pr-tips h3 { margin: 0 0 6px; font: 400 clamp(22px, 2vw, 27px)/1.1 var(--display); color: var(--cream); }
.pr-tips p { margin: 0; font: 500 16px/1.45 var(--body); color: rgba(255,247,230,.76); }
.pr-tips li:nth-child(2) { transition-delay: .08s; } .pr-tips li:nth-child(3) { transition-delay: .16s; }

/* --- the footer: the same dusk, but it rises out of night (no cream finale above it) ---------------------------------------------- */
.print .foot { padding-top: clamp(130px, 13vw, 200px); background:
  radial-gradient(circle at 88% 42%, rgba(255,236,190,.95) 0 15px, rgba(255,236,190,.22) 16px 46px, transparent 90px),
  linear-gradient(180deg, var(--n0) 0, #10153a 14%, #2c2552 30%, #4a3566 40%, #1a2050 58%, #0d1230 80%, #080a1c 100%); }
.foot-cols a[aria-current='page'], .print .nav-link[aria-current='page'] { color: var(--gd); }

/* --- under 1180 px (tablets, small laptops, portrait phones): no room for the copy and the card beside the bench, so they stack:
       the copy on the night ground, the bench full width, then the file row and the card (side by side from 761 px) ----------------- */
@media (max-width: 1180px) and (min-height: 561px), (max-width: 760px) and (orientation: portrait) {
  .pr-stage { display: flex; flex-direction: column; height: auto; min-height: 0; max-height: none; overflow: visible; }
  .pr-copy { order: 1; } .pr-view { order: 2; } .pr-act { order: 3; } .pr-card { order: 4; }
  .pr-copy, .pr-act { padding-left: max(var(--in), env(safe-area-inset-left)); padding-right: max(var(--in), env(safe-area-inset-right)); pointer-events: auto; }
  .pr-copy { padding-top: calc(var(--nav-h) + 22px); padding-bottom: 18px; }
  .pr-stage .disp { font-size: clamp(40px, 11.5vw, 60px); }
  .pr-stage .disp br { display: none; }
  .pr-line { font-size: 16.5px; margin-top: 10px; }
  .pr-view { height: 58svh; min-height: 340px; }
  .pr-vig { background: linear-gradient(180deg, var(--n0) 0, rgba(8,10,28,0) 14%, rgba(8,10,28,0) 84%, var(--n0) 100%); }
  .pr-corner { bottom: 16px; }
  .pr-act { padding-top: 16px; }
  .pr-card { width: auto; max-height: none; overflow: visible; margin: 20px max(var(--in), env(safe-area-inset-right)) 0 max(var(--in), env(safe-area-inset-left)); }
  .pr-drop p { font-size: 44px; }
}
@media (max-width: 760px) and (orientation: portrait) { .pr-tips { grid-template-columns: 1fr; } }
@media (min-width: 761px) and (max-width: 1180px) and (min-height: 561px) {
  .pr-stage { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); grid-template-rows: auto auto auto; column-gap: var(--pr-gap); }
  .pr-copy { grid-area: 1 / 1 / 2 / 3; }
  .pr-view { grid-area: 2 / 1 / 3 / 3; height: min(62svh, 640px); }
  .pr-act { grid-area: 3 / 1 / 4 / 2; padding-top: 24px; }
  .pr-card { grid-area: 3 / 2 / 4 / 3; margin: 20px max(var(--in), env(safe-area-inset-right)) 0 0; }
  .pr-try { max-width: 520px; }
}

/* --- phones, landscape: the bench left (60 %) with only the kicker over it; the file row and the card on the right (the card scrolls
       inside), so the short canvas keeps its whole height for the bench ------------------------------------------------------------- */
@media (max-height: 560px) and (orientation: landscape) {
  .pr-stage { height: 100svh; min-height: 340px; grid-template-columns: 60% 40%; grid-template-rows: auto minmax(0, 1fr); }
  .pr-view { grid-area: 1 / 1 / -1 / 2; }
  .pr-copy { grid-area: 1 / 1 / 2 / 2; padding-top: calc(var(--nav-h) + 6px); }
  .pr-copy .kick { margin: 0; }
  .pr-copy h1, .pr-line, .pr-hint, .pr-safe { display: none; }
  .pr-act { grid-area: 1 / 2 / 2 / 3; display: flex; align-items: center; gap: 8px; min-width: 0; padding: calc(var(--nav-h) + 6px) max(12px, env(safe-area-inset-right)) 0 12px; }
  .pr-act > * { flex: none; }
  .pr-load { min-height: 38px; padding: 0 18px; font-size: 17px; }
  /* one row of samples that scrolls sideways beside the button (the card keeps the height) */
  .pr-try { flex: 1 1 auto; min-width: 0; width: auto; flex-wrap: nowrap; overflow-x: auto; margin-top: 0; gap: 6px; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .pr-try::-webkit-scrollbar { display: none; }
  .chip { flex: none; min-height: 40px; }
  .pr-try-k { display: none; }
  .chip { min-height: 34px; padding: 0 12px; font-size: 14px; }
  .pr-corner { bottom: max(12px, env(safe-area-inset-bottom)); gap: 8px; }
  .pr-round { width: 40px; height: 40px; }
  .pr-card { grid-area: 2 / 2 / 3 / 3; align-self: stretch; width: auto; max-height: none; margin: 10px max(12px, env(safe-area-inset-right)) 12px 12px; padding: 14px 16px; }
  .pr-name { font-size: 22px; }
  .pr-stats { margin-top: 10px; padding: 10px 0 12px; gap: 10px 12px; }
  .pr-stats dd { font-size: 15px; }
  .pr-set { margin-top: 12px; }
  .pr-sw { grid-template-columns: 40px repeat(6, 1fr); gap: 6px 4px; }
  .sw i { width: 24px; height: 24px; }
}
@media (prefers-reduced-motion: reduce) { .pr-poster, .pr-poster img { transition: none; } }
@media print { .pr-stage, .pr-plans { display: none !important; } }

/* --- ?still (tools/print1026/posters.mjs renders the posters and the share image): the UI keeps its place, so the studio frames
       the bench around it exactly as it does live, but nothing over the canvas is drawn ---------------------------------------------- */
html.still .nav, html.still .skip, html.still .pr-copy, html.still .pr-act, html.still .pr-card, html.still .pr-corner, html.still .pr-under, html.still .pr-vig { visibility: hidden; }
html.still .pr-poster { display: none !important; }

/* --- review 1: the copy column gets its own night behind it over the 3D (desktop), the zoom hint, the play bar under the bench -------- */
@media (min-width: 1181px), (max-height: 560px) and (orientation: landscape) {
  .pr-vig { background:
    linear-gradient(180deg, rgba(8,10,28,.62) 0, rgba(8,10,28,.2) 16%, rgba(8,10,28,0) 30%, rgba(8,10,28,0) 82%, var(--n0) 100%),
    linear-gradient(90deg, rgba(8,10,28,.74) 0, rgba(8,10,28,.56) 24%, rgba(8,10,28,.18) 40%, rgba(8,10,28,0) 52%); }
}
.pr-zoomhint { position: absolute; z-index: 3; left: 50%; bottom: max(26px, env(safe-area-inset-bottom)); margin: 0; padding: 9px 16px; border-radius: 999px; pointer-events: none;
  background: rgba(8,10,28,.78); color: var(--cream); font: 600 14px/1.2 var(--body); white-space: nowrap; opacity: 0; transform: translate(-50%, 6px); transition: opacity .3s ease, transform .3s ease; }
.pr-zoomhint.on { opacity: 1; transform: translate(-50%, 0); }
.pr-under[hidden] { display: none !important; }
.pr-under { display: flex; align-items: center; gap: 10px; position: relative; z-index: 3; }
.pr-under .pr-bar { flex: 1; min-width: 0; margin: 0; }
.pr-under .pr-photo { width: 44px; height: 44px; min-height: 44px; padding: 0; flex: none; border-radius: 50%; }
.pr-under .pr-photo svg { width: 20px; height: 20px; }
.pr-under .pr-photo-t { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 1180px) and (min-height: 561px), (max-width: 760px) and (orientation: portrait) {
  .pr-under { order: 3; padding: 12px max(var(--in), env(safe-area-inset-right)) 0 max(var(--in), env(safe-area-inset-left)); }
  .pr-act { order: 4; } .pr-card { order: 5; }
}
@media (min-width: 761px) and (max-width: 1180px) and (min-height: 561px) {
  .pr-under { grid-area: 3 / 1 / 4 / 3; max-width: 760px; }
  .pr-act { grid-area: 4 / 1 / 5 / 2; } .pr-card { grid-area: 4 / 2 / 5 / 3; }
  .pr-stage { grid-template-rows: auto auto auto auto; }
}
@media (max-height: 560px) and (orientation: landscape) {
  .pr-under { grid-area: 1 / 1 / -1 / 2; align-self: end; margin: 0 12px max(12px, env(safe-area-inset-bottom)) calc(max(var(--in), env(safe-area-inset-left)) + 140px);
    padding: 4px 6px 4px 4px; border-radius: 999px; background: rgba(8,10,28,.66); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
  .pr-under .pr-play, .pr-under .pr-photo { width: 40px; height: 40px; min-height: 40px; }
}
/* a short laptop screen (1280x720): the card fits without its own scroll */
@media (min-width: 1181px) and (max-height: 780px) {
  .pr-card { padding: 16px 18px 14px; margin-top: calc(var(--nav-h) + 12px); }
  .pr-name { font-size: 24px; }
  .pr-stats { margin-top: 10px; padding: 10px 0 12px; gap: 10px 14px; }
  .pr-set { margin-top: 12px; }
  .pr-set legend { margin-bottom: 8px; }
  .pr-bar { margin-top: 12px; }
  .pr-tools { margin-top: 12px; }
  .pr-status { margin-top: 10px; }
  .pr-copy { padding-top: calc(var(--nav-h) + clamp(18px, 4vh, 40px)); }
  .pr-stage .disp { font-size: clamp(44px, 4.4vw, 72px); }
}

/* --- review 2: the poster fades in when it arrives (print.js marks it .in; without scripting it is simply there), no drop line where
       nothing can be dropped, 44 px targets in the card on touch screens, captions at 12 px ------------------------------------------ */
@media (scripting: enabled) {
  .pr-poster img { opacity: 0; transition: opacity .5s ease; }
  .pr-poster img.in { opacity: 1; }
}
.pr-pick-t { display: none; }
@media (hover: none) and (pointer: coarse) { .pr-drop-t { display: none; } .pr-pick-t { display: inline; } }
.pr-card-k, .pr-set legend, .pr-stats dt { font-size: 12px; }
.pr-sw-k { font-size: 12px; letter-spacing: .1em; }
@media (pointer: coarse) {
  .sw, .pr-seg span, .pr-btn { min-height: 44px; }
  .pr-scrub { height: 44px; }
  .pr-round { position: relative; }
  .pr-round::after { content: ''; position: absolute; inset: -2px; border-radius: 50%; }
}
@media (max-height: 560px) and (orientation: landscape) {
  .pr-sw { grid-template-columns: 48px repeat(6, 1fr); }
  .chip, .pr-load { min-height: 40px; }
}

/* --- review 3: on the compact layouts the status line (and its units link) sits under the file row (print.ts moves it there); the card
       fits a 320 px screen ---------------------------------------------------------------------------------------------------------- */
.pr-act .pr-status { margin-top: 12px; max-width: 46ch; }
.pr-act .pr-status:empty { min-height: 0; margin-top: 0; }
.pr-act .pr-undo { margin-top: 6px; }
@media (max-height: 560px) and (orientation: landscape) {
  .pr-act { flex-wrap: wrap; row-gap: 4px; }
  .pr-try { flex-basis: 0; }
  .pr-act .pr-status { flex: 1 0 100%; max-width: none; margin-top: 2px; font-size: 13px; line-height: 1.35; }
  .pr-act .pr-status p + p { margin-top: 2px; }
  .pr-act .pr-undo { flex: none; margin-top: 0; font-size: 13px; }
}
@media (max-width: 360px) {
  .pr-sw { grid-template-columns: 44px repeat(6, minmax(0, 1fr)); gap: 10px 4px; }
  .pr-sw-k { letter-spacing: .06em; }
  .sw i { width: 24px; height: 24px; }
}

/* --- printcolor1026: the model's own colours: a swatch of all its filaments, and a legend (each filament a button: pressed = silk) */
.pr-sw > [hidden], .pr-legend[hidden] { display: none; }
.sw-own i { background: conic-gradient(#f3e6c8 0 50%, #ffc93c 0 75%, #b8432f 0); }
.pr-legend { grid-column: 3 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 0 12px; min-width: 0; }
.pr-leg { display: inline-flex; align-items: center; gap: 6px; min-height: 26px; padding: 0; border: 0; background: none; color: var(--cream); font: 600 12.5px/1.2 var(--body); cursor: pointer; text-align: left; }
.pr-leg i { flex: none; width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 -1px 2px rgba(0,0,0,.3), 0 0 0 1px rgba(255,255,255,.2); }
.pr-leg.silk i { background-image: linear-gradient(135deg, rgba(255,255,255,0) 15%, rgba(255,255,255,.7) 45%, rgba(255,255,255,0) 70%); }
.pr-leg small { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #8f9bd0; }
.pr-leg small:empty { display: none; }
.pr-leg:hover span { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(255,255,255,.35); }
.pr-leg:focus-visible { outline: 2px solid var(--cream); outline-offset: 2px; border-radius: 4px; }
@media (pointer: coarse) { .pr-leg { min-height: 44px; } }
@media (max-width: 360px) { .pr-legend { gap: 0 8px; } .pr-leg { font-size: 12px; } }


/* --- printplans-on1026: the two ways in (ready-made, your own chicken), a print sent from the game, the downloads ----------------- */
.pr-try { margin-top: 0; }
.pr-own { margin-top: clamp(16px, 2.4vh, 24px); max-width: 420px; }
.pr-own-line { margin: 0 0 10px; font: 600 15px/1.4 var(--body); color: var(--cream); text-shadow: 0 1px 2px rgba(0,0,0,.6), 0 1px 10px rgba(0,0,0,.8); text-wrap: balance; }
.pr-own .pr-load-row { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.pr-own-btn { min-height: 44px; padding: 0 16px; background: rgba(8,10,28,.58); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.pr-file:focus-visible + .pr-own-btn { outline: 3px solid var(--cream); outline-offset: 3px; }
.pr-own .pr-hint { font-size: 14px; }
.pr-game { margin: 0 0 clamp(16px, 2.4vh, 24px); padding: 14px 16px 16px; max-width: 420px; border: 1px solid rgba(255,216,74,.5); border-radius: 18px;
  background: linear-gradient(180deg, rgba(23,32,74,.9), rgba(13,18,48,.92)); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 18px 40px rgba(0,0,0,.4); }
.pr-game[hidden] { display: none; }
.pr-game-k { margin: 0 0 6px; font: 700 11.5px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--gd); }
.pr-game-n { margin: 0; font: 600 16px/1.35 var(--body); color: var(--cream); overflow-wrap: anywhere; }
.pr-game-b { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; }
.pr-game-b .pr-load[hidden], .pr-game-b .pr-btn[hidden] { display: none; }
.pr-game-b .pr-load:disabled { filter: grayscale(.6); opacity: .7; cursor: default; }
.pr-dl { margin-top: 16px; padding-bottom: 16px; border-bottom: 1px solid rgba(207,214,242,.14); }
.pr-dl[hidden] { display: none; }
.pr-dl-b { display: flex; flex-wrap: wrap; gap: 8px; }
.pr-dl-b .pr-btn { flex: 1 1 0; min-width: 0; min-height: 50px; flex-direction: column; gap: 3px; padding: 6px 10px; border-radius: 14px; border-color: rgba(255,216,74,.45); }
.pr-dl-b .pr-btn[hidden] { display: none; }
.pr-dl-b .pr-btn b { font: 400 18px/1 var(--display); letter-spacing: .02em; color: var(--gd); }
.pr-dl-sz { font-size: 12px; line-height: 1.1; opacity: .75; font-variant-numeric: tabular-nums; }
.pr-dl-sz:empty { display: none; }
.pr-dl-note { margin: 8px 0 0; font: 500 13px/1.4 var(--body); color: rgba(255,247,230,.72); }
.pr-dl-note[hidden] { display: none; }
@media (max-width: 1180px) and (min-height: 561px), (max-width: 760px) and (orientation: portrait) {
  .pr-game, .pr-own { max-width: none; }
}
/* a portrait phone: a print sent from the game is the first thing under the title (above the bench), until the visitor answers */
@media (max-width: 760px) and (orientation: portrait) {
  .pr-stage.game .pr-act { order: 1; padding-top: 0; padding-bottom: 16px; }
  .pr-stage.game .pr-try, .pr-stage.game .pr-own, .pr-stage.game .pr-safe { display: none; }
  .pr-game { margin-bottom: 0; }
}
/* phones, landscape: the act row is one line: the game's card takes it while it is up; else the samples and a small own-file button */
@media (max-height: 560px) and (orientation: landscape) {
  .pr-own-line, .pr-own .pr-hint { display: none; }
  .pr-own { margin: 0; flex: none; }
  .pr-own-btn { min-height: 34px; padding: 0 12px; font-size: 13.5px; }
  .pr-game { display: flex; align-items: center; gap: 8px; margin: 0; padding: 6px 8px 6px 12px; border-radius: 14px; max-width: none; min-width: 0; flex: 1 1 auto; }
  .pr-game-k { display: none; }
  .pr-game-n { flex: 1 1 auto; min-width: 0; font-size: 13px; line-height: 1.25; }
  .pr-game-b { margin: 0; flex: none; gap: 6px; }
  .pr-game-b .pr-btn { min-height: 34px; padding: 0 10px; }
  .pr-stage.game .pr-try, .pr-stage.game .pr-own { display: none; }
  .pr-dl { margin-top: 10px; padding-bottom: 10px; }
  .pr-dl-b .pr-btn { min-height: 42px; font-size: 13px; }
  .pr-dl-b .pr-btn b { font-size: 16px; }
  .pr-dl-note { font-size: 12px; }
}
