/* Robo Iraq - Custom CSS with Green and Pink Theme */

/* Font Face Declaration */
@font-face {
    font-family: 'Avenir';
    src: url('../fonts/AvenirLTStd-Medium.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

/* Additional font weights for Avenir - fallback to system fonts for different weights */
h1, h2, h3, h4, h5, h6,
.section-title,
.hero-title,
.navbar-brand,
.product-name,
.btn {
    font-family: 'Avenir', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* Optimize font rendering */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

:root {
    --primary-color1: #e91e63; /* Pink */
    --primary-color: #ec008c; /* Pink company*/
    --secondary-color: #4caf50; /* Green */
    --primary-dark: #c2185b;
    --secondary-dark: #388e3c;
    --light-pink: #fce4ec;
    --light-green: #e8f5e8;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --white: #ffffff;
    --gray: #6c757d;
    --border-radius: 15px;
    --box-shadow: 0 5px 25px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
    --green-color: #d7df23; 
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Avenir', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

html {
    overflow-x: hidden;
    width: 100%;
}

/* Prevent horizontal scroll issues */
.container-fluid {
    padding-left: 15px;
    padding-right: 15px;
    max-width: 100%;
    overflow-x: hidden;
}

.container {
    max-width: 100%;
    overflow-x: hidden;
}

/* Arabic Font Support */
[lang="ar"] body {
    font-family: 'Cairo', 'Avenir', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    direction: rtl;
}

[lang="ar"] h1, 
[lang="ar"] h2, 
[lang="ar"] h3, 
[lang="ar"] h4, 
[lang="ar"] h5, 
[lang="ar"] h6,
[lang="ar"] .section-title,
[lang="ar"] .hero-title,
[lang="ar"] .navbar-brand,
[lang="ar"] .product-name,
[lang="ar"] .btn {
    font-family: 'Cairo', 'Avenir', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* RTL Support */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .navbar-nav {
    margin-left: 0;
    margin-right: auto;
}

[dir="rtl"] .text-md-end {
    text-align: right !important;
}

[dir="rtl"] .me-2 {
    margin-left: 0.5rem !important;
    margin-right: 0 !important;
}

[dir="rtl"] .ms-auto {
    margin-left: 0 !important;
    margin-right: auto !important;
}

/* Language Switcher */
.language-switcher {
    margin-left: 15px;
}

[dir="rtl"] .language-switcher {
    margin-left: 0;
    margin-right: 15px;
}

.language-switcher .dropdown-toggle {
    border: 2px solid rgba(255,255,255,0.5) !important;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(10px);
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: var(--transition);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    font-weight: 500;
    color: var(--dark-color) !important;
    min-width: 120px;
}

.language-switcher .dropdown-toggle:hover {
    border-color: var(--primary-color) !important;
    background: rgba(233, 30, 99, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(233, 30, 99, 0.3);
    color: var(--primary-color) !important;
}

.language-switcher .dropdown-toggle:focus {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(233, 30, 99, 0.25);
}

.language-switcher .dropdown-menu {
    min-width: 150px;
    border: none;
    border-radius: 15px;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    padding: 0.5rem 0;
    overflow: visible !important;
    max-height: none !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

.language-switcher .dropdown-menu::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

.language-switcher .dropdown-item {
    padding: 0.75rem 1.25rem;
    font-weight: 500;
    transition: var(--transition);
    border-radius: 10px;
    margin: 0.2rem 0.5rem;
    color: var(--dark-color);
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: auto !important;
    max-width: none !important;
}

.language-switcher .dropdown-item:hover {
    background: linear-gradient(45deg, var(--light-pink), var(--light-green));
    color: var(--primary-color);
    transform: translateX(3px);
}

[dir="rtl"] .language-switcher .dropdown-item:hover {
    transform: translateX(-3px);
}

.language-switcher .dropdown-item.active {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(233, 30, 99, 0.3);
}

/* Ensure dropdown appears properly */
.language-switcher .dropdown {
    position: static !important;
}

.language-switcher .dropdown-menu {
    position: absolute !important;
    z-index: 9999 !important;
    transform: none !important;
}

/* Mobile responsive adjustments for language switcher */
@media (max-width: 768px) {
    .language-switcher .dropdown-toggle {
        min-width: 100px;
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
    }
    
    .language-switcher .dropdown-menu {
        min-width: 130px;
        font-size: 0.9rem;
    }
    
    .language-switcher .dropdown-item {
        padding: 0.6rem 1rem;
    }
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    /* background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); */
    background: var(--green-color);
    border-radius: 2px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--gray);
    max-width: 600px;
    margin: 0 auto;
}

/* Custom Button Styles */
.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
    border: none;
    border-radius: var(--border-radius);
    padding: 12px 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    box-shadow: var(--box-shadow);
}

.btn-primary:hover {
    background: linear-gradient(45deg, var(--primary-dark), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(233, 30, 99, 0.3);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: var(--border-radius);
    padding: 10px 25px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

/* Navigation */
.custom-navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    transition: var(--transition);
    padding: 1rem 0;
    width: 100%;
    z-index: 1030;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-color) !important;
}

.brand-text {
    background:black;/*linear-gradient(45deg, var(--primary-color), var(--secondary-color));*/
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-nav .nav-link {
    color: var(--dark-color) !important;
    font-weight: 500;
    margin: 0 15px;
    /* padding: 10px 0 !important; */
    position: relative;
    transition: var(--transition);
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    transition: var(--transition);
}

.navbar-nav .nav-link:hover::after {
    width: 100%;
}

/* Mobile Navigation Improvements */
.navbar-toggler {
    border: none;
    padding: 4px 8px;
    border-radius: 8px;
    background: rgba(233, 30, 99, 0.1);
    transition: var(--transition);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(233, 30, 99, 0.25);
}

.navbar-toggler:hover {
    background: rgba(233, 30, 99, 0.2);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23e91e63' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    width: 1.5em;
    height: 1.5em;
}

/* Mobile menu styles */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        border-radius: 15px;
        margin-top: 1rem;
        padding: 1.5rem;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        border: 1px solid rgba(233, 30, 99, 0.1);
        position: absolute;
        top: 100%;
        left: 15px;
        right: 15px;
        z-index: 1000;
    }
    
    .navbar-nav {
        text-align: center;
        width: 100%;
    }
    
    .navbar-nav .nav-item {
        width: 100%;
    }
    
    .navbar-nav .nav-link {
        margin: 0;
        padding: 12px 20px !important;
        border-bottom: 1px solid rgba(233, 30, 99, 0.1);
        font-size: 1.1rem;
        font-weight: 600;
        display: block;
        width: 100%;
        text-align: center;
    }
    
    .navbar-nav .nav-item:last-child .nav-link {
        border-bottom: none;
    }
    
    .navbar-nav .nav-link::after {
        display: none;
    }
    
    .navbar-nav .nav-link:hover {
        background: rgba(233, 30, 99, 0.05);
        border-radius: 10px;
        color: var(--primary-color) !important;
        transform: translateX(5px);
    }
    
    /* RTL support for mobile menu */
    [dir="rtl"] .navbar-nav .nav-link:hover {
        transform: translateX(-5px);
    }
    
    /* Language switcher adjustments for mobile */
    .language-switcher {
        margin: 1rem 0 0 0;
        display: flex;
        justify-content: center;
        width: 100%;
    }
    
    .language-switcher .dropdown-toggle {
        width: 100%;
        max-width: 200px;
        justify-content: center;
    }
    
    .language-switcher .dropdown-menu {
        position: absolute !important;
        inset: 0px auto auto 50% !important;
        transform: translate(-50%, 0px) !important;
    }
}

/* Hero Section */
.hero-section {
    height: 100vh;
    height: calc(var(--vh, 1vh) * 100);
    position: relative;
    overflow: hidden;
    width: 100%;
}

.hero-slide {
    height: 100vh;
    height: calc(var(--vh, 1vh) * 100);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    width: 100%;
}

/* Mobile-first approach for hero slides */
@media (max-width: 768px) {
    .hero-slide {
        background-size: cover;
        background-position: center center;
        background-color: #f8f9fa; /* Fallback color */
        min-height: 100vh;
    }
    
    /* Alternative: Use background-size: contain to show full image */
    .hero-slide.show-full {
        background-size: contain;
        background-position: center center;
        background-color: #000; /* Dark background for letterboxing */
    }
}

/* For very small screens, ensure images fit properly */
@media (max-width: 480px) {
    .hero-slide {
        background-size: contain; /* Show full image instead of cropping */
        background-position: center top; /* Position image at top */
        background-color: #000; /* Dark background for letterboxing */
        min-height: 100vh;
        background-repeat: no-repeat;
    }
    
    .hero-section {
        background: #000; /* Dark background for sections too */
        position: relative;
    }
    
    .hero-content {
        position: absolute;
        bottom: 100px; /* More space from bottom for indicators */
        left: 50%;
        transform: translateX(-50%); /* Perfect horizontal centering */
        width: calc(100vw - 30px); /* Full viewport width minus margins */
        max-width: 350px;
        background: rgba(0,0,0,0.85);
        border-radius: 12px;
        padding: 20px;
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        border: 1px solid rgba(255,255,255,0.15);
        margin: 0; /* Remove any default margins */
        text-align: center; /* Ensure text is centered */
    }
}

/* Landscape mobile devices */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-slide {
        background-size: contain; /* Show full image in landscape */
        background-position: center;
        background-color: #000;
        height: 100vh;
        background-repeat: no-repeat;
    }
    
    .hero-content {
        position: absolute;
        bottom: 20px; /* Even lower in landscape mode */
        left: 50%;
        transform: translateX(-50%);
        width: 80%;
        max-width: 600px;
        background: rgba(0,0,0,0.8);
        border-radius: 10px;
        padding: 15px 20px;
    }
    
    .hero-title {
        font-size: 1.5rem;
        margin-bottom: 0.5rem;
    }
    
    .hero-description {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* background: linear-gradient(135deg, rgba(233, 30, 99, 0.8), rgba(76, 175, 80, 0.6)); */
}

.hero-content {
    position: relative;
    z-index: 2;
    color: var(--white);
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-description {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.carousel-control-prev,
.carousel-control-next {
    width: 5%;
}

.carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin: 0 5px;
}

/* Products Section */
.products-section {
    padding: 100px 0;
    background-color: var(--white);
}

.product-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.product-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.badge-featured {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(45deg, var(--primary-color), var(--primary-color));
    /* background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); */
    color: var(--white);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.product-info {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-name {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.product-category {
    color: var(--green-color);
    font-weight: 500;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.product-description {
    color: var(--gray);
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.product-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.product-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Spare Parts Section */
.spare-parts-section {
    padding: 100px 0;
    background-color: var(--light-color);
}

.spare-part-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.spare-part-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.spare-part-image {
    height: 200px;
    overflow: hidden;
    background-color: var(--light-color);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.spare-part-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.spare-part-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.spare-part-name {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
    line-height: 1.4;
    text-align: left;
}

.spare-part-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
    text-align: left;
}

.spare-part-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: auto;
}

.spare-part-actions .btn {
    flex: 1;
    min-width: 120px;
}

.spare-part-actions .btn-group {
    flex: 0 0 auto;
}

.part-number {
    color: var(--gray);
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    display: block;
    text-align: left;
}

.part-number {
    color: var(--gray);
    font-size: 0.75rem;
}

/* Contact Section */
.contact-section {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--light-pink), var(--light-green));
}

.contact-form-wrapper {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.contact-form .form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 15px 20px;
    font-size: 1rem;
    transition: var(--transition);
}

.contact-form .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(233, 30, 99, 0.25);
}

.contact-info {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    height: fit-content;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
}

.contact-icon {
    width: 60px;
    height: 60px;
    /* background: var(--green-color); */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    flex-shrink: 0;
}

.contact-icon i {
    color: var(--dark-color);
    font-size: 1.2rem;
}

.contact-details h5 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.contact-details p,
.contact-details a {
    color: var(--gray);
    margin-bottom: 0;
    text-decoration: none;
}

.contact-details a:hover {
    color: var(--primary-color);
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-icons a {
    width: 45px;
    height: 45px;
    /* background: var(--green-color); */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--dark-color);
    text-decoration: none;
    transition: var(--transition);
}

.social-icons a:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(233, 30, 99, 0.4);
}

/* Footer */
.footer {
    background-color: var(--dark-color);
    color: var(--white);
    overflow-x: hidden;
    padding-left: 0;
    padding-right: 0;
}

.footer .container {
    max-width: 100%;
    padding-left: 10px;
    padding-right: 10px;
}

.footer p {
    margin-bottom: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
    max-width: 100%;
}

/* Responsive footer text */
@media (max-width: 768px) {
    .footer p {
        font-size: 0.75rem !important;
        line-height: 1.4 !important;
        padding: 0 5px !important;
    }
}

@media (max-width: 480px) {
    .footer p {
        font-size: 0.65rem !important;
        line-height: 1.3 !important;
    }
}

/* Sales Centers Section */
.sales-centers-section {
    background-color: var(--light-color);
}

.sales-center-card {
    transition: var(--transition);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: none;
}

.sales-center-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.sales-center-card .card-title {
    font-size: 1.1rem;
    font-weight: 600;
}

.sales-center-card .card-text {
    color: var(--gray);
    margin-bottom: 0.75rem;
}

.sales-center-card .card-text i {
    width: 20px;
}

.sales-center-card a[href^="tel:"] {
    color: var(--secondary-color);
    font-weight: 500;
}

.sales-center-card a[href^="tel:"]:hover {
    color: var(--secondary-dark);
}

.btn-outline-light {
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.btn-outline-light:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background: #25d366;
    color: var(--white);
    border-radius: 50%;
    text-align: center;
    font-size: 2rem;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: var(--transition);
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

.whatsapp-float a {
    color: var(--white);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* Modal Customization */
.modal-content {
    border-radius: var(--border-radius);
    border: none;
    box-shadow: var(--box-shadow);
}

.modal-header {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    border-bottom: none;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.btn-close {
    filter: invert(1);
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Fix horizontal scrolling and layout issues */
    body {
        width: 100vw;
        overflow-x: hidden;
    }
    
    .container {
        padding-left: 15px;
        padding-right: 15px;
        max-width: 100%;
    }
    
    .row {
        margin-left: 0;
        margin-right: 0;
    }
    
    .col-12,
    [class*="col-"] {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    /* Hero section mobile fixes */
    .hero-section {
        height: 100vh;
        width: 100%;
        overflow: hidden;
        min-height: 500px; /* Ensure minimum height */
        background: #000; /* Dark background for letterboxing */
    }
    
    .hero-slide {
        background-size: contain !important; /* Show full image */
        background-position: center center !important;
        background-attachment: scroll; /* Fix for mobile scrolling issues */
        background-repeat: no-repeat !important;
        background-color: #000 !important; /* Dark background */
    }
    
    .hero-title {
        font-size: 2.2rem;
        line-height: 1.2;
        margin-bottom: 1rem;
        text-shadow: 2px 2px 8px rgba(0,0,0,0.9); /* Stronger shadow for visibility */
        font-weight: 700;
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
        text-shadow: 1px 1px 4px rgba(0,0,0,0.9); /* Stronger shadow for visibility */
    }
    
    .hero-content {
        padding: 20px;
        text-align: center;
        background: rgba(0,0,0,0.8); /* Darker background for better contrast */
        border-radius: 15px;
        backdrop-filter: blur(5px); /* Blur effect for better readability */
        -webkit-backdrop-filter: blur(5px);
        border: 1px solid rgba(255,255,255,0.1);
        position: absolute;
        bottom: 80px; /* Position text near bottom of screen */
        left: 50%;
        transform: translateX(-50%); /* Perfect horizontal centering */
        width: calc(100vw - 40px); /* Full width minus margins */
        max-width: 500px;
        margin: 0; /* Remove any default margins */
    }
    
    /* Section adjustments */
    .section-title {
        font-size: 2rem;
        margin-bottom: 0.8rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
        padding: 0 15px;
    }
    
    /* Product and spare part cards */
    .product-actions {
        justify-content: center;
        flex-direction: column;
        gap: 8px;
    }
    
    .product-actions .btn {
        width: 100%;
        padding: 10px;
        font-size: 0.9rem;
    }
    
    /* Contact section mobile */
    .contact-form-wrapper,
    .contact-info {
        padding: 25px;
        margin-bottom: 2rem;
    }
    
    .contact-item {
        margin-bottom: 20px;
    }
    
    .contact-icon {
        width: 50px;
        height: 50px;
        margin-right: 15px;
    }
    
    [dir="rtl"] .contact-icon {
        margin-right: 0;
        margin-left: 15px;
    }
    
    /* Social icons mobile */
    .social-icons {
        justify-content: center;
        gap: 10px;
    }
    
    .social-icons a {
        width: 40px;
        height: 40px;
    }
    
    /* Navbar mobile specific */
    .navbar-nav .nav-link {
        margin: 0 5px;
        font-size: 1rem;
    }
    
    /* Cards spacing */
    .product-card,
    .spare-part-card {
        margin-bottom: 2rem;
        max-width: 100%;
    }
    
    /* WhatsApp button mobile */
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 576px) {
    /* Extra small devices */
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .section-subtitle {
        font-size: 0.9rem;
    }
    
    /* Smaller padding for mobile */
    .contact-form-wrapper,
    .contact-info {
        padding: 20px;
    }
    
    /* Product cards for very small screens - 2 columns */
    .col-lg-3.col-md-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
    
    /* Make product cards more compact on mobile */
    .product-card {
        margin-bottom: 15px;
    }
    
    .product-card .product-info {
        padding: 10px;
    }
    
    .product-card .product-name {
        font-size: 0.85rem;
        line-height: 1.2;
        margin-bottom: 5px;
    }
    
    .product-card .product-category {
        font-size: 0.7rem;
        margin-bottom: 3px;
    }
    
    .product-card .product-description {
        font-size: 0.75rem;
        line-height: 1.3;
        margin-bottom: 8px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    
    .product-card .product-price {
        font-size: 0.85rem;
        margin-bottom: 8px;
    }
    
    .product-card .price-original {
        font-size: 0.7rem;
    }
    
    .product-card .savings-amount {
        font-size: 0.65rem;
    }
    
    .product-card .product-actions {
        flex-direction: column;
        gap: 5px;
    }
    
    .product-card .product-actions .btn {
        font-size: 0.75rem;
        padding: 6px 10px;
        width: 100%;
    }
    
    .product-card .product-actions .btn-group {
        width: 100%;
    }
    
    .product-card .product-actions .btn-group .btn {
        width: auto;
    }
    
    .product-card .text-muted.small {
        font-size: 0.7rem;
    }
    
    /* Make spare part cards compact on mobile */
    .spare-part-card .spare-part-info {
        padding: 10px;
    }
    
    .spare-part-card .spare-part-name {
        font-size: 0.85rem;
        line-height: 1.2;
        margin-bottom: 5px;
    }
    
    .spare-part-card .spare-part-price {
        font-size: 0.85rem;
        margin-bottom: 5px;
    }
    
    .spare-part-card .part-number {
        font-size: 0.7rem;
    }
    
    .spare-part-card .spare-part-actions {
        flex-direction: column;
        gap: 5px;
    }
    
    .spare-part-card .spare-part-actions .btn {
        font-size: 0.75rem;
        padding: 6px 10px;
        width: 100%;
    }
    
    /* Adjust badges for mobile */
    .badge-featured,
    .discount-badge,
    .sale-badge {
        font-size: 0.65rem;
        padding: 3px 6px;
    }
    
    /* Spare parts grid for small screens */
    .spare-parts-section .col-lg-2.col-md-3.col-sm-4.col-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
    
    /* Language switcher mobile */
    .language-switcher .dropdown-toggle {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
        min-width: 90px;
    }
    
    /* Navbar brand mobile */
    .navbar-brand {
        font-size: 1.2rem;
    }
    
    .navbar-brand img {
        height: 30px;
    }
}

/* Landscape orientation fixes for mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-section {
        height: 100vh;
        min-height: 500px;
    }
    
    .hero-slide {
        height: 100vh;
        min-height: 500px;
        background-size: cover !important;
        background-position: center !important;
    }
    
    .hero-content {
        padding-top: 2rem;
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: 1rem;
    }
}

/* Additional mobile hero fixes */
@media (max-width: 576px) {
    .hero-section {
        height: 100vh;
        height: calc(var(--vh, 1vh) * 100);
        min-height: 600px;
        background: #000; /* Dark background */
    }
    
    .hero-slide {
        height: 100vh;
        height: calc(var(--vh, 1vh) * 100);
        min-height: 600px;
        background-size: contain !important; /* Show full image */
        background-position: center !important;
        background-repeat: no-repeat !important;
        background-color: #000 !important;
    }
    
    .hero-content {
        position: absolute;
        bottom: 90px; /* Position at bottom instead of center */
        left: 4%;
        transform: translateX(-50%); /* Perfect horizontal centering */
        width: calc(100vw - 30px); /* Full viewport width minus small margins */
        max-width: 400px;
        background: rgba(0,0,0,0.8); /* Darker background for better contrast */
        border-radius: 15px;
        padding: 25px;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(255,255,255,0.2);
        margin: 0; /* Remove any default margins */
        text-align: center; /* Center align all text content */
    }
    
    .hero-title {
        font-size: 1.8rem;
        font-weight: 700;
        text-shadow: 2px 2px 8px rgba(0,0,0,1);
        margin-bottom: 1rem;
    }
    
    .hero-description {
        font-size: 0.95rem;
        text-shadow: 1px 1px 4px rgba(0,0,0,1);
        line-height: 1.4;
    }
}

/* Fix for iPhone notch and safe areas */
@supports (padding: max(0px)) {
    .navbar {
        padding-left: max(15px, env(safe-area-inset-left));
        padding-right: max(15px, env(safe-area-inset-right));
    }
    
    .container {
        padding-left: max(15px, env(safe-area-inset-left));
        padding-right: max(15px, env(safe-area-inset-right));
    }
}

/* Prevent zoom on input focus for iOS */
@media screen and (-webkit-min-device-pixel-ratio: 0) {
    select,
    textarea,
    input[type="text"],
    input[type="password"],
    input[type="datetime"],
    input[type="datetime-local"],
    input[type="date"],
    input[type="month"],
    input[type="time"],
    input[type="week"],
    input[type="number"],
    input[type="email"],
    input[type="url"],
    input[type="search"],
    input[type="tel"],
    input[type="color"] {
        font-size: 16px;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    /* background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); */
    background: var(--green-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, var(--primary-dark), var(--secondary-dark));
}

/* Rich Text Content Styles */
.rich-content {
    line-height: 1.8;
}

.rich-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin: 1rem 0;
    transition: var(--transition);
}

.rich-content img:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

.rich-content .image {
    margin: 1.5rem 0;
    text-align: center;
}

.rich-content .image-style-side {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
    max-width: 50%;
}

.rich-content .image-style-align-left {
    float: left;
    margin-right: 1.5rem;
    margin-bottom: 1rem;
    max-width: 50%;
}

.rich-content .image-style-align-right {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
    max-width: 50%;
}

/* Clear floats after rich content */
.rich-content::after {
    content: "";
    display: table;
    clear: both;
}

/* Rich content headings */
.rich-content h1,
.rich-content h2,
.rich-content h3,
.rich-content h4,
.rich-content h5,
.rich-content h6 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.rich-content h1 { font-size: 2rem; }
.rich-content h2 { font-size: 1.75rem; }
.rich-content h3 { font-size: 1.5rem; }
.rich-content h4 { font-size: 1.25rem; }
.rich-content h5 { font-size: 1.1rem; }
.rich-content h6 { font-size: 1rem; }

/* Rich content lists */
.rich-content ul,
.rich-content ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.rich-content li {
    margin-bottom: 0.5rem;
}

/* Rich content tables */
.rich-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.rich-content table th,
.rich-content table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.rich-content table th {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    font-weight: 600;
}

.rich-content table tr:hover {
    background-color: rgba(233, 30, 99, 0.05);
}

/* Rich content blockquotes */
.rich-content blockquote {
    border-left: 4px solid var(--primary-color);
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
    background: var(--light-pink);
    font-style: italic;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

/* Rich content links */
.rich-content a {
    color: var(--primary-color);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: var(--transition);
}

.rich-content a:hover {
    border-bottom-color: var(--primary-color);
}

/* Responsive rich content */
@media (max-width: 768px) {
    .rich-content .image-style-side,
    .rich-content .image-style-align-left,
    .rich-content .image-style-align-right {
        float: none;
        margin: 1rem 0;
        max-width: 100%;
    }
    
    .rich-content table {
        font-size: 0.9rem;
    }
    
    .rich-content ul,
    .rich-content ol {
        padding-left: 1.5rem;
    }
}

/* Product Media Gallery Styles */
.product-media-gallery {
    max-width: 100%;
}

.product-main-image {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.product-main-image:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

/* Custom carousel indicators as thumbnails */
.carousel-indicators {
    justify-content: center;
    gap: 5px;
    margin-bottom: 0;
}

.carousel-indicators button {
    border-radius: 8px;
    border: 2px solid var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: var(--transition);
    opacity: 0.7;
}

.carousel-indicators button:hover,
.carousel-indicators button.active {
    opacity: 1;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px var(--primary-color);
}

/* Video styling */
.product-videos video {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

/* Responsive adjustments for product gallery */
@media (max-width: 768px) {
    .product-main-image {
        height: 250px !important;
    }
    
    .carousel-indicators button {
        width: 40px !important;
        height: 40px !important;
    }
    
    .product-videos video {
        max-height: 200px !important;
    }
}

@media (max-width: 576px) {
    .product-main-image {
        height: 200px !important;
    }
    
    .carousel-indicators button {
        width: 30px !important;
        height: 30px !important;
        margin: 0 2px !important;
    }
    
    /* Hero carousel indicators positioning for mobile */
    .hero-section .carousel-indicators {
        bottom: 30px;
        z-index: 15;
    }
    
    .hero-section .carousel-indicators button {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        margin: 0 3px;
        background-color: rgba(255,255,255,0.5);
        border: none;
    }
    
    .hero-section .carousel-indicators button.active {
        background-color: var(--primary-color);
    }
}

/* Discount Styles */
.discount-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #ff4444, #cc0000);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(255, 68, 68, 0.3);
    animation: pulse 2s infinite;
    text-transform: uppercase;
}

.sale-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(233, 30, 99, 0.3);
    text-transform: uppercase;
}

.price-container {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.price-original {
    color: #999;
    text-decoration: line-through;
    font-size: 0.9em;
    font-weight: normal;
}

.price-discounted {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.1em;
}

.savings-amount {
    background: var(--light-green);
    color: var(--secondary-dark);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.8em;
    font-weight: 600;
    white-space: nowrap;
}

/* RTL Support for Discount Badges */
[dir="rtl"] .discount-badge {
    right: auto;
    left: 10px;
}

[dir="rtl"] .sale-badge {
    left: auto;
    right: 10px;
}

/* Pulse animation for discount badge */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Product Card Discount Styles */
.product-card {
    position: relative;
    overflow: hidden;
}

.product-image {
    position: relative;
}

.spare-part-card {
    position: relative;
    overflow: hidden;
}

.spare-part-image {
    position: relative;
}

/* Cart Item Discount Styles */
.cart-item-price {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.cart-item-savings {
    font-size: 0.8em;
    color: var(--secondary-color);
    font-weight: 600;
}

/* Mobile responsiveness for discount elements */
@media (max-width: 768px) {
    .discount-badge,
    .sale-badge {
        font-size: 10px;
        padding: 3px 6px;
        top: 5px;
    }
    
    .discount-badge {
        right: 5px;
    }
    
    .sale-badge {
        left: 5px;
    }
    
    [dir="rtl"] .discount-badge {
        right: auto;
        left: 5px;
    }
    
    [dir="rtl"] .sale-badge {
        left: auto;
        right: 5px;
    }
    
    .price-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}

/* Discount highlight effect */
.product-card:hover .discount-badge,
.spare-part-card:hover .discount-badge {
    animation: pulse 1s ease-in-out;
}

/* Special styling for featured discounted products */
.product-card.featured-discount {
    border: 2px solid var(--primary-color);
    box-shadow: 0 8px 30px rgba(233, 30, 99, 0.2);
}

.product-card.featured-discount .sale-badge {
    background: linear-gradient(135deg, #ff6b6b, #ff5252);
    animation: pulse 2s infinite;
}

/* Override Bootstrap's translate-middle class */
.translate-middle {
    transform: none !important;
}

/* Override Bootstrap's start-100 class */
.start-100 {
    left: auto !important;
}

/* Phone number styling - always LTR */
.phone-number,
a[href^="tel:"] {
    direction: ltr !important;
    text-align: left !important;
    unicode-bidi: embed;
}

/* For RTL pages, ensure phone numbers stay LTR but are right-aligned within their container */
[dir="rtl"] .contact-details .phone-number {
    text-align: right;
    direction: ltr;
    display: inline-block;
}

/* Contact form RTL styling */
[dir="rtl"] .contact-form .form-control {
    text-align: right;
    direction: rtl;
}

[dir="rtl"] .contact-form .form-control::placeholder {
    text-align: right;
    direction: rtl;
}

/* Special handling for phone input - keep it LTR even in Arabic */
[dir="rtl"] .contact-form input[type="tel"] {
    text-align: right;
    direction: ltr;
}

[dir="rtl"] .contact-form input[type="tel"]::placeholder {
    text-align: right;
    direction: rtl;
}

/* Email input should stay LTR for email format */
[dir="rtl"] .contact-form input[type="email"] {
    text-align: right;
    direction: ltr;
}

[dir="rtl"] .contact-form input[type="email"]::placeholder {
    text-align: right;
    direction: rtl;
}
.start-100 {
     right: auto !important; 
}

/* Override Bootstrap text-primary to black */
.text-primary {
    --bs-text-opacity: 1;
    color: rgb(0, 0, 0) !important;
}

/* Product card clickable elements */
.product-image a {
    display: block;
    transition: var(--transition);
}

.product-image a:hover {
    transform: scale(1.05);
}

.product-name a {
    transition: var(--transition);
}

.product-name a:hover {
    color: var(--primary-color) !important;
    text-decoration: none !important;
}

.bg-primary {
    --bs-bg-opacity: 1;
    background-color: #000 !important;
}
.bg-warning {
    --bs-bg-opacity: 1;
    background-color: #d7df23 !important; /* Neon green */
}