/* One portrait screen: cast above a four-game illustrated menu. */
#home{
 --tile-radius:18px;
 height:100%;min-height:0;overflow:hidden;
 display:grid;grid-template-rows:44px clamp(82px,13dvh,112px) clamp(88px,16dvh,146px) 20px minmax(0,1fr) 22px;
 gap:6px;padding:max(8px,env(safe-area-inset-top)) 14px max(10px,env(safe-area-inset-bottom));
}
#home .home-top{padding:0 2px;gap:4px;align-items:center;min-width:0}
#home .home-actions{gap:7px}
#home .home-top .icon-button{width:44px;height:40px;border-radius:14px;font-size:23px;box-shadow:0 3px #aabe94,0 5px 10px #193b3433}
#home .tiny-label{font:13px/1.1 'Bible Display';letter-spacing:0;color:#fff3ba;transform:rotate(-6deg);text-shadow:0 2px #985029,1px 0 #985029,-1px 0 #985029;white-space:nowrap;animation:kampung-wiggle 5s ease-in-out infinite;transform-origin:35% 70%}
#home .tiny-label b{display:inline-block;color:#ffdf58;font-weight:400}
#home .brand{min-height:0;margin:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px}
#home .brand>span{font:20px/1.2 'Bible Display';letter-spacing:2px;color:#ffe584;transform:rotate(-3deg);text-shadow:0 2px #7b4024,0 4px #284936;-webkit-text-stroke:.6px #784825!important;paint-order:stroke fill}
#home .brand img.brand-logo{width:min(58%,235px);height:calc(100% - 50px);max-width:75%;min-height:30px;margin:0;object-fit:contain}
#home .brand .creator-credit{font-size:6px;letter-spacing:1px;margin:0;line-height:1.2}
#home .brand p{font:700 13px/1.1 'Bible Futura';margin:3px 0 0;transform:rotate(-2deg);text-shadow:0 2px #244a3b}
#home .video-friends{width:100%;max-width:440px;height:100%;min-height:0;padding:0;gap:0;margin:0 auto;align-items:stretch}
#home .friend-card{height:100%;min-height:0;width:25%;justify-content:end;overflow:visible}
#home .friend-card canvas,#home .friend-card[data-friend=unyil] canvas{height:calc(100% - 16px);width:125%;min-height:0;object-fit:contain;flex:none}
#home .friend-card b{font:clamp(9px,2.6vw,12px)/1.1 'Bible Display';padding:4px 7px;margin-top:-5px;border-radius:10px;letter-spacing:.2px;flex:none}
#home .choose-label{margin:0;font:10px/1 'Bible Display';letter-spacing:1.3px;gap:10px}
#home .choose-label span{width:35px}
#home .games{min-height:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));gap:9px;padding:0 2px 4px}
#home .game-card{grid-column:auto;position:relative;display:block;width:100%;height:100%;min-height:0;padding:0;border:2px solid #ffe5a3;border-radius:var(--tile-radius);box-shadow:0 4px #173b30,0 6px 10px #17352644;text-decoration:none;isolation:isolate}
#home .game-card>img{transform:none;object-fit:cover;object-position:center;filter:brightness(.88) saturate(1.1)}
#home .game-card:after{background:linear-gradient(0deg,#163a32f5 0%,#183629d9 20%,#18382b00 80%)}
#home .parking-card:after{background:linear-gradient(0deg,#513c23fa,#513c23bb 35%,#513c2322 85%)}
#home .music-card:after{background:linear-gradient(0deg,#17224afa,#17224acc 35%,#17224a00 90%)}
#home .game-card .card-chip{top:6px;left:6px;right:auto;font:700 7px/1.1 'Bible Montserrat';padding:3px 5px;border-radius:6px;letter-spacing:.2px;z-index:4}
#home .game-card .card-copy{left:9px;right:30px;bottom:8px;z-index:3}
#home .game-card .card-copy h2{font-size:clamp(13px,3.5vw,18px)!important;line-height:1.13!important;margin:0;text-shadow:0 2px #273d2c,1px 0 #273d2c,-1px 0 #273d2c;letter-spacing:0}
#home .game-card .card-copy p,#home .card-best{display:none}
#home .game-card .play-pill{position:absolute;right:6px;bottom:7px;left:auto;width:24px;height:26px;display:flex;justify-content:center;align-items:center;border-radius:9px;padding:0!important;font-size:0!important;background:linear-gradient(#ffdf6c,#ffbb35);color:#63431d;box-shadow:0 3px #b17522;z-index:4;text-shadow:none}
#home .game-card .card-copy .play-pill{right:-24px;bottom:0}
#home .play-pill b{display:none}
#home .play-pill:after{content:'▶';font:11px 'Bible Futura'}
#home .parking-hero,#home .bridge-hero{width:68px;height:110%;right:2px;bottom:-20%;z-index:1;opacity:.95;background-position:center top}
#home .bridge-hero{width:58px;right:6px;bottom:-24%}
#home .card-kite{right:11px;top:7px;transform:rotate(12deg);font-size:0}
#home .card-kite img{width:64px;height:76px;object-fit:contain}
#home .music-card>img{object-position:50% 35%}
#home .dessert-card{grid-column:1/-1}
#home .dessert-card:after{background:linear-gradient(90deg,#773b32ed,#773b3266 65%,#773b3211)}
#home .dessert-card .card-copy{bottom:16px;right:120px}
#home .dessert-card .card-copy h2{font-size:clamp(15px,4vw,20px)!important}
#home .dessert-card .card-copy .play-pill{display:none}
#home .dessert-card .card-dessert{right:21px;top:4px;bottom:4px;font-size:0;width:100px}
#home .dessert-card .card-dessert img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(0 3px 2px #562e2766)}
#home .home-footer{display:flex;justify-content:space-between;align-items:center;gap:3px;margin:0;font:9px 'Bible Futura';white-space:nowrap}
#home .home-footer>span{font-size:13px}
#home .home-footer button{margin:0;padding:4px 0;font-size:9px;white-space:nowrap}
@keyframes kampung-wiggle{0%,24%,100%{transform:rotate(-6deg) translateY(0)}5%{transform:rotate(-9deg) translateY(-3px) scale(1.035)}10%{transform:rotate(-3deg) translateY(1px) scale(.99)}16%{transform:rotate(-7deg) translateY(-1px)}}
@media(max-height:650px){
 #home{grid-template-rows:40px 78px 86px 17px minmax(0,1fr) 19px;gap:4px;padding-inline:11px}
 #home .brand>span{font-size:17px}
 #home .brand p{font-size:11px;margin-top:1px}
 #home .brand img.brand-logo{height:34px;width:185px}
 #home .games{gap:7px}
 #home .game-card .card-chip{font-size:6px;padding:2px 4px;top:5px;left:5px}
 #home .game-card .card-copy{bottom:6px;left:7px}
 #home .game-card .card-copy h2{font-size:13px!important}
 #home .dessert-card .card-copy{bottom:9px}
 #home .tiny-label{font-size:11px}
 #home .card-kite img{height:59px;width:48px}
 #home .game-card .play-pill{height:23px;width:22px}
}
@media(prefers-reduced-motion:reduce){#home .tiny-label{animation:none}#home .friend-card.hello b{animation:none}}

/* Four games, reading order: bridge, crossing, parking, kentongan. */
#home .crossing-card:after{background:linear-gradient(0deg,#3b5c43fa,#3b5c4366 55%,transparent)}
#home .crossing-card>img{object-position:50% 58%;filter:saturate(1.1)}
#home .crossing-card .card-chip{background:#ffe897;color:#725221}
#home .game-card .card-copy h2{font-size:clamp(16px,4.2vw,22px)!important}
#home .music-card>img{object-position:50% 25%}
#home .bridge-hero{height:95%;bottom:-9%;width:72px}
#home .parking-hero{height:94%;bottom:-8%;width:77px}
@media(max-height:650px){#home .game-card .card-copy h2{font-size:15px!important}#home .parking-hero,#home .bridge-hero{width:59px}}
