/* ================= Quán Nhỏ Ven Đường — MonBlock =================
   Painted, sunlit street-food look. The day of service (scPlay) is full screen and ONE scene: the street with the customer,
   the steel cart (glass cabinet, counter, rack) in front, a wooden tray of round picture buttons. Portrait first; landscape
   keeps the same composition with a wider street. */
:root {
  --bg: #0d1117;
  --panel: #151c26;
  --panel-2: #1b2431;
  --line: #2b3646;
  --txt: #e8eef6;
  --muted: #93a3b8;
  --accent: #ffb43a;
  --wood: #b8763a;
  --wood-d: #7a4a22;
  --wood-l: #dca463;
  --serve: #ff7a1a;
  --ol: #3b2416;
  --cream: #fff8ea;
  --cream-2: #f6e4c4;
  --ink: #3b2416;
  --ink-2: #7a5a3a;
  --round: ui-rounded, "SF Pro Rounded", "Nunito", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { touch-action: manipulation; -webkit-text-size-adjust: 100%; }
body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--txt);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-tap-highlight-color: transparent;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}
.hidden { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--accent); }
.wrap { max-width: 720px; margin: 0 auto; padding: 8px 14px 28px; }
.screen { animation: fade .18s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
h2 { font-size: 17px; margin: 18px 0 10px; }
.note { color: var(--muted); font-size: 13px; line-height: 1.5; }

/* ---------- mode cards (home Nhiệm vụ sheet) ---------- */
.xpbar { height: 6px; border-radius: 9px; background: var(--panel-2); overflow: hidden; }
.xpbar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #ff9a3a, #ffd23a); border-radius: 9px; }
.big { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; margin: 0 0 10px; padding: 15px 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); font-size: 17px; font-weight: 800; text-align: left; }
.big small { color: var(--muted); font-size: 13px; font-weight: 600; }
body.mb-light .big-map { --bar: #ff7a1a; }

/* ---------- mini stall (home card, shop try-on, buy dialog): the shop front + the cabinet with jars ---------- */
.mini-stall { position: relative; height: 190px; overflow: hidden; border: 2px solid var(--ol); border-radius: 18px; background: #3a2010; box-shadow: 0 4px 0 #2a160a; }
.mini-stall .ms-bg { position: absolute; inset: 0 0 36px; }
.mini-stall .ms-bg svg { width: 100%; height: 100%; display: block; }
.mini-stall .awning { position: absolute; left: 0; right: 0; top: 0; height: 36px; }
.mini-stall .ms-lanterns { position: absolute; left: 9%; right: 9%; top: 32px; display: flex; justify-content: space-between; z-index: 3; }
.mini-stall .ms-lanterns svg { width: 22px; height: 38px; }
.mini-stall .ms-chef { position: absolute; left: 50%; bottom: 40px; width: 100px; height: 100px; margin-left: -50px; filter: drop-shadow(0 4px 3px rgba(0, 0, 0, .35)); }
.mini-stall .ms-chef svg { width: 100%; height: 100%; }
.mini-stall .ms-counter { position: absolute; left: 0; right: 0; bottom: 0; height: 52px; display: flex; gap: 4px; justify-content: center; align-items: flex-end; padding: 0 64px 4px 12px;
  background: linear-gradient(#7a4520, #4a2610); border-top: 4px solid #2a160a; box-shadow: inset 0 3px 0 rgba(255, 210, 150, .25); }
.mini-stall .ms-counter::before { content: ''; position: absolute; left: 10px; right: 10px; top: 4px; height: 8px; background: radial-gradient(circle, #ffe9a0 0 1.6px, rgba(255, 210, 100, .45) 2.6px, transparent 4.5px) 0 0 / 16px 8px repeat-x; }
.mini-stall .ms-counter img { width: 40px; height: 40px; display: block; }
.mini-stall .ms-plant { position: absolute; right: 8px; bottom: 8px; width: 54px; height: 64px; z-index: 2; }
.mini-stall .ms-plant svg { width: 100%; height: 100%; }
.mini-stall .ms-pet { position: absolute; left: 14px; bottom: 44px; width: 52px; height: 52px; z-index: 2; }
.mini-stall .ms-pet svg { width: 100%; height: 100%; }

/* ---------- awnings (VHCatalog.AWNINGS): .aw-<id> — stall, mini stall and shop tiles ---------- */
.awning { --aw1: #2f7de1; position: relative; display: grid; place-items: center; height: 38px; z-index: 3; border-bottom: 2.5px solid #4a2a14; box-shadow: 0 4px 8px rgba(0, 0, 0, .25); }
.awning::after { content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 13px; background: radial-gradient(circle at 11px 0, var(--aw1) 9px, #4a2a14 9.5px 11.5px, transparent 12px) 0 0 / 22px 13px repeat-x; }
.awning b { position: relative; z-index: 1; max-width: 86%; padding: 3px 14px; overflow: hidden; border: 2px solid #3a200e; border-radius: 6px; background: linear-gradient(#7a4520, #5a3014); color: #ffe7a6; font-size: 14px; font-weight: 900; letter-spacing: .3px; white-space: nowrap; text-overflow: ellipsis; text-shadow: 0 1px 0 #000; box-shadow: 0 2px 0 rgba(0, 0, 0, .3); }
.aw-batxanh { --aw1: #2a6fd0; background: linear-gradient(#3d8af0, #2a6fd0); }
.aw-soddo { --aw1: #d8262b; background: repeating-linear-gradient(90deg, #e3262b 0 22px, #fff6ea 22px 44px); }
.aw-vang { --aw1: #f2b81a; background: repeating-linear-gradient(90deg, #f6c12f 0 22px, #fffaf0 22px 44px); }
.aw-cauvong { --aw1: #8a5ad6; background: repeating-linear-gradient(90deg, #e8463a 0 18px, #f6a12a 18px 36px, #f6d32a 36px 54px, #4cb85a 54px 72px, #3a8ae0 72px 90px, #8a5ad6 90px 108px); }
.aw-maila { --aw1: #a87a3a; background: repeating-linear-gradient(100deg, #c8a058 0 3px, #b08840 3px 6px, #d8b068 6px 9px), #c8a058; }
.aw-maila::after { background: repeating-linear-gradient(90deg, #a87a3a 0 3px, transparent 3px 6px); height: 12px; }
.aw-hoangkim { --aw1: #c8202a; background: linear-gradient(#ffe27a, #e8b020 60%, #c88a10); }
.aw-hoangkim b { background: linear-gradient(#c8202a, #8a1018); color: #ffe27a; }
.aw-cavien { --aw1: #ff8a1a; background: radial-gradient(circle, #ffe27a 0 5px, transparent 5.5px) 0 0 / 22px 18px, linear-gradient(#ffa23a, #ff7a1a); }
.aw-cavien b { background: linear-gradient(#ffd23a, #e8a010); color: #8a2a0a; text-shadow: none; }
.aw-phoco { --aw1: #8a3a1a; background: repeating-linear-gradient(90deg, #a8482a 0 14px, #8a3a1a 14px 16px), #a8482a; }
.aw-phoco::after { background: radial-gradient(circle at 7px 0, #8a3a1a 7px, transparent 7.5px) 0 0 / 14px 9px repeat-x; }
.aw-phoco b { background: linear-gradient(#2a1a10, #120a04); color: #ffd23a; }
.aw-topping { --aw1: #ff8ab4; background: radial-gradient(circle, #4a2a1a 0 3.4px, transparent 4px) 11px 22px / 22px 14px, repeating-linear-gradient(90deg, #ff9ac0 0 22px, #fff4f8 22px 44px); }
.aw-topping b { background: linear-gradient(#fff4f8, #ffd0e2); color: #c8306a; text-shadow: none; }
.aw-phovang { --aw1: #7a4a22; background: linear-gradient(rgba(255, 220, 160, .25), transparent 40%), repeating-linear-gradient(90deg, #9a6230 0 12px, #8a5428 12px 13px, #a86c38 13px 25px, #7a4a22 25px 26px); }
.aw-phovang::after { background: repeating-linear-gradient(90deg, #7a4a22 0 6px, #5a3418 6px 8px); height: 7px; border-bottom: 2px solid #4a2a14; }
.aw-phovang b { background: linear-gradient(#c8202a, #8a1018); color: #ffe27a; }

/* ---------- map: an illustrated street with the stalls as signboards ---------- */
.citymap { position: relative; padding: 16px 10px 22px; border-radius: 20px; overflow: hidden; border: 2px solid var(--ol); box-shadow: 0 4px 0 #2a160a;
  background: radial-gradient(circle at 12% 18%, rgba(110, 180, 90, .55) 0 34px, transparent 36px), radial-gradient(circle at 88% 46%, rgba(110, 180, 90, .5) 0 40px, transparent 42px),
    radial-gradient(circle at 18% 78%, rgba(110, 180, 90, .5) 0 30px, transparent 32px), radial-gradient(circle at 80% 88%, rgba(120, 190, 220, .55) 0 46px, transparent 48px),
    repeating-linear-gradient(0deg, transparent 0 46px, rgba(160, 120, 70, .1) 46px 48px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(160, 120, 70, .1) 46px 48px), #f6e8c8; }
.citymap .road { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.road-base { fill: none; stroke: #5a5450; stroke-width: 30; stroke-linecap: round; }
.road-line { fill: none; stroke: #ffe9a0; stroke-width: 3; stroke-dasharray: 12 10; }
.stop { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; width: 88%; margin: 0 0 20px; padding: 10px 14px 10px 10px; border: 2px solid var(--ol); border-radius: 18px;
  background: linear-gradient(#fffaf0, #f6e6c8); color: var(--ink); font-family: var(--round); text-align: left; box-shadow: 0 4px 0 #7a4a22, 0 8px 14px rgba(60, 30, 10, .25); }
.stop:nth-of-type(even) { margin-left: auto; flex-direction: row-reverse; text-align: right; padding: 10px 10px 10px 14px; }
.stop:last-child { margin-bottom: 0; }
.stop:active { transform: translateY(2px); box-shadow: 0 2px 0 #7a4a22; }
.stop-ic { display: grid; place-items: center; flex: none; width: 66px; height: 66px; border-radius: 50%; border: 3px solid var(--ol); font-size: 34px;
  background: radial-gradient(circle at 40% 32%, #fff, var(--th, #ffb43a) 60%, var(--th-d, #c8782a)); box-shadow: 0 3px 0 var(--ol), inset 0 -4px 0 rgba(0, 0, 0, .12); }
.stop-no { position: absolute; top: -11px; left: 14px; padding: 2px 10px; border: 2px solid var(--ol); border-radius: 99px; background: #7a3a14; color: #ffe7a6; font-size: 12px; font-weight: 900; }
.stop:nth-of-type(even) .stop-no { left: auto; right: 14px; }
.stop-tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stop-tx b { font-size: 16px; font-weight: 900; }
.stop-tx small { color: var(--ink-2); font-size: 12px; font-weight: 600; line-height: 1.35; }
.stop-tx em { color: #c8601a; font-size: 12px; font-style: normal; font-weight: 900; }
.stop-tx .st { color: #f2a91a; letter-spacing: -1px; text-shadow: 0 1px 0 #a86a00; }
.stop.locked { filter: grayscale(.9); background: #eee8dc; box-shadow: 0 3px 0 #a89a88; }
.stop.locked > * { opacity: .6; }
.stop.next { margin-top: 26px; box-shadow: 0 4px 0 #c8501a, 0 0 0 4px rgba(255, 154, 58, .5), 0 10px 18px rgba(200, 80, 20, .35); }
.stop .pin { position: absolute; right: 12px; top: -26px; padding: 3px 10px; border: 2px solid var(--ol); border-radius: 99px; background: linear-gradient(#ffa23a, #ff6a10); color: #fff; font-size: 11.5px; font-style: normal; font-weight: 900; animation: pulse .7s infinite alternate; }
.stop:nth-of-type(even) .pin { right: auto; left: 12px; }
.stop.done { box-shadow: 0 4px 0 #2f8a4a; }
.stop.done .stop-ic::after { content: '✓'; position: absolute; transform: translate(24px, -24px); width: 22px; height: 22px; border: 2px solid #fff; border-radius: 50%; background: #2fa35a; color: #fff; font-size: 13px; font-weight: 900; line-height: 18px; text-align: center; }
.th-school { --th: #ffd27a; --th-d: #d99a2a; } .th-office { --th: #a8d8ff; --th-d: #3a8ae0; } .th-oldtown { --th: #ffe08a; --th-d: #c8302a; }
.th-market { --th: #ffc8a8; --th-d: #c86a3a; } .th-lake { --th: #b8e6c8; --th-d: #3a9a5a; } .th-saigon { --th: #d8b8ff; --th-d: #6a3ab0; }
.stop-rev { display: block; margin-top: 2px; color: #5a6a3a; font-size: 11.5px; font-weight: 800; }
.stop.soon { opacity: .75; background: repeating-linear-gradient(-45deg, #fffaf0 0 12px, #f2e8d4 12px 24px); box-shadow: 0 3px 0 #b8a888; border-style: dashed; }
.stop.soon .stop-ic { --th: #e8e0d0; --th-d: #b8ac98; filter: grayscale(.4); }
.stop.soon em { color: #8a7a62; }
.daylist { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.dayb { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 12px; border: 2px solid var(--ol); border-radius: 14px; background: linear-gradient(#fffaf0, #f6e6c8); color: var(--ink); text-align: left; box-shadow: 0 3px 0 #7a4a22; }
.dayb:active { transform: translateY(2px); box-shadow: 0 1px 0 #7a4a22; }
.dayb b { font-size: 15px; font-weight: 900; }
.dayb .st { color: #f2a91a; font-size: 18px; letter-spacing: 1px; text-shadow: 0 1px 0 #a86a00; }
.dayb small { color: var(--ink-2); font-size: 12px; font-weight: 600; }
.dayb.locked { opacity: .5; cursor: default; box-shadow: none; }
.dayb.got { background: linear-gradient(#f2fff2, #d8f2d8); }
.dayb .newd { color: #c8501a; font-weight: 800; }
.dayb .dlv { font-size: 11px; letter-spacing: -1px; }

/* ================= play: ONE painted scene (owner 04/11/2026 — design principles in .ai/RULES.md) =================
   The sunny street (#stallBg) with the customer + a picture bubble · the steel cart in front = glass cabinet (#cabShelf trays),
   counter (#dish + #stove tools), rack (#rackShelf bottles / pots / shaker / bags) on wheels · the wooden tray of round
   picture buttons. No boxes around the zones: the cart parts are drawn to read as one object. Sizes come from
   VHArt.layout() (main.js sets --s cell, --cabCols, --rackCols, --cartW, --vitW, --workH, --sceneH on #stall).
   Doneness colours (VHStove.tone, owner 04/11/2026): YELLOW = chưa chín, GREEN = chín, RED = quá lửa / cháy — the bar under each item. */
#scPlay { position: fixed; z-index: 5; inset: 0; animation: none; }
body:not(.mb-full) #scPlay { top: calc(var(--mb-top, 52px) + env(safe-area-inset-top)); }
.stall { --ol: #4a2c1a; --green: #2fa84f; --yellow: #ffc21a; --red: #e5374f; --gap: 4px; --s: 60px; --post: 12px;
  position: absolute; inset: 0; overflow: hidden; color: var(--ink); font-family: var(--round);
  padding: env(safe-area-inset-top) env(safe-area-inset-right) 0 env(safe-area-inset-left); user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
  /* Warm brick pavement under the cart (the sidewalk of Bếp Việt đại chiến). */
  background-color: #d9967c;
  background-image: linear-gradient(rgba(255, 236, 200, .22), rgba(90, 40, 20, .14)), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='32'%3E%3Crect width='48' height='32' fill='%23d9967c'/%3E%3Cg fill='%23ecb59b' stroke='%23b8735a' stroke-width='1.4'%3E%3Crect x='1' y='1' width='22' height='14' rx='2.5'/%3E%3Crect x='25' y='1' width='22' height='14' rx='2.5'/%3E%3Crect x='-11' y='17' width='22' height='14' rx='2.5'/%3E%3Crect x='13' y='17' width='22' height='14' rx='2.5'/%3E%3Crect x='37' y='17' width='22' height='14' rx='2.5'/%3E%3C/g%3E%3Cg fill='%23fff' opacity='.28'%3E%3Crect x='4' y='3.5' width='11' height='2' rx='1'/%3E%3Crect x='28' y='3.5' width='11' height='2' rx='1'/%3E%3Crect x='16' y='19.5' width='11' height='2' rx='1'/%3E%3Crect x='40' y='19.5' width='6' height='2' rx='1'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 100% 100%, 48px 32px; }
.stall-bg { position: absolute; left: 0; right: 0; top: 0; height: calc(env(safe-area-inset-top) + 48px + var(--sceneH, 140px) + 34px); pointer-events: none; }
.stall-bg svg { width: 100%; height: 100%; display: block; }
.stall-bg::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 26px; background: linear-gradient(transparent, #e8d0a6); }

/* HUD: one thin cream bar on the stall's awning: ⏸ · day + clock · stall + money (+ goal) · stars + ❤ · chef */
.hud { position: relative; z-index: 8; display: flex; align-items: center; gap: 8px; height: 40px; margin: 4px 6px 0; padding: 0 4px 0 3px; border-radius: 99px;
  background: linear-gradient(rgba(255, 252, 244, .97), rgba(250, 236, 206, .95)); box-shadow: 0 1px 0 rgba(255, 255, 255, .8) inset, 0 3px 8px rgba(80, 40, 10, .28); }
.hud-pause { flex: none; display: flex; gap: 3.5px; align-items: center; justify-content: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%;
  background: radial-gradient(circle at 38% 30%, #fff4e6, #f3b37c 70%, #d98a4c); box-shadow: 0 2px 3px rgba(90, 40, 10, .35), inset 0 -2px 2px rgba(120, 50, 10, .25); }
.hud-pause i { width: 4px; height: 12px; border-radius: 2px; background: #6a3a1a; }
.hud-pause:active { transform: scale(.92); }
.hud-day { flex: none; display: flex; flex-direction: column; line-height: 1.05; }
.hud-day b { font-size: 13.5px; font-weight: 900; }
.hud-day em { display: flex; align-items: center; gap: 3px; color: var(--ink-2); font-size: 11px; font-style: normal; font-weight: 800; font-variant-numeric: tabular-nums; }
.clk { position: relative; width: 10px; height: 10px; border: 1.6px solid currentColor; border-radius: 50%; }
.clk::before { content: ''; position: absolute; left: 3.2px; top: 1px; width: 1.4px; height: 3.6px; border-radius: 1px; background: currentColor; }
.clk::after { content: ''; position: absolute; left: 3.6px; top: 3.6px; width: 2.8px; height: 1.4px; border-radius: 1px; background: currentColor; }
.hud-mid { position: relative; flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; line-height: 1; padding: 3px 8px 2px; border-radius: 14px;
  background: linear-gradient(#fffdf8, #f6e8cc); box-shadow: inset 0 1px 2px rgba(120, 70, 20, .22), 0 1px 0 #fff; }
.hud-mid small { max-width: 100%; overflow: hidden; color: #b4502a; font-size: 10px; font-weight: 900; white-space: nowrap; text-overflow: ellipsis; }
.hud-mid b { color: var(--ink); font-size: 18px; font-weight: 900; letter-spacing: -.3px; font-variant-numeric: tabular-nums; }
.hud-mid.bump b { animation: bump .45s ease; }
@keyframes bump { 40% { transform: scale(1.16); color: #1f9a4a; } }
.goalbar { position: relative; display: block; width: 100%; max-width: 130px; height: 4px; margin-top: 2px; border-radius: 9px; background: rgba(140, 90, 40, .22); }
.goalbar > i { position: absolute; inset: 0; border-radius: 9px; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, #ffa22a, #ffd84a); transition: transform .3s; }
.goalbar em { position: absolute; inset: 0; }
.goalbar em i { position: absolute; top: -1px; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: #e2cfa8; }
.goalbar em i.on { background: #ffb300; box-shadow: 0 0 0 1px #fff; }
.hud-rate { flex: none; display: flex; flex-direction: column; align-items: flex-end; line-height: 1.05; }
.hud-stars { color: #ffb300; font-size: 14px; letter-spacing: -1px; text-shadow: 0 1px 0 #a86a00; }
.hud-heart { color: #d23a4a; font-size: 10.5px; font-weight: 900; white-space: nowrap; }
.hud-heart.low { animation: blink .5s infinite alternate; }
@keyframes blink { to { opacity: .45; } }
.hud-chef { flex: none; width: 34px; height: 34px; overflow: hidden; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff4dc, #f2c27e); box-shadow: 0 0 0 2px #fff, 0 2px 4px rgba(80, 40, 10, .35); }
.hud-chef svg { width: 100%; height: 100%; transform: translateY(14%) scale(1.5); }

/* ---------- the play area: portrait = street (scene) · cart · tray, stacked ---------- */
.play { position: absolute; left: 0; right: 0; top: calc(env(safe-area-inset-top) + 48px); bottom: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; padding-bottom: env(safe-area-inset-bottom); }
.scene { position: relative; flex: none; width: 100%; height: var(--sceneH, 140px); }
.scene::before, .scene::after { content: ''; position: absolute; top: -6px; bottom: -40px; z-index: 0; width: 11px; pointer-events: none; border: 2px solid #4a2a14; border-radius: 3px;
  background: linear-gradient(90deg, #8a4f22, #d89a5a 35%, #b8743a 70%, #7a4520); box-shadow: 2px 0 4px rgba(60, 30, 10, .3); }
.scene::before { left: 2px; } .scene::after { right: 2px; }
/* The stall's awning runs behind the HUD; two lanterns hang from it at the edges. */
.stall .awning { position: absolute; left: 0; right: 0; top: calc(-48px - env(safe-area-inset-top)); height: calc(48px + env(safe-area-inset-top)); z-index: 0; box-shadow: 0 6px 10px rgba(60, 30, 10, .22); }
.stall .awning::after { height: 13px; }
.lanterns { position: absolute; left: 4px; right: 4px; top: 4px; z-index: 2; display: flex; justify-content: space-between; pointer-events: none; }
.lanterns svg { width: 18px; height: 31px; filter: drop-shadow(0 3px 2px rgba(60, 30, 10, .3)); transform-origin: 50% 0; animation: swing 3.2s ease-in-out infinite alternate; }
.lanterns svg:nth-child(2) { display: none; }
.lanterns svg.lights { position: absolute; left: -4px; top: -6px; width: calc(100% + 8px); height: 26px; filter: none; animation: none; }
@keyframes swing { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }

/* The customer stands in the street behind the cart; the bubble shows the order in pictures. */
.cust { position: absolute; left: 0; right: 0; top: 0; bottom: 0; z-index: 1; pointer-events: none; }
.cfig { position: absolute; left: 6px; bottom: -16px; height: calc(100% + 6px); max-height: 190px; aspect-ratio: 120 / 150; pointer-events: auto; filter: drop-shadow(2px 6px 5px rgba(60, 30, 10, .3)); }
.cfig svg { width: 100%; height: 100%; display: block; transform-origin: 50% 100%; animation: idle 2.6s ease-in-out infinite alternate; }
.cfig.leave svg { animation: none; }
@keyframes idle { to { transform: translateY(-2.5%) scale(1.012, .99); } }
.cfig.leave { animation: leave 1.1s ease forwards; }
@keyframes leave { 60% { transform: none; opacity: 1; } to { transform: translateX(-30px); opacity: 0; } }
.cfig.empty { opacity: 0; }
.bub { position: absolute; left: calc(min(var(--sceneH, 140px) * .8, 152px) + 8px); top: 22px; z-index: 3; display: flex; align-items: center; gap: 6px; max-width: calc(100% - min(var(--sceneH, 140px) * .8, 152px) - 56px);
  padding: 6px 10px 6px 6px; border-radius: 22px; background: linear-gradient(#ffffff, #fbf4e6); box-shadow: 0 4px 10px rgba(70, 35, 10, .28), inset 0 -2px 0 rgba(200, 160, 110, .25); pointer-events: auto; cursor: pointer; animation: bubIn .25s ease; }
.bub::before { content: ''; position: absolute; left: -9px; top: 50%; width: 16px; height: 16px; margin-top: -4px; background: #fdf9f1; transform: rotate(45deg) skew(10deg, 10deg); border-radius: 2px; box-shadow: -2px 2px 3px rgba(70, 35, 10, .12); }
@keyframes bubIn { from { transform: scale(.6); opacity: 0; } }
.ob-dish { --p: 1; --pc: var(--green); position: relative; flex: none; width: 66px; height: 66px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(closest-side, #fffaf0 calc(100% - 6px), transparent calc(100% - 5.5px)), conic-gradient(var(--pc) calc(var(--p) * 360deg), #ece2d0 0); }
.ob-dish .dish-svg { width: 56px; height: 48px; }
/* Two-dish order: the other dish, small on the ring's lower-left edge — "2" = still to come, green ✓ = already handed over. */
.ob-dish.two { margin-bottom: 8px; }
.ob-more { position: absolute; left: -12px; bottom: -14px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 40% 35%, #fff, #f1e6d2); box-shadow: 0 0 0 2px #fff, 0 2px 4px rgba(70, 35, 10, .35); }
.ob-more .dish-svg { width: 30px; height: 26px; }
.ob-more i { position: absolute; right: -4px; bottom: -4px; width: 16px; height: 16px; border-radius: 50%; background: var(--ol); color: #fff; font-size: 10.5px; font-style: normal; font-weight: 900; line-height: 16px; text-align: center; box-shadow: 0 0 0 1.5px #fff; }
.ob-more.got { opacity: .8; }
.ob-more.got i { background: var(--green); }
.bub[data-lv="mid"] .ob-dish { --pc: var(--yellow); }
.bub[data-lv="low"] .ob-dish { --pc: var(--red); }
.bub[data-lv="low"] { animation: hurry .5s ease-in-out infinite alternate; }
@keyframes hurry { to { transform: translateX(2px) rotate(.6deg); } }
.ob-parts { display: flex; flex-wrap: wrap; gap: 3px; align-content: center; min-width: 63px; max-width: 132px; }
.ob-p { position: relative; width: 30px; height: 30px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff, #f1e6d2); box-shadow: inset 0 0 0 1px rgba(160, 120, 70, .25); }
.ob-p .ico { width: 100%; height: 100%; display: block; }
.ob-p.ok::after { content: '✓'; position: absolute; right: -3px; top: -3px; width: 14px; height: 14px; border-radius: 50%; background: var(--green); color: #fff; font-size: 10px; font-weight: 900; line-height: 14px; text-align: center; box-shadow: 0 0 0 1.5px #fff; }
.ob-p.no { background: radial-gradient(circle at 40% 35%, #fff, #fde6e6); }
.ob-p.no::before { content: ''; position: absolute; inset: 2px; z-index: 2; border: 2.5px solid var(--red); border-radius: 50%; background: linear-gradient(45deg, transparent calc(50% - 1.3px), var(--red) calc(50% - 1.3px) calc(50% + 1.3px), transparent calc(50% + 1.3px)); }
.ob-p.no.bad { animation: shakeX .18s linear infinite; }
.ob-p.no .ico { opacity: .7; }
.bub.said { padding: 8px 14px; font-size: 14px; font-weight: 900; }
.bub.said.ok { color: #1f7a3a; }
.bub.said.bad { color: #b8202a; }
.bub.say { max-width: min(230px, calc(100% - 140px)); padding: 7px 12px; font-size: 12.5px; font-weight: 800; line-height: 1.3; }
/* Customers waiting further back: small busts with a patience bar, tap to serve them first. */
.queue { position: absolute; right: 6px; bottom: 8px; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.qc { --p: 1; position: relative; width: 42px; height: 46px; padding: 0; border: 0; border-radius: 50% 50% 12px 12px; background: none; filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .3)); }
.qc svg { width: 100%; height: 100%; display: block; }
.qc::after { content: ''; position: absolute; left: 4px; right: 4px; bottom: -3px; height: 4px; border-radius: 3px; background: linear-gradient(90deg, var(--green) calc(var(--p) * 100%), rgba(60, 30, 10, .25) 0); }
.qc.hurry::after { background: linear-gradient(90deg, var(--red) calc(var(--p) * 100%), rgba(60, 30, 10, .25) 0); }
.qc.on { display: none; }
.qc .qn { position: absolute; right: -3px; top: -3px; width: 15px; height: 15px; border-radius: 50%; background: var(--ol); color: #fff; font-size: 10px; font-style: normal; font-weight: 900; line-height: 15px; text-align: center; box-shadow: 0 0 0 1.5px #fff; }
.qmore { padding: 1px 7px; border-radius: 99px; background: rgba(255, 250, 240, .9); color: var(--ink-2); font-size: 11px; font-weight: 900; box-shadow: 0 1px 3px rgba(60, 30, 10, .3); }
.float { position: absolute; left: 30%; top: 30%; z-index: 6; display: flex; flex-direction: column; align-items: center; gap: 2px; pointer-events: none; opacity: 0; }
.float.show { animation: floatUp 1.4s ease-out forwards; }
.float b { padding: 2px 10px; border-radius: 99px; background: rgba(255, 255, 255, .92); font-size: 15px; font-weight: 900; white-space: nowrap; box-shadow: 0 2px 4px rgba(60, 30, 10, .3); }
.float .fm { color: #1f8a3a; } .float .ft { color: #d2408a; font-size: 13px; } .float .fh.up { color: #d23a4a; font-size: 12px; } .float .fh.down { color: #7a6a5a; font-size: 12px; }
.float .fg.g-perfect { background: linear-gradient(#ffe27a, #ffb300); color: #6a3a00; } .float .fg.g-wrong { background: #e5374f; color: #fff; }
@keyframes floatUp { 0% { opacity: 0; transform: translateY(16px) scale(.8); } 15% { opacity: 1; transform: none; } 80% { opacity: 1; } to { opacity: 0; transform: translateY(-34px); } }

/* ---------- the cart: one steel object ---------- */
.cart::after { content: ''; position: absolute; inset: 0; z-index: 4; border: 2.5px solid #4a2a14; border-radius: 34px 34px 7px 7px; pointer-events: none; }
.cart { position: relative; z-index: 4; flex: none; width: var(--cartW, 96%); display: grid; grid-template-columns: minmax(0, 1fr); grid-template-areas: "vit" "work" "lip" "rack"; margin-bottom: 18px;
  filter: drop-shadow(0 10px 8px rgba(70, 35, 10, .28)); }
/* Glass display cabinet: steel top rail + corner posts, glass with a warm strip light and sun reflections, glass shelves. */
.vit { grid-area: vit; position: relative; padding: 20px var(--post) 10px; border-radius: 34px 34px 0 0; border-top: 7px solid #c4ced6;
  background: radial-gradient(120% 60% at 50% 0, rgba(255, 255, 255, .9) 0 18%, transparent 19%) top / 100% 30px no-repeat, linear-gradient(0deg, #aab4bd, #e2e8ec) bottom / 100% 9px no-repeat,
    linear-gradient(#fff6d6 0 3px, rgba(255, 238, 190, .55) 3px 14px, transparent 30px) 0 11px / 100% 40px no-repeat,
    linear-gradient(170deg, rgba(246, 251, 255, .93), rgba(222, 238, 247, .86) 45%, rgba(240, 248, 252, .9)); }
.vit::before, .vit::after { content: ''; position: absolute; top: 22px; bottom: 0; width: var(--post); z-index: 3; pointer-events: none; background: linear-gradient(90deg, #8e9aa5, #f3f6f8 35%, #b6c0c9 70%, #8e9aa5); box-shadow: 0 0 0 .5px rgba(60, 70, 80, .45); }
.vit::before { left: 0; border-radius: 4px 4px 0 0; } .vit::after { right: 0; border-radius: 4px 4px 0 0; }
/* The glass hood's curved highlight. */
.vit > .shelf::before { content: ''; position: absolute; left: 8%; right: 8%; top: -22px; height: 16px; z-index: 2; pointer-events: none; border-top: 3px solid rgba(255, 255, 255, .85); border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
/* Potted plants on the pavement beside the cart (behind it). */
.side-pl { position: absolute; z-index: 5; width: 46px; height: 54px; pointer-events: none; filter: drop-shadow(0 4px 3px rgba(60, 30, 10, .3)); }
.side-pl svg { width: 100%; height: 100%; }
.side-pl.l { left: -34px; top: calc(var(--s) * 2 + 54px); }
.side-pl.r { right: -34px; bottom: 30px; }
#cabShelf { --cols: var(--cabCols, 5); position: relative; display: flex; flex-wrap: wrap; align-content: flex-start; justify-content: center; gap: var(--gap); width: calc(var(--cols) * var(--s) + (var(--cols) - 1) * var(--gap)); margin: 0 auto;
  background: repeating-linear-gradient(to bottom, transparent 0 calc(var(--s) - 5px), rgba(255, 255, 255, .95) calc(var(--s) - 5px) calc(var(--s) - 3px), rgba(110, 140, 160, .32) calc(var(--s) - 3px) var(--s), transparent var(--s) calc(var(--s) + var(--gap))); }
/* Sun reflections on the glass, over the trays (never catch taps). */
#cabShelf::after { content: ''; position: absolute; inset: -6px -4px; z-index: 2; pointer-events: none;
  background: linear-gradient(115deg, transparent 0 12%, rgba(255, 255, 255, .28) 12% 15%, transparent 15% 19%, rgba(255, 255, 255, .16) 19% 20%, transparent 20% 64%, rgba(255, 255, 255, .2) 64% 68%, transparent 68%); }
.vit-pet { position: absolute; right: 26px; top: -42px; z-index: 5; width: 46px; height: 46px; pointer-events: none; }
.vit-pet svg { width: 100%; height: 100%; }
/* The stall's potted plant (shop decor) stands on the pavement beside the button tray. */
.plant-spot { position: absolute; left: 8px; bottom: calc(4px + env(safe-area-inset-bottom)); z-index: 4; width: 50px; height: 58px; pointer-events: none; filter: drop-shadow(0 4px 3px rgba(60, 30, 10, .3)); }
.plant-spot svg { width: 100%; height: 100%; }
/* Brushed steel counter top (seen from a little above) with the cabinet's soft shadow on it. */
.work { grid-area: work; position: relative; display: flex; align-items: stretch; gap: 6px; height: var(--workH, 120px); padding: 8px 10px 4px;
  background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#d6dde3, #eef2f5 40%, #cfd7de); }
/* The counter's front edge: a polished steel band. */
.lip { grid-area: lip; height: 12px; background: linear-gradient(#ffffff 0 1.5px, #c2cbd3 1.5px, #e8edf1 45%, #a3aeb8 80%, #6f7a85); box-shadow: inset 0 2px 0 #4a2a14, inset 0 -2px 0 #4a2a14, 0 2px 2px rgba(60, 30, 10, .25); }
/* Under the counter: the stall's coloured panel, steel shelf rails per row, steel legs. */
.rack { grid-area: rack; position: relative; padding: 8px var(--post) 8px; background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#9fd6c0, #7cc0a6); border-radius: 0 0 6px 6px; }
.rack { box-shadow: inset 0 -9px 0 #9a5c2a, inset 0 -11px 0 #d8a060; }
.rack::before, .rack::after { content: ''; position: absolute; top: 0; bottom: -10px; width: var(--post); z-index: 3; pointer-events: none; background: linear-gradient(90deg, #7a4520, #d89a5a 35%, #b8743a 70%, #7a4520); border-radius: 0 0 3px 3px; box-shadow: 0 0 0 .5px rgba(60, 30, 10, .5); }
.rack::before { left: 0; } .rack::after { right: 0; }
#rackShelf { --cols: var(--rackCols, 5); display: flex; flex-wrap: wrap; align-content: flex-start; justify-content: center; gap: var(--gap); width: calc(var(--cols) * var(--s) + (var(--cols) - 1) * var(--gap)); margin: 0 auto;
  background: repeating-linear-gradient(to bottom, transparent 0 calc(var(--s) - 6px), #f0bd78 calc(var(--s) - 6px) calc(var(--s) - 4px), #c8864a calc(var(--s) - 4px) calc(var(--s) + 1px), #7a4520 calc(var(--s) + 1px) calc(var(--s) + 3px), rgba(0, 0, 0, .14) calc(var(--s) + 3px) calc(var(--s) + var(--gap))); }
.rack:empty, #rackShelf:empty { display: none; }
.wheel { position: absolute; bottom: -17px; z-index: 5; width: 28px; height: 28px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle at 42% 38%, #f2f4f6 0 3px, #a8b2bc 3.5px 6px, #2a2a2e 6.5px 10px, #4a4a52 10.5px 12px, #1e1e22 12.5px); box-shadow: 0 4px 4px rgba(40, 20, 6, .35); }
.wheel.wl { left: 4px; } .wheel.wr { right: 4px; }

/* ---------- one ingredient on the cart: the art only (no names), a small round badge ----------
   badge: step number (orange) of the order being made, ✓ in the dish, a flame while cooking, ⊘ the customer said no. */
.pic { pointer-events: none; user-select: none; -webkit-user-drag: none; -webkit-touch-callout: none; }
.tray { position: relative; width: var(--s); height: var(--s); padding: 0; border: 0; background: none; touch-action: none; cursor: pointer; }
.tray .art { position: absolute; inset: 0; display: flex; align-items: flex-end; justify-content: center; transition: transform .12s; }
.tray .art img { width: 100%; height: 100%; display: block; }
.tray.rk-pour .art img, .tray.rk-shake .art img { width: 96%; height: 96%; }
.tray.press .art { transform: translateY(2px) scale(.93); }
.tray .bdg { position: absolute; right: 0; top: 0; z-index: 3; display: none; place-items: center; min-width: 19px; height: 19px; padding: 0 4px; border-radius: 99px;
  background: linear-gradient(#ffb44a, #ff7a10); color: #fff; font-size: 11px; font-style: normal; font-weight: 900; box-shadow: 0 0 0 1.5px #fff, 0 2px 3px rgba(60, 30, 10, .35); }
.tray.s-need .bdg, .tray.s-ok .bdg, .tray.s-fire .bdg, .tray.s-no .bdg { display: grid; }
.tray.s-ok .bdg { background: var(--green); }
.tray.s-meh .bdg { background: #d8a020; }
.tray.s-fire .bdg { background: linear-gradient(#ffd23a, #ff6a10); }
.tray.s-no .bdg { background: var(--red); }
.tray.s-cur .art { filter: drop-shadow(0 0 4px #ffcf4a) drop-shadow(0 0 2px #ffcf4a); }
.tray.s-no.s-bad .art { animation: shakeX .18s linear infinite; }
.tray.holding .art { transform: rotate(-8deg) translateY(-3px); }
.tray.holding.inzone .art { filter: drop-shadow(0 0 6px var(--green)); }
.tray.holding.pastzone .art { filter: drop-shadow(0 0 6px var(--red)); }
.tray.pop .art { animation: dpop .3s ease; }
@keyframes shakeX { 25% { transform: translateX(-2px); } 75% { transform: translateX(2px); } }

/* ---------- on the counter: the dish being made on a wooden board, then the tools ---------- */
.dishbox { position: relative; flex: 0 0 31%; min-width: 0; min-height: 0; display: grid; place-items: end center; }
.dishbox::before { content: ''; position: absolute; left: 4%; right: 4%; bottom: 0; height: 30%; border-radius: 50%; background: radial-gradient(closest-side, #e8b878, #c88a4a 75%, #8a5626 98%, transparent);
  box-shadow: 0 3px 3px rgba(60, 30, 10, .3); }
.dish { position: relative; z-index: 1; width: 100%; height: 100%; min-height: 0; display: grid; place-items: end center; overflow: visible; touch-action: none; cursor: grab; }
.dish .dish-svg { width: 100%; max-height: 100%; filter: drop-shadow(0 3px 2px rgba(60, 30, 10, .3)); }
.dish.pop .dish-svg, .dishbox .pop .dish-svg { animation: dpop .3s ease; }
@keyframes dpop { 40% { transform: scale(1.08); } }
.dishbox.none .dish { opacity: 0; }
.dishbox.done .dish .dish-svg { filter: drop-shadow(0 0 8px #ffd23a) drop-shadow(0 3px 2px rgba(60, 30, 10, .3)); animation: dpop 1s ease infinite; }
.dishbox.shaking .dish { animation: shake .12s linear infinite; }
@keyframes shake { 25% { transform: translate(-3px, 1px) rotate(-3deg); } 75% { transform: translate(3px, -1px) rotate(3deg); } }
/* Pour / shake gauge beside the dish: yellow (not yet) → GREEN band (stop!) → red (too much) — same colours as the stove. */
.pourfx { position: absolute; z-index: 5; right: 0; top: -6px; width: 46px; height: 46px; pointer-events: none; animation: tilt .25s ease forwards; transform-origin: 70% 20%; }
.pourfx svg { width: 100%; height: 100%; }
.pourfx .stream { position: absolute; left: 6px; top: 36px; width: 5px; height: 36px; border-radius: 3px; opacity: .85; transform-origin: 50% 0; animation: stream .18s linear infinite alternate; }
@keyframes tilt { from { transform: rotate(0); } to { transform: rotate(-38deg); } }
@keyframes stream { from { transform: scaleY(.9) scaleX(.8); } to { transform: scaleY(1.05) scaleX(1.15); } }
.fillg { --zt: 80%; position: absolute; z-index: 6; left: -2px; top: 4%; bottom: 6%; width: 14px; border-radius: 8px; pointer-events: none; box-shadow: 0 0 0 2px #fff, 0 2px 4px rgba(60, 30, 10, .4);
  background: linear-gradient(0deg, #fff0b8 var(--zt), #ffc4c4 var(--zt)); }
.fillg .zone { position: absolute; left: 0; right: 0; background: repeating-linear-gradient(45deg, #2fa84f 0 4px, #6fd88a 4px 8px); }
.fillg .bar { position: absolute; left: 2px; right: 2px; bottom: 2px; height: calc(100% - 4px); border-radius: 6px; transform-origin: 50% 100%; transform: scaleY(0); background: linear-gradient(#ffe066, #ffb400); opacity: .9; }
.fillg.inzone .bar { background: linear-gradient(#5ad87a, #2fa84f); }
.fillg.pastzone .bar { background: linear-gradient(#ff8a8a, #e5374f); }
.fillg .stop { position: absolute; left: -4px; top: -24px; width: max-content; padding: 2px 8px; border-radius: 10px; background: var(--green); color: #fff; font-size: 12px; font-weight: 900; white-space: nowrap; opacity: 0; transform: scale(.6); transition: opacity .1s, transform .1s; box-shadow: 0 0 0 2px #fff; }
.fillg.inzone .stop { opacity: 1; transform: none; animation: beat .35s ease-in-out infinite alternate; }
.fillg.pastzone .stop { opacity: 1; transform: none; background: var(--red); color: #fff; }
.fillg.pastzone .stop::after { content: ' Tràn!'; }
@keyframes beat { to { transform: scale(1.12); } }

/* Tools on the counter: each drawn at 4:3 inside its cell (container units), the items sit on the cooking surface. */
.stove { position: relative; flex: 1; min-width: 0; container-type: size; }
.stg { position: absolute; inset: 0; display: grid; gap: 4px; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
/* A tall counter area (landscape): two tools stack instead of shrinking side by side. */
@container (aspect-ratio < 1.1) { .stove.n2 .stg { grid-auto-flow: row; grid-auto-rows: minmax(0, 1fr); grid-template-columns: minmax(0, 1fr); } }
.stn { position: relative; min-height: 0; container-type: size; display: grid; place-items: end center; }
.stn-box { position: relative; width: min(100cqw, 133.3cqh); height: min(100cqh, 75cqw); }
.stn.pop .stn-box { animation: dpop .3s ease; }
.stn-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.stn-al { position: absolute; z-index: 6; top: -2px; right: 0; display: none; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: #fff; font-size: 12px; font-style: normal; font-weight: 900; box-shadow: 0 0 0 2px #fff, 0 2px 4px rgba(0, 0, 0, .4); pointer-events: none; }
.stn[data-al="perfect"] .stn-al, .stn[data-al="ready"] .stn-al, .stn[data-al="flip"] .stn-al { display: grid; background: var(--green); color: #fff; animation: beat .4s ease-in-out infinite alternate; }
.stn[data-al="over"] .stn-al, .stn[data-al="burnt"] .stn-al { display: grid; background: var(--red); animation: shakeX .18s linear infinite; }
.slot { position: absolute; z-index: 2; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; }
.stn-board .slot { border-radius: 14px; }
.stn.flash .stn-box { animation: flash .5s ease 2; }
@keyframes flash { 50% { filter: drop-shadow(0 0 7px #ffd23a) drop-shadow(0 0 2px #ffd23a); } }
.stn.over-ok .stn-box, .slot.over-ok, .dishbox.over-ok, .scene.over-ok .cfig, .rbtn.over-ok { filter: drop-shadow(0 0 6px #3ec46d) drop-shadow(0 0 2px #3ec46d); }
.stn.over-bad .stn-box, .slot.over-bad, .dishbox.over-bad { filter: drop-shadow(0 0 5px #e5374f); }
.stn-grill .coal { animation: coal 1.4s ease-in-out infinite alternate; }
@keyframes coal { to { opacity: .6; } }
.stn.on .stn-svg .bub { animation: coal .5s ease-in-out infinite alternate; }
/* An item on a tool: food colour follows doneness --d; the small bar under it (--r countdown) is the tone colour. */
.ck { --d: 0; --u: 0; --r: 0; --rc: var(--yellow); position: absolute; inset: 0; display: block; padding: 0; border: 0; border-radius: 50%; background: none; touch-action: none; cursor: pointer; }
.ck::before { content: ''; position: absolute; inset: -8px; border-radius: 50%; }
.ck-bar { position: absolute; left: 14%; right: 14%; bottom: -4px; z-index: 4; height: 5px; border-radius: 3px; background: rgba(40, 24, 12, .5); box-shadow: 0 0 0 1px rgba(255, 255, 255, .85); overflow: hidden; pointer-events: none; }
.ck-bar i { position: absolute; inset: 0; border-radius: 3px; background: var(--rc); transform-origin: 0 50%; transform: scaleX(var(--r)); }
.ck.chop .ck-bar i { transform: scaleX(calc(var(--cut, 0))); }
.ck.t-green { --rc: var(--green); }
.ck.t-red { --rc: var(--red); }
.ck-f { position: absolute; inset: 0; display: block; transition: transform .1s; }
.ck .food { width: 144%; height: 144%; margin: -22%; display: block; filter: drop-shadow(0 2px 1px rgba(0, 0, 0, .35)); }
.ck.fry .food { filter: sepia(calc(min(var(--d), 1.1) * .75)) saturate(calc(1 + min(var(--d), 1) * .7)) brightness(calc(1.08 - max(var(--d) - 1.05, 0) * .8)) drop-shadow(0 2px 1px rgba(0, 0, 0, .35)); }
.ck:not(.fry) .food { opacity: calc(.55 + min(var(--d), 1) * .45); filter: saturate(calc(1.15 - max(var(--d) - 1.25, 0) * 1.2)) drop-shadow(0 2px 1px rgba(0, 0, 0, .3)); }
.stn-board .ck .food { opacity: 1; filter: drop-shadow(0 2px 1px rgba(0, 0, 0, .3)); }
.ck-up { position: absolute; right: -1px; top: -1px; z-index: 3; width: 10px; height: 10px; border-radius: 50%; background: #9ad89a; box-shadow: 0 0 0 1.5px #fff; }
.ck.flipme .ck-up { background: var(--green); }
.ck.t-green::after, .ck.t-red::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; pointer-events: none; animation: glow .55s ease-in-out infinite alternate; }
.ck.t-green::after { box-shadow: 0 0 10px 3px rgba(47, 168, 79, .9); }
.ck.t-red::after { box-shadow: 0 0 10px 3px rgba(229, 55, 79, .85); animation-duration: .3s; }
.stn-board .ck.t-green::after { border-radius: 14px; }
@keyframes glow { from { opacity: .3; } to { opacity: 1; } }
.ck.k-over .ck-f { animation: jitter .16s linear infinite; }
.ck.k-burnt .food { filter: brightness(.28) saturate(.3) drop-shadow(0 2px 1px rgba(0, 0, 0, .4)) !important; }
@keyframes jitter { 25% { transform: translate(-1px, 1px); } 75% { transform: translate(1px, -1px); } }
.ck .smoke { position: absolute; left: 50%; top: -6px; width: 0; height: 0; display: none; pointer-events: none; }
.ck.k-burnt .smoke, .ck.fry.k-over .smoke { display: block; }
.ck .smoke i { position: absolute; left: -9px; top: 0; width: 18px; height: 18px; border-radius: 50%; background: rgba(50, 50, 50, .7); animation: smoke 1.2s ease-out infinite; }
.ck.k-over .smoke i { background: rgba(220, 220, 220, .5); }
.ck .smoke i:nth-child(2) { animation-delay: -.4s; } .ck .smoke i:nth-child(3) { animation-delay: -.8s; }
@keyframes smoke { from { transform: translate(0, 0) scale(.5); opacity: .9; } to { transform: translate(6px, -28px) scale(1.6); opacity: 0; } }
.ck.flipping .ck-f { animation: flip .36s ease-out; }
@keyframes flip { 0% { transform: none; } 40% { transform: translateY(-14px) scaleY(.1); } 100% { transform: none; } }
.ck-f.up .food { transform: scaleX(-1); }
.ck:active .ck-f { transform: scale(.9); }
.stn-board .ck { border-radius: 14px; }
.ck .kn { position: absolute; right: -14px; top: -10px; width: 38px; height: 19px; transform-origin: 90% 50%; transform: rotate(-25deg); pointer-events: none; }
.ck .kn svg { width: 100%; height: 100%; }
.ck.chopping .kn { animation: chop .16s ease-in; }
.ck.chopping .ck-f { animation: thud .16s ease-in; }
@keyframes chop { 50% { transform: rotate(8deg) translate(-6px, 8px); } }
@keyframes thud { 50% { transform: scale(1.06, .94); } }
.spark { position: absolute; left: 50%; top: 30%; z-index: 6; width: 24px; height: 24px; margin-left: -12px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, #fff 0 2px, rgba(255, 220, 90, .9) 3px, rgba(255, 200, 40, 0) 12px); animation: spark .7s ease-out forwards; }
@keyframes spark { from { transform: scale(.4); opacity: 1; } to { transform: translateY(-22px) scale(2); opacity: 0; } }
.puff { position: fixed; z-index: 99; width: 30px; height: 30px; margin: -15px 0 0 -15px; border-radius: 50%; pointer-events: none; background: radial-gradient(circle, rgba(90, 90, 90, .7), rgba(90, 90, 90, 0) 70%); animation: puff .7s ease-out forwards; }
@keyframes puff { from { transform: scale(.5); opacity: 1; } to { transform: translateY(-30px) scale(2.2); opacity: 0; } }
/* Drag ghost + flying pieces */
.ghost { position: fixed; left: 0; top: 0; z-index: 100; width: 60px; height: 60px; pointer-events: none; filter: drop-shadow(0 8px 6px rgba(0, 0, 0, .35)); will-change: transform; }
.ghost svg, .ghost img { width: 100%; height: 100%; display: block; }
.ghost.g-dish { width: 110px; height: 96px; margin: -24px 0 0 -30px; }
.lift { opacity: .35; }
body.dragging, body.dragging * { cursor: grabbing !important; }
.fly { position: fixed; z-index: 99; width: 46px; height: 46px; pointer-events: none; will-change: transform; }
.fly svg, .fly img { width: 100%; height: 100%; display: block; }
/* A piece dropped straight into the dish (tap without a source): falls in from above. */
.drop { position: absolute; left: 50%; top: 0; z-index: 3; width: 40px; height: 40px; margin-left: -20px; pointer-events: none; animation: dropIn .5s ease-in forwards; }
.drop img { width: 100%; height: 100%; display: block; }
@keyframes dropIn { from { transform: translateY(-30px) scale(1.1); opacity: 0; } 30% { opacity: 1; } to { transform: translateY(30px) scale(.7); opacity: 0; } }

/* ---------- the wooden tray: round picture-only buttons (aria-labels name them) ---------- */
.dock { position: relative; z-index: 5; flex: none; display: flex; align-items: center; gap: 12px; height: 58px; margin-bottom: 6px; padding: 0 12px; border-radius: 18px;
  background: repeating-linear-gradient(178deg, rgba(255, 220, 160, .16) 0 2px, transparent 2px 9px), linear-gradient(#c88a4c, #9a5c2a 70%, #7a4520);
  box-shadow: inset 0 2px 0 rgba(255, 226, 170, .55), inset 0 -3px 0 rgba(60, 30, 10, .35), 0 4px 8px rgba(60, 30, 10, .35); }
.rbtn { position: relative; flex: none; display: grid; place-items: center; width: 46px; height: 46px; padding: 0; border: 0; border-radius: 50%;
  background: radial-gradient(circle at 40% 32%, #fffdf8, #f1e2c6 65%, #d9bf94); box-shadow: 0 3px 0 #5a3416, 0 5px 6px rgba(40, 20, 6, .35), inset 0 -2px 3px rgba(150, 100, 50, .3); }
.rbtn .btn-ico { width: 30px; height: 30px; }
.rbtn:active { transform: translateY(3px); box-shadow: 0 0 0 #5a3416, inset 0 -2px 3px rgba(150, 100, 50, .3); }
.rbtn.serve { width: 54px; height: 54px; margin-left: 8px; }
.rbtn.serve .sv-dish { width: 46px; height: 40px; display: grid; place-items: center; }
.rbtn.serve .sv-dish svg { width: 100%; height: 100%; }
.rbtn.serve.off .sv-dish { opacity: .45; filter: grayscale(.5); }
.rbtn.serve .sv-ring { position: absolute; inset: -5px; border-radius: 50%; pointer-events: none; }
.rbtn.serve.go { background: radial-gradient(circle at 40% 32%, #fffbe0, #ffd84a 70%, #f2a91a); animation: serveGo .6s ease-in-out infinite alternate; }
.rbtn.serve.go .sv-ring { box-shadow: 0 0 0 3px #ffe27a, 0 0 16px 5px rgba(255, 200, 60, .95); animation: glow .5s ease-in-out infinite alternate; }
.rbtn:disabled { opacity: .7; }
@keyframes serveGo { to { transform: scale(1.08); } }
@keyframes pulse { to { transform: scale(1.04); } }

/* ---------- guidance: the glove + one 1–3 word tag, the glow around the next thing to touch (opacity / transform only) ---------- */
.ghand { position: absolute; left: 0; top: 0; z-index: 40; width: 36px; height: 42px; pointer-events: none; transition: transform .28s ease; will-change: transform; }
.gh-in { display: block; width: 100%; height: 100%; filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .45)); }
.gh-in svg { width: 100%; height: 100%; display: block; }
.ghand.m-tap .gh-in { animation: ghTap .8s ease-in-out infinite; }
.ghand.m-hold .gh-in { animation: ghHold 1.3s ease-in-out infinite; }
.ghand.m-drag .gh-in { animation: ghDrag 1.7s ease-in-out infinite; }
.ghand.m-wait .gh-in { opacity: .55; animation: ghWait 2.2s ease-in-out infinite; }
.ghand.nohand .gh-in { visibility: hidden; }
@keyframes ghTap { 0%, 100% { transform: translate(0, 10px); } 45% { transform: translate(0, 0) scale(.9); } }
@keyframes ghHold { 0% { transform: translate(0, 10px); } 25%, 75% { transform: translate(0, 0) scale(.86); } 100% { transform: translate(0, 10px); } }
@keyframes ghDrag { 0% { transform: translate(0, 10px); opacity: 0; } 12% { transform: translate(0, 0) scale(.9); opacity: 1; } 72% { transform: translate(var(--dx), var(--dy)) scale(.9); opacity: 1; } 88%, 100% { transform: translate(var(--dx), var(--dy)) scale(.9); opacity: 0; } }
@keyframes ghWait { 50% { transform: translate(0, 6px); } }
.gh-t { position: absolute; left: 32px; top: 30px; padding: 2px 8px; border-radius: 99px; background: #fffaf0; color: var(--ol); font-size: 11.5px; font-weight: 900; white-space: nowrap; box-shadow: 0 2px 4px rgba(60, 30, 10, .4); }
.gh-t:empty { display: none; }
.ghand.flipx .gh-t { left: auto; right: 26px; }
.ghand.flipy .gh-t { top: -30px; }
.ghand.lv-green .gh-t { background: var(--green); color: #fff; }
.ghand.lv-red .gh-t { background: var(--red); color: #fff; }
.ghand.lv-yellow .gh-t { background: #fff3c4; color: #6a4a00; }
.ghand.lv-good .gh-t { background: linear-gradient(#ffe27a, #ffb300); }
.g-target::after { content: ''; position: absolute; inset: -3px; z-index: 4; border-radius: 12px; box-shadow: 0 0 0 2.5px #ff9a1a, 0 0 12px 3px rgba(255, 154, 26, .8); animation: glow .55s ease-in-out infinite alternate; pointer-events: none; }
.ck.g-target::after, .qc.g-target::after, .rbtn.g-target::after { border-radius: 50%; inset: -5px; }
.g-drop .stn-box, .dishbox.g-drop .dish { filter: drop-shadow(0 0 5px rgba(255, 176, 40, .95)); }

/* Toasts while selling: 1–3 words, one at a time, in the street above the cart. */
.toastbox { position: absolute; left: 0; right: 0; top: calc(env(safe-area-inset-top) + 52px); z-index: 30; display: flex; justify-content: center; pointer-events: none; }
.toastbox .vh-t { padding: 5px 14px; border-radius: 99px; background: rgba(255, 250, 240, .96); color: var(--ink); font-size: 13.5px; font-weight: 900; box-shadow: 0 3px 8px rgba(60, 30, 10, .35); animation: tIn .2s ease; white-space: nowrap; }
.toastbox .vh-t.t-bad { background: linear-gradient(#ff7a7a, #e5374f); color: #fff; animation: tIn .2s ease, shakeX .18s linear .2s 3; }
.toastbox .vh-t.t-done, .toastbox .vh-t.t-warn { background: linear-gradient(#fff3b0, #ffd23a); color: #5a3a00; }
.toastbox .vh-t.t-raw, .toastbox .vh-t.t-good { background: linear-gradient(#e8ffe8, #b8e8be); color: #145a2a; }
@keyframes tIn { from { transform: translateY(-8px) scale(.9); opacity: 0; } }

/* Each stall: only the counter tint + rack panel colour change (one warm palette). */
.lk-cart .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#d6dde3, #eef2f5 40%, #cfd7de); }
.lk-cart .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#9fd6c0, #7cc0a6); }
.lk-kiosk .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#dbe2e7, #f2f5f7 40%, #d2dadf); }
.lk-kiosk .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .16) 46px 48px), linear-gradient(#f6c98a, #e8a95a); }
.lk-pho .work { background: linear-gradient(rgba(60, 40, 20, .2), transparent 12px), repeating-linear-gradient(92deg, rgba(255, 230, 190, .16) 0 2px, transparent 2px 11px), linear-gradient(#d8a868, #c08a4c 50%, #b07a3c); }
.lk-pho .rack { background: linear-gradient(rgba(0, 0, 0, .24), transparent 9px), repeating-linear-gradient(92deg, transparent 0 40px, rgba(0, 0, 0, .12) 40px 42px), linear-gradient(#a8693a, #7e4a20); }
.lk-market .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#d6dde3, #eef2f5 40%, #cfd7de); }
.lk-market .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#e89a7a, #d27a58); }
.lk-bun .work { background: linear-gradient(rgba(60, 40, 20, .2), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 240, 200, .2) 0 2px, transparent 2px 14px), linear-gradient(#ecd2a0, #d8b47a); }
.lk-bun .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#a6cfa0, #84b47e); }
.lk-inox .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .26) 0 1px, transparent 1px 4px), linear-gradient(100deg, #eef2f5, #c2cbd3 40%, #e8edf0 60%, #b6c0c9); }
.lk-inox .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#f4b4a0, #e88e74); }
/* The 9 stalls of 04/11/2026: warm wood / steel counters, a rack tint per stall. */
.lk-xoi .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 245, 210, .2) 0 2px, transparent 2px 13px), linear-gradient(#e6c48c, #d0a466); }
.lk-xoi .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#9ccf7a, #74b056); }
.lk-xien .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#d6dde3, #eef2f5 40%, #cfd7de); }
.lk-xien .rack { background: linear-gradient(rgba(0, 0, 0, .22), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .12) 46px 48px), linear-gradient(#f0a070, #d8784a); }
.lk-topping .work { background: linear-gradient(rgba(60, 40, 20, .16), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .24) 0 1px, transparent 1px 5px), linear-gradient(#fdf2f6, #f6dce6 50%, #eed0dc); }
.lk-topping .rack { background: linear-gradient(rgba(0, 0, 0, .18), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .18) 46px 48px), linear-gradient(#ffb8d0, #f292b4); }
.lk-sinhto .work { background: linear-gradient(rgba(60, 40, 20, .16), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .24) 0 1px, transparent 1px 5px), linear-gradient(#fffaf0, #f4ecd8 50%, #ece0c4); }
.lk-sinhto .rack { background: linear-gradient(rgba(0, 0, 0, .18), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .16) 46px 48px), linear-gradient(#ffd27a, #f4b24a); }
.lk-che .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .22) 0 1px, transparent 1px 5px), linear-gradient(#e2eef0, #f4f8f8 40%, #d4e2e4); }
.lk-che .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#a8dccc, #7cc4ae); }
.lk-combui .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .26) 0 1px, transparent 1px 4px), linear-gradient(100deg, #eef2f5, #c2cbd3 40%, #e8edf0 60%, #b6c0c9); }
.lk-combui .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#9cc4e8, #74a6d4); }
.lk-phovang .work { background: linear-gradient(rgba(60, 40, 20, .2), transparent 12px), repeating-linear-gradient(92deg, rgba(255, 230, 190, .16) 0 2px, transparent 2px 11px), linear-gradient(#c89458, #a87638 50%, #9a6a30); }
.lk-phovang .rack { background: linear-gradient(rgba(0, 0, 0, .24), transparent 9px), repeating-linear-gradient(92deg, transparent 0 40px, rgba(0, 0, 0, .12) 40px 42px), linear-gradient(#c8902a, #a0701a); }
.lk-hue .work { background: linear-gradient(rgba(60, 40, 20, .2), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 240, 200, .2) 0 2px, transparent 2px 14px), linear-gradient(#ead0a4, #d4b07c); }
.lk-hue .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#c8a8e0, #a886cc); }
.lk-oc .work { background: linear-gradient(rgba(60, 40, 20, .18), transparent 12px), repeating-linear-gradient(90deg, rgba(255, 255, 255, .26) 0 1px, transparent 1px 4px), linear-gradient(100deg, #eef2f5, #c2cbd3 40%, #e8edf0 60%, #b6c0c9); }
.lk-oc .rack { background: linear-gradient(rgba(0, 0, 0, .2), transparent 9px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .14) 46px 48px), linear-gradient(#8ad0e0, #5ab4c8); }

/* ---------- landscape / desktop: the same composition — cart in the middle of a wider street ---------- */
@media (orientation: landscape) and (min-width: 600px) {
  .stall-bg { height: max(62%, 100% - var(--cartH, 300px) * .55); }
  .stall-bg::after { display: none; }
  .play { top: calc(env(safe-area-inset-top) + 46px); display: block; }
  .scene { position: absolute; inset: 0; height: auto; }
  .stall .awning { top: calc(-46px - env(safe-area-inset-top)); height: calc(46px + env(safe-area-inset-top)); }
  .hud { max-width: 760px; margin: 3px auto 0; }
  .cart { position: absolute; left: 50%; top: auto; bottom: calc(18px + env(safe-area-inset-bottom)); width: var(--cartW); margin: 0 0 0 calc(var(--cartW) / -2); grid-template-columns: var(--vitW) minmax(0, 1fr); grid-template-areas: "vit work" "lip lip" "rack rack"; }
  .vit { height: var(--workH); border-radius: 34px 0 0 0; }
  .cart::after { border-radius: 34px 9px 7px 7px; }
  .side-pl { display: none; }
  .vit::after { border-radius: 0; }
  #cabShelf { height: calc(100% - 0px); align-content: start; }
  .work { height: var(--workH); border-radius: 0 9px 0 0; padding: 10px 10px 6px; }
  .work .dishbox { flex: 0 0 32%; }
  /* Three tools beside the dish: two rows. */
  .stove.n3 .stg, .stove.n4 .stg { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rack { border-radius: 0 0 6px 6px; }
  /* Street columns beside the cart: the customer stands on the left with the bubble above, the others wait on the right. */
  .cfig { left: calc(var(--sideW) / 2); bottom: 0; width: min(var(--sideW) - 6px, 200px); height: auto; max-height: none; transform: translateX(-50%); }
  .cfig.leave { animation: leaveL 1.1s ease forwards; }
  @keyframes leaveL { 60% { transform: translateX(-50%); opacity: 1; } to { transform: translateX(-90%); opacity: 0; } }
  .bub { left: calc(var(--sideW) / 2); top: auto; bottom: calc(min(var(--sideW) - 6px, 200px) * 1.25 + 4px); transform: translateX(-50%); width: min(var(--sideW) - 12px, 230px); max-width: none; flex-direction: column; padding: 8px; }
  .bub::before { left: 50%; top: auto; bottom: -7px; margin: 0 0 0 -8px; }
  .ob-parts { justify-content: center; max-width: none; }
  .queue { right: 0; top: 8px; bottom: auto; flex-direction: row; flex-wrap: wrap; justify-content: center; width: var(--sideW); }
  .float { left: 4%; top: 18%; }
  .dock { position: absolute; right: calc(var(--sideW) / 2); bottom: calc(10px + env(safe-area-inset-bottom)); transform: translateX(50%); flex-direction: column; height: auto; width: 66px; padding: 10px 0; gap: 10px; }
  .rbtn.serve { margin: 6px 0 0; }
  .toastbox { top: calc(env(safe-area-inset-top) + 50px); }
  /* Right street column: the waiting customers, then the stall's plant + pet, then the button tray. */
  .plant-spot { left: auto; right: calc(var(--sideW) / 2 + 2px); top: auto; bottom: calc(214px + env(safe-area-inset-bottom)); width: 40px; height: 48px; }
  .vit-pet { left: calc(var(--cartW) + var(--sideW) / 2 + 2px); right: auto; top: calc(var(--cartH) - 240px); width: 44px; height: 44px; }
}
@media (orientation: landscape) and (min-width: 600px) and (max-height: 430px) {
  .hud { height: 36px; }
  .hud-pause, .hud-chef { width: 30px; height: 30px; }
}

/* ---------- missions, map rewards ---------- */
.dialog h4 { margin: 14px 0 6px; font-size: 15px; }
.mis { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.mis li { display: flex; flex-direction: column; gap: 2px; padding: 7px 10px; border: 1.5px solid #d8b884; border-radius: 12px; background: #fffdf6; }
.mis li b { font-size: 13px; }
.mis li span { color: var(--ink-2); font-size: 12px; font-weight: 700; }
.mis li.done { border-color: #6ac884; background: #effaf1; }
.mis.mini li { padding: 5px 9px; }
.mbar { display: block; height: 7px; margin-top: 3px; overflow: hidden; border: 1px solid #b89868; border-radius: 9px; background: #efe2c8; }
.mbar i { display: block; height: 100%; transform-origin: 0 50%; background: linear-gradient(90deg, #3ec46d, #9be36a); }
.rwcard { display: flex; align-items: center; gap: 10px; padding: 8px; border: 2px solid #e8b860; border-radius: 14px; background: linear-gradient(#fff6dc, #ffe2a8); }
.rwcard .prev { flex: none; width: 88px; height: 70px; }
.rwcard .prev.of svg { width: 70px; height: 70px; }
.rwcard .prev.ln svg { width: 26px; height: 46px; }
.rwcard .prev.pl svg { width: 52px; height: 60px; }
.rwcard > div:last-child { display: flex; flex: 1; flex-direction: column; gap: 2px; min-width: 0; text-align: left; }
.rwcard b { font-size: 14px; color: #7a3a10; }
.rwcard span { font-size: 12.5px; font-weight: 700; }
.rwcard small { color: #8a6a3a; font-size: 11.5px; }
.rwcard.big .prev { width: 110px; height: 90px; }
.mapdone { position: relative; margin: 0 0 8px; padding: 12px 10px 10px; overflow: hidden; border: 2px solid #e8a020; border-radius: 16px; background: radial-gradient(circle at 50% 0, #fff6c8, #ffd56a); text-align: center; animation: popd .4s ease; }
.mapdone::before { content: ''; position: absolute; inset: -60%; background: repeating-conic-gradient(rgba(255, 255, 255, .35) 0 10deg, transparent 10deg 20deg); animation: spin 14s linear infinite; pointer-events: none; }
.mapdone > * { position: relative; }
.mapdone .md-h { display: block; margin-bottom: 6px; color: #9a3a00; font-size: 17px; font-weight: 900; letter-spacing: .3px; }
.mapdone .rwcard { text-align: left; background: rgba(255, 255, 255, .78); }
@keyframes popd { from { transform: scale(.6); opacity: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
.item.prize { opacity: .85; border-style: dashed; }
.item.prize .act { color: #c8781a; }

/* ---------- shop ---------- */
.shop-top { display: flex; justify-content: flex-end; gap: 16px; margin: 4px 0; font-size: 17px; font-weight: 800; }
.gem-chip b { color: #7fd8ff; }
.tabs { display: flex; gap: 4px; margin: 6px 0 10px; overflow-x: auto; scrollbar-width: none; }
.tabs button { flex: 1 0 auto; padding: 9px 5px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); font-weight: 800; font-size: 12.5px; white-space: nowrap; }
.shop { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.item { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 8px 12px; border: 2px solid var(--line); border-radius: 16px; background: var(--panel); text-align: center; }
.item.active { border-color: var(--accent); }
.item.locked { opacity: .55; }
.item.poor .act.buy { color: var(--muted); }
.item b { font-size: 14px; }
.item .rar { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; }
.item .desc { color: var(--muted); font-size: 11.5px; line-height: 1.35; }
.item .act { font-size: 13px; font-weight: 800; color: var(--muted); }
.item .act.buy { color: var(--accent); }
/* Price block pinned to the card bottom: two fixed rows (🪙, then 💎 / "chỉ xu" / empty) so a row of cards lines up. */
.item .it-pay { margin-top: auto; width: 100%; display: flex; flex-direction: column; gap: 4px; padding-top: 4px; }
.item .pp { display: block; padding: 5px 6px; border-radius: 10px; font-size: 13px; font-weight: 800; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item .pp-coin { background: #fff3d2; border: 1.5px solid #f0c060; color: #8a5600; }
.item .pp-gem { background: #f1e8ff; border: 1.5px solid #c9b2ff; color: #6a36d0; }
.item .pp-only { border: 1.5px dashed #e2cfaa; color: var(--muted); font-size: 11.5px; font-weight: 700; }
.item .pp-st { background: #e8f8ec; border: 1.5px solid #9ad8a8; color: #1f8a3e; }
.item .pp-sub { color: var(--muted); font-size: 11.5px; font-weight: 700; border: 1.5px solid transparent; }
.item .pp-gap { visibility: hidden; border: 1.5px solid transparent; }
.item.poor .pp-coin, .item.poor .pp-gem { opacity: .6; }
.item .lk { position: absolute; z-index: 2; top: 6px; left: 6px; right: 6px; padding: 3px 6px; border-radius: 8px; background: rgba(40, 24, 10, .78); color: #fff;
  font-style: normal; font-size: 11px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item.locked { opacity: 1; }
.item.locked .prev, .item.locked > b, .item.locked .desc, .item.locked .it-pay { opacity: .55; }
/* Collection of opened stalls (each keeps its own look). */
/* In-play upgrade panel. */
#dialog .uplist { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); margin-top: 8px; }
#modal .dialog:has(.uplist) .dlg-btns { position: sticky; bottom: -16px; z-index: 3; margin: 8px -16px -16px; padding: 10px 16px 16px;
  background: linear-gradient(rgba(255, 248, 236, 0), #fff8ec 30%); }
.gem { color: #7fd8ff; }
.prev { position: relative; display: grid; place-items: center; width: 100%; max-width: 132px; height: 96px; overflow: hidden; border: 2px solid var(--ol); border-radius: 14px; background: radial-gradient(circle at 50% 30%, #fff2d8, #f2c88a); }
.prev.up { font-size: 50px; background: radial-gradient(circle at 50% 30%, #fff8ea, #e8d2b0); }
.prev.aw { align-items: start; background: linear-gradient(#bfe0f0, #f6efe0); }
.prev.aw .awning { width: 100%; height: 34px; }
.prev.aw .awning b { font-size: 10px; padding: 2px 6px; }
.prev.ln { display: flex; justify-content: space-around; align-items: flex-start; background: radial-gradient(circle at 50% 70%, #5a3a4a, #1e1630); }
.prev.ln svg { width: 34px; height: 60px; }
.prev.pl { background: radial-gradient(circle at 50% 30%, #f2fff0, #c8e8b8); }
.prev.pl svg { width: 70px; height: 82px; }
.prev.of svg { width: 96px; height: 96px; transform: translateY(6px); }
.buyprev { display: flex; justify-content: center; margin: 4px 0 8px; }
.buyprev .mini-stall { width: 100%; }
.buyprev .prev { max-width: 170px; }

/* ---------- day intro / result ---------- */
.menu-board { margin: 0 0 8px; padding: 8px 8px 10px; border: 3px solid #6a4020; border-radius: 14px; background: radial-gradient(ellipse at 50% 0, #34483e, #22302a); box-shadow: inset 0 0 0 2px #8a5a30, 0 3px 0 #3a2010; }
.menu-board h5 { margin: 0 0 6px; color: #ffe8a8; font-size: 13px; font-weight: 900; text-align: center; letter-spacing: .4px; }
.intro-dishes { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.dchip { position: relative; display: flex; flex-direction: column; align-items: center; width: 88px; padding: 5px 4px 6px; border: 2px solid var(--ol); border-radius: 14px; background: linear-gradient(#fffaf0, #f2dfba); color: var(--ink); box-shadow: 0 3px 0 rgba(0, 0, 0, .4); }
.dchip svg { width: 74px; height: 60px; }
.dchip b { font-size: 11.5px; line-height: 1.2; text-align: center; }
.dchip small { color: #a8481a; font-size: 12px; font-weight: 900; }
.dchip.new::after { content: 'MỚI'; position: absolute; top: -8px; right: -6px; padding: 1px 7px; border: 2px solid #fff; border-radius: 99px; background: #e5374f; color: #fff; font-size: 10px; font-weight: 900; }
.goal-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 6px 0; }
.goal-t { display: flex; flex-direction: column; align-items: center; padding: 6px 4px; border: 2px solid #e2c48c; border-radius: 12px; background: #fffaf0; }
.goal-t i { color: #ffb300; font-size: 15px; font-style: normal; letter-spacing: -1px; text-shadow: 0 1px 0 #a86a00; }
.goal-t b { color: var(--ink); font-size: 13px; }
.goal-t.g1 { border-color: #ff9a3a; background: #fff0d8; }
.intro-meta { margin: 4px 0; color: var(--ink-2); font-size: 13px; font-weight: 800; text-align: center; }
.tips { margin: 6px 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
.tips li { padding: 6px 10px; border-left: 4px solid #ff9a3a; border-radius: 8px; background: #fff6e2; color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.4; }
.toggles { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tgl { flex: 1 1 140px; display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 7px 10px; border: 2px solid #d8b884; border-radius: 12px; background: #fff; color: var(--ink); font-size: 12.5px; font-weight: 800; }
.tgl i { padding: 1px 8px; border-radius: 99px; background: #d8cfc0; color: #fff; font-size: 11px; font-style: normal; font-weight: 900; }
.tgl.on i { background: #1f9a4a; }
.stars3 { display: flex; justify-content: center; gap: 6px; margin: 0; font-size: 48px; line-height: 1; }
.stars3 i { color: #e2d6c4; font-style: normal; -webkit-text-stroke: 2px #b8a688; }
.stars3 i.on { color: #ffc21a; -webkit-text-stroke: 2px #a86a00; text-shadow: 0 3px 0 #c88a00; animation: starpop .45s ease both; }
@keyframes starpop { from { transform: scale(0) rotate(-40deg); } 70% { transform: scale(1.3); } to { transform: none; } }

/* ---------- leaderboard ---------- */
.rank .row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.rank .row.me { background: #fff6e2; border-radius: 10px; }
.rank .no { width: 28px; color: var(--muted); font-weight: 800; text-align: center; }
.rank .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.rank .nm small { color: var(--muted); font-weight: 600; }
.rank .sc { font-weight: 900; color: #c8501a; white-space: nowrap; }

.help { line-height: 1.6; }
.help ul { padding-left: 20px; }

/* ---------- dialogs: cream paper card with a wooden ribbon title (ids beat sdk/game-light.css) ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: rgba(5, 8, 12, .62); }
#modal { background: rgba(30, 14, 4, .62); }
#modal .dialog { width: min(440px, 100%); max-height: calc(100dvh - 32px); overflow: auto; padding: 0 16px 16px; border: 3px solid var(--ol); border-radius: 22px;
  background: linear-gradient(#fffcf4, #f8ead0); color: var(--ink); font-family: var(--round); box-shadow: 0 6px 0 #2a160a, 0 24px 60px rgba(0, 0, 0, .55); animation: dlgIn .22s ease; }
@keyframes dlgIn { from { transform: translateY(14px) scale(.96); opacity: 0; } }
#modal .dialog h3 { position: sticky; top: 0; z-index: 2; margin: 0 -16px 10px; padding: 11px 16px 10px; border-bottom: 3px solid var(--ol); background: linear-gradient(#ffa23a, #e8641a); color: #fff; font-size: 18px; font-weight: 900; text-align: center; text-shadow: 0 2px 0 rgba(120, 40, 0, .5); }
#modal .dialog p { line-height: 1.5; }
#modal .dialog .note { color: var(--ink-2); }
#modal .dialog .score { margin: 4px 0; color: #c8501a; font-size: 38px; font-weight: 900; text-align: center; -webkit-text-stroke: 1px #7a2a06; }
#modal .dialog .rw { margin: 6px 0; padding: 8px 10px 8px 26px; border-radius: 12px; background: #fff6e2; font-size: 13.5px; font-weight: 700; line-height: 1.7; }
#modal .dlg-btns { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 14px; }
#modal .dlg-btns button { padding: 10px 16px; border: 2px solid var(--ol); border-radius: 14px; background: linear-gradient(#fffaf0, #ecd6b0); color: var(--ink); font-weight: 900; box-shadow: 0 3px 0 #2a160a; }
#modal .dlg-btns button.pri { flex: 1 1 auto; background: linear-gradient(#ffb44a, #ff7a10); color: #fff; text-shadow: 0 2px 0 rgba(120, 40, 0, .45); box-shadow: 0 3px 0 #8a3a06; }
#modal .dlg-btns button:active { transform: translateY(2px); box-shadow: 0 1px 0 #2a160a; }
.dialog { width: min(440px, 100%); max-height: calc(100dvh - 32px); overflow: auto; padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.dlg-btns { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 14px; }

/* Toasts: in play they drop in under the HUD, coloured by urgency */
.toast { position: fixed; left: 50%; top: calc(110px + env(safe-area-inset-top)); z-index: 90; transform: translateX(-50%); width: max-content; max-width: 90vw; text-align: center; padding: 10px 16px; border-radius: 12px; background: #2a1d12; color: #fff; font-weight: 700; box-shadow: 0 8px 24px rgba(0, 0, 0, .4); }
body.mb-light .toast.vh-t { padding: 8px 14px; border: 2px solid var(--ol); border-radius: 14px; background: linear-gradient(#fffaf0, #f2dfba); color: var(--ink); font-family: var(--round); font-size: 13.5px; font-weight: 900; box-shadow: 0 3px 0 #2a160a, 0 8px 20px rgba(0, 0, 0, .35); animation: toastIn .2s ease; }
body.mb-light .toast.vh-t.t-good { background: linear-gradient(#eaffea, #c4eec4); border-color: #1f7a3a; color: #145a2a; }
body.mb-light .toast.vh-t.t-warn { background: linear-gradient(#fff2cc, #ffd27a); border-color: #b8640a; color: #7a3a00; }
body.mb-light .toast.vh-t.t-done { background: linear-gradient(#eaffea, #8fdc9f); border-color: #1f7a3a; color: #145a2a; }
body.mb-light .toast.vh-t.t-raw { background: linear-gradient(#fff8d0, #ffe27a); border-color: #a87800; color: #5a3a00; }
body.mb-light .toast.vh-t.t-bad { background: linear-gradient(#ff7a7a, #e5374f); border-color: #7a0a18; color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, .3); animation: toastIn .2s ease, shakeT .18s linear .2s 4; }
@keyframes toastIn { from { transform: translate(-50%, -12px); opacity: 0; } }
@keyframes shakeT { 25% { transform: translate(calc(-50% - 4px), 0); } 75% { transform: translate(calc(-50% + 4px), 0); } }
.updatebar { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 45; display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel-2); }
.updatebar button { padding: 8px 12px; border: 0; border-radius: 10px; background: var(--accent); color: #1c1608; font-weight: 800; }

/* ---------- events (sdk/events.js): limited item tag ---------- */
.evtag { display: inline-block; margin: 2px 0; padding: 1px 8px; border-radius: 999px; background: linear-gradient(90deg, #ff9a3c, #ff4fa0); color: #fff; font-size: 11px; font-style: normal; font-weight: 800; }
.item.ev { border-color: #ff9a3c; }

/* ---------- light skin tweaks (sdk/game-light.css does the shared classes) ---------- */
body.mb-light .me-av { background: linear-gradient(#ffe6b8, #f6c77a); }
body.mb-light #shopList .item { border: 2px solid #e2cfaa; border-radius: 16px; background: linear-gradient(#fffdf8, #fbf1de); box-shadow: 0 3px 0 #e2cfaa; }
body.mb-light #shopList .item.active { border-color: #ff8a1a; background: linear-gradient(#fff8ec, #ffe8c8); box-shadow: 0 3px 0 #ff8a1a; }
body.mb-light .item .act.buy { color: var(--coin); }
body.mb-light .dayb { background: linear-gradient(#fffaf0, #f6e6c8); }
body.mb-light .dayb.got { background: linear-gradient(#f2fff2, #d8f2d8); }
body.mb-light .dchip { background: linear-gradient(#fffaf0, #f2dfba); }

/* ============ Painted stall (owner-approved design 06/11/2026, portrait only) ============
   The stall is the owner's painted picture (img/<art>/stall.webp) standing on the bottom edge; main.js fitPainted() sets the px
   numbers: --W column width, --cl column left, --pw / --ph picture size, --off lift above the home bar, --ct picture top,
   --hudH plaque height, --sct / --hs street box, --u = W / 390, --k people scale, --bgt / --bgh street picture. Everything on
   the picture (trays, bottles, pan, dish, buttons) is a transparent box in % of the picture (js/painted.js). */
.stall.painted { padding: 0; background: #e9a08a; }
.stall.painted .stall-bg { inset: 0; height: auto; background: repeat-y 0 calc(var(--bgt) + var(--bgh) - 4px) / 100% auto; }
.stall.painted .stall-bg::after { display: none; }
.stall.painted .p-bg { position: absolute; left: 0; top: var(--bgt); width: 100%; height: var(--bgh); }
.stall.painted .p-chalk { position: absolute; left: calc(var(--cl) + 4px * var(--u)); top: calc(var(--sct) + 26px * var(--u)); width: calc(38px * var(--u)); transform: rotate(-2deg); box-shadow: 0 2px 4px rgba(0, 0, 0, .35); }
.stall.painted .p-lantern { position: absolute; right: calc(var(--cl) + 6px * var(--u)); top: calc(var(--sct) + 4px * var(--u)); width: calc(38px * var(--u)); }
.stall.painted .p-lnum { position: absolute; right: calc(var(--cl) + 6px * var(--u)); top: calc(var(--sct) + 36px * var(--u)); width: calc(38px * var(--u)); text-align: center; color: #b3261a; font-weight: 900; font-size: calc(11px * var(--u)); }
.stall.painted .awning, .stall.painted .lanterns, .stall.painted .vit-pet, .stall.painted .lip, .stall.painted .wheel, .stall.painted .side-pl,
.stall.painted .plant-spot, .stall.painted .goalbar, .stall.painted .hud-chef, .stall.painted .dishbox::before { display: none; }
/* The two wooden posts carry the chalk sign + lantern of a stall that has them (PA.layers); a bare picture has none. */
.stall.painted.bare .scene::before, .stall.painted.bare .scene::after { display: none; }

/* HUD: the three painted wooden plaques under the notch, live text on them. */
.stall.painted .hud { position: absolute; z-index: 9; left: var(--cl); top: env(safe-area-inset-top); width: var(--W); height: var(--hudH); margin: 0; padding: 0; border-radius: 0; display: block;
  background: 0 0 / 100% 100% no-repeat; box-shadow: none; }
.stall.painted .hud > *, .stall.painted .hud-mid > *, .stall.painted .hud-day > *, .stall.painted .hud-rate > * { position: absolute; }
.stall.painted .hud-day, .stall.painted .hud-mid, .stall.painted .hud-rate { position: static; display: block; margin: 0; padding: 0; background: none; box-shadow: none; }
.stall.painted .hud-pause { border-radius: 50%; background: transparent; box-shadow: none; }
.stall.painted .hud-pause i { display: none; }
.stall.painted #hudDay, .stall.painted .hud-day em, .stall.painted #stallSign, .stall.painted #hudMoney, .stall.painted .hud-stars, .stall.painted .hud-heart {
  transform: translate(-50%, -50%); white-space: nowrap; color: #3b2210; font-weight: 900; font-family: "Trebuchet MS", "Arial Rounded MT Bold", var(--round); line-height: 1; }
.stall.painted #hudDay { font-size: calc(12px * var(--u)); }
.stall.painted .hud-day em { font-style: normal; font-size: calc(12px * var(--u)); }
.stall.painted .hud-day em .clk { display: none; }
.stall.painted #stallSign { max-width: 30%; overflow: hidden; text-overflow: ellipsis; font-size: calc(11px * var(--u)); color: #b3261a; }
.stall.painted #hudMoney { font-size: calc(17px * var(--u)); letter-spacing: .3px; }
.stall.painted .hud-stars { color: #f6b81a; font-size: calc(15px * var(--u)); letter-spacing: -1px; text-shadow: 0 1px 0 #8a5426; }
.stall.painted .hud-heart { color: #b3261a; font-size: calc(11px * var(--u)); }
.stall.painted .hud-heart { font-size: 0; }
.stall.painted .hud-heart b { font-size: calc(11px * var(--u)); }
/* Dark painted plaques (GEO hud.light): cream lettering with a dark edge. */
.stall.painted .hud.hud-light #hudDay, .stall.painted .hud.hud-light .hud-day em, .stall.painted .hud.hud-light #hudMoney { color: #fff3dc; text-shadow: 0 1px 0 #2a160a; }
.stall.painted .hud.hud-light #stallSign { color: #ffd36b; text-shadow: 0 1px 0 #2a160a; }
.stall.painted .hud.hud-light .hud-heart { color: #ff8a7a; text-shadow: 0 1px 0 #2a160a; }

/* The play area: the whole screen; the street box above the picture, the picture on the bottom edge. */
.stall.painted .play { inset: 0; top: 0; display: block; padding: 0; }
.stall.painted .scene { position: absolute; left: var(--cl); top: var(--sct); width: var(--W); height: var(--hs); z-index: 3; }
.stall.painted .cart { position: absolute; z-index: 4; left: calc(var(--cl) + (var(--W) - var(--pw)) / 2); bottom: var(--off); top: auto; width: var(--pw); height: var(--ph); margin: 0; display: block;
  background: 0 0 / 100% 100% no-repeat; border: 0; box-shadow: none; border-radius: 0; padding: 0; }
.stall.painted .cart::before, .stall.painted .cart::after { display: none; }
.stall.painted .vit, .stall.painted .work, .stall.painted .rack, .stall.painted .shelf { display: contents; }
.stall.painted #cabShelf, .stall.painted #rackShelf { display: contents; }
.stall.painted #cabShelf::before, .stall.painted #cabShelf::after, .stall.painted #rackShelf::before, .stall.painted #rackShelf::after { display: none; }
.stall.painted .tray { position: absolute; z-index: 2; width: auto; height: auto; border-radius: 10px; }  /* above the dish (z 1): the bag sits on the dish spot */
.stall.painted .tray .art { display: none; }
.stall.painted .tray[data-lock] { background: rgba(60, 40, 20, .38); cursor: default; }
.stall.painted .tray[data-lock]::after { content: '🔒'; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: calc(14px * var(--u)); opacity: .85; }
.stall.painted .tray.s-cur { box-shadow: 0 0 0 2px #ffd23a, 0 0 12px 3px rgba(255, 210, 58, .8); }
.stall.painted .tray.s-ok { box-shadow: 0 0 0 2px rgba(47, 168, 79, .9); }
.stall.painted .tray.press { transform: scale(.95); }
.stall.painted .tray .bdg { right: 6%; top: 14%; }
.stall.painted .dishbox { position: absolute; display: block; }
.stall.painted .dish { position: absolute; inset: 0; display: block; }
.stall.painted .dish .p-full { position: absolute; left: var(--fl); bottom: var(--fb); width: var(--fw); filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .35)); }
/* Toppings heaped on the food in the cup; sauces in dipping saucers on the tray beside the cup. */
/* The dish box is the long serving tray painted on the counter: the cup on its left, toppings on the cup, dipping saucers in a
   row on the right of the tray (owner 06/11/2026). */
.stall.painted .dish .p-tops { position: absolute; left: var(--tl); width: var(--tw); bottom: var(--tb); display: flex; justify-content: center; filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .35)); }
.stall.painted .dish .p-tops img { width: 46%; height: auto; margin: 0 -7%; }
.stall.painted .dish .p-sauces { position: absolute; left: var(--sl); width: var(--sw); bottom: var(--sb); display: flex; justify-content: flex-start; align-items: flex-end; filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .4)); }
.stall.painted .dish .p-sauces img { width: 46%; height: auto; margin: 0 -4%; }
/* Pouring: the cup picture shows only up to the poured level; the gauge is big and stands right of the cup (owner 06/11/2026). */
.stall.painted .dish .p-full.p-rise { clip-path: inset(var(--rise) 0 0 0); }
/* Ingredients put in so far, each its own little picture laid on the round tray (plate.parts false). */
.stall.painted .dish .p-laid { position: absolute; left: 1%; width: 66%; bottom: 10%; display: flex; flex-wrap: wrap-reverse; justify-content: center; align-items: flex-end;
  gap: calc(1px * var(--u)); filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .4)); pointer-events: none; }
.stall.painted .dish .p-laid span { width: calc(27px * var(--u)); height: calc(27px * var(--u)); display: grid; place-items: center; }
.stall.painted .dish .p-laid img { max-width: 100%; max-height: 100%; }
.stall.painted .dish .p-full.p-ghost { opacity: .35; filter: grayscale(.6); }
/* Owner 06/11/2026: a slim gauge on the LEFT of the cup (the big one beside the bag was too heavy). */
.stall.painted .fillg { left: -4%; right: auto; top: -28%; bottom: 14%; width: calc(9px * var(--u)); border-radius: 99px; z-index: 8; box-shadow: 0 0 0 1.5px #fff, 0 1px 3px rgba(60, 30, 10, .35); }
.stall.painted .fillg .bar { left: 1px; right: 1px; bottom: 1px; height: calc(100% - 2px); border-radius: 99px; }
.stall.painted .fillg .zone { background: #4cc86c; }
.stall.painted .fillg .stop { top: auto; bottom: calc(100% + 3px); left: 50%; transform: translateX(-50%) scale(.6); font-size: calc(11px * var(--u)); padding: 1px 6px; box-shadow: 0 0 0 1.5px #fff; }
.stall.painted .fillg.inzone .stop, .stall.painted .fillg.pastzone .stop { transform: translateX(-50%); }
.stall.painted .pourfx { left: 22%; right: auto; top: -78%; width: calc(62px * var(--u)); height: calc(62px * var(--u)); transform-origin: 30% 30%; filter: drop-shadow(0 3px 3px rgba(60, 30, 10, .35)); }
/* The painted jug of the poured tea, tilted over the cup; the stream runs from its spout (upper left) into the cup. */
.stall.painted .pourfx .p-jug { width: 100%; height: 100%; object-fit: contain; display: block; }
.stall.painted .pourfx .stream { left: 4%; top: 26%; width: calc(6px * var(--u)); height: 90%; border-radius: 99px; transform: rotate(38deg); transform-origin: 50% 0; opacity: .95; box-shadow: inset 1.5px 0 0 rgba(255, 255, 255, .55), 0 0 0 1px rgba(74, 42, 20, .35); animation: none; }
.stall.painted .dishbox.done .dish .p-full { filter: drop-shadow(0 0 8px #ffd23a) drop-shadow(0 0 3px #ffd23a); animation: dpop 1s ease infinite; }
.stall.painted .stove.p-stove { position: absolute; inset: 0; display: block; pointer-events: none; }
.stall.painted .p-stn { position: absolute; pointer-events: auto; }
.stall.painted .p-stn .stn-box { width: 100%; height: 100%; }
/* Owner 06/11/2026: the doneness bar under food on a painted tool is longer + thicker (the slots are small on the picture). */
/* Owner 06/11/2026 (2nd pass): the bar sits ABOVE the food, on a solid dark track with a white rim + dark outline, so it
   reads on the bright oven glass / steamer / pot. Sized from --W: inside a .ck, --u is the flip progress (0..1), not the scale. */
.stall.painted .slot .ck-bar { left: -6%; right: -6%; top: calc(var(--W) * -13 / 390); bottom: auto; height: calc(var(--W) * 9 / 390); border-radius: 99px;
  background: #3b2412; box-shadow: 0 0 0 2px #fff, 0 0 0 3.5px #4a2a14, 0 2px 4px rgba(40, 24, 12, .5); }
.stall.painted .slot .ck-bar i { border-radius: 99px; }
.stall.painted .stn-al { top: 4%; right: 6%; }
/* The four painted round buttons of the wooden tray. */
.stall.painted .dock { position: absolute; z-index: 6; left: calc(var(--cl) + (var(--W) - var(--pw)) / 2); bottom: var(--off); width: var(--pw); height: var(--ph); margin: 0; padding: 0; background: none; border: 0; box-shadow: none; pointer-events: none; display: block; }
.stall.painted .dock::before, .stall.painted .dock::after { display: none; }
.stall.painted .rbtn { position: absolute; height: auto; aspect-ratio: 1; transform: translate(-50%, -50%); background: transparent; border: 0; box-shadow: none; pointer-events: auto; }
.stall.painted .rbtn .btn-ico, .stall.painted .rbtn .sv-dish { display: none; }
.stall.painted .rbtn.serve.go { box-shadow: 0 0 0 3px #ffd23a, 0 0 16px 6px rgba(255, 210, 58, .85); border-radius: 50%; animation: beat .5s ease-in-out infinite alternate; }
.stall.painted .rbtn.serve.off { opacity: 1; }

/* Customers: painted people. The one ordering on the left, the queue side by side on the right; feet hidden behind the cabinet. */
.stall.painted .cfig.p-cfig { left: calc(4px * var(--u)); bottom: 0; top: auto; width: calc(112px * var(--u) * var(--k)); height: auto; max-height: none; aspect-ratio: auto; }
.stall.painted .cfig.p-cfig img { width: 100%; display: block; transform-origin: 50% 100%; animation: idle 2.6s ease-in-out infinite alternate; }
.stall.painted .queue { position: absolute; inset: 0; display: block; padding: 0; }
.stall.painted .qc.p-q { position: absolute; width: calc(98px * var(--u) * var(--k)); height: auto; border-radius: 0; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .25)); }
.stall.painted .qc.p-q img { width: 100%; display: block; }
.stall.painted .qc.p-q::after { left: 18%; right: 18%; bottom: auto; top: -6px; }
.stall.painted .qc.p-q0 { left: calc(170px * var(--u)); bottom: calc(6px * var(--u)); z-index: 2; }
.stall.painted .qc.p-q1 { left: calc(256px * var(--u)); bottom: calc(2px * var(--u)); width: calc(80px * var(--u) * var(--k)); z-index: 3; }
.stall.painted .qc.p-q2 { left: calc(312px * var(--u)); bottom: calc(12px * var(--u)); width: calc(96px * var(--u) * var(--k)); z-index: 1; }
.stall.painted .p-more { position: absolute; right: 4px; bottom: calc(60px * var(--u)); }
/* Order bubble kiểu A: a parchment sign like the top plaques, the dish in the patience ring, the parts in round chips. */
.stall.painted .bub.p-bub { z-index: 6; left: calc(96px * var(--u)); top: auto; bottom: calc(170px * var(--u) * var(--k)); max-width: calc(290px * var(--u)); display: flex; align-items: center; gap: calc(5px * var(--u));
  padding: calc(6px * var(--u)) calc(9px * var(--u)) calc(6px * var(--u)) calc(6px * var(--u)); border-radius: calc(18px * var(--u));
  background: linear-gradient(#fffaf0, #f6e6c4); border: 3px solid #8a5426; box-shadow: 0 3px 0 #5c3414, 0 6px 10px rgba(0, 0, 0, .3); transform-origin: 0 100%; }
.stall.painted .bub.p-bub::before { content: ''; position: absolute; left: -15px; top: 40%; border: 9px solid transparent; border-right: 14px solid #8a5426; }
.stall.painted .bub.p-bub::after { content: ''; position: absolute; left: -9px; top: calc(40% + 3px); border: 6px solid transparent; border-right: 10px solid #fbf2de; }
.stall.painted .p-ring { --p: 1; position: relative; flex: none; width: calc(64px * var(--u)); height: calc(64px * var(--u)); border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--rc, #3cb44a) calc(var(--p) * 1turn), #e6d8b8 0); }
.stall.painted .bub[data-lv="mid"] .p-ring { --rc: #f0b81a; }
.stall.painted .bub[data-lv="low"] .p-ring { --rc: #e5374f; }
.stall.painted .p-ring::before { content: ''; position: absolute; inset: 6px; border-radius: 50%; background: #fff; box-shadow: inset 0 2px 3px rgba(0, 0, 0, .12); }
.stall.painted .p-ring img { position: relative; width: 74%; }
.stall.painted .p-ring .dish-svg { position: relative; width: 74%; }
.stall.painted .p-plus { color: #8a5426; font-weight: 900; font-size: calc(14px * var(--u)); }
/* Parts always in TWO rows (more parts = more columns, smaller chips) so a long order never grows up under the plaques. */
.stall.painted .p-parts { --cs: calc(36px * var(--u)); display: grid; grid-template-columns: repeat(var(--pc, 3), var(--cs)); gap: calc(4px * var(--u)); }
.stall.painted .p-parts.many { --cs: calc(31px * var(--u)); }
.stall.painted .p-parts .ob-p { position: relative; width: var(--cs); height: var(--cs); border-radius: 50%; background: #fff; border: 2px solid #c9a46a; display: grid; place-items: center; overflow: visible; }
.stall.painted .p-parts .ob-p img { max-width: 80%; max-height: 80%; }
.stall.painted .p-parts .ob-p.ok { border-color: #2fa84f; box-shadow: 0 0 0 2px rgba(47, 168, 79, .35); }
.stall.painted .p-parts .ob-p.ok::after { content: '✓'; position: absolute; right: -4px; top: -4px; width: 15px; height: 15px; border-radius: 50%; background: #2fa84f; color: #fff; font-size: 10px; font-weight: 900; display: grid; place-items: center; }
.stall.painted .p-parts .ob-p.no::before { content: ''; position: absolute; left: 10%; right: 10%; top: 50%; height: 3px; background: #e5374f; transform: rotate(-35deg); border-radius: 2px; z-index: 1; }
.stall.painted .p-more2 { position: relative; flex: none; margin-left: calc(2px * var(--u)); padding-left: calc(7px * var(--u)); border-left: 2px dashed #c9a46a; }
.stall.painted .p-more2 img { width: calc(28px * var(--u)); display: block; }
.stall.painted .p-more2 i { position: absolute; right: -8px; top: -9px; width: 18px; height: 18px; border-radius: 50%; background: #c42a1a; color: #fff; font-size: 11px; font-weight: 900; font-style: normal; display: grid; place-items: center; border: 2px solid #fff; }
.stall.painted .p-more2.got i { background: #2fa84f; }
.stall.painted .bub.say, .stall.painted .bub.said { left: calc(104px * var(--u)); top: auto; bottom: calc(120px * var(--u) * var(--k)); background: #fffaf0; border: 3px solid #8a5426; }
/* Portrait only: a phone held sideways asks to be turned. */
@media (orientation: landscape) and (pointer: coarse) {
  .stall.painted::after { content: '📱 Xoay dọc điện thoại để bán hàng'; position: absolute; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(40, 20, 8, .92); color: #fff; font-weight: 900; font-size: 18px; }
}
/* Painted stall fills the whole phone: #scPlay spans the large viewport, the page under Safari's toolbar is brick, not white. */
html:has(body.vh-painted), body.mb-light.vh-painted { background: #b86a50 var(--vhBrickImg, none) repeat-y 0 var(--vhBrickY, 0) / 100% auto !important; }
body.vh-painted #scPlay { bottom: auto; height: 100lvh; }

/* ---------- map, painted style (owner 06/11/2026: same look as the painted stall) ----------
   Brick pavement of the stall picture as the ground, an asphalt street with a stone curb, every stop a painted wooden signboard
   (light cream card with a thin wood edge — owner 06/11/2026: the plank boards read heavy), the stall's dish on a soft cream
   medallion, a brass padlock while locked. */
.citymap { border: 0; border-radius: 16px; box-shadow: inset 0 0 0 3px #6a3a18, inset 0 0 40px rgba(60, 30, 10, .35), 0 4px 10px rgba(60, 30, 10, .3);
  background: url(../img/map/brick.webp) 0 0 / 100% auto repeat-y #c98a6a; }
.citymap .road-curb { fill: none; stroke: #d8c4a0; stroke-width: 40; stroke-linecap: round; }
.citymap .road-base { stroke: #4e4844; stroke-width: 32; }
.citymap .road-line { stroke: #fff2c0; stroke-width: 3; stroke-dasharray: 14 12; }
.citymap .stop { border: 2px solid #e6c497; border-radius: 18px; background: linear-gradient(#fffbf2, #fbf0dc); box-shadow: 0 3px 0 #ead2ae, 0 6px 14px rgba(120, 70, 30, .12); padding: 14px 16px; min-height: 96px; }
.citymap .stop:nth-of-type(even) { padding: 14px 16px; }
.citymap .stop:active { transform: translateY(2px); box-shadow: 0 1px 0 #ead2ae, 0 3px 8px rgba(120, 70, 30, .12); }
.citymap .stop-ic { position: relative; width: 68px; height: 68px; box-shadow: none; border-radius: 50%; border: 2px solid #ecd0a6; background: radial-gradient(circle at 40% 35%, #fffaf0, #f7e6c8); }
.citymap .stop-ic img { width: 76%; height: 76%; object-fit: contain; filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .4)); pointer-events: none; }
.citymap .stop-no { top: -8px; left: 16px; background: #f6a54a; border-color: #fff; color: #fff; }
.citymap .stop:nth-of-type(even) .stop-no { right: 16px; }
.citymap .stop-tx b { color: #5a3214; }
.citymap .stop-tx small { color: #9a7656; }
.citymap .stop.locked { filter: saturate(.4); background: #f6efe4; }
.citymap .stop.locked > * { opacity: 1; }
.citymap .stop.locked .stop-tx { opacity: .75; }
.citymap .stop.next { border-color: #f6a54a; box-shadow: 0 0 0 3px rgba(246, 165, 74, .35), 0 6px 14px rgba(120, 70, 30, .14); }

.citymap .stop.done .stop-ic::after { transform: none; top: 0; right: 0; }
.citymap .stop.soon { opacity: 1; background: #f6efe4; border-style: dashed; filter: saturate(.55); }
.citymap .stop.soon .stop-ic { filter: none; }
.citymap .stop.soon .stop-ic img { opacity: .8; }

/* Painted dish pictures outside play (dishPic in main.js): same box as the drawn dish they replace. */
.dchip img.pdish { width: 74px; height: 64px; object-fit: contain; filter: drop-shadow(0 2px 2px rgba(60, 30, 10, .35)); }
.prev.dsh img.pdish { width: 100%; height: 100%; object-fit: contain; }
.buyprev img.pdish { width: 120px; height: 110px; object-fit: contain; filter: drop-shadow(0 3px 3px rgba(60, 30, 10, .35)); }
/* Day progress strip at the very top of the painted stall (owner 06/11/2026): customers finished / customers of the day. */
.hud-prog { display: none; }
.stall.painted .hud-prog { display: block; left: 24%; right: 24%; top: calc(var(--W) * 3 / 390); height: calc(var(--W) * 15 / 390); z-index: 2; overflow: hidden;
  border-radius: 99px; background: #fff6e2; border: calc(var(--W) * 1.5 / 390) solid #6a3d1a; box-shadow: 0 1px 3px rgba(40, 20, 5, .35); }
.stall.painted .hud-prog > i { position: absolute; inset: 0; transform-origin: 0 50%; transform: scaleX(0); transition: transform .4s; background: linear-gradient(180deg, #ffd45a, #f29a1e); }
.stall.painted .hud-prog > b { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: calc(var(--W) * 9.5 / 390);
  font-weight: 800; color: #4a2a14; letter-spacing: .2px; text-shadow: 0 1px 0 rgba(255, 246, 226, .8); white-space: nowrap; }

/* ===== Trang chủ tranh vẽ (design system 17/11/2026 — bố cục chuẩn: ‹ trên trái, loa + sách trên phải, logo + CHƠI, 4 ô đáy) ===== */
#scHome { position: fixed; inset: 0; z-index: 5; overflow: hidden; padding: 0; max-width: none; background: #d98a5e; animation: none; container-type: size; }
#scHome .hm-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top; }
body:has(#scHome:not(.hidden)) .mb-nav { display: none !important; }
#scHome button { -webkit-appearance: none; appearance: none; font-family: inherit; }
.hm-back, .hm-gear { position: absolute; top: max(10px, env(safe-area-inset-top)); width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; padding: 0; box-shadow: 0 3px 6px rgba(0, 0, 0, .35); }
.hm-back { left: max(10px, env(safe-area-inset-left)); background: #fff; border: 3px solid #e3e5e8; color: #191b1d; font: 700 28px/1 system-ui; padding-bottom: 4px; }
.hm-gear { right: max(10px, env(safe-area-inset-right)); border-radius: 12px; background: linear-gradient(#5ab4ff, #2a6fd8); border: 3px solid #e8f7ff; color: #fff; }
.hm-gear svg { width: 26px; height: 26px; display: block; }
.hm-mute { display: none; position: absolute; left: 7px; right: 7px; top: 50%; height: 3px; background: #ff4d4d; border-radius: 2px; transform: rotate(-45deg); }
.hm-gear.off .hm-mute { display: block; }
.hm-book { top: calc(max(10px, env(safe-area-inset-top)) + 54px); border-radius: 50%; }
.hm-top { position: absolute; left: calc(max(10px, env(safe-area-inset-left)) + 52px); top: max(10px, env(safe-area-inset-top)); display: flex; align-items: center; gap: 8px; }
.hm-av { position: relative; flex: none; width: 52px; height: 52px; padding: 0; border-radius: 50%; border: 3px solid #d8a13a; background: #fff3d6; display: grid; place-items: center; box-shadow: 0 3px 6px rgba(0, 0, 0, .35); cursor: pointer; }
.hm-av .me-avemo { position: absolute; inset: 0; display: grid; place-items: center; font-size: 28px; line-height: 1; border-radius: 50%; overflow: hidden; color: var(--px, #e5484d); font-weight: 900; }
.hm-lv { position: absolute; left: 50%; bottom: -9px; transform: translateX(-50%); padding: 1px 8px; border-radius: 8px; background: #7a4a1c; border: 2px solid #d8a13a; color: #fff; font: 900 12px/1.2 system-ui, sans-serif; white-space: nowrap; }
.hm-name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.hm-xp, .hm-pts { display: none; }
.hm-bar { display: flex; align-items: center; gap: 4px; min-width: 84px; height: 32px; padding: 0 10px 0 4px; border-radius: 16px; background: rgba(20, 60, 90, .78); border: 2px solid rgba(255, 255, 255, .55); }
.hm-bar img { width: 24px; height: auto; flex: none; }
.hm-bar b { flex: 1; color: #fff !important; font: 900 14px/1 system-ui, sans-serif; text-align: center; }
.hm-stack { position: absolute; left: 0; right: 0; top: calc(max(10px, env(safe-area-inset-top)) + 64px); bottom: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.6cqh; padding: 0 5cqw; }
.hm-logo { flex: 0 1 auto; min-height: 0; max-height: 16cqh; max-width: 84cqw; width: auto; height: auto; filter: drop-shadow(0 5px 6px rgba(0, 0, 0, .3)); pointer-events: none; }
.hm-hero { flex: 0 1 auto; min-height: 0; max-height: 28cqh; max-width: 72cqw; width: auto; height: auto; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .25)); pointer-events: none; }
.hm-play { flex: none; width: min(70cqw, 330px); padding: 1.2cqh 3cqw 1.4cqh; border-radius: 999px; text-align: center; color: #fff; background: linear-gradient(#8aea5a, #2fae2a 60%, #238a22); border: 4px solid #fff5cf; box-shadow: 0 5px 0 #1b6b1a, 0 9px 12px rgba(0, 0, 0, .35); }
.hm-play b { display: block; font: 900 clamp(26px, 5.2cqh, 44px)/1.05 "Arial Rounded MT Bold", system-ui, sans-serif; -webkit-text-stroke: .12em #1d6a1d; paint-order: stroke fill; letter-spacing: 2px; }
.hm-play small { display: block; font: 900 clamp(12px, 1.8cqh, 15px)/1.2 system-ui, sans-serif; -webkit-text-stroke: .2em #1d6a1d; paint-order: stroke fill; }
.hm-play:active, .hm-ic:active { transform: scale(.96); }
.hm-row { position: absolute; left: 50%; bottom: max(14px, env(safe-area-inset-bottom)); transform: translateX(-50%); display: flex; gap: 2cqw; }
.hm-ic { position: relative; width: min(21cqw, 96px); padding: 0; background: none; border: 0; box-shadow: none; color: #fff; }
.hm-ic img { width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; display: block; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .4)); }
.hm-ic span { display: block; margin-top: -2px; text-align: center; font: 900 clamp(12px, 1.7cqh, 14px)/1.1 system-ui, sans-serif; -webkit-text-stroke: .22em #4a2a14; paint-order: stroke fill; white-space: nowrap; }
.hm-dot { position: absolute; top: 2px; right: 2px; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 11px; background: #e5374f; border: 2px solid #fff; color: #fff; font: 900 12px/18px system-ui; font-style: normal; }
.hm-dot.hidden { display: none; }
#scHome .hm-seo { position: absolute !important; width: 1px !important; height: 1px !important; margin: 0 !important; padding: 0 !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; white-space: nowrap !important; }
#scBook a.bk-link { display: flex; align-items: center; min-height: 44px; padding: 8px 16px; border: 1px solid var(--skin-card-line, #e3e5e8); border-radius: 12px; background: var(--skin-card, #f7f8f9); color: var(--skin-ink, #191b1d); font-size: 15px; font-weight: 700; text-decoration: none; }
#scBook .bk-list, #scModes { display: flex; flex-direction: column; gap: 8px; }
#scModes .big { margin: 0; }
#scHelp .help ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; line-height: 1.4; }
.hm-dot-s { min-width: 16px; width: 16px; height: 16px; padding: 0; top: 6px; right: 10px; }
.hm-av .me-avemo { background: radial-gradient(circle at 40% 35%, #fffaf0, #f7e6c8); }
.hm-av .me-avemo svg { width: 100%; height: 100%; transform: translateY(4px) scale(1.12); }
#scQuests { display: flex; flex-direction: column; gap: 10px; }
#scQuests .big { margin: 0; }
#scQuests .note { margin: 0; font-size: 14px; }
#scQuests .mis li { padding: 10px 12px; border: 1px solid var(--skin-card-line, #e3e5e8); border-radius: 12px; background: var(--skin-card, #f7f8f9); }
#scQuests .mis li.done { border-color: #00a862; background: #eaf8f1; }
.qd-card { display: flex; flex-direction: column; gap: 4px; padding: 12px 16px; border: 1px solid #e3e5e8; border-radius: 12px; background: #f7f8f9; }
.qd-card b { font-size: 16px; }
.qd-card small { color: #606368; font-size: 14px; line-height: 1.4; }
.qd-done { margin: 4px 0 0; color: #00a862; font-size: 14px; font-weight: 800; }
/* Khung ngang thấp (điện thoại cầm ngang 844×390): logo + hình chính to hơn, gọn giữa thanh trên và 4 ô (như Người Que) */
@container (orientation: landscape) {
  .hm-stack { top: calc(max(10px, env(safe-area-inset-top)) + 58px); bottom: calc(max(10px, env(safe-area-inset-bottom)) + min(11cqw, 22cqh) + 22px); gap: 1.2cqh; }
  .hm-logo { max-height: 19cqh; max-width: 46cqw; }
  .hm-hero { max-height: 25cqh; max-width: 40cqw; }
  .hm-play { width: min(46cqw, 340px); padding: 0.8cqh 3cqw 1cqh; }
  .hm-play small { white-space: nowrap; font-size: clamp(12px, 3.2cqh, 15px); }
  .hm-play b { font-size: clamp(24px, 7cqh, 40px); }
  .hm-row { bottom: max(10px, env(safe-area-inset-bottom)); gap: 1.6cqw; }
  .hm-ic { width: min(11cqw, 22cqh, 96px); }
  .hm-ic span { font-size: clamp(12px, 3.2cqh, 14px); }
}

/* Map strip under CHƠI: glass strip like Tìm Đồ "Chọn bức tranh" (one play mode, so CHƠI starts the next day) */
.hm-maps { flex: none; display: flex; align-items: center; gap: 6px; min-height: 44px; margin-top: 1cqh; padding: 0 14px 0 8px; border: 2px solid rgba(255, 255, 255, .55); border-radius: 999px; background: rgba(20, 60, 90, .78); color: #fff; font: 800 13px/40px system-ui, sans-serif; box-shadow: none; }
.hm-maps img { width: 32px; height: 32px; flex: none; object-fit: contain; }
.hm-maps:active { transform: scale(.96); }
.hm-maps small { margin-left: 2px; padding: 2px 8px; border-radius: 999px; background: rgba(255, 255, 255, .18); font-size: 13px; font-weight: 800; }

/* Sheet skin "wood": small sheets take the colours of the painted home (owner 30/11/2026). */
body.mb-light { --skin-frame: #6b3d17; --skin-head: linear-gradient(#93592a, #6b3d17); --skin-head-ink: #fff3d6; --skin-line: #d8a13a;
  --skin-paper: #f4e6c6; --skin-card: #fffaf0; --skin-card-line: #d6b886; --skin-ink: #3a1d0c; --skin-muted: #765536; --skin-hover: #fff3dc; }
