/* Minimal RTL overrides for the Arabic locale.
   Bootstraps's LTR build is used, so a few direction-sensitive helpers are
   flipped here. Add to this file as RTL-specific issues surface. */

[dir="rtl"] body {
    text-align: right;
}

/* Spacing utilities are physical in Bootstrap; mirror the inline-axis ones. */
[dir="rtl"] .me-1 { margin-right: 0 !important; margin-left: 0.25rem !important; }
[dir="rtl"] .me-2 { margin-right: 0 !important; margin-left: 0.5rem !important; }
[dir="rtl"] .me-3 { margin-right: 0 !important; margin-left: 1rem !important; }
[dir="rtl"] .me-4 { margin-right: 0 !important; margin-left: 1.5rem !important; }
[dir="rtl"] .ms-1 { margin-left: 0 !important; margin-right: 0.25rem !important; }
[dir="rtl"] .ms-2 { margin-left: 0 !important; margin-right: 0.5rem !important; }
[dir="rtl"] .ms-3 { margin-left: 0 !important; margin-right: 1rem !important; }
[dir="rtl"] .ms-4 { margin-left: 0 !important; margin-right: 1.5rem !important; }

/* Text alignment helpers. */
[dir="rtl"] .text-start { text-align: right !important; }
[dir="rtl"] .text-end { text-align: left !important; }

/* Right-anchored dropdowns should open from the inline-start edge. */
[dir="rtl"] .dropdown-menu-end { right: auto; left: 0; }

/* Directional navigation icons. */
[dir="rtl"] .fa-arrow-left,
[dir="rtl"] .fa-arrow-right {
    transform: scaleX(-1);
}
