/* Shared language preference control; existing header/workspace geometry is retained. */
.tp-footer-inner .tp-locale-control{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-start;gap:6px 12px;min-width:0;font-size:12px;color:var(--tp-body,#58665d)}
.tp-locale-control label{display:flex;align-items:center;gap:8px;max-width:100%}
.tp-locale-control select{font:inherit;font-size:13px;line-height:1.3;min-height:36px;width:168px;max-width:100%;padding:6px 24px 6px 9px;color:var(--tp-ink,#24382c);background:var(--tp-paper,#fbf8f3);border:1px solid var(--tp-line,#d9dfd9);border-radius:9px}
.tp-locale-control button{font:inherit;min-height:36px;padding:4px 0;background:none;border:0;color:inherit;text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.tp-locale-control :is(select,button):focus-visible{outline:2px solid var(--tp-green-dark,#2b693d);outline-offset:3px}
:lang(ja) :is(p,li,dd,h1,h2,h3,button,label,summary){word-break:normal;overflow-wrap:anywhere;line-break:strict}
:lang(de) :is(button,.tpx-label,.tp-navlinks a),:lang(fr) :is(button,.tpx-label,.tp-navlinks a){overflow-wrap:break-word}
:lang(de) :is(.tpx-mode-option,.tpx-mode),:lang(fr) :is(.tpx-mode-option,.tpx-mode){min-width:0}
@media(max-width:640px){.tp-footer-inner .tp-locale-control{justify-content:center;width:100%}.tp-locale-control label{flex-wrap:wrap;justify-content:center}}

.tp-footer-meta:has(.tp-locale-control){flex-wrap:wrap}

/* Translated sign-in labels must remain readable; account names retain ellipsis. */
@media(max-width:640px){body .tp-header .tp-account[data-auth-label]:not([role="button"]){max-width:100%;white-space:normal}}
/* Allow a Japanese mode name and its plan label to stay together. */
@container compression-mode (min-width:400px){html:lang(ja) .tpx-page.has-tablet-workspace:not(.tpx-tool-page) .tpx-home-compressor .tpx-mode-tabs{width:min(100%,480px)}}
