/* Language uses logical layout; all chess geometry and coordinates stay LTR. */
.language-control{display:flex;align-items:center;gap:5px;flex-shrink:0;max-width:155px;padding:5px 7px;border:1px solid #95c6e455;border-radius:14px;background:#133751bb;color:#edf8ff}
.language-control svg{width:20px;height:20px;flex-shrink:0}.language-control select{width:110px;min-width:0;padding:6px 2px;border:0;background:transparent;color:inherit;font:inherit;font-size:14px}.language-control option,.language-setting option,.language-welcome option{background:#163b55;color:#fff}
.language-setting{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-block:8px}.language-setting select{max-width:60%}
.dashboard-hero>.daily-egg-button{position:absolute;inset-inline-end:16px;top:12px;z-index:4;width:62px;height:78px;padding:9px}.dashboard-hero>.daily-egg-button>.golden-egg{width:43px;height:59px}.dashboard-hero>.daily-egg-button>i{top:3px;inset-inline-end:0;font-size:17px}.daily-egg-button.claimed>.golden-egg{animation:none;filter:saturate(.6);opacity:.75}.daily-egg-button.claimed>i{color:#c2f0bf}
.daily-reward-shortcut{display:flex;align-items:center;gap:6px;border-radius:14px;padding:5px 8px;min-width:0;color:#f4e8cc}.daily-reward-shortcut .reward-info-button{border:0;background:transparent;padding:5px 0;min-width:0;flex:1;text-align:start;color:inherit}.reward-info-button b,.reward-info-button small{display:block}.reward-info-button small{margin-top:4px}.daily-egg-button{position:relative;display:flex;align-items:center;justify-content:center;width:48px;min-width:48px;min-height:52px;border:0;background:transparent;padding:5px;cursor:pointer}.golden-egg{display:block;width:31px;height:42px;border-radius:50% 50% 46% 46% / 62% 62% 38% 38%;background:radial-gradient(ellipse at 28% 25%,#fff8c3 0,#f4cd66 22%,#d49a29 52%,#8c5915 85%);box-shadow:inset -4px -3px 8px #6e3d3244,0 0 17px #f4cf6c55}.daily-egg-button>.golden-egg{animation:daily-egg-idle 3.6s ease-in-out infinite;transform-origin:50% 85%}.daily-egg-button>i{position:absolute;inset-inline-end:0;top:6px;font-size:13px;color:#ffe4a5;font-style:normal}.daily-egg-button[aria-busy=true] .golden-egg{animation:none;filter:brightness(1.2)}.daily-egg-button:focus-visible{outline:2px solid #ffe49c;outline-offset:1px;border-radius:12px}.egg-reward-layer{position:fixed;z-index:80;pointer-events:none;overflow:visible}.egg-reward-layer>strong{position:absolute;left:0;top:-35px;white-space:nowrap;color:#ffdf7e;font-size:28px;text-shadow:0 2px 5px #102d4c;transform:translateX(-50%)}.egg-shell{position:absolute;left:0;top:0;transform:translate(-50%,-50%)}.egg-left{clip-path:polygon(0 0,54% 0,44% 35%,57% 50%,45% 68%,54% 100%,0 100%)}.egg-right{clip-path:polygon(54% 0,100% 0,100% 100%,54% 100%,45% 68%,57% 50%,44% 35%)}.egg-flight-coin{position:absolute;left:0;top:0;display:grid;place-items:center;width:25px;height:25px;border:2px solid #f8df8b;border-radius:50%;background:linear-gradient(140deg,#fff0a3,#d99a28);box-shadow:0 0 13px #ffd86a88;color:#855512;font-size:15px;font-style:normal}@keyframes daily-egg-idle{0%,100%{transform:translateY(0) rotate(-3deg)}45%{transform:translateY(-4px) rotate(3deg)}60%{transform:translateY(-3px) rotate(-2deg)}}@media(prefers-reduced-motion:reduce){.daily-egg-button>.golden-egg{animation:none}}.reduced .daily-egg-button>.golden-egg{animation:none}
.language-welcome{box-sizing:border-box;width:min(480px,calc(100vw - 32px));max-height:calc(100dvh - 32px);padding:28px;text-align:center;border:1px solid #d7bd7755;border-radius:25px;color:#f0f8ff;background:#153b55;overflow:auto}
.language-welcome::backdrop{background:#041a35bb;backdrop-filter:blur(8px)}.welcome-crown{font-size:42px;color:#f5d18b}.language-welcome h2{font-size:clamp(21px,4vw,28px);line-height:1.3;overflow-wrap:anywhere}.language-welcome label{display:block;margin-block:20px 8px}.language-welcome select{display:block;width:100%;margin-block:0 24px;padding:12px}.language-welcome .primary{width:100%}
html[lang=ja] body{font-family:system-ui,"Yu Gothic","Meiryo",sans-serif;line-break:strict;word-break:normal}
html[lang=ar] body{font-family:system-ui,"Segoe UI",Tahoma,sans-serif}
html[dir=rtl] header{direction:ltr}
html[dir=rtl] .dashboard-copy,html[dir=rtl] .item-copy,html[dir=rtl] .lesson-copy,html[dir=rtl] .profile-account,html[dir=rtl] .review-comment{text-align:start}
html[dir=rtl] .home-family{left:2%;right:auto}
.board-grid,.board-row,.board-frame,.lesson-board,.review-board,.best-move-board,.mini-board,.move-notation,.player-clock,.friend-room-code,code,[data-clock-side]{direction:ltr;unicode-bidi:isolate}
.player-card b,.profile-account h2,.chat-sender,.lobby-names{unicode-bidi:plaintext}
.chat-message-text{unicode-bidi:plaintext;text-align:start}
html:not([lang=en]) h1,html:not([lang=en]) h2,html:not([lang=en]) h3,html:not([lang=en]) button,html:not([lang=en]) small{overflow-wrap:break-word}
html:not([lang=en]) .dashboard-modes-heading>span{max-width:40%;text-align:end}
html:not([lang=en]) .dashboard-mode-grid button small{line-height:1.25}
@media(max-width:1100px){.language-control{max-width:126px}.language-control select{width:85px}.language-control svg{width:16px;height:16px}}
@media(min-width:1100px){html:not([lang=en]) body .bottom-dock{width:460px!important;max-width:calc(100vw - 32px)}html:not([lang=en]) body .bottom-dock button{flex:1;min-width:0;padding:5px 6px!important;overflow-wrap:normal;font-size:13px}html:not([lang=en]) body.is-home footer.homepage-footer{grid-template-columns:minmax(0,1fr) 480px minmax(0,1fr)}}
@media(max-width:600px){.language-control{position:absolute;inset-inline-end:initial;right:12px;left:auto;top:10px;z-index:5}.language-control select{font-size:13px}.language-welcome{padding:20px}}
@media(min-width:1100px) and (max-height:750px){html[lang=ja] .bot-gallery{grid-template-rows:68px 140px minmax(0,1fr);padding-top:12px}html[lang=ja] .bot-tier-title{padding:6px 12px;margin:4px 0}html[lang=ja] .bot-tile-art{height:64px;width:64px}html[lang=ja] .bot-options .time-choice{margin:6px 0;padding:7px}html[lang=ja] .bot-options .practice-sides{margin-bottom:8px}html[lang=ja] .bot-options .desktop-copy,html[lang=ja] .bot-options .desktop-rewards{margin-top:6px}html[lang=ja] .bot-options .bot-play-button{margin:6px 0}}
