.agora-language-switch {display:flex;justify-content:flex-end;align-items:center;gap:6px;padding:8px 15px;background:#ede0cc;color:#3b2412;font:16px/1.4 Arial,sans-serif;box-sizing:border-box;}
.agora-language-switch select {min-height:44px;max-width:100%;padding:7px 10px;border:1px solid #8b572a;border-radius:8px;background:#fff8eb;color:#3b2412;font:inherit;cursor:pointer;}
.agora-language-switch select:focus-visible {outline:3px solid #d59b2d;outline-offset:2px;}
.agora-language-game {position:fixed;top:6px;right:6px;z-index:9000;padding:2px 5px;border-radius:8px;background:#fff0ceeF;font-size:14px;}
.agora-language-game select {min-height:40px;padding:5px;}
@media(max-width:420px) {.agora-language-game {font-size:12px;}.agora-language-game label{display:none;}}

/* Sélecteur sans icône, à la hauteur des commandes du jeu. */
.agora-language-switch select {box-sizing:border-box;height:52px;min-height:52px;}
.agora-language-game {top:20px;right:8px;padding:0;background:transparent;font-size:14px;}
.agora-language-game select {height:52px;min-height:52px;padding:10px 8px;border:2px solid #8b552d;border-radius:9px;background:#fff3ce;color:#352615;box-shadow:0 4px 16px #0006;}
@media(max-width:600px) {.agora-language-game {top:12px;}}

/* Les libellés allemands plus longs peuvent se répartir sur plusieurs lignes. */
html[lang="de"] #choice {flex-wrap:wrap;justify-content:center;}
html[lang="de"] #choice button {max-width:100%;white-space:normal;font-size:16px;}
html[lang="de"] #startChoiceBox button {max-width:100%;white-space:normal;overflow-wrap:break-word;}

/* Les choix d'action espagnols peuvent revenir à la ligne sur petit écran. */
html[lang="es"] #choice {flex-wrap:wrap;justify-content:center;}
html[lang="es"] #choice button {max-width:100%;white-space:normal;font-size:16px;}
html[lang="es"] #startChoiceBox button {max-width:100%;white-space:normal;overflow-wrap:break-word;}

/* Commande de langue compacte, dans la barre du jeu ; choix natif sur téléphone. */
#gameControls .agora-language-compact { position:relative; grid-column:2; grid-row:2; width:52px; height:52px; padding:0; border:2px solid #8b552d; border-radius:9px; background:#fff3ce; color:#352615; box-shadow:0 4px 16px #0006; }
#gameControls .agora-language-compact:hover { background:#ffe6a2; }
#gameControls .agora-language-compact:focus-within { outline:3px solid #2769b5; outline-offset:3px; }
#gameControls .agora-language-globe { display:flex; align-items:center; justify-content:center; position:absolute; inset:0; pointer-events:none; }
#gameControls .agora-language-globe svg { width:28px; height:28px; }
#gameControls .agora-language-compact select { position:absolute; inset:0; width:100%; max-width:100%; height:100%; min-height:0; padding:0; margin:0; opacity:0; cursor:pointer; }
#gameControls:has(#problemInstructionBtn:not([hidden])) #hintBtn { grid-column:3; grid-row:2; justify-self:start; }
#gameControls:has(#problemInstructionBtn:not([hidden])) #restartBtn { grid-column:3; grid-row:2; justify-self:end; }
#gameControls:has(#problemInstructionBtn:not([hidden])) #exportBtn { grid-column:1; grid-row:2; }

/* La langue suit directement le bouton Ajuster la vue. */
#viewControls .agora-language-compact { flex:0 0 52px; }
#gameControls:not(:has(#problemInstructionBtn:not([hidden]))) { grid-template-columns:52px 52px max-content 52px; }
