/* Arabic typography: self-hosted variable Cairo, with complete Arabic/Latin glyphs.
   Keep font rules off icon elements and code blocks. English font preferences
   and the existing RTL layout remain independent of this typography layer. */
@font-face {
    font-family: "Cairo";
    font-style: normal;
    font-weight: 200 1000;
    font-display: swap;
    src: url("../fonts/cairo/cairo-variable.woff2") format("woff2");
}

:root {
    --erp-font-arabic: "Cairo", "Segoe UI", Tahoma, sans-serif;
}

html:lang(ar) {
    --bs-body-font-family: var(--erp-font-arabic);
    --cui-body-font-family: var(--erp-font-arabic);
}

html:lang(ar) body {
    font-family: var(--erp-font-arabic);
    line-height: 1.75;
    letter-spacing: normal;
}

html:lang(ar) body.font-md {
    font-size: 15px;
}

html:lang(ar) body.spacing-normal {
    line-height: 1.75;
}

html:lang(ar) body.spacing-relaxed {
    line-height: 1.9;
}

html:lang(ar) body.spacing-wide {
    line-height: 2.1;
}

html:lang(ar) :is(button, input, select, textarea, .btn, .form-control,
    .form-select, .dropdown-menu, .tooltip, .popover, .table) {
    font-family: var(--erp-font-arabic);
    letter-spacing: normal;
}

html:lang(ar) :is(h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6) {
    font-family: var(--erp-font-arabic);
    line-height: 1.5;
    letter-spacing: normal;
}

html:lang(ar) :is(h1, h2, .h1, .h2) {
    font-weight: 700;
}

/* Arabic uses connected letterforms: Latin-style tracking breaks the rhythm. */
html:lang(ar) :is(.workspace-eyebrow, .dashboard-settings-kicker, .construction-kicker) {
    letter-spacing: normal;
    line-height: 1.7;
}
