/* 30.11.2026: самостоятельная Игротека и яркая связь с текущим жителем. */
.arcade-page{max-width:1080px;margin:0 auto;padding-bottom:96px}.arcade-title{display:flex;align-items:center;gap:18px;margin:14px 0 18px}.arcade-title-art{display:grid;place-items:center;flex:0 0 82px;height:82px;border-radius:26px;background:#fff1ad;box-shadow:0 9px 0 #e8c85e;font-size:43px}.arcade-title h1{margin:0 0 6px}.arcade-title p{max-width:720px;margin:0;color:#4f5360;font-size:17px}.arcade-title.compact{margin:10px 0 14px}.arcade-title.compact .hero{flex:0 0 auto}.arcade-context{margin:12px 0 20px}.arcade-context.compact{margin:8px 0 14px}.arcade-subjects{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.arcade-subject{display:grid;grid-template-columns:72px minmax(0,1fr) auto;align-items:center;gap:14px;min-height:112px;padding:16px;color:#302c3a;text-decoration:none;border:2px solid #ffffffd9;background:linear-gradient(145deg,#fffdf7,#f3f8e9);box-shadow:0 10px 24px #354c3514;transition:transform .18s ease,box-shadow .18s ease}.arcade-subject:hover,.arcade-subject:focus-visible{transform:translateY(-3px);box-shadow:0 14px 28px #354c3524;outline:4px solid #d8c8f1}.arcade-subject .hero{width:72px;height:72px;margin:0}.arcade-subject .hero img{width:100%;height:100%;object-fit:contain}.arcade-subject span{display:flex;flex-direction:column;gap:5px}.arcade-subject b{font-size:21px}.arcade-subject small{color:#535c54;font-size:13px;line-height:1.35}.arcade-subject strong{color:#17674e;white-space:nowrap}.arcade-rule{display:flex;flex-direction:column;gap:5px;margin-top:16px;padding:17px 20px;background:#fff5cf;color:#413b2c}.arcade-rule span{font-size:14px}.arcade-controls{display:flex;align-items:flex-end;gap:12px;margin:16px 0;padding:16px;border-radius:20px;background:#f3edff}.arcade-controls label{display:flex;flex:1;flex-direction:column;gap:7px;color:#4d405f;font-weight:900}.arcade-controls select{width:100%;min-height:50px;padding:9px 40px 9px 13px;border:2px solid #b9a7d3;border-radius:13px;background:#fff;color:#332a41;font:inherit;font-size:16px;cursor:pointer}.arcade-controls select:focus{border-color:#7257b5;outline:4px solid #e8ddf8}.arcade-controls .btn{margin:0;white-space:nowrap}.arcade-topic-note{margin:0 0 14px;color:#4f5360;font-size:14px}.arcade-games .igro-play,.arcade-res-games .igro-play{min-width:0;min-height:170px}.arcade-games .igro-e>img,.arcade-res-games .igro-e>img,.igro-runname>img{display:block;width:58px;height:58px;max-width:100%;object-fit:contain}.arcade-games .igro-e>span,.arcade-res-games .igro-e>span{font-size:48px}.arcade-empty{grid-column:1/-1;padding:24px;text-align:center}.arcade-empty p{margin-bottom:0}.arcade-no-res{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:15px 18px}.arcade-result .arcade-context{text-align:left;width:100%;margin-top:18px}.arcade-got{color:#17674e;font-size:24px;font-weight:1000}.arcade-res-games{grid-template-columns:repeat(auto-fit,minmax(150px,240px));justify-content:center;gap:18px;margin:18px 0}.resident-play-head{display:grid;grid-template-columns:110px minmax(0,1fr) 110px;align-items:center;gap:20px;box-sizing:border-box;margin:8px 0 18px;padding:18px 22px;border:2px solid rgba(255,255,255,.85);border-radius:28px;background:linear-gradient(135deg,#fff8d9,#f2edff);box-shadow:0 12px 30px rgba(53,76,53,.12);overflow:hidden}.resident-play-head>img{display:block;width:110px;height:110px;max-width:100%;object-fit:contain;justify-self:center}.resident-play-head>div{min-width:0}.resident-play-head h1{margin:4px 0 6px;font-size:clamp(28px,4vw,42px);line-height:1.1}.resident-play-head p{margin:0;color:#4f5360;line-height:1.45}@media(max-width:700px){.resident-play-head{grid-template-columns:64px minmax(0,1fr) 64px;gap:12px;padding:14px;border-radius:22px}.resident-play-head>img{width:64px;height:64px}.resident-play-head h1{font-size:clamp(24px,7vw,32px)}.resident-play-head p{font-size:14px}.arcade-res-games{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.arcade-res-games .igro-play{min-height:160px;padding:10px}}@media(max-width:390px){.resident-play-head{grid-template-columns:52px minmax(0,1fr) 52px;gap:10px;padding:12px}.resident-play-head>img{width:52px;height:52px}.resident-play-head .city-kicker{font-size:12px}}.arcade-all-topics{padding:20px}.arcade-all-topics p{margin:6px 0 14px}.arcade-all-topics .row{align-items:stretch}.arcade-run .run-head{margin-bottom:8px}.arcade-run .igro-runname{display:flex;align-items:center;gap:10px}.arcade-run .igro-runname>img{width:42px;height:42px}.city-shortcuts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:18px}.city-shortcut{display:grid;grid-template-columns:54px minmax(0,1fr) auto;align-items:center;gap:12px;min-height:88px;padding:15px 17px;color:#332f3d;text-decoration:none;border:2px solid #ffffffe0;background:linear-gradient(135deg,#fff7c9,#fff);box-shadow:0 10px 24px #354c3514;transition:transform .18s ease}.city-shortcut:hover,.city-shortcut:focus-visible{transform:translateY(-2px);outline:4px solid #d8c8f1}.city-shortcut>span:first-child{font-size:39px;text-align:center}.city-shortcut>span:nth-child(2){display:flex;flex-direction:column;gap:4px}.city-shortcut b{font-size:20px}.city-shortcut small{color:#555b53}.city-shortcut strong{color:#17674e}.city-shortcut-camp{background:linear-gradient(135deg,#e2f3d2,#fff)}
@media(max-width:700px){.arcade-subjects{grid-template-columns:1fr}.arcade-controls{align-items:stretch;flex-direction:column}.arcade-controls .btn{width:100%}.city-shortcuts{grid-template-columns:1fr}.arcade-title{align-items:flex-start}.arcade-title-art{flex-basis:64px;height:64px;border-radius:20px;font-size:34px}.arcade-title p{font-size:15px}.arcade-subject{grid-template-columns:62px minmax(0,1fr)}.arcade-subject .hero{width:62px;height:62px}.arcade-subject strong{grid-column:2}.arcade-no-res{align-items:flex-start;flex-direction:column}}
@media(max-width:390px){.arcade-page{padding-left:10px;padding-right:10px}.arcade-title{gap:11px}.arcade-title h1{font-size:30px}.arcade-subject{padding:13px}.arcade-games{grid-template-columns:repeat(2,minmax(0,1fr))!important}.arcade-games .igro-play{min-width:0;min-height:154px;padding:10px}.city-shortcut{grid-template-columns:46px minmax(0,1fr)}.city-shortcut strong{grid-column:2}.arcade-all-topics .btn{width:100%}}
@media(prefers-reduced-motion:reduce){.arcade-subject,.city-shortcut{transition:none}.arcade-subject:hover,.city-shortcut:hover{transform:none}}

/* 30.11.2026: единая колонка и узнаваемая сцена текущего жителя внутри каждой игры. */
.arcade-run.city-lesson-active,.arcade-result-page.city-lesson-active{
  --city-game-bg:url('../img/scenes/kuku-stage-grove.jpg');
  box-sizing:border-box;
  padding:18px 22px 30px;
  border:1px solid rgba(255,255,255,.82);
  border-radius:32px;
  background-image:linear-gradient(115deg,rgba(239,248,255,.68),rgba(255,250,229,.48)),var(--city-game-bg);
  background-repeat:no-repeat;
  background-position:center;
  background-size:cover;
  box-shadow:0 20px 50px rgba(27,65,62,.18),inset 0 1px 0 rgba(255,255,255,.6);
}
.city-lesson-active[data-city-resident="squirrel"]{--city-game-bg:url('../img/scenes/kuku-stage-pizza.jpg')}
.city-lesson-active[data-city-resident="bat"]{--city-game-bg:url('../img/scenes/kuku-stage-cave.jpg')}
.city-lesson-active[data-city-resident="suslik"]{--city-game-bg:url('../img/scenes/kuku-stage-harvest.jpg')}
.city-lesson-active[data-city-resident="morzh"]{--city-game-bg:url('../img/scenes/forest-winter.jpg')}
.city-lesson-active[data-city-resident="yashcherka"]{--city-game-bg:url('../img/scenes/map-mountain.jpg')}
.city-lesson-active[data-city-resident="nerpa"]{--city-game-bg:url('../img/scenes/kuku-stage-pond.jpg')}
.city-lesson-active[data-city-resident="pchela"]{--city-game-bg:url('../img/scenes/kuku-stage-meadow.jpg')}
.city-lesson-active[data-city-resident="vydra"]{--city-game-bg:url('../img/scenes/map-river.jpg')}
.city-lesson-active[data-city-resident="chayka"]{--city-game-bg:url('../img/scenes/kuku-stage-treasure.jpg')}
.arcade-run>.run-head{width:min(100%,760px);max-width:none;margin:6px auto 8px}
.arcade-run .city-run-context.arcade-context.compact{width:min(100%,760px);margin:8px auto 14px}
.arcade-run #arcadeQuiz{width:min(100%,760px);margin:0 auto}
.arcade-run #arcadeQuiz .quiz{width:100%;margin:0 auto}
.arcade-result-page>.arcade-result{width:min(100%,760px);margin:0 auto}
.arcade-result-page .arcade-result .arcade-context.compact{width:100%;margin:18px auto 14px}
@media(max-width:700px){
  .arcade-run.city-lesson-active,.arcade-result-page.city-lesson-active{padding:12px 10px 22px;border-radius:24px}
  .arcade-run>.run-head{margin-top:2px}
}

/* Название игры может переноситься; звук и выход сохраняют зону нажатия 44 px. */
.arcade-run>.run-head>.igro-runname{flex:1;min-width:0;line-height:1.25;overflow-wrap:anywhere}
.arcade-run>.run-head .btn,.arcade-run>.run-head .sndbtn{flex:0 0 auto;min-width:44px;min-height:44px}
@media(max-width:380px){.arcade-run>.run-head>.igro-runname{gap:6px;font-size:14px}.arcade-run .igro-runname>img{flex:0 0 34px;width:34px;height:34px}.arcade-run>.run-head #arcadeExit{padding-left:8px;padding-right:8px}}
