/* Reading direction follows the selected language; game coordinates stay fixed. */
html:is([lang="ru"], [lang="uk"]) { --round: system-ui, Arial, sans-serif; }
.chips.wide button { flex: 1 1 0; min-width: 0; height: auto; min-height: 40px; padding-block: 6px; line-height: 1.3; white-space: normal; overflow-wrap: anywhere; }
.stage-chip .stage-label { white-space: normal; overflow-wrap: anywhere; text-align: center; }
.play-terms-dialog > * { min-inline-size: 0; overflow-wrap: anywhere; }
.entry-card :is(button, h1, p, small, .app-button > span:not(.app-icon)) { min-inline-size: 0; overflow-wrap: anywhere; }
.entry-card .who-choices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.entry-card .row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.entry-card .row input { letter-spacing: 4px; }
#game .count.goal :is(.round-goal, .round-victory) { white-space: normal; overflow-wrap: break-word; }
#game .buttons b { max-inline-size: calc(100% - 4px); white-space: normal; overflow-wrap: anywhere; }
html[dir="rtl"] body { font-family: "Noto Sans Arabic", Tahoma, Arial, sans-serif; }
html[dir="rtl"] :is(button, input, select, textarea) { font-family: inherit; }
html[dir="rtl"] :is(.field, .rules, .rule, .story-path, .story-path button, .chapter-summary, .dialogue-box, .dialogue-text,
  .reader-chapter, .reader-text, .item-help, .billing-product.billing-access,
  .story-hero-choice span, .btn.app-button > span:not(.app-icon), .account-card, .billing-card) { text-align: start; }
html[dir="rtl"] :is(.dialogue-text, .reader-text, .item-help) { direction: rtl; }
html[dir="rtl"] #storyDialogue .dialogue-text { text-align: start; }
html[dir="rtl"] .reader-speaker { left: auto; right: 22px; }
html[dir="rtl"] .btn.app-button > span:not(.app-icon) { align-items: flex-start; }
html[dir="rtl"] :is(.ticket-code, #roomCode, #roomInput, input[type="email"], input[type="url"], .keyboard-hint, .reader-position) { direction: ltr; unicode-bidi: isolate; }
html[dir="rtl"] :is(#game, #board, #board3d, .controls, .pad, .buttons, .hud, .dialogue-standing-actors, .reader-actors) { direction: ltr; }
html[dir="rtl"] #game :is(.tutorial-step, .pickup, .hud-status, .disease-tag, .hud-item-help, .buttons b, .round-goal, .round-victory) { direction: rtl; unicode-bidi: plaintext; }
html[dir="rtl"] #game .hud-item-help { text-align: start; }
:is(.nm, .n, #meName, #champName, .acc-name) { unicode-bidi: plaintext; }
#languageSelect, #languageSelect option { unicode-bidi: plaintext; }
@media (orientation: landscape) {
  html:is([lang="ru"], [lang="uk"], [lang="tr"]) #game .buttons { margin-bottom: 20px; }
}
