/* Shared, account-independent language control. Autonyms stay readable in either direction. */
.language-picker { position:relative; flex:none; color:var(--text); }
.language-trigger { display:flex; align-items:center; justify-content:center; gap:7px; min-height:38px; padding:7px 10px; border:1px solid var(--border); border-radius:9px; background:var(--panel); font-size:12px; font-weight:550; line-height:1.3; list-style:none; cursor:pointer; white-space:nowrap; }
.language-trigger::-webkit-details-marker { display:none; }
.language-trigger::marker { content:""; }
.language-trigger .ui-icon { width:17px; height:17px; flex:none; }
.language-chevron { width:12px; height:12px; flex:none; }
.language-picker[open] .language-chevron { transform:rotate(180deg); }
.language-trigger:hover,.language-picker[open] .language-trigger { background:var(--hover); border-color:var(--accent-text); }
.language-trigger:focus-visible,.language-option:focus-visible { outline:2px solid var(--accent-text); outline-offset:3px; }
.language-panel { position:absolute; inset-block-start:calc(100% + 9px); inset-inline-end:0; z-index:95; width:240px; max-width:calc(100vw - 24px); padding:8px; border:1px solid var(--border); border-radius:12px; background:var(--panel); box-shadow:0 12px 32px #09162b26; text-align:start; white-space:normal; }
.language-heading { padding:5px 9px 9px; color:var(--muted); font-size:11px; font-weight:600; }
.language-option { display:flex; align-items:center; justify-content:space-between; gap:14px; width:100%; min-height:40px; border:0; border-radius:7px; padding:9px 10px; background:transparent; color:var(--text); font-size:13px; text-align:start; }
.language-option:hover,.language-option:focus-visible { background:var(--hover); }
.language-option[aria-current] { background:var(--primary-soft); color:var(--accent-text); font-weight:650; }
.language-option .ui-icon { width:16px; height:16px; flex:none; }
.language-documents-note { margin:8px 2px 0; border-top:1px solid var(--border); padding:10px 7px 3px; color:var(--muted); font-size:10px; line-height:1.6; }
.language-feedback { padding:9px 7px 3px; font-size:11px; line-height:1.6; color:var(--text); }
.language-picker--mobile { display:none; }
.language-panel [hidden] { display:none; }
/* Business identifiers and German-format entry controls remain left-to-right. */
:where(input[type="email"],input[type="tel"],input[type="url"],input[type="number"],input[type="date"],input[type="time"],input[type="datetime-local"],input[inputmode="decimal"],input[inputmode="numeric"],input[autocomplete="postal-code"],input[autocomplete="one-time-code"],[data-german-date],[data-german-time],[data-german-datetime],input[name*="license_plate"],input[name*="vin"],input[name*="iban"],input[name*="bic"],input[name*="postal_code"],input[name*="tax_number"],input[name*="vat_id"],.plate,.license-plate,.iban,[data-running-clock],bdi) { direction:ltr; unicode-bidi:isolate; }
html[dir="rtl"] { --ui-direction:-1; }
html[dir="rtl"] body { font-family:Tahoma,"Segoe UI",Arial,sans-serif; }
html[dir="rtl"] :is(h1,h2,h3,h4,.eyebrow,.nav-caption) { letter-spacing:normal; }
html[dir="rtl"] :is(.nav-link,.address-option,.data-table th,.data-table td,.responsive-table td,.customer-cell>div,.text-link,.quick-access-item,.settings-tab,.crm-choice) { text-align:start; }
html[dir="rtl"] :is(.user-pill,.data-pairs dd,.position-line-total) { text-align:end; }
html[dir="rtl"] .sidebar { border-right:0; border-left:1px solid var(--border); }
html[dir="rtl"] .app-body .nav-link.active::before { left:auto; right:-6px; }
html[dir="rtl"] .mobile-nav-panel { right:auto; left:12px; }
html[dir="rtl"] .workspace-dialog .create-panel>h2 { padding-right:0; padding-left:48px; }
html[dir="rtl"] .workspace-dialog-close { right:auto; left:0; }
html[dir="rtl"] .quick-access-search>.ui-icon { left:auto; right:12px; }
html[dir="rtl"] .quick-access-search input { padding-left:12px!important; padding-right:40px!important; }
html[dir="rtl"] .quick-access-trigger kbd { margin-left:0; margin-right:8px; }
html[dir="rtl"] .news-popover { inset-inline-start:auto; inset-inline-end:24px; }
html[dir="rtl"] .news-preview-item summary::after { margin-left:0; margin-right:auto; }
html[dir="rtl"] .password-field input { padding-right:12px; padding-left:48px; }
html[dir="rtl"] .password-field button { right:auto; left:6px; }
html[dir="rtl"] .login-page.entry-page .auth-form .password-field input { padding-right:12px; padding-left:54px; }
html[dir="rtl"] .login-page.entry-page .password-field button { right:auto; left:3px; }
html[dir="rtl"] .mk-section-nav { margin-left:0; margin-right:auto; padding-right:0; padding-left:20px; }
html[dir="rtl"] .mk-shared-label { margin-left:0; margin-right:auto; padding-left:0; padding-right:20px; }
html[dir="rtl"] .mk-scan-filetype { margin-left:0; margin-right:auto; }
html[dir="rtl"] .mk-scan-steps li:not(:last-child)::after { left:auto; right:14px; }
html[dir="rtl"] .showcase-table :is(th,td) { text-align:start; }
html[dir="rtl"] .showcase-table :is(th,td):last-child { text-align:left; }
html[dir="rtl"] .showcase-table td span { margin-left:0; margin-right:5px; }
html[dir="rtl"] .showcase-flow li+li::before { left:auto; right:-50%; }
html[dir="rtl"] .mk-business-flow>span[aria-hidden] { transform:scaleX(-1); }
html[dir="rtl"] :is(.numeric,.showcase-table td:last-child,.showcase-total>strong) { direction:ltr; unicode-bidi:isolate; }
html[dir="rtl"] .brand-mark { direction:ltr; }
html[dir="rtl"] .pagination .ui-icon { transform:scaleX(-1); }
/* The amount stays LTR; its mobile field label follows the surrounding RTL list. */
@media(max-width:900px) {
    html[dir="rtl"] .responsive-table td.numeric { flex-direction:row-reverse; text-align:end; }
    html[dir="rtl"] .responsive-table td::before { direction:rtl; text-align:start; }
}
/* PDF canvases and document images are originals, independent of UI language. */
.document-viewer canvas,.document-viewer img,[data-pdf-canvas],[data-preview-image] { direction:ltr; }
@media(max-width:1100px) {
    .topbar-right { gap:10px; }
    .language-picker--desktop .language-current { display:none; }
}
@media(max-width:1100px) {
    .language-picker--mobile { display:block; }
    .language-picker--mobile .language-current,.language-picker--mobile .language-chevron { display:none; }
    .language-picker--mobile .language-trigger { width:34px; min-height:34px; padding:7px; }
    html[dir="rtl"] .mk-section-nav { padding-left:0; }
}
@media(max-width:760px) {
    .language-picker--mobile .language-panel { position:fixed; inset-block-start:64px; inset-inline-end:12px; }
    .public-header .language-current,.mk-header .language-current { display:none; }
    .public-header .language-chevron,.mk-header .language-chevron { display:none; }
    .public-header .language-trigger,.mk-header .language-trigger { padding:8px; }
    .public-header nav { gap:8px; }
    html[dir="rtl"] .app-body .mobile-brand-title { margin-right:0; margin-left:auto; }
    html[dir="rtl"] .app-body .mobile-topbar-row>.brand-mark { margin-right:0; margin-left:auto; }
    html[dir="rtl"] .news-popover { inset-inline-end:12px; }
}
@media(max-width:420px) {
    .app-body .mobile-topbar-row { gap:6px; }
    .language-picker--mobile .language-trigger { width:30px; min-height:32px; padding:6px; }
}
