#gameSelectScreen[hidden],#cleanerScreen[hidden],#arcadeNativeTest[hidden] { display:none; }
#gameSelectScreen,#cleanerScreen { position:absolute; inset:0; z-index:40; color:#244e59; font-family:"Noto Sans KR","Malgun Gothic",system-ui,sans-serif; }
#gameSelectScreen { overflow-y:auto; overscroll-behavior:contain; background:radial-gradient(ellipse at 15% 12%,#fff4be 0,transparent 40%),radial-gradient(ellipse at 95% 100%,#a8dcca 0,transparent 48%),linear-gradient(140deg,#e6f4e9,#b8dce3); }
.arcade-wrap { width:min(1040px,100%); min-height:100%; margin:auto; padding:max(14px,env(safe-area-inset-top)) max(18px,env(safe-area-inset-right)) max(16px,env(safe-area-inset-bottom)) max(18px,env(safe-area-inset-left)); display:flex; flex-direction:column; justify-content:center; gap:14px; }
.arcade-header { display:flex; flex-wrap:wrap; align-items:center; gap:10px; min-height:44px; }
.arcade-brand { display:flex; align-items:center; gap:9px; color:#285567; text-decoration:none; max-width:100%; overflow-wrap:anywhere; }
.arcade-brand img { border-radius:12px; width:44px; height:44px; }
.arcade-brand b { font-size:1rem; line-height:1.15; letter-spacing:.06em; }
.arcade-brand small { display:block; font-size:.75rem; margin-top:4px; }
#gameSelectScreen #lobbyLanguageControl { margin-left:auto; color:#254e5b; flex-shrink:0; }
#gameSelectScreen #lobbyLanguageControl button { min-width:44px; min-height:44px; font-size:.875rem; color:#254e5b; }
#arcadeNativeTest { background:#315665; color:#fff5ce; padding:4px 7px; border-radius:7px; font-size:.75rem; font-weight:800; }
.arcade-heading { text-align:center; }
.arcade-heading p { margin:0 0 6px; font-size:.875rem; color:#507a7d; }
.arcade-heading h1 { font-size:clamp(1.35rem,3vw,2.25rem); line-height:1.3; margin:0; font-weight:900; word-break:keep-all; overflow-wrap:anywhere; }
.arcade-choices { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:22px; }
.arcade-card { overflow:hidden; border:3px solid #ffffffdb; border-radius:24px; box-shadow:0 8px 0 #568d9633,0 18px 35px #476b7a16; background:#fff9ea; text-align:left; padding:0; color:#244e59; cursor:pointer; display:flex; flex-direction:column; min-width:0; }
.arcade-card:focus-visible,#cleanerScreen button:focus-visible,#arcadeReturnBtn:focus-visible { outline:3px solid #d86e57; outline-offset:3px; }
.arcade-card-picture { position:relative; background:#95cfbf; height:clamp(110px,25vh,260px); overflow:hidden; }
.arcade-card-picture img,.arcade-card-picture canvas { width:100%; height:100%; object-fit:cover; display:block; }
.arcade-card-tag { position:absolute; bottom:10px; left:10px; padding:6px 10px; border-radius:20px; background:#fff9e8ec; font-size:.875rem; font-weight:800; }
.arcade-card-copy { padding:18px 20px; flex:1; display:flex; flex-direction:column; }
.arcade-card h2 { margin:0 0 6px; font-size:1.5rem; line-height:1.3; font-weight:900; overflow-wrap:anywhere; }
.arcade-card p { font-size:1rem; line-height:1.5; margin:0 0 16px; }
.arcade-card strong { display:flex; align-items:center; justify-content:center; min-height:44px; padding:9px 14px; border-radius:12px; background:#e28268; color:#fffdf2; font-size:1rem; margin-top:auto; }
.arcade-cleaner strong { background:#267e7b; }
.arcade-footer { display:flex; flex-wrap:wrap; justify-content:space-between; gap:8px 16px; align-items:center; font-size:.875rem; }
.arcade-footer p { margin:0; line-height:1.5; }
.arcade-footer nav { display:flex; flex-wrap:wrap; justify-content:center; gap:14px; }
.arcade-footer a { min-height:44px; display:flex; align-items:center; font-weight:700; text-decoration:underline; }
#arcadeReturnBtn { min-width:44px; min-height:44px; border:1px solid #8dcecd; background:#275765; border-radius:10px; color:#fff5d6; font-size:1.25rem; }
#cleanerScreen { background:#a5d3c2; overflow:hidden; touch-action:none; }
#cleanerCanvas { width:100%; height:100%; display:block; touch-action:none; outline:none; }
.cleaner-hud { position:absolute; top:env(safe-area-inset-top,0px); left:env(safe-area-inset-left,0px); right:env(safe-area-inset-right,0px); padding:4px; display:grid; grid-template-columns:44px minmax(0,1fr) 44px 44px; align-items:start; gap:5px; pointer-events:none; }
.cleaner-hud button { width:44px; height:44px; border:1px solid #fff6de; background:#f9f7e7f0; border-radius:12px; color:#28545c; font-size:1.5rem; pointer-events:auto; box-shadow:0 3px #37655c25; }
.cleaner-status { background:#fff9e9ed; border:1px solid #fffceb; border-radius:12px; padding:4px 10px; max-width:400px; min-width:0; }
.cleaner-status strong { display:block; font-size:.875rem; line-height:1.35; overflow-wrap:anywhere; }
.cleaner-status > div { display:flex; align-items:center; gap:8px; }
.cleaner-status progress { width:min(230px,100%); min-width:20px; height:9px; accent-color:#398d7b; border:0; border-radius:8px; overflow:hidden; }
.cleaner-status progress::-webkit-progress-bar { background:#d7e4d0; border-radius:8px; }
.cleaner-status progress::-webkit-progress-value { background:linear-gradient(90deg,#71c8ad,#e6ca79); border-radius:8px; }
.cleaner-status b { font-size:.875rem; white-space:nowrap; }
.cleaner-hint { position:absolute; bottom:max(7px,env(safe-area-inset-bottom)); left:50%; transform:translateX(-50%); padding:7px 12px; margin:0; width:max-content; max-width:calc(100% - 24px); background:#fff9e6df; color:#3a6466; border-radius:12px; font-size:.875rem; line-height:1.4; text-align:center; pointer-events:none; }
#cleanerDialog { box-sizing:border-box; width:min(640px,calc(100% - 20px)); max-height:calc(100dvh - max(20px,env(safe-area-inset-top)) - env(safe-area-inset-bottom)); overflow-y:auto; overscroll-behavior:contain; background:#fff9e9; color:#28545b; border:3px solid #d7e6c5; border-radius:22px; padding:18px; margin:auto; font-size:1rem; line-height:1.5; box-shadow:0 14px 0 #284b4926; touch-action:pan-y; }
#cleanerDialog::backdrop { background:#21474665; }
#cleanerDialog header { display:flex; align-items:center; gap:10px; margin-bottom:12px; }
#cleanerDialog header > span { font-size:1.5rem; }
#cleanerDialog h2 { margin:0; font-size:1.2rem; line-height:1.3; font-weight:900; overflow-wrap:anywhere; }
#cleanerDialog p { margin:10px 0; }
#cleanerDialog button { min-height:44px; padding:9px 12px; background:#e6eee0; color:#315e63; border:1px solid #c5d8c4; border-radius:11px; font-family:inherit; font-size:.875rem; font-weight:700; line-height:1.4; cursor:pointer; overflow-wrap:anywhere; }
.cleaner-area-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:7px; }
.cleaner-area-grid button { display:flex; flex-direction:column; align-items:center; gap:2px; min-width:0; text-align:center; }
.cleaner-area-grid button > span { font-size:1.5rem; }
.cleaner-area-grid button b { font-size:.875rem; line-height:1.3; }
.cleaner-area-grid small { font-size:.75rem; color:#627f7b; }
#cleanerDialog button[aria-pressed=true] { background:#cce8d6; border:2px solid #439987; }
.cleaner-cars { display:flex; flex-wrap:wrap; gap:6px; border:0; padding:0; margin:12px 0; }
.cleaner-cars legend { font-size:.875rem; font-weight:800; margin-bottom:6px; }
#cleanerDialog .cleaner-cars button { flex:1; min-width:90px; border-left:7px solid var(--car-color); }
.cleaner-cars button span { display:block; font-size:1.25rem; }
.cleaner-dialog-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.cleaner-dialog-actions button { flex:1; min-width:120px; }
#cleanerDialog .cleaner-primary { background:#2f817a; color:#fffbed; border-color:#2f817a; }
.cleaner-options { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.cleaner-small { font-size:.875rem; color:#5c7c78; }
.cleaner-finish-art { font-size:2.6rem; text-align:center; margin:12px 0 0; }
.cleaner-finish-score { display:block; font-size:2.4rem; text-align:center; color:#2f817a; }
@media(max-width:540px) { .arcade-wrap { gap:10px; padding:10px 14px max(10px,env(safe-area-inset-bottom)); } .arcade-choices { gap:12px; grid-template-columns:1fr; } .arcade-card { border-radius:18px; display:grid; grid-template-columns:36% minmax(0,1fr); } .arcade-card-picture { height:100%; min-height:140px; } .arcade-card-tag { display:none; } .arcade-card-copy { padding:12px; } .arcade-card h2 { font-size:1.1875rem; } .arcade-card p { font-size:.875rem; margin-bottom:10px; } .arcade-card strong { font-size:.875rem; padding:7px; } .arcade-footer { justify-content:center; text-align:center; } .arcade-footer p { font-size:.75rem; } .arcade-heading p { display:none; } .cleaner-hint { font-size:.8125rem; } #cleanerDialog { padding:12px; } .cleaner-area-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-height:500px) and (orientation:landscape) { .arcade-wrap { gap:7px; padding-block:5px; } .arcade-header { min-height:40px; } .arcade-brand img { width:36px; height:36px; } .arcade-brand small,.arcade-heading p,.arcade-footer p,.arcade-card p { display:none; } .arcade-heading h1 { font-size:1.125rem; } .arcade-choices { gap:14px; } .arcade-card { border-radius:17px; } .arcade-card-picture { height:clamp(68px,27dvh,160px); } .arcade-card-copy { padding:7px 12px; } .arcade-card h2 { font-size:1.125rem; margin:0 0 5px; } .arcade-card strong { min-height:44px; font-size:.875rem; padding:6px; } .arcade-card-tag { padding:4px 8px; bottom:6px; font-size:.75rem; } .arcade-footer { justify-content:center; } .arcade-footer a { min-height:44px; font-size:.75rem; } #cleanerDialog { width:min(720px,calc(100% - 16px)); padding:10px 14px; } .cleaner-area-grid { grid-template-columns:repeat(3,minmax(0,1fr)); } .cleaner-area-grid button { padding:5px; } .cleaner-area-grid button > span { display:none; } .cleaner-cars button span { display:none; } .cleaner-cars { margin:7px 0; } .cleaner-small { font-size:.8125rem; } .cleaner-finish-art { font-size:1.8rem; margin:0; } .cleaner-finish-score { font-size:1.8rem; } }
@media(prefers-reduced-motion:reduce) { .arcade-card { transition:none; } }
