/* Draft scenery and controls; top status HUD inherits the original unboxed design. */
body.adventure-mode .adventure-heading-actions button:focus-visible,body.adventure-mode #adventureNotebook:focus-visible{outline:3px solid #08796e;outline-offset:4px}
body.adventure-mode .adventure-controls{left:max(14px,env(safe-area-inset-left,0px));right:max(14px,env(safe-area-inset-right,0px))}
body.adventure-mode .adventure-start{background:linear-gradient(150deg,#416b692b,#f8d79a33);backdrop-filter:blur(4px);overflow:auto}
body.adventure-mode .adventure-start>div{border:2px solid #f2d395;border-radius:26px;background:linear-gradient(150deg,#fffdf2,#fff0d0);box-shadow:inset 0 2px #fff,0 8px 0 #bd904b35,0 22px 60px #503c4133}
body.adventure-mode .adventure-start h2{color:#215d52}
body.adventure-mode .adventure-start-icon{width:54px;height:54px;display:grid;place-items:center;margin:0 auto 14px;border-radius:18px;border:1px solid #dfb563;background:linear-gradient(#fff0b4,#f1c969);box-shadow:0 3px 0 #b48a40;color:#745024}
body.adventure-mode .adventure-summary{background:linear-gradient(145deg,#fffdf1,#ffe9b8);border:2px solid #e7bd6d;box-shadow:0 10px 40px #493c3526;border-radius:24px}
@media(max-height:450px){
 body.adventure-mode .adventure-start>div{margin:auto;padding:12px 20px}
}
.arcade-draft-menu{max-width:650px;margin:8vh auto;padding:28px;text-align:center;background:#fff7e5;border:1px solid #e2bf7f;border-radius:24px;color:#245b50}.arcade-draft-menu h1{font-size:clamp(25px,5vw,36px);margin:18px 0}.arcade-draft-menu p{font-size:14px;line-height:1.6;margin:16px 0}.arcade-draft-options{display:grid;gap:12px;margin:24px 0}.arcade-draft-options button,.arcade-draft-menu>a{min-height:44px}.arcade-draft-menu>a{display:inline-flex;align-items:center;justify-content:center;padding:10px 14px}.arcade-draft-menu~.arcade-admin-draft{display:none}@media(max-height:450px){.arcade-draft-menu{margin:10px auto;padding:15px}.arcade-draft-menu p{margin:8px 0}.arcade-draft-options{margin:12px 0;grid-template-columns:repeat(3,1fr)}}
body.arcade-page:has(.arcade-draft-menu){height:auto;overflow:auto}body.arcade-page:has(.arcade-draft-menu)>main{height:auto;overflow:visible}.arcade-draft-menu{margin:30px auto;max-width:min(650px,calc(100vw - 24px))}

/* Raised thumb zones: secondary attack above-left of the larger jump button. */
body.adventure-mode .adventure-controls{
 bottom:calc(clamp(40px,8svh,76px) + env(safe-area-inset-bottom,0px));
 left:max(16px,env(safe-area-inset-left,0px));right:max(20px,env(safe-area-inset-right,0px));
}
body.adventure-mode .adventure-action-buttons{position:relative;width:176px;height:138px;flex:none;pointer-events:none}
body.adventure-mode .adventure-controls #adventureAttack{
 position:absolute;top:0;left:0;width:72px;min-width:72px;height:72px;min-height:72px;border-radius:50%;padding:8px;gap:5px;
}
body.adventure-mode .adventure-controls #adventureJump{
 width:88px;min-width:88px;height:88px;min-height:88px;border-radius:50%;padding:10px;flex-direction:column;gap:6px;font-size:13px;
}
body.adventure-mode .adventure-controls .adventure-action-buttons #adventureJump{position:absolute;right:0;bottom:0}
body.adventure-mode .adventure-controls #adventureJump svg{width:31px;height:31px}
@media(max-width:680px){
 body.adventure-mode .adventure-controls{left:max(14px,env(safe-area-inset-left,0px));right:max(14px,env(safe-area-inset-right,0px))}
 body.adventure-mode .adventure-action-buttons{width:152px;height:126px}
 body.adventure-mode .adventure-controls #adventureAttack{width:64px;min-width:64px;height:64px;min-height:64px}
 body.adventure-mode .adventure-controls #adventureJump,body.adventure-mode .adventure-controls:has(#adventureAttack) #adventureJump{width:80px;min-width:80px;height:80px;min-height:80px;padding:8px;gap:5px;font-size:12px}
}
@media(max-height:350px){
 body.adventure-mode .adventure-controls{bottom:calc(24px + env(safe-area-inset-bottom,0px))}
 body.adventure-mode .adventure-action-buttons{height:112px}
}

/* One carved jade-and-gold control family, with open scenery between buttons. */
body.adventure-mode .adventure-direction{padding:0;border:0;border-radius:0;background:none;box-shadow:none;gap:8px}
body.adventure-mode .adventure-controls :is(#adventureLeft,#adventureRight,#adventureJump,#adventureAttack){
 border:2px solid #e9c675;border-radius:50%;
 background:radial-gradient(circle at 35% 22%,#438f80,#22685d 55%,#124a43);
 color:#fff1c5;box-shadow:inset 0 0 0 3px #153f394d,inset 0 3px 3px #fff1c540,0 4px 0 #82612f,0 6px 12px #2c322b40;
 opacity:.95;text-shadow:0 1px 2px #173c35;transition:box-shadow .1s,filter .1s;
}
body.adventure-mode .adventure-controls :is(#adventureLeft,#adventureRight){width:64px;height:64px;min-width:64px;min-height:64px;padding:12px}
body.adventure-mode .adventure-controls :is(#adventureLeft,#adventureRight,#adventureJump,#adventureAttack).pressed{
 transform:translateY(3px);background:radial-gradient(circle at 35% 22%,#327366,#174f46);
 box-shadow:inset 0 2px 6px #102f3970,inset 0 0 0 3px #153f394d,0 1px 0 #82612f;
}
body.adventure-mode .adventure-controls #adventureAttack:disabled{opacity:.5;filter:saturate(.45)}
body.adventure-mode .adventure-controls button:focus-visible{outline:3px solid #fff3c9;outline-offset:4px}
@media(max-width:680px){body.adventure-mode .adventure-controls :is(#adventureLeft,#adventureRight){width:54px;height:54px;min-width:54px;min-height:54px;padding:10px}}
/* Keep gameplay pinned to the viewport even when lobby focus leaves a scroll offset. */
body.adventure-mode>main{position:fixed;inset:0;margin:0;height:100dvh}
/* Musafir puzzle draft: fixed landscape board, original explorer and carved stone. */
body.musafir-mode>header,body.musafir-mode>footer{display:none}body.musafir-mode>main{position:fixed;inset:0;width:100%;max-width:none;padding:0;overflow:auto;background:radial-gradient(ellipse at 70% 10%,#fceac0,#d4b27b)}
.musafir-shell{height:100dvh;min-height:320px;padding:12px max(18px,env(safe-area-inset-right));display:flex;flex-direction:column;color:#284d45;box-sizing:border-box;gap:10px}.musafir-shell header,.musafir-shell footer{display:flex;align-items:center;justify-content:space-between;gap:12px}.musafir-shell h1{font-size:clamp(17px,2.4vw,27px);margin:2px 0}.musafir-shell small{font-size:10px;letter-spacing:.5px}.musafir-shell button{min-height:44px;border:1px solid #b08a48;border-radius:12px;background:#fff2d0;color:#31584b;font-weight:800;padding:8px 14px;touch-action:manipulation}.musafir-shell button:disabled{opacity:.45}.musafir-shell button:focus-visible{outline:3px solid #247c70;outline-offset:2px}.musafir-play{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;gap:clamp(20px,5vw,80px)}.musafir-play aside{max-width:210px;width:26%}.musafir-play h2{font-size:clamp(22px,3vw,38px);line-height:1.1;margin:14px 0}.musafir-play p{font-size:13px;line-height:1.5}.musafir-tag{font-size:10px;letter-spacing:2px;color:#846128}#musafirStats{font-weight:800}#musafirBoard{--tile:min(calc((100dvh - 132px)/7),calc((72vw - 50px)/9),68px);display:grid;grid-template-columns:repeat(9,var(--tile));grid-auto-rows:var(--tile);border:5px solid #987748;border-radius:10px;overflow:hidden;box-shadow:0 7px 0 #785935,0 15px 35px #70562a30;background:#d4bb8d;flex-shrink:0}.musafir-tile{position:relative;display:grid;place-items:center}.musafir-tile.floor{background:linear-gradient(145deg,#f4dfb4,#e6cb98);box-shadow:inset 0 0 0 1px #b5986630}.musafir-tile.wall{background:linear-gradient(145deg,#d4b27d,#a17c4d);border:2px solid #b08c57;box-shadow:inset 0 3px #ecd3a3,inset -4px -5px #85643d55;border-radius:5px}.musafir-switch{width:56%;height:56%;border:3px solid #8e9a75;border-radius:50%;background:#a6b78a;box-shadow:inset 0 2px 4px #4e715655}.lit .musafir-switch{background:#5dc5a0;box-shadow:0 0 12px #66ddac}.musafir-box{position:absolute;inset:12%;display:grid;place-items:center;border:3px solid #8f592f;border-radius:4px;background:linear-gradient(135deg,#d2a763,#a8733e);box-shadow:inset 0 0 0 2px #e5bd77,0 3px 0 #70502a;color:#ffdf91;font-size:22px}.lit .musafir-box{border-color:#278b6b}.musafir-player{position:absolute;inset:-15% 6% 0;z-index:2;filter:drop-shadow(0 2px 1px #5e482e33)}.musafir-player svg{width:100%;height:100%}.musafir-door{width:65%;height:85%;border:3px solid #98703b;border-radius:40% 40% 0 0;display:grid;place-items:center;background:#80603c;font-size:20px}.musafir-door.open{background:#255b4f;color:#ffe69c;box-shadow:0 0 14px #78cd9a}.musafir-pad,.musafir-tools{display:flex;gap:7px;align-items:center}.musafir-pad button{width:48px;height:48px;padding:0;border-radius:50%;background:linear-gradient(#438b7c,#1b594f);color:#fff1c8;border:2px solid #e7bd70;box-shadow:0 3px #856539;font-size:25px}.musafir-tools small{max-width:140px}.musafir-pad button:active{transform:translateY(2px)}
@media(max-height:430px){.musafir-shell{padding-block:6px;gap:6px}.musafir-play h2{font-size:23px;margin:8px 0}.musafir-play p{font-size:11px;margin:7px 0}.musafir-tools small{display:none}#musafirBoard{--tile:min(calc((100dvh - 112px)/7),calc((72vw - 50px)/9))}}
@media(orientation:portrait){.musafir-play{flex-direction:column;gap:10px}.musafir-play aside{width:100%;max-width:none}.musafir-play h2{display:none}#musafirBoard{--tile:min(calc((100vw - 50px)/9),calc((100dvh - 240px)/7))}.musafir-shell footer{flex-wrap:wrap}.musafir-tools small{display:none}}
.musafir-shell>header,.musafir-shell>footer{position:static;inset:auto;width:100%;max-width:none;margin:0;padding:0;border:0;background:none;box-shadow:none;flex:0 0 auto;transform:none}.musafir-shell>header{min-height:44px}.musafir-shell>footer{min-height:48px}#musafirBoard{--tile:min(calc((100dvh - 160px)/7),calc((72vw - 50px)/9),68px)}
@media(orientation:portrait){#musafirBoard{--tile:min(calc((100vw - 50px)/9),calc((100dvh - 290px)/7))}}
.musafir-shell h1{font-family:Nunito,sans-serif;font-weight:800;line-height:1.3;letter-spacing:normal;text-shadow:none}
/* Oasis concept: warm cinematic village, restrained serif HUD and emerald/gold controls. */
body.oasis-mode>header,body.oasis-mode>footer{display:none}
body.oasis-mode>main{position:fixed;inset:0;padding:0;max-width:none;width:100%;overflow:hidden}
.oasis-shell{position:relative;width:100%;height:100dvh;background:#ead2a7;overflow:hidden;color:#ffedb0;font-family:Georgia,"Times New Roman",serif}
.oasis-shell:fullscreen{width:100vw;height:100dvh}
#oasisCanvas{width:100%;height:100%;display:block}
.oasis-hud{position:absolute!important;inset:clamp(12px,2.5vh,22px) max(18px,env(safe-area-inset-right)) auto max(18px,env(safe-area-inset-left))!important;display:flex!important;justify-content:space-between!important;align-items:flex-start!important;gap:12px!important;padding:0!important;background:none!important;border:0!important;box-shadow:none!important;pointer-events:none}
.oasis-hud-left{min-width:0}.oasis-hud-right{display:flex;align-items:center;gap:clamp(10px,1.5vw,20px)}
.oasis-route{width:clamp(225px,29vw,365px);padding:7px 12px 9px;background:linear-gradient(90deg,#101e17d6,#182419ab 82%,#18241900);border-radius:9px 0 0 9px;text-shadow:0 1px 3px #000}
.oasis-route>span{display:flex;align-items:center;gap:13px;font-size:clamp(14px,1.65vw,21px);font-weight:400;white-space:nowrap;color:#fff0b8}
.oasis-route>span svg{width:27px;height:28px;fill:none;stroke:#e9c76e;stroke-width:1.5;stroke-linecap:round}
.oasis-route progress{display:block;width:100%;height:10px;margin:5px 0 7px;padding:2px;appearance:none;border:1px solid #e9cb7b;border-radius:8px;background:#18251c;overflow:hidden;box-shadow:0 0 0 1px #493921}
.oasis-route progress::-webkit-progress-bar{background:#18251c}.oasis-route progress::-webkit-progress-value{background:linear-gradient(#fff3aa,#e9b739);border-radius:8px}.oasis-route progress::-moz-progress-bar{background:#ebbd49;border-radius:8px}
.oasis-hud #oasisMission{display:flex;align-items:center;gap:9px;font:400 clamp(12px,1.3vw,17px)/1.25 Georgia,serif;color:#fff4d3;margin:0}
#oasisMission:before{content:'';width:8px;height:8px;flex-shrink:0;background:#f2cc51;border:2px solid #534c27;outline:1px solid #e7ca7b;border-radius:50%}
.oasis-shell button{pointer-events:auto;min-width:44px;min-height:44px;border:2px solid #d9b970;background:#063d35;color:#ffe6a1;padding:8px;font-family:inherit;touch-action:manipulation;cursor:pointer}
.oasis-shell button:focus-visible{outline:3px solid #fff3af;outline-offset:4px}.oasis-shell button:active{filter:brightness(1.18)}
.oasis-task-badge{position:relative;width:clamp(125px,14vw,180px);height:49px;filter:drop-shadow(0 3px 3px #35250c77)}
.oasis-task-badge>svg{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
.oasis-task-badge>span{position:absolute;inset:0 10px;display:flex;align-items:center;justify-content:center;gap:9px;color:#312312;text-shadow:0 1px #fff2bd}
.oasis-task-badge small,.oasis-task-badge b{font:600 clamp(12px,1.15vw,16px)/1 Georgia,serif;white-space:nowrap}
.oasis-hud #oasisExit,.oasis-hud #oasisFullscreen{display:grid;place-items:center;width:clamp(44px,4.2vw,54px);height:clamp(44px,4.2vw,54px);padding:10px;border-radius:50%;background:radial-gradient(circle at 35% 20%,#154d40,#012e2a);border:2px solid #ddbd72;box-shadow:inset 0 0 0 2px #062721,0 2px 5px #1d241e88;color:#f6db8a}
.oasis-hud button svg{width:100%;height:100%;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}
.oasis-minimap{position:absolute;right:max(18px,env(safe-area-inset-right));top:clamp(75px,13.8vh,100px);border:3px solid #d9b870;border-radius:50%;box-shadow:inset 0 0 0 2px #21382a,0 3px 12px #1c291e77;background:#bca67d;overflow:hidden;pointer-events:none}
.oasis-map-label{display:none}.oasis-minimap canvas{display:block;width:clamp(96px,12vw,150px);height:clamp(96px,12vw,150px)}
#oasisNotice{position:absolute;top:108px;left:22px;max-width:38%;padding:6px 10px;background:#12251bba;border:1px solid #d5bc8666;border-radius:5px;color:#ffefbf;font:13px/1.4 Georgia,serif;pointer-events:none}#oasisNotice[hidden]{display:none}
#oasisStick{position:absolute;left:max(25px,env(safe-area-inset-left));bottom:max(25px,env(safe-area-inset-bottom));width:clamp(112px,14vw,180px);height:clamp(112px,14vw,180px);border:2px solid #d9ba6b;border-radius:50%;background:radial-gradient(circle,#152d2544,#102b2366);box-shadow:inset 0 0 25px #2a2a1c44,0 2px 8px #211f1455;display:grid;place-items:center;touch-action:none;user-select:none}
#oasisStick span{position:relative;z-index:1;width:41%;height:41%;border:2px solid #f2d27c;border-radius:50%;background:radial-gradient(ellipse at 30% 15%,#8ce0be 0%,#268d76 13%,#026454 36%,#00382f 80%);box-shadow:inset 0 0 0 3px #022d2580,inset 0 -6px 9px #052a2780,0 3px 9px #111d17aa;pointer-events:none}
#oasisStick i{position:absolute;width:10px;height:10px;border-top:3px solid #f8e2a766;border-left:3px solid #f8e2a766;pointer-events:none}#oasisStick i:nth-of-type(1){top:12%;transform:rotate(45deg)}#oasisStick i:nth-of-type(2){right:12%;transform:rotate(135deg)}#oasisStick i:nth-of-type(3){bottom:12%;transform:rotate(225deg)}#oasisStick i:nth-of-type(4){left:12%;transform:rotate(-45deg)}
.oasis-actions{position:absolute;right:max(28px,env(safe-area-inset-right));bottom:max(27px,env(safe-area-inset-bottom));display:flex;align-items:center;gap:clamp(17px,2.3vw,31px)}
.oasis-actions button{display:flex;flex-direction:column;justify-content:center;align-items:center;border-radius:50%;background:radial-gradient(ellipse at 35% 20%,#0c5545,#002f28 80%);box-shadow:inset 0 0 0 4px #073b31,inset 0 0 0 5px #e3c97c55,0 0 0 2px #1d3324,0 4px 10px #29241a88}
.oasis-actions #oasisInteract{width:clamp(88px,11vw,140px);height:clamp(88px,11vw,140px)}
.oasis-actions #oasisSprint{width:clamp(62px,7.2vw,92px);height:clamp(62px,7.2vw,92px);margin-top:-13px}
.oasis-actions svg{display:block;width:36%;height:36%;margin:0 auto 5px;fill:none;stroke:currentColor;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
.oasis-actions #oasisSprint svg{fill:#f3da92;stroke:none}.oasis-actions small{font:400 clamp(13px,1.65vw,21px)/1.1 Georgia,serif;text-shadow:0 1px #001c17}.oasis-actions #oasisSprint small{font-size:clamp(11px,1.2vw,16px)}
.oasis-actions #oasisInteract:after{content:'◇—◇';font-size:13px;line-height:1;color:#b69a58;margin-top:5px}.oasis-actions #oasisInteract.ready{border-color:#fff2ad;box-shadow:inset 0 0 0 4px #073b31,inset 0 0 0 5px #e3c97c88,0 0 14px #f5d48588}.oasis-actions button:disabled{opacity:.6}
#oasisEnd{position:absolute;inset:20% 20%;padding:24px;text-align:center;border:2px solid #dab773;border-radius:18px;background:#172e24f5;box-shadow:0 15px 50px #1b211aaa;z-index:8}#oasisEnd[hidden]{display:none}#oasisEnd h2{color:#ffdf94}#oasisEnd button{border-radius:8px;padding:10px 20px}
@media(max-height:350px){.oasis-route{width:205px;padding:5px 9px}.oasis-route>span{font-size:13px;gap:7px}.oasis-route>span svg{height:20px;width:20px}.oasis-route progress{height:8px;margin:4px 0 5px}.oasis-hud #oasisMission{font-size:11px}.oasis-minimap{top:68px}.oasis-minimap canvas{width:78px;height:78px}.oasis-hud-right{gap:8px}.oasis-task-badge{width:118px}#oasisStick{width:94px;height:94px;bottom:17px}.oasis-actions{bottom:19px;right:20px;gap:17px}.oasis-actions #oasisInteract{width:78px;height:78px}.oasis-actions #oasisSprint{width:60px;height:60px}#oasisNotice{top:88px;font-size:11px}}
@media(orientation:portrait){.oasis-hud{inset:12px!important;gap:6px!important}.oasis-route{width:170px;padding:5px}.oasis-route>span{font-size:10px;gap:4px}.oasis-route>span svg{width:15px;height:20px}.oasis-hud #oasisMission{font-size:10px}.oasis-hud-right{gap:4px}.oasis-task-badge{width:70px}.oasis-task-badge>span{flex-direction:column;gap:3px}.oasis-task-badge small,.oasis-task-badge b{font-size:9px}.oasis-hud #oasisExit,.oasis-hud #oasisFullscreen{padding:9px}.oasis-minimap{top:100px}#oasisNotice{top:110px}}
