/* Approved clean strip layout - independent buttons, no image hotspots */
:root{--appInk:#163671;--appOrange:#ff8c2b}
#app{max-width:1050px}
body:has(#parkurView.active){background:#f3faff}
body:has(#parkurView.active) .topbar{display:flex;position:relative;top:auto;min-height:64px;border-radius:20px}
.papi-brand{width:52px;height:45px;object-fit:contain;object-position:50% 50%}
.brand-text{font-size:clamp(18px,2.6vw,27px);white-space:nowrap}
.brand-text span{font-weight:850}
.brand-text strong{color:#157cdb}
#parkurView{display:none}
#parkurView.active{display:flex;flex-direction:column;gap:10px}
.mobile-parkur-title{flex:0 0 auto;min-height:88px;display:flex;align-items:center;justify-content:space-between;gap:10px;background:linear-gradient(115deg,#fffaf2,#fffefa);border-radius:22px;border:1px solid #f6e5d0;padding:10px 16px;box-shadow:0 5px 16px #526b8e16}
.mobile-parkur-title span{font-size:clamp(20px,3.2vw,32px);font-weight:900;color:var(--appInk)}
.mobile-parkur-title h1{margin:3px 0 0;color:#ed6a2c;font-size:clamp(16px,2.6vw,25px);line-height:1.1}
.mobile-parkur-title img{width:180px;max-height:77px;object-fit:contain}
#parkurView .adventure-map{flex:1;min-height:0;display:grid;grid-template-columns:1fr;grid-template-rows:repeat(6,minmax(0,1fr));gap:8px;overflow:hidden}
.mobile-region{--tone:#ff8b63;--bg:#fff0e7;position:relative;min-height:0;display:flex;align-items:center;gap:16px;overflow:hidden;border:1px solid #fff;border-radius:18px;padding:6px 15px;background:var(--bg);isolation:isolate}
.mobile-region.zone-2{--tone:#44bb92;--bg:#e9faf1}.mobile-region.zone-3{--tone:#f6b931;--bg:#fff6d9}.mobile-region.zone-4{--tone:#439bff;--bg:#e8f5ff}.mobile-region.zone-5{--tone:#b16ce8;--bg:#f6eaff}.mobile-region.zone-6{--tone:#fa6a88;--bg:#ffeaf0}
.mobile-region-label{position:relative;z-index:1;flex:0 0 33%;display:flex;align-items:center;gap:11px;min-width:0}
.region-index{flex:none;display:grid;place-items:center;padding:6px;border-radius:14px;background:var(--tone);color:white;font-size:14px;font-weight:900;min-width:60px;min-height:42px;text-align:center}
.mobile-region-label h2{color:var(--appInk);font-size:clamp(15px,2.3vw,23px);line-height:1.12;margin:0;overflow-wrap:anywhere}
.region-art{position:absolute;inset:auto 0 0 auto;height:100%;width:33%;object-fit:contain;object-position:right bottom;pointer-events:none;opacity:.96;z-index:0}
.mobile-region-nodes{display:flex;gap:clamp(4px,.9vw,12px);position:relative;z-index:2;flex:1;align-items:center;justify-content:flex-start;margin-right:15%}
.mobile-node{width:clamp(34px,4.5vw,52px);height:clamp(34px,4.5vw,52px);min-width:34px;min-height:34px;border:3px solid white;border-radius:50%;display:grid;place-items:center;background:#e7edf4;color:#46546d;font-weight:900;font-size:clamp(14px,2.3vw,20px);box-shadow:0 3px 0 #aabbd0,0 3px 9px #26446b21;position:relative;flex-shrink:0}
.mobile-node:not(:last-child):after{content:'';position:absolute;left:calc(100% + 3px);top:50%;height:3px;width:clamp(4px,.9vw,12px);background:#b4bbc8;pointer-events:none}
.mobile-node.available{background:#287eff;color:white;cursor:pointer;box-shadow:0 3px 0 #1356a1,0 0 0 2px #b2d6ff}
.mobile-node.complete{background:#31b876;color:white;cursor:pointer}.mobile-node.locked{cursor:not-allowed;opacity:.82}
.mobile-node:focus-visible{outline:3px solid #153de4;outline-offset:3px}
#parkurView .adventure-footer{flex:0 0 auto;margin:0;padding:9px 13px;background:white;min-height:50px;border:1px solid #e1edfa;box-shadow:0 2px 10px #24447114}
#parkurView .adventure-footer button{min-height:36px}
#parkurView .adventure-continue{min-height:36px;padding:7px 15px;box-shadow:none;background:linear-gradient(180deg,#ffae40,#fb7724)}
#parkurView .map-help{display:none}
/* On phones, the whole parkour (header, six regions, footer) fits viewport. */
@media(max-width:700px){
html,body{overflow-x:hidden}body:has(#parkurView.active){overflow:hidden}
#app:has(#parkurView.active){height:100dvh;min-height:0;display:flex;flex-direction:column;padding:5px 7px;max-width:none}
#app:has(#parkurView.active) .topbar{flex:0 0 auto;min-height:49px;padding:4px 7px;gap:4px;border-radius:13px;flex-wrap:nowrap}
#app:has(#parkurView.active) main{min-height:0;flex:1;display:flex;flex-direction:column}
#parkurView.active{height:100%;min-height:0;gap:5px}
.papi-brand{width:29px;height:31px}.brand{gap:3px}.brand-text{font-size:14px;line-height:1.02;white-space:normal;max-width:98px}
.tabs{order:0!important;width:auto!important;gap:2px;flex:1;justify-content:flex-end}
.tab{font-size:10px!important;padding:7px 5px!important;border-radius:9px!important;min-height:30px}
.topbar-right{display:none}
.mobile-parkur-title{min-height:58px;padding:5px 10px;border-radius:12px}.mobile-parkur-title span{font-size:17px}.mobile-parkur-title h1{font-size:14px}.mobile-parkur-title img{width:104px;max-height:53px}
#parkurView .adventure-map{gap:4px}
.mobile-region{border-radius:12px;padding:4px 7px;gap:5px}
.mobile-region-label{flex:0 0 33%;display:block}.region-index{display:none}.mobile-region-label h2{font-size:clamp(11px,3.2vw,15px);line-height:1.09}
.mobile-region-label h2:before{content:attr(data-zone);display:block}
.mobile-region-nodes{margin-right:0;justify-content:flex-start;gap:3px}
.mobile-node{width:clamp(29px,8vw,38px);height:clamp(29px,8vw,38px);min-width:29px;min-height:29px;border-width:2px;font-size:clamp(12px,3.4vw,16px)}
.mobile-node:not(:last-child):after{width:3px;left:calc(100% + 1px)}
.region-art{width:30%;opacity:.63}
#parkurView .adventure-footer{min-height:43px;padding:5px 7px;gap:5px;font-size:11px;border-radius:12px}
#parkurView .adventure-footer button{min-height:32px;font-size:11px;padding:5px 8px;border-radius:9px}
#parkurView .adventure-continue{font-size:11px;padding:5px 8px}
}
@media(max-width:375px){.brand-text{font-size:12px;max-width:80px}.mobile-region-label{flex-basis:32%}.region-art{width:28%}.mobile-node{width:28px;height:28px;min-width:28px;min-height:28px}.tab{font-size:9px!important}}
@media(max-height:590px) and (max-width:700px){.mobile-parkur-title{min-height:42px}.mobile-parkur-title img{max-height:34px}.mobile-parkur-title span{font-size:15px}#app:has(#parkurView.active) .topbar{min-height:43px}.mobile-node{width:28px;height:28px;min-height:28px;min-width:28px}}
@media(min-width:701px){#app:has(#parkurView.active){max-width:1050px}#parkurView .adventure-map{min-height:670px}.mobile-region{min-height:95px}}
@media(prefers-reduced-motion:reduce){.mobile-node{transition:none}}
/* Unified desktop/mobile parkour; keep every footer action inside viewport. */
#app:has(#parkurView.active){max-width:980px;width:100%;margin-inline:auto;min-width:0}
#app:has(#parkurView.active) main,#parkurView.active,#parkurView .adventure-map{min-width:0}
#parkurView .adventure-footer{width:100%;max-width:100%;box-sizing:border-box;display:grid!important;grid-template-columns:minmax(0,1fr) auto auto!important;align-items:center;gap:clamp(3px,1vw,12px);overflow:hidden}
#parkurView .adventure-footer >span{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#parkurView .adventure-footer >button{min-width:0;box-sizing:border-box;max-width:100%;white-space:nowrap;display:flex;justify-content:center;align-items:center}
#parkurView .adventure-continue{margin:0}
@media(min-width:701px){
 #app:has(#parkurView.active){max-width:980px}
 #parkurView .adventure-map{grid-template-columns:minmax(0,1fr);grid-template-rows:repeat(6,minmax(0,1fr));min-height:600px;height:min(70vh,760px);gap:9px}
 #parkurView .mobile-region{min-height:0;padding:8px 16px}
 #parkurView .mobile-region-label{flex-basis:34%}
 #parkurView .mobile-region-nodes{margin-right:9%;justify-content:flex-start}
 #parkurView .region-art{width:28%}
}
@media(max-width:700px){
 #app:has(#parkurView.active){max-width:100vw;width:100%;overflow:hidden}
 #parkurView.active{min-width:0;overflow:hidden}
 #parkurView .adventure-map{min-height:0!important}
 #parkurView .adventure-footer{min-height:43px!important;gap:3px!important;padding:5px!important}
 #parkurView .adventure-footer >button{padding:5px clamp(4px,1.4vw,8px)!important;font-size:clamp(10px,2.6vw,12px)!important;min-height:32px!important}
 #parkurView .adventure-footer >span{font-size:clamp(10px,2.8vw,12px)}
}
@media(max-width:360px){
 #parkurView .adventure-footer >button{font-size:10px!important;padding:5px 4px!important}
 #parkurView .mobile-region-label{flex-basis:31%}
 #parkurView .mobile-node{width:27px;height:27px;min-width:27px;min-height:27px}
}
/* Mobile question screen: one question and all controls within one viewport. */
@media(max-width:700px){
 body:has(.modal-backdrop.quiz-screen){overflow:hidden}
 .modal-backdrop.quiz-screen{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;padding:5px;overflow:hidden;height:100dvh;max-height:100dvh}
 .quiz-screen .modal-card{width:100%;height:calc(100dvh - 10px);max-height:calc(100dvh - 10px);margin:0;overflow:hidden;display:flex;flex-direction:column;min-height:0;border:2px solid #dbe8fa}
 .quiz-screen .quiz-layout{height:100%;min-height:0;display:flex;flex-direction:column;gap:4px;padding:7px}
 .quiz-screen .quiz-top{flex:0 0 auto;gap:4px;padding:0;justify-content:space-between}
 .quiz-screen .quiz-top .crumbs{flex:1;min-width:0;overflow:hidden;white-space:nowrap;flex-wrap:nowrap}
 .quiz-screen .quiz-top .crumbs>.crumb-pill:not(:last-child),.quiz-screen .quiz-top .crumbs>span:not(.crumb-pill){display:none}
 .quiz-screen .quiz-top .crumbs>.crumb-pill:last-child{min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 .quiz-screen .quiz-top .back-btn{width:36px;height:36px;font-size:21px}
 .quiz-screen .progress-nodes{gap:3px;flex:none}
 .quiz-screen .pnode{width:24px;height:24px;font-size:11px}
 .quiz-screen .timer,.quiz-screen .timer-pill{display:none}
 .quiz-screen .quiz-card{display:flex;flex-direction:column;flex:1;min-height:0;padding:9px;border-radius:14px;overflow:hidden}
 .quiz-screen .q-card-left{height:100%;min-height:0;display:flex;flex-direction:column;gap:5px;overflow:hidden}
 .quiz-screen .q-card-left h3{font-size:17px;line-height:1.15;margin:0;flex:0 0 auto}
 .quiz-screen .skill-badge{padding:3px 6px;font-size:10px}
 .quiz-screen .question-title{font-size:clamp(14px,3.7vw,17px);line-height:1.22;margin:0;flex:0 0 auto}
 .quiz-screen .options{display:grid;grid-template-columns:1fr;gap:5px;margin:0;flex:1 1 auto;min-height:0}
 .quiz-screen .option{padding:5px 9px;font-size:clamp(12px,3.3vw,15px);line-height:1.15;min-height:0;display:flex;align-items:center;border-radius:11px}
 .quiz-screen .option b{width:25px;height:25px;flex:none;font-size:12px}
 .quiz-screen .prompt-box,.quiz-screen .reading-box{font-size:clamp(12px,3.1vw,15px);line-height:1.25;padding:8px;flex:0 1 auto;min-height:0;overflow:hidden}
 .quiz-screen .prompt-box ul{margin:0;padding-left:19px}
 .quiz-screen .image-panel{height:clamp(90px,19dvh,160px);flex:0 1 auto;min-height:65px}
 .quiz-screen .order-list{display:grid;gap:4px;flex:1;min-height:0}
 .quiz-screen .order-item{padding:5px 7px;line-height:1.15;min-height:0;font-size:clamp(12px,3.2vw,15px);gap:6px}
 .quiz-screen .order-num{width:24px;height:24px;flex:none}
 .quiz-screen .order-actions button{height:30px;width:31px}
 .quiz-screen .text-box{display:flex;flex-direction:column;flex:1;min-height:0}
 .quiz-screen .text-box textarea{flex:1;min-height:70px;padding:10px;font-size:16px}
 .quiz-screen .text-meta{font-size:11px;margin-top:2px}
 .quiz-screen .q-side{display:none}
 .quiz-screen .q-actions{margin:0;gap:4px;flex:0 0 auto;display:flex;flex-direction:column}
 .quiz-screen .feedback-box{min-height:27px;padding:5px 8px;font-size:clamp(11px,2.9vw,13px);line-height:1.15}
 .quiz-screen .nav-btn{min-height:42px;padding:8px;font-size:15px}
}
@media(max-width:700px) and (max-height:650px){
 .quiz-screen .quiz-layout{padding:4px}
 .quiz-screen .quiz-card{padding:5px}
 .quiz-screen .q-card-left{gap:3px}
 .quiz-screen .image-panel{height:90px}
 .quiz-screen .q-card-left h3{font-size:15px}
 .quiz-screen .question-title{font-size:13px}
 .quiz-screen .option{font-size:12px;padding:3px 6px}
 .quiz-screen .feedback-box{min-height:22px;padding:3px 5px}
 .quiz-screen .nav-btn{min-height:37px;padding:5px}
}

/* Clear answer feedback, including accessible symbols (not color alone). */
.quiz-screen .option.correct,.option.correct{background:#daf7e3!important;border-color:#15984b!important;color:#13562f!important;box-shadow:inset 0 0 0 1px #15984b}
.quiz-screen .option.wrong,.option.wrong{background:#ffdee0!important;border-color:#d72c40!important;color:#852332!important;box-shadow:inset 0 0 0 1px #d72c40}
.answer-mark{margin-left:auto;font-size:20px;font-weight:900}
.option.correct .answer-mark{color:#138a40}.option.wrong .answer-mark{color:#cc2639}
.feedback-correct{background:#ddf6e5!important;color:#13673a!important;border:1px solid #33a95c}
.feedback-wrong{background:#ffe4e6!important;color:#9c2432!important;border:1px solid #e3606c}
