:root{--ink:#3b2a14}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{margin:0;height:100%;height:100dvh;overflow:hidden;overscroll-behavior:none;position:fixed;inset:0;width:100%;background:#4a2379;font-family:"Rubik","Varela Round","IBM Plex Sans Hebrew",Arial,sans-serif;color:#fff;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none;touch-action:none}
button{font-family:inherit;color:inherit;cursor:pointer;border:none;touch-action:manipulation}
#cv{position:fixed;inset:0;width:100%;height:100%;display:block;touch-action:none}
#conf{position:fixed;inset:0;width:100%;height:100%;pointer-events:none;z-index:25}
.iconbtn{width:48px;height:48px;border-radius:50%;background:#fff;color:#4a2379;box-shadow:0 4px 0 #0003;font-size:23px;display:flex;align-items:center;justify-content:center;flex:none;padding:0}
.iconbtn:active{transform:translateY(3px);box-shadow:0 1px 0 #0003}
#top{position:fixed;top:max(10px,env(safe-area-inset-top));inset-inline-start:12px;inset-inline-end:12px;z-index:20;display:none;gap:8px;align-items:center;flex-wrap:wrap}
body.play #top{display:flex}
.pill{background:#fff;color:#4a2379;border-radius:999px;padding:6px 12px;font-weight:900;font-size:clamp(15px,4.2vw,20px);box-shadow:0 3px 0 #0003;white-space:nowrap}
#cap{position:fixed;left:0;right:0;bottom:max(18px,env(safe-area-inset-bottom));z-index:19;text-align:center;font:900 clamp(22px,6.4vw,36px)/1.15 Rubik,Arial;text-shadow:0 3px 0 #0008;padding:0 16px;pointer-events:none;min-height:44px}
#picks{position:fixed;left:0;right:0;bottom:max(70px,calc(env(safe-area-inset-bottom) + 70px));z-index:21;display:none;justify-content:center;gap:10px;padding:0 10px;direction:ltr}
#picks.show{display:flex}
#picks button{flex:1;max-width:96px;min-height:64px;border-radius:20px;font:900 28px Rubik,Arial;color:#4a2379;background:#fff;box-shadow:0 5px 0 #0004}
#picks button:active{transform:translateY(4px);box-shadow:0 1px 0 #0004}
#nogl{position:fixed;inset:0;z-index:99;display:none;flex-direction:column;align-items:center;justify-content:center;gap:14px;background:#4a2379;padding:24px;text-align:center;font-size:20px;font-weight:700}
#nogl.show{display:flex}
#obar{position:fixed;left:0;right:0;bottom:max(14px,env(safe-area-inset-bottom));z-index:22;display:none;justify-content:center;gap:10px;padding:0 10px}
#obar.show{display:flex}#obar button{flex:1;max-width:190px;min-height:56px;border-radius:20px;font:900 18px Rubik,Arial;color:#fff;box-shadow:0 5px 0 #0004;padding:4px 8px}
#obar button:active{transform:translateY(4px)}#obar button.dis{filter:grayscale(1) opacity(.5);pointer-events:none}
body.hasobar #cap{bottom:calc(max(14px,env(safe-area-inset-bottom)) + 142px)}.pill:empty{display:none}
#oStars{font-size:44px;letter-spacing:6px;min-height:52px}#oStars span{display:inline-block}
#oStars span.off{filter:grayscale(1) opacity(.4)}
.pill.pop{animation:pillPop .45s}@keyframes pillPop{40%{transform:scale(1.3) rotate(-4deg)}}
body.shake #cv{animation:shk .35s}@keyframes shk{20%{transform:translate(-6px,3px)}40%{transform:translate(5px,-4px)}60%{transform:translate(-4px,-2px)}80%{transform:translate(3px,3px)}}
@media (orientation:landscape) and (max-height:700px){#picks button{min-height:50px}#picks{bottom:max(52px,calc(env(safe-area-inset-bottom) + 52px))}}

/* big laptop / desktop windows: scale the menu & result screens up so they do not look tiny */
/* menus use the shared kit (ui.js): the menu is a card docked at the bottom, the 3D scene stays visible above it */
.an-menu{--an-accent:#6b3fb0;z-index:30}
#pause,#over{z-index:31}
.goal{background:var(--an-tint);border-radius:12px;padding:4px 10px;font-size:15px}.goal:empty{display:none}
#cpBtn{display:none}#cpBtn.show{display:inline-flex}
#oStars span.off{filter:grayscale(1) opacity(.4)}
.an-set{display:flex;flex-direction:column;gap:8px}.an-set>b{font-size:15px;color:var(--an-soft);font-weight:600}

/* camera pass: on wide/landscape screens the 1-2-3 buttons and the caption must not overlap each other or hide the cups */
@media (orientation:landscape) and (max-height:700px){#cap{font-size:clamp(20px,4.6vh,28px);min-height:34px}#picks{bottom:max(64px,calc(env(safe-area-inset-bottom) + 64px))}}
@media (orientation:landscape) and (max-height:520px){.an-menu .an-in.one{flex-direction:column;align-items:stretch}.an-menu .an-in.one>*{align-self:stretch;grid-column:auto;grid-row:auto}}
@media (orientation:landscape) and (max-height:520px){.an-menu .an-in.one{gap:6px}.an-menu .an-in.one .an-body,.an-menu .an-in.one .an-foot,.an-menu .an-in.one .an-head{gap:6px}#over .an-in{padding-top:2px;padding-bottom:6px}}
