/* =============================================================================
   boardroom-i18n.css (BR1236)
   The language switcher, in the sv2 look (DM Sans, #e6eaf1 lines, 8px radius, 36px
   controls): rows inside the avatar menu (.bi18n-menu) and the compact picker on the
   guest screens / settings (.bi18n-select). Loaded for every language; direction-neutral
   (logical properties), so it is excluded from the RTL mirroring with data-rtl="skip".
   ========================================================================== */

.bi18n-sr {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Rows in a dropdown menu ---------------------------------------- */

.bi18n-menu {
    margin: 0;
    padding: 6px 0;
    border-top: 1px solid #e5e7eb;
    font-family: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
.bi18n-menu-title {
    padding: 4px 16px 6px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #9ca3af;
}
.bi18n-menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    padding: 9px 16px;
    border: 0;
    background: transparent;
    color: #4b5563;
    font: inherit;
    font-size: 14px;
    text-align: start;
    cursor: pointer;
}
.bi18n-menu-item:hover,
.bi18n-menu-item:focus-visible {
    background: #f3f4f6;
    color: #111827;
    outline: none;
}
.bi18n-menu-item.is-active {
    color: #111827;
    font-weight: 500;
}
.bi18n-menu-check {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
    color: #0B45A9;
}

/* ---------- Compact picker ------------------------------------------------- */

.bi18n-select-form {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-family: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
.bi18n-select-label {
    display: inline-flex;
    align-items: center;
    color: #6b7280;
    cursor: pointer;
}
.bi18n-select-label svg {
    width: 18px;
    height: 18px;
}
.bi18n-select {
    appearance: none;
    -webkit-appearance: none;
    height: 36px;
    padding: 0 32px 0 12px;
    border: 1px solid #dbe1ea;
    border-radius: 8px;
    background: #fff url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none'%3E%3Cpath d='M6 8l4 4 4-4' stroke='%236b7280' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 10px center / 14px;
    color: #111827;
    font: inherit;
    font-size: 14px;
    line-height: 34px;
    cursor: pointer;
}
[dir="rtl"] .bi18n-select {
    padding: 0 12px 0 32px;
    background-position: left 10px center;
}
.bi18n-select:focus-visible {
    outline: 2px solid transparent;
    border-color: #0B45A9;
    box-shadow: 0 0 0 3px rgba(11, 69, 169, .16);
}
.bi18n-select-apply {
    height: 36px;
    padding: 0 12px;
    border: 1px solid #dbe1ea;
    border-radius: 8px;
    background: #fff;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

/* Agency sign-up (first step): logo at the start of the row, the picker at the end. */
.bi18n-signup-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}
.bi18n-signup-head .bi18n-select {
    height: 32px;
    line-height: 30px;
    font-size: 13px;
}

/* Under the guest auth card: centred, quiet. */
.bra-page .bi18n-select-form {
    justify-content: center;
    margin-top: 18px;
}
.bra-page .bi18n-select {
    height: 32px;
    line-height: 30px;
    font-size: 13px;
}

/* ---------- Translated labels in fixed columns ----------------------------- */

/* Filter rows of the sv2 pages (Sales, Advertising, Expenses, Products, Customers, Inventory) put each
   label in a 64px column on phones (the views' own style blocks). A translated label longer than that
   ("العلامة التجارية") takes a second line instead of running under its control. English labels fit
   on one line and are not touched. */
@media only screen and (max-width: 768px) {
    html:not([lang="en"]) .sv2-ctl-label {
        white-space: normal;
        overflow-wrap: anywhere;
        line-height: 1.25;
    }
}

/* Buttons of the older auth screens (app.css `.auth .btn`: 174px wide, 50px high). A translated label
   ("Dokończ rejestrację") broke onto two lines and out of the 50px height: the button grows from
   174px instead. English keeps its fixed width. */
html:not([lang="en"]) .auth .btn {
    width: max-content;
    min-width: 174px;
    max-width: 100%;
}
