/* ===== shared geometry: fluid clamps, type scale, one gold focus ===== */
* { margin: 0; box-sizing: border-box; -webkit-text-size-adjust: 100%; }
html, body { height: 100%; }
body { font-family: "Baloo 2", sans-serif; overflow: hidden; background: var(--ground); color: var(--cream); }
.screen { width: 100dvw; height: 100dvh; position: relative; overflow: hidden;
  padding: var(--pad-screen-y) var(--pad-screen-x); display: flex; flex-direction: column; align-items: center; }
:root {
  --pad-screen-y: clamp(24px, 5vh, 64px); --pad-screen-x: clamp(48px, 5vw, 96px);
  --gap-screen: clamp(20px, 3.5vh, 48px);
  --t-screen-title: clamp(36px, 6vh, 68px); --t-shelf-title: clamp(30px, 4.8vh, 52px);
  --t-action: clamp(24px, 3.8vh, 40px); --t-card-title: clamp(20px, 2.6vh, 30px);
  --t-card-desc: clamp(16px, 2vh, 22px); --t-calm: clamp(22px, 3.4vh, 36px); --t-hud: clamp(18px, 2.8vh, 28px);
}
.brand { position: absolute; top: clamp(16px,2.6vh,30px); right: var(--pad-screen-x); width: clamp(44px,6.4vh,70px);
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.35)); z-index: 5; }
.sky { position: absolute; inset: 0; pointer-events: none; background: var(--sky); }
.title-screen { font-size: var(--t-screen-title); font-weight: 800; text-align: center; z-index: 1; }
.title-shelf { font-size: var(--t-shelf-title); font-weight: 800; text-align: center; z-index: 1; }
.title-end { font-size: clamp(28px,4.4vh,48px); font-weight: 800; text-align: center; z-index: 1; }
.calm { font-size: var(--t-calm); font-weight: 600; color: var(--calm); text-align: center; }
.calm.small { font-size: clamp(18px,2.6vh,28px); }
.btn { font-size: var(--t-action); font-weight: 800; border: none; border-radius: 999px; padding: .45em 1.4em;
  font-family: inherit; background: var(--btn-bg); color: var(--btn-ink); box-shadow: var(--btn-shadow); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--primary-shadow); }
.btn-outline { background: transparent; color: var(--pink); box-shadow: inset 0 0 0 .12em var(--pink); }
.focused { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: clamp(3px,.5vh,5px); }
.hud { display: flex; align-items: center; gap: clamp(26px,3vw,60px); font-size: var(--t-hud); font-weight: 700;
  margin-top: clamp(10px,1.8vh,20px); z-index: 1; }
.wallet { display: flex; align-items: center; gap: .4em; color: var(--gold); font-size: clamp(22px,3.4vh,36px); }
.stones { display: flex; gap: clamp(7px,1vh,12px); }
.stone { width: clamp(14px,2.2vh,24px); aspect-ratio: 1; border-radius: var(--stone-radius); border: .14em solid var(--dim); }
.stone.past { background: var(--dim); }
.stone.today { background: var(--gold); border-color: var(--gold); box-shadow: 0 0 12px var(--gold-glow); }
/* week-dots group (PM 2026-09-14 (b)): "this week" captions the dots, not the streak */
.hud .week { display: flex; flex-direction: row; align-items: baseline; gap: clamp(6px,.9vw,12px); }
/* store chip (PM 2026-09-14 (c), decision-11 browse-only store canon); inkverse/chalkboard
   carry their own boxed .hud .chip treatments below */
.hud .chip { padding: .35em 1em; border-radius: 999px; background: var(--lift); color: var(--cream); font-size: .7em; }
.doors { display: flex; gap: clamp(12px,1.6vw,28px); }
.doors .btn { font-size: var(--t-hud); padding: .35em 1.1em; }
.center-stage { margin: auto; display: flex; flex-direction: column; align-items: center; gap: var(--gap-screen);
  text-align: center; z-index: 1; max-width: 84%; }
.hero { width: clamp(200px,32vh,360px); aspect-ratio: 1; object-fit: cover; border-radius: var(--card-radius);
  box-shadow: var(--art-shadow); }
.facts { font-size: var(--t-calm); color: var(--calm); font-weight: 600; }
.actions { display: flex; gap: clamp(18px,2.4vw,44px); justify-content: center; }
.quiz-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px,2.4vh,28px); }
.quiz { min-width: clamp(260px,22vw,420px); }

/* ===== clay-room components (direction A) ===== */
.ledge { position: absolute; left: -6vw; right: -6vw; bottom: -16vh; height: 46vh; background: var(--ledge-bg);
  border-radius: var(--ledge-radius); box-shadow: var(--ledge-shadow); }
.carousel { display: flex; gap: clamp(16px,1.8vw,36px); align-items: flex-end; margin-top: auto; margin-bottom: 17vh;
  z-index: 1; align-self: stretch; justify-content: flex-start; overflow: visible; }
.slab { width: clamp(340px,26vw,500px); position: relative; display: flex; flex-direction: column; align-items: center;
  filter: brightness(.86) saturate(.88); transform: scale(.95); transform-origin: bottom center; }
.slab.peek { width: clamp(120px,9vw,180px); overflow: hidden; flex: 0 0 auto; align-items: flex-start; }
.slab.peek .art { width: clamp(340px,26vw,500px); max-width: none; }
.slab .art { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block;
  border-radius: var(--card-radius); box-shadow: var(--art-shadow); }
.slab .tag { background: var(--tag-bg); color: var(--ink); border-radius: var(--tag-radius);
  padding: clamp(10px,1.6vh,18px) clamp(16px,2.2vh,26px); width: 90%; margin-top: -4.6vh;
  box-shadow: 0 10px 20px rgba(0,0,0,.4); text-align: center; position: relative; }
.slab .tag .t { font-size: var(--t-card-title); font-weight: 800; line-height: 1.15;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.3em; }
.slab .tag .d { font-size: var(--t-card-desc); font-weight: 600; color: var(--dim); line-height: 1.2;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.stamp { position: absolute; top: clamp(10px,1.6vh,18px); right: clamp(10px,1.6vh,18px);
  width: clamp(44px,6.4vh,68px); aspect-ratio: 1; background: var(--stamp-bg); border-radius: var(--stamp-radius);
  display: grid; place-items: center; box-shadow: 0 6px 12px rgba(0,0,0,.35); z-index: 2; transform: rotate(var(--stamp-tilt)); }
.stamp svg { width: 68%; height: 68%; }
.stamp.ghost svg path { fill: none; stroke: var(--stamp-ghost); stroke-width: 7; stroke-dasharray: 2 9; stroke-linecap: round; }
.stamp.won svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; }
.slab.sketch .art { filter: grayscale(.55) contrast(.82) brightness(1.06); }
.pencil { position: absolute; left: clamp(12px,1.8vh,20px); bottom: 8.2vh; font-size: clamp(24px,3.6vh,38px); color: #7a6a4f;
  background: var(--stamp-bg); border-radius: 50%; width: 1.7em; aspect-ratio: 1; display: grid; place-items: center;
  box-shadow: 0 6px 12px rgba(0,0,0,.35); z-index: 2; }
.slab.focus { filter: none; transform: scale(1.06); }
.slab.focus::before { content: ""; position: absolute; inset: -1.2vh; border: clamp(4px,.6vh,6px) solid var(--ring);
  border-radius: var(--ring-radius); z-index: 3; pointer-events: none; }
.slab.focus::after { content: ""; position: absolute; left: 8%; right: 8%; bottom: -9vh; height: 6vh;
  background: radial-gradient(ellipse at center, var(--glow), transparent 70%); border-radius: 50%; }
.picker-ground { position: absolute; left: -8vw; right: -8vw; bottom: -14vh; height: 34vh; background: var(--ledge-bg);
  border-radius: var(--ledge-radius); }
.picker-kids { display: flex; gap: clamp(60px,9vw,180px); align-items: flex-end; margin-top: auto; margin-bottom: var(--gap-screen); z-index: 1; }
.kidbtn { display: flex; flex-direction: column; align-items: center; gap: clamp(14px,2.4vh,26px); position: relative; }
.kidbtn .pebble { width: clamp(300px,44vh,470px); aspect-ratio: 1; overflow: hidden; border-radius: var(--pebble-radius);
  box-shadow: 0 18px 34px rgba(0,0,0,.4); background: var(--pebble-bg); }
.kidbtn .pebble img { width: 100%; height: 100%; object-fit: cover; }
.kidbtn .nametag { background: var(--tag-bg); color: var(--ink); font-size: var(--t-action); font-weight: 800;
  border-radius: var(--tag-radius); padding: .3em 1.1em; box-shadow: 0 8px 16px rgba(0,0,0,.35); }
/* E1.12 kid stage anatomy: cutout + ledge + label, clamp-only sizing (1080p + 720p share one definition) */
.screen[data-screen="picker"] .kidbtn .cutout { height: clamp(240px,38vh,480px); width: auto; display: block; }
.screen[data-screen="picker"] .kidbtn .stage-ledge { align-self: center; width: 100%;
  height: clamp(10px,1.6vh,18px); background: var(--stage-ledge, var(--lift));
  border-radius: var(--card-radius, clamp(14px,2vh,22px)); }
.screen[data-screen="picker"] .kidbtn .cutout-medallion { height: clamp(240px,38vh,480px); aspect-ratio: 1; border-radius: 50%;
  background: var(--cream); color: var(--ground); display: grid; place-items: center;
  font-size: clamp(90px,15vh,190px); font-weight: 800; }
.kidbtn.recess { filter: brightness(.8) saturate(.85); }
.kidbtn.focus { transform: scale(1.06); }
.kidbtn.focus::after { content: ""; position: absolute; left: 50%; bottom: clamp(52px,9vh,96px); width: 125%;
  height: clamp(30px,5.4vh,56px); transform: translateX(-50%);
  background: radial-gradient(ellipse at center, var(--glow-strong) 0%, var(--glow) 45%, transparent 72%);
  border-radius: 50%; z-index: -1; }
/* ---- E1.12 picker kid stages: ALL rules scoped to the picker screen (handoff keeps its own model) ---- */
.screen[data-screen="picker"] .kidbtn { width: fit-content; gap: clamp(10px,1.8vh,20px); transition: transform 150ms ease-out; }
.screen[data-screen="picker"] .kidbtn.focus { transform: none; outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: clamp(3px,.5vh,5px); }
.screen[data-screen="picker"] .kidbtn.focus::after { content: none; }
/* ---- picker sync to production sw v11 (PICKER-fix v1.1 F2/F3/F7/F8 + v1.2): x-carousel scrollbar
   suppressed (same precedent as shelf-row), doors grid axis, doors enabled tokens, failure state ---- */
.screen[data-screen="picker"] .picker-kids, .screen[data-screen="picker"] .picker-row { scrollbar-width: none; }
.screen[data-screen="picker"] .picker-kids::-webkit-scrollbar, .screen[data-screen="picker"] .picker-row::-webkit-scrollbar { display: none; }
.screen[data-screen="picker"] .picker-doors { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  gap: clamp(24px,6vw,60px); justify-content: center; align-self: stretch; z-index: 1; }
.screen[data-screen="picker"] .picker-doors .kidbtn { justify-self: center; gap: clamp(8px,1.4vh,16px); }
.screen[data-screen="picker"] .kidbtn-door { filter: none; }
.screen[data-screen="picker"] .kidbtn-door .cutout { height: clamp(70px,12vh,160px); }
.screen[data-screen="picker"] .kidbtn-door .nametag { font-size: clamp(16px,2.6vh,30px); background: var(--cream); color: var(--ink); box-shadow: 0 8px 16px #00000059; }
.screen[data-screen="picker"] .picker-row-empty { margin: 0; padding: 0; }
.screen[data-screen="picker"] .picker-failure { margin: auto 0; display: flex; flex-direction: column; align-items: center; gap: var(--gap-screen); z-index: 1; }
/* production failure retry treatment (sw v11 .nila-picker .nila-action.nila-primary parity) */
.screen[data-screen="picker"] .picker-failure .btn-primary { border-radius: 999px; font-size: clamp(20px,3.2vh,36px); font-weight: 800; padding: .45em 1.4em; box-shadow: none; }
.screen[data-screen="celebration"] { padding: 0; }
.cele-overlay { position: absolute; inset: 0; pointer-events: none; }
.cele-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cele-tintlayer { position: absolute; inset: 0; background: var(--cele-tint); pointer-events: none; }
.cele-stamp { position: absolute; top: 12vh; right: 16vw; width: clamp(70px,10vh,110px); aspect-ratio: 1;
  background: var(--stamp-bg); border-radius: 50%; display: grid; place-items: center;
  box-shadow: 0 10px 24px rgba(0,0,0,.4); transform: rotate(-12deg); z-index: 1; }
.cele-stamp svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; }
.cele-stamp svg { width: 68%; height: 68%; }
.cele-lower { position: absolute; left: 0; right: 0; bottom: 0; padding: 6vh 5vw 8vh;
  background: linear-gradient(transparent, var(--cele-veil) 45%); text-align: center; }
.cele-stars { font-size: clamp(32px,5vh,52px); color: var(--gold); font-weight: 800; }
.store-grid { display: flex; gap: clamp(18px,2.2vw,40px); margin-top: var(--gap-screen); z-index: 1; }
.item { background: var(--lift); border-radius: var(--card-radius); padding: clamp(14px,2vh,22px);
  width: clamp(240px,19vw,360px); display: flex; flex-direction: column; gap: clamp(8px,1.2vh,14px);
  box-shadow: var(--art-shadow); }
.item img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: var(--item-radius); }
.item .t { font-size: var(--t-card-title); font-weight: 800; }
.item .p { font-size: var(--t-hud); font-weight: 800; color: var(--gold); }
.item.locked { filter: saturate(.35) brightness(.8); }
.comeback { margin-top: var(--gap-screen); font-size: var(--t-hud); font-weight: 600; color: var(--calm);
  background: var(--lift); border-radius: 999px; padding: .5em 1.4em; z-index: 1; }
.cb-art { margin-right: .5em; }
.store-back { margin-top: auto; z-index: 1; }
.wallet-line { font-size: var(--t-calm); font-weight: 700; color: var(--gold); z-index: 1; }
.endings-wrap { display: flex; gap: clamp(40px,6vw,120px); align-items: center; margin: auto; z-index: 1; }
.ending { display: flex; flex-direction: column; align-items: center; gap: clamp(14px,2.2vh,26px); max-width: 38vw; }
.ending-divider { width: 2px; align-self: stretch; background: linear-gradient(transparent, var(--dim), transparent); }
.beat-card { width: clamp(300px,23vw,440px); display: flex; flex-direction: column; align-items: center; position: relative; }
.beat-card .art { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--card-radius); box-shadow: var(--art-shadow); }
.beat-card .tag { background: var(--tag-bg); color: var(--ink); border-radius: var(--tag-radius);
  padding: clamp(8px,1.3vh,14px) clamp(16px,2.2vh,26px); width: 86%; margin-top: -4.2vh; text-align: center;
  box-shadow: 0 10px 20px rgba(0,0,0,.4); font-size: var(--t-card-title); font-weight: 800; }
.hollow { opacity: .45; filter: grayscale(.6); }
.glow-gold { filter: drop-shadow(0 0 34px rgba(255,199,44,.45)); }

/* ===== parent frame (all directions; palette varies per theme) ===== */
.parent-frame { background: var(--p-bg); color: var(--p-ink); padding: 0; }
.p-head { width: 100%; padding: 18px 20px 10px; display: flex; justify-content: flex-end; }
.p-head img { width: 34px; }
.p-thread { flex: 1; width: 100%; max-width: 560px; margin: 0 auto; padding: 8px 16px 16px; display: flex;
  flex-direction: column; gap: 12px; overflow: hidden; justify-content: flex-end; }
.bub { max-width: 82%; padding: 12px 16px; border-radius: var(--bub-radius); font-size: 17px; line-height: 1.35; font-weight: 600; }
.bub.nila { background: var(--p-nila); color: var(--p-ink); align-self: flex-start; border-bottom-left-radius: 6px;
  box-shadow: 0 2px 6px rgba(23,18,63,.08); }
.bub.me { background: var(--p-me); color: var(--cream); align-self: flex-end; border-bottom-right-radius: 6px; }
.p-art { width: 100%; border-radius: 12px; display: block; }
.receipt-t { font-weight: 800; }
.receipt-s { color: var(--p-dim); font-size: 15px; margin-top: 4px; }
.p-composer { width: 100%; max-width: 560px; margin: 0 auto; padding: 12px 16px 22px; display: flex; gap: 10px; }
.p-composer .field { flex: 1; background: var(--p-nila); border-radius: 999px; padding: 13px 20px; color: var(--p-dim);
  font-size: 17px; font-weight: 600; box-shadow: 0 2px 6px rgba(23,18,63,.08); }
.p-composer .send { background: var(--primary); color: #fff; border-radius: 999px; padding: 13px 22px; font-weight: 800; font-size: 17px; }
.p-actions { display: flex; gap: 10px; }
.p-btn { border-radius: 999px; padding: 10px 18px; font-weight: 800; background: var(--p-chip); color: var(--p-ink); font-size: 16px; }
.p-btn.primary { background: var(--primary); color: #fff; }

/* ============ DIRECTION A: CLAY ROOM (merged ui-spec v1) ============ */
.theme-clay {
  --ground: #1c1150; --lift: #2b1c7a; --cream: #fff4dc; --ink: #17123f; --dim: #6b5fa8;
  --primary: #ff6b2c; --pink: #ff3d8b; --gold: #ffc72c; --ring: #ffe14d;
  --calm: #cfc4f2; --gold-glow: rgba(255,199,44,.8); --glow: rgba(255,225,77,.5); --glow-strong: rgba(255,225,77,.95);
  --sky: radial-gradient(ellipse 85% 58% at 50% -6%, #2b1c7a 0%, rgba(43,28,122,.45) 42%, transparent 72%);
  --ledge-bg: linear-gradient(#342487, #2b1c7a 30%); --ledge-radius: 48% 52% 0 0 / 26% 28% 0 0;
  --ledge-shadow: 0 -14px 50px rgba(0,0,0,.3) inset;
  --card-radius: clamp(18px,2.6vh,30px); --art-shadow: 0 22px 34px rgba(0,0,0,.45);
  --tag-bg: #fff4dc; --tag-radius: clamp(12px,1.8vh,20px); --stamp-bg: #fff4dc; --stamp-radius: 50%; --stamp-tilt: 0deg;
  --stamp-ghost: #b3a88f; --ring-radius: clamp(22px,3.2vh,36px); --item-radius: clamp(10px,1.5vh,16px);
  --stone-radius: 45% 55% 50% 50% / 55% 45% 55% 45%;
  --btn-bg: #2b1c7a; --btn-ink: #fff4dc; --btn-shadow: 0 .14em 0 #180d45; --primary-shadow: 0 .18em 0 #c24a17;
  --pebble-bg: #fff4dc; --pebble-radius: 47% 53% 50% 50% / 55% 50% 50% 45%;
  --cele-tint: rgba(28,17,80,.18); --cele-veil: rgba(20,12,56,.88);
  --p-bg: #f6efe0; --p-nila: #ffffff; --p-me: #2b1c7a; --p-chip: #efe6d2; --bub-radius: 20px;
  --p-ink: #17123f; --p-dim: #6b5fa8;
}

/* ============ DIRECTION B: STORYBOOK ============ */
.theme-storybook {
  --ground: #241028; --lift: #33220f; --cream: #f6ead0; --ink: #452e14; --dim: #9a7c50;
  --primary: #b8462e; --pink: #c25a70; --gold: #d9a441; --ring: #ffd94d;
  --calm: #d8c6a2; --gold-glow: rgba(217,164,65,.8); --glow: rgba(255,217,77,.45); --glow-strong: rgba(255,217,77,.9);
  --sky: radial-gradient(ellipse 90% 62% at 50% -8%, #3a2513 0%, transparent 68%);
  --ledge-bg: linear-gradient(#3a2513, #2a1a0e 40%); --ledge-radius: 50% 50% 0 0 / 10% 10% 0 0; --ledge-shadow: none;
  --card-radius: 10px; --art-shadow: 0 14px 28px rgba(0,0,0,.5);
  --tag-bg: #f6ead0; --tag-radius: 8px; --stamp-bg: #f6ead0; --stamp-radius: 50%; --stamp-tilt: 8deg; --stamp-ghost: #b09a70;
  --ring-radius: 12px; --item-radius: 8px; --stone-radius: 4px;
  --btn-bg: #4a3016; --btn-ink: #f6ead0; --btn-shadow: 0 .14em 0 #241304; --primary-shadow: 0 .18em 0 #7c2a16;
  --pebble-bg: #f6ead0; --pebble-radius: 46%;
  --cele-tint: rgba(32,20,12,.2); --cele-veil: rgba(24,14,8,.88);
  --p-bg: #e7d3a8; --p-nila: #fdf6e0; --p-me: #7c4a1e; --p-chip: #dcc9a0; --bub-radius: 14px 18px 12px 20px;
  --p-ink: #452e14; --p-dim: #9a7c50;
}
.theme-storybook .parent-frame { background-image: repeating-linear-gradient(0deg, transparent 0 30px, rgba(120,80,40,.14) 30px 31px); }
.book { display: flex; width: min(78vw,1500px); height: 50vh; margin-top: 2.5vh; z-index: 1;
  box-shadow: 0 30px 60px rgba(0,0,0,.55); border-radius: 14px; }
.book .page { flex: 1; background: #f6ead0; position: relative; overflow: hidden; }
.book .page.left { border-radius: 14px 3px 3px 14px; }
.book .page.right { border-radius: 3px 14px 14px 3px; padding: 4vh 3vw; color: #452e14;
  display: flex; flex-direction: column; gap: 1.6vh; justify-content: center; }
.book .page.right::before { content: ""; position: absolute; top: 0; right: 11%; width: 30px; height: 70px;
  background: #c25a70; clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 76%, 0 100%); }
.book .gutter { width: 2vw; background: linear-gradient(90deg, #e2d0a8, #b39a72 50%, #e2d0a8); }
.pageart { width: 100%; height: 100%; object-fit: cover; display: block; }
.deckle { position: absolute; inset: 0; box-shadow: inset 0 0 60px rgba(69,46,20,.35); }
.postmark { position: absolute; top: 3vh; right: 2.4vw; width: clamp(56px,8vh,86px); aspect-ratio: 1;
  border: 3px dashed rgba(184,70,46,.75); border-radius: 50%; display: grid; place-items: center; transform: rotate(10deg); }
.postmark svg { width: 58%; height: 58%; }
.postmark svg path { fill: none; stroke: rgba(184,70,46,.7); stroke-width: 6; stroke-dasharray: 3 8; stroke-linecap: round; }
.p-title { font-size: clamp(26px,4vh,44px); font-weight: 800; line-height: 1.15; }
.p-desc { font-size: var(--t-calm); font-weight: 600; color: #7c5c2e; }
.p-meta { font-size: var(--t-hud); font-weight: 700; color: #9a7c50; }
.page.right .btn { align-self: flex-start; }
.pageindex { display: flex; gap: 1.4vw; margin-top: 1vh; z-index: 1; align-items: flex-end; }
.pagetab { width: clamp(120px,9vw,170px); aspect-ratio: 3/4; background: #efe2c4; border-radius: 8px; padding: 6px;
  box-shadow: 0 10px 22px rgba(0,0,0,.45); position: relative; }
.pagetab:nth-child(odd) { transform: rotate(-1.4deg); }
.pagetab:nth-child(even) { transform: rotate(1.2deg); }
.pagetab img { width: 100%; height: 100%; object-fit: cover; border-radius: 5px; display: block; }
.pagetab.current { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 4px; transform: translateY(-1.6vh); }
.pagetab.sketch img { filter: grayscale(.6) contrast(.85) brightness(1.05); }
.pagetab.peektab { width: clamp(64px,5vw,96px); opacity: .7; }
.mini-star { position: absolute; top: -10px; right: -10px; width: 36px; aspect-ratio: 1; background: #f6ead0;
  border-radius: 50%; display: grid; place-items: center; z-index: 2; box-shadow: 0 4px 10px rgba(0,0,0,.35); }
.mini-star svg { width: 64%; height: 64%; }
.mini-star svg path { fill: var(--gold); stroke: #b8892e; stroke-width: 4; }
.mini-pencil { position: absolute; bottom: -8px; left: -8px; width: 30px; aspect-ratio: 1; background: #f6ead0;
  border-radius: 50%; display: grid; place-items: center; box-shadow: 0 4px 8px rgba(0,0,0,.35); z-index: 2; }
.bookcover { margin: auto; background: linear-gradient(#8a3524, #6e2818); border-radius: 16px; padding: 5vh 4.5vw 6vh;
  box-shadow: 0 30px 70px rgba(0,0,0,.6), inset 0 0 0 6px rgba(246,234,208,.14); display: flex; flex-direction: column;
  align-items: center; gap: 4.5vh; z-index: 1; }
.cover-plates { display: flex; gap: 4vw; }
.plate { background: #f6ead0; border-radius: 46%; padding: 10px; width: clamp(220px,32vh,340px); aspect-ratio: 1;
  box-shadow: 0 14px 28px rgba(0,0,0,.45); display: flex; flex-direction: column; align-items: center; position: relative; }
.plate img { width: 100%; flex: 1; min-height: 0; object-fit: cover; border-radius: 42%; }
.plate-name { font-size: var(--t-action); font-weight: 800; color: #452e14; padding: 1vh 0 .4vh; }
.plate.focus { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 6px; transform: translateY(-1.4vh); }
.plate.recess { filter: brightness(.82) saturate(.85); }
.singlepage { margin: auto; width: min(56vw,980px); background: #f6ead0; color: #452e14; border-radius: 12px;
  padding: 4vh 3.5vw 4.5vh; box-shadow: 0 30px 60px rgba(0,0,0,.55); display: flex; flex-direction: column;
  align-items: center; gap: 2vh; text-align: center; z-index: 1; }
.sp-art { width: 100%; aspect-ratio: 16/8; object-fit: cover; border-radius: 8px; }
.ribbons { display: flex; gap: 2.4vw; align-items: flex-start; }
.ribbon { white-space: nowrap; }
.ribbon { border: none; font-family: inherit; font-size: var(--t-action); font-weight: 800; cursor: pointer;
  background: #b8462e; color: #f6ead0; padding: 1.1em 1.2em 1.9em; border-radius: 8px 8px 0 0;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 84%, 0 100%); }
.ribbon.focused { background: var(--gold); color: #452e14; transform: translateY(1.2vh); outline: none; box-shadow: 0 0 0 5px var(--ring); }
.exlibris { width: clamp(90px,13vh,130px); aspect-ratio: 1; border: 3px solid #b8462e; border-radius: 50%;
  display: grid; place-items: center; transform: rotate(-8deg); }
.exlibris svg { width: 62%; height: 62%; }
.exlibris svg path { fill: var(--gold); stroke: #b8892e; stroke-width: 4; }
.singlepage .title-screen { color: #452e14; }
.singlepage .calm, .singlepage .facts { color: #7c5c2e; }
.singlepage .cele-stars { color: #b8892e; }
.storebook { height: 62vh; }
.storeleft { padding: 4vh 2.6vw; display: flex; flex-direction: column; gap: 2.4vh; color: #452e14; justify-content: center; }
.storeleft .title-shelf, .storeleft .wallet-line { color: #452e14; }
.storeleft .wallet-line { color: #b8892e; }
.storeleft .comeback { background: #efe2c4; color: #7c5c2e; }
.catalog { display: grid; grid-template-columns: 1fr 1fr; gap: 2vh 1.6vw; padding: 3.4vh 2.4vw; align-content: center; }
.cat { background: #efe2c4; border-radius: 8px; padding: 10px; display: flex; flex-direction: column; gap: 6px;
  color: #452e14; box-shadow: 0 6px 14px rgba(69,46,20,.25); }
.cat img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: 5px; }
.cat .t { font-size: var(--t-card-desc); font-weight: 800; }
.cat .p { font-size: var(--t-hud); font-weight: 800; color: #b8462e; }
.cat.focused { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 3px; }
.cat.locked { filter: saturate(.35) brightness(.88); }

/* ============ DIRECTION C: LANTERN TRAIL ============ */
.theme-lantern {
  --ground: #06061a; --lift: #17123f; --cream: #f2ead2; --ink: #3a2c14; --dim: #8a7cb0;
  --primary: #ff8a3d; --pink: #ff5d9e; --gold: #ffd24d; --ring: #ffe97a;
  --calm: #b9b0e0; --gold-glow: rgba(255,210,77,.9); --glow: rgba(255,210,110,.55); --glow-strong: rgba(255,220,120,.95);
  --sky:
    radial-gradient(1.5px 1.5px at 12% 22%, #fff9, transparent 100%),
    radial-gradient(1.5px 1.5px at 32% 10%, #fff7, transparent 100%),
    radial-gradient(2px 2px at 55% 18%, #fff8, transparent 100%),
    radial-gradient(1.5px 1.5px at 74% 8%, #fff6, transparent 100%),
    radial-gradient(2px 2px at 88% 26%, #fff8, transparent 100%),
    radial-gradient(1.5px 1.5px at 45% 30%, #fff5, transparent 100%),
    radial-gradient(1.5px 1.5px at 66% 40%, #fff4, transparent 100%),
    radial-gradient(ellipse 85% 60% at 50% -8%, #141036 0%, transparent 72%);
  --ledge-bg: none; --ledge-radius: 0; --ledge-shadow: none;
  --card-radius: clamp(20px,3vh,34px); --art-shadow: 0 0 0 3px rgba(255,214,130,.35), 0 0 34px rgba(255,196,90,.28), 0 18px 30px rgba(0,0,0,.5);
  --tag-bg: #f6ecd4; --tag-radius: 12px; --stamp-bg: #f6ecd4; --stamp-radius: 50%; --stamp-tilt: 0deg; --stamp-ghost: #b0a184;
  --ring-radius: 16px; --item-radius: 12px; --stone-radius: 50%;
  --btn-bg: #1a1546; --btn-ink: #f2ead2; --btn-shadow: 0 0 18px rgba(120,100,220,.35), 0 .14em 0 #0a0820;
  --primary-shadow: 0 .18em 0 #b35a17, 0 0 24px rgba(255,150,60,.4);
  --pebble-bg: #f6ecd4; --pebble-radius: 50%;
  --cele-tint: rgba(4,4,24,.4); --cele-veil: rgba(6,6,26,.88);
  --p-bg: #0d0b26; --p-nila: #262050; --p-me: #5546a8; --p-chip: #2c2658; --bub-radius: 20px;
  --p-ink: #ece6ff; --p-dim: #9a90d0;
}
.theme-lantern .wallet { text-shadow: 0 0 14px rgba(255,210,77,.8); }
.theme-lantern .stone.today { border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; }
.trailline { position: absolute; top: 13vh; left: 6vw; right: 6vw; height: 0; z-index: 0;
  border-top: 3px dashed rgba(255,220,140,.4); }
.lantern-row { display: flex; justify-content: center; align-items: flex-start; gap: clamp(28px,3.6vw,72px);
  margin-top: 13vh; width: 100%; z-index: 1; }
.lantern { position: relative; display: flex; flex-direction: column; align-items: center; width: clamp(200px,15vw,290px); }
.lantern.peek { width: clamp(90px,7vw,130px); opacity: .55; }
.lantern.peek .ltag { display: none; }
.lstring { width: 2px; height: 5vh; background: linear-gradient(rgba(255,220,150,0), rgba(255,220,150,.65)); }
.lframe { width: 100%; aspect-ratio: 3/4; border-radius: 44% 44% 22% 22% / 26% 26% 14% 14%; overflow: hidden;
  background: #141038; border: 3px solid rgba(255,205,120,.55); position: relative;
  box-shadow: 0 0 40px rgba(255,190,90,.28), inset 0 0 30px rgba(255,180,80,.16); }
.lframe .blur { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: blur(18px) brightness(.55); transform: scale(1.25); }
.lframe .sharp { position: relative; width: 100%; height: 100%; object-fit: contain; display: block; }
.ltag { margin-top: 1.4vh; background: #f6ecd4; color: #3a2c14; padding: .7em 1.1em; border-radius: 10px;
  font-size: var(--t-card-desc); font-weight: 800; max-width: 115%; text-align: center; line-height: 1.2;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  box-shadow: 0 8px 16px rgba(0,0,0,.4); }
.lstar { position: absolute; top: 4.2vh; right: -14px; width: clamp(34px,4.8vh,52px); aspect-ratio: 1; z-index: 2; }
.lstar svg { width: 100%; height: 100%; }
.lstar.won svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; filter: drop-shadow(0 0 10px rgba(255,210,77,.9)); }
.lstar.ghost svg path { fill: none; stroke: rgba(246,236,212,.5); stroke-width: 6; stroke-dasharray: 3 9; stroke-linecap: round; }
.lantern.focus { width: clamp(250px,19vw,350px); z-index: 2; }
.lantern.focus .lframe { border-color: var(--ring); box-shadow: 0 0 0 4px var(--ring), 0 0 70px rgba(255,205,110,.55), inset 0 0 34px rgba(255,190,90,.25); }
.lantern.unlit .lframe { border-color: rgba(122,110,180,.4); box-shadow: none; }
.lantern.unlit .lframe img { filter: grayscale(.7) brightness(.5); }
.lantern.unlit .ltag { background: #2a2450; color: #b9b0e0; }
.lpencil { position: absolute; bottom: 16%; left: 6%; width: 34px; aspect-ratio: 1; background: #f6ecd4; border-radius: 50%;
  display: grid; place-items: center; box-shadow: 0 4px 10px rgba(0,0,0,.4); z-index: 2; }
.hang-row { display: flex; justify-content: center; align-items: flex-start; gap: 10vw; margin: auto 0; z-index: 1; }
.hang-row.picker-row { align-items: flex-end; }
.biglantern { position: relative; display: flex; flex-direction: column; align-items: center; width: clamp(280px,36vh,430px); }
.biglantern .lstring { height: 7vh; }
.biglantern.focus { transform: scale(1.06); }
.biglantern.focus .lframe { border-color: var(--ring); box-shadow: 0 0 0 5px var(--ring), 0 0 80px rgba(255,205,110,.55); }
.biglantern.recess { filter: brightness(.75) saturate(.85); }
.biglantern.jumbo { width: clamp(200px,30vh,320px); }
.biglantern.jumbo .lstring { height: 3vh; }
.lant-answer { border: 2px solid rgba(255,205,120,.45); box-shadow: 0 0 18px rgba(255,190,90,.2), var(--btn-shadow); }
.riselights { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(6px 9px at 18% 78%, rgba(255,205,120,.8), transparent 100%),
  radial-gradient(5px 8px at 34% 62%, rgba(255,190,100,.65), transparent 100%),
  radial-gradient(7px 10px at 52% 82%, rgba(255,205,120,.75), transparent 100%),
  radial-gradient(5px 8px at 68% 58%, rgba(255,190,100,.6), transparent 100%),
  radial-gradient(6px 9px at 84% 74%, rgba(255,205,120,.7), transparent 100%),
  radial-gradient(4px 7px at 26% 40%, rgba(255,190,100,.5), transparent 100%),
  radial-gradient(5px 8px at 76% 30%, rgba(255,205,120,.5), transparent 100%),
  radial-gradient(4px 6px at 44% 22%, rgba(255,190,100,.45), transparent 100%); }
.cele-star { width: clamp(90px,13vh,130px); aspect-ratio: 1; filter: drop-shadow(0 0 30px rgba(255,210,77,.8)); }
.cele-star svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; }
.stall-line { width: 84%; height: 2px; background: linear-gradient(90deg, transparent, rgba(255,220,150,.7), transparent);
  margin-top: 3vh; z-index: 1; }
.stall { display: flex; justify-content: center; gap: clamp(22px,2.8vw,56px); z-index: 1; }
.stallitem { display: flex; flex-direction: column; align-items: center; width: clamp(220px,17vw,330px); }
.stallitem .lstring { height: 3vh; }
.sframe { width: 100%; aspect-ratio: 16/10; border-radius: 14px; overflow: hidden;
  border: 3px solid rgba(255,205,120,.3); box-shadow: 0 0 12px rgba(255,190,90,.1); }
.sframe img { width: 100%; height: 100%; object-fit: cover; display: block; }
.stallitem .t { margin-top: 1vh; font-size: var(--t-card-title); font-weight: 800; text-align: center; }
.stallitem .p { font-size: var(--t-hud); font-weight: 800; color: var(--gold); }
.stallitem.focused .sframe { border-color: var(--ring); box-shadow: 0 0 0 4px var(--ring), 0 0 40px rgba(255,205,110,.45); }
.stallitem.locked { filter: saturate(.35) brightness(.7); }

/* ============ DIRECTION D: BLOCK TOWER ============ */
.theme-blocks {
  --ground: #0e2233; --lift: #123a52; --cream: #eef4ff; --ink: #12233c; --dim: #6f87a8;
  --primary: #e64533; --pink: #ff4d94; --gold: #ffc72c; --ring: #ffe14d;
  --calm: #b8cfe4; --gold-glow: rgba(255,199,44,.8); --glow: rgba(255,225,77,.45); --glow-strong: rgba(255,225,77,.9);
  --sky: radial-gradient(ellipse 85% 58% at 50% -6%, #173852 0%, transparent 70%);
  --ledge-bg: none; --ledge-radius: 0; --ledge-shadow: none;
  --card-radius: clamp(14px,2vh,22px); --art-shadow: 0 14px 0 rgba(0,0,0,.35), 0 22px 30px rgba(0,0,0,.4);
  --tag-bg: #eef4ff; --tag-radius: 12px; --stamp-bg: #eef4ff; --stamp-radius: 50%; --stamp-tilt: 0deg; --stamp-ghost: #8fa4c0;
  --ring-radius: 16px; --item-radius: 10px; --stone-radius: 50%;
  --btn-bg: #1a4f9e; --btn-ink: #eef4ff; --btn-shadow: 0 .18em 0 #0c2c5c; --primary-shadow: 0 .18em 0 #a82c1e;
  --pebble-bg: #eef4ff; --pebble-radius: 18%;
  --cele-tint: rgba(10,35,55,.3); --cele-veil: rgba(8,25,40,.88);
  --p-bg: #ffffff; --p-nila: #eef4ff; --p-me: #2470d8; --p-chip: #ffe9c4; --bub-radius: 14px;
  --p-ink: #241040; --p-dim: #7a68a8;
}
.baseplate { position: absolute; left: 0; right: 0; bottom: 0; height: 12vh;
  background-color: #134e34;
  background-image: radial-gradient(circle at 24px 24px, rgba(255,255,255,.14) 9px, transparent 10px);
  background-size: 48px 48px; box-shadow: 0 -6px 20px rgba(0,0,0,.35); }
.blockrow { position: absolute; left: 0; right: 0; bottom: 9vh; display: flex; justify-content: center;
  align-items: flex-end; gap: clamp(18px,2.2vw,44px); z-index: 1; }
.blockrow .blk { width: clamp(280px,19vw,390px); flex-direction: column; gap: 1vh; padding: 1vh 1vw 1.5vh; }
.blockrow .blk .bface { width: 100%; aspect-ratio: 16/9; }
.blockrow .blk .btitle { font-size: var(--t-card-desc); text-align: center; min-height: 2.4em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tower-head { display: flex; flex-direction: column; align-items: center; }
.blk { position: relative; display: flex; align-items: center; gap: 1.4vw; width: clamp(520px,36vw,780px);
  padding: 1.6vh 1.6vw; border-radius: 16px; box-shadow: 0 .55em 0 rgba(0,0,0,.35), 0 18px 30px rgba(0,0,0,.4); }
.blockrow .blk:nth-child(5n+1) { background: linear-gradient(#b85a4e, #9c463c); }
.blockrow .blk:nth-child(5n+2) { background: linear-gradient(#4a76b8, #3a5e94); }
.blockrow .blk:nth-child(5n+3) { background: linear-gradient(#d9b04a, #bd9a38); }
.blockrow .blk:nth-child(5n+4) { background: linear-gradient(#5aa37c, #488566); }
.blockrow .blk:nth-child(5n+5) { background: linear-gradient(#8a72c0, #705aa8); }
.blockrow .blk:nth-child(5n+3) .btitle { color: #2a1c08; }
.bface { width: clamp(110px,8.6vw,170px); aspect-ratio: 1; object-fit: cover; border-radius: 12px; flex: 0 0 auto;
  box-shadow: inset 0 0 0 3px rgba(255,255,255,.25); }
.btitle { color: #fff; font-size: var(--t-card-title); font-weight: 800; line-height: 1.2; }
.bstud { position: absolute; top: -12px; right: 20px; width: clamp(34px,4.8vh,52px); aspect-ratio: 1;
  background: rgba(255,255,255,.16); border-radius: 50%; display: grid; place-items: center; }
.bstud svg { width: 82%; height: 82%; }
.bstud.won svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; }
.bstud.ghost svg path { fill: none; stroke: rgba(255,255,255,.7); stroke-width: 8; stroke-dasharray: 4 10; stroke-linecap: round; }
.blk.hollowblock { background: transparent; border: 3px dashed rgba(255,255,255,.45); box-shadow: none; }
.blk.hollowblock .bface { filter: grayscale(.65) brightness(.7); }
.blk.hollowblock .btitle { color: rgba(238,244,255,.75); }
.bpencil { position: absolute; bottom: -10px; left: 18px; width: 34px; aspect-ratio: 1; background: #eef4ff;
  border-radius: 50%; display: grid; place-items: center; box-shadow: 0 4px 10px rgba(0,0,0,.4); z-index: 2; }
.blockrow .blk.focus { transform: translateY(-2.2vh) scale(1.05); z-index: 3; outline: clamp(4px,.6vh,6px) solid var(--ring);
  outline-offset: 4px; }
.peekblock { width: clamp(120px,9vw,180px) !important; opacity: .55; overflow: hidden; }
.cube-row { display: flex; gap: 8vw; align-items: flex-end; margin-top: auto; margin-bottom: 17vh; z-index: 1; }
.cube { width: clamp(260px,38vh,400px); aspect-ratio: 1; border-radius: 16%; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 2vh; background: linear-gradient(#2f80ed, #1a4f9e);
  box-shadow: 0 16px 0 #0f2f57, 0 26px 40px rgba(0,0,0,.45); }
.cube:last-child { background: linear-gradient(#e2503f, #b03223); box-shadow: 0 16px 0 #6e1d13, 0 26px 40px rgba(0,0,0,.45); }
.cube img { width: 60%; aspect-ratio: 1; object-fit: cover; border-radius: 50%; box-shadow: inset 0 0 0 4px rgba(255,255,255,.3); }
.cubename { background: #eef4ff; color: #12233c; font-size: var(--t-action); font-weight: 800; padding: .2em 1em; border-radius: 10px; }
.cube.focus { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 6px; transform: translateY(-2.4vh); }
.cube.recess { filter: brightness(.78) saturate(.85); }
.jumboblock { width: clamp(560px,44vw,900px); background: linear-gradient(#2f80ed, #1f5cb8); }
.jumboblock .bface { width: clamp(150px,12vw,230px); }
.jumboblock .btitle { font-size: var(--t-calm); }
.block-answers { display: flex; gap: 2vw; }
.flagtower { display: flex; flex-direction: column; align-items: center; }
.flagpole { width: 5px; height: 9vh; background: #eef4ff; border-radius: 3px; }
.flag { width: clamp(60px,9vh,90px); height: clamp(36px,5.4vh,54px); background: var(--gold);
  clip-path: polygon(0 0, 100% 50%, 0 100%); margin-left: clamp(30px,4.5vh,45px); margin-top: -8.4vh; margin-bottom: 2.4vh; }
.mini-block { width: clamp(120px,16vh,180px); height: clamp(38px,5.4vh,54px); border-radius: 10px; margin-top: 1vh;
  box-shadow: 0 .4em 0 rgba(0,0,0,.35); }
.mb1 { background: #e2503f; } .mb2 { background: #2f80ed; width: clamp(140px,19vh,210px); } .mb3 { background: #37b26c; width: clamp(160px,22vh,240px); }
.bin { display: flex; gap: clamp(16px,2vw,36px); background: rgba(255,255,255,.05); border: 3px solid rgba(255,255,255,.16);
  border-radius: 24px; padding: 3vh 2.4vw; margin-top: 2vh; z-index: 1; }
.binitem { border-radius: 14px; padding: 12px; width: clamp(210px,16vw,320px);
  display: flex; flex-direction: column; gap: 8px; box-shadow: 0 .5em 0 rgba(0,0,0,.3); }
.bin .binitem:nth-child(4n+1) { background: linear-gradient(#4a76b8, #3a5e94); }
.bin .binitem:nth-child(4n+2) { background: linear-gradient(#b85a4e, #9c463c); }
.bin .binitem:nth-child(4n+3) { background: linear-gradient(#5aa37c, #488566); }
.bin .binitem:nth-child(4n+4) { background: linear-gradient(#8a72c0, #705aa8); }
.binitem img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: 8px; }
.binitem .t { font-size: var(--t-card-title); font-weight: 800; }
.binitem .p { font-size: var(--t-hud); font-weight: 800; color: var(--gold); }
.binitem.focused { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 3px; }
.binitem.locked { filter: saturate(.35) brightness(.75); }

/* ============ DIRECTION E: GARDEN TERRARIUM ============ */
.theme-garden {
  --ground: #0c2620; --lift: #14453a; --cream: #f2ecd8; --ink: #123126; --dim: #4f7a6c;
  --primary: #ff8a4d; --pink: #ff6fa0; --gold: #ffd24d; --ring: #ffec70;
  --calm: #b8d8c8; --gold-glow: rgba(255,210,77,.85); --glow: rgba(200,255,150,.4); --glow-strong: rgba(255,236,112,.95);
  --sky:
    radial-gradient(2px 2px at 20% 30%, rgba(255,236,150,.5), transparent 100%),
    radial-gradient(2px 2px at 62% 18%, rgba(255,236,150,.4), transparent 100%),
    radial-gradient(2px 2px at 84% 36%, rgba(255,236,150,.35), transparent 100%),
    radial-gradient(ellipse 85% 58% at 50% -6%, #164a3a 0%, transparent 72%);
  --ledge-bg: none; --ledge-radius: 0; --ledge-shadow: none;
  --card-radius: clamp(18px,2.6vh,30px); --art-shadow: 0 18px 30px rgba(0,0,0,.5);
  --tag-bg: #6b4a2f; --tag-radius: clamp(12px,1.8vh,20px); --stamp-bg: #f2ecd8; --stamp-radius: 50%; --stamp-tilt: 0deg;
  --stamp-ghost: #a8b49a; --ring-radius: clamp(22px,3.2vh,36px); --item-radius: 14px;
  --stone-radius: 50% 50% 50% 50% / 62% 62% 38% 38%;
  --btn-bg: #14453a; --btn-ink: #f2ecd8; --btn-shadow: 0 .14em 0 #08201a; --primary-shadow: 0 .18em 0 #b35a20;
  --pebble-bg: #f2ecd8; --pebble-radius: 50%;
  --cele-tint: rgba(8,40,32,.3); --cele-veil: rgba(6,32,26,.88);
  --p-bg: #cfe0c6; --p-nila: #f2f8ea; --p-me: #1f5c40; --p-chip: #b9d2ac; --bub-radius: 20px;
  --p-ink: #123126; --p-dim: #4f7a6c;
}
.theme-garden .beat-card .tag, .theme-garden .slab .tag { color: #f2ecd8; }
.theme-garden .beat-card .tag .d, .theme-garden .slab .tag .d { color: #c8b49a; }
.bed { position: absolute; left: -4vw; right: -4vw; bottom: -6vh; height: 26vh;
  background: linear-gradient(#5a3a20, #3c2513); border-radius: 50% 50% 0 0 / 24% 24% 0 0;
  box-shadow: 0 -10px 34px rgba(0,0,0,.35); }
.bed::before { content: ""; position: absolute; left: 0; right: 0; top: -2.6vh; height: 4.4vh;
  background: radial-gradient(ellipse 8% 100% at 6% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 18% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 30% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 42% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 54% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 66% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 78% 100%, #2f7a4a 60%, transparent 62%),
    radial-gradient(ellipse 8% 100% at 90% 100%, #2f7a4a 60%, transparent 62%); }
.plants { position: absolute; left: 0; right: 0; bottom: 12vh; display: flex; justify-content: center;
  align-items: flex-end; gap: clamp(22px,3vw,60px); z-index: 1; }
.plant { position: relative; display: flex; flex-direction: column; align-items: center; width: clamp(200px,15vw,300px); }
.bloom { width: clamp(190px,14.5vw,280px); aspect-ratio: 16/11; border-radius: 46% 54% 48% 52% / 62% 64% 36% 38%;
  overflow: hidden; border: 4px solid #57b07e; box-shadow: 0 12px 26px rgba(0,0,0,.45); background: #14453a; position: relative; }
.bloom .blur { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(16px) brightness(.55); transform: scale(1.25); }
.bloom .sharp { position: relative; width: 100%; height: 100%; object-fit: contain; display: block; }
.bloom img:not(.blur):not(.sharp) { width: 100%; height: 100%; object-fit: cover; display: block; }
.stem { width: 6px; height: 6vh; background: #3f8f5f; border-radius: 3px; }
.pot { width: 82%; background: linear-gradient(#c96f3f, #9a4d26); clip-path: polygon(5% 0, 95% 0, 84% 100%, 16% 100%);
  padding: 1.8vh 9% 2.6vh; }
.pot-t { color: #fff3e2; font-size: clamp(15px,2vh,20px); font-weight: 800; text-align: center; line-height: 1.2;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.plant.focus { z-index: 2; }
.plant.focus .bloom { border-color: var(--ring); box-shadow: 0 0 0 4px var(--ring), 0 0 50px rgba(255,236,112,.4); }
.firefly { position: absolute; top: -3.4vh; right: 4%; width: clamp(36px,5vh,54px); aspect-ratio: 1; z-index: 2;
  filter: drop-shadow(0 0 12px rgba(255,220,110,.9)); }
.firefly svg path { fill: var(--gold); stroke: #d99e06; stroke-width: 4; }
.seedpacket { width: clamp(112px,8.2vw,160px); aspect-ratio: 3/4; background: #efe2c4; border-radius: 8px;
  transform: rotate(-4deg); display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 1vh; box-shadow: 0 10px 22px rgba(0,0,0,.4); margin-bottom: 1vh; }
.seedpacket span { width: 34px; aspect-ratio: 1; background: #fff; border-radius: 50%; display: grid; place-items: center; }
.seed-t { color: #6b4a2f; font-size: var(--t-card-desc); font-weight: 800; text-align: center; padding: 0 8px; }
.sprout { position: absolute; bottom: 36%; left: 4%; width: 34px; height: 38px; z-index: 2; }
.sprout::before, .sprout::after { content: ""; position: absolute; bottom: 0; width: 16px; height: 22px;
  background: #57b07e; border-radius: 50% 50% 50% 50% / 70% 70% 30% 30%; }
.sprout::before { left: 0; transform: rotate(-24deg); }
.sprout::after { right: 0; transform: rotate(24deg); }
.peekplant { opacity: .55; transform: scale(.72); }
.peekplant .pot-t { display: none; }
.peekplant .pot { padding-bottom: 1.6vh; }
.facebloom { border-radius: 50%; }
.pickerplants { bottom: 17vh; gap: 9vw; }
.pickerplants .plant { width: clamp(240px,30vh,360px); }
.pickerplants .bloom { width: clamp(200px,26vh,320px); }
.pickerplants .pot-t { font-size: var(--t-action); }
.plant.recess { filter: brightness(.78) saturate(.85); }
.jumbobloom { width: clamp(220px,32vh,340px); }
.signposts { display: flex; gap: 3vw; align-items: flex-end; }
.signpost { border: none; font-family: inherit; font-size: var(--t-action); font-weight: 800; cursor: pointer;
  background: #2f7a4a; color: #eafff0; padding: .9em 1.3em; border-radius: 40% 40% 0 0 / 26% 26% 0 0; position: relative; }
.signpost::after { content: ""; display: block; width: 10px; height: 4vh; background: #8a5a30; margin: 0 auto; }
.signpost.focused { background: var(--gold); color: #2e1c0c; box-shadow: 0 0 0 5px var(--ring); }
.fireflies { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(3px 3px at 15% 30%, rgba(255,236,150,.9), transparent 100%),
  radial-gradient(3px 3px at 32% 55%, rgba(255,236,150,.7), transparent 100%),
  radial-gradient(4px 4px at 50% 24%, rgba(255,236,150,.85), transparent 100%),
  radial-gradient(3px 3px at 68% 48%, rgba(255,236,150,.7), transparent 100%),
  radial-gradient(3px 3px at 85% 28%, rgba(255,236,150,.8), transparent 100%),
  radial-gradient(2px 2px at 40% 72%, rgba(255,236,150,.6), transparent 100%),
  radial-gradient(2px 2px at 78% 68%, rgba(255,236,150,.6), transparent 100%); }
.celebloom { width: clamp(220px,30vh,320px); position: relative; }
.firefly.big { width: clamp(52px,7vh,72px); top: -26px; right: -26px; }
.seedrow { display: flex; justify-content: center; gap: clamp(16px,2vw,36px); margin-top: 2.4vh; z-index: 1; }
.packet { background: linear-gradient(#7a5a34, #5f4225); color: #fff3e2; border-radius: 10px; padding: 12px;
  width: clamp(210px,16vw,320px); display: flex; flex-direction: column; gap: 8px;
  box-shadow: 0 12px 24px rgba(0,0,0,.4), inset 0 0 0 3px rgba(0,0,0,.18); }
.packet img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: 6px; }
.packet .t { font-size: var(--t-card-title); font-weight: 800; }
.packet .p { font-size: var(--t-hud); font-weight: 800; color: var(--gold); }
.packet.focused { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 3px; transform: rotate(-1.6deg) translateY(-1vh); }
.packet.locked { filter: saturate(.35) brightness(.88); }
.biglantern .ltag { font-size: var(--t-action); }

.theme-storybook .cele-overlay { box-shadow: inset 0 0 0 14px rgba(246,234,208,.92), inset 0 0 60px rgba(69,46,20,.5); }
.theme-storybook .cele-stamp { background: #f6ead0; border: 3px solid #b8462e; }
.theme-storybook .cele-lower { background: linear-gradient(transparent, rgba(36,16,8,.9) 45%); }
.theme-lantern .cele-overlay { background:
  radial-gradient(8px 12px at 16% 70%, rgba(255,205,120,.85), transparent 100%),
  radial-gradient(6px 10px at 30% 45%, rgba(255,190,100,.7), transparent 100%),
  radial-gradient(9px 13px at 50% 66%, rgba(255,205,120,.8), transparent 100%),
  radial-gradient(6px 10px at 70% 40%, rgba(255,190,100,.65), transparent 100%),
  radial-gradient(8px 12px at 86% 60%, rgba(255,205,120,.75), transparent 100%),
  radial-gradient(5px 8px at 42% 20%, rgba(255,190,100,.5), transparent 100%),
  radial-gradient(5px 8px at 78% 24%, rgba(255,205,120,.55), transparent 100%); }
.theme-blocks .cele-overlay { background:
  linear-gradient(#e2503f,#e2503f) 8% 12% / 54px 34px no-repeat,
  linear-gradient(#ffc72c,#ffc72c) 88% 18% / 46px 30px no-repeat,
  linear-gradient(#2f80ed,#2f80ed) 14% 78% / 50px 32px no-repeat,
  linear-gradient(#37b26c,#37b26c) 84% 74% / 56px 34px no-repeat; opacity: .85; }
.theme-garden .cele-overlay { background:
  radial-gradient(4px 4px at 15% 30%, rgba(255,236,150,.9), transparent 100%),
  radial-gradient(4px 4px at 32% 55%, rgba(255,236,150,.75), transparent 100%),
  radial-gradient(5px 5px at 50% 24%, rgba(255,236,150,.85), transparent 100%),
  radial-gradient(4px 4px at 68% 48%, rgba(255,236,150,.75), transparent 100%),
  radial-gradient(4px 4px at 85% 28%, rgba(255,236,150,.8), transparent 100%),
  radial-gradient(3px 3px at 40% 72%, rgba(255,236,150,.6), transparent 100%),
  radial-gradient(3px 3px at 78% 66%, rgba(255,236,150,.6), transparent 100%),
  radial-gradient(3px 3px at 22% 80%, rgba(255,236,150,.55), transparent 100%); }

/* ============ BOOKSHELF (shared, themed by vars) ============ */
.bs-pickbar { display: flex; align-items: center; gap: clamp(18px,2.4vw,44px); z-index: 1;
  margin-top: clamp(6px,1.4vh,16px); }
.bs-picklabel { font-size: clamp(22px,3.2vh,34px); font-weight: 800; color: var(--cream); }
.bs-pickhint { font-size: clamp(16px,2.2vh,24px); font-weight: 700; color: var(--calm); }
.bs-slots { display: flex; gap: clamp(8px,1vh,14px); }
.bs-slot { width: clamp(30px,4.4vh,46px); aspect-ratio: 1; display: grid; place-items: center; }
.bs-slot svg { width: 100%; height: 100%; }
.bs-slot.filled svg { fill: var(--gold); filter: drop-shadow(0 0 10px var(--gold-glow)); }
.bs-slot.empty svg { fill: transparent; stroke: var(--dim); stroke-width: 7; animation: bspulse 2.2s ease-in-out infinite; }
@keyframes bspulse { 0%,100% { opacity: .45; } 50% { opacity: 1; } }

.bs-case { flex: 1; min-height: 0; width: 100%; display: flex; flex-direction: column;
  justify-content: space-evenly; padding: 0 clamp(40px,6vw,140px); z-index: 1; }
.bs-row { position: relative; }
.bs-rowlabel { font-size: clamp(17px,2.4vh,26px); font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; color: var(--calm); margin-bottom: clamp(4px,.8vh,10px); }
.bs-books { display: flex; align-items: flex-end; gap: clamp(22px,2.6vw,54px);
  padding-left: clamp(6px,1vw,20px); }
.bs-plank { height: clamp(12px,1.8vh,20px); border-radius: 6px; margin-top: -2px;
  background: linear-gradient(var(--lift), var(--ground)); box-shadow: 0 10px 22px rgba(0,0,0,.4); }
.bs-book { position: relative; width: clamp(120px,14.5vh,190px); cursor: default;
  border-radius: var(--item-radius); }
.bs-art { width: 100%; aspect-ratio: 0.68; object-fit: cover; display: block;
  border-radius: var(--item-radius); box-shadow: var(--art-shadow);
  border-left: clamp(5px,.9vh,9px) solid rgba(0,0,0,.28); }
.bs-title { font-size: clamp(14px,2vh,20px); font-weight: 700; line-height: 1.25;
  color: var(--cream); margin-top: clamp(5px,.9vh,10px); max-width: 100%; }
.bs-pick { position: absolute; top: clamp(-12px,-1.6vh,-8px); right: clamp(-12px,-1.6vh,-8px); z-index: 2;
  width: clamp(34px,5vh,52px); aspect-ratio: 1; background: var(--tag-bg); border-radius: 50%;
  display: grid; place-items: center; box-shadow: 0 6px 16px rgba(0,0,0,.35); }
.bs-pick svg { width: 64%; height: 64%; fill: var(--gold); }
.bs-pencil { position: absolute; top: 8%; right: 8%; width: 22%; aspect-ratio: 1; }
.bs-pencil svg { width: 100%; height: 100%; }
.bs-book.sketch .bs-art { filter: saturate(.55) brightness(.92); }
.bs-book.focus { transform: translateY(clamp(-24px,-3.2vh,-14px)) scale(1.07); z-index: 2; }
.bs-book.focus .bs-art { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: clamp(3px,.5vh,5px); }
.bs-book.focus .bs-title { font-weight: 800; }

/* theme flourishes */
.theme-lantern .bs-plank { background: linear-gradient(90deg, transparent, rgba(255,214,130,.5) 18%, rgba(255,214,130,.5) 82%, transparent);
  box-shadow: 0 0 26px rgba(255,196,90,.3); height: clamp(4px,.7vh,8px); }
.theme-lantern .bs-rowlabel { color: var(--gold); text-shadow: 0 0 12px rgba(255,210,77,.45); }
.theme-lantern .bs-book.focus .bs-art { box-shadow: 0 0 0 3px rgba(255,214,130,.5), 0 0 44px rgba(255,196,90,.45), 0 18px 30px rgba(0,0,0,.5); }
.theme-storybook .bs-plank { border-radius: 2px; }
.theme-blocks .bs-plank { border-radius: 0; }

/* bookshelf v2 - fit all three rows, bigger books */
.bs-pickbar { margin-top: clamp(2px,.6vh,8px); gap: clamp(14px,1.8vw,34px); }
.bs-picklabel { font-size: clamp(19px,2.6vh,28px); }
.bs-pickhint { font-size: clamp(16px,2.2vh,22px); }
.bs-slot { width: clamp(26px,3.6vh,38px); }
.bs-case { justify-content: space-evenly; padding: 0 clamp(30px,4.5vw,110px); }
.bs-rowlabel { font-size: clamp(16px,2.2vh,24px); margin-bottom: clamp(2px,.5vh,6px); }
.bs-books { gap: clamp(26px,3.4vw,68px); }
.bs-book { width: auto; }
.bs-art { height: clamp(140px,19.5vh,240px); width: auto; aspect-ratio: 0.68; }
.bs-title { font-size: clamp(12px,1.55vh,17px); margin-top: clamp(3px,.6vh,7px); max-width: 15ch; }
.bs-plank { height: clamp(9px,1.4vh,15px); }
.bs-book.focus { transform: translateY(clamp(-18px,-2.4vh,-10px)) scale(1.06); }
.bs-book.focus .bs-art { outline-width: clamp(3px,.5vh,5px); }
.bs-stack { align-self: flex-end; display: flex; flex-direction: column-reverse; gap: clamp(4px,.7vh,8px);
  margin-left: clamp(8px,1vw,20px); padding-bottom: 2px; }
.bs-stack span { display: block; height: clamp(13px,1.9vh,20px); border-radius: 4px;
  background: linear-gradient(90deg, var(--lift), var(--dim)); box-shadow: 0 4px 10px rgba(0,0,0,.35); }
.bs-stack span:nth-child(1) { width: clamp(90px,11vh,140px); }
.bs-stack span:nth-child(2) { width: clamp(70px,9vh,115px); }
.bs-stack span:nth-child(3) { width: clamp(100px,12vh,150px); }
.bs-stack.two span:nth-child(1) { width: clamp(85px,10vh,130px); }
.theme-lantern .bs-stack span { background: linear-gradient(90deg, #241d52, #4a3f8a); box-shadow: 0 0 16px rgba(120,100,220,.3); }

/* bookshelf v3 - fit budget */
.screen[data-screen="bookshelf"] { padding-top: clamp(14px,2.6vh,34px); padding-bottom: clamp(10px,1.8vh,24px); }
.screen[data-screen="bookshelf"] .title-shelf { font-size: clamp(26px,4.2vh,46px); }
.screen[data-screen="bookshelf"] .bs-case { justify-content: flex-start; gap: clamp(12px,2.2vh,26px); padding-top: clamp(6px,1vh,14px); }
.screen[data-screen="bookshelf"] .bs-art { height: clamp(150px,19vh,230px); }
.screen[data-screen="bookshelf"] .bs-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 14ch; }
.screen[data-screen="bookshelf"] .bs-rowlabel { margin-bottom: clamp(2px,.4vh,5px); }

/* bookshelf v4 - final fit */
.screen[data-screen="bookshelf"] .bs-art { height: clamp(140px,17vh,200px); }
.screen[data-screen="bookshelf"] .bs-case { gap: clamp(8px,1.6vh,18px); }
.screen[data-screen="bookshelf"] .bs-rowlabel { font-size: clamp(15px,2vh,21px); }
.screen[data-screen="bookshelf"] .bs-plank { height: clamp(8px,1.1vh,12px); margin-top: clamp(2px,.4vh,5px); }
.screen[data-screen="bookshelf"] .bs-title { font-size: clamp(14px,1.9vh,19px); }
.screen[data-screen="bookshelf"] .hud { margin-top: clamp(2px,.5vh,6px); }
.screen[data-screen="bookshelf"] .bs-art { height: clamp(135px,16.2vh,190px); }
.screen[data-screen="bookshelf"] .bs-case { padding-top: 0; }
.screen[data-screen="bookshelf"] .bs-pickbar { margin-top: 0; }

/* bookshelf-pick fit: all three rows + focus inside viewport */
.screen[data-screen="bookshelf-pick"] { padding-top: clamp(10px,1.8vh,24px); padding-bottom: clamp(8px,1.4vh,18px); }
.screen[data-screen="bookshelf-pick"] .title-shelf { font-size: clamp(24px,3.6vh,40px); }
.screen[data-screen="bookshelf-pick"] .bs-pickbar { margin-top: 0; }
.screen[data-screen="bookshelf-pick"] .bs-case { justify-content: flex-start; gap: clamp(6px,1.2vh,14px); }
.screen[data-screen="bookshelf-pick"] .bs-rowlabel { margin-bottom: clamp(1px,.3vh,3px); }
.screen[data-screen="bookshelf-pick"] .bs-art { height: clamp(95px,13vh,165px); }
.screen[data-screen="bookshelf-pick"] .bs-plank { height: clamp(8px,1.1vh,12px); margin-top: clamp(2px,.4vh,5px); }

/* picture-quiz: pre-reader option cards */
.quizpic-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px,2.4vh,26px); margin-top: var(--gap-screen); z-index: 1;
  width: min(50vw, 84vh); gap: clamp(12px,2vh,22px); margin-top: clamp(10px,1.6vh,18px); }
.quizpic-card { border: none; background: var(--card, #fff); border-radius: var(--card-radius); cursor: pointer;
  padding: clamp(10px,1.6vh,18px); display: flex; flex-direction: column; align-items: center; gap: clamp(6px,1vh,12px);
  box-shadow: var(--art-shadow); }
.quizpic-art { width: 100%; aspect-ratio: 3/2; border-radius: calc(var(--card-radius) * .6); display: grid; place-items: center;
  background: var(--lift); position: relative; }
.quizpic-art svg { width: 34%; fill: var(--dim); opacity: .5; }
.quizpic-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.quizpic-art[data-hint]::after { content: "art coming: " attr(data-hint); position: absolute; bottom: 8%; font-size: clamp(12px,1.6vh,17px);
  color: var(--dim); font-weight: 600; }
.quizpic-word { font-size: var(--t-card-title); font-weight: 800; color: var(--ink, #2a1f10); text-align: center; }
.quizpic-card.focused { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 4px; }

/* quizpic fit: title smaller so the picture grid owns the screen */
.screen.quizpic .title-screen { font-size: clamp(28px,4.4vh,50px); max-width: 22em; margin-left: auto; margin-right: auto; }
.theme-inkverse .screen.quizpic .quizpic-grid { width: min(46vw, 74vh); }
/* quizpic focus: bold themes get their own mechanisms (design-checker r2 finding) */
.theme-inkverse .quizpic-card.focused { outline: none; box-shadow: rgb(42,111,242) 7px 7px 0 0; transform: rotate(-1.2deg); }
.theme-chalkboard .quizpic-card.focused { outline: none; box-shadow: 0 0 24px rgba(255,224,102,.45), 0 0 4px rgba(255,224,102,.85); }

/* ============ AWARDS WALL (shared, themed by vars) ============ */
.aw-wrap { flex: 1; min-height: 0; width: 100%; display: flex; gap: clamp(28px,3.4vw,70px);
  padding: 0 clamp(30px,4vw,90px); z-index: 1; align-items: stretch; }
.aw-hero { flex: 0 0 34%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(6px,1vh,12px); }
.aw-hero-label { font-size: clamp(16px,2.2vh,24px); font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--calm); }
.aw-medal { width: clamp(90px,15vh,170px); aspect-ratio: 1; background: var(--tag-bg); border-radius: 50%;
  display: grid; place-items: center; box-shadow: 0 0 0 clamp(5px,.8vh,8px) var(--gold), 0 0 44px var(--gold-glow), 0 18px 34px rgba(0,0,0,.4); }
.aw-medal svg { width: 58%; height: 58%; fill: var(--gold); }
.aw-hero-name { font-size: clamp(30px,4.6vh,50px); font-weight: 800; color: var(--gold);
  text-shadow: 0 0 22px var(--gold-glow); text-align: center; line-height: 1.05; }
.aw-hero-sub { font-size: clamp(16px,2.2vh,24px); font-weight: 600; color: var(--calm); }
.aw-nudge { margin-top: clamp(8px,1.6vh,18px); background: var(--lift); border-radius: var(--card-radius);
  padding: clamp(12px,1.9vh,22px) clamp(18px,2.4vh,30px); width: 100%; text-align: center;
  box-shadow: 0 14px 30px rgba(0,0,0,.35); }
.aw-nudge-t { font-size: clamp(16px,2.2vh,24px); font-weight: 700; color: var(--cream); }
.aw-nudge-big { font-size: clamp(22px,3.4vh,36px); font-weight: 800; color: var(--gold); margin: 2px 0 8px; }
.aw-nudge-n { font-size: clamp(15px,2vh,21px); font-weight: 700; color: var(--calm); margin-top: 6px; }
.aw-bar { height: clamp(8px,1.2vh,12px); border-radius: 99px; background: rgba(0,0,0,.35); overflow: hidden; }
.aw-bar.big { height: clamp(10px,1.5vh,15px); }
.aw-fill { height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--primary), var(--gold));
  box-shadow: 0 0 12px var(--gold-glow); }
.aw-streaks { display: flex; gap: clamp(10px,1.4vw,22px); margin-top: clamp(8px,1.4vh,16px); width: 100%; }
.aw-streak { flex: 1; display: flex; align-items: center; gap: clamp(8px,1.2vh,14px);
  background: var(--lift); border-radius: var(--item-radius); padding: clamp(8px,1.2vh,14px) clamp(10px,1.6vh,18px); }
.aw-streak-ico { font-size: clamp(22px,3.4vh,36px); }
.aw-streak-n { font-size: clamp(15px,2vh,21px); font-weight: 800; color: var(--gold); }
.aw-streak-d { font-size: clamp(14px,1.9vh,18px); font-weight: 600; color: var(--calm); }
.aw-ladders { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-evenly; }
.aw-row { display: flex; align-items: center; gap: clamp(12px,1.6vw,28px);
  background: var(--lift); border-radius: var(--item-radius); padding: clamp(7px,1.1vh,13px) clamp(12px,1.8vh,22px); }
.aw-ico { font-size: clamp(20px,3vh,32px); width: 1.4em; text-align: center; }
.aw-main { flex: 1; min-width: 0; }
.aw-cat { font-size: clamp(15px,2vh,21px); font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--calm); }
.aw-rungs { display: flex; align-items: baseline; gap: .5em; flex-wrap: nowrap; overflow: hidden;
  font-size: clamp(15px,2.1vh,22px); margin: 1px 0 5px; }
.aw-rung { font-weight: 600; color: var(--dim); white-space: nowrap; }
.aw-rung.done { color: var(--calm); text-decoration: line-through; text-decoration-thickness: 2px; }
.aw-rung.cur { font-weight: 800; color: var(--gold); }
.aw-sep { color: var(--dim); font-size: .8em; }
.aw-next { font-size: clamp(14px,1.9vh,19px); font-weight: 600; color: var(--calm); text-align: right; line-height: 1.25; }
.aw-next b { color: var(--gold); font-weight: 800; }
.theme-lantern .aw-medal { box-shadow: 0 0 0 clamp(5px,.8vh,8px) var(--gold), 0 0 60px rgba(255,210,90,.5), 0 18px 34px rgba(0,0,0,.5); }
.theme-lantern .aw-row, .theme-lantern .aw-nudge, .theme-lantern .aw-streak { box-shadow: 0 0 20px rgba(120,100,220,.22), 0 10px 22px rgba(0,0,0,.35); }

/* svg icons inherit gold */
.aw-ico svg, .aw-streak-ico svg { width: 1em; height: 1em; fill: var(--gold); filter: drop-shadow(0 0 8px var(--gold-glow)); }
.aw-streak-ico svg { width: 1.1em; height: 1.1em; }

/* bookshelf v5 - Vihaan folds: locked-book stacks, whole-word titles */
.bs-stack { flex-direction: row; align-items: flex-end; gap: clamp(10px,1.4vh,16px); }
.bs-soon { width: clamp(60px,7.6vh,100px); aspect-ratio: 0.68; border-radius: var(--item-radius);
  border: clamp(2px,.35vh,4px) dashed var(--dim); display: grid; place-items: center;
  background: rgba(255,255,255,.04); opacity: .85; }
.bs-soon-star { width: 42%; aspect-ratio: 1; }
.bs-soon-star svg { width: 100%; height: 100%; fill: var(--dim); }
.screen[data-screen="bookshelf"] .bs-title { max-width: 16.5ch; word-break: normal; overflow-wrap: break-word; }
.screen[data-screen="bookshelf"] .bs-book:not(.focus) .bs-title { -webkit-line-clamp: 1; white-space: nowrap; text-overflow: ellipsis; }
.screen[data-screen="bookshelf"] .bs-book.focus .bs-title { -webkit-line-clamp: 3; font-size: clamp(13px,1.8vh,19px); }

/* bookshelf v6 - Inaaya folds: fill the shelf, whole-word titles */
.screen[data-screen="bookshelf"] .bs-books { justify-content: space-evenly; gap: clamp(14px,1.8vw,40px); padding-left: 0; }
.screen[data-screen="bookshelf"] .bs-book:not(.focus) .bs-title { -webkit-line-clamp: 2; white-space: normal; max-width: 100%; }
.screen[data-screen="bookshelf"] .bs-title { max-width: 100%; }
/* bookshelf v7 - pick badge pinned onto the cover, not floating */
.bs-pick { top: clamp(5px,.9vh,10px); right: clamp(5px,.9vh,10px); }

/* ==================== SPRINT 3 BOLD THEME 3: INKVERSE (comic ink + halftone; Spider-Verse anchor) ==================== */
.theme-inkverse {
  --ground: #f3e9cf; --lift: #fff8e2; --cream: #1a1408; --ink: #1a1408; --dim: #8a7c5c;
  --tag-bg: #ffd12f; --tag-radius: 6px; --item-radius: 8px;
  --accent-red: #e63946; --accent-blue: #2a6ff2; --accent-y: #ffd12f;
}
/* owned-marker gold absorbed from production (PM ruling 2026-09-14); body-scoped so a tile's
   inner world-theme frame (.wp-frame.theme-*) does not capture it - the ring/suffix is skin chrome */
body.theme-inkverse { --gold: #e0a800; }
.theme-inkverse .sky { background:
  radial-gradient(circle at 18% 12%, rgba(230,57,70,.14), transparent 42%),
  radial-gradient(circle at 85% 82%, rgba(42,111,242,.12), transparent 46%),
  linear-gradient(var(--lift), var(--ground)); }
.theme-inkverse .sky::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(26,20,8,.14) 1.2px, transparent 1.7px); background-size: 9px 9px; }
.theme-inkverse .title-screen, .theme-inkverse .title-shelf { text-transform: uppercase; letter-spacing: .02em;
  color: var(--cream); text-shadow: 3px 3px 0 var(--accent-y), 6px 6px 0 rgba(26,20,8,.85); }
.theme-inkverse .slab, .theme-inkverse .item, .theme-inkverse .beat-card {
  background: #fffdf2; border: 4px solid #1a1408; border-radius: 8px; box-shadow: 7px 7px 0 #1a1408; }
.theme-inkverse .carousel .slab:nth-child(odd) { transform: rotate(-1.5deg); }
.theme-inkverse .carousel .slab:nth-child(even) { transform: rotate(1.3deg); }
.theme-inkverse .slab.focus { transform: rotate(0deg) scale(1.05); box-shadow: 0 0 0 4px #1a1408, 12px 12px 0 var(--accent-red); }
.theme-inkverse .stamp { background: repeating-conic-gradient(#ffd12f 0 12deg, #ffb703 12deg 24deg); border: 3px solid #1a1408; color: #1a1408; }
.theme-inkverse .btn { border: 3px solid #1a1408; border-radius: 8px; box-shadow: 4px 4px 0 #1a1408; text-transform: uppercase; }
.theme-inkverse .btn-primary { background: var(--accent-red); color: #fff8e2; }
.theme-inkverse .btn-door { background: #fffdf2; color: #1a1408; }
.theme-inkverse .btn.focused { box-shadow: 0 0 0 3px #1a1408, 7px 7px 0 var(--accent-blue); }
.theme-inkverse .quiz-grid .btn-door:nth-child(odd) { transform: rotate(-.8deg); }
.theme-inkverse .quiz-grid .btn-door:nth-child(even) { transform: rotate(.8deg); }
.theme-inkverse .pebble { background: repeating-conic-gradient(#ffd12f 0 14deg, #ff9f1c 14deg 28deg); border: 4px solid #1a1408; box-shadow: 6px 6px 0 #1a1408; }
.theme-inkverse .kidbtn.focus .pebble { box-shadow: 0 0 0 5px #1a1408, 10px 10px 0 var(--accent-red); }
.theme-inkverse .screen[data-screen="picker"] .kidbtn.focus { outline: none; box-shadow: rgb(42,111,242) 7px 7px 0 0; }
.theme-inkverse .screen[data-screen="picker"] .kidbtn .stage-ledge { background: #1a1408; border-radius: 6px; }
.theme-inkverse .nametag { border: 3px solid #1a1408; box-shadow: 4px 4px 0 #1a1408;
  background: var(--cream); color: var(--lift); } /* row-359 parity (VD styles.css v2 declared delta, integrated onto current upstream): production paper-on-ink (ink block + paper text); mock --lift == production --ground-lift #fff8e2 */
.theme-inkverse .wallet, .theme-inkverse .hud .chip, .theme-inkverse .switcher { background: #fffdf2; border: 3px solid #1a1408; box-shadow: 3px 3px 0 #1a1408; color: #1a1408; }
.theme-inkverse .facts, .theme-inkverse .calm, .theme-inkverse .wallet-line, .theme-inkverse .comeback { color: #4a3f28; }
.theme-inkverse .bs-plank { background: #1a1408; height: 5px; box-shadow: 0 5px 0 rgba(26,20,8,.22); }
.theme-inkverse .bs-rowlabel { background: #1a1408; color: var(--accent-y); padding: .3vh 1.2vh; border-radius: 4px; transform: rotate(-1deg); display: inline-block; width: fit-content; text-transform: uppercase; }
.theme-inkverse .bs-pick { background: repeating-conic-gradient(#ffd12f 0 12deg, #ffb703 12deg 24deg); border: 3px solid #1a1408; color: #1a1408; }
.theme-inkverse .bs-book.focus .bs-art { box-shadow: 0 0 0 4px #1a1408, 10px 10px 0 var(--accent-blue); }
.theme-inkverse .bs-soon { border-color: #1a1408; background: rgba(26,20,8,.04); }
.theme-inkverse .bs-slot { border-color: #1a1408; }
.theme-inkverse .aw-row { background: #fffdf2; border: 3px solid #1a1408; box-shadow: 5px 5px 0 #1a1408; color: #1a1408; }
.theme-inkverse .aw-cat { color: var(--accent-red); }
.theme-inkverse .aw-rung { color: #4a3f28; }
.theme-inkverse .aw-rung.cur { color: #1a1408; background: var(--accent-y); border: 2px solid #1a1408; }
.theme-inkverse .aw-next { color: #4a3f28; }
.theme-inkverse .aw-bar { background: rgba(26,20,8,.12); border: 2px solid #1a1408; }
.theme-inkverse .aw-fill { background: linear-gradient(90deg, var(--accent-red), #ff7a3d); }
.theme-inkverse .aw-medal { background: repeating-conic-gradient(#ffd12f 0 12deg, #ffb703 12deg 24deg); border: 5px solid #1a1408; box-shadow: 8px 8px 0 #1a1408; color: #1a1408; }
.theme-inkverse .aw-hero-name { color: #1a1408; text-shadow: 3px 3px 0 var(--accent-y); }
.theme-inkverse .aw-hero-label, .theme-inkverse .aw-hero-sub, .theme-inkverse .aw-nudge-n { color: #4a3f28; }
.theme-inkverse .aw-nudge, .theme-inkverse .aw-streak { background: #fffdf2; border: 3px solid #1a1408; box-shadow: 4px 4px 0 #1a1408; }
.theme-inkverse .aw-nudge-big { color: var(--accent-red); text-shadow: 2px 2px 0 #1a1408; }
.theme-inkverse .aw-streak-ico { background: var(--accent-y); border: 2px solid #1a1408; }
.theme-inkverse .aw-streak-n { color: #1a1408; } .theme-inkverse .aw-streak-d { color: #4a3f28; }
.theme-inkverse .cele-tintlayer { background: transparent; }
.theme-inkverse .cele-overlay { background: radial-gradient(circle at 50% 38%, rgba(255,209,47,.5), rgba(243,233,207,.92) 72%); }
.theme-inkverse .powring { position: absolute; left: 50%; top: 36%; width: 48vh; height: 48vh; translate: -50% -50%;
  background: repeating-conic-gradient(#e63946 0 9deg, #ffd12f 9deg 18deg); border-radius: 50%; border: 6px solid #1a1408; }
.theme-inkverse .cele-stamp.pow { z-index: 2; background: #fffdf2; border: 5px solid #1a1408; box-shadow: 8px 8px 0 #1a1408; color: #1a1408; }
.theme-inkverse .cele-lower { background: linear-gradient(transparent, rgba(243,233,207,.96) 42%); }
.theme-inkverse .cele-lower .title-screen { color: #1a1408; }
.theme-inkverse .cele-stars { color: var(--accent-red); -webkit-text-stroke: 1px #1a1408; }
.theme-inkverse .cele-lower .calm { color: #4a3f28; }

/* ==================== SPRINT 3 BOLD THEME 4: CHALKBOARD (playground chalk wall; stamp-slam harvested) ==================== */
.theme-chalkboard {
  --ground: #23282e; --lift: #2f363e; --cream: #f4efe0; --ink: #20242a; --dim: #7d8894;
  --tag-bg: #f4efe0; --tag-radius: 14px 5px 16px 6px; --item-radius: 18px 7px 20px 8px;
  --chalk-pink: #ff9ecb; --chalk-y: #ffe066; --chalk-b: #7ec8ff; --chalk-g: #a8e6a3;
}
body.theme-chalkboard { --gold: #ffe066; }
.theme-chalkboard .sky { background:
  radial-gradient(ellipse at 28% 18%, rgba(255,255,255,.06), transparent 52%),
  radial-gradient(ellipse at 76% 78%, rgba(255,255,255,.045), transparent 46%),
  linear-gradient(#2b323a, #21262c); }
.theme-chalkboard .sky::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(244,239,224,.05) 1px, transparent 1.6px); background-size: 7px 7px; }
.theme-chalkboard .title-screen, .theme-chalkboard .title-shelf { color: var(--cream); text-shadow: 0 0 7px rgba(244,239,224,.45), 2px 2px 0 rgba(0,0,0,.35); }
.theme-chalkboard .slab, .theme-chalkboard .item, .theme-chalkboard .beat-card {
  border: 3px solid rgba(244,239,224,.85); border-radius: 20px 7px 22px 9px/9px 24px 8px 20px;
  background: rgba(244,239,224,.07); box-shadow: 0 0 0 1px rgba(244,239,224,.14), 0 12px 26px rgba(0,0,0,.4); }
.theme-chalkboard .slab.focus { border-color: var(--chalk-y); box-shadow: 0 0 0 2px rgba(255,224,102,.5), 0 0 30px rgba(255,224,102,.4); }
.theme-chalkboard .stamp { background: transparent; border: 3px solid var(--chalk-g); }
.theme-chalkboard .stamp svg path, .theme-chalkboard .stamp svg { fill: none; stroke: var(--chalk-g); stroke-width: 1.8; }
.theme-chalkboard .btn { border: 3px solid rgba(244,239,224,.85); border-radius: 22px 8px 24px 10px/10px 26px 9px 22px; background: transparent; color: var(--cream); }
.theme-chalkboard .btn-primary { background: var(--chalk-pink); border-color: var(--chalk-pink); color: #20242a; }
.theme-chalkboard .btn.focused { background: var(--chalk-y); border-color: var(--chalk-y); color: #20242a; box-shadow: 0 0 24px rgba(255,224,102,.45); }
.theme-chalkboard .btn-primary.focused { background: var(--chalk-y); border-color: var(--chalk-y); }
.theme-chalkboard .pebble { border: 4px dashed rgba(244,239,224,.8); background: rgba(244,239,224,.08); }
.theme-chalkboard .kidbtn.focus .pebble { border-style: solid; border-color: var(--chalk-y); box-shadow: 0 0 26px rgba(255,224,102,.45); }
.theme-chalkboard .screen[data-screen="picker"] .kidbtn.focus { outline: none; box-shadow: 0 0 24px rgba(255,224,102,.45); }
.theme-chalkboard .screen[data-screen="picker"] .kidbtn .stage-ledge { background: rgba(244,239,224,.14); border: 2px dashed rgba(244,239,224,.7); }
.theme-chalkboard .nametag { border: 2px solid rgba(244,239,224,.6); border-radius: 14px 5px 16px 6px; }
.theme-chalkboard .wallet, .theme-chalkboard .hud .chip, .theme-chalkboard .switcher { border: 2px solid rgba(244,239,224,.6); border-radius: 16px 6px 18px 7px; background: rgba(244,239,224,.08); color: var(--cream); }
.theme-chalkboard .facts, .theme-chalkboard .calm, .theme-chalkboard .wallet-line, .theme-chalkboard .comeback { color: #b9c2cc; }
.theme-chalkboard .bs-plank { background: repeating-linear-gradient(90deg, rgba(244,239,224,.75) 0 26px, transparent 26px 40px); height: 4px; box-shadow: none; }
.theme-chalkboard .bs-rowlabel { color: var(--chalk-b); text-decoration: underline wavy rgba(126,200,255,.55) 2px; text-underline-offset: 6px; }
.theme-chalkboard .bs-pick { background: transparent; border: 3px solid var(--chalk-y); color: var(--chalk-y); }
.theme-chalkboard .bs-book.focus .bs-art { box-shadow: 0 0 0 3px rgba(255,224,102,.6), 0 0 34px rgba(255,224,102,.4); }
.theme-chalkboard .bs-soon { border-color: rgba(244,239,224,.45); }
.theme-chalkboard .bs-slot { border-color: rgba(244,239,224,.5); }
.theme-chalkboard .aw-row { background: rgba(244,239,224,.06); border: 3px solid rgba(244,239,224,.7); border-radius: 18px 6px 20px 8px/8px 22px 7px 18px; }
.theme-chalkboard .aw-cat { color: var(--chalk-b); }
.theme-chalkboard .aw-rung.cur { color: #20242a; background: var(--chalk-y); }
.theme-chalkboard .aw-bar { background: rgba(244,239,224,.14); border: 2px solid rgba(244,239,224,.35); }
.theme-chalkboard .aw-fill { background: linear-gradient(90deg, var(--chalk-b), var(--chalk-pink)); }
.theme-chalkboard .aw-medal { background: transparent; border: 4px dashed var(--chalk-y); color: var(--chalk-y); box-shadow: 0 0 30px rgba(255,224,102,.35); }
.theme-chalkboard .aw-hero-name { color: var(--chalk-y); text-shadow: 0 0 14px rgba(255,224,102,.5); }
.theme-chalkboard .aw-nudge, .theme-chalkboard .aw-streak { background: rgba(244,239,224,.07); border: 3px solid rgba(244,239,224,.65); border-radius: 18px 6px 20px 8px; }
.theme-chalkboard .aw-nudge-big { color: var(--chalk-pink); text-shadow: 0 0 12px rgba(255,158,203,.5); }
.theme-chalkboard .aw-streak-ico { background: transparent; border: 2px solid rgba(244,239,224,.6); }
.theme-chalkboard .cele-overlay { background: radial-gradient(circle at 50% 40%, rgba(35,40,46,.2), rgba(20,24,28,.92) 78%); }
.theme-chalkboard .chalkdust { position: absolute; inset: 0;
  background-image: radial-gradient(rgba(244,239,224,.32) 1.6px, transparent 2.2px), radial-gradient(rgba(255,224,102,.28) 1.1px, transparent 1.7px);
  background-size: 92px 92px, 57px 57px; background-position: 0 0, 31px 46px; }
.theme-chalkboard .cele-stamp.chalktick { background: transparent; border: none; box-shadow: none; width: 42vh; height: 34vh; }
.theme-chalkboard .cele-stamp.chalktick svg { width: 100%; height: 100%; filter: drop-shadow(0 0 20px rgba(244,239,224,.55)); }
.theme-chalkboard .cele-stars { color: var(--chalk-y); text-shadow: 0 0 16px rgba(255,224,102,.6); }

/* ---- sprint3 iteration 2: inkverse celebration composition + chalkboard chalk-bold pass ---- */
.theme-inkverse .powring { left: 50%; top: 34%; width: 52vh; height: 52vh; }
.theme-inkverse .cele-stamp.pow { top: 34%; left: 50%; translate: -50% -50%; width: 24vh; height: 24vh; }
.theme-inkverse .cele-overlay { background: radial-gradient(circle at 50% 36%, rgba(255,209,47,.42), rgba(243,233,207,.82) 74%); }
.theme-chalkboard .slab, .theme-chalkboard .bs-book .bs-art, .theme-chalkboard .item, .theme-chalkboard .beat-card { border-width: 5px; }
.theme-chalkboard .carousel .slab:nth-child(3n+1) { border-color: var(--chalk-pink); }
.theme-chalkboard .carousel .slab:nth-child(3n+2) { border-color: var(--chalk-y); }
.theme-chalkboard .carousel .slab:nth-child(3n) { border-color: var(--chalk-b); }
.theme-chalkboard .carousel .slab.focus { border-color: #fff; box-shadow: 0 0 0 3px rgba(255,224,102,.8), 0 0 38px rgba(255,224,102,.55); }
.theme-chalkboard .ledge { background: repeating-linear-gradient(90deg, rgba(244,239,224,.7) 0 30px, transparent 30px 46px); height: 5px; border-radius: 3px; box-shadow: none; }
.theme-chalkboard .title-screen::after, .theme-chalkboard .title-shelf::after { content: ""; display: block; width: 34%; height: 5px; margin: 1vh auto 0;
  background: repeating-linear-gradient(90deg, var(--chalk-pink) 0 14px, transparent 14px 20px); border-radius: 3px; opacity: .85; }
.theme-chalkboard .cele-stamp.chalktick { background: transparent; border: none; box-shadow: none; width: 40vh; height: 32vh; top: 32%; }
.theme-chalkboard .tickarm { position: absolute; left: 50%; top: 50%; width: 26vh; height: 9vh;
  border-left: 9vh solid transparent; border-bottom: none; }
.theme-chalkboard .tickarm::before { content: ""; position: absolute; left: -19vh; top: 4.5vh; width: 15vh; height: 5.5vh;
  background: var(--chalk-g); border-radius: 4vh; transform: rotate(42deg); box-shadow: 0 0 22px rgba(168,230,163,.6); }
.theme-chalkboard .tickarm::after { content: ""; position: absolute; left: -8.5vh; top: -7.5vh; width: 26vh; height: 5.5vh;
  background: var(--chalk-g); border-radius: 4vh; transform: rotate(-52deg); box-shadow: 0 0 22px rgba(168,230,163,.6); }

/* ---- sprint3 iteration 3: joined chalk tick ---- */
.theme-chalkboard .tickarm { width: 17vh; height: 27vh; border: none;
  border-left: 6vh solid var(--chalk-g); border-bottom: 6vh solid var(--chalk-g);
  border-radius: 0 0 0 3.5vh; transform: rotate(-45deg); translate: -50% -62%; filter: drop-shadow(0 0 18px rgba(168,230,163,.65)); }
.theme-chalkboard .tickarm::before, .theme-chalkboard .tickarm::after { content: none; }

/* ---- sprint3 Vihaan folds: global truncation, inkverse sky burst, chalk doodles AROUND cards ---- */
/* 1. global: whole-word tag titles, full title on focus (all themes) */
.slab .tag .t, .beat-card .tag .t { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; word-break: normal; overflow-wrap: break-word; }
.slab.focus .tag .t, .beat-card.focus .tag .t { -webkit-line-clamp: 4; }
/* 2. inkverse shelf: WHAM burst fills the dead paper */
.theme-inkverse .screen[data-screen="shelf"]::before { content: "WHAM!"; position: absolute; top: 13%; right: 7%;
  font-weight: 800; font-size: 6.5vh; color: #fffdf2; letter-spacing: .03em;
  background: repeating-conic-gradient(#2a6ff2 0 10deg, #ffd12f 10deg 20deg);
  border: 5px solid #1a1408; border-radius: 50%; padding: 7vh 3.5vh; transform: rotate(9deg);
  box-shadow: 6px 6px 0 #1a1408; text-shadow: 2px 2px 0 #1a1408; z-index: 1; }
/* 3. chalkboard: frames mat AROUND the photo, doodles between cards */
.theme-chalkboard .slab, .theme-chalkboard .bs-book .bs-art, .theme-chalkboard .item, .theme-chalkboard .beat-card { padding: clamp(8px,1.2vh,14px); background: #23282e; }
.theme-chalkboard .slab .art { border-radius: 10px 4px 12px 5px; }
.theme-chalkboard .carousel .slab { position: relative; }
.theme-chalkboard .carousel .slab:nth-child(odd)::after { content: ""; position: absolute; top: -3.2vh; right: -1.2vh; width: 4.5vh; height: 4.5vh;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2l2.4 6.6 7 .3-5.5 4.4 1.9 6.7L12 16.2 6.2 20l1.9-6.7L2.6 8.9l7-.3z" fill="none" stroke="%23ffe066" stroke-width="1.8" stroke-linejoin="round"/></svg>') center/contain no-repeat; opacity: .9; }
.theme-chalkboard .carousel .slab:nth-child(even)::after { content: ""; position: absolute; bottom: -2.6vh; left: -1.6vh; width: 7vh; height: 2.6vh;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 14"><path d="M2 7 C 10 -2, 18 16, 26 7 S 36 4, 38 7" fill="none" stroke="%23ff9ecb" stroke-width="2.4" stroke-linecap="round"/></svg>') center/contain no-repeat; opacity: .85; }
/* 4. chalkboard wall: playground doodles in the sky (stars, spiral, rocket, hopscotch) */
.theme-chalkboard .sky::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background:
   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2l2.4 6.6 7 .3-5.5 4.4 1.9 6.7L12 16.2 6.2 20l1.9-6.7L2.6 8.9l7-.3z" fill="none" stroke="%23f4efe0" stroke-width="1.4" stroke-linejoin="round"/></svg>') 8% 22%/5.5vh no-repeat,
   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2l2.4 6.6 7 .3-5.5 4.4 1.9 6.7L12 16.2 6.2 20l1.9-6.7L2.6 8.9l7-.3z" fill="none" stroke="%237ec8ff" stroke-width="1.4" stroke-linejoin="round"/></svg>') 90% 14%/4.5vh no-repeat,
   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30"><path d="M15 15 m0 -2 a2 2 0 1 1 -0.1 0 M15 15 m0 -5 a5 5 0 1 1 -0.1 0 M15 15 m0 -8.5 a8.5 8.5 0 1 1 -0.1 0" fill="none" stroke="%23ff9ecb" stroke-width="1.6"/></svg>') 78% 68%/7vh no-repeat,
   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 34"><path d="M12 2 C 17 8, 17 18, 12 24 C 7 18, 7 8, 12 2 z M12 24 l-4 6 M12 24 l4 6 M9 10 a3 3 0 1 1 -0.1 0" fill="none" stroke="%23a8e6a3" stroke-width="1.6" stroke-linecap="round"/></svg>') 14% 72%/6vh no-repeat,
   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 44"><path d="M2 2 h26 v9 h-26 z M2 11 v9 h13 v-9 M15 20 h13 v9 h-26 v-9 M2 29 v11 h26" fill="none" stroke="%23f4efe0" stroke-width="1.5"/></svg>') 88% 86%/8vh no-repeat; }

/* ---- sprint3 gate folds round 2 (Vihaan+Inaaya template-level) ---- */
/* T1: 5th card fully visible - no clipping; T3: fill the dead band with taller cards */
.carousel { gap: clamp(12px,1.4vw,28px); margin-bottom: 13vh; padding: 0 1vw; box-sizing: border-box; }
.slab { width: clamp(300px,21vw,440px); }
.slab .art { aspect-ratio: 4/3; }
.slab.peek { width: clamp(110px,8vw,170px); }
.slab.peek .art { width: clamp(300px,21vw,440px); }
/* T5: inkverse subtitle contrast */
.theme-inkverse .slab .tag .d { color: #5a4a20; }
/* T6: inkverse celebration = brightest screen */
.theme-inkverse .cele-overlay { background: radial-gradient(circle at 50% 36%, rgba(255,209,47,.16), rgba(243,233,207,.5) 80%); }
/* T7: chalkboard tick redrawn in chalk, accent position - the star-in-bowl stays the hero */
.theme-chalkboard .cele-stamp.chalktick { width: 24vh; height: 20vh; top: 16%; left: auto; right: 9%; translate: none;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 82"><path d="M10 48 L38 68 L92 12" fill="none" stroke="%23f4efe0" stroke-width="20" stroke-linecap="round" stroke-linejoin="round" opacity=".28"/><path d="M10 48 L38 68 L92 12" fill="none" stroke="%23f4efe0" stroke-width="9" stroke-linecap="round" stroke-linejoin="round" stroke-dasharray="11 3"/></svg>') center/contain no-repeat;
  filter: drop-shadow(0 0 14px rgba(244,239,224,.5)); }
.theme-chalkboard .tickarm { display: none; }

/* ---- sprint3 gate folds round 3: five full cards, WHAM legibility ---- */
.slab { width: clamp(280px,17.5vw,420px); }
.slab .art { aspect-ratio: 1/1; }
.carousel { margin-bottom: 10vh; }
.slab.peek { width: clamp(280px,17.5vw,420px); overflow: visible; align-items: center; }
.slab.peek .art { width: 100%; max-width: 100%; }
.theme-inkverse .screen[data-screen="shelf"]::before { content: "WHAM!"; font-size: 4.6vh; padding: 6.5vh 4vh; top: 14%; right: 6%; }
.theme-inkverse .screen[data-screen="shelf"]::before { width: 24vh; height: 24vh; padding: 0; display: grid; place-items: center; font-size: 5vh; }

/* ---- sprint3 gate folds round 4: short labels ship in data; chalk ghost-boxes killed ---- */
.theme-chalkboard .stamp.ghost { display: none; }
.theme-chalkboard .slab .stamp.won, .theme-chalkboard .slab .stamp:not(.ghost) { position: absolute; top: -2vh; right: -1.6vh; z-index: 2;
  background: #23282e; border-radius: 50% 46% 52% 48%/48% 52% 46% 54%; }

/* ==================== SPRINT 4: WEEKLY-PICK FLOW ==================== */
/* pick action bar under the case */
.bs-actionbar { position: absolute; left: 50%; bottom: 3.2vh; translate: -50% 0; display: flex; align-items: center; gap: 2.4vh; z-index: 3; }
.bspick-btn { font-size: clamp(20px,3vh,34px); padding: 1.6vh 4vh; }
.bspick-note { font-size: clamp(15px,2vh,22px); font-weight: 800; color: var(--cream); opacity: .92; }
.screen[data-screen="bookshelf-pick"] .bs-case { transform: translateY(-4vh) scale(.94); transform-origin: top center; }
/* pick-confirm: slots ceremony */
.pc-slots { position: absolute; left: 50%; top: 30%; translate: -50% -50%; display: flex; gap: 3vh; z-index: 2; }
.pc-slots .bs-slot { width: 11vh; height: 11vh; border-width: 5px; }
.pc-slots .pc-just { background: var(--tag-bg); box-shadow: 0 0 44px rgba(255,210,77,.65); }
.pc-sub { font-size: clamp(20px,2.8vh,32px); font-weight: 800; margin: .6vh 0 1.6vh; }
/* week view */
.screen[data-screen="week"] .wk-books { display: flex; gap: 3vw; justify-content: center; margin-top: 16vh; }
.wk-book { position: relative; width: clamp(180px,20vh,260px); }
.wk-book .bs-art { width: 100%; aspect-ratio: .85; object-fit: cover; border-radius: var(--item-radius); box-shadow: var(--art-shadow); }
.wk-book .bs-title { text-align: center; margin-top: 1vh; }
.wk-book.today .bs-art { box-shadow: 0 0 0 4px var(--tag-bg), 0 0 40px rgba(255,210,77,.4); }
.wk-check { position: absolute; top: -1.8vh; right: -1.8vh; width: 5.5vh; height: 5.5vh; border-radius: 50%;
  background: #4caf6d; color: #fff; display: grid; place-items: center; z-index: 2; box-shadow: 0 6px 14px rgba(0,0,0,.4); }
.wk-check svg { width: 62%; height: 62%; }
.wk-strip { display: flex; gap: 1.4vw; justify-content: center; margin-top: 5vh; }
.wk-day { width: 9.5vw; max-width: 150px; padding: 1.6vh 0; text-align: center; border-radius: var(--item-radius);
  border: 2px solid rgba(255,255,255,.16); color: var(--cream); opacity: .55; font-weight: 800; font-size: clamp(16px,2.2vh,22px); }
.wk-day.past { opacity: .8; border-color: rgba(255,255,255,.3); }
.wk-day.now { opacity: 1; border-color: var(--tag-bg); box-shadow: 0 0 18px rgba(255,210,77,.35); }
.wk-calm { text-align: center; margin-top: 3.5vh; }
/* theme skins */
.theme-inkverse .wk-book .bs-art { border: 4px solid #1a1408; box-shadow: 6px 6px 0 #1a1408; }
.theme-inkverse .wk-day { border: 3px solid #1a1408; background: #fffdf2; color: #1a1408; opacity: 1; box-shadow: 3px 3px 0 #1a1408; }
.theme-inkverse .wk-day.now { background: var(--accent-y); }
.theme-inkverse .pc-slots .bs-slot { border-color: #1a1408; }
.theme-inkverse .bspick-note { color: #4a3f28; }
.theme-chalkboard .wk-book .bs-art { border: 4px solid rgba(244,239,224,.85); border-radius: 18px 6px 20px 8px; }
.theme-chalkboard .wk-book:nth-child(1) .bs-art { border-color: var(--chalk-pink); }
.theme-chalkboard .wk-book:nth-child(2) .bs-art { border-color: var(--chalk-y); }
.theme-chalkboard .wk-book:nth-child(3) .bs-art { border-color: var(--chalk-b); }
.theme-chalkboard .wk-day { border: 2px dashed rgba(244,239,224,.5); border-radius: 14px 5px 16px 6px; }
.theme-chalkboard .wk-check { background: var(--chalk-g); color: #20242a; }
.theme-chalkboard .pc-slots .pc-just { background: var(--chalk-y); box-shadow: 0 0 44px rgba(255,224,102,.55); }

/* ---- inkverse residuals: ghost-slot stars visible on the burst; celebration de-fog hard ---- */
.theme-inkverse .stamp.ghost { opacity: 1; color: rgba(26,20,8,.6); }
.theme-inkverse .stamp.ghost svg { opacity: 1; }
.theme-inkverse .cele-overlay { background: radial-gradient(circle at 50% 36%, rgba(255,209,47,.06), rgba(243,233,207,.26) 82%); }
/* inkverse: empty slot = ink-dashed corner box; earned = sunburst star (comic corner-box idiom) */
.theme-inkverse .stamp.ghost { background: transparent; border: 3px dashed #1a1408; }
.theme-inkverse .stamp.ghost svg { display: none; }
.theme-inkverse .stamp:not(.ghost) { background: repeating-conic-gradient(#ffd12f 0 12deg, #ffb703 12deg 24deg); border: 3px solid #1a1408; color: #1a1408; }

/* ---- sprint4 chalkboard folds (Vihaan): readable week chips; stars off her face ---- */
.theme-chalkboard .wk-day { opacity: .95; border: 3px solid rgba(244,239,224,.85); color: var(--cream); }
.theme-chalkboard .wk-day.past { color: var(--chalk-g); border-color: rgba(168,230,163,.7); }
.theme-chalkboard .wk-day.now { background: var(--chalk-y); color: #20242a; border-color: var(--chalk-y); }
.pc-slots { top: 17%; }
.theme-chalkboard .pc-slots .bs-slot { background: transparent; border-color: rgba(244,239,224,.9); color: var(--chalk-y); }
.theme-chalkboard .pc-slots .bs-slot.filled { background: rgba(35,40,46,.55); border-color: var(--chalk-y); color: var(--chalk-y);
  box-shadow: 0 0 26px rgba(255,224,102,.5); }
.theme-chalkboard .pc-slots .bs-slot svg, .theme-chalkboard .pc-slots .bs-slot svg path { fill: var(--chalk-y); stroke: none; }

/* ==================== SPRINT 5: PICK YOUR WORLD ==================== */
.screen[data-screen="worldpick"] .title-screen { text-align: center; }
.wp-grid { position: absolute; left: 50%; top: 47%; translate: -50% -50%; display: grid; grid-template-columns: 1fr 1fr; gap: 3.4vh 3vw; z-index: 1; }
.wp-world { background: none; border: none; padding: 0; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 1.4vh; }
.wp-frame { position: relative; width: 30vw; max-width: 560px; aspect-ratio: 16/9.6; border-radius: var(--item-radius); overflow: hidden;
  border: 4px solid rgba(255,255,255,.22); box-shadow: 0 18px 40px rgba(0,0,0,.45); }
.wp-world.focus .wp-frame { border-color: var(--tag-bg); box-shadow: 0 0 0 4px rgba(255,210,77,.35), 0 0 50px rgba(255,210,77,.4); }
.wp-frame .sky { position: absolute; inset: 0; }
.wp-scale { position: absolute; left: -14%; top: 8%; width: 240%; transform: scale(.42); transform-origin: top left; }
.wp-scale .wp-row { display: flex; gap: 3vw; justify-content: center; align-items: flex-end; }
.wp-scale .slab, .wp-scale .biglantern { filter: none; transform: none; }
.wp-name { font-size: clamp(20px,2.8vh,32px); font-weight: 800; color: var(--cream); }
.wp-world.focus .wp-name { color: var(--tag-bg); }
.wp-calm { position: absolute; bottom: 5vh; left: 50%; translate: -50% 0; }
/* mini states inside thumbs: shrink internals that rely on viewport units */
.wp-scale .slab .tag .t { font-size: 22px; } .wp-scale .slab .tag .d { display: none; }
.wp-scale .stamp { width: 60px; height: 60px; } .wp-scale .stamp svg { width: 100%; height: 100%; }
.theme-inkverse .wp-world.focus .wp-frame { border-color: #1a1408; box-shadow: 0 0 0 4px #1a1408, 10px 10px 0 var(--accent-red); }
.theme-inkverse .wp-frame { border-color: #1a1408; box-shadow: 7px 7px 0 #1a1408; }
.theme-inkverse .wp-name { color: #1a1408; text-transform: uppercase; text-shadow: 2px 2px 0 var(--accent-y); }
.theme-chalkboard .wp-world.focus .wp-frame { border-color: var(--chalk-y); box-shadow: 0 0 0 3px rgba(255,224,102,.5), 0 0 44px rgba(255,224,102,.45); }
.theme-chalkboard .wp-frame { border: 4px solid rgba(244,239,224,.7); border-radius: 22px 8px 24px 10px/10px 26px 9px 22px; }

/* ---- sprint5 iteration 2: thumbs fill frames; title clearance ---- */
.wp-grid { top: 52%; }
.wp-scale { left: 50%; top: 50%; translate: -50% -50%; width: 250%; }
.wp-frame .sky::before { content: none; }
.screen[data-screen="worldpick"] .title-screen { margin-top: 2.5vh; position: relative; z-index: 2; }

/* ---- sprint5 iteration 3: proper centered scaling container ---- */
.wp-scale { left: 0; top: 0; translate: none; width: 240%; height: 240%; transform: scale(.42); transform-origin: top left;
  display: flex; align-items: center; justify-content: center; }

/* ---- sprint5 iteration 4: no name/calm collision ---- */
.wp-grid { top: 49%; gap: 2.6vh 2.6vw; }
.wp-frame { width: 27vw; }
.wp-calm { bottom: 3.2vh; }
.theme-inkverse .wp-world.focus .wp-name { color: var(--accent-red); text-shadow: 2px 2px 0 #1a1408; }

/* owned state (PM ruling 2026-09-14; VD mockset v4 beat-8 treatment): the current world
   keeps a persistent thin gold INSET ring + gold "- yours!" name suffix, independent of
   focus. Focus stays the bright thick outer ring; locked stays dashed token. */
.wp-name .yours { color: var(--gold); }
/* the frame's .sky covers the padding box, so an inset shadow on .wp-frame itself
   paints under the content - the ring rides an ::after overlay with the same value */
.wp-world.owned .wp-frame::after { content: ""; position: absolute; inset: 0; border-radius: inherit;
  box-shadow: inset 0 0 0 clamp(2px,.55vh,4px) var(--gold); pointer-events: none; z-index: 3; }

/* ---- sprint5 gate polish: bigger previews, one-line guard copy ---- */
.wp-scale { width: 200%; height: 200%; transform: scale(.52); }
.wp-calm { white-space: nowrap; }

/* ---- worldpick canon v1.9 band proportion (VD packet v1.2) ---- */
@media (min-width: 521px) and (max-width: 1000px) {
  .wp-scale { width: 220%; height: 220%; transform: scale(.455); }
}

/* ---- sprint 6: store v2 + redemption flow ---- */
.st-wallet { position: absolute; top: 120px; left: 80px; right: 80px; display: flex; align-items: baseline; justify-content: center; gap: 16px; }
.st-wallet-n { font-size: 64px; font-weight: 800; color: var(--gold, #E8B931); }
.st-wallet-s { font-size: 30px; color: var(--dim); }
.st-grid { position: absolute; top: 220px; left: 80px; right: 80px; bottom: 130px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 26px; }
.st-card { position: relative; background: var(--cream); border: 4px solid var(--dim); border-radius: var(--card-radius); box-shadow: var(--art-shadow); padding: 14px; display: flex; flex-direction: column; align-items: center; }
.st-card img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; margin-top: 40px; }
.st-prov { position: absolute; top: 10px; left: 12px; right: 12px; font-size: 22px; font-weight: 700; color: var(--dim); text-align: center; }
.st-prov.nila { color: var(--pink, #ff3d8b); }
.st-t { font-size: 28px; font-weight: 700; color: var(--ink); text-align: center; margin-top: 12px; line-height: 1.2; }
.st-p { font-size: 32px; font-weight: 800; color: var(--primary); margin-top: 8px; }
.st-card.focus { border-color: var(--primary); box-shadow: 0 0 0 6px color-mix(in srgb, var(--primary) 30%, transparent), var(--art-shadow); }
.st-card.st-big .st-p { font-size: 36px; }
.st-prog { width: 100%; height: 18px; border-radius: 9px; background: var(--dim); opacity: .9; margin-top: 10px; overflow: hidden; }
.st-prog-fill { height: 100%; background: var(--gold, #E8B931); border-radius: 9px; }
.st-prog-n { font-size: 22px; color: var(--dim); margin-top: 6px; }
.rd-math { display: flex; align-items: center; gap: 28px; font-weight: 800; }
.rd-from { font-size: 72px; color: var(--gold, #E8B931); }
.rd-arrow { font-size: 56px; color: var(--dim); }
.rd-to { font-size: 72px; color: var(--primary); }
.theme-inkverse .st-card, .theme-inkverse .rd-math { border-radius: 4px; }
.theme-inkverse .st-card img { border-radius: 2px; }
.theme-chalkboard .st-card { background: #242E29; border: 3px dashed rgba(244,241,234,.5); box-shadow: 0 6px 18px rgba(0,0,0,.4); }
.theme-chalkboard .st-card img { border-radius: 8px; }
.theme-chalkboard .st-t, .theme-chalkboard .st-prov { color: #F4F1EA; }
.theme-chalkboard .st-prov.nila { color: #D9B84A; }
.theme-chalkboard .st-prog { background: rgba(244,241,234,.25); }
.theme-chalkboard .st-prog-n { color: rgba(244,241,234,.75); }
.theme-chalkboard .st-wallet-s { color: rgba(244,241,234,.7); }
.theme-lantern .st-wallet-s, .theme-blocks .st-wallet-s { color: rgba(244,241,234,.75); }
.st-wallet-n svg { width: 52px; height: 52px; fill: var(--gold, #E8B931); vertical-align: middle; }
.theme-inkverse .st-card { background: var(--lift); border: 3px solid #1a1408; box-shadow: 6px 6px 0 rgba(26,20,8,.85); }
.theme-inkverse .st-card.focus { border-color: #C8321E; box-shadow: 0 0 0 4px rgba(200,50,30,.35), 6px 6px 0 rgba(26,20,8,.85); }
/* sprint6 gate fix: price is the money number - readable on every card body */
.st-p { color: color-mix(in srgb, var(--primary) 55%, var(--ink)); }
.theme-chalkboard .st-p { color: #D9B84A; }
/* sprint 8: welcome hero presence */
.screen[data-screen="welcome"] .hero { width: clamp(280px,44vh,480px); }
.screen[data-screen="welcome"] .calm { font-size: clamp(26px,4vh,42px); max-width: 26em; }

/* ---- sprint 9: week-close + fresh-week ---- */
.wk-stats { display: flex; gap: 36px; justify-content: center; }
.wk-stat { font-size: clamp(26px,3.8vh,40px); font-weight: 700; color: var(--calm); }
.wk-stat b { font-size: clamp(48px,7vh,84px); font-weight: 800; color: var(--gold, #ffc72c); }
.screen[data-screen="weekclose"] .hero, .screen[data-screen="freshweek"] .hero { width: clamp(240px,36vh,400px); }
.theme-chalkboard .wk-stat { color: rgba(244,241,234,.85); }
.theme-lantern .wk-stat, .theme-blocks .wk-stat { color: rgba(244,241,234,.85); }
.theme-garden .wp-world.focus .wp-name { color: var(--gold); }
/* protect worldpick preview card labels from outer-skin tag-color leakage */
.wp-frame.theme-clay .slab .tag, .wp-frame.theme-clay .beat-card .tag { color: #17123f; }
.wp-frame.theme-clay .slab .tag .d, .wp-frame.theme-clay .beat-card .tag .d { color: #6b5fa8; }
.wp-frame.theme-chalkboard .slab .tag, .wp-frame.theme-chalkboard .beat-card .tag { color: #20242a; }
.wp-frame.theme-chalkboard .slab .tag .d, .wp-frame.theme-chalkboard .beat-card .tag .d { color: #7d8894; }
/* sprint 8 residual: transparent cutout must not carry the rectangular art shadow */
.screen[data-screen="welcome"] .hero { box-shadow: none; filter: drop-shadow(0 18px 30px rgba(0,0,0,.4)); }

/* ---- sprint 10: group card ---- */
.grp-crew { display: flex; justify-content: center; gap: 0; }
.grp-crew img { width: clamp(64px,10vh,110px); aspect-ratio: 1; border-radius: 50%; object-fit: cover; border: 4px solid var(--cream); margin-left: -18px; box-shadow: var(--art-shadow); }
.grp-crew img:first-child { margin-left: 0; }

/* ---- sprint 11: cleared shelf ---- */
.cleared-row { display: flex; gap: clamp(28px,3.5vw,64px); justify-content: center; }
.cleared-card { position: relative; width: clamp(240px,24vw,360px); }
.cleared-card img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: var(--card-radius); box-shadow: var(--art-shadow); }
.cleared-tick { position: absolute; top: -18px; right: -18px; width: 64px; height: 64px; border-radius: 50%; background: var(--gold, #ffc72c); box-shadow: var(--art-shadow); }
.cleared-tick::after { content: ""; position: absolute; left: 20px; top: 26px; width: 24px; height: 14px; border-left: 6px solid var(--ink); border-bottom: 6px solid var(--ink); transform: rotate(-45deg); }
.cleared-t { margin-top: 10px; font-size: var(--t-card-title); font-weight: 800; color: var(--calm); text-align: center; }
.theme-chalkboard .cleared-tick { background: #D9B84A; }
.theme-chalkboard .cleared-tick::after { border-color: #20242a; }
.screen[data-screen="cleared"] .cleared-card { width: clamp(190px,19vw,280px); }
.screen[data-screen="cleared"] .center-stage { gap: clamp(14px,2.4vh,26px); }
/* sprint 12 / Inaaya watch-note: inkverse celebration stamp OFF the kid's face - corner-tick pattern */
.theme-inkverse .cele-stamp.pow { top: 5vh; right: 6vw; left: auto; transform: none; width: clamp(90px,13vh,150px); }
.theme-inkverse .powring { left: auto; right: 5vw; top: 4vh; translate: none; width: 26vh; height: 26vh; border-width: 5px; }
.theme-inkverse .cele-stamp.pow { top: calc(4vh + 8vh); right: calc(5vw + 8vh); width: 10vh; height: 10vh; }

/* ---- sprint 12: world unlock ---- */
.wp-world.wp-new { position: relative; }
.wp-world.wp-new::after { content: "NEW!"; position: absolute; top: 6px; right: 6px; z-index: 3;
  font-weight: 800; font-size: clamp(18px,2.6vh,30px); color: #1a1408; background: var(--gold, #ffd24d);
  padding: 6px 14px; border-radius: 999px; transform: rotate(6deg); box-shadow: 0 6px 14px rgba(0,0,0,.35); }
.wp-world.wp-new .wp-frame { border-color: var(--gold, #ffd24d); box-shadow: 0 0 0 4px rgba(255,210,77,.3), 0 0 44px rgba(255,210,77,.35); }
/* storybook preview labels: guard against outer-skin leakage */
.wp-frame.theme-storybook .slab .tag, .wp-frame.theme-storybook .beat-card .tag { color: #452e14; }
.wp-frame.theme-storybook .slab .tag .d, .wp-frame.theme-storybook .beat-card .tag .d { color: #9a7c50; }
.wp-frame.theme-lantern .slab .tag, .wp-frame.theme-lantern .beat-card .tag { color: #452e14; }
.wp-frame.theme-lantern .slab .tag .d, .wp-frame.theme-lantern .beat-card .tag .d { color: #9a7c50; }
/* worldpick-5: 3+2 grid (6-col track, tiles span 2), smaller frames */
.screen[data-screen="worldpick5"] .wp-grid { grid-template-columns: repeat(6, 1fr); gap: 2.4vh 2vw; width: 88vw; }
.screen[data-screen="worldpick5"] .wp-frame { width: 100%; max-width: none; }
.screen[data-screen="worldpick5"] .wp-world { grid-column: span 2; }
.screen[data-screen="worldpick5"] .wp-world:nth-child(4) { grid-column: 2 / span 2; }
.screen[data-screen="worldpick5"] .wp-name { font-size: clamp(18px,2.4vh,28px); }

/* ---- sprint 13: turn handoff ---- */
.handoff-kids { gap: clamp(40px,6vw,110px); }
.handoff-kids .kidbtn.recess { filter: brightness(.82) saturate(.85); }
.handoff-kids .nametag { max-width: 12em; }

/* ---- sprint 14: the bigger one ---- */
.bigger-kicker { color: var(--gold, #ffc72c); font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }

/* E1.12 stage skins: ledge + nametag per theme (clay uses --lift default + base nametag) */
.theme-storybook .screen[data-screen="picker"] .kidbtn .stage-ledge { background: linear-gradient(#3a2513,#2a1a0e); }
.theme-storybook .screen[data-screen="picker"] .kidbtn .nametag { background: #f6ead0; color: #452e14; }
.theme-lantern .screen[data-screen="picker"] .kidbtn .stage-ledge { background: rgba(255,205,110,.35); box-shadow: 0 0 18px rgba(255,205,110,.35); }
.theme-lantern .screen[data-screen="picker"] .kidbtn .nametag { background: #f6ecd4; color: #3a2c14; }
.theme-blocks .screen[data-screen="picker"] .kidbtn .stage-ledge { background: linear-gradient(#e2503f,#b03223); }
.theme-blocks .screen[data-screen="picker"] .kidbtn .nametag { background: #eef4ff; color: #12233c; }
.theme-garden .screen[data-screen="picker"] .kidbtn .stage-ledge { background: linear-gradient(#c96f3f,#9a4d26); }
.theme-garden .screen[data-screen="picker"] .kidbtn .nametag { background: #f2ecd8; color: #123126; }

/* ---- VD gap states G1/G2/G4/G6 (user-flows.md @ 756cd56; clamp-only, theme-native) ---- */
.skel { background: var(--lift); border-radius: var(--card-radius, clamp(14px,2vh,22px)); animation: skelpulse 1.6s ease-in-out infinite; }
@keyframes skelpulse { 0%,100% { opacity: .55; } 50% { opacity: .95; } }
.skel-title { width: clamp(200px,26vw,420px); height: clamp(24px,4vh,44px); margin: var(--pad-screen-y, 4vh) auto 0; }
.skel-stage { height: clamp(240px,38vh,480px); aspect-ratio: 1/2; }
.skel-ledge { width: 70%; height: clamp(10px,1.6vh,18px); }
.skel-tag { width: clamp(70px,10vh,120px); height: clamp(24px,3.4vh,38px); }
.skel-art { width: 100%; aspect-ratio: 16/9; }
.skel-line { width: 60%; height: clamp(14px,2vh,22px); }
.skel-title-lg { width: min(70vw, 20em); height: clamp(30px,5vh,56px); }
.skel-hero { width: clamp(200px,32vh,360px); aspect-ratio: 1; }
.skel-pill { width: clamp(140px,20vh,240px); height: clamp(40px,6.4vh,70px); border-radius: 999px; }
.skel-answer { width: 100%; height: clamp(48px,7.4vh,84px); }
.skel-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap-screen); width: min(56vw,76vh); margin: 0 auto; z-index: 1; }
.skel-card { width: 100%; aspect-ratio: 4/5; }
/* G2 dead pill: calm dim/rest, never alarm red; ring advances */
.btn.dead { filter: brightness(.82) saturate(.85); text-decoration: line-through; cursor: default; }
/* warm inline note (commit errors, wrong answer) */
.warm-note { font-size: clamp(20px,2.8vh,32px); font-weight: 700; color: var(--cream); z-index: 1; }
.edge-sub { font-size: clamp(20px,2.8vh,32px); }
/* G4 leave prompt: calm modal over dimmed picker */
.leave-dim { filter: brightness(.7); }
.leave-scrim { position: absolute; inset: 0; background: rgba(0,0,0,.45); z-index: 4; }
.leave-modal { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); z-index: 5;
  background: var(--lift); border-radius: var(--card-radius, clamp(18px,2.6vh,30px));
  padding: clamp(24px,4vh,48px) clamp(32px,5vw,72px); display: flex; flex-direction: column;
  align-items: center; gap: var(--gap-screen); box-shadow: var(--art-shadow); }
.leave-title { font-size: clamp(36px,6vh,68px); font-weight: 800; color: var(--cream); }
.moon { width: clamp(64px,10vh,120px); fill: var(--cream); opacity: .9; }
.star-outline { width: 100%; height: 100%; color: var(--gold, #ffc72c); }
.bs-count { z-index: 1; text-align: center; }
.bs-mini-row { display: flex; gap: var(--gap-screen); z-index: 1; align-items: flex-start; }
.bs-mini { width: clamp(200px,26vh,320px); display: flex; flex-direction: column; gap: clamp(8px,1.2vh,14px); align-items: center; }
.bs-mini img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--card-radius); box-shadow: var(--art-shadow); }
.bs-mini.focus { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: clamp(3px,.5vh,5px); border-radius: var(--card-radius); }
.bs-mini-t { font-weight: 800; color: var(--cream); font-size: var(--t-action); text-align: center; }
/* bookshelf loading title placement */
.screen[data-screen="bookshelf"] .title-shelf { z-index: 1; }

/* worldpick-5 locked FIREFLY WOODS row (PM ruling 2026-09-14; DS-1 mockset v2 anatomy) */
.wp-locked { grid-column: 1 / span 2; display: flex; align-items: center; gap: clamp(12px,1.7vw,30px);
  background: var(--lift); border-radius: clamp(10px,3vh,18px); padding: clamp(10px,1.4vh,20px) clamp(14px,1.9vw,34px);
  filter: saturate(.9); position: relative; z-index: 1; }
.wp-locked.focus { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: clamp(3px,.5vh,5px); }
.wp-locked-frame { position: relative; flex: none; width: clamp(46px,11.5vh,84px); aspect-ratio: 1;
  border-radius: clamp(8px,2.6vh,15px); overflow: hidden;
  background: radial-gradient(ellipse 85% 58% at 50% -6%, #17472e 0%, transparent 72%), #0d2417;
  box-shadow: inset 0 0 0 clamp(2px,.55vh,4px) rgba(255,236,112,.5); }
.ffwp { position: absolute; width: clamp(2px,.75vh,5px); height: clamp(2px,.75vh,5px); border-radius: 50%;
  background: #ffe98a; box-shadow: 0 0 clamp(4px,1.9vh,12px) clamp(1px,.55vh,4px) rgba(255,220,120,.55); }
.sprout { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.sprout i { position: absolute; display: block; }
.sprout-stem { bottom: 0; left: 44%; width: 11%; height: 62%; background: #1c4a2e; border-radius: clamp(1px,.4vh,3px); }
.sprout-leaf { top: 5%; width: 47%; height: 31%; }
.sprout-leaf.la { left: 0; background: #7cc476; border-radius: 100% clamp(1px,.3vh,4px) 100% clamp(1px,.3vh,4px); transform: rotate(-20deg); }
.sprout-leaf.lb { right: 0; background: #9be08f; border-radius: clamp(1px,.3vh,4px) 100% clamp(1px,.3vh,4px) 100%; transform: rotate(20deg); }
.wp-locked-body { flex: 1; display: flex; flex-direction: column; gap: clamp(2px,.5vh,6px); }
.wp-locked-name { font-size: clamp(12px,3.3vh,20px); font-weight: 800; }
.wp-locked-name em { color: var(--gold); font-style: normal; font-size: .78em; }
.wp-locked-line { font-size: clamp(10px,2.8vh,17px); color: var(--calm); }
.wp-locked-rule { font-size: clamp(9px,2.4vh,15px); color: var(--calm); font-weight: 700; }
/* worldpick-5 canon (PM ruling 2026-09-14): 2x2 thumbs + full-width locked row;
   overrides the legacy 6-col 5-thumb worldpick5 layout above. */
.screen[data-screen="worldpick5"] .wp-world { grid-column: auto / span 3; }
.screen[data-screen="worldpick5"] .wp-world:nth-child(4) { grid-column: auto / span 3; }
.screen[data-screen="worldpick5"] .wp-locked { grid-column: 1 / -1; }
/* worldpick-5 fit: shrink thumbs so 2x2 + locked row + title + calm all fit 720p */
.screen[data-screen="worldpick5"] .wp-frame { width: 21vw; }
.screen[data-screen="worldpick5"] .wp-calm { bottom: 2vh; }
.screen[data-screen="worldpick5"] .wp-frame { width: 19vw; }
.screen[data-screen="worldpick5"] .wp-grid { top: 53.5%; }

/* shelf canon chrome (PM ruling 2026-09-14 (b); VD mockset v3 beat-3):
   streak header text in the shelf HUD and canon tabs above the card row. */
.hud .streak-line { font-weight: 800; font-size: .82em; white-space: nowrap; }
.hud .streak-sub { color: var(--calm); font-size: .62em; white-space: nowrap; }
.shelf-tabs { display: flex; gap: clamp(14px,3vw,30px); justify-content: center; z-index: 1; margin-top: clamp(4px,.6vh,8px); }
.shelf-tab { font-size: clamp(12px,3.2vh,21px); font-weight: 800; }

/* worldpick-5 phone self-break fix (VD mockset v3 beat-8; PM ruling 2026-09-14 (c);
   media block LAST - the cascade loses otherwise. At <=520px: grid to 94vw,
   thumbs and names vw-driven, locked row wraps with a min-width text column. */
@media (max-width: 520px) {
  .screen[data-screen="worldpick5"] .wp-grid { width: 94vw; gap: 1.4vh 3.5vw; }
  .screen[data-screen="worldpick5"] .wp-frame { width: min(26vw, 14.5vh); }
  .screen[data-screen="worldpick5"] .wp-name { font-size: clamp(11px, 4.2vw, 17px); }
  .screen[data-screen="worldpick5"] .wp-locked { flex-wrap: wrap; align-items: flex-start; }
  .screen[data-screen="worldpick5"] .wp-locked-body { flex: 1 1 11em; min-width: 0; }
  .screen[data-screen="worldpick5"] .wp-locked-rule { flex: 0 0 auto; margin-left: auto; }
}


/* TRIP-5-BACK-BAND fold (PM ruling 2026-09-14, mask-list #1 retirement; style matched to
   builder production evidence 20:30 - text "Back", no glyph; base ground-lift/cream,
   chalkboard transparent chalk-outline; geometry from gate mask bbox 1280:30,10,115,90 /
   390:12,17,84,82). worldpick5 inherits. */
.wp-back { position: absolute; left: clamp(12px,2.34vw,30px); top: clamp(10px,1.4vh,17px); z-index: 4;
  display: grid; place-items: center; min-width: clamp(84px,9vw,115px); min-height: clamp(70px,12.5vh,90px);
  background: var(--lift); color: var(--cream); border: none; box-shadow: none; cursor: pointer;
  border-radius: clamp(18px,3.3vh,36px); padding: clamp(16px,2.8vh,32px) clamp(20px,2.2vw,40px);
  font-family: inherit; font-size: clamp(24px,3.8vh,40px); font-weight: 700; }
.theme-chalkboard .wp-back { background: transparent; border: 3px solid rgba(244,239,224,.85);
  border-radius: 22px 8px 24px 10px/10px 26px 9px 22px; color: var(--cream); }

/* ---- viewport-true repair (PM ruling 2026-09-14 20:30): symmetric-quirk port REJECTED.
   (1) desktop: 5 full cards no scroll - the working ~194px fit codified, shrink quirk gone.
   (2) phone <=520: shelf = carousel (2 full + peek, kid-tappable, fold-don't-shrink);
   store = 2-up grid + vertical scroll; HUD fits; full titles never clipped. ---- */
.screen[data-screen="shelf"] .slab, .screen[data-screen="shelf"] .slab.peek { flex: 0 0 auto; width: clamp(170px,15.2vw,240px); }
.screen[data-screen="shelf"] .slab.peek .art { width: 100%; max-width: 100%; }
@media (max-width: 520px) {
  .wp-back { left: 12px; top: 17px; min-width: 84px; min-height: 82px; font-size: 16px; padding: .45em 1.2em; }
  .hud { flex-wrap: wrap; justify-content: center; max-width: 96vw; row-gap: clamp(2px,.6vh,6px); column-gap: clamp(12px,4vw,20px); }
  .screen[data-screen="shelf"] .carousel { overflow-x: auto; scrollbar-width: none; gap: clamp(10px,3vw,16px); padding: 0 4vw; margin-left: calc(-1 * var(--pad-screen-x)); margin-right: calc(-1 * var(--pad-screen-x)); align-self: stretch; }
  .screen[data-screen="shelf"] .slab, .screen[data-screen="shelf"] .slab.peek { width: clamp(130px,36vw,170px); }
  .screen[data-screen="shelf"] .slab.peek { width: clamp(90px,26vw,120px); }
  .slab .tag .t, .slab .tag .d { -webkit-line-clamp: unset; overflow: visible; min-height: 0; }
  .slab .tag .t { font-size: clamp(13px,3.8vw,17px); }
  .slab .tag .d { font-size: clamp(11px,3.2vw,14px); }
  .screen[data-screen="store"] .st-wallet { top: 84px; left: 16px; right: 16px; gap: 10px; }
  .screen[data-screen="store"] .st-wallet-n { font-size: 34px; }
  .screen[data-screen="store"] .st-wallet-s { font-size: 18px; }
  .screen[data-screen="store"] .st-grid { grid-template-columns: repeat(2, 1fr); top: 150px; left: 16px; right: 16px; bottom: 132px; overflow-y: auto; gap: 14px; align-content: start; }
  .screen[data-screen="store"] .store-back { bottom: 16px; }
  .screen[data-screen="store"] .st-card { padding: 8px; }
  .screen[data-screen="store"] .st-card img { margin-top: 24px; }
  .screen[data-screen="store"] .st-prov { font-size: 12px; left: 8px; right: 8px; }
  .screen[data-screen="store"] .st-t { font-size: 15px; }
  .screen[data-screen="store"] .st-p { font-size: 18px; }
}

/* picker phone <=520px (production sw v11 F5/F6 analogs): brand/title de-overlap, uniform rhythm
   (mock .screen is a flex column without grid gap, so the uniform clamp rides on the row margin) */
@media (max-width: 520px) {
  .screen[data-screen="picker"] .brand { width: 40px; top: 14px; right: 16px; }
  .screen[data-screen="picker"] .title-screen { font-size: clamp(34px,9vw,52px); max-width: calc(100vw - 160px); }
  .screen[data-screen="picker"] .picker-kids, .screen[data-screen="picker"] .picker-row { margin-block: var(--gap-screen); }
}

/* ---- Row-316 residual port: production picker FAILURE composition, geometry and
   theme layers verbatim (apps/web styles.css .nila-screen/.nila-picker +
   themes.css theme blocks), scoped to the failure beat. One markup serves all
   four themes; production's conditional ground render is CSS-conditional here
   (lantern ground-free). Tokens are production's, declared on the screen per
   theme so the mock's global theme vars stay untouched elsewhere. ---- */
.screen[data-screen="picker-error"] {
  min-height: 100vh; min-height: 100dvh; max-height: 100vh; max-height: 100dvh;
  overflow: hidden; display: flex; flex-direction: column; align-items: center;
  justify-content: center; justify-content: safe center; gap: clamp(20px, 3.5vh, 48px);
  color: var(--cream); font-family: "Baloo 2", "Nunito", "Comic Sans MS", system-ui, sans-serif;
  text-align: center; padding: clamp(24px, 5vh, 64px) clamp(48px, 5vw, 96px);
  box-sizing: border-box; background: var(--sky); background-color: var(--ground);
}
body.theme-clay .screen[data-screen="picker-error"] {
  --ground: #1c1150; --ground-lift: #2b1c7a; --cream: #fff4dc; --cream-dim: #e4d9be;
  --ink: #17123f; --tangerine: #ff6b2c; --primary: var(--tangerine); --focus-ring: #ffe14d;
  --sky: radial-gradient(ellipse 85% 58% at 50% -6%, #2b1c7a 0%, rgba(43, 28, 122, 0.45) 42%, transparent 72%);
}
body.theme-lantern .screen[data-screen="picker-error"] {
  --ground: #06061a; --ground-lift: #17123f; --cream: #f2ead2; --cream-dim: #b9b0e0;
  --ink: #3a2c14; --tangerine: #ff8a3d; --primary: var(--tangerine); --focus-ring: #ffe97a;
  --sky:
    radial-gradient(1.5px 1.5px at 12% 22%, rgba(255, 255, 255, 0.6), transparent 100%),
    radial-gradient(1.5px 1.5px at 32% 10%, rgba(255, 255, 255, 0.5), transparent 100%),
    radial-gradient(2px 2px at 55% 18%, rgba(255, 255, 255, 0.55), transparent 100%),
    radial-gradient(1.5px 1.5px at 74% 8%, rgba(255, 255, 255, 0.4), transparent 100%),
    radial-gradient(2px 2px at 88% 26%, rgba(255, 255, 255, 0.55), transparent 100%),
    radial-gradient(1.5px 1.5px at 45% 30%, rgba(255, 255, 255, 0.35), transparent 100%),
    radial-gradient(1.5px 1.5px at 66% 40%, rgba(255, 255, 255, 0.3), transparent 100%),
    radial-gradient(ellipse 85% 60% at 50% -8%, #141036 0%, transparent 72%);
}
body.theme-inkverse .screen[data-screen="picker-error"] {
  --ground: #f3e9cf; --ground-lift: #fff8e2; --cream: #1a1408; --cream-dim: #8a7c5c;
  --ink: #1a1408; --tangerine: #e63946; --primary: var(--tangerine); --focus-ring: #ffd94d;
  --pink: #2a6ff2; --accent-y: #ffd12f; --ink-block: #1a1408;
  --sky:
    radial-gradient(circle at 18% 12%, rgba(230, 57, 70, 0.14), transparent 42%),
    radial-gradient(circle at 85% 82%, rgba(42, 111, 242, 0.12), transparent 46%),
    linear-gradient(#fff8e2, #f3e9cf);
}
body.theme-chalkboard .screen[data-screen="picker-error"] {
  --ground: #23282e; --ground-lift: #2f363e; --cream: #f4efe0; --cream-dim: #a8b2bc;
  --ink: #20242a; --tangerine: #ff9ecb; --primary: var(--tangerine); --focus-ring: #ffe14d;
  --sky:
    radial-gradient(ellipse at 28% 18%, rgba(255, 255, 255, 0.06), transparent 52%),
    radial-gradient(ellipse at 76% 78%, rgba(255, 255, 255, 0.045), transparent 46%),
    linear-gradient(#2b323a, #21262c);
}
/* production .nila-picker structure rules, verbatim */
.screen[data-screen="picker-error"] .picker-brand { position: absolute; top: clamp(16px, 2.6vh, 30px); right: clamp(48px, 5vw, 96px); width: clamp(44px, 6.4vh, 70px); filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.35)); }
.screen[data-screen="picker-error"] .nila-title { font-size: clamp(36px, 6vh, 68px); font-weight: 800; margin: 0; letter-spacing: 0.01em; text-shadow: 0 6px 0 rgba(10, 7, 38, 0.5); }
.screen[data-screen="picker-error"] .picker-ground { position: absolute; left: -8vw; right: -8vw; bottom: -14vh; height: 34vh; background: var(--ground-lift); border-radius: 0; }
body.theme-lantern .screen[data-screen="picker-error"] .picker-ground { display: none; }
.screen[data-screen="picker-error"] .picker-row-empty { margin: 0; padding: 0; }
.screen[data-screen="picker-error"] .picker-failure { margin: auto 0; display: flex; flex-direction: column; align-items: center; gap: clamp(20px, 3.5vh, 48px); z-index: 1; }
.screen[data-screen="picker-error"] .nila-calm { font-weight: 600; font-size: clamp(22px, 3.4vh, 36px); color: var(--cream-dim); margin: 0; }
.screen[data-screen="picker-error"] .nila-action { border: 0; padding: 0; color: inherit; font: inherit; background: none; cursor: pointer; }
.screen[data-screen="picker-error"] .nila-action.nila-primary { background: var(--primary); color: #fff; border-radius: 999px; font-size: clamp(20px, 3.2vh, 36px); font-weight: 800; padding: 0.45em 1.4em; }
.screen[data-screen="picker-error"] .nila-focused { background: #3a2a94; transform: scale(1.07) translateY(-clamp(3px, 0.6vh, 6px)); box-shadow: 0 0 0 clamp(4px, 0.7vh, 8px) var(--ink), 0 0 0 clamp(8px, 1.5vh, 16px) var(--focus-ring), 0 30px 60px rgba(0, 0, 0, 0.5); }
/* doors: production .picker-doors grid (content-width, centered - NOT stretched),
   door anatomy == production .kidbtn/.kidbtn-door verbatim */
.screen[data-screen="picker-error"] .picker-doors { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: clamp(24px, 6vw, 60px); align-items: flex-end; justify-content: center; z-index: 1; margin-bottom: clamp(10px, 2vh, 24px); }
.screen[data-screen="picker-error"] .picker-doors .kidbtn { display: flex; flex-direction: column; align-items: center; gap: clamp(8px, 1.4vh, 16px); position: relative; background: none; border: 0; padding: 0; color: inherit; font: inherit; width: fit-content; justify-self: center; }
.screen[data-screen="picker-error"] .kidbtn-door { filter: none; }
.screen[data-screen="picker-error"] .kidbtn-door .cutout { height: clamp(70px, 12vh, 160px); width: auto; display: block; }
.screen[data-screen="picker-error"] .kidbtn-door .stage-ledge { align-self: center; width: 100%; height: clamp(10px, 1.6vh, 18px); background: var(--ground-lift); border-radius: 6px; }
.screen[data-screen="picker-error"] .kidbtn-door .nametag { background: var(--cream); color: var(--ink); font-size: clamp(16px, 2.6vh, 30px); font-weight: 800; border-radius: clamp(14px, 2.4vh, 26px); padding: 0.3em 1.1em; box-shadow: 0 8px 16px rgba(0, 0, 0, 0.35); }
/* phone fold (production themes.css F31: doors fold to nametag-only at <=520px) */
@media (max-width: 520px) {
  .screen[data-screen="picker-error"] .picker-doors .kidbtn-door .cutout,
  .screen[data-screen="picker-error"] .picker-doors .kidbtn-door .stage-ledge { display: none; }
  .screen[data-screen="picker-error"] .picker-doors { margin-bottom: 2vh; }
  /* production F5/F6 phone fixes (styles.css @media <=520, verbatim) */
  .screen[data-screen="picker-error"] .picker-brand { width: 40px; top: 14px; right: 16px; }
  .screen[data-screen="picker-error"] .nila-title { font-size: clamp(34px, 9vw, 52px); max-width: calc(100vw - 160px); }
}
/* inkverse theme layer (themes.css verbatim) */
body.theme-inkverse .screen[data-screen="picker-error"] .nila-title { text-transform: uppercase; letter-spacing: 0.02em; text-shadow: clamp(2px, 0.3vh, 3px) clamp(2px, 0.3vh, 3px) 0 var(--accent-y), clamp(4px, 0.6vh, 6px) clamp(4px, 0.6vh, 6px) 0 rgba(26, 20, 8, 0.85); }
body.theme-inkverse .screen[data-screen="picker-error"] .nila-action { text-transform: uppercase; border: 3px solid var(--ink-block); border-radius: 8px; box-shadow: 4px 4px 0 var(--ink-block); }
body.theme-inkverse .screen[data-screen="picker-error"] .nila-action.nila-primary { background: var(--tangerine); color: #fff8e2; }
body.theme-inkverse .screen[data-screen="picker-error"] .nila-action.nila-focused { box-shadow: 0 0 0 3px var(--ink-block), 7px 7px 0 var(--pink); }
/* chalkboard theme layer (themes.css verbatim): doodle sky, chalk dust, child
   lift + furniture absolute, title glow + pink chalk underline, chalk buttons */
body.theme-chalkboard .screen[data-screen="picker-error"] { position: relative; }
body.theme-chalkboard .screen[data-screen="picker-error"]::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
  background:
    url("assets/design/chalk-doodles/chalk-doodle-star.svg") 8% 22%/5.5vh no-repeat,
    url("assets/design/chalk-doodles/chalk-doodle-star-blue.svg") 90% 14%/4.5vh no-repeat,
    url("assets/design/chalk-doodles/chalk-doodle-spiral.svg") 78% 68%/7vh no-repeat,
    url("assets/design/chalk-doodles/chalk-doodle-fish.svg") 14% 72%/6vh no-repeat,
    url("assets/design/chalk-doodles/chalk-doodle-shelf.svg") 88% 86%/8vh no-repeat;
}
body.theme-chalkboard .screen[data-screen="picker-error"]::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(244, 239, 224, 0.05) 1px, transparent 1.6px);
  background-size: 7px 7px;
}
body.theme-chalkboard .screen[data-screen="picker-error"] > * { position: relative; z-index: 1; }
body.theme-chalkboard .screen[data-screen="picker-error"] > .picker-brand,
body.theme-chalkboard .screen[data-screen="picker-error"] > .picker-ground { position: absolute; }
body.theme-chalkboard .screen[data-screen="picker-error"] > .picker-brand { z-index: 5; }
body.theme-chalkboard .screen[data-screen="picker-error"] .nila-title { text-shadow: 0 0 clamp(4px, 0.7vh, 7px) rgba(244, 239, 224, 0.45), 2px 2px 0 rgba(0, 0, 0, 0.35); }
body.theme-chalkboard .screen[data-screen="picker-error"] .nila-title::after {
  content: ""; display: block; width: 34%; height: clamp(3px, 0.5vh, 5px);
  margin: clamp(5px, 1vh, 10px) auto 0;
  background: repeating-linear-gradient(90deg, #ff9ecb 0 clamp(7px, 1.3vh, 14px), transparent clamp(7px, 1.3vh, 14px) clamp(10px, 1.9vh, 20px));
  border-radius: 3px; opacity: 0.85;
}
body.theme-chalkboard .screen[data-screen="picker-error"] .nila-action {
  background: transparent; border: clamp(2px, 0.35vh, 3px) solid rgba(244, 239, 224, 0.85);
  border-radius: clamp(11px, 2vh, 22px) clamp(4px, 0.8vh, 8px) clamp(12px, 2.2vh, 24px) clamp(5px, 1vh, 10px) / clamp(5px, 1vh, 10px) clamp(13px, 2.4vh, 26px) clamp(4px, 0.9vh, 9px) clamp(11px, 2vh, 22px);
  box-shadow: none; color: var(--cream);
}
body.theme-chalkboard .screen[data-screen="picker-error"] .nila-action.nila-primary { background: #ff9ecb; border-color: #ff9ecb; color: var(--ink); }
body.theme-chalkboard .screen[data-screen="picker-error"] .nila-action.nila-focused { background: #ffe066; border-color: #ffe066; color: var(--ink); box-shadow: 0 0 clamp(12px, 2.2vh, 24px) rgba(255, 224, 102, 0.45); }

/* ===== MOCK-quiz-390-narrow-wrap-spec v1.1 COMMIT 1 (VD spec):
   narrow-viewport quiz wrap, mock-only, one media block, no existing rules
   edited. Deterministic column count per theme anatomy at 390 (candidate cell
   = (390 - 2*16 safe margin - 16 gap) / 2 = 171px): clay/chalkboard/inkverse
   doors (natural ~260px), storybook ribbons, blocks blocks and garden
   signposts all exceed 171px -> single centered column, pill width
   min(natural, 358px). Lantern circles clamp to min(182px, 42vw) = 163.8px at
   390 <= 171px -> two columns. Safe area: 16px container side margins + 4px
   inner padding so the focus ring never clips; screen side padding (48px at
   390) neutralized on the quiz screen only, inside this block. Labels wrap,
   line-height >= 1.15, no truncation/ellipsis (break-word so an over-long
   single word stays painted inside its pill). DOM order == visual order,
   row-major. Overflow: horizontal never; vertical scroll on .center-stage
   when title + facts + pills exceed the viewport. */
@media (max-width: 767px) {
  .screen[data-screen="quiz"] { padding-left: 0; padding-right: 0; }
  .screen[data-screen="quiz"] .center-stage { max-width: none; width: 100%; max-height: 760px; overflow-y: auto; overflow-x: hidden; scroll-padding-block: 12px; padding-block-end: 12px; }
  .screen[data-screen="quiz"] .quiz-grid,
  .screen[data-screen="quiz"] .ribbons,
  .screen[data-screen="quiz"] .hang-row.answers,
  .screen[data-screen="quiz"] .block-answers,
  .screen[data-screen="quiz"] .signposts {
    display: grid; grid-template-columns: minmax(0, 358px); justify-content: center; justify-items: center;
    gap: 16px; margin-left: 16px; margin-right: 16px; padding: 4px; align-items: start;
  }
  .screen[data-screen="quiz"] .hang-row.answers { margin: auto 16px; }
  /* horizontal padding tightened to 18px at <=767px only: the themes' native
     ~90px door padding would leave ~260px content width at 390 and force a
     4th line on the 40-char fixture, breaking rule 3's max-3-lines cap;
     18px gives ~314px content, so "An extraordinarily" fits one line.
     Vertical rhythm untouched. */
  .screen[data-screen="quiz"] .btn-door.quiz,
  .screen[data-screen="quiz"] .ribbon,
  .screen[data-screen="quiz"] .blockanswer,
  .screen[data-screen="quiz"] .signpost {
    width: auto; max-width: 100%; white-space: normal; overflow-wrap: break-word;
    line-height: 1.2; text-align: center; padding-left: 18px; padding-right: 18px;
  }
  /* lantern v1.3 (PM row 374): EXACT measured content class - probe in mock.js
     sets data-answer-mode on the quiz screen; CSS keys on the attribute.
     circle mode: v1.0 geometry (diameter min(182px,42vw), 2 columns).
     pill mode: v1.3 rule 4 geometry (single column, width min(100%,358px),
     min-height 72px, stadium radius, padding 14px 18px), same anatomy. */
  .screen[data-screen="quiz"][data-answer-mode="circle"] .hang-row.answers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* circle mode v1.4: text box = 95% of diameter centered (2.5% side padding);
     label wraps to MAX 3 lines (v1.3's 2-line cap superseded); overflow-wrap
     normal per spec probe - the pill trigger guarantees no word exceeds the
     box, so a painted word crossing the border-box means the trigger missed. */
  .screen[data-screen="quiz"][data-answer-mode="circle"] .lant-answer {
    width: min(182px, 42vw); aspect-ratio: 1; border-radius: 50%; padding: 2.5%;
    white-space: normal; overflow-wrap: normal; line-height: 1.15;
    display: grid; place-items: center; text-align: center;
  }
  .screen[data-screen="quiz"][data-answer-mode="pill"] .hang-row.answers { grid-template-columns: minmax(0, 358px); }
  .screen[data-screen="quiz"][data-answer-mode="pill"] .lant-answer {
    width: min(100%, 358px); min-height: 72px; aspect-ratio: auto; border-radius: 999px; padding: 14px 18px;
    white-space: normal; overflow-wrap: break-word; line-height: 1.15;
    display: grid; place-items: center; text-align: center;
  }
  .screen[data-screen="quiz"] .singlepage { width: calc(100% - 8px); max-height: 760px; overflow-y: auto; overflow-x: hidden; scroll-padding-block: 12px; padding-block-end: 12px; }
  /* COMMIT 1 amendment (checker FAIL 15:34, spec v1.6): every anatomy names a
     bounded vertical scroll owner - .center-stage for clay/lantern/blocks/
     garden/inkverse/chalkboard, .singlepage.quizpage for storybook (the
     v1.0 rule named only .center-stage, which exempted storybook silently).
     Identical owner mechanics per v1.6: max-height 760px, overflow-y auto,
     overflow-x hidden, scroll-padding-block 12px so a focused answer's ring
     clears the owner's edges when scrolled into view. padding-block-end 12px
     gives the scrollable content tail room so the LAST answer's focus ring
     (max hard ring 9px: 5px outline + 4px offset) also clears the owner's
     bottom edge when scrollIntoView hits max scroll. Evidence bar is
     viewport-complete: every answer scrolls FULLY into view at 390x844. */
}


/* ===== MOCK-quiz-390-narrow-wrap-spec v1.1 COMMIT 2 (PM row 371 item 3; VD
   placement call): mock Quiz Back control - calm door button BELOW the answer
   grid, left-aligned with the answer column, class btn btn-door quiz-back,
   min hit target 44x88. NEVER focused on entry (initial focus = first
   answer). Render-only (target: return to card detail - noted, not wired).
   INTENTIONALLY changes >=768 quiz renders (row 371 mandate): bottom-left
   under the grid at the theme's existing rhythm - the owner's own flex gap
   supplies the rhythm; align-self:flex-start lands the left edge on the
   full-width grid/row container's left edge (clay/chalkboard/inkverse
   quiz-grid, storybook ribbons, blocks block-answers, garden signposts) and
   on the stage content edge for centered-cluster anatomies (lantern
   hang-row) - deterministic reading, documented. flex-shrink:0 is load-
   bearing: the scroll owners are flex columns, and an explicit min-height
   overrides the flex automatic content minimum, so without shrink:0 the
   button compresses to 44px and its label clips when the owner overflows. */
.screen[data-screen="quiz"] .quiz-back { align-self: flex-start; min-width: 88px; min-height: 44px; flex-shrink: 0; }
@media (max-width: 767px) {
  /* <=767px: Back in-flow at the bottom of the stacked answer column, left
     edge at the 16px safe margin (the same margin convention the answer
     containers use), fully inside [0,390]; when the composition overflows
     844 (storybook fit-3/fit-6 by design, v1.6) Back stays reachable via the
     owner's vertical scroll and horizontally unclipped. */
  .screen[data-screen="quiz"] .quiz-back { margin-left: 16px; }
}

/* ===== MOCK-shelf-390-narrow-layout-spec v1.0 (VD spec): narrow-viewport
   shelf repair, mock-only, one media block, no existing selectors edited.
   Vertical flow title -> HUD -> shelf-tabs -> book stack/carousel ->
   pageindex; vertical scroll allowed, horizontal document scroll never.
   Carousel slab width interpretation: VD's "78% (280px)" refers to the 358px
   content column and yields a 29% peek, outside its own 12-25% peek rule;
   304px = 78% of the 390px viewport satisfies both the percentage language
   and the checked peek range (58px = 19.1% at 390). Pageindex strip: VD's
   96px tabs + 12px gaps give the checked 12-25% peek only when the strip is
   capped at 342px (3 tabs + 3 gaps + 18px = 18.75% peek). Strip padding is
   24/10/14 rather than 4px because pagetab.current's ring (up to 6px outline
   + 4px offset + translateY(-1.6vh)) needs 22.5px top room to paint fully -
   the spec's own rule 3 (ring fully painted) governs. */
@media (max-width: 767px) {
  .screen[data-screen="shelf"] { padding-left: 0; padding-right: 0; overflow-y: auto; scroll-padding-block: 12px; }
  /* scroll-padding-block: the pageindex strip is the last flow element, so a
     focused tab's painted rect ends flush at the 844 viewport bottom and its
     ring (5px outline + 4px offset) would clip off-viewport; the padding
     makes scrollIntoView(block:"nearest") leave 12px of clearance, keeping
     the focused tab's ring fully painted (spec rule 3). */
  .screen[data-screen="shelf"] .hud { flex-wrap: wrap; justify-content: center; margin-left: 16px; margin-right: 16px; row-gap: 6px; }
  .screen[data-screen="shelf"] .shelf-tabs { flex-wrap: wrap; margin-left: 16px; margin-right: 16px; }

  /* storybook: two-page spread becomes a vertical stack (art page on top,
     text page below), each 100% of the content column */
  .theme-storybook .screen[data-screen="shelf"] .book { flex-direction: column; width: calc(100% - 32px); height: auto; margin-top: 2vh; }
  .theme-storybook .screen[data-screen="shelf"] .book .page { flex: none; width: 100%; }
  .theme-storybook .screen[data-screen="shelf"] .book .page.left { border-radius: 14px 14px 3px 3px; }
  .theme-storybook .screen[data-screen="shelf"] .book .page.left .pageart { height: auto; aspect-ratio: 3/2; }
  .theme-storybook .screen[data-screen="shelf"] .book .gutter { width: 0; height: 12px; flex: none; background: linear-gradient(180deg, #e2d0a8, #b39a72 50%, #e2d0a8); }
  .theme-storybook .screen[data-screen="shelf"] .book .page.right { border-radius: 3px 3px 14px 14px; padding: 3vh 6vw; }
  /* the absolutely-positioned postmark (theme-native, stays) overlaps the
     title's right end at 358px column width - cold visual inspection caught
     "orde[r] ... all [by]" occluded behind the ribbon. Reserve the postmark
     column so every title word paints clear (postmark left edge ~292px at
     390; 76px padding keeps text right edge <= ~275px). */
  .theme-storybook .screen[data-screen="shelf"] .book .page.right .p-title { margin-right: 76px; }
  .theme-storybook .screen[data-screen="shelf"] .pageindex { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; gap: 12px; width: min(342px, calc(100% - 32px)); margin-top: 2vh; padding: 24px 0 14px; align-items: flex-end; scroll-padding-inline: 0; }
  /* inline padding ZERO: with padding-inline the mandatory snap aligns tab0 to the
     snapport (padding-box) edge and pins scrollLeft=padding (>0); zero padding makes
     scrollLeft=0 the natural snap position AND puts the 4th-tab peek at 342-324=18px
     (18.75%, inside the 12-25% band). */
  /* checker v1.2: painted tab width must be the canonical 96px - the base odd/even
     deckle rotation (+-1.2-1.4deg) paints 99.1px; flatten rotation at <=767 only.
     The .current lift (translateY) is a state marker and is restored below. */
  .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab:nth-child(odd), .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab:nth-child(even) { transform: none; }
  .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab.current { transform: translateY(-1.6vh); }
  /* v1.2 ruling b: initial focus lands on the FIRST tab; it needs a ring style
     (base CSS has no .pagetab.focus ring). */
  .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab.focus { outline: clamp(4px,.6vh,6px) solid var(--ring); outline-offset: 3px; }
  .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab, .theme-storybook .screen[data-screen="shelf"] .pageindex .pagetab.peektab { width: 96px; flex: 0 0 auto; scroll-snap-align: start; }

  /* carousel shelves (the other six themes): horizontal by design, made
     explicit - first slab flush at the 16px margin, snap, next-slab peek */
  /* shelf screen side padding is 0 inside this block, so the strip sits in
     normal flow (NO negative margins); its 16px inline padding places the
     first card flush at the 16px margin. The spec's "carousel shelves" rule
     names lantern/blocks/garden, whose mock anatomies are .lantern-row /
     .blockrow / .plants (not .carousel) - the same scroll-snap-strip rule
     applies to them per the spec's own scope line ("the other six share the
     same rules ... plus the carousel rule"). Item width 304px = 78% of the
     390px viewport, the reading that satisfies both the spec's "78%" language
     and its checked 12-25% peek. */
  .screen[data-screen="shelf"] .blockrow { position: static; }
  .screen[data-screen="shelf"] .carousel,
  .screen[data-screen="shelf"] .lantern-row,
  .screen[data-screen="shelf"] .blockrow,
  .screen[data-screen="shelf"] .plants { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; gap: 12px; padding: 4px 16px; margin: 2vh 0; align-self: stretch; justify-content: flex-start; scroll-padding-inline: 16px; }
  /* scroll-padding-inline is load-bearing: the snapport derives from the
     strip's PADDING box, not its content box, so without it the mandatory
     snap pulls the first slab to x=0 at load (snap position scrollLeft=16)
     instead of the 16px margin; it also keeps a focused slab's ring off the
     strip edges during scrollIntoView. */
  .screen[data-screen="shelf"] .carousel .slab, .screen[data-screen="shelf"] .carousel .slab.peek,
  .screen[data-screen="shelf"] .lantern-row .lantern,
  .screen[data-screen="shelf"] .blockrow .blk,
  .screen[data-screen="shelf"] .plants .plant { flex: 0 0 auto; width: min(304px, 78vw); scroll-snap-align: start; }
  /* strip cards flatten at <=767px: the recess scale(.95) / focus scale(1.06)
     / inkverse +-1.5deg rotations distort painted geometry (first card would
     paint at 23.6px, not the 16px margin; rects inflate) and the spec's
     painted-inside-[0,390] and 12-25% peek assertions are load-bearing.
     Recess/focus signaling survives via filter brightness and the focus
     ring/shadow treatments. */
  .screen[data-screen="shelf"] .carousel .slab, .screen[data-screen="shelf"] .carousel .slab.focus,
  .screen[data-screen="shelf"] .lantern-row .lantern, .screen[data-screen="shelf"] .lantern-row .lantern.focus,
  .screen[data-screen="shelf"] .blockrow .blk, .screen[data-screen="shelf"] .blockrow .blk.focus,
  .screen[data-screen="shelf"] .plants .plant, .screen[data-screen="shelf"] .plants .plant.focus { transform: none; }
  /* the same flatten covers the blockrow/lantern/plants strips: .blk.focus
     carries translateY(-2.2vh) scale(1.05) at >=768, which inflates painted
     rects (battery measured a phantom 4px gap / 27% peek against the real
     12px / 24% layout) and distorts the ring geometry the checker asserts.
     Focus signaling survives via outline/border/box-shadow treatments. */
  .screen[data-screen="shelf"] .carousel .slab.peek .art { width: 100%; max-width: 100%; }
}
