/* Home board only. Game, reader, vocabulary and progress layouts stay owned by their existing stylesheets. */
body:has(#homeScreen.active) {
  background: radial-gradient(ellipse at 10% 0, #e4f4ef, transparent 55%), radial-gradient(ellipse at 100% 100%, #f5e9d7, transparent 55%), #faf8f2;
}
body:has(#homeScreen.active) .sky { display:none; }
body:has(#homeScreen.active) .app { max-width:620px; padding: max(12px,env(safe-area-inset-top)) 18px max(12px,env(safe-area-inset-bottom)); }
body:has(#homeScreen.active) .topbar { flex:0 0 48px; height:48px; grid-template-columns:44px minmax(0,1fr) 44px; }
body:has(#homeScreen.active) .brand { background:none; box-shadow:none; padding:0; gap:5px; font-size:13px; white-space:nowrap; color:#52645c; }
body:has(#homeScreen.active) .brand-icon { font-size:20px; }
body:has(#homeScreen.active) .icon-button { width:44px; height:44px; box-shadow:0 2px 8px #314d3710; border:1px solid #dedfd5; }
#homeScreen.active { display:flex; flex-direction:column; gap:0; padding:0 2px; }
#homeScreen .hero { flex:0 0 auto; padding:18px 0 20px; }
#homeScreen .hero-friends { display:none; }
#homeScreen .hero h1 { margin:0; font-size:clamp(28px,4.4vh,38px); line-height:1.15; text-shadow:none; letter-spacing:-.02em; color:#284e46; }
#homeScreen .hero h1 span { font-size:.78em; color:#6c7d70; font-weight:600; letter-spacing:0; }
#homeScreen #numberChoices { display:flex; flex-direction:column; flex:1 1 0; min-height:0; gap:12px; padding:0 0 4px; }
#homeScreen .game-card { display:flex; flex-direction:row; flex:1 1 0; min-height:0; width:100%; max-height:154px; margin:0; padding:12px 18px; gap:18px; border:1px solid #ffffffb3; border-radius:24px; box-shadow:0 4px 0 #3047350a,0 8px 20px #30473506; text-decoration:none; color:#29453e; text-align:start; justify-content:flex-start; transition:transform .15s,box-shadow .15s; }
#homeScreen .game-card.recognize { background:#f8dfaa; }
#homeScreen .game-card.count { background:#cce9e9; }
#homeScreen .game-card.vocab { background:#e0ddf4; }
#homeScreen .game-card .card-picture { flex:0 0 72px; width:72px; height:72px; min-height:0; display:grid; place-items:center; padding:0; letter-spacing:0; }
#homeScreen .card-svg { display:block; width:72px; height:72px; }
#homeScreen .card-text { display:flex; flex-direction:column; gap:5px; min-width:0; align-self:center; }
#homeScreen .card-text strong { margin:0; font-size:clamp(23px,6.2vw,30px); line-height:1.16; font-weight:800; text-align:right; }
#homeScreen .card-text > span { font-size:clamp(17px,4.5vw,21px); line-height:1.2; color:#435b54; font-weight:600; }
#homeScreen .reading-home-link { flex:0 0 auto; width:100%; margin:14px 0 0; min-height:76px; padding:12px 18px; gap:15px; border:1px solid #d7dfd0; border-radius:20px; background:#f0f3e9; box-shadow:none; justify-content:flex-start; color:#385744; }
#homeScreen .reading-icon { flex:0 0 48px; }
#homeScreen .reading-icon svg { width:48px; height:48px; }
#homeScreen .reading-label { display:flex; flex-direction:column; gap:4px; text-align:start; min-width:0; }
#homeScreen .reading-label strong { font-size:18px; line-height:1.2; }
#homeScreen .reading-label > span { font-size:14px; color:#5b705e; line-height:1.2; }
#homeScreen #progressButton { display:none; }
#homeScreen .grownup-link { flex:0 0 auto; min-height:44px; padding:10px 12px; margin:8px auto 0; background:none; box-shadow:none; color:#617167; font-size:13px; font-weight:600; }
#homeScreen a:focus-visible,#homeScreen button:focus-visible { outline:3px solid #375c50; outline-offset:3px; }
#homeScreen .game-card:active,#homeScreen .reading-home-link:active { transform:translateY(2px); box-shadow:none; }
@media(max-height:700px) {
 #homeScreen .hero { padding:8px 0 14px; }
 #homeScreen #numberChoices { gap:10px; }
 #homeScreen .game-card { padding:8px 14px; gap:14px; border-radius:21px; }
 #homeScreen .card-picture,#homeScreen .game-card .card-picture { flex-basis:60px; width:60px; height:60px; }
 #homeScreen .card-svg { width:60px; height:60px; }
 #homeScreen .reading-home-link { min-height:68px; margin-top:12px; padding:9px 14px; gap:12px; }
}
@media(max-width:350px) {
 body:has(#homeScreen.active) .app { padding-left:14px; padding-right:14px; }
 body:has(#homeScreen.active) .brand { font-size:11px; }
 #homeScreen .hero h1 { font-size:28px; }
 #homeScreen .card-text strong { font-size:23px; }
 #homeScreen .card-text > span { font-size:17px; }
 #homeScreen .reading-label strong { font-size:16px; }
 #homeScreen .reading-label > span { font-size:13px; }
}
@media(min-width:800px) and (min-height:700px) {
 #homeScreen .hero { padding:24px 0 28px; }
 #homeScreen #numberChoices { gap:16px; }
}
@media(prefers-reduced-motion:reduce) { #homeScreen.active,#homeScreen .game-card { animation:none; transition:none; } }

/* Vector home chrome stays legible even when the platform has no emoji font. */
body:has(#homeScreen.active) .brand-icon { display:flex; }
body:has(#homeScreen.active) #soundButton { font-size:0; display:grid; place-items:center; }
body:has(#homeScreen.active) #soundButton::after { content:""; width:22px; height:22px; background:center/contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2352695c' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 4 5 9H2v6h3l6 5Z M15 8q4 4 0 8 M18 4q8 8 0 16'/%3E%3C/svg%3E"); }
body:has(#homeScreen.active) #soundButton[aria-label*="Silencio"]::after { background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2352695c' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 4 5 9H2v6h3l6 5Z M16 9l6 6 M22 9l-6 6'/%3E%3C/svg%3E"); }
