/* ============================================
   AL IMARA Website - Arabic RTL Styles
   ============================================ */

/* RTL Direction */
body[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

/* Navigation RTL Adjustments */
body[dir="rtl"] .nav-link::after {
    left: auto;
    right: 50%;
    transform: translateX(50%);
}

body[dir="rtl"] .nav-link:hover::after {
    right: 50%;
    transform: translateX(50%);
}

/* Spacing Reversals */
body[dir="rtl"] .space-x-3 > * + *,
body[dir="rtl"] .space-x-4 > * + *,
body[dir="rtl"] .space-x-8 > * + * {
    margin-left: 0;
    margin-right: var(--tw-space-x-reverse);
}

body[dir="rtl"] .mr-3 {
    margin-right: 0;
    margin-left: 0.75rem;
}

body[dir="rtl"] .ml-3 {
    margin-left: 0;
    margin-right: 0.75rem;
}

/* Flex Direction Adjustments */
body[dir="rtl"] .flex-row {
    flex-direction: row-reverse;
}

/* Icons and Check Marks */
body[dir="rtl"] .fas.fa-check-circle,
body[dir="rtl"] .mr-3 {
    margin-right: 0;
    margin-left: 0.75rem;
}

/* Hero Section RTL */
body[dir="rtl"] .hero-section .flex.justify-start {
    justify-content: flex-start;
}

/* Product Image Adjustments */
body[dir="rtl"] .order-1 {
    order: 2;
}

body[dir="rtl"] .order-2 {
    order: 1;
}

body[dir="rtl"] .md\:order-1 {
    order: 1;
}

body[dir="rtl"] .md\:order-2 {
    order: 2;
}

@media (min-width: 768px) {
    body[dir="rtl"] .md\:order-1 {
        order: 2;
    }
    
    body[dir="rtl"] .md\:order-2 {
        order: 1;
    }
}

/* Contact Icons */
body[dir="rtl"] .contact-icon {
    margin-right: 0;
    margin-left: 18px;
}

/* Social Icons */
body[dir="rtl"] .flex.space-x-4 {
    direction: ltr;
}

/* Text Alignment */
body[dir="rtl"] .text-left {
    text-align: right;
}

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

/* Floating Buttons - Keep on right side for both LTR and RTL */
body[dir="rtl"] .whatsapp-float,
body[dir="rtl"] .scroll-top {
    right: 30px;
    left: auto;
}

/* Logo and Brand Elements - Keep aligned properly */
body[dir="rtl"] .flex.items-center.space-x-3 {
    flex-direction: row;
}

/* Language Switcher */
.lang-switcher {
    display: inline-flex;
    background: rgba(181, 141, 106, 0.1);
    border-radius: 4px;
    padding: 2px;
    border: 1px solid var(--gold-color);
}

.lang-switcher a {
    padding: 6px 12px;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.lang-switcher a.active {
    background: var(--gold-color);
    color: white;
}

.lang-switcher a:hover:not(.active) {
    background: rgba(181, 141, 106, 0.2);
}

/* ============================================
   Video Section - RTL Specific Adjustments
   ============================================ */

body[dir="rtl"] .video-section {
    width: 100%;
    background: var(--primary-color);
    padding: 0;
    margin: 0;
    position: relative;
}

body[dir="rtl"] .video-container {
    position: relative;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
    background: var(--primary-dark);
}

body[dir="rtl"] .hero-video {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    min-height: 400px;
    max-height: 700px;
}

/* Mobile optimization */
@media (max-width: 768px) {
    body[dir="rtl"] .hero-video {
        min-height: 300px;
        max-height: 500px;
    }
}
