/* ============================================================
   RTL overrides — loaded only when the active culture is Arabic
   (the <html> element carries dir="rtl"). These selectors are
   prefixed with [dir="rtl"] so they win over the equal-specificity
   physical-direction rules in site.css AND the per-view inline
   <style> blocks, regardless of source order.
   ============================================================ */

/* Cairo renders Arabic well; keep the comfortable line-height. */
[dir="rtl"] body {
    font-family: 'Cairo', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* --- Top bar --- */
[dir="rtl"] .top-bar-contact i {
    margin-right: 0;
    margin-left: 5px;
}

/* --- Navigation --- */
[dir="rtl"] .navbar-nav .btn-verify {
    margin-left: 0;
    margin-right: 15px;
}

[dir="rtl"] .dropdown-item:hover {
    transform: translateX(-5px);
    padding-left: 20px;
    padding-right: 25px;
}

/* Language switcher chips */
[dir="rtl"] .lang-switch i {
    margin-right: 0;
    margin-left: 5px;
}

/* --- About checkmark list --- */
[dir="rtl"] .about-list {
    padding-right: 0;
}

[dir="rtl"] .about-list li {
    padding-left: 0;
    padding-right: 25px;
}

[dir="rtl"] .about-list li:before {
    left: auto;
    right: 0;
}

/* --- Benefits list (Standards pages) --- */
[dir="rtl"] .benefits-list {
    padding: 0;
}

[dir="rtl"] .benefits-list li {
    padding-left: 0;
    padding-right: 30px;
}

[dir="rtl"] .benefits-list li i {
    left: auto;
    right: 0;
}

/* --- Numbered process steps (Standards / Documents / Services) --- */
[dir="rtl"] .step-number {
    margin-right: 0;
    margin-left: 20px;
}

[dir="rtl"] .process-step:not(:last-child)::after {
    left: auto;
    right: 25px;
}

/* --- Document submission checklists --- */
[dir="rtl"] .submission-info ul li {
    padding-left: 0;
    padding-right: 30px;
}

[dir="rtl"] .submission-info ul li i {
    left: auto;
    right: 0;
}

/* --- Generic icon-prefixed lists used across content pages --- */
[dir="rtl"] .info-list,
[dir="rtl"] .related-standards,
[dir="rtl"] .feature-list,
[dir="rtl"] .check-list {
    padding-right: 0;
}

[dir="rtl"] .check-list li {
    padding-left: 0;
    padding-right: 30px;
}

[dir="rtl"] .check-list li i {
    left: auto;
    right: 0;
}

/* --- Floating action buttons (WhatsApp + back-to-top): bottom-LEFT in RTL.
       Mirrors the reading direction and keeps them clear of the right edge
       (avoids the right-edge clipping seen on some mobile viewports). The base
       site.css anchors them with right:30px/20px, so reset `right` and set
       `left`. `right: auto !important` guards against any stray right anchor. --- */
[dir="rtl"] .floating-whatsapp,
[dir="rtl"] .back-to-top {
    right: auto !important;
    left: 30px;
}

/* --- Responsive tweaks --- */
@media (max-width: 768px) {
    [dir="rtl"] .navbar-nav .btn-verify {
        margin-right: 0 !important;
    }

    [dir="rtl"] .floating-whatsapp,
    [dir="rtl"] .back-to-top {
        right: auto !important;
        left: 20px;
    }
}

/* --- Services pages: icon block beside content + bullet lists --- */
[dir="rtl"] .service-icon-small {
    margin-right: 0;
    margin-left: 20px;
}

[dir="rtl"] .service-content ul {
    padding-right: 0;
    padding-left: 0;
}

[dir="rtl"] .service-content ul li {
    padding-left: 0;
    padding-right: 20px;
}

[dir="rtl"] .service-content ul li:before {
    left: auto;
    right: 0;
}

/* --- Phone / WhatsApp numbers always render left-to-right, even in RTL.
       <bdi dir="ltr"> handles the markup cases; this also covers tel:/wa.me
       links (e.g. the Contact page) without touching their markup. --- */
[dir="rtl"] a[href^="tel:"]:not(.floating-whatsapp),
[dir="rtl"] a[href^="https://wa.me"]:not(.floating-whatsapp),
[dir="rtl"] .num-ltr {
    direction: ltr;
    unicode-bidi: isolate;
    display: inline-block;
}
