:root{font-family:'Trebuchet MS','Malgun Gothic',system-ui,sans-serif;color:#173d43;background:#103d45;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;--ink:#173d43;--teal:#0d7881;--mint:#dcfff0;--cream:#fff7e7;--gold:#ffcf64;--coral:#fa765f}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden}body{display:grid;place-items:center;background:radial-gradient(ellipse at 50% 0%,#39a9a7,#07515b 75%)}button{font:inherit;border:0;cursor:pointer;-webkit-tap-highlight-color:transparent}.game-shell{height:100dvh;width:min(100vw,620px);display:flex;flex-direction:column;position:relative;overflow:hidden;background:#eaf8df;box-shadow:0 0 55px #002a3180;padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}
.topbar{height:64px;min-height:64px;display:flex;align-items:center;justify-content:space-between;padding:0 18px;background:linear-gradient(100deg,#087078,#0c8990);color:white;z-index:2;box-shadow:0 4px 14px #084a4e44}.brand{display:flex;align-items:center;gap:9px}.brand-mark{width:35px;height:35px;border-radius:13px;display:grid;place-items:center;background:#ffdc83;color:#247a79;font-size:23px;box-shadow:inset 0 2px 0 #fff8}.brand strong{font:20px Jua,sans-serif;letter-spacing:.1px;display:block}.brand small{font-size:10px;opacity:.8;letter-spacing:1.6px;text-transform:uppercase}.level-chip{height:42px;min-width:96px;display:flex;align-items:baseline;justify-content:center;gap:4px;padding:5px 10px;border-radius:13px;background:#ffffff20;border:1px solid #ffffff40}.level-chip span{font-size:9px;letter-spacing:1px;opacity:.8}.level-chip b{font:24px Jua,sans-serif;color:#ffe18f}.level-chip i{font-style:normal;font-size:11px;opacity:.8}.sound-button{width:37px;height:37px;border-radius:50%;background:#ffffff20;color:#fff;font-size:20px;border:1px solid #ffffff35}
.orderbar{height:76px;min-height:76px;display:flex;align-items:center;gap:10px;padding:9px 18px;background:linear-gradient(180deg,#fffaf0,#fff4dd);position:relative;z-index:2;border-bottom:1px solid #e8d6ac}.order-copy{display:grid;line-height:1.1;flex:1}.eyebrow{font-size:10px;letter-spacing:1.1px;color:#ab7843;text-transform:uppercase}.order-copy strong{font:18px Jua,sans-serif;color:#244b4c;margin-top:4px}.order-copy small{font-size:11px;color:#87704e;margin-top:3px}.order-drink{height:57px;min-width:68px;display:flex;align-items:center;gap:4px}.order-drink img{width:43px;height:52px;object-fit:contain;filter:drop-shadow(0 4px 3px #6b7b5433)}.order-drink b{font:15px Jua,sans-serif;color:#0f7776}.stage-progress{position:absolute;left:0;right:0;bottom:0;height:4px;background:#e8d9bb}.stage-progress div{height:100%;width:0;background:linear-gradient(90deg,#ffbd57,#ff775b);transition:width .35s ease}
.playfield{position:relative;flex:1;min-height:0;overflow:hidden;background:#d9a75d}canvas{width:100%;height:100%;display:block;touch-action:none}.hint{position:absolute;left:50%;bottom:18%;transform:translateX(-50%);display:flex;align-items:center;gap:8px;padding:9px 14px;border-radius:24px;background:#fffbefdc;color:#42605b;font-size:11px;line-height:1.2;text-align:left;box-shadow:0 5px 15px #66390835;pointer-events:none;transition:opacity .5s}.hint b{font:14px Jua,sans-serif;color:#117d79}.hint-finger{font-size:26px;color:#ef7657;animation:point 1s ease-in-out infinite alternate}.shot-counter{position:absolute;right:12px;top:12px;display:flex;gap:7px;align-items:center;padding:6px 10px;border-radius:20px;background:#fff9e7e8;color:#53635a;font-size:11px;box-shadow:0 3px 10px #673e1d20}.shot-counter b{display:grid;place-items:center;width:23px;height:23px;border-radius:50%;background:#ffca65;color:#734816;font:15px Jua,sans-serif}.toast{position:absolute;top:18px;left:50%;transform:translate(-50%,-12px);padding:8px 14px;background:#123f42ed;color:white;font-size:12px;border-radius:20px;opacity:0;pointer-events:none;transition:.2s;white-space:nowrap}.toast.show{opacity:1;transform:translate(-50%,0)}
.bottombar{height:82px;min-height:82px;background:linear-gradient(180deg,#fffaf0,#f3e8cf);display:flex;align-items:center;padding:8px 16px;gap:12px;z-index:2;border-top:1px solid #dcc99e;box-shadow:0 -4px 12px #765b2c20}.next-drink{height:62px;display:grid;grid-template-columns:42px auto;grid-template-rows:22px 21px;align-items:center;column-gap:6px;flex:1;min-width:0}.next-drink img{grid-row:1/3;width:40px;height:58px;object-fit:contain;filter:drop-shadow(0 3px 2px #7d694230)}.next-drink span,.score span{font-size:10px;color:#8d7955;line-height:1}.next-drink b{font:14px Jua,sans-serif;color:#325658;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.score{display:grid;text-align:right;min-width:77px}.score b{font:21px Jua,sans-serif;color:#b77922;line-height:1.15}.restart-button{width:44px;height:44px;border-radius:15px;background:#fff;color:#a56037;box-shadow:0 3px 0 #dec895,0 5px 10px #5b421b1c;font-size:26px;line-height:1}
.overlay{position:absolute;inset:0;z-index:4;display:grid;place-items:center;background:#083b43a6;backdrop-filter:blur(3px);padding:24px}.overlay[hidden]{display:none}.result-card{width:min(100%,330px);padding:24px 22px 20px;text-align:center;border:3px solid #fff0c9;border-radius:26px;background:linear-gradient(165deg,#fffdf6,#ffe8bd);box-shadow:0 15px 40px #002c3344;animation:pop .35s cubic-bezier(.2,.9,.25,1.2)}.result-icon{font-size:44px;line-height:1;margin-bottom:9px;filter:drop-shadow(0 4px 2px #56382324)}.result-card h1{margin:5px 0 5px;font:27px Jua,sans-serif;color:#276365}.result-text{font-size:13px;color:#766449;margin:0 auto 15px;max-width:250px}.result-actions{display:grid;gap:9px}.action-button{min-height:46px;border-radius:15px;padding:10px 16px;font:17px Jua,sans-serif;box-shadow:0 4px 0 #174a4330;transition:transform .1s,filter .1s}.action-button:active{transform:translateY(2px);filter:brightness(.95)}.action-primary{background:linear-gradient(180deg,#25afa0,#168278);color:white}.action-reward{background:linear-gradient(180deg,#ffc75d,#f5a83c);color:#583c13}.action-quiet{background:#fff;color:#54706a;box-shadow:0 3px 0 #d9caa9}.action-button small{font:10px 'Gowun Dodum',sans-serif;display:block;opacity:.85;margin-top:2px}
@keyframes point{from{transform:translate(0,0) rotate(-25deg)}to{transform:translate(9px,-7px) rotate(5deg)}}@keyframes pop{from{transform:scale(.78);opacity:0}to{transform:scale(1);opacity:1}}
@media(min-width:621px){.game-shell{height:min(100dvh,1000px);border-radius:24px;border:1px solid #b5d9bf}.topbar{border-radius:24px 24px 0 0}.playfield{min-height:480px}}
@media(max-height:620px) and (orientation:landscape){.game-shell{width:100vw}.topbar{height:50px;min-height:50px}.orderbar{height:57px;min-height:57px}.bottombar{height:61px;min-height:61px}.brand strong{font-size:17px}.order-drink img{height:43px}.hint{bottom:10%}}

/* Prize wallet and compact merge roadmap */
.topbar{gap:7px;padding-left:11px;padding-right:11px}
.brand{gap:6px;min-width:0}
.brand-mark{width:30px;height:30px;flex:0 0 30px;font-size:20px}
.brand strong{font-size:16px;white-space:nowrap}
.brand small{font-size:8px;letter-spacing:1px}
.coin-purse{height:34px;min-width:58px;display:flex;align-items:center;justify-content:center;gap:4px;padding:0 7px;border:1px solid #fff7;border-radius:12px;background:#6b4d2438;color:#fff4c9;white-space:nowrap}
.coin-purse span{font-size:16px;line-height:1}
.coin-purse b{font:15px Jua,sans-serif}
.goal-counter b{width:auto;min-width:43px;padding:0 5px;border-radius:12px;font-size:13px}
.level-chip{height:38px;min-width:79px;gap:3px;padding:4px 7px}
.level-chip b{font-size:21px}
.sound-button{width:33px;height:33px;flex:0 0 33px;font-size:18px}
.bottombar{height:132px;min-height:132px;display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;gap:0;padding:4px 12px 7px}
.merge-guide{height:51px;min-height:51px;display:flex;flex-direction:column;justify-content:center;gap:1px;border-bottom:1px solid #ddcba8}
.merge-caption{padding-left:2px;color:#927349;font-size:8px;line-height:10px;font-weight:700;letter-spacing:.3px}
.merge-track{height:37px;display:flex;align-items:center;justify-content:center;gap:clamp(1px,1vw,5px);overflow:hidden}
.merge-step{height:33px;min-width:0;max-width:34px;flex:1 1 30px;position:relative;display:grid;place-items:center;border:1px solid transparent;border-radius:8px;opacity:.63}
.merge-step img{display:block;width:clamp(20px,7vw,29px);height:29px;object-fit:contain;filter:drop-shadow(0 2px 1px #51381430)}
.merge-step.current{opacity:1;border-color:#36ad91;background:#dffff1;box-shadow:0 0 0 1px #43b89955}
.merge-step.current i{background:#138c76}
.merge-step.goal{opacity:1;border-color:#e9a63f;background:#fff0c8;box-shadow:0 0 0 1px #f1be5b66}
.merge-step.goal i{background:#d58b25}
.bottom-controls{height:68px;min-height:68px;display:flex;align-items:center;gap:9px;padding:4px 1px 0}
.bottom-controls .next-drink{height:58px}
.bottom-controls .next-drink img{width:36px;height:53px}
.bottom-controls .score{min-width:68px}
.bottom-controls .score b{font-size:18px}
.bottom-controls .restart-button{width:39px;height:39px;flex:0 0 39px;border-radius:13px;font-size:23px}
@media(max-width:360px){.brand strong{font-size:14px}.brand small{font-size:7px}.topbar{gap:5px;padding-left:8px;padding-right:8px}.level-chip{min-width:73px}.merge-track{gap:0}.merge-step img{width:23px}}
@media(max-height:620px) and (orientation:landscape){.bottombar{height:91px;min-height:91px}.merge-guide{height:38px;min-height:38px}.merge-track{height:27px}.merge-step{height:25px}.merge-step img{height:23px}.bottom-controls{height:49px;min-height:49px}.bottom-controls .next-drink{height:43px}.bottom-controls .next-drink img{height:40px}}

/* Compact HUD arranged like the playable reference: wallet, score, level and NEXT. */
.topbar{height:68px;min-height:68px;gap:7px;padding:5px 9px;justify-content:space-between}
.coin-purse{min-width:59px;height:35px;padding:0 6px;gap:3px}
.coin-purse b{font-size:14px}
.score-pill{display:grid;justify-items:center;align-content:center;min-width:47px;height:36px;padding:2px 5px;border:1px solid #ffffff45;border-radius:10px;background:#ffffff18;color:#fff}
.score-pill span{font-size:8px;line-height:10px;opacity:.82}
.score-pill b{max-width:59px;overflow:hidden;text-overflow:ellipsis;font:14px Jua,sans-serif;line-height:16px;color:#ffe18f}
.level-chip{min-width:67px;height:36px;gap:2px;padding:3px 5px}
.level-chip span{font-size:8px}
.level-chip b{font-size:18px}
.level-chip i{font-size:9px}
.next-ticket{width:70px;height:59px;flex:0 0 70px;display:grid;grid-template-columns:1fr 31px;grid-template-rows:12px 1fr;align-items:center;padding:2px 4px;border:1px solid #fff8;border-radius:10px;background:#fff9e8;color:#815521;box-shadow:0 2px 6px #063e3d30;overflow:hidden}
.next-ticket span{grid-column:1;grid-row:1;font:bold 8px/12px system-ui,sans-serif;letter-spacing:.35px}
.next-ticket img{grid-column:2;grid-row:1/3;width:30px;height:46px;object-fit:contain;filter:drop-shadow(0 2px 2px #60431d42)}
.next-ticket b{grid-column:1;grid-row:2;align-self:center;font:8px/1.05 Jua,sans-serif;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.orderbar{height:70px;min-height:70px;padding:7px 14px}
.bottombar{height:61px;min-height:61px;display:flex;align-items:center;padding:6px 8px;background:linear-gradient(180deg,#fffaf0,#f3e8cf)}
.merge-guide{height:46px;min-height:46px;width:100%;display:flex;align-items:center;gap:3px;border:0}
.merge-track{height:42px;min-width:0;flex:1;justify-content:space-between;gap:1px}
.merge-step{height:39px;max-width:none;flex:1 1 24px;border-radius:6px}
.merge-step img{width:clamp(18px,6.2vw,27px);height:35px}
.merge-end-arrow{display:grid;place-items:center;flex:0 0 28px;height:34px;border-radius:8px;background:#8dca50;color:#fff;font:bold 21px/1 system-ui,sans-serif;box-shadow:0 2px 0 #57933b}
@media(max-width:360px){.topbar{gap:4px;padding-inline:6px}.coin-purse{min-width:53px}.score-pill{min-width:40px}.level-chip{min-width:61px}.next-ticket{width:65px;flex-basis:65px}.merge-track{gap:1px}.merge-step img{width:20px}}
@media(max-height:620px) and (orientation:landscape){.topbar{height:54px;min-height:54px}.next-ticket{height:46px;grid-template-rows:10px 1fr}.next-ticket img{height:36px}.orderbar{height:53px;min-height:53px}.bottombar{height:47px;min-height:47px}.merge-guide{height:35px;min-height:35px}.merge-track{height:34px}.merge-step{height:31px}.merge-step img{height:28px}}

/* One compact top menu: the goal cup leads, followed by the next-cup preview. */
.topbar{height:74px;min-height:74px;gap:5px;padding:5px 8px}
.coin-purse{min-width:54px;height:34px;padding-inline:5px}
.score-pill{min-width:38px;height:34px;padding-inline:3px}
.score-pill b{max-width:49px;font-size:13px}
.level-chip{min-width:57px;height:34px;padding:3px 4px}
.level-chip b{font-size:17px}
.target-ticket{position:relative;display:grid;grid-template-columns:34px minmax(0,1fr) auto;grid-template-rows:1fr;align-items:center;gap:3px;flex:1;min-width:84px;height:60px;padding:3px 5px 6px;border:1px solid #ead5a9;border-radius:10px;background:#fff5dc;color:#765124;box-shadow:0 2px 6px #063e3d20;overflow:hidden}
.target-ticket>img{grid-column:1;grid-row:1;width:34px;height:47px;object-fit:contain;filter:drop-shadow(0 2px 2px #60431d35)}
.target-copy{grid-column:2;grid-row:1;display:grid;min-width:0;gap:1px;line-height:1}
.target-copy span{font:bold 7px/9px system-ui,sans-serif;letter-spacing:.45px;color:#a97537}
.target-copy b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:9px/11px Jua,sans-serif;color:#5d4930}
.target-copy small{font:7px/9px system-ui,sans-serif;color:#92754e}
.target-ticket>strong{grid-column:3;grid-row:1;align-self:start;margin-top:5px;padding:3px 4px;border-radius:7px;background:#fff;color:#986820;font:bold 8px/1 system-ui,sans-serif;white-space:nowrap}
.target-ticket .stage-progress{height:3px;background:#ead8b7}
.target-ticket .stage-progress div{background:linear-gradient(90deg,#f7b944,#ef8054)}
.next-ticket{width:57px;flex:0 0 57px;height:60px;grid-template-columns:1fr;grid-template-rows:10px 1fr;justify-items:center;padding:2px 3px 3px}
.next-ticket span{grid-column:1;grid-row:1}
.next-ticket img{grid-column:1;grid-row:2;width:35px;height:39px}
.next-ticket b{display:none}
.playfield{flex:1}
.merge-track{justify-content:space-around;gap:0}
.merge-step{border:0;border-radius:0;opacity:1;background:transparent;box-shadow:none}
.merge-step.current,.merge-step.goal{opacity:1;border:0;background:transparent;box-shadow:none}
.merge-step img{width:clamp(20px,6.8vw,30px);height:37px;filter:drop-shadow(0 2px 1px #51381430)}
@media(max-width:360px){.topbar{gap:3px;padding-inline:5px}.coin-purse{min-width:48px}.score-pill{min-width:32px}.score-pill b{max-width:38px;font-size:12px}.level-chip{min-width:50px}.level-chip span{font-size:7px}.level-chip b{font-size:15px}.level-chip i{font-size:8px}.target-ticket{min-width:66px;grid-template-columns:27px minmax(0,1fr) auto;gap:2px;padding-inline:3px}.target-ticket>img{width:28px;height:42px}.target-copy b{font-size:8px}.target-copy small{font-size:6px}.target-ticket>strong{font-size:7px;padding:3px 2px}.next-ticket{width:47px;flex-basis:47px}.next-ticket img{width:31px;height:36px}.merge-step img{width:19px}}
@media(max-height:620px) and (orientation:landscape){.topbar{height:58px;min-height:58px}.target-ticket,.next-ticket{height:47px}.target-ticket>img{height:38px}.next-ticket img{height:32px}}

/* Large, unclipped drink previews sit on the lower part of the wooden table. */
.topbar{height:58px;min-height:58px;justify-content:flex-end;gap:9px}
.cup-previews{position:absolute;z-index:1;left:5%;right:5%;bottom:8%;display:flex;justify-content:space-between;gap:8%;pointer-events:none}
.table-cup-card{position:relative;display:flex;align-items:center;gap:5px;width:46%;height:70px;padding:4px 8px;border:1px solid #fff9;border-radius:12px;background:linear-gradient(110deg,#fff8e9ed,#f2d7a9e8);box-shadow:0 4px 12px #5232113b;overflow:visible}
.table-cup-card>img{width:49px;height:60px;flex:0 0 49px;object-fit:contain;filter:drop-shadow(0 3px 2px #51381445)}
.table-cup-copy{display:grid;min-width:0;flex:1;gap:2px;line-height:1.05}
.table-cup-copy span,.preview-label{font:700 9px/1 system-ui,sans-serif;color:#a06b30;letter-spacing:.25px}
.table-cup-copy b,.next-preview b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:12px/1.1 Jua,sans-serif;color:#5d4930}
.table-cup-copy small{font:9px/1 system-ui,sans-serif;color:#92754e}
.table-cup-card>strong{align-self:flex-start;margin-top:2px;padding:4px 5px;border-radius:7px;background:#fff;color:#986820;font:bold 9px/1 system-ui,sans-serif;white-space:nowrap}
.table-cup-card .stage-progress{height:3px;background:#ead8b7}
.table-cup-card .stage-progress div{background:linear-gradient(90deg,#f7b944,#ef8054)}
.next-preview{display:grid;grid-template-columns:minmax(0,1fr) 49px;grid-template-rows:18px 1fr;align-items:center;padding:3px 8px}
.next-preview .preview-label{grid-column:1;grid-row:1}
.next-preview>img{grid-column:2;grid-row:1/3;width:49px;height:60px;object-fit:contain;filter:drop-shadow(0 3px 2px #51381445)}
.next-preview b{grid-column:1;grid-row:2;align-self:start;font-size:11px}
.topbar{justify-content:flex-start}
/* The referenced area is the bottom merge strip: give every cup a full, larger slot. */
.bottombar{height:76px;min-height:76px;padding:5px 7px}
.merge-guide{height:64px;min-height:64px;gap:4px;overflow:visible}
.merge-track{height:60px;overflow:visible;gap:0}
.merge-step{height:58px;overflow:visible;flex:1 1 0;min-width:0}
.merge-step img{width:clamp(28px,9vw,40px);height:54px;max-width:none;object-fit:contain;transform:scale(1.12);transform-origin:center;filter:drop-shadow(0 2px 2px #51381445)}
.merge-end-arrow{flex-basis:34px;height:42px;border-radius:8px;font-size:23px}
@media(max-width:360px){.topbar{gap:6px}.cup-previews{left:4%;right:4%;gap:5%}.table-cup-card{width:47.5%;height:64px;padding:3px 5px;gap:3px}.table-cup-card>img{width:40px;height:54px;flex-basis:40px}.table-cup-copy span,.preview-label{font-size:8px}.table-cup-copy b,.next-preview b{font-size:10px}.table-cup-copy small{font-size:8px}.table-cup-card>strong{font-size:8px;padding:3px}.next-preview{grid-template-columns:minmax(0,1fr) 41px;padding-inline:5px}.next-preview>img{width:41px;height:54px}}
@media(max-width:360px){.merge-step img{width:clamp(27px,9vw,33px);height:51px;transform:scale(1.08)}.merge-end-arrow{flex-basis:30px;height:38px}}
@media(max-height:620px) and (orientation:landscape){.topbar{height:48px;min-height:48px}.cup-previews{bottom:6%}.table-cup-card{height:55px}.table-cup-card>img,.next-preview>img{height:47px}.bottombar{height:62px;min-height:62px}.merge-guide{height:53px;min-height:53px}.merge-track{height:50px}.merge-step{height:49px}.merge-step img{height:46px}}

/* Put the goal on the canopy and the queued cup beside the fixed launch point. */
.cup-previews{inset:0;left:0;right:0;bottom:auto;display:block}
.goal-preview{position:absolute;left:50%;top:5%;transform:translateX(-50%);width:min(250px,68%);height:66px}
.next-preview{position:absolute;left:calc(50% + 43px);top:72%;width:min(126px,36%);height:60px}
@media(max-width:360px){.goal-preview{top:4%;height:60px}.next-preview{left:calc(50% + 34px);top:73%;width:min(112px,36%);height:56px}}
@media(max-height:620px) and (orientation:landscape){.goal-preview{top:3%;height:52px}.goal-preview>img{height:44px}.next-preview{top:70%;height:50px}.next-preview>img{height:43px}}

/* v2: next card no longer collapses to the top, completed cups live in the top bar, merge strip sits on the table front. */
.cup-previews{bottom:0}
.done-chip{height:34px;display:flex;align-items:center;gap:3px;padding:0 6px;border:1px solid #ffffff45;border-radius:10px;background:#ffffff18;color:#fff;white-space:nowrap}
.done-chip img{width:20px;height:28px;object-fit:contain;filter:drop-shadow(0 1px 1px #0005)}
.done-chip span{font-size:8px;opacity:.82}
.done-chip b{font:14px Jua,sans-serif;color:#ffe18f}
.game-shell{position:relative}
.bottombar{position:absolute;left:0;right:0;bottom:0;height:78px;min-height:0;padding:4px 8px 6px;background:linear-gradient(180deg,#fff6df00,#6b3f1a33);border:0;box-shadow:none;pointer-events:none}
.merge-guide{padding:0 4px;border-radius:14px;background:#fff7e6cc;box-shadow:0 3px 10px #4a2a0f40}
@media(max-width:360px){.done-chip span{display:none}}
.merge-guide{flex-direction:row;align-items:center}
.merge-end-arrow{flex:0 0 28px;height:34px;font-size:20px}

/* Goal and next cups are pictures only: goal centred on the cloth, next at the right edge of the launch row. */
.table-cup-card{background:none;border:0;box-shadow:none;padding:0;gap:0}
.table-cup-copy,.table-cup-card>strong,.table-cup-card .stage-progress,.preview-label,.next-preview b{display:none}
.goal-preview{left:50%;top:calc(50% - 0px);width:auto;height:auto;top:6.5%;transform:translateX(-50%)}
.goal-preview>img{width:84px;height:104px;flex-basis:auto;filter:drop-shadow(0 4px 4px #51381466)}
.next-preview{display:flex;left:auto;right:4%;top:73%;width:auto;height:auto}
.next-preview>img{width:62px;height:76px;filter:drop-shadow(0 3px 3px #51381466)}
@media(max-width:360px){.goal-preview>img{width:72px;height:90px}.next-preview>img{width:54px;height:66px}}
.goal-preview{top:15%;transform:translate(-50%,-50%)}
.goal-preview{top:9%}
@media(max-width:360px){.goal-preview{top:9%}}
.goal-preview{top:5.5%}
@media(max-width:360px){.goal-preview{top:5.5%}}

/* Transparent top bar floating over the artwork. */
.topbar{position:absolute;top:env(safe-area-inset-top);left:0;right:0;background:transparent;box-shadow:none;border:0;border-radius:0}
.coin-purse,.score-pill,.done-chip,.level-chip{background:#0b4f5a66;border-color:#ffffff55;text-shadow:0 1px 2px #0006}
.goal-preview{top:14.5%}
@media(max-width:360px){.goal-preview{top:14.5%}}
.topbar{justify-content:flex-start}.done-chip{margin-left:auto}
.goal-preview{top:10.5%}
@media(max-width:360px){.goal-preview{top:10.5%}}
.goal-preview{top:8.5%}
@media(max-width:360px){.goal-preview{top:8.5%}}

/* WANTED poster on the canopy cloth. */
.goal-preview{top:17.5%;display:flex;flex-direction:column;align-items:center;gap:0;padding:7px 14px 8px;min-width:112px;border:3px solid #7a4a22;border-radius:6px;background:linear-gradient(160deg,#f6e2b0,#e7c47f);box-shadow:0 5px 12px #4a2a0f66,inset 0 0 14px #b9833a66;transform:translate(-50%,-50%) rotate(-1.5deg)}
.goal-preview::before,.goal-preview::after{content:"";position:absolute;top:4px;width:6px;height:6px;border-radius:50%;background:#5a3414;box-shadow:inset 0 1px 1px #fff8}
.goal-preview::before{left:5px}.goal-preview::after{right:5px}
.wanted-title{font:900 25px/1 Georgia,'Times New Roman',serif;letter-spacing:2px;color:#5a2d0c;text-shadow:0 1px 0 #fff6,0 -1px 0 #0003;border-bottom:2px solid #7a4a22;padding:2px 2px 4px;margin-bottom:3px}
.goal-preview>img{width:70px;height:88px}
@media(max-width:360px){.wanted-title{font-size:21px}.goal-preview{min-width:96px}.goal-preview>img{width:60px;height:76px}}

/* Merge strip: cup art is square (320x320); keep it square, unscaled and unblurred. */
.merge-step{height:auto;flex:1 1 0}
.merge-step img{width:min(100%,38px);height:auto;aspect-ratio:1/1;max-width:none;transform:none;object-fit:contain}
.merge-end-arrow{flex:0 0 26px;height:30px;font-size:18px}

/* Compact WANTED poster hangs right under the top bar; NEXT cup sits under the level chip. */
.goal-preview{top:calc(env(safe-area-inset-top) + 60px);transform:translateX(-50%) rotate(-1.2deg);padding:5px 12px 6px;min-width:92px}
.wanted-title{font-size:15px;letter-spacing:1.5px;padding:1px 2px 3px;margin-bottom:2px;border-bottom-width:1.5px}
.goal-preview>img{width:54px;height:68px}
.goal-preview::before,.goal-preview::after{top:3px;width:5px;height:5px}
.next-preview{top:calc(env(safe-area-inset-top) + 64px);right:6px}
.next-preview>img{width:62px;height:76px}
@media(max-width:360px){.goal-preview{top:calc(env(safe-area-inset-top) + 60px);min-width:84px}.wanted-title{font-size:13px}.goal-preview>img{width:48px;height:60px}.next-preview{top:calc(env(safe-area-inset-top) + 64px);right:4px}.next-preview>img{width:54px;height:66px}}

/* Poster sits in the top-bar row between the score and completed chips; cup art matches in-game cup size. */
.goal-preview{left:153px;top:calc(env(safe-area-inset-top) + 3px);min-width:0;padding:3px 7px 5px;transform:translateX(-50%) rotate(-1deg);z-index:3}
.wanted-title{font-size:9px;letter-spacing:.8px;padding:0 1px 2px;margin-bottom:1px;border-bottom-width:1px}
.goal-preview>img{width:56px;height:70px}
.goal-preview::before,.goal-preview::after{top:2px;width:3px;height:3px}
.goal-preview::before{left:3px}.goal-preview::after{right:3px}
@media(max-width:360px){.goal-preview{left:140px;min-width:0}.wanted-title{font-size:8px}.goal-preview>img{width:50px;height:62px}}

/* Poster centred in the top-bar row with a larger cup; right-hand chips compacted to leave room. */
.goal-preview{left:50%;padding:3px 8px 5px}
.goal-preview>img{width:64px;height:80px}
.level-chip i{display:none}
.done-chip img,.done-chip span{display:none}
.done-chip b::before{content:"✓ ";font-size:11px;color:#bff5c8}
@media(max-width:360px){.goal-preview{left:50%}.goal-preview>img{width:56px;height:70px}}
@keyframes wantedSwap{0%{transform:translateX(-50%) rotate(-1deg) scale(.7) rotateX(70deg);opacity:.2}60%{transform:translateX(-50%) rotate(2deg) scale(1.12)}100%{transform:translateX(-50%) rotate(-1deg) scale(1);opacity:1}}
.goal-preview.swap{animation:wantedSwap .45s ease-out}

/* Toasts appear on the cloth below the WANTED poster instead of on top of it. */
.toast{top:calc(env(safe-area-inset-top) + 170px)}

.sound-toggle{position:absolute;z-index:3;left:8px;top:calc(env(safe-area-inset-top) + 64px);width:34px;height:34px;border-radius:50%;border:1px solid #ffffff66;background:#0b4f5a88;color:#fff;font-size:16px;line-height:1;display:grid;place-items:center;padding:0}

.lang-toggle{position:absolute;z-index:3;left:48px;top:calc(env(safe-area-inset-top) + 64px);height:34px;min-width:38px;padding:0 8px;border-radius:17px;border:1px solid #ffffff66;background:#0b4f5a88;color:#fff;font:700 12px/1 system-ui,sans-serif;letter-spacing:.5px}
