/* Game-style menus: a one-screen home over the live 3D street, the map picker, each map's mission road and two bottom sheets. */
#menu.game-menu{padding:0;overflow:hidden;text-align:left;justify-content:flex-start;align-items:stretch;background:linear-gradient(180deg,#06140ff4,#0a2019f8)}
#menu.game-menu.gm-on-home{background:linear-gradient(180deg,#06140fd8 0,#06140f00 22%,#06140f00 44%,#06140fc4 66%,#06140ff2 100%)}
#menu .menu-shell{max-width:none;width:100%;height:100%;margin:0;position:relative}
.gm-home[hidden],.gm-screen[hidden],.gm-sheet[hidden],.gm-explore[hidden],.gm-badge[hidden],.gm-dot[hidden]{display:none!important}
#menu button{-webkit-tap-highlight-color:transparent}

/* ---- home ---- */
.gm-home{height:100%;display:flex;flex-direction:column;gap:10px;max-width:560px;margin:0 auto;padding:max(10px,env(safe-area-inset-top)) max(14px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(14px,env(safe-area-inset-left))}
.gm-top{display:flex;align-items:center;gap:6px}
.gm-profile{display:flex;align-items:center;gap:8px;flex:1 1 auto;min-width:0;background:#0b221ce0;border:1px solid #3f6a55;border-radius:999px;padding:3px 12px 3px 3px;text-align:left;color:var(--ui-text)}
.gm-avatar{display:grid;place-items:center;width:38px;height:38px;flex:none;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe9a8,#e0a73c);font-size:20px;box-shadow:inset 0 -3px 0 #a5782d}
.gm-who{display:flex;flex-direction:column;min-width:0;line-height:1.25}
.gm-who b{font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.gm-level{display:flex;align-items:center;gap:6px;font-size:11px;color:#dfff63;font-weight:800;white-space:nowrap}
.gm-xp{display:block;width:54px;height:6px;border-radius:9px;background:#ffffff24;overflow:hidden;font-style:normal}
.gm-xp em{display:block;height:100%;width:0;background:linear-gradient(90deg,#dfff63,#9fe36f);border-radius:9px}
.gm-chip{display:inline-flex;align-items:center;height:34px;padding:0 10px;flex:none;border-radius:999px;background:#0b221ce0;border:1px solid #3f6a55;font-size:13px;font-weight:900;white-space:nowrap;color:var(--ui-text)}
.gm-stars{color:#ffd46a}.gm-coins{color:#c8f59a}
.gm-icon{position:relative;display:grid;place-items:center;width:38px;height:38px;flex:none;border-radius:50%;background:#0b221ce0;border:1px solid #3f6a55;font-size:17px;color:var(--ui-text);padding:0}
.gm-dot{position:absolute;top:0;right:0;width:11px;height:11px;border-radius:50%;background:#ff5d4d;border:2px solid #0b221c}
.gm-hero{text-align:center;margin-top:2px}
#menu .gm-hero h1{font-size:clamp(32px,10vw,46px);line-height:1.08;font-weight:900;margin:0;letter-spacing:-.02em;text-shadow:0 3px 0 #000a,0 0 26px #000c}
.gm-hero h1 span{color:var(--ui-gold)}
#menu .gm-tag{display:inline-flex;align-items:center;gap:7px;margin:6px 0 0;font-size:12px;font-weight:800;color:#e9f1e4;text-shadow:0 1px 4px #000}
#menu .gm-hero .sponsor-line{margin:4px 0 0}
/* the app link, highlighted right under the title */
#menu .gm-app{display:flex;width:max-content;max-width:100%;align-items:center;gap:8px;margin:10px auto 0;min-height:44px;padding:8px 20px;border-radius:999px;border:2px solid #fff3c4;
  background:linear-gradient(135deg,#ffe397,#ffbf4a);color:#233523;font-size:15px;font-weight:900;box-shadow:0 4px 0 #a5782d,0 0 0 0 #ffd46a99;animation:gm-app-glow 2.2s ease-out infinite}
#menu .gm-app span:first-child{font-size:19px}
#menu .gm-app:active{transform:translateY(2px);box-shadow:0 2px 0 #a5782d}
@keyframes gm-app-glow{0%{box-shadow:0 4px 0 #a5782d,0 0 0 0 #ffd46acc}70%{box-shadow:0 4px 0 #a5782d,0 0 0 14px #ffd46a00}100%{box-shadow:0 4px 0 #a5782d,0 0 0 0 #ffd46a00}}
@media (prefers-reduced-motion:reduce){#menu .gm-app{animation:none}}
.gm-notices{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:8px;pointer-events:none}
.gm-notices>*{pointer-events:auto;width:100%;max-width:440px;margin:0}
/* notice cards: solid, one line, so they read over the 3D street */
#menu .gm-notices .home-install,#menu .gm-sheet-notices .home-install{flex-wrap:nowrap;gap:8px;padding:8px 6px 8px 12px;background:#0f2a22f2;border:1px solid #57947a;border-radius:16px;box-shadow:0 8px 22px #0009}
#menu .gm-notices .install-text small{display:none}
#menu .gm-notices .install-text strong{font-size:13px;line-height:1.35}
#menu .gm-notices #installCard .install-go,#menu .gm-notices #pushCard .install-go,#menu .gm-sheet-notices #installCard .install-go,#menu .gm-sheet-notices #pushCard .install-go{flex:0 0 auto;min-height:38px;padding:6px 12px}
#menu .gm-notices .home-news{background:#0f2a22f2;border-color:#57947a;box-shadow:0 8px 22px #0009;max-height:38vh;overflow-y:auto}
.gm-dash{display:flex;flex-direction:column;gap:9px}
.gm-stats{display:grid;grid-template-columns:repeat(3,1fr);width:100%;padding:7px 4px;margin:0;border-radius:16px;background:#0b221ce0;border:1px solid #3f6a55;color:var(--ui-text)}
.gm-stat{display:flex;flex-direction:column;align-items:center;gap:1px;border-left:1px solid #ffffff16}
.gm-stat:first-child{border-left:0}
.gm-stat b{font-size:18px;font-weight:900;line-height:1.25}
.gm-stat small{font-size:10.5px;color:var(--ui-muted);font-weight:700}
#menu .gm-dash .chline{margin:0;font-size:12px;font-weight:800;color:#ffe5a4;text-align:center}
#menu .gm-challenge{width:100%;min-height:44px;margin:0;font-weight:800}
#menu .gm-play{display:flex;align-items:center;justify-content:center;gap:14px;width:100%;min-height:68px;margin:0;padding:8px 16px;border-radius:20px;font-size:25px;font-weight:900;box-shadow:0 6px 0 #a5782d,0 12px 26px #0008;animation:gm-glow 2.4s ease-in-out infinite}
#menu .gm-play:active{transform:translateY(3px);box-shadow:0 3px 0 #a5782d}
.gm-play-icon{display:grid;place-items:center;width:44px;height:44px;flex:none;border-radius:50%;background:#233523;color:#ffd46a;font-size:19px;padding-left:3px}
.gm-play-text{display:flex;flex-direction:column;text-align:left;line-height:1.15}
.gm-play-text small{font-size:12px;font-weight:700;opacity:.8}
#menu .gm-dash .quick-goal{margin:-3px 0 0;text-align:center}
.gm-mission-row{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.gm-missions,.gm-continue{position:relative;display:flex;align-items:center;gap:9px;min-width:0;min-height:62px;padding:8px 12px;border-radius:18px;text-align:left;color:var(--ui-text);background:linear-gradient(180deg,#22634a,#174634);border:1px solid #57947a;box-shadow:0 4px 0 #0b281e}
.gm-missions:active,.gm-continue:active,.gm-dock-btn:active,.gm-tile:active,.gm-map:active{transform:translateY(2px)}
.gm-mi-icon{font-size:25px;line-height:1}
.gm-mi-text{display:flex;flex-direction:column;font-size:19px;font-weight:900;line-height:1.15}
.gm-mi-text small{font-size:11px;font-weight:700;color:#d3e7d4}
.gm-missions meter,.gm-map-meta meter{-webkit-appearance:none;appearance:none;height:5px;border:0;border-radius:9px;background:#ffffff22;overflow:hidden}
.gm-missions{display:grid;grid-template-columns:auto minmax(0,1fr);align-content:center;column-gap:9px;row-gap:6px}.gm-missions meter{grid-column:1/-1;width:100%;margin:0}
.gm-missions meter::-webkit-meter-bar,.gm-map-meta meter::-webkit-meter-bar{background:#ffffff22;border:0;border-radius:9px;height:5px}
.gm-missions meter::-webkit-meter-optimum-value,.gm-map-meta meter::-webkit-meter-optimum-value,.gm-missions meter::-webkit-meter-suboptimum-value,.gm-map-meta meter::-webkit-meter-suboptimum-value,.gm-missions meter::-webkit-meter-even-less-good-value,.gm-map-meta meter::-webkit-meter-even-less-good-value{background:#ffd46a;border-radius:9px}
.gm-missions meter::-moz-meter-bar,.gm-map-meta meter::-moz-meter-bar{background:#ffd46a;border-radius:9px}
.gm-continue{flex-direction:column;align-items:flex-start;justify-content:center;gap:1px;padding-right:42px;background:linear-gradient(180deg,#2c4d3f,#1e3c30);border-color:#4f7a66}
.gm-continue small{font-size:10.5px;color:#dfff63;font-weight:800}
.gm-continue b{font-size:12.5px;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.gm-continue-go{position:absolute;right:10px;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#dfff63;color:#163325;font-size:11px;padding-left:2px}
.gm-dock{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.gm-dock-btn{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:0;min-height:62px;padding:8px 3px 7px;border-radius:16px;background:#0b221ce8;border:1px solid #3f6a55;color:var(--ui-text);font-size:11px;font-weight:800;line-height:1.2;text-align:center}
.gm-dock-btn>span{font-size:22px;line-height:1}
.gm-badge{position:absolute;top:-7px;right:-3px;display:grid;place-items:center;min-width:24px;height:20px;padding:0 5px;border-radius:999px;background:#ff5d4d;color:#fff;font-size:10px;font-style:normal;font-weight:900;border:2px solid #0b221c}

/* ---- map picker and mission road ---- */
.gm-screen{height:100%;display:flex;flex-direction:column;max-width:760px;margin:0 auto;padding:max(10px,env(safe-area-inset-top)) max(14px,env(safe-area-inset-right)) 0 max(14px,env(safe-area-inset-left))}
.gm-screen-head{display:flex;align-items:center;gap:10px;padding:2px 0 12px;flex:none}
.gm-back{display:grid;place-items:center;width:42px;height:42px;flex:none;padding:0;border-radius:50%;background:#173a2e;border:1px solid #4b6c58;color:var(--ui-text);font-size:20px;font-weight:900}
#menu .gm-screen-head h2{flex:1;min-width:0;margin:0;font-size:22px;font-weight:900}
.gm-maps{flex:1;min-height:0;overflow-y:auto;display:grid;gap:14px;align-content:start;padding:2px 2px max(18px,env(safe-area-inset-bottom))}
.gm-map{position:relative;display:flex;flex-direction:column;padding:0;overflow:hidden;border-radius:22px;text-align:left;color:var(--ui-text);background:#123227;border:1px solid #57947a;box-shadow:0 5px 0 #0a231b}
.gm-map-art{display:block;height:136px;background:#1d4a3a center/cover no-repeat}
.gm-map-art.dhaka{background-image:linear-gradient(180deg,#0000 50%,#123227),url('/dhaka/img/map-dhaka.jpg'),linear-gradient(135deg,#3b5d4c,#1d3a30)}
.gm-map-art.cox{background-image:linear-gradient(180deg,#0000 50%,#123227),url('/dhaka/img/map-cox.jpg'),linear-gradient(135deg,#2f6f86,#d9c48e)}
.gm-map-art.soon{display:grid;place-items:center;height:64px;font-size:30px;background:repeating-linear-gradient(135deg,#1a3a2f 0 14px,#163328 14px 28px)}
.gm-map-body{display:flex;flex-direction:column;gap:3px;padding:8px 14px 14px}
.gm-map-body b{font-size:22px;font-weight:900}
.gm-map-body small{font-size:12px;line-height:1.5;color:var(--ui-muted)}
.gm-map-meta{display:flex;align-items:center;gap:10px;margin-top:6px;font-size:12px;font-weight:800;color:#ffd46a}
.gm-map-meta meter{flex:1;min-width:40px}
.gm-map-new{position:absolute;top:10px;right:10px;z-index:1;padding:4px 10px;border-radius:999px;background:#ff5d4d;color:#fff;font-size:11px;font-weight:900;box-shadow:0 2px 6px #0006}
.gm-map.locked{box-shadow:none;border-style:dashed;filter:saturate(.5);opacity:.8}
.gm-explore{flex:none;display:flex;gap:8px;overflow-x:auto;padding:2px 2px 12px;scrollbar-width:none}
.gm-explore::-webkit-scrollbar{display:none}
.gm-tile-slot{display:contents}
.gm-tile{flex:none;display:flex;flex-direction:column;align-items:flex-start;gap:3px;width:128px;min-height:86px;padding:9px 10px;border-radius:16px;text-align:left;color:var(--ui-text);background:#173a2e;border:1px solid #4b6c58;box-shadow:0 3px 0 #0a231b}
.gm-tile>span{font-size:21px;line-height:1}
.gm-tile b{font-size:12.5px;line-height:1.3}
.gm-tile small{font-size:10.5px;line-height:1.3;color:var(--ui-muted)}
#menu .gm-cox-status{flex:1 1 auto;align-self:center;display:flex;flex-direction:column;gap:3px;min-width:0;margin:0;font-size:12px;line-height:1.45;color:var(--ui-muted)}
#exploreCox{overflow:visible}
.gm-cox-status strong{color:var(--ui-text)}
.gm-road-wrap{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden;margin:0 calc(-1*max(14px,env(safe-area-inset-right))) 0 calc(-1*max(14px,env(safe-area-inset-left)));border-top:1px solid #ffffff14;background:radial-gradient(circle at 20% 10%,#ffffff08 0 2px,#0000 3px) 0 0/34px 34px,linear-gradient(180deg,#123a2b,#0c2a1f)}
.gm-road{position:relative;max-width:480px;margin:0 auto}
.gm-road-art{position:absolute;inset:0;pointer-events:none}
.gm-road-art svg{display:block;width:100%;height:100%;overflow:visible}
.gm-road-art path{fill:none;stroke-linecap:round;stroke-linejoin:round;vector-effect:non-scaling-stroke}
.gm-road-edge{stroke:#091510;stroke-width:48}
.gm-road-top{stroke:#3b4542;stroke-width:40}
.gm-road-line{stroke:#efe4b0;stroke-width:2.5;stroke-dasharray:10 13}
.gm-stop{position:absolute;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;width:70px;padding:0;background:none;border:0;color:var(--ui-text)}
.gm-stop-dot{position:relative;display:grid;place-items:center;width:54px;height:54px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffeab0,#e2a83e);color:#233523;font-size:19px;font-weight:900;border:3px solid #fff3c4;box-shadow:0 5px 0 #8a5f20,0 9px 14px #0009}
.gm-stop.done .gm-stop-dot{background:radial-gradient(circle at 35% 30%,#dcff96,#6dbd48);border-color:#f0ffd4;box-shadow:0 5px 0 #3a7628,0 9px 14px #0009}
.gm-stop.locked .gm-stop-dot{background:#2a3934;border-color:#4b5d55;color:#9fb0a6;font-size:17px;box-shadow:0 4px 0 #141f1b}
.gm-stop.current .gm-stop-dot{width:64px;height:64px;font-size:23px;animation:gm-bob 1.5s ease-in-out infinite}
.gm-stop.current .gm-stop-dot::after{content:'';position:absolute;inset:-9px;border-radius:50%;border:3px solid #dfff63;animation:gm-ring 1.6s ease-out infinite}
.gm-stop.current::before{content:'🛺';position:absolute;top:-38px;font-size:26px;filter:drop-shadow(0 3px 2px #0009)}
.gm-stop-stars{min-height:15px;margin-top:5px;font-size:12px;letter-spacing:1px;color:#ffd46a;text-shadow:0 1px 2px #000}
.gm-stop-name{position:absolute;top:27px;transform:translateY(-50%);width:min(132px,32vw);font-size:11.5px;font-weight:800;line-height:1.3;color:#f2f6ea;text-shadow:0 1px 3px #000;pointer-events:none}
.gm-stop.left .gm-stop-name{left:68px;text-align:left}
.gm-stop.right .gm-stop-name{right:68px;text-align:right}
.gm-stop.locked .gm-stop-name{color:#a9b9b0}
.gm-stop.current.left .gm-stop-name{left:80px}.gm-stop.current.right .gm-stop-name{right:80px}

/* ---- bottom sheets ---- */
.gm-sheet{position:absolute;inset:0;z-index:5;display:flex;align-items:flex-end;justify-content:center;background:#020806b0}
.gm-sheet-in{width:100%;max-width:520px;max-height:90%;overflow-y:auto;display:flex;flex-direction:column;gap:12px;padding:14px 16px max(18px,env(safe-area-inset-bottom));border-radius:24px 24px 0 0;background:#0f2a22;border:1px solid #4b6c58;border-bottom:0;box-shadow:0 -12px 40px #0008;animation:gm-up .22s ease-out}
.gm-sheet-head{display:flex;align-items:center;justify-content:space-between;gap:10px}
#menu .gm-sheet-head h2{margin:0;font-size:19px}
#menu .gm-sheet-sub{margin:2px 0 -4px;font-size:13px;color:var(--ui-muted)}
#menu .gm-music{width:100%;min-height:46px;margin:0;font-weight:800}
#menu .gm-music[aria-pressed="false"]{opacity:.6}
.gm-sheet-settings:empty,.gm-sheet-notices:empty{display:none}
.gm-sheet-settings .control-settings{margin:0!important}
.gm-share-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}
#menu .gm-share-grid .home-share{display:flex;align-items:center;justify-content:center;width:auto;min-height:46px;margin:0;padding:8px;font-size:12.5px;font-weight:800;text-align:center;text-decoration:none}
#menu .gm-sheet .daily-jobs{margin:0}
#menu .gm-sheet .home-hint{margin:0}
.gm-profile-top{display:flex;align-items:center;gap:12px}
.gm-avatar.big{width:58px;height:58px;font-size:29px}
.gm-profile-top b{display:block;font-size:18px}
.gm-profile-top small{display:block;margin:2px 0 7px;font-size:12px;font-weight:800;color:#dfff63}
.gm-profile-top .gm-xp{width:190px;max-width:100%;height:8px}
.gm-profile-rows{display:grid;grid-template-columns:1fr auto;margin:0;border:1px solid #35584b;border-radius:14px;overflow:hidden}
.gm-profile-rows dt,.gm-profile-rows dd{margin:0;padding:9px 12px;font-size:13px;border-top:1px solid #ffffff12}
.gm-profile-rows dt{color:var(--ui-muted)}
.gm-profile-rows dd{font-weight:900;text-align:right}
.gm-profile-rows dt:first-of-type,.gm-profile-rows dd:first-of-type{border-top:0}
#menu .gm-profile-note{margin:0;font-size:12.5px;color:#ffe5a4}

@keyframes gm-glow{0%,100%{filter:brightness(1)}50%{filter:brightness(1.08)}}
@keyframes gm-bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-4px)}}
@keyframes gm-ring{0%{opacity:.9;transform:scale(.9)}100%{opacity:0;transform:scale(1.35)}}
@keyframes gm-up{from{transform:translateY(40px);opacity:0}to{transform:none;opacity:1}}
@media (hover:hover) and (pointer:fine){.gm-missions:hover,.gm-continue:hover,.gm-dock-btn:hover,.gm-tile:hover,.gm-map:hover,.gm-icon:hover,.gm-profile:hover,.gm-stats:hover,.gm-stop:hover .gm-stop-dot{filter:brightness(1.15)}}
@media (prefers-reduced-motion:reduce){#menu .gm-play,.gm-stop.current .gm-stop-dot,.gm-stop.current .gm-stop-dot::after,.gm-sheet-in{animation:none}}

/* wide screens: the menu sits in a left column and the rickshaw shows on the right */
@media (orientation:landscape) and (min-aspect-ratio:5/4){
 #menu.game-menu.gm-on-home{background:linear-gradient(90deg,#06140fec 0,#06140fb8 30%,#06140f00 56%),linear-gradient(180deg,#06140fa8 0,#06140f00 20%)}
 .gm-home{max-width:none;display:grid;grid-template-columns:minmax(300px,390px) 1fr;grid-template-rows:auto auto 1fr auto;grid-template-areas:"top top" "hero notices" "space notices" "dash notices";column-gap:28px;row-gap:10px}
 .gm-top{grid-area:top}.gm-hero{grid-area:hero;text-align:left}.gm-dash{grid-area:dash}
 #menu .gm-app{margin-left:0}
 .gm-notices{grid-area:notices;align-items:flex-end}
 .gm-top .gm-profile{flex:0 1 330px;margin-right:auto}
 .gm-maps{grid-template-columns:repeat(3,minmax(0,1fr))}
 .gm-map-art{height:150px}.gm-map-art.soon{height:150px}
}
@media (orientation:landscape) and (max-height:500px){
 .gm-home{row-gap:6px}
 #menu .gm-app{margin-top:4px;min-height:38px;padding:5px 14px;font-size:13px}
 #menu .gm-hero h1{font-size:26px}#menu .gm-tag{display:none}
 .gm-stats{padding:4px}.gm-stat b{font-size:15px}.gm-stat small{font-size:10px}
 #menu .gm-play{min-height:52px;font-size:20px;gap:10px}.gm-play-icon{width:34px;height:34px;font-size:15px}.gm-play-text small{font-size:11px}
 .gm-missions,.gm-continue{min-height:48px;padding:6px 10px}.gm-continue{padding-right:42px}.gm-missions{row-gap:4px}.gm-mi-icon{font-size:20px}.gm-mi-text{font-size:16px}
 .gm-dock-btn{min-height:48px;flex-direction:row;gap:5px;padding:4px}.gm-dock-btn>span{font-size:17px}
 .gm-screen-head{padding-bottom:6px}.gm-map-art,.gm-map-art.soon{height:96px}.gm-map-body{padding:6px 12px 10px}.gm-map-body b{font-size:18px}
 .gm-explore{padding-bottom:8px}.gm-tile{flex-direction:row;align-items:center;gap:7px;width:auto;min-height:44px;padding:6px 12px}.gm-tile small{display:none}.gm-tile b{white-space:nowrap}.gm-tile>span{font-size:17px}
}
@media (max-width:360px){.gm-chip{padding:0 7px;font-size:12px}.gm-xp{width:40px}.gm-dock-btn{font-size:10px}.gm-mi-text{font-size:17px}}
#menu #campaignProgress{height:5px;margin:0;accent-color:#ffd46a}
/* on the home screen a toast sits in the open middle, clear of the title and the app button */
@media (orientation:portrait){body:has(#menu.gm-on-home:not([hidden])) .toast{top:44%}}
