/* Mobile app shell. Desktop galleries and puzzle coordinates are unchanged. */
.mobileOnly,.mobileTabs,.mobilePager{display:none}
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 html,body{height:100%;overflow:hidden;overscroll-behavior:none}
 .app{height:100vh;height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden}
 .topbar{backdrop-filter:none;height:calc(56px + env(safe-area-inset-top));padding:env(safe-area-inset-top) max(12px,env(safe-area-inset-right)) 0 max(12px,env(safe-area-inset-left));gap:8px;flex:none}
 .brand{min-width:0}.brandName{font-size:25px}.brandTag{display:none}.brandIcon{width:32px;height:32px}
 .topActions{min-width:0}.topActions .iconBtn{width:44px;height:44px}.accountBtn{height:44px;font-size:0;padding:8px;max-width:110px;color:#553080;background:#eadcf7;border-color:#d9c5ee}.accountBtn:after{font-size:12px}
 .topbar .nav{position:fixed;left:0;right:0;bottom:0;height:calc(66px + env(safe-area-inset-bottom));padding:5px max(12px,env(safe-area-inset-right)) max(5px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));display:flex;gap:8px;background:#fff8f2f5;border-top:1px solid #dfcee8;box-shadow:0 -5px 25px #74519812;backdrop-filter:blur(14px)}
 .navBtn{flex:1;min-height:48px;font-size:14px;font-weight:900;border-radius:17px;padding:8px}.navBtn.active{background:#eadcf7;border-color:#d9c5ee;color:#553080}
 .app>main{flex:1;min-height:0;margin-bottom:calc(66px + env(safe-area-inset-bottom));overflow:hidden}
 .screen.active{height:100%;min-height:0;overflow:hidden}
 .galleryWrap,.shopWrap{height:100%;min-height:0;max-width:none;padding:10px max(12px,env(safe-area-inset-right)) 8px max(12px,env(safe-area-inset-left));display:flex;flex-direction:column;gap:8px}
 .galleryHeading{flex:none;margin:0;gap:8px}.galleryHeading h1{font-size:24px;line-height:1.12;margin:4px 0}.galleryHeading p,.galleryHeading .eyebrow{display:none}
 .mobileOnly{display:block}.mobileTabs{display:flex;flex:none;gap:8px;padding:4px;border-radius:18px;background:#eadff1}.mobileTabs button{flex:1;min-height:44px;font-size:13px;padding:7px}.mobileTabs button[aria-pressed=true]{background:#fffaf6;border-color:#d9c6e9;color:#553080;box-shadow:0 2px 0 #cdb8da}
 .mobilePager{display:flex;align-items:center;justify-content:center;gap:16px;flex:none;min-height:46px}.mobilePager button{height:44px;min-width:52px;padding:7px}.mobilePager button:disabled{opacity:.35;cursor:default}.mobilePager span{min-width:70px;text-align:center;font-size:13px;font-weight:800;color:#5f4876}
 /* Native horizontal paging: controls also support keyboard and reduced motion. */
 #libraryGrid,#shopItems,#paidPackItems{display:grid;grid-template-rows:minmax(0,1fr);grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:100%;gap:0;flex:1;min-height:0;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x mandatory;scrollbar-width:none;overscroll-behavior-x:contain;border-radius:20px}
 #libraryGrid::-webkit-scrollbar,#shopItems::-webkit-scrollbar,#paidPackItems::-webkit-scrollbar{display:none}
 #libraryGrid>.motifCard,#shopItems>.shopCard,#paidPackItems>.paidPackCard{scroll-snap-align:start;scroll-snap-stop:always;min-width:0;margin:0;max-height:100%;height:100%}
 .libraryFilters{margin:0;flex:none;align-items:center;gap:7px}.libraryFilters label{display:flex;align-items:center;gap:7px;font-size:12px}.libraryFilters select{min-height:44px;max-width:160px;margin:0;padding:6px;font-size:13px}.libraryFilters>span{padding:0;font-size:11px}
 #libraryGrid>.motifCard{display:flex;flex-direction:column;border-width:3px}
 #libraryGrid .motifCard img{flex:1;min-height:0;height:0;aspect-ratio:auto;object-fit:contain;background:#efe5f3}
 #libraryGrid .motifCaption{flex:none;padding:10px;display:flex;gap:8px}#libraryGrid .motifCaption strong{font-size:19px}#libraryGrid .motifCaption small{font-size:11px;margin-top:3px}#libraryGrid .motifStatus{font-size:11px;max-width:95px}
 #screen-home .libraryFilters,#screen-home #motifGrid,#screen-home .previousMotifs{display:none}
 #screen-home .playerStrip{flex:none;display:flex;flex-wrap:wrap;align-items:center;margin:0;padding:10px;gap:7px;border-radius:18px}
 #screen-home .playerIdentity{flex:1;min-width:0;gap:3px}#screen-home .playerIdentity strong{font-size:16px;overflow-wrap:anywhere}#screen-home .eyebrow{font-size:9px}
 #screen-home .playerStrip>.softBtn{min-height:44px;padding:8px;font-size:12px}
 #screen-home #featuredDaily{flex-basis:100%;width:100%;min-height:48px;margin:0;padding:5px 10px}#featuredDaily img{width:50px;height:34px}
 #screen-home #playerStatus{flex-basis:100%;font-size:11px;margin:0;max-height:44px;overflow:auto}#playerStatus:empty{display:none}
 #screen-home .continuePanel{flex:none;margin:0;padding:10px;gap:12px;border-radius:18px}
 #screen-home .continuePanel img{width:85px;max-height:88px}#screen-home .continuePanel h2{font-size:18px;margin:3px 0}#screen-home .continuePanel p{font-size:11px;margin:4px 0}#screen-home .continuePanel .primaryBtn{padding:8px 12px;min-height:44px;font-size:12px}
 #screen-home .softPopHero{flex:1;min-height:0;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:minmax(0,1fr) auto;align-items:center;margin:0;padding:12px;gap:3px;overflow:hidden;border-radius:20px}
 #screen-home .softPopHero h1{font-size:clamp(24px,7vw,34px)}#screen-home .softPopHero button{font-size:12px;padding:8px;min-height:44px;margin-top:7px}
 #screen-home .softPopHero>.softBtn{grid-column:1/-1;justify-self:start;margin:0}
 #screen-home .softPopMascot{width:100%;height:100%;min-height:0;max-height:220px;object-fit:contain;margin:0}
 #screen-library .personalLibrary{display:none}
 #screen-library .libraryHeroToken{display:none}#screen-library .libraryHero{flex:none}
 #screen-library[data-library-tab=personal]{display:flex;flex-direction:column}
 #screen-library[data-library-tab=personal]>.galleryWrap{height:auto;flex:none}
 #screen-library[data-library-tab=personal] .libraryFilters,#screen-library[data-library-tab=personal] #libraryGrid,#screen-library[data-library-tab=personal] .mobilePager{display:none}
 #screen-library[data-library-tab=personal] .personalLibrary{display:block;flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding:8px 12px;margin:0}
 .personalHeading{gap:8px;flex-wrap:wrap}.personalHeading h2{font-size:20px}.personalHeading p,#personalStorageStatus{font-size:12px}
 .shopHero{padding:12px;display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0;flex:none}.shopHero h1{font-size:23px;line-height:1.1;margin:0}.shopHero p,.shopHero .eyebrow{display:none}.shopBalance{font-size:13px;white-space:nowrap;padding:10px;margin:0}
 .shopStatus{flex:none;max-height:55px;overflow:auto;overscroll-behavior:contain;line-height:1.35;font-size:12px;margin:0;padding:5px 0}
 #shopItems>.shopCard,#paidPackItems>.paidPackCard{min-height:0;padding:14px;overflow:auto;overflow-x:hidden;overscroll-behavior:contain}
 .shopCard:after{top:0;right:0;height:100%;max-height:150px}
 .shopCard h2{font-size:24px;margin:5px 0}.shopDescription,.paidPackCard p{font-size:13px;line-height:1.4;margin:5px 0}.shopIllustration{height:clamp(72px,22dvh,180px);width:180px;margin:3px auto}
 .shopCardFoot{padding-top:8px}.shopCardActions{padding:5px 0 0;margin-top:7px}.shopCardActions button,.paidPackCard .primaryBtn{min-height:44px;font-size:13px}
 #screen-shop[data-shop-tab=cosmetics] #paidPacks,#screen-shop[data-shop-tab=packs] #shopItems,#screen-shop[data-shop-tab=packs] #shopItems+.mobilePager{display:none}
 #screen-shop[data-shop-tab=packs] #paidPacks:not([hidden]){display:flex;flex:1;min-height:0;flex-direction:column;margin:0;gap:0}#paidPacks>div:first-child{display:none}
 body.playing .app>main{margin-bottom:0}body.playing .screen.active{height:100dvh}
 /* Forms, long descriptions and reward lists scroll inside their panel, never the page. */
 dialog,.modal{max-width:calc(100vw - 20px - env(safe-area-inset-left) - env(safe-area-inset-right));max-height:calc(100dvh - 20px - env(safe-area-inset-top) - env(safe-area-inset-bottom));overscroll-behavior:contain}
 #motifDialog[open]{display:flex;flex-direction:column;overflow:hidden}#motifDialog .motifPreview{flex:none;min-height:0;height:clamp(110px,25dvh,220px)}#motifDialog .motifPreview img{height:100%;object-fit:contain}
 #motifDialog .motifInfo{align-self:stretch;overflow:auto;min-height:0;padding:12px 18px;overscroll-behavior:contain}#motifDialog h2{font-size:25px;margin:4px 0}#motifDialog .pieceCountLabel{margin:10px 0 5px}#motifDialog p{font-size:12px;margin:6px 0}#motifDialog .primaryBtn{min-height:44px}
 .completeWrap{height:100%;min-height:0;display:block;overflow:auto;overscroll-behavior:contain;padding:10px}.completeImage{height:22dvh}.completeBody{padding:16px}.completeBody h1{font-size:28px}.completeActions{position:sticky;bottom:0;background:#fffaf6;padding:10px 0 0}
 .installHelp{display:block;font-size:13px;line-height:1.5}.installHelp h4{font-size:15px}
}
@media(max-width:700px) and (max-height:650px){
 #screen-home .playerStrip{padding:7px}#screen-home .continuePanel{padding:7px}#screen-home .continuePanel .eyebrow{display:none}#screen-home .softPopHero h1{font-size:24px}#screen-home .softPopHero>.softBtn{grid-column:1/-1;justify-self:start;margin:0}
 #screen-home .softPopMascot{max-height:140px}
 .shopHero h1{font-size:19px}.galleryHeading h1{font-size:21px}
}
@media(max-width:700px) and (max-height:750px){
 #shopItems>.shopCard{display:grid;grid-template-columns:84px minmax(0,1fr);align-content:start;gap:5px 10px;padding:12px}
 .shopCardHead{grid-column:1/-1}.shopCard .shopIllustration{grid-column:1;grid-row:2/4;width:84px;height:88px;margin:0}
 .shopCard h2{grid-column:2;grid-row:2;font-size:20px;margin:0;align-self:end}.shopCard .shopDescription{grid-column:2;grid-row:3;font-size:12px;margin:0}
 .shopCardFoot{grid-column:1/-1;grid-row:4;padding-top:4px}.shopCardActions{grid-column:1/-1;grid-row:5;margin:0;padding:0}
 #paidPackItems>.paidPackCard{display:grid;grid-template-columns:84px minmax(0,1fr);align-content:start;gap:5px 10px;padding:12px}
 .paidPackCard>.shopType{grid-column:1/-1}.paidPackCard .shopIllustration{grid-column:1;grid-row:2/5;width:84px;height:90px;margin:0}.paidPackCard .packArtCaption{display:none}
 .paidPackCard h3{grid-column:2;grid-row:2;font-size:19px}.paidPackCard>p{grid-column:2;font-size:12px}.paidPackFoot{grid-column:1/-1;grid-row:5}
}
@media(max-height:500px) and (max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home .galleryWrap{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:auto minmax(0,1fr)}#screen-home .playerStrip{grid-column:1/-1}#screen-home #featuredDaily{flex-basis:auto;width:auto;flex:1}#screen-home .continuePanel{min-height:0}#screen-home .continuePanel img{width:58px}#screen-home .softPopHero{height:100%}#screen-home .continuePanel[hidden]+.softPopHero{grid-column:1/-1}
 #screen-library .galleryHeading{display:none}#screen-shop .shopHero{display:none}
 #screen-home .softPopHero>.softBtn{display:none}#screen-home .softPopHero h1{font-size:18px;margin:0}#screen-home .softPopHero .primaryBtn{margin-top:4px}
 #screen-shop .shopWrap{padding-top:4px;padding-bottom:4px;gap:3px}#screen-shop .shopStatus{font-size:10px;line-height:1.3;max-height:14px;padding:0}
 #screen-shop .mobilePager{min-height:44px}#screen-shop .mobilePager button{height:44px}
 #libraryGrid>.motifCard{flex-direction:row}#libraryGrid .motifCard img{width:50%;height:100%}#libraryGrid .motifCaption{width:50%;align-items:center}
 #shopItems>.shopCard,#paidPackItems>.paidPackCard{display:grid;grid-template-columns:64px minmax(0,1fr);align-content:start;gap:3px 10px;padding:6px}
 .shopCardHead,.shopCard .shopDescription,.paidPackCard>.shopType,.paidPackCard .packArtCaption,.paidPackCard>p{display:none}
 .shopCard .shopIllustration,.paidPackCard .shopIllustration{grid-column:1;grid-row:1/4;width:64px;height:78px;margin:0}
 .shopCard h2,.paidPackCard h3{grid-column:2;grid-row:1;font-size:18px;margin:0;align-self:start}.shopCardFoot{grid-column:2;grid-row:2;padding:0}.shopCardActions{grid-column:2;grid-row:3;padding:0;margin:0;flex-wrap:nowrap}.shopCardActions button{min-width:0;flex:1;padding:5px;font-size:12px}.paidPackFoot{grid-column:2;grid-row:2/4;margin:0}
 #motifDialog[open]{flex-direction:row}#motifDialog .motifPreview{width:45%;height:auto}#motifDialog .motifInfo{width:55%}
}
@media(display-mode:standalone){.installHelp{display:none}}

/* A2: the same dock and clear screen ownership on phones. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 .topbar .nav{z-index:90;left:max(8px,env(safe-area-inset-left));right:max(8px,env(safe-area-inset-right));bottom:0;gap:4px;height:calc(68px + env(safe-area-inset-bottom));padding:5px 5px max(5px,env(safe-area-inset-bottom));border:1px solid #fff;border-bottom:0;border-radius:20px 20px 0 0;background:#fff8f2f5;box-shadow:0 -7px 24px #54346d1b;backdrop-filter:none;transform:none}
 .navBtn{display:flex;flex:1;flex-direction:column;justify-content:center;align-items:center;gap:1px;min-width:0;min-height:48px;padding:3px 5px;border:1px solid transparent;border-radius:15px;font-size:10px;line-height:1.1}
 .navGlyph{width:22px;height:22px}
 .navBtn.active,.navBtn[aria-current=page]{background:#eaddf5;border-color:#d2bce9;color:#553080;box-shadow:inset 0 2px 0 #fff,0 2px 0 #bea4d4}
 .app>main{margin-bottom:calc(68px + env(safe-area-inset-bottom))}
 body.playing .app>main{margin-bottom:0}
}
@media(max-width:700px) and (max-height:500px), (max-height:500px) and (pointer:coarse){
 #screen-home .galleryWrap{grid-template-rows:auto auto;overflow-y:auto;overscroll-behavior:contain;align-content:start}
 #screen-home .playerStrip,#screen-home .continuePanel,#screen-home .softPopHero{min-height:0}
 #screen-home .softPopHero{height:auto;min-height:140px}
 .mobileJourney{max-height:calc(100dvh - 12px - env(safe-area-inset-top) - env(safe-area-inset-bottom))}
}

/* A3 lobby: only the next two actions stay visible on the home scene. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home .playerStrip{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;padding:9px 10px;gap:8px}
 #screen-home .playerIdentity{min-width:0}
 #screen-home .journeyLauncher{min-height:44px;padding:8px 10px;font-size:12px;white-space:nowrap}
 #screen-home .lobbyContinue{display:grid;grid-template-columns:92px minmax(0,1fr);margin:0;min-height:126px;border-radius:20px}
 #screen-home .lobbyContinue>img{min-height:126px;max-height:none}
 #screen-home .lobbyContinueCopy{padding:11px 12px;gap:3px}
 #screen-home .lobbyContinue .eyebrow{display:block;font-size:8px}
 #screen-home .lobbyContinue h2{font-size:20px;line-height:1.06}
 #screen-home .lobbyContinue p{font-size:11px;line-height:1.3}
 #screen-home .lobbyContinue .lobbyActions{gap:6px;margin-top:3px}
 #screen-home .lobbyContinue .lobbyActions .primaryBtn,#screen-home .lobbyContinue .lobbyActions .softBtn{min-height:38px;padding:6px 9px;font-size:11px}
 #screen-home .lobbyHero{display:grid;grid-template-columns:minmax(0,1fr) minmax(115px,.72fr);grid-template-rows:1fr;flex:1;min-height:0;margin:0;padding:16px;border-radius:22px;overflow:hidden}
 #screen-home .lobbyHero .lobbyIntro{align-content:center}
 #screen-home .lobbyHero .eyebrow{display:block;font-size:9px}
 #screen-home .lobbyHero h1{font-size:clamp(25px,7.8vw,36px);margin:7px 0}
 #screen-home .lobbyHero p{display:block;font-size:12px;line-height:1.4}
 #screen-home .lobbyHeroArt{min-height:0}
 #screen-home .lobbyHero .softPopMascot{width:140%;max-height:240px}
 #screen-home .lobbyHero .lobbyActions{gap:6px;margin-top:8px}
 #screen-home .lobbyHero .lobbyActions .primaryBtn,#screen-home .lobbyHero .lobbyActions .softBtn{min-height:40px;padding:7px 9px;font-size:11px}
 #screen-home[data-lobby-state="returning"] .lobbyHero{min-height:0;padding:14px}
 #screen-home[data-lobby-state="returning"] .lobbyHero h1{font-size:22px}
 #screen-home[data-lobby-state="returning"] .lobbyHero p{font-size:11px}
 #screen-home[data-lobby-state="returning"] .lobbyHeroArt{min-height:0}
 #screen-home[data-lobby-state="returning"] .lobbyHero .softPopMascot{width:120%;max-height:160px}
}
@media(max-width:700px) and (max-height:650px){
 #screen-home .lobbyContinue{grid-template-columns:72px minmax(0,1fr);min-height:96px}
 #screen-home .lobbyContinue>img{min-height:96px}
 #screen-home .lobbyContinueCopy{padding:7px 9px}
 #screen-home .lobbyContinue .eyebrow,#screen-home .lobbyContinue .softBtn{display:none}
 #screen-home .lobbyHero{min-height:145px;padding:11px}
 #screen-home .lobbyHero p{display:none}
 #screen-home .lobbyHero h1{font-size:23px}
 #screen-home .lobbyHero .softPopMascot{max-height:150px}
}

/* A5 — the table owns the viewport; controls live in a slim, stable dock. */
@media(max-width:700px){
 #screen-home .homeAlbum{margin-top:0;flex:none}.albumLaunch{min-height:78px;padding:10px 12px;gap:10px;border-radius:19px}.albumLaunchCopy strong{font-size:18px}.albumLaunchCopy .eyebrow{font-size:8px}.albumLaunchCopy small{font-size:11px}.albumMiniatures .albumSlot{width:38px;height:38px;border-width:2px}.albumMiniatures .albumCheck{font-size:9px;min-width:15px;height:15px;right:1px;bottom:1px}.albumArrow{font-size:22px}
 .albumDialog{padding:15px;border-radius:22px}.albumBook{padding:16px}.albumBook h3{font-size:27px}.albumPages{gap:7px;margin:15px 0}.albumPictureTitle{font-size:11px;padding:8px 2px}.albumPages .albumSlot{min-height:88px}.albumHeader h2{font-size:23px}
 .completeCard:has(.resultAlbum:not([hidden])) .completeImage{height:17dvh;min-height:125px}.completeCard:has(.resultAlbum:not([hidden])) .completeBody{padding:12px 16px}.completeCard:has(.resultAlbum:not([hidden])) .completeBody h1{font-size:26px}.completeCard:has(.resultAlbum:not([hidden])) .resultGrid{margin:9px 0}.completeCard:has(.resultAlbum:not([hidden])) .resultBox{padding:8px}.completeCard:has(.resultAlbum:not([hidden])) .rankResult{margin:8px 0}.completeCard:has(.resultAlbum:not([hidden])) .completionRewardArt{width:48px;height:48px}.completeCard:has(.resultAlbum:not([hidden])) .rankResult h3{margin:7px 0;font-size:20px}.completeCard:has(.resultAlbum:not([hidden])) .rankResult p{margin:7px 0;font-size:12px}.resultAlbum{padding:9px 10px;margin:9px 0}.albumResultPages{gap:6px}.albumResultPages .albumSlot{width:46px;height:38px;border-width:2px}.albumResultCount{font-size:12px}
}

/* Camera-bound tabletop environments. No extra animation loop or screen-space props. */
.stage{background:linear-gradient(145deg,#b9ad9d,#a39786)}
.stage:before,html[data-cosmetic-table="linen-morning"] .stage:before{display:none}
.stage:after{display:none}
.stage>.world{z-index:1}




/* Floating HUD: only the controls intercept pointers; the table keeps all its space. */
body.playing .app{width:100%;max-width:none;height:100vh;height:100dvh;margin:0;border-radius:0}
body.playing #screen-play.active{display:flex;flex-direction:column;height:100%;overflow:hidden;padding:0;scrollbar-gutter:auto}
body.playing .playShell{position:relative;display:flex;flex:1;flex-direction:column;width:100%;height:100%;min-height:0;max-width:none;padding:0}
body.playing .stage{flex:1;min-height:0;height:auto;width:100%;border-radius:0}
body.playing #screen-play .hud{--hud-top:max(12px,env(safe-area-inset-top));--hud-bottom:max(12px,env(safe-area-inset-bottom));--hud-left:max(12px,env(safe-area-inset-left));--hud-right:max(12px,env(safe-area-inset-right));position:absolute;z-index:85;inset:0;display:block;width:auto;max-width:none;min-height:0;margin:0;padding:0;border:0;border-radius:0;background:none;box-shadow:none;backdrop-filter:none;transform:none;pointer-events:none;transition:opacity .16s ease}
body.playing #screen-play .hud.start-hide,body.playing #screen-play .hud.completion-hide{opacity:0;transform:none;visibility:hidden}
body.playing #screen-play .hud.milestone{animation:none}
body.playing #screen-play.table-active .hud:not(.start-hide):not(.completion-hide){opacity:.62}
body.playing .hudNavigation,body.playing .hudActions,body.playing .zoomGroup{position:absolute;display:flex;align-items:center;gap:6px;padding:0;border:0;border-radius:0;background:none;overflow:visible}
.soundRecovery[hidden]{display:none!important}
body.playing .hudNavigation{top:var(--hud-top);left:var(--hud-left)}
body.playing .hudActions{left:var(--hud-left);bottom:var(--hud-bottom)}
body.playing .zoomGroup{right:var(--hud-right);bottom:var(--hud-bottom)}
body.playing .playStats{display:flex;gap:6px;max-width:none}
body.playing .hudBtn,body.playing .zoomGroup .hudBtn,.playBackBtn,.playPauseBtn{display:inline-flex;align-items:center;justify-content:center;gap:4px;flex:none;min-width:44px;min-height:44px;height:44px;padding:0 12px;border:1px solid #fff;border-radius:16px;background:linear-gradient(160deg,#fffdfaf0,#f0e7edf2);color:#4b3272;box-shadow:inset 0 2px 1px #fff,0 3px 7px #34213f40;font:900 12px/1 Nunito,sans-serif;white-space:nowrap;cursor:pointer}
body.playing .hudBtn,body.playing .playBackBtn,body.playing .playPauseBtn{pointer-events:auto;touch-action:manipulation}
body.playing .zoomGroup .hudBtn+.hudBtn{border-left:1px solid #fff}
body.playing .zoomGroup .hudBtn,.playBackBtn,.playPauseBtn{padding:0;font-size:24px}
body.playing .hudLabel{display:inline}
body.playing .hudBtn strong{margin:0;padding:3px 5px;line-height:1}
body.playing .pauseLabel{display:none}
.playBackBtn:focus-visible,.playPauseBtn:focus-visible,.playToolsBtn:focus-visible{outline:3px solid #f4c256;outline-offset:3px}
body.playing .playTools{position:absolute;right:var(--hud-right);top:var(--hud-top)}
body.playing .playToolsBtn{padding:0;font-size:26px}
.playToolsPanel[hidden]{display:none!important}
body.playing .playToolsPanel{position:absolute;z-index:90;right:0;top:calc(100% + 8px);bottom:auto;display:grid;gap:6px;width:min(310px,calc(100vw - 24px));min-width:0;max-height:calc(100dvh - var(--hud-top) - var(--hud-bottom) - 124px);overflow:auto;overscroll-behavior:contain;pointer-events:auto;padding:10px;border:1px solid #ddc9eb;border-radius:20px;background:#fff9f4;box-shadow:0 10px 28px #4c315544}
body.playing .playToolsPanel .hudBtn{justify-content:flex-start;width:100%;height:44px;min-height:44px;padding:0 12px;text-align:left}
body.playing .playToolsPanel .quietAction,body.playing #resetZoomBtn{display:inline-flex}
.playInfo{padding:5px;color:#5e3f7f}.playInfo>small{display:block;font:700 11px/1.35 Nunito,sans-serif}
.playInfo h2{margin:5px 0 10px;color:#533476;font:900 20px/1.2 Nunito,sans-serif}
.playInfoStats{display:flex;justify-content:space-between;gap:8px;margin-bottom:9px;font:700 12px Nunito,sans-serif;font-variant-numeric:tabular-nums}
body.playing .playProgress{position:static;display:flex;align-items:center;gap:8px;padding:0;color:#5e3f7f;font:900 11px Nunito,sans-serif}
.playProgress .progressBar{flex:1;height:6px;min-width:0;margin:0;border-radius:999px;background:#e1d4eb;border:0;overflow:hidden}
.playProgress .progressFill{height:100%;border-radius:inherit;background:linear-gradient(90deg,#a780e2,#7142b9)}
@media(max-width:350px){body.playing #screen-play .hud{--hud-left:max(8px,env(safe-area-inset-left));--hud-right:max(8px,env(safe-area-inset-right))}body.playing .hudActions .hudBtn{padding-inline:8px;font-size:11px}}
@media(prefers-reduced-motion:reduce){body.playing #screen-play .hud{transition:none}}
html.reduced-motion body.playing #screen-play .hud{transition:none}

/* Soft Arcade: static CSS depth, scoped to the floating play controls. */
body.playing #screen-play .hud{--hud-bottom:max(16px,env(safe-area-inset-bottom))}
body.playing #screen-play .hudNavigation,body.playing #screen-play .hudActions{gap:10px}
body.playing #screen-play .playStats{gap:0}
body.playing #screen-play .arcadeControl{
 --arcade-top:#fffdf7;--arcade-bottom:#f3e6d2;--arcade-edge:#c7a982;--arcade-rim:#fffaf0;--arcade-ink:#5a2b99;
 display:inline-flex;align-items:center;justify-content:center;gap:8px;min-width:52px;min-height:52px;height:52px;padding:0 16px;
 border:1px solid var(--arcade-rim);border-radius:19px;background:linear-gradient(var(--arcade-top),var(--arcade-bottom));color:var(--arcade-ink);
 box-shadow:inset 0 2px 1px #ffffff80,0 4px 0 var(--arcade-edge),0 7px 10px #34213f30;
 font:900 14px/1 Nunito,sans-serif;white-space:nowrap;cursor:pointer;touch-action:manipulation;pointer-events:auto;
 translate:0;transform:none;transition:translate 90ms ease,box-shadow 90ms ease
}
body.playing #screen-play #hudHome,body.playing #screen-play #hintBtn{
 --arcade-top:#a570ec;--arcade-bottom:#773bd0;--arcade-edge:#542597;--arcade-rim:#bd96ef;--arcade-ink:#fff
}
body.playing #screen-play #pausePuzzle{--arcade-top:#ff929a;--arcade-bottom:#f26375;--arcade-edge:#bf4358;--arcade-rim:#ffb4b7;--arcade-ink:#fff}
body.playing #screen-play #previewBtn{--arcade-top:#54cdb2;--arcade-bottom:#249a84;--arcade-edge:#1c705f;--arcade-rim:#8be3cc;--arcade-ink:#fff}
body.playing #screen-play #previewBtn.active{--arcade-top:#229c86;--arcade-bottom:#197b69;--arcade-edge:#135e51;translate:0 3px;box-shadow:inset 0 2px 3px #155e5140,0 1px 0 var(--arcade-edge),0 3px 5px #34213f30}
body.playing #screen-play #hudHome,body.playing #screen-play #pausePuzzle,body.playing #screen-play .playToolsBtn{width:52px;padding:0}
.hudIcon{display:block;flex:none;width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:2.6;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
#pausePuzzle .hudIcon{stroke-width:4}
body.playing #screen-play #hintCount{display:grid;place-items:center;min-width:28px;height:28px;margin:0;padding:0 6px;border:1px solid #fff4c5;border-radius:10px;background:linear-gradient(#fff9df,#ffe5a1);box-shadow:0 2px 0 #5a2b9940;color:#502675;font:1000 16px/1 Nunito,sans-serif}
body.playing #screen-play .zoomGroup{gap:0;border:1px solid #fffaf0;border-radius:19px;background:linear-gradient(#fffdf7,#f3e6d2);box-shadow:inset 0 2px 1px #ffffff80,0 4px 0 #c7a982,0 7px 10px #34213f30}
body.playing #screen-play .zoomGroup .arcadeControl{min-width:50px;width:50px;padding:0;border:0;border-radius:18px 0 0 18px;background:none;box-shadow:none;font-size:28px;translate:none;transition:background-color 90ms ease}
body.playing #screen-play .zoomGroup .arcadeControl+.arcadeControl{border-left:1px solid #d9c4a8;border-radius:0 18px 18px 0}
body.playing #screen-play .arcadeControl:active:not(:disabled){translate:0 3px;transform:none;box-shadow:inset 0 2px 1px #ffffff50,0 1px 0 var(--arcade-edge),0 3px 5px #34213f30}
body.playing #screen-play .zoomGroup .arcadeControl:active:not(:disabled){translate:none;box-shadow:inset 0 2px 3px #85664e24;background:#d7c1a124}
body.playing #screen-play .arcadeControl:focus-visible{outline:3px solid #ffe292;outline-offset:4px}
body.playing #screen-play .arcadeControl:disabled{opacity:.52;cursor:not-allowed;translate:none;box-shadow:inset 0 1px 1px #fff5,0 2px 0 var(--arcade-edge)}
@media(hover:hover){body.playing #screen-play .arcadeControl:hover:not(:disabled){box-shadow:inset 0 2px 1px #ffffffb0,0 4px 0 var(--arcade-edge),0 8px 12px #34213f40}body.playing #screen-play .zoomGroup .arcadeControl:hover:not(:disabled){background:#ffffff66;box-shadow:none}}
/* Primary touch devices use the existing two-finger camera gesture in either orientation.
   A narrow desktop window still has buttons; a touch-enabled laptop with a mouse keeps them. */
@media(hover:none) and (pointer:coarse){body.playing #screen-play .zoomGroup{display:none}}
@media(max-width:400px){
 body.playing #screen-play .hud{--hud-left:max(8px,env(safe-area-inset-left));--hud-right:max(8px,env(safe-area-inset-right))}
 body.playing #screen-play .arcadeControl{gap:6px;min-height:46px;height:46px;min-width:46px;padding:0 10px;font-size:13px;border-radius:16px}
 body.playing #screen-play #hudHome,body.playing #screen-play #pausePuzzle,body.playing #screen-play .playToolsBtn{width:46px;padding:0}
 body.playing #screen-play .hudActions{gap:8px}
 body.playing #screen-play .hudActions .hudIcon{width:20px;height:20px}
 body.playing #screen-play #hintCount{min-width:24px;height:24px;padding:0 4px;font-size:14px;border-radius:8px}
 body.playing #screen-play .zoomGroup .arcadeControl{width:44px;min-width:44px;padding:0;font-size:26px}
}
@media(prefers-reduced-motion:reduce){body.playing #screen-play .arcadeControl{transition:none}}
html.reduced-motion body.playing #screen-play .arcadeControl{transition:none}

/* T5: a finite target strip, separate from the live puzzle percentage. */
.playGoal[hidden]{display:none!important}
.playGoal{flex:none;margin:0 2px 7px;border:1px solid #deccef;border-radius:16px;background:#fbf6ff;color:#533379;overflow:hidden;contain:layout}
.playGoal[data-kind=mission]{background:#fff9e9;border-color:#e9d7a7}
.playGoalSummary{display:grid;grid-template-columns:44px minmax(0,1fr) 90px;gap:10px;align-items:center;min-height:64px;padding:7px 11px;cursor:pointer;list-style:none}
.playGoalSummary::-webkit-details-marker{display:none}
.playGoalSummary:focus-visible{outline:3px solid #7345b8;outline-offset:-3px;border-radius:15px}
.playGoalArt{position:relative;display:grid;place-items:center;width:44px;height:44px;color:#9663cf;font-size:29px}
.playGoalArt img{position:absolute;width:44px;height:44px;object-fit:contain}
.playGoalCopy{display:grid;gap:1px;min-width:0}
.playGoalCopy>small{font:900 9px/1.2 Nunito,sans-serif;letter-spacing:.06em;color:#805b9b}
.playGoalCopy>strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:900 15px/1.25 Nunito,sans-serif}
#playGoalAction{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;font:700 12px/1.25 Nunito,sans-serif;color:#715a80}
.playGoalNumbers{display:grid;gap:2px;text-align:right;font:900 13px/1.2 Nunito,sans-serif;font-variant-numeric:tabular-nums}
.playGoalUnit{font-size:9px;font-weight:800;color:#76538e}
.playGoalNumbers>small{font-size:10px;color:#76538e}
.playGoalTrack{display:block;height:5px;border-radius:99px;background:#e8daf3;overflow:hidden}
#playGoalFill{display:block;height:100%;background:linear-gradient(90deg,#be89e5,#764ac3);border-radius:inherit}
.playGoal[data-kind=mission] #playGoalFill{background:linear-gradient(90deg,#bb84da,#e8af56)}
.playGoal[open] .playGoalNumbers>small span{display:inline-block;transform:rotate(180deg)}
.playGoalDetails{padding:0 13px 10px 65px;font:700 12px/1.4 Nunito,sans-serif}
.playGoalDetails p{margin:4px 0}.playGoalDetails small{display:block;color:#7f6b89;font-size:10px}
@media(max-width:700px){.playGoal{margin:0 2px 5px;border-radius:13px}.playGoalSummary{grid-template-columns:36px minmax(0,1fr) 65px;gap:7px;padding:6px 8px;min-height:61px}.playGoalArt,.playGoalArt img{width:36px;height:36px}.playGoalCopy>strong{font-size:13px}.playGoalCopy>small{font-size:8px}#playGoalAction{font-size:11px}.playGoalNumbers{font-size:11px}.playGoalDetails{padding-left:12px}}
@media(max-height:500px){.playGoalSummary{min-height:44px;padding-block:3px}.playGoalArt,.playGoalArt img{width:32px;height:32px}#playGoalAction{-webkit-line-clamp:1}.playGoalCopy>small{display:none}.playGoalDetails{padding-top:4px}}

/* A6: each shop page fits the app viewport; its illustration remains prominent. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-shop .shopHero{padding:9px 11px}
 #screen-shop .shopHero h1{font-size:20px}
 #screen-shop .shopBalance{font-size:12px;padding:5px 8px}
 #screen-shop .shopBalance:before{width:21px;height:21px}
 #screen-shop .shopStatus{max-height:42px;margin:0;padding:0;font-size:11px}
 #screen-shop #shopItems>.shopCard,#screen-shop #paidPackItems>.paidPackCard{display:flex;flex-direction:column;gap:5px;align-content:initial;overflow:auto;padding:11px;max-height:100%;min-height:0}
 #screen-shop .shopCardHead{display:flex;grid-column:auto;gap:5px}
 #screen-shop .shopCardVisual{flex:1 1 145px;min-height:88px;max-height:32dvh;width:100%;margin:2px 0 4px}
 #screen-shop .shopCardVisual .shopIllustration{height:calc(100% - 16px);width:min(78%,180px)}
 #screen-shop #paidPackItems{margin-top:0}
 #screen-shop .shopCard h2,#screen-shop .paidPackCard h3{grid-column:auto;grid-row:auto;align-self:auto;margin:0;font-size:21px}
 #screen-shop .shopDescription,#screen-shop .paidPackDescription{display:block;grid-column:auto;grid-row:auto;max-height:3em;overflow:hidden;margin:0;font-size:12px;line-height:1.35}
 #screen-shop .paidPackContents{display:block;grid-column:auto;grid-row:auto;margin:0;font-size:11px;line-height:1.25}
 #screen-shop .shopCardFoot,#screen-shop .paidPackFoot{display:flex;grid-column:auto;grid-row:auto;flex:none;align-items:center;margin-top:auto;padding-top:4px}
 #screen-shop .paidPackPrice{display:grid;gap:2px}
 #screen-shop .shopCardActions{display:flex;grid-column:auto;grid-row:auto;flex:none;gap:7px;margin:0;padding:0}
 #screen-shop .shopCardActions button,#screen-shop .paidPackFoot button{min-height:44px;font-size:12px}
}
@media(max-width:700px) and (max-height:650px), (max-height:500px) and (pointer:coarse){
 #screen-shop .shopCardVisual{flex-basis:88px;min-height:72px;max-height:20dvh}
 #screen-shop .shopCard h2,#screen-shop .paidPackCard h3{font-size:18px}
 #screen-shop .shopDescription,#screen-shop .paidPackDescription{display:none}
 #screen-shop .shopCardHead .shopRarity{display:none}
}

/* Keep the picture invitation and both exits visible on shorter portrait screens. */
@media(max-width:700px) and (max-height:880px){
 .completeCard:has(.nextPuzzleCard:not([hidden])) .completeImage{height:14dvh;min-height:100px}
 .completeCard:has(.nextPuzzleCard:not([hidden])) .completeBody{padding-top:8px;padding-bottom:8px}
}
/* Keep the daily invitation on the same mobile screen as Continue and Albums. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home #featuredDaily.dailyInvitation{flex:none;grid-template-columns:62px minmax(0,1fr) auto;min-height:98px;margin:0;padding:10px 12px;gap:10px;border-radius:20px}
 #screen-home #featuredDaily.dailyInvitation .dailyInvitationPhoto{width:62px;height:62px;border-width:2px;border-radius:12px}
 #screen-home #featuredDaily.dailyInvitation .dailyInvitationSeal{display:none}
 .dailyInvitationCopy{gap:4px}.dailyInvitationCopy .eyebrow{font-size:8px}.dailyInvitationCopy strong{font-size:19px}.dailyInvitationCopy small{font-size:10px;line-height:1.25}
 .dailyInvitationAction{min-height:44px;padding:9px 8px;font-size:11px;border-radius:13px}
 #screen-home #featuredDaily[data-daily-state=unavailable]{grid-template-columns:minmax(0,1fr) auto}
}
@media(max-width:700px) and (max-height:650px){
 #screen-home #featuredDaily.dailyInvitation{min-height:78px;padding:7px 9px;gap:8px;grid-template-columns:48px minmax(0,1fr) auto}
 #screen-home #featuredDaily.dailyInvitation .dailyInvitationPhoto{width:48px;height:48px}.dailyInvitationCopy strong{font-size:17px}.dailyInvitationCopy small{display:none}
 #screen-home .lobbyHero{min-height:95px}#screen-home[data-lobby-state=returning] .lobbyHero{padding:8px}#screen-home .lobbyHeroArt{min-height:0}#screen-home .lobbyHero .softPopMascot{max-height:105px}
 #screen-home .albumLaunch{min-height:68px;padding:7px 10px}
}
@media(max-height:500px) and (max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home #featuredDaily.dailyInvitation{grid-column:1;grid-row:3;min-height:68px;padding:6px 8px;grid-template-columns:42px minmax(0,1fr) auto;gap:6px}
 #screen-home .homeAlbum{grid-column:2;grid-row:3}#screen-home .galleryWrap{grid-template-rows:auto minmax(0,1fr) auto;gap:6px}
 #screen-home #featuredDaily.dailyInvitation .dailyInvitationPhoto{width:42px;height:42px}.dailyInvitationCopy strong{font-size:16px}.dailyInvitationCopy small{display:none}.dailyInvitationAction{font-size:10px;padding:7px 6px}
}
@media(max-width:700px), (max-height:500px) and (pointer:coarse){#screen-home #featuredDaily[data-photo-missing=true]{grid-template-columns:minmax(0,1fr) auto}}
@media(max-height:500px) and (max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home .lobbyContinue{min-height:96px;grid-template-columns:62px minmax(0,1fr)}#screen-home .lobbyContinue>img{min-height:0;height:100%;width:62px}
 #screen-home .lobbyContinueCopy{padding:5px 9px;gap:2px}#screen-home .lobbyContinue .eyebrow,#screen-home .lobbyContinue .softBtn{display:none}
 #screen-home .lobbyContinue h2{font-size:18px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#screen-home .lobbyContinue p{font-size:10px;line-height:1.2}
 #screen-home .lobbyContinue .lobbyActions{margin:0}#screen-home .lobbyContinue .lobbyActions .primaryBtn{min-height:44px;padding:7px 9px}
}
@media(max-height:500px) and (max-width:700px), (max-height:500px) and (pointer:coarse){#screen-home .lobbyContinue h2,#screen-home .lobbyContinue p{margin:0}}

/* Optional goals fit as a single card; tabs replace long scrolling lists. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home .homeJourneyActions{gap:5px}#screen-home .homeJourneyActions .softBtn{min-height:44px;padding:7px 8px;font-size:11px}
 .littleGoalsDialog{width:min(520px,calc(100vw - 16px));max-height:calc(100dvh - 16px);padding:14px;border-radius:23px}.littleGoalsDialog h2{font-size:25px}.goalIntro{font-size:12px;margin:7px 0 11px}.goalContent{margin-top:12px}.goalCard{padding:16px;gap:9px}.goalCard h3{font-size:27px}.goalDescription{font-size:13px}.goalCard .bitmapArt{width:80px;height:80px}.goalActions button{font-size:12px;padding:9px 10px}
}
@media(max-width:700px) and (max-height:650px){.littleGoalsDialog{padding:10px}.goalIntro{margin:5px 0 8px}.goalContent{margin-top:9px}.goalCard{padding:11px;gap:6px}.goalCard .bitmapArt{width:60px;height:60px}.goalCard h3{font-size:23px}.goalStatus{margin:5px 0}.goalPrize{padding:5px 9px}}
@media(max-height:500px) and (max-width:700px), (max-height:500px) and (pointer:coarse){
 .littleGoalsDialog{width:min(700px,calc(100vw - 16px));padding:10px;display:grid;grid-template-columns:170px minmax(0,1fr);gap:6px 12px}.littleGoalsDialog:not([open]){display:none}.littleGoalsDialog header{grid-column:1;grid-row:1}.goalIntro{grid-column:1;grid-row:2;font-size:11px;margin:0}.goalTabs{grid-column:1;grid-row:3;align-self:start}.goalContent{grid-column:2;grid-row:1/6;margin:0}.goalRelax{grid-column:1;grid-row:4;margin:0;align-self:start}.goalStatus{grid-column:1;grid-row:5;margin:0;font-size:11px}.goalCard{padding:10px;gap:5px}.goalCard .bitmapArt{width:44px;height:44px}.goalCard h3{font-size:22px}.goalDescription{font-size:12px}.goalPrize{padding:4px 9px}.goalRule{font-size:9px}.goalActions{gap:6px;margin:0}.goalProgress{font-size:11px}
}

/* Goal artwork and controls stay inside the Home screen, with 44px touch targets. */
@media(max-width:700px), (max-height:500px) and (pointer:coarse){
 #screen-home .lobbyHero.hasAchievementGoal{grid-template-columns:minmax(0,1fr);gap:0}
 #homeAchievementGoal .achievementGoalCard{grid-template-columns:85px minmax(0,1fr);gap:10px}
 #screen-home .lobbyHero .achievementGoalTitle,#screen-home[data-lobby-state=returning] .lobbyHero .achievementGoalTitle{font-size:clamp(19px,5.8vw,25px);margin:4px 0 7px}
 .achievementGoalTrack{height:9px}.achievementGoalProgress{font-size:11px;margin-top:4px}.achievementGoalNote{font-size:10px;line-height:1.25;margin-top:4px}
 .achievementGoalActions{gap:5px;margin-top:8px}#screen-home .lobbyHero .achievementGoalActions button{min-height:44px;font-size:11px;padding:6px 9px;margin:0}
 #screen-home .lobbyHero .achievementGoalMessage{font-size:10px}
 #resultAchievementGoal{padding:8px;margin:7px 0}#resultAchievementGoal .achievementGoalCard{grid-template-columns:52px minmax(0,1fr);gap:8px}
 #resultAchievementGoal .achievementGoalTitle{font-size:16px}#resultAchievementGoal .achievementGoalActions button{font-size:11px}
}
@media(max-width:700px) and (max-height:730px), (max-height:500px) and (pointer:coarse){
 #homeAchievementGoal .achievementGoalCard{grid-template-columns:56px minmax(0,1fr);gap:8px}
 #screen-home .lobbyHero .achievementGoalTitle,#screen-home[data-lobby-state=returning] .lobbyHero .achievementGoalTitle{font-size:19px;margin:3px 0 5px}
 #homeAchievementGoal .achievementGoalNote{display:none}#homeAchievementGoal .achievementGoalActions{margin-top:5px}
 #screen-home .lobbyHero .achievementGoalMessage:not(:empty){display:block}
}

@media(max-width:700px) and (max-height:730px){
 #screen-home:has(.hasAchievementGoal) .homeJourneyActions{flex-direction:row}
 #screen-home:has(.hasAchievementGoal) .playerStrip{padding:7px 9px;gap:6px}
 #screen-home:has(.hasAchievementGoal) .playerIdentity strong{font-size:14px}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue{height:108px;min-height:108px;padding:0;grid-template-columns:72px minmax(0,1fr)}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue>img{width:72px;height:100%;min-height:0;max-height:108px;object-fit:cover}
 #screen-home:has(.hasAchievementGoal) .lobbyContinueCopy{padding:7px 9px;gap:3px}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue h2{font-size:19px;margin:0}#screen-home:has(.hasAchievementGoal) .lobbyContinue p{margin:2px 0}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue .eyebrow,#screen-home:has(.hasAchievementGoal) .lobbyContinue .softBtn{display:none}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue .primaryBtn{min-height:44px}
 #screen-home:has(.hasAchievementGoal) #featuredDaily.dailyInvitation{min-height:74px;padding:7px 9px;grid-template-columns:48px minmax(0,1fr) auto;gap:8px}
 #screen-home:has(.hasAchievementGoal) #featuredDaily.dailyInvitation .dailyInvitationPhoto{width:48px;height:48px}
 #screen-home:has(.hasAchievementGoal) .dailyInvitationCopy small{display:none}#screen-home:has(.hasAchievementGoal) .dailyInvitationCopy strong{font-size:17px}
 #screen-home:has(.hasAchievementGoal) .albumLaunch{min-height:66px;padding:7px 10px}
 #screen-home .lobbyHero.hasAchievementGoal,#screen-home[data-lobby-state=returning] .lobbyHero.hasAchievementGoal{min-height:148px;padding:8px}
}
@media(max-width:700px) and (max-height:620px){
 #screen-home:has(.hasAchievementGoal) .playerIdentity>.eyebrow{display:none}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue{height:94px;min-height:94px}
 #screen-home:has(.hasAchievementGoal) .lobbyContinue>img{max-height:94px}
 #screen-home:has(.hasAchievementGoal) .albumLaunch{min-height:58px;padding:4px 8px}
 #screen-home:has(.hasAchievementGoal) #featuredDaily.dailyInvitation{min-height:62px;padding:4px 8px}
 #screen-home .lobbyHero.hasAchievementGoal,#screen-home[data-lobby-state=returning] .lobbyHero.hasAchievementGoal{min-height:134px;padding:5px}
 #screen-home .lobbyHero .achievementGoalTitle,#screen-home[data-lobby-state=returning] .lobbyHero .achievementGoalTitle{font-size:17px}
}

@media(max-width:700px) and (max-height:620px){
 #screen-home:has(.hasAchievementGoal) .playerStrip{padding-block:4px}
 #screen-home:has(.hasAchievementGoal) .homeJourneyActions .softBtn{padding-inline:6px}
 #screen-home:has(.hasAchievementGoal) #featuredDaily.dailyInvitation{height:60px;min-height:60px;max-height:60px}
 #screen-home:has(.hasAchievementGoal) .dailyInvitationCopy .eyebrow{display:none}
 #screen-home:has(.hasAchievementGoal) .dailyInvitationCopy strong{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:15px}
 #screen-home:has(.hasAchievementGoal) .albumLaunch{height:50px;min-height:50px;max-height:50px;gap:6px}
 #screen-home:has(.hasAchievementGoal) .albumLaunchCopy .eyebrow{display:none}
 #screen-home:has(.hasAchievementGoal) .albumLaunchCopy strong{font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 #screen-home:has(.hasAchievementGoal) .albumLaunchCopy small{font-size:10px}
 #screen-home:has(.hasAchievementGoal) .albumMiniatures .albumSlot{width:28px;height:28px}
}
.progressWrap{height:100%;width:100%;box-sizing:border-box;min-height:0;display:flex;flex-direction:column;gap:12px;padding:18px 24px;max-width:1160px;margin:auto}
.progressHeader{display:flex;align-items:center;justify-content:space-between;gap:12px;flex:none}.progressHeader h1{font-size:32px;margin:2px 0}.progressRefresh{min-width:44px;min-height:44px}
.progressSectionHelp{flex:none;margin:0;padding:0 3px;font-size:13px;line-height:1.4;color:#665273}
.progressTabs,.progressAlbumTabs{display:flex;gap:6px;flex:none}.progressTabs .softBtn,.progressAlbumTabs .softBtn{min-height:44px;padding:9px 15px}.progressTabs [aria-selected=true],.progressAlbumTabs [aria-pressed=true]{background:#7b43c6;color:white}
.progressPanel{flex:1;min-height:0;display:flex;flex-direction:column;gap:12px}.progressPanel[hidden],.progressCabinet[hidden],#progressBooks[hidden],#progressPictures[hidden]{display:none!important}
.progressOverview{justify-content:center;overflow:auto;overscroll-behavior:contain}.progressOverview>p{margin:0;color:#725887}.progressStats{display:grid;grid-template-columns:2fr 1fr;gap:12px}.progressStats .playerJourney,.progressStats .playerStreak{margin:0;max-width:none;min-width:0;width:auto;flex:initial}.progressStats .journeyMascot{width:76px;height:76px}.progressStats .journeyCopy{min-width:0}.progressStats .journeyMilestone{display:none}
.progressNext{display:flex;gap:8px;align-items:center;flex-wrap:wrap;background:#f0e5fa;border:1px solid #d9c2f3;border-radius:20px;padding:14px}.progressNext strong{flex:1}.progressNext .eyebrow{width:100%}.progressLinks{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.progressDoor{display:grid;grid-template-columns:auto 1fr;gap:6px 12px;align-items:center;text-align:left;background:linear-gradient(145deg,#fffaf4,#ede0f7);border:2px solid #e0c7f3;border-radius:22px;padding:16px;color:#533378;box-shadow:0 4px 0 #ddc5eb;cursor:pointer;min-height:100px;font:inherit}.progressDoorIcon{grid-row:1/3;font-size:32px;color:#9153d0}.progressDoor strong{font-size:20px}.progressDoor small{font-size:13px;line-height:1.4}.progressStatus:empty{display:none}.progressStatus{font-size:13px}
.progressCabinet,#progressPictures{flex:1;min-height:0;height:100%;display:flex;flex-direction:column}.progressCabinet .achievementsWrap{padding:0;height:100%;width:100%}.progressCabinet .achievementsHero{min-height:54px;padding:5px 12px}.progressCabinet .achievementsHero .eyebrow{display:none}.progressCabinet .achievementsHeroArt{width:48px;height:48px}.progressCabinet .achievementsHero h1{font-size:24px}.progressCabinet .achievementTabs{gap:5px}.progressCabinet .achievementTabs button{font-size:13px;min-height:44px;padding:6px 12px}.progressCabinet[data-pictures=true] .achievementTabs{display:none}
.missionsPanel{flex:1;min-height:0;display:flex;flex-direction:column;gap:10px;max-width:760px;width:100%;margin:0 auto}.missionsPanel h2{margin:0;font-size:25px}.missionsPanel .goalIntro{margin:0;font-size:14px}.missionsPanel .goalContent{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}.missionsPanel .goalCard{padding:16px;border-radius:22px;min-height:0}.missionsPanel .goalCard h3{font-size:23px;margin:8px 0}.missionsPanel .goalMedal{width:76px;height:76px}.missionsPanel .goalActions button{min-height:44px}.missionsPanel .goalRelax{align-self:center;min-height:44px}.missionsPanel .goalSelected{color:#6f3ba5;font-weight:bold}.missionsPanel .goalStatus{font-size:13px;margin:0}.missionsPanel .goalStatus:empty{display:none}
#progressBooks{flex:1;min-height:0}.progressPanel .albumContent{height:100%;display:flex;flex-direction:column;gap:8px;max-width:900px;margin:auto}.progressBookPager{display:flex;justify-content:space-between;align-items:center;gap:12px;flex:none}.progressBookPager button{min-height:44px;min-width:44px}.progressPanel .albumBook{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding:14px 20px;border-radius:24px;margin:0}.progressPanel .albumBook h3{font-size:25px;margin:5px 0}.progressPanel .albumBook>p{font-size:13px;margin:6px 0}.progressPanel .albumPages{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:10px 0}.progressPanel .albumPhoto{height:clamp(80px,20dvh,180px);width:100%;object-fit:cover}.progressPanel .albumSlot{min-width:0}.progressPanel .albumPictureTitle{font-size:13px}.progressPanel .albumCount{font-size:14px}.progressPanel .albumBook .primaryBtn{min-height:44px}
.progressWrap button:focus-visible{outline:3px solid #7941c5;outline-offset:3px}
.progressStats .journeyCopy strong,.progressStats .journeyCopy small{color:#533a74}
#progressPictures>#playerCollections{order:2;flex:none;width:auto;max-width:none;margin:7px 0 0;padding:8px 12px;gap:2px;font-size:12px}#progressPictures>#playerCollections[hidden]{display:none}
@media(max-width:700px),(max-height:500px) and (pointer:coarse){
 .progressWrap{padding:8px 12px;gap:7px}.progressHeader h1{font-size:25px}.progressHeader .eyebrow{display:none}.progressTabs{gap:4px}.progressTabs .softBtn{flex:1;padding:6px 3px;font-size:12px;min-height:44px}.progressPanel{gap:7px}.progressOverview{justify-content:flex-start;gap:9px}.progressOverview>p{font-size:12px}.progressStats{grid-template-columns:1fr;gap:7px}.progressStats .playerJourney{padding:8px 12px;min-height:74px}.progressStats .journeyMascot{width:46px;height:46px}.progressStats .journeyLevel{font-size:25px}.progressStats .journeyCopy strong{font-size:16px}.progressStats .journeyXP{font-size:12px}.progressStats .playerStreak{padding:8px 12px}.progressStats .playerStreak strong{font-size:14px}.progressNext{padding:9px 12px;gap:5px;border-radius:17px}.progressNext strong{font-size:15px}.progressNext>small{font-size:12px}.progressNext .softBtn{font-size:12px;min-height:44px;padding:6px 10px}.progressLinks{grid-template-columns:1fr;gap:7px}.progressDoor{min-height:62px;padding:9px 12px;border-radius:17px;gap:2px 10px}.progressDoor strong{font-size:17px}.progressDoor small{font-size:11px}.progressDoorIcon{font-size:27px}.progressCabinet .achievementsHero{min-height:42px;padding:2px 8px}.progressCabinet .achievementsHero h1{font-size:21px}.progressCabinet .achievementsHero p{font-size:10px}.progressCabinet .achievementTools>p{display:none}.progressCabinet .achievementTools{justify-content:flex-end}.progressCabinet .achievementTabs button{flex:1;padding:5px 3px;font-size:11px}.progressCabinet .achievementsHeroArt{display:none}.missionsPanel h2{font-size:22px}.missionsPanel .goalIntro{font-size:12px}.missionsPanel .goalCard{padding:11px}.missionsPanel .goalCard h3{font-size:21px}.missionsPanel .goalMedal{width:58px;height:58px}.missionsPanel .goalDescription{font-size:13px}.missionsPanel .goalRule{font-size:11px}.missionsPanel .goalRelax{font-size:12px;padding:7px 12px}.progressAlbumTabs .softBtn{flex:1;padding:6px 10px;font-size:12px}.progressPanel .albumPages{grid-template-columns:repeat(2,minmax(0,1fr));margin:7px 0}.progressPanel .albumBook{padding:12px}.progressPanel .albumBook h3{font-size:21px}.progressPanel .albumPhoto{height:clamp(75px,19dvh,160px)}.progressPanel .albumBook>p{font-size:12px}.progressBookPager span{font-size:12px}
}
@media(max-height:660px){.progressWrap{gap:5px}.progressHeader .eyebrow{display:none}.progressHeader h1{font-size:23px}.progressOverview{gap:6px}.progressStats{grid-template-columns:2fr 1fr}.progressStats .journeyMascot{display:none}.progressStats .playerJourney,.progressStats .playerStreak{padding:7px 9px}.progressStats .journeyCopy .eyebrow,.progressStats .playerStreak .eyebrow{display:none}.progressDoor{min-height:52px;padding:6px 10px}.progressDoor small{font-size:10px}.progressNext{padding:7px 10px}.progressNext .eyebrow{display:none}.missionsPanel .goalMedal{float:right;width:45px;height:45px}.missionsPanel .goalCard h3{font-size:18px}.progressPanel .albumPhoto{height:85px}}

/* Size the bitmap wrapper too: the img alone does not set its grid row height. */
.missionsPanel .goalCard .bitmapArt{width:76px;height:76px}.missionsPanel .goalMedal{width:100%;height:100%}
@media(max-width:700px){.missionsPanel .goalCard .bitmapArt{width:58px;height:58px}}
@media(max-height:660px){.missionsPanel .goalCard .bitmapArt{width:40px;height:40px}.missionsPanel .goalCard{gap:5px}.missionsPanel .goalCard h3{margin:0}.missionsPanel .goalContent{margin-top:0}}

/* T4: one pictured next action; detail and other choices stay secondary. */
#screen-home[data-play-lobby] .galleryWrap{display:flex;flex-direction:column;gap:10px;height:100%;min-height:0;max-width:1100px;padding:14px 20px}
#screen-home[data-play-lobby] .libraryFilters,#screen-home[data-play-lobby] #motifGrid,#screen-home[data-play-lobby] .previousMotifs,#screen-home[data-play-lobby] #homeAlbum,#screen-home[data-play-lobby] .lobbyIntro,#screen-home[data-play-lobby] .lobbyHeroArt{display:none!important}
#screen-home[data-play-lobby] .playerStrip{flex:none;margin:0;padding:7px 12px;min-height:0}
#screen-home[data-play-lobby] .playerIdentity>.eyebrow{display:none}
#screen-home[data-play-lobby] .lobbyHero{order:1;flex:1;min-height:0;margin:0;padding:14px;gap:10px 22px;display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);grid-template-rows:auto minmax(0,1fr);border-radius:28px;overflow:hidden}
.playPicture{grid-column:1;grid-row:1/3;position:relative;min-height:0;border-radius:20px;overflow:hidden;background:radial-gradient(circle,#f6d981,#eacffa);display:flex;align-items:center;justify-content:center}
.playPicture img{height:100%;width:100%;object-fit:cover;min-height:0}.playPictureGlow{position:absolute;inset:0;pointer-events:none;box-shadow:inset 0 0 0 2px #fff9,inset 0 -12px 35px #50386025;border-radius:inherit}
.playPrompt{grid-column:2;grid-row:1;display:grid;gap:7px;align-content:center;min-width:0;padding:10px 0 0}
#screen-home[data-play-lobby] .playPrompt h1{font-size:clamp(23px,3vw,35px);margin:0;line-height:1.12;overflow-wrap:anywhere}
#screen-home[data-play-lobby] .playPrompt p{display:block;margin:0;font-size:13px;line-height:1.3}
#screen-home[data-play-lobby] .playPrompt .primaryBtn{margin:6px 0 0;min-height:50px;font-size:17px;justify-self:stretch}
#screen-home[data-play-lobby] #lobbyOpenStatus:empty{display:none}
#screen-home[data-play-lobby] #lobbyOpenStatus{color:#9b384d;font-size:12px}
#screen-home[data-play-lobby] #homeAchievementGoal{grid-column:2;grid-row:2;align-self:center;width:100%;min-width:0;margin:0;border:1px solid #dfc6ed;border-radius:20px;background:#f2e7fa;padding:12px}
#screen-home[data-play-lobby] .achievementGoalCard{grid-template-columns:60px minmax(0,1fr);gap:10px;align-items:center}
#screen-home[data-play-lobby] .goalMedalShell{width:60px;max-height:60px}.goalMedalShell .goalArtFallback{font-size:35px}
#screen-home[data-play-lobby] .achievementGoalTitle{font-size:19px;margin:4px 0 6px;line-height:1.1}
#screen-home[data-play-lobby] .achievementGoalNote{display:block;font-size:12px;line-height:1.3;margin-top:6px}
#screen-home[data-play-lobby] .achievementGoalProgress,#screen-home[data-play-lobby] .achievementGoalMessage{font-size:11px}
#screen-home[data-play-lobby] .achievementGoalPlay{display:none}
#screen-home[data-play-lobby] .achievementGoalDetails{min-height:44px;padding:5px 0;font-size:12px;border:0;background:none;box-shadow:none;text-decoration:underline}
#screen-home[data-play-lobby] .achievementGoalActions{margin:0}
#screen-home[data-play-lobby] #continuePanel{order:2;flex:none;min-height:68px;height:auto;max-height:90px;margin:0;grid-template-columns:60px minmax(0,1fr);border-radius:18px}
#screen-home[data-play-lobby] #continuePanel>img{width:60px;height:100%;min-height:0;max-height:90px;object-fit:cover}
#screen-home[data-play-lobby] .lobbyContinueCopy{padding:6px 10px;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2px 8px;align-items:center}
#screen-home[data-play-lobby] .lobbyContinueCopy h2{grid-column:1;font-size:16px;margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#screen-home[data-play-lobby] .lobbyContinueCopy p{grid-column:1;font-size:10px;margin:0}
#screen-home[data-play-lobby] .lobbyContinueCopy>.eyebrow{display:none}
#screen-home[data-play-lobby] .lobbyContinueCopy .lobbyActions{grid-column:2;grid-row:1/3;margin:0}
#screen-home[data-play-lobby] .lobbyContinueCopy [data-nav=library]{display:none}
#screen-home[data-play-lobby] #playDailyBtn{min-height:44px;font-size:11px;margin:0;padding:6px 9px;background:#eaddf5;color:#543779;box-shadow:0 2px 0 #bea4d4}
#screen-home[data-play-lobby] #featuredDaily{order:3;min-height:68px;max-height:86px;height:auto;margin:0;padding:8px 12px;grid-template-columns:54px minmax(0,1fr) auto;gap:10px;flex:none;flex-basis:auto}
#screen-home[data-play-lobby] #featuredDaily .dailyInvitationPhoto{width:54px;height:54px}
#screen-home[data-play-lobby] #featuredDaily .dailyInvitationSeal,#screen-home[data-play-lobby] #featuredDaily .dailyInvitationCopy small{display:none}
#screen-home[data-play-lobby] #featuredDaily .dailyInvitationCopy .eyebrow{display:block;font-size:9px}
#screen-home[data-play-lobby] #featuredDaily .dailyInvitationCopy strong{font-size:17px;line-height:1.1}
#screen-home[data-play-lobby] .playChoose{order:4;flex:none;min-height:44px;margin:0;align-self:center;font-size:13px;padding:7px 15px}
@media(max-width:700px){
 #screen-home[data-play-lobby] .galleryWrap{padding:8px max(12px,env(safe-area-inset-right)) 8px max(12px,env(safe-area-inset-left));gap:7px}
 #screen-home[data-play-lobby] .lobbyHero{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(64px,1fr) auto auto;padding:10px;gap:7px;border-radius:23px}
 #screen-home[data-play-lobby] .playPicture{grid-column:1;grid-row:1;border-radius:16px}
 #screen-home[data-play-lobby] .playPrompt{grid-column:1;grid-row:2;padding:0;gap:4px}
 #screen-home[data-play-lobby] .playPrompt h1{font-size:24px}
 #screen-home[data-play-lobby] .playPrompt .eyebrow{display:none}
 #screen-home[data-play-lobby] .playPrompt .primaryBtn{font-size:16px;min-height:48px;margin-top:3px}
 #screen-home[data-play-lobby] #homeAchievementGoal{grid-column:1;grid-row:3;padding:7px 9px;border-radius:15px}
 #screen-home[data-play-lobby] .achievementGoalCard{grid-template-columns:44px minmax(0,1fr);gap:7px}
 #screen-home[data-play-lobby] .goalMedalShell{width:44px;max-height:44px}
 #screen-home[data-play-lobby] .achievementGoalTitle{font-size:17px;margin:2px 0 4px}
 #screen-home[data-play-lobby] .achievementGoalNote{font-size:11px;margin-top:4px}
 #screen-home[data-play-lobby] .achievementGoalDetails{font-size:11px}
 #screen-home[data-play-lobby] .achievementGoalProgress{display:none}
 #screen-home[data-play-lobby] #continuePanel{min-height:64px;max-height:64px}
 #screen-home[data-play-lobby] #featuredDaily{min-height:64px;max-height:72px;padding:6px 10px;grid-template-columns:44px minmax(0,1fr) auto;gap:7px}
 #screen-home[data-play-lobby] #featuredDaily .dailyInvitationPhoto{width:44px;height:44px}
}
@media(max-width:700px) and (max-height:720px){
 #screen-home[data-play-lobby] .galleryWrap{gap:5px;padding-block:5px}
 #screen-home[data-play-lobby] .playerStrip{padding:4px 8px;font-size:12px}
 #screen-home[data-play-lobby] .playerIdentity strong{font-size:12px}
 #screen-home[data-play-lobby] .lobbyHero{grid-template-rows:minmax(36px,1fr) auto auto;padding:7px;gap:5px}
 #screen-home[data-play-lobby] .playPrompt{grid-template-columns:minmax(0,1fr) auto;gap:3px 7px}
 #screen-home[data-play-lobby] .playPrompt h1{font-size:18px;grid-column:1;grid-row:1;align-self:end}
 #screen-home[data-play-lobby] .playPrompt p{font-size:10px;grid-column:1;grid-row:2}
 #screen-home[data-play-lobby] .playPrompt .primaryBtn{font-size:12px;padding:7px 10px;min-height:44px;grid-column:2;grid-row:1/3;margin:0}
 #screen-home[data-play-lobby] #lobbyOpenStatus{grid-column:1/-1}
 #screen-home[data-play-lobby] .achievementGoalCard{grid-template-columns:34px minmax(0,1fr);gap:5px}
 #screen-home[data-play-lobby] .goalMedalShell{width:34px;max-height:34px}
 #screen-home[data-play-lobby] .achievementGoalTitle{font-size:14px}
 #screen-home[data-play-lobby] .achievementGoalNote{font-size:10px}
 #screen-home[data-play-lobby] .achievementGoalTrack{height:5px}
 #screen-home[data-play-lobby] #featuredDaily{min-height:54px;max-height:54px;padding:4px 8px;grid-template-columns:38px minmax(0,1fr) auto}
 #screen-home[data-play-lobby] #featuredDaily .dailyInvitationPhoto{width:38px;height:38px}
 #screen-home[data-play-lobby] .playChoose{font-size:12px;min-height:44px}
}
@media(max-height:500px){
 #screen-home[data-play-lobby] .lobbyHero{grid-template-columns:minmax(0,1fr) minmax(0,1fr);grid-template-rows:auto auto}
 #screen-home[data-play-lobby] .playPicture{grid-column:1;grid-row:1/3}
 #screen-home[data-play-lobby] .playPrompt{grid-column:2;grid-row:1}
 #screen-home[data-play-lobby] #homeAchievementGoal{grid-column:2;grid-row:2}
 #screen-home[data-play-lobby] .galleryWrap{overflow:auto;overscroll-behavior:contain}
}
/* Absolute bitmap content cannot force the short-screen grid row beyond its bounds. */
#screen-home[data-play-lobby] .playPicture{align-self:stretch;height:auto;min-height:0}
#screen-home[data-play-lobby] .playPicture img{position:absolute;inset:0;height:100%;width:100%;object-fit:cover}
#screen-home[data-play-lobby] .lobbyHero .achievementGoalTitle{font-size:19px}
@media(max-width:700px){#screen-home[data-play-lobby] .lobbyHero .achievementGoalTitle{font-size:17px}}
@media(max-width:700px) and (max-height:720px){#screen-home[data-play-lobby] .lobbyHero .achievementGoalTitle{font-size:14px}}

/* T4 refinement: compact recommendation and swipeable alternatives. */
#screen-home[data-play-lobby] .lobbyHero{flex:none;grid-template-columns:180px minmax(0,1fr);grid-template-rows:auto auto;gap:10px 16px;padding:14px;max-height:none}
#screen-home[data-play-lobby] .playPicture{grid-column:1;grid-row:1/3;width:180px;min-height:140px;max-height:230px}
#screen-home[data-play-lobby] .playPrompt{grid-column:2;grid-row:1;grid-template-columns:minmax(0,1fr) auto;gap:5px 10px;padding:0}
#screen-home[data-play-lobby] .playPrompt .eyebrow{display:block;grid-column:1/-1;font-size:10px;letter-spacing:.1em}
#screen-home[data-play-lobby] .playPrompt h1{grid-column:1;grid-row:auto;font-size:26px}
#screen-home[data-play-lobby] .playPrompt #lobbyPictureMeta{grid-column:1;grid-row:auto;font-size:15px;font-weight:800;color:#56357c}
#screen-home[data-play-lobby] .playPrompt #lobbyStart{grid-column:2;grid-row:2/4;min-height:52px;margin:0;font-size:16px;padding:9px 15px}
#screen-home[data-play-lobby] .playPieces{grid-column:1;justify-self:start;border:0;background:none;color:#6a3ab2;text-decoration:underline;font:800 12px Nunito,sans-serif;min-height:44px;padding:3px 0;cursor:pointer}
#screen-home[data-play-lobby] #homeAchievementGoal{grid-column:2;grid-row:2;align-self:stretch;padding:7px 9px}
#screen-home[data-play-lobby] .achievementGoalCard{grid-template-columns:34px minmax(0,1fr);gap:7px}
#screen-home[data-play-lobby] .goalMedalShell{width:34px;height:34px}
#screen-home[data-play-lobby] .achievementGoalCopy{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:8px;align-items:center}
#screen-home[data-play-lobby] .achievementGoalCopy>*{grid-column:1}
#screen-home[data-play-lobby] .achievementGoalActions{grid-column:2;grid-row:1/7;align-self:center;margin:0}
#screen-home[data-play-lobby] .lobbyHero .achievementGoalTitle{font-size:16px;margin:3px 0}
#screen-home[data-play-lobby] .achievementGoalNote{font-size:11px;margin-top:4px}
#screen-home[data-play-lobby] .achievementGoalProgress{display:none}
#screen-home[data-play-lobby] #continuePanel,#screen-home[data-play-lobby] #featuredDaily{display:none!important}
#screen-home[data-play-lobby] .playAlternatives{order:3;display:flex;flex-direction:column;gap:8px;flex:1;min-height:0;max-height:310px}
.playAlternatives>header{display:flex;align-items:center;justify-content:space-between;flex:none;gap:8px}
.playAlternatives h2{font:1000 22px Nunito,sans-serif;margin:0;color:#55367e}
#screen-home[data-play-lobby] .playChoose{margin:0;min-height:44px;align-self:center;padding:6px 12px;font-size:12px}
.playOtherRow{display:flex;align-items:center;gap:7px;flex:1;min-height:0}
.playOtherRow>.softBtn{flex:none;min-height:44px;width:44px;padding:5px;font-size:28px;border-radius:14px}
.playOtherRow>.softBtn:disabled{opacity:.35}
.playOtherRail{display:flex;align-items:stretch;gap:10px;flex:1;min-width:0;height:100%;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x proximity;scrollbar-width:thin;overscroll-behavior-x:contain;padding:3px 3px 7px}
.playOtherCard{display:flex;flex-direction:column;flex:0 0 190px;min-width:0;min-height:0;padding:0 0 7px;border:2px solid #fff;border-radius:18px;overflow:hidden;background:#f1e4f8;color:#523677;scroll-snap-align:start;cursor:pointer;text-align:left;box-shadow:0 2px 0 #cbb4dc}
.playOtherCard img{flex:1;min-height:0;width:100%;height:0;object-fit:cover;background:#e7daf0}
.playOtherCard strong{flex:none;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;font:900 14px/1.15 Nunito,sans-serif;padding:6px 8px 0}
.playOtherCard small{flex:none;font:800 12px Nunito,sans-serif;padding:3px 8px 0;color:#79549c}
.playOtherCard:focus-visible,.playPieces:focus-visible{outline:3px solid #7540bc;outline-offset:2px}
@media(max-width:700px){
 #screen-home[data-play-lobby] .lobbyHero{grid-template-columns:92px minmax(0,1fr);grid-template-rows:auto auto;padding:9px;gap:7px;border-radius:22px}
 #screen-home[data-play-lobby] .playPicture{grid-column:1;grid-row:1;width:92px;min-height:0;height:110px;max-height:110px}
 #screen-home[data-play-lobby] .playPrompt{grid-column:2;grid-row:1;display:grid;grid-template-columns:minmax(0,1fr);gap:3px;align-content:start}
 #screen-home[data-play-lobby] .playPrompt .eyebrow{display:block;grid-column:1/-1;grid-row:1;font-size:8px}
 #screen-home[data-play-lobby] .playPrompt h1{grid-column:1/-1;grid-row:2;font-size:20px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 #screen-home[data-play-lobby] .playPrompt #lobbyPictureMeta{grid-column:1/-1;grid-row:3;font-size:12px}
 #screen-home[data-play-lobby] .playPrompt #lobbyStart{grid-column:1/-1;grid-row:4;min-height:44px;font-size:13px;padding:6px 8px}
 #screen-home[data-play-lobby] .playPrompt:has(.playPieces:not([hidden])){grid-template-columns:minmax(0,1fr) 54px}
 #screen-home[data-play-lobby] .playPrompt:has(.playPieces:not([hidden])) #lobbyStart{grid-column:1;font-size:12px}
 #screen-home[data-play-lobby] .playPieces{grid-column:2;grid-row:4;justify-self:stretch;min-height:44px;font-size:10px;padding:3px;background:#eadcf4;border-radius:12px;text-decoration:none;white-space:normal}
 #screen-home[data-play-lobby] #homeAchievementGoal{grid-column:1/-1;grid-row:2;padding:6px 8px}
 #screen-home[data-play-lobby] .achievementGoalCard{grid-template-columns:28px minmax(0,1fr);gap:5px}
 #screen-home[data-play-lobby] .goalMedalShell{width:28px;height:28px}
 #screen-home[data-play-lobby] .lobbyHero .achievementGoalTitle{font-size:14px}
 #screen-home[data-play-lobby] .achievementGoalNote{font-size:10px}
 #screen-home[data-play-lobby] .achievementGoalTrack{height:5px}
 #screen-home[data-play-lobby] .achievementGoalActions .achievementGoalDetails{font-size:10px;min-height:44px}
 #screen-home[data-play-lobby] .playAlternatives{max-height:360px;gap:5px}
 .playAlternatives h2{font-size:18px}.playOtherRow{gap:4px}.playOtherRail{gap:8px}.playOtherRow>.softBtn{width:44px}.playOtherCard{flex-basis:148px;border-radius:15px}
 .playOtherCard strong{font-size:13px}.playOtherCard small{font-size:11px}
}
@media(max-width:700px) and (max-height:650px){
 #screen-home[data-play-lobby] .lobbyHero{padding:6px;gap:5px}
 #screen-home[data-play-lobby] .playPicture{width:78px;height:94px}
 #screen-home[data-play-lobby] .lobbyHero{grid-template-columns:78px minmax(0,1fr)}
 #screen-home[data-play-lobby] .playPrompt h1{font-size:17px}
 #screen-home[data-play-lobby] .playPrompt #lobbyPictureMeta{font-size:11px}
 .playOtherCard{flex-basis:135px}.playOtherCard strong{-webkit-line-clamp:1}
}
/* T6: verified totals and separate collectible rewards, without new animation work. */
#screen-complete .completeImage{height:clamp(80px,12dvh,140px);min-height:80px}
.rankResult{position:relative}.rankResult>.rewardTrophy{position:absolute;right:8px;top:0;width:44px;height:44px;margin:0;z-index:1}
.rankResult:has(.resultEarned){display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:6px}
.rankResult .resultEarned,.rankResult .resultSaveStatus{grid-column:1/-1}
.rankResult:has(.resultEarned)>.resultDiscoveries,.rankResult:has(.resultEarned)>.resultRanking{margin:0;min-width:0}
.rankResult details[open]{grid-column:1/-1}
#screen-complete .rankResult .resultEarned h3{font-size:14px;margin:0 0 6px;padding-right:35px}
#resultAchievementGoal .achievementGoalNote:empty{display:none}
#resultAchievementGoal .achievementGoalCopy{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 6px}
#resultAchievementGoal .eyebrow,#resultAchievementGoal .achievementGoalTrack,#resultAchievementGoal .achievementGoalMessage,#resultAchievementGoal .achievementGoalNote,#resultAchievementGoal .achievementGoalNext,#resultAchievementGoal .achievementGoalActions{grid-column:1/-1}
#resultAchievementGoal .eyebrow{margin:0}#resultAchievementGoal .achievementGoalTitle{margin:0;font-size:16px}
#resultAchievementGoal .achievementGoalProgress{margin:0;font-size:10px;align-self:center;white-space:nowrap}
#screen-complete .resultGrid{margin:8px 0}#screen-complete .resultBox{padding:7px}#screen-complete .resultBox b{font-size:21px}
@media(min-width:900px){#screen-complete .completeCard{width:min(1100px,100%);display:grid;grid-template-columns:minmax(220px,.7fr) minmax(0,1.3fr)}#screen-complete .completeImage{height:100%;grid-column:1;grid-row:1;border-radius:26px 0 0 26px}#screen-complete .completeBody{grid-column:2;padding:12px 16px}}
.resultSaveStatus{font-weight:850;color:#3d6a52!important;font-size:13px;margin:6px 0!important}
.rankResult .resultEarned{padding:10px 12px;background:#f2eafa;border:1px solid #dfccec;border-radius:17px}
.rankResult .resultEarned h3{font-size:16px;margin:0 0 8px}
.resultRewardTotals{display:flex;gap:8px;flex-wrap:wrap}
.resultRewardAmount{display:grid;grid-template-columns:25px 1fr;gap:1px 6px;flex:1;min-width:135px;padding:8px;border-radius:12px;background:#fffafc}
.resultRewardAmount strong{font-size:19px;color:#583887}.resultRewardAmount small{grid-column:2;font-size:10px;color:#675375}
.resultRewardAmount .resultCurrency{grid-row:1/3;align-self:center;color:#8750c3;font-size:23px}
.resultRewardAmount.resultCoins{background:#fff1c9;border:0;color:#72501c}.resultRewardAmount.resultCoins:before{display:none}.resultRewardAmount.resultCoins strong,.resultRewardAmount.resultCoins .resultCurrency{color:#72501c}
.resultBonus,.resultLevel{display:block;margin-top:6px;font-size:11px;color:#665076}
.resultDiscoveries,.resultRanking,.resultConnection{margin:9px 0;border:1px solid #dbc9e5;border-radius:13px;background:#fffafc}
.resultDiscoveries summary,.resultRanking summary,.resultConnection summary{padding:10px 12px;font-size:12px;font-weight:850;cursor:pointer;min-height:40px;box-sizing:border-box}
.resultDiscoveries summary:focus-visible,.resultRanking summary:focus-visible,.resultConnection summary:focus-visible{outline:3px solid #7c45c4;outline-offset:2px;border-radius:12px}
.rankResult .resultRewardExplain{padding:0 12px;font-size:11px;margin:0 0 8px;line-height:1.4}
.resultDiscoveryList{list-style:none;margin:0;padding:0 10px 10px;display:grid;gap:8px}
.resultDiscovery{display:grid;grid-template-columns:40px minmax(0,1fr);gap:4px 9px;align-items:center;padding:8px;background:#f4edf9;border-radius:12px}
.resultDiscoveryArt{position:relative;display:grid;place-items:center;width:40px;height:40px;font-size:25px;color:#8750c3;grid-row:1/3}
.resultDiscoveryArt img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;background:#f4edf9}
.resultDiscoveryCopy{min-width:0}.resultDiscoveryCopy strong{font-size:13px}.resultDiscoveryCopy small{display:block;font-size:10px;color:#6a517b}
.resultDiscovery button{justify-self:start;font-size:11px;padding:7px 10px;min-height:36px;white-space:normal}
.resultRanking p,.resultRanking button,.resultConnection p{margin:5px 12px 12px!important}
#resultAchievementGoal .achievementGoalNote{display:block;font-size:11px;line-height:1.35;color:#684d79;margin:5px 0}
#resultAchievementGoal .achievementGoalProgress{font-weight:850}
#resultAchievementGoal[data-state=earned]{border-color:#c7dcae;background:linear-gradient(115deg,#f1f7dd,#fff0c9)}
#resultAchievementGoal .achievementGoalNext{overflow-wrap:anywhere;line-height:1.35}
@media(max-width:700px){
 .rankResult .resultEarned{padding:8px 10px}.rankResult .resultEarned h3{font-size:14px}
 .resultRewardAmount{min-width:100px;padding:7px}.resultRewardAmount strong{font-size:17px}.resultRewardAmount small{font-size:9px}
 #screen-complete .completeImage{height:clamp(80px,10dvh,120px);min-height:80px}
 #screen-complete .completeBody{padding:10px 13px}#screen-complete .completeBody h1{font-size:25px}
 #screen-complete .resultGrid{margin:8px 0}#screen-complete .resultBox{padding:7px}#screen-complete .resultBox b{font-size:21px}
 #screen-complete .rankResult>.rewardTrophy{width:44px;height:44px}
}

/* T7: one visual language for permanent medals, timed missions and picture albums. */
.progressSymbol{display:inline-grid;place-items:center;flex:none;width:32px;height:32px;border-radius:11px;background:#ede0fc;color:#6632a0;box-shadow:inset 0 1px 0 #fff}
.progressSymbol svg{width:72%;height:72%}
.progressSymbol[data-kind=missions]{color:#1a675d;background:#d9f1e6}
.progressSymbol[data-kind=albums]{color:#875219;background:#ffedc7}
.progressSymbol[data-kind=overview]{color:#355e90;background:#dceafa}
.progressBadge{display:inline-flex;align-items:center;justify-content:center;gap:5px;align-self:center;max-width:100%;box-sizing:border-box;padding:4px 8px;border:1px solid #ccb8e6;border-radius:12px;background:#f0e5fb;color:#583282;font:800 12px/1.3 Nunito,sans-serif;white-space:normal}
.progressBadgeMark{flex:none;font-size:14px}
.progressBadge[data-state=earned],.progressBadge[data-state=collected]{color:#205f40;border-color:#a4c8b2;background:#e0f2e5}
.progressBadge[data-state=reward]{color:#754300;border-color:#d8b26a;background:#fff0c7}
.progressBadge[data-state=pending],.progressBadge[data-state=ended],.progressBadge[data-state=locked]{color:#58536b;border-color:#c7c3d4;background:#eeeaf4}
.progressTabs .softBtn{display:flex;align-items:center;justify-content:center;gap:7px;min-width:0}
.progressTabs .progressSymbol{width:26px;height:26px;border-radius:9px;box-shadow:none}
.progressTabs [aria-selected=true]{box-shadow:0 3px 0 #51307c,inset 0 1px 0 #fff8}
.progressTabs [aria-selected=true] .progressSymbol{background:#ffffff26;color:white}
.progressDoor[data-kind=missions]{border-color:#b0dac8;background:linear-gradient(145deg,#fffaf4,#e1f3e9);box-shadow:0 4px 0 #b9d9cc}
.progressDoor[data-kind=albums]{border-color:#e5c98e;background:linear-gradient(145deg,#fffaf4,#fff0d2);box-shadow:0 4px 0 #e6cf9f}
.progressDoor .progressDoorIcon{width:52px;height:52px;border-radius:17px;grid-row:1/3}
.progressDoor small{color:#554969}
.progressNext{display:grid;grid-template-columns:42px minmax(0,1fr) auto;align-items:center;gap:5px 10px}
.progressNext>.progressNextIcon{grid-column:1;grid-row:1/4;width:42px;height:42px}
.progressNext>.eyebrow{grid-column:2;width:auto;font-size:11px}
.progressNext>strong{grid-column:2;grid-row:2;min-width:0;overflow-wrap:anywhere}
.progressNext>.progressNextCount{grid-column:2;grid-row:3;font-weight:800;color:#59456e}
.progressNext>.progressBadge{grid-column:3;grid-row:1;justify-self:end}
.progressNext>.softBtn{grid-column:3;grid-row:2/4;min-height:44px;min-width:44px}
.progressNext[data-kind=missions]{background:#e5f4ec;border-color:#afd5c2}
.progressStats .journeyCopy small{font-size:13px}.progressStats .playerStreak small{font-size:12px}
.progressStats .journeyTrack{position:relative}
.missionsPanel>header{display:flex;align-items:center;gap:9px}
.missionsPanel .goalIntro{color:#5c496e;line-height:1.4}
.missionsPanel .goalCard{max-width:600px;margin:0 auto;grid-template-columns:72px minmax(0,1fr);justify-items:start;text-align:left;gap:10px 14px;background:linear-gradient(140deg,#e4f5e9,#fff5dd)}
.missionsPanel .goalCard>.bitmapArt{grid-column:1;grid-row:1/5;width:72px;height:72px;align-self:start}
.missionsPanel .goalCard>.eyebrow,.missionsPanel .goalCard>h3,.missionsPanel .goalDescription,.missionsPanel .goalCard>.progressBadge:first-of-type{grid-column:2}
.missionsPanel .goalCard>.eyebrow{color:#365f52;font-size:11px;letter-spacing:.08em}
.missionsPanel .goalCard>h3{margin:0;font-size:24px;line-height:1.15}
.missionsPanel .goalDescription{margin:0;color:#574364;line-height:1.4;font-size:14px}
.missionsPanel .goalCard>.progressBadge{align-self:start;justify-self:start;grid-column:1/-1}
.missionsPanel .goalTrack,.missionsPanel .goalProgress,.missionsPanel .goalActions,.missionsPanel .goalRule,.missionsPanel .goalSelected{grid-column:1/-1;width:100%;box-sizing:border-box}
.missionsPanel .goalTrack{height:10px}.missionsPanel .goalProgress{font-size:14px;color:#4d3769}
.missionsPanel .goalActions{margin:0;justify-content:start}.missionsPanel .goalActions .primaryBtn{width:100%;font-size:15px}
.missionsPanel .goalPrize{grid-column:1/-1;color:#754300;border:1px solid #d8b26a;background:#fff0c7;font-size:12px}
.missionsPanel .goalRule{color:#614f6d;line-height:1.4;font-size:12px;text-align:left}
.missionsPanel .goalDone{margin:0;line-height:1.4;color:#47644e;font-size:13px}
.progressPanel .albumBook{position:relative;background:linear-gradient(145deg,#fffaec,#fbe7ba);border:1px solid #e3c78a}
.progressPanel .albumBookIcon{float:right;width:44px;height:44px;margin:0 0 6px 8px}
.progressPanel .albumBook>.progressBadge{margin-right:5px}
.progressPanel .albumBook>.eyebrow{display:block;margin-top:8px;color:#765421;font-size:11px}
.progressPanel .albumBook>p{font-size:14px;color:#5c4968;line-height:1.4}
.progressPanel .albumPictureTitle{font-size:14px;line-height:1.25;padding:9px 4px;color:#503072}
.progressCabinet .achievementsHero p{font-size:13px;color:#5b456d}
.progressCabinet .achievementDisplay button{min-height:44px;min-width:44px}
.progressCabinet .achievementsWrap{gap:7px}
.progressCabinet .achievementsHero{box-sizing:border-box;min-height:50px;padding:4px 12px}
.progressCabinet .achievementsHero h1{margin:0;font-size:23px}
.progressCabinet .achievementsHeroArt{width:40px;height:40px}
.progressCabinet .achievementTabs{box-sizing:border-box;padding:3px}
.progressCabinet .achievementTools{min-height:44px}
.progressCabinet .achievementDisplay{padding:1px}
.progressCabinet .achievementCard{justify-content:flex-start;overflow:auto;overscroll-behavior:contain}
.progressCabinet .achievementArt,.progressCabinet .achievementArt:has(img){width:82px;height:82px}
.progressCabinet .achievementCards[data-layout=list] .achievementCard{justify-content:flex-start}
.progressCabinet .achievementCard{border-color:#d4bce5;box-shadow:inset 0 2px 0 #fff,0 3px 0 #ceb2df}
.progressCabinet .achievementOwned{background:linear-gradient(145deg,#fffaf3,#e7f3e8);border-color:#b0ceb9;box-shadow:inset 0 2px 0 #fff,0 3px 0 #b4cebb}
.progressCabinet .achievementCard small{color:#5e4b6b;font-size:12px}
.achievementCardCopy .progressBadge{font-size:11px;padding:3px 7px;line-height:1.2}
.achievementCardCopy .progressBadgeMark{font-size:12px}
.achievementCardCopy>.progressBadge+.progressBadge{margin-top:1px}
.achievementDialog .progressBadge{margin:2px auto 6px}
.achievementDialog .achievementRewardHelp{font-size:13px;line-height:1.4;color:#5d4770}
.achievementDialog .achievementDetailDate,.achievementDialog .achievementDetailPath{color:#614d6b}
.achievementDialog [tabindex="-1"]:focus,.goalCard[tabindex="-1"]:focus,.albumBook[tabindex="-1"]:focus{outline:3px solid #6930a5;outline-offset:-3px}
.progressWrap :is(button,summary):focus-visible,.achievementDialog :is(button,summary):focus-visible{outline:3px solid #61308f;outline-offset:3px}
.progressWrap button:disabled{cursor:default}
.progressWrap .primaryBtn,.achievementDialog .primaryBtn{background:linear-gradient(#8d50d1,#6a31b2);color:#fff}
@media(max-width:700px){
 .progressWrap{padding:8px 10px;gap:8px}.progressTabs{gap:5px}
 .progressTabs .softBtn{flex-direction:column;gap:2px;min-height:58px;padding:5px 2px;font-size:12px;border-radius:15px}
 .progressTabs .progressSymbol{width:22px;height:22px;border-radius:7px}
 .progressDoor .progressDoorIcon{width:40px;height:40px;border-radius:13px}
 .progressDoor{min-height:70px}.progressDoor small{font-size:12px;line-height:1.3}
 .progressNext{grid-template-columns:32px minmax(0,1fr);padding:10px;gap:4px 8px}
 .progressNext>.progressNextIcon{width:32px;height:32px;grid-row:1/4}
 .progressNext>.progressBadge{grid-column:2;grid-row:4;justify-self:start}
 .progressNext>.softBtn{grid-column:1/-1;grid-row:5;justify-self:stretch;margin-top:3px}
 .progressNext>.eyebrow{display:block;font-size:10px}.progressNext>strong{font-size:16px}.progressNext>.progressNextCount{font-size:13px}
 .missionsPanel{gap:8px}.missionsPanel .goalCard{grid-template-columns:48px minmax(0,1fr);padding:13px;gap:8px 10px}
 .missionsPanel .goalCard>.bitmapArt{width:48px;height:48px}
 .missionsPanel .goalCard>h3{font-size:22px}.missionsPanel .goalDescription{font-size:14px}
 .missionsPanel .goalCard>.progressBadge:first-of-type{grid-column:1/-1}
 .missionsPanel .goalIntro{font-size:13px}.missionsPanel .goalRelax{font-size:13px}
 .progressCabinet .achievementTabs button{font-size:12px;line-height:1.25;padding:5px}
 .progressCabinet .achievementCard{padding:9px 8px;gap:6px}
 .progressCabinet .achievementCard{justify-content:center}
 .progressCabinet .achievementsHeroArt{display:none}
 .progressCabinet .achievementCard strong{font-size:15px;line-height:1.2}
 .progressCabinet .achievementCardCopy{gap:4px}
 .progressCabinet .achievementPager{gap:8px}
 .progressCabinet .achievementPager span{font-size:12px}
 .progressCabinet .achievementCards[data-layout=list] .achievementCard{padding:9px 12px;gap:12px}
 .progressPanel .albumBook{padding:13px}.progressPanel .albumBook h3{font-size:23px}
 .progressPanel .albumBook>.eyebrow{font-size:10px}.progressPanel .albumBook>p{font-size:13px}
}
@media(max-width:350px){.progressTabs .softBtn{font-size:11px}.progressCabinet .achievementCardCopy .progressBadge{font-size:10px;padding:3px 4px}.progressCabinet .achievementArt,.progressCabinet .achievementArt:has(img){width:66px;height:66px}.progressCabinet .achievementCard strong{font-size:14px}}
@media(max-height:660px){
 .progressTabs .softBtn{flex-direction:row;min-height:44px;gap:4px}.progressTabs .progressSymbol{width:18px;height:18px}
 .progressOverview{flex-shrink:1;overflow:auto}.progressNext{grid-template-columns:28px minmax(0,1fr) auto;gap:3px 6px;padding:8px}
 .progressNext>.progressNextIcon{width:28px;height:28px}.progressNext>.progressBadge{grid-column:2;grid-row:4;font-size:10px}
 .progressNext>.softBtn{grid-column:3;grid-row:1/5;min-height:44px;padding:6px;font-size:11px;margin:0}.progressNext>.eyebrow{font-size:10px}
 .progressDoor{min-height:62px;padding:8px 10px}.progressDoor small{font-size:12px}.progressDoor strong{font-size:16px}
 .missionsPanel .goalCard{padding:10px;gap:7px}.missionsPanel .goalCard>.bitmapArt{width:44px;height:44px}
 .progressCabinet .achievementCard{overflow:auto;overscroll-behavior:contain;justify-content:flex-start}
 .progressCabinet .achievementArt,.progressCabinet .achievementArt:has(img){width:58px;height:58px}
 .progressCabinet .achievementCardCopy{flex-shrink:0}.progressCabinet .achievementCard strong{font-size:14px}
}
@media(prefers-reduced-motion:reduce){.progressWrap *, .achievementDialog *{animation:none!important;transition:none!important}}
html.reduced-motion .progressWrap *,html.reduced-motion .achievementDialog *,.progressCabinet[data-still=true] *{animation:none!important;transition:none!important}
/* A short viewport gets fewer, wider cards rather than clipped art or tiny targets. */
.progressCabinet .achievementCards[data-layout=wall] .achievementArt,.progressCabinet .achievementCards[data-layout=wall] .achievementArt:has(img){width:82px;height:82px}
.progressCabinet .achievementCards[data-compact=true] .achievementCard{flex-direction:row;text-align:left;justify-content:flex-start;align-items:center;padding:6px 10px;gap:10px}
.progressCabinet .achievementCards[data-compact=true] .achievementArt,.progressCabinet .achievementCards[data-compact=true] .achievementArt:has(img){width:44px;height:44px}
.progressCabinet .achievementCards[data-compact=true] .achievementCardCopy{align-items:flex-start;align-self:flex-start;gap:3px;padding-right:16px;flex:1;min-width:0}
.progressCabinet .achievementCards[data-compact=true] .progressBadge{align-self:flex-start;font-size:11px}
@media(max-height:800px){
 .progressCabinet .achievementCards[data-layout=wall] .achievementArt,.progressCabinet .achievementCards[data-layout=wall] .achievementArt:has(img){width:56px;height:56px}
 .progressCabinet .achievementCards[data-layout=wall] .achievementCard{padding:8px;gap:4px;justify-content:flex-start}
 .progressCabinet .achievementCards[data-compact=true] .achievementCard{padding:6px 10px;gap:10px;align-items:center}
 .progressCabinet .achievementCards[data-compact=true] .achievementArt,.progressCabinet .achievementCards[data-compact=true] .achievementArt:has(img){width:40px;height:40px}
}
@media(max-height:500px){
 .progressWrap{padding:6px 12px;gap:5px}.progressHeader{min-height:44px}.progressHeader h1{font-size:22px}
 .progressCabinet{overflow:auto;overscroll-behavior:contain;scrollbar-width:thin}
 .progressCabinet .achievementsWrap{height:auto;min-height:355px;gap:6px}
 .progressCabinet .achievementPanel{min-height:116px}
 .progressCabinet .achievementCard{min-height:44px}
}

/* P5.4: an optional, finite example; gameplay keeps the entire table. */
body.playing #screen-play .wholeBoardControl{position:absolute;left:var(--hud-left);bottom:calc(var(--hud-bottom) + 68px)}
body.playing #screen-play #previewBtn .hudLabel{display:flex;flex-direction:column;gap:3px;align-items:flex-start}
body.playing #screen-play .previewHold{font:800 10px/1 Nunito,sans-serif;letter-spacing:.06em;text-transform:uppercase;opacity:.9}
body.playing #screen-play #hintBtn .hudLabel{display:inline}
body.playing #screen-play .playGuide{position:absolute;top:calc(var(--hud-top) + 98px);left:50%;translate:-50% 0;width:min(400px,calc(100% - 24px));color:#372451;pointer-events:none;font:800 13px/1.4 Nunito,sans-serif}
.playGuide[hidden],.playGuideDemo[hidden],#playGuideProgress[hidden]{display:none!important}
.playGuidePrompt{display:flex;align-items:center;gap:8px;padding:5px 6px 5px 14px;border:1px solid #e2cfe5;border-radius:18px;background:#fffaf1f5;box-shadow:0 3px 0 #c9b4c3,0 6px 16px #34213f20}
.playGuidePrompt p{flex:1;min-width:0;margin:0;font-size:13px;line-height:1.3}
.playGuidePrompt button{flex:none;min-height:44px;border:0;border-radius:13px;background:#eee0fd;color:#62319c;padding:0 10px;font:900 12px/1.2 Nunito,sans-serif;pointer-events:auto;touch-action:manipulation;cursor:pointer}
.playGuidePrompt #playGuideDismiss{width:44px;padding:0;background:none;font-size:24px;color:#716080}
.playGuidePrompt button:focus-visible{outline:3px solid #7e32dc;outline-offset:2px}
.playGuideDemo{margin:8px 4px 0;padding:12px 18px;max-height:calc(100dvh - 260px);overflow:auto;overscroll-behavior:contain;pointer-events:auto;border:1px solid #e2cfe5;border-radius:18px;background:#fffcf6;box-shadow:0 5px 18px #34213f25}
.playGuideDemo p{margin:7px 0;font-size:13px;line-height:1.45}
.playGuideDemo #playGuideGestures{color:#624d7b}
.playGuideDemo .playGuideTools{border-top:1px dashed #d7c1e7;padding-top:8px;font-size:12px;color:#624d7b}
.playGuideDrawing{display:block;width:min(230px,100%);height:106px;margin:auto;overflow:visible}
.playGuideSpark{opacity:.8}
.playGuideDemo[data-animate=true] .playGuideLeft{animation:guideJoinLeft 1.7s cubic-bezier(.22,.68,.24,1) both}
.playGuideDemo[data-animate=true] .playGuideRight{animation:guideJoinRight 1.7s cubic-bezier(.22,.68,.24,1) both}
.playGuideDemo[data-animate=true] .playGuideSpark{animation:guideJoinSpark 1.7s ease-out both}
@keyframes guideJoinLeft{0%,25%{transform:translateX(-30px) rotate(-6deg);transform-origin:90px 58px}72%,100%{transform:translateX(0) rotate(0)}}
@keyframes guideJoinRight{0%,25%{transform:translateX(30px) rotate(6deg);transform-origin:162px 58px}72%,100%{transform:translateX(0) rotate(0)}}
@keyframes guideJoinSpark{0%,70%{opacity:0}80%{opacity:1}100%{opacity:.8}}
body.playing #screen-play.table-active .playGuide{visibility:hidden}
.playGuide[data-quiet=true] .playGuideDrawing g{animation:none!important}
@media(hover:none) and (pointer:coarse){body.playing #screen-play .wholeBoardControl{bottom:var(--hud-bottom)}}
@media(max-width:700px){
 body.playing #screen-play .wholeBoardLabel{display:none}
 body.playing #screen-play .wholeBoardControl{width:46px;padding:0}
 body.playing #screen-play .playGuide{top:calc(var(--hud-top) + 86px);width:min(360px,calc(100% - 16px))}
 .playGuidePrompt{gap:3px;padding-left:10px}.playGuidePrompt p{font-size:12px}.playGuidePrompt button{font-size:11px;padding-inline:8px}
}
@media(max-height:450px){
 body.playing #screen-play .playGuide{top:calc(var(--hud-top) + 86px);width:min(440px,calc(100% - 160px))}
 .playGuideDemo{max-height:calc(100dvh - 220px);padding:8px 14px}.playGuideDrawing{height:70px}
}
@media(max-width:350px){body.playing #screen-play #hintBtn .hudLabel{display:none}}
@media(prefers-reduced-motion:reduce){.playGuideDrawing g{animation:none!important}}
html.reduced-motion .playGuideDrawing g{animation:none!important}

/* P5.5: a durable-save receipt, with a persistent warning only on storage failure. */
#playSaveStatus[hidden],.puzzleSaveWarning[hidden]{display:none!important}
body.playing #screen-play .scPlayReceipt{max-width:calc(100% - var(--hud-left) - var(--hud-right));flex-wrap:wrap}
body.playing #screen-play #playSaveStatus{font-weight:900;color:#326855;white-space:nowrap}
body.playing #screen-play #playSaveStatus[data-state=saving],body.playing #screen-play #playSaveStatus[data-state=syncing]{color:#665379}
body.playing #screen-play #playSaveStatus[data-state=unsafe]{color:#974626}
.puzzleSaveWarning{display:flex;align-items:center;gap:12px;padding:10px 14px;border:1px solid #d8a664;border-radius:16px;background:#fff3d9;color:#693f22;box-shadow:0 3px 0 #d9c0a4;font:800 13px/1.4 Nunito,sans-serif}
.puzzleSaveWarning p{flex:1;margin:0}.puzzleSaveWarning .softBtn{flex:none;min-height:44px;padding:8px 12px;font-size:12px}
body.playing #screen-play #playSaveWarning{position:absolute;top:calc(var(--hud-top) + 98px);left:50%;translate:-50% 0;width:min(440px,calc(100% - 24px));pointer-events:auto}
body.jv3[data-ui-theme=sticker-club] #homeSaveWarning{grid-column:1/-1;order:5;margin:4px 0 0}
#pauseSaveStatus{font-size:14px;line-height:1.5;max-width:400px;margin:0 0 16px;color:inherit}
@media(max-width:350px){body.playing #screen-play .scPlayReceipt{font-size:9px;gap:4px}body.playing #screen-play .scPlayReceipt>span{padding-inline:4px}.puzzleSaveWarning{gap:6px;padding:9px;font-size:12px}}

/* P5.6: picture first, one next-picture invitation; deeper facts stay available. */
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody{gap:10px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody h1{font-size:clamp(28px,4vw,42px);margin:8px 0 0}
.finishPictureName{font:800 16px/1.3 Nunito,sans-serif;color:#6b577a;margin:7px 0 0;overflow-wrap:anywhere}
.finishPictureName[hidden],.finishRecord[hidden],.finishDiscoveries[hidden]{display:none!important}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultGrid{margin:0 0 10px;gap:8px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultBox{padding:7px 10px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultBox b{font-size:22px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] #puzzleResult{display:block;margin:7px 0;border:0;background:none;padding:0;box-shadow:none}
#screen-complete[data-finish=simple] #puzzleResult>.completionRewardArt,#screen-complete[data-finish=simple] #puzzleResult>.rewardTrophy{display:none}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultEarned{padding:10px;background:#f3eaff;border:1px dashed #ccb7e4}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultEarned h3{font-size:13px;padding:0;margin:0 0 7px}
.finishRecord{color:#6740a2;background:#f0e4ff;padding:8px 11px;border-radius:9px;font:900 14px/1.35 Nunito,sans-serif;margin:8px 0}
.finishPanels{flex:1 1 0;min-width:0;min-height:0;display:flex;flex-direction:column}
.finishDiscoveries{display:inline-block;margin-inline-start:.7em;font:750 12px/1.4 Nunito,sans-serif;color:#6c507f}
.finishDetails{flex:none;min-width:0;border-top:1px dashed #d6bfdf}
.finishDetails[open]{max-height:max(44px,65%);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}
.finishDetails>summary{position:sticky;top:0;z-index:1;min-height:44px;display:list-item;padding:12px 8px;background:var(--sc-paper,#fffcf6);cursor:pointer;font:900 13px/1.4 Nunito,sans-serif;color:#654087}
.finishDetails>summary:focus-visible{outline:3px solid #8c42dd;outline-offset:-2px;border-radius:7px}
.finishDetailActions{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
.finishDetailActions>button{min-height:44px;font-size:12px}
#finishRewardDetails>.resultDiscoveries>summary{display:none}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions{gap:8px;align-items:center}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions>.softBtn{flex:1;min-height:44px;font-size:12px;padding:8px 10px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .nextPuzzleCard{flex-basis:100%;min-height:84px;padding:11px 12px}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions #nextPuzzleBtn:not([hidden]){display:flex}
body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .nextPuzzleCopy strong{font-size:17px;overflow-wrap:anywhere}
#screen-complete .nextPuzzleArrow{display:flex;align-items:center;gap:7px;flex:none;font-size:19px}
#screen-complete .nextPuzzleArrow b{font:900 13px/1 Nunito,sans-serif}
#screen-complete[data-finish=simple] .nextPuzzleArrow{width:auto;min-width:62px;height:38px;padding:0 9px;border-radius:12px}
#screen-complete .completeActions:has(#nextPuzzleBtn[hidden]) #chooseNextPuzzle{color:#fff;background:linear-gradient(#a147f1,#7622cb);border-color:#b574ed}
/* The postcard column can carry the title, leaving the right column for the full result. */
@media(min-width:701px) and (min-height:561px){
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeCard{grid-template-rows:auto minmax(0,1fr) auto}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody{display:contents}
 #screen-complete[data-finish=simple] .scResultHeading{grid-area:1/1}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeImage{grid-area:2/1/4/2;max-height:100%}
 #screen-complete[data-finish=simple] .finishPanels{grid-area:1/2/3/3}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions{grid-area:3/2}
 #screen-complete[data-finish=simple] .nextPuzzleStatus{grid-column:2}
}
@media(max-width:700px){
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeCard{gap:10px;padding:12px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeImage{height:clamp(90px,18dvh,145px);width:min(90%,260px)}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody{gap:6px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody h1{font-size:28px;margin-top:4px}
 .finishPictureName{font-size:13px;margin:4px 0 0;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .nextPuzzleCard{min-height:72px;padding:8px 10px;gap:8px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .nextPuzzleCopy strong{font-size:14px}
 #screen-complete[data-finish=simple] .nextPuzzleThumb{width:47px;height:43px;flex:none}
 #screen-complete[data-finish=simple] .nextPuzzleArrow b{display:none}
 #screen-complete[data-finish=simple] .nextPuzzleArrow{width:30px;min-width:30px;height:30px;padding:0}
}
@media(max-height:560px) and (orientation:landscape){
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeCard{display:grid;grid-template-columns:minmax(100px,.6fr) minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto;padding:10px;gap:14px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeImage{width:100%;height:auto;max-height:100%;grid-area:2/1;align-self:center}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody{display:contents}
 #screen-complete[data-finish=simple] .scResultHeading{grid-area:1/1}
 #screen-complete[data-finish=simple] .finishPanels{grid-area:1/2/3/3}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions{grid-column:1/-1;display:grid;grid-template-columns:minmax(0,2fr) repeat(2,minmax(0,1fr))}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions:has(#nextPuzzleBtn[hidden]){grid-template-columns:repeat(2,minmax(0,1fr))}
 #screen-complete[data-finish=simple] .nextPuzzleStatus{grid-column:1/-1}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody h1{font-size:25px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .nextPuzzleCard{min-height:62px}
}
/* On portrait phones the finished postcard and heading share a row. */
@media(max-width:700px) and (min-height:561px), (max-width:700px) and (orientation:portrait){
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeCard{display:grid;grid-template-columns:clamp(84px,25vw,110px) minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto;gap:10px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody{display:contents}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeImage{grid-area:1/1;width:100%;height:auto;border-width:4px;border-bottom-width:14px}
 #screen-complete[data-finish=simple] .scResultHeading{grid-area:1/2;align-self:center}
 #screen-complete[data-finish=simple] .finishPanels{grid-area:2/1/3/3}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeActions{grid-area:3/1/4/3}
 #screen-complete[data-finish=simple] .nextPuzzleStatus{grid-column:1/-1}
}
@media(max-height:450px){
 #screen-complete[data-finish=simple] .scResultHeading .eyebrow{display:none}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .completeBody h1{font-size:23px;margin:0}
 #screen-complete[data-finish=simple] .finishPictureName{font-size:12px;margin:3px 0 0;-webkit-line-clamp:1}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultGrid{display:flex;gap:18px;margin:0 0 5px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultBox{display:flex;align-items:center;gap:6px;padding:0;border:0;background:none}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultBox small{font-size:10px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultBox b{font-size:16px}
 #screen-complete[data-finish=simple] .finishRecord{font-size:11px;margin:4px 0;padding:3px 7px}
 body[data-ui-theme=sticker-club] #screen-complete[data-finish=simple] .resultSaveStatus{font-size:10px;margin:3px 0 5px}
}
