/* FontAwesome CDN for Icons */
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css');
/* Swiper CSS for professional sliders */
@import url('https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css');
/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Tajawal:wght@300;400;500;700;800&display=swap');

:root {
    --primary-color: #633921;
    --primary-light: #8a5a3d;
    --primary-dark: #3e2213;
    --accent-color: #d4a373;
    --gold-color: #c5a059; /* Premium Gold */
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-color: #ffffff;
    --bg-secondary: #fdfbf7; /* Warm tint */
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.3);
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(99, 57, 33, 0.05);
    --shadow-md: 0 8px 16px rgba(99, 57, 33, 0.08);
    --shadow-lg: 0 16px 32px rgba(99, 57, 33, 0.12);
    --shadow-glow: 0 0 20px rgba(197, 160, 89, 0.3);
    
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
}

[data-theme="dark"] {
    --text-color: #f3f4f6;
    --text-light: #d1d5db;
    --bg-color: #1a1512; /* Deep brown-black */
    --bg-secondary: #241c18; 
    --card-bg: #2a221d;
    --border-color: #3e2f28;
    --glass-bg: rgba(26, 21, 18, 0.85);
    --glass-border: rgba(255, 255, 255, 0.05);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.4);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { 
    scroll-behavior: smooth; 
    scroll-padding-top: 100px; /* Fix for fixed header blocking section titles */
}

body {
    font-family: 'Outfit', sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.7;
    overflow-x: hidden;
}

[dir="rtl"] body { font-family: 'Tajawal', sans-serif; }

a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* Utilities */
.container { max-width: 1400px; margin: 0 auto; padding: 0 2rem; position: relative; }
.section-padding { padding: 6rem 0; }
.text-primary { color: var(--primary-color); }
.text-gold { color: var(--gold-color); }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    box-shadow: 0 4px 15px rgba(99, 57, 33, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 0%; height: 100%;
    background: linear-gradient(135deg, var(--gold-color), #daa520);
    transition: var(--transition);
    z-index: -1;
}

.btn-primary:hover::before { width: 100%; }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 8px 25px rgba(99, 57, 33, 0.4); }

.btn-outline-primary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}
.btn-outline-primary:hover {
    background: var(--primary-color);
    color: white;
}

.section-head {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

.section-title {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    display: block;
    width: 60%;
    height: 4px;
    background: var(--gold-color);
    margin: 10px auto 0;
    border-radius: 2px;
}

/* Header */
header {
    position: fixed;
    top: 0; left: 0; width: 100%;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition);
    height: 90px;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo img { height: 60px; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1)); }

.nav-links { display: flex; gap: 2.5rem; }
.nav-link { 
    font-weight: 600; 
    font-size: 1.05rem;
    position: relative;
    color: var(--text-color);
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: -5px; left: 50%;
    width: 0; height: 2px;
    background: var(--gold-color);
    transition: var(--transition);
    transform: translateX(-50%);
}

.nav-link:hover { color: var(--primary-color); }
.nav-link:hover::before { width: 100%; }

/* Mobile Menu Drawer */
@media (max-width: 900px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%; /* Hidden by default */
        width: 250px;
        height: 100vh;
        background: var(--bg-secondary);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        transition: 0.4s ease;
        padding-top: 60px; /* Space for close button if needed, or just centering */
        z-index: 1001;
        display: flex; /* Override display: none from original media query if using simple class toggle */
    }

    .nav-links.active {
        right: 0;
    }
    
    .mobile-menu-btn { display: block !important; }
}

/* Hero Slider */
.hero-slider-section {
    padding-top: 90px;
    position: relative;
    width: 100%;
    overflow: hidden;
}

.swiper-hero {
    width: 100%;
    height: calc(100vh - 90px);
    min-height: 600px;
    max-height: 900px;
}

.swiper-slide {
    position: relative;
    overflow: hidden;
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* or contain based on banner design, usually cover for full hero */
}

/* If the user wants the banners to be fully visible without cropping, we might need object-fit: contain with a background. 
   But usually hero sliders are 'cover'. */

.slide-content-wrapper {
    /* For semantic H1/p that we are HIDING visually as requested for the slider look 
       or we can place them below. 
       Actually, let's keep them technically there but hidden or put below.
       Strategy: The user said "Sliders content shouldn't be covered".
       I will assume the text is IN the image. 
       I will create a 'Welcome' bar below the slider for the H1 content.
    */
}

/* New Welcome Section bar below hero */
.hero-welcome-bar {
    background: var(--bg-secondary);
    padding: 3rem 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

/* Swiper Customization */
.swiper-button-next, .swiper-button-prev {
    color: var(--gold-color) !important;
    background: rgba(255, 255, 255, 0.9);
    width: 50px !important;
    height: 50px !important;
    border-radius: 50%;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}
.swiper-button-next:hover, .swiper-button-prev:hover {
    background: var(--primary-color);
    color: white !important;
}
.swiper-pagination-bullet-active {
    background: var(--primary-color) !important;
}

/* Products Modern Carousel */
.product-swiper {
    padding: 2rem 1rem 4rem !important;
}

.product-card {
    background: var(--card-bg);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    border: 1px solid var(--border-color);
    height: 100%;
}

.product-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-lg);
    border-color: var(--gold-color);
}

.product-img-wrapper {
    height: 300px;
    overflow: hidden;
    position: relative;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.product-card:hover .product-img {
    transform: scale(1.1);
}

.product-info {
    padding: 1.5rem;
    text-align: center;
}

.product-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

/* Services with Glassmorphism */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(99, 57, 33, 0.05), rgba(197, 160, 89, 0.05));
    opacity: 0;
    transition: var(--transition);
    z-index: -1;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--gold-color);
}
.service-card:hover::before { opacity: 1; }

.service-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    color: var(--gold-color); /* Changed to gold for contrast */
    transition: var(--transition);
}
.service-card:hover .service-icon { transform: scale(1.1) rotate(5deg); }

/* Stats with animation */
.stats-section {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('imgs/back.jpg'); /* Updated background */
    background-size: cover;
    background-attachment: fixed;
    color: white;
    padding: 6rem 0;
    position: relative;
}

.stat-item {
    text-align: center;
    padding: 2rem;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255,255,255,0.2);
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--gold-color);
    display: block;
    margin-bottom: 0.5rem;
}

/* Contact Modern */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.contact-info {
    background: var(--primary-color);
    color: white;
    padding: 4rem 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-info h3 { font-size: 2rem; margin-bottom: 1.5rem; color: var(--gold-color); }
.contact-item { display: flex; align-items: center; margin-bottom: 1.5rem; gap: 1rem; font-size: 1.1rem; }
.contact-item i { width: 40px; height: 40px; background: rgba(255,255,255,0.1); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--gold-color); }

.contact-form-wrapper {
    background: var(--card-bg);
    padding: 4rem 3rem;
}

.form-input {
    width: 100%;
    padding: 1.2rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
    font-family: inherit;
    transition: var(--transition);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: white;
    box-shadow: 0 0 0 4px rgba(99, 57, 33, 0.1);
}

/* Footer & Socials */
.social-icons {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}
.social-icon {
    width: 45px; height: 45px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    display: flex; align-items: center; justify-content: center;
    color: white;
    font-size: 1.2rem;
    border: 1px solid rgba(255,255,255,0.1);
    transition: var(--transition);
}
.social-icon:hover {
    background: var(--gold-color);
    color: var(--primary-color);
    transform: translateY(-5px);
}

/* Animations */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.float-anim { animation: float 6s ease-in-out infinite; }

.hover-scale { transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.hover-scale:hover { transform: scale(1.1); }

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal.active { opacity: 1; transform: translateY(0); }

/* Floating WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    z-index: 1000;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    box-shadow: 0 6px 14px rgba(0,0,0,0.4);
    transform: translateY(-5px);
}
[dir="rtl"] .whatsapp-float {
    right: auto;
    left: 30px;
}

/* Mobile */
@media (max-width: 900px) {
    /* .nav-links { display: none; } Replaced by specific drawer logic above */ 

    .contact-grid { grid-template-columns: 1fr; }
    .section-title { font-size: 2rem; }
    
    /* Mobile Slider Fix */
    .hero-slider-section { 
        padding-top: 80px; 
        height: auto;
        min-height: auto;
    }
    .swiper-hero { 
        height: auto !important; 
        min-height: auto !important;
        max-height: none !important;
    }
    .hero-img {
        height: auto !important;
        width: 100%;
        max-height: none;
        object-fit: contain; /* Ensure full image is visible */
    }
    
    /* About Us Mobile Fix */
    .about-grid { 
        grid-template-columns: 1fr !important; 
        gap: 3rem !important;
        text-align: center;
    }
    .about-text .section-head { text-align: center !important; margin-bottom: 2rem; }
    .about-text p { text-align: justify; text-align-last: center; }
    
    /* Fix overlapping card on mobile */
    .about-img { margin-bottom: 3rem; }
    .about-stat-card {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        margin: -40px auto 0; /* partial overlap */
        transform: none;
        max-width: 250px;
    }
    
    .partners-gap { gap: 2rem !important; }
}
