/* Approved direct repair: 4096x2182, lossless source-preserving derivative.
 * Source hash and exact 152x40 historical-version removal rectangle are recorded
 * in recovery-20261006-evidence/title-recovery/asset-provenance.json.
 * Coordinates below use its 2048x1091 reference space. Native buttons retain the
 * accessible labels and handlers; the visible corrected labels are source pixels.
 */
@font-face { font-family:'Title Version'; src:url('../assets/img/ui/title-version-DM_Sans.ttf') format('truetype'); font-weight:100 1000; font-display:swap; }
#app:has(#title.active) { max-width:min(100vw,177.7778dvh); max-height:min(100dvh,56.25vw); }
body:has(#title.active) #settingsGearBtn { visibility:hidden; }
#title.screen.active {
 --title-art-top:calc((100cqh - 53.271484375cqw) / 2);
 position:relative; padding:0 !important; overflow:auto !important;
 background:url('../assets/img/ui/title-direct-repair.webp') center / contain no-repeat,#071423 !important;
}
#title .title-brand { position:absolute; inset:0; display:block; width:100% !important; height:100%; margin:0 !important; padding:0; pointer-events:none; }
#title .title-logo { position:absolute; display:block; left:33.3984375cqw; top:calc(var(--title-art-top) + 2.9296875cqw); width:33.3984375cqw; height:22.36328125cqw; background:none; }
#title .title-body { position:absolute; inset:0; display:block; width:100% !important; min-width:0; height:100%; margin:0 !important; padding:0; transform:none; pointer-events:none; }
#title .title-menu { position:absolute; inset:0; display:block; width:100%; min-width:0; padding:0 !important; border:0; border-radius:0; background:none; box-shadow:none; }
#title .title-menu::before,#title .title-menu::after { content:none; }
#title .title-menu .menu-btn {
 position:absolute; left:34.5703125cqw; width:29.78515625cqw !important; height:5.712890625cqw; min-height:44px;
 margin:0 !important; padding:0 !important; border:0; border-radius:12%; background:transparent; box-shadow:none;
 pointer-events:auto; touch-action:manipulation; transition:box-shadow .15s; color:#fff1ad;
}
#title #btnLobby { top:calc(var(--title-art-top) + 25.29296875cqw); height:6.8359375cqw; }
#title #btnShop { top:calc(var(--title-art-top) + 32.71484375cqw); }
#title #btnSettings { top:calc(var(--title-art-top) + 38.96484375cqw); }
#title #btnTitleQuit { top:calc(var(--title-art-top) + 45.21484375cqw); }
#title .menu-art { display:none; }
#title .menu-label { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; border:0; }
#title .title-menu .menu-btn:focus-visible { outline:2px solid #ffe5a4; outline-offset:2px; }
#title .title-menu .menu-btn:is(:active,.is-pressed) { box-shadow:inset 0 0 0 3px #ffe5a4, inset 0 0 35px #e4c36a66; transform:none; filter:none; }
#title .title-menu .menu-btn.is-pointer-hovered:where(:not(:disabled)) { box-shadow:inset 0 0 18px #ffe5a477; }
#title #titleMenu #buildVer {
 position:absolute !important; left:59.7900390625cqw; top:calc(var(--title-art-top) + 51.5380859375cqw) !important;
 right:auto !important; bottom:auto !important; width:4.638671875cqw; height:1.5380859375cqw; display:flex; align-items:center; justify-content:center;
 margin:0 !important; padding:0; border:0; background:none; border-radius:0;
 font-family:'Title Version',sans-serif; font-size:.6982421875cqw !important; font-weight:700; line-height:1; letter-spacing:.08em;
}
/* The repaired screenshot's measured source centers, inside the contained art.
 * Only title geometry changes; the shared six-tribe renderer is untouched. */
#title .title-elements .title-element { width:6.6cqw; height:6.6cqw; }
#title .title-element:has([data-element="dark"]) { left:30.6640625cqw; top:calc(var(--title-art-top) + 8.3984375cqw); }
#title .title-element:has([data-element="fire"]) { left:69.43359375cqw; top:calc(var(--title-art-top) + 8.3984375cqw); }
#title .title-element:has([data-element="water"]) { left:23.388671875cqw; top:calc(var(--title-art-top) + 21.19140625cqw); }
#title .title-element:has([data-element="wind"]) { left:76.611328125cqw; top:calc(var(--title-art-top) + 21.19140625cqw); }
#title .title-element:has([data-element="earth"]) { left:25.830078125cqw; top:calc(var(--title-art-top) + 33.837890625cqw); }
#title .title-element:has([data-element="light"]) { left:74.169921875cqw; top:calc(var(--title-art-top) + 33.837890625cqw); }
#exitNotice:not(:empty) { position:fixed; z-index:100000; bottom:16px; left:50%; transform:translateX(-50%); width:max-content; max-width:calc(100vw - 32px); padding:12px 20px; border:1px solid #d9b970; border-radius:6px; background:#0b1928; color:#fff0cf; text-align:center; font-size:16px; box-shadow:0 4px 20px #000a; }
@container stage (max-height:400px) {
 /* Exact sprite rectangles permit 44px native controls in compact windows.
  * The original text-free portal avoids duplicating a baked second menu. */
 #title.screen.active { display:flex !important; justify-content:flex-start !important; padding:2cqh 8px !important; background-image:url('../assets/img/ui/element-portal-background.webp') !important; }
 #title .title-brand { position:relative; inset:auto; height:24cqh; flex:0 0 auto; }
 #title .title-logo { left:50%; top:0; transform:translateX(-50%); width:35.84279476cqh; height:24cqh; background:url('../assets/img/ui/title-direct-repair.webp') 50.14662757% 9.478672986% / 299.41520468% 238.20960699% no-repeat; mask-image:linear-gradient(to right,transparent,#000 10%,#000 90%,transparent),linear-gradient(to bottom,transparent,#000 10%,#000 90%,transparent); mask-composite:intersect; }
 #title .title-body { position:relative; inset:auto; width:36cqw !important; min-width:230px; height:auto; margin:1cqh auto 0 !important; }
 #title .title-menu { position:relative; inset:auto; display:flex; flex-direction:column; gap:4px !important; }
 #title .title-menu .menu-btn { position:relative; top:auto !important; left:auto; width:100% !important; height:auto !important; aspect-ratio:610 / 117; flex:0 0 auto; border-radius:0; background-image:url('../assets/img/ui/title-direct-repair.webp'); background-repeat:no-repeat; background-size:335.737704918% 932.478632479%; clip-path:polygon(8% 0,92% 0,98% 28%,100% 50%,98% 72%,92% 100%,8% 100%,2% 72%,0 50%,2% 28%); }
 #title #btnLobby { aspect-ratio:610 / 140; background-size:335.737704918% 779.285714286%; background-position:49.235048679% 54.469926393%; }
 #title #btnShop { background-position:49.235048679% 68.788501027%; }
 #title #btnSettings { background-position:49.235048679% 81.930184805%; }
 #title #btnTitleQuit { background-position:49.235048679% 95.071868583%; }
 #title .title-menu .menu-btn:focus-visible { outline:0; box-shadow:inset 0 0 0 3px #ffe5a4; }
 #title #titleMenu #buildVer { position:static !important; width:fit-content; height:auto; align-self:flex-end; padding:3px 8px; font-size:10px !important; line-height:14px; border:1px solid #e4c36a73; border-radius:6px; background:#0008; }
 #title .title-element { left:var(--element-x) !important; top:var(--element-y) !important; }
}
@media (prefers-reduced-motion:reduce) { #title .title-menu .menu-btn { transition:none; } }

/* Restore the pre-update approved hover plate (deployment closed-test-20261007-1).
 * Keep the corrected title art and idle geometry; the existing live label sits
 * above the original blank-center sprite only while that sprite is visible. */
#title .title-menu .menu-btn { isolation:isolate; font-size:clamp(16px,3.825717cqh,36px) !important; font-weight:700; letter-spacing:0 !important; text-shadow:0 2px 3px #000; }
#title #btnLobby { font-size:clamp(17px,4.463337cqh,42px) !important; }
#title .menu-art.plate-hover {
 position:absolute; inset:0; z-index:-1; pointer-events:none; display:grid; opacity:0;
 clip-path:polygon(8% 0,92% 0,97% 28%,97% 38%,100% 50%,97% 62%,97% 72%,92% 100%,8% 100%,3% 72%,3% 62%,0 50%,3% 38%,3% 28%);
}
#title .plate-hover > span { background-image:url('../assets/img/ui/approved-title-source.png?v=0.404'); background-repeat:no-repeat; min-width:0; min-height:0; }
#title .plate-hover::before,#title .plate-hover::after { content:""; position:absolute; background-image:url('../assets/img/ui/approved-title-source.png?v=0.404'); background-repeat:no-repeat; pointer-events:none; }
#title .plate-hover { grid-template-columns:54fr 400fr 54fr; grid-template-rows:1fr; }
#title .plate-hover .slice-0 { background-size:3096.296296296296% 855.4545454545455%; background-position:36.093943139678615% 53.42960288808665%; }
#title .plate-hover .slice-1 { background-size:2388.5714285714284% 855.4545454545455%; background-position:40.574282147315856% 53.42960288808665%; }
#title .plate-hover .slice-2 { background-size:3096.296296296296% 855.4545454545455%; background-position:64.15327564894932% 53.42960288808665%; }
#title .plate-hover::before,#title .plate-hover::after { left:10.629921%; right:10.629921%; }
#title .plate-hover::before { top:0; height:14.545454545454545%; background-size:418% 5881.25%; background-position:50.157232704402524% 48%; mask-image:linear-gradient(to bottom,#000 70%,transparent); }
#title .plate-hover::after { bottom:0; height:14.545454545454545%; background-size:418% 5881.25%; background-position:50.157232704402524% 58.16216216216217%; mask-image:linear-gradient(to top,#000 70%,transparent); }
#title .title-menu .menu-btn.is-pointer-hovered:where(:not(:disabled)) { box-shadow:none; }
#title .menu-btn.is-pointer-hovered:where(:not(:disabled)) .plate-hover { opacity:1; }
#title .menu-btn.is-pointer-hovered:where(:not(:disabled)) .menu-label { position:relative; width:auto; height:auto; margin:0; overflow:visible; clip-path:none; }
#title .title-menu .menu-btn:is(:active,.is-pressed) { box-shadow:none; }
#title .menu-btn:is(:focus-visible,:active,.is-pressed) .plate-hover { opacity:1; }
#title .menu-btn:is(:focus-visible,:active,.is-pressed) .menu-label { position:relative; width:auto; height:auto; margin:0; overflow:visible; clip-path:none; }
@container stage (max-height:400px) { #title .title-menu .menu-btn,#title #btnLobby { font-size:17px !important; } }

/* G124: foreign-language idle labels reuse the approved text-free hover plate. */
html:not(:lang(ko)) #title .menu-art.plate-hover { opacity:1; }
html:not(:lang(ko)) #title .menu-label { position:relative; width:auto; height:auto; margin:0; overflow:visible; clip-path:none; }

/* Translated labels retain their text-free plate and existing feedback. */
#title .menu-art.plate-hover {opacity:1;filter:brightness(.83);transition:filter .15s;}
#title .menu-label {position:relative;width:auto;height:auto;margin:0;overflow:visible;clip-path:none;}
#title .menu-btn.is-pointer-hovered:where(:not(:disabled)) .plate-hover {filter:brightness(1.08);}
#title .menu-btn:where(:not(:disabled)):is(:focus-visible,:active,.is-pressed) .plate-hover {filter:brightness(1.08);}
/* Korean states keep the original lettering and curved source plate. */
html:lang(ko) #title .menu-art.plate-hover {display:none;}
html:lang(ko) #title .menu-btn .menu-label {position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip-path:inset(50%);}
html:lang(ko) #title .menu-art.plate-normal {
 position:absolute;inset:0;height:5.712890625cqw;z-index:-1;pointer-events:none;display:block;opacity:1;
 background-image:url('../assets/img/ui/title-direct-repair.webp');background-repeat:no-repeat;
 background-size:335.737704918% 932.478632479%;filter:brightness(1);transition:filter .15s;
 clip-path:polygon(8% 0,92% 0,97% 28%,97% 38%,100% 50%,97% 62%,97% 72%,92% 100%,8% 100%,3% 72%,3% 62%,0 50%,3% 38%,3% 28%);
}
html:lang(ko) #title #btnLobby .plate-normal {height:6.8359375cqw;background-size:335.737704918% 779.285714286%;background-position:49.235048679% 54.469926393%;}
html:lang(ko) #title #btnShop .plate-normal {background-position:49.235048679% 68.788501027%;}
html:lang(ko) #title #btnSettings .plate-normal {background-position:49.235048679% 81.930184805%;}
html:lang(ko) #title #btnTitleQuit .plate-normal {background-position:49.235048679% 95.071868583%;}
/* Keep the 44px hit target independent from the artwork; compact buttons already use sprite aspect ratios. */
@container stage (max-height:400px){html:lang(ko) #title .menu-art.plate-normal,html:lang(ko) #title #btnLobby .plate-normal {height:100%;}}
/* Keep the same raster lettering and curved ornament in every Korean state.
 * Lighten affects the dark plate while preserving the brighter original text. */
html:lang(ko) #title .plate-normal::before {
 content:"";position:absolute;inset:8% 4.7%;border-radius:6% / 45%;pointer-events:none;
 background:linear-gradient(180deg,#7c3308,#411502 52%,#843b07);
 box-shadow:inset 0 0 0 1px #ffd36e,inset 0 0 12px #ffad15aa,0 0 9px #ff950099;
 mix-blend-mode:lighten;opacity:0;transition:opacity .15s;
}
html:lang(ko) #title .menu-btn:where(:not(:disabled)):is(.is-pointer-hovered,:focus-visible,:active,.is-pressed) .plate-normal::before {opacity:1;}
@media(prefers-reduced-motion:reduce){html:lang(ko) #title .menu-art.plate-normal {transition:none;}}
/* Fade only inner slice edges; keep horizontal and diagonal plate ornament. */
#title #btnLobby .slice-1 {margin-inline:-3px;mask-image:linear-gradient(90deg,transparent,#000 3%,#000 97%,transparent);}
/* Pointer hover owns the bright plate while present. Keep focus-visible's
 * outline, then restore the focused plate automatically when hover leaves. */
#title .title-menu:has(.menu-btn.is-pointer-hovered:where(:not(:disabled))) .menu-btn:not(.is-pointer-hovered) .plate-hover {filter:brightness(.83);transition:none;}
html:lang(ko) #title .title-menu:has(.menu-btn.is-pointer-hovered:where(:not(:disabled))) .menu-btn:not(.is-pointer-hovered) .plate-hover {display:none;}
html:lang(ko) #title .title-menu:has(.menu-btn.is-pointer-hovered:where(:not(:disabled))) .menu-btn:not(.is-pointer-hovered) .menu-label {position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip-path:inset(50%);}
html:lang(ko) #title .title-menu:has(.menu-btn.is-pointer-hovered:where(:not(:disabled))) .menu-btn:not(.is-pointer-hovered) .plate-normal::before {opacity:0;transition:none;}
@media(prefers-reduced-motion:reduce){html:lang(ko) #title .plate-normal::before {transition:none;}}
