/* Home-only gallery. Keep the preserved logo and two tappable frames at every width. */
body.mumin-layout[data-view=games]:has(.gallery-home){--home-cream:#f3e7cf;--home-ink:#352619;color:var(--home-cream)}
body.mumin-layout[data-view=games]:has(.gallery-home) .app{position:relative;display:flex;flex-direction:column;min-height:100svh;width:100%;max-width:none;padding:0;background:transparent}
body.mumin-layout[data-view=games]:has(.gallery-home) .app>header{display:none!important}
body.mumin-layout[data-view=games]:has(.gallery-home) #main{display:block;flex:1;width:100%;max-width:940px;margin:0 auto;padding:100px 32px 40px;background:transparent}
body.mumin-layout[data-view=games] #main .gallery-home{display:flex;flex-direction:column;align-items:center;width:100%;max-width:none;margin:0;gap:26px;text-align:center}
.gallery-home-heading{display:flex;flex-direction:column;align-items:center;gap:12px;width:100%;max-width:100%;color:var(--home-cream);text-shadow:0 2px 4px #1c110d66}
body.mumin-layout #main .gallery-home-heading h1{width:100%;font-size:0;line-height:0;margin:0}
.gallery-home-logo{display:block;width:340px;max-width:100%;height:auto;margin:0 auto}
.gallery-home-heading p{font:400 clamp(17px,2.5vw,24px)/1.45 Georgia,'Times New Roman',serif;margin:0;color:var(--home-cream);text-wrap:balance}
.gallery-home-games{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch;gap:22px;width:100%;max-width:620px}
body.mumin-layout #main :is(.gallery-home .gallery-home-game,.gallery-choice-card){position:relative;isolation:isolate;display:flex;width:100%;min-width:0;min-height:44px;margin:0;padding:clamp(12px,2.8vw,28px);border:0;border-radius:0;box-shadow:none;color:var(--home-ink,#352619);filter:drop-shadow(0 8px 9px #120b0844);background:transparent url('../assets/home-gallery/wood-frame.svg') center/100% 100% no-repeat!important;touch-action:manipulation;text-align:center}
.gallery-home-game:before,.gallery-choice-card:before{content:'';position:absolute;inset:6.7% 8.75%;z-index:-1;background:#ead9b6 url('../assets/home-gallery/parchment-panel.svg') center/100% 100% no-repeat}
.gallery-home-paper,.gallery-choice-paper{display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;min-width:0;padding:0 0 8px}
.gallery-home-game-art{display:block;flex:none;width:100%;height:auto;aspect-ratio:3/2;object-fit:contain;margin:0;pointer-events:none}
body.mumin-layout #main .gallery-home-game-title{display:block;font:600 clamp(16px,3.2vw,30px)/1.2 Georgia,'Times New Roman',serif;color:var(--home-ink);margin:8px 0 0;letter-spacing:-.02em;text-wrap:balance;overflow-wrap:normal}
.gallery-home-game-title>span{display:block}
body.mumin-layout #main :is(.gallery-home .gallery-home-game,.gallery-choice-card):focus-visible{outline:3px solid var(--home-cream,#f3e7cf);outline-offset:5px}
.gallery-home-meta{display:grid;justify-items:center;gap:14px;width:100%;margin:0;color:var(--home-cream)}
body.mumin-layout #main .gallery-home .quest-home-player{display:flex;align-items:center;justify-content:center;gap:9px;min-height:44px;max-width:100%;margin:0;padding:4px 12px;border:1px solid #c6ac7944;border-radius:24px;color:var(--home-cream);background:#2c211b88}
.gallery-home .quest-home-avatar{width:32px;height:32px;font-size:21px;border-color:#c6ac7966;background:#3b3024}
.gallery-home .quest-home-player-copy{text-align:start;gap:0;max-width:200px;min-width:0}
.gallery-home .quest-home-player-copy strong{font-size:14px;line-height:1.4;overflow-wrap:anywhere}
.gallery-home .game-version{color:#ddcdb0;margin:0;font-size:11px}
html[lang=ar] .gallery-home-heading p,html[lang=ar] body.mumin-layout #main .gallery-home-game-title{font-family:var(--arabic-font,Arial,sans-serif);letter-spacing:normal}
html[lang=ar] body.mumin-layout #main .gallery-home-game-title{font-size:clamp(16px,3vw,29px);line-height:1.6}
@media(hover:hover){body.mumin-layout #main :is(.gallery-home .gallery-home-game,.gallery-choice-card):hover{filter:brightness(1.08)}}
@media(max-width:700px){body.mumin-layout[data-view=games]:has(.gallery-home) #main{padding:88px 20px 30px}.gallery-home-logo{width:280px}.gallery-home-games{gap:14px;max-width:560px}}
@media(max-width:540px){body.mumin-layout[data-view=games]:has(.gallery-home) #main{padding:82px 14px 28px}body.mumin-layout[data-view=games] #main .gallery-home{gap:20px}.gallery-home-heading{gap:10px}.gallery-home-logo{width:250px}.gallery-home-games{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.gallery-home-paper,.gallery-choice-paper{padding-bottom:5px}body.mumin-layout #main .gallery-home-game-title{font-size:clamp(16px,4.4vw,21px);margin-top:6px}html[lang=ar] body.mumin-layout #main .gallery-home-game-title{font-size:clamp(15px,4.2vw,20px)}}
@media(max-width:360px){.gallery-home-logo{width:230px}.gallery-home-games{gap:10px}.gallery-home-heading p{font-size:16px}}
@media(prefers-reduced-motion:reduce){.gallery-home *{scroll-behavior:auto;transition:none}}
