/* 
   ==========================================================================
   AL-ATAA PREMIUM STYLES
   Mobile-First | Clean Architecture | Performance Optimized
   ========================================================================== 
*/

:root {
    --primary: #ff9933;
    --primary-dark: #cc7a29;
    --dark: #1a1a1a;
    --light: #f4f4f4;
    --white: #ffffff;
    --gray: #666666;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: all 0.3s ease;
}

/* --- RESET & BASIC --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background: var(--light);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

/* --- HEADER --- */
.main-header {
    background: var(--dark);
    /* Dark Header Reverted */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
    border-bottom: none;
}

.desktop-nav ul li a {
    font-weight: 500;
    font-size: 16px;
    position: relative;
    color: var(--white);
    /* Reverted to white */
    transition: var(--transition);
}

.desktop-nav ul li a:hover,
.desktop-nav ul li a.active {
    color: var(--primary);
}

.btn-lang {
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--white);
    /* Reverted to white */
    font-weight: bold;
    padding: 5px 15px;
    border-radius: 20px;
    cursor: pointer;
    font-family: inherit;
    transition: var(--transition);
}

.btn-lang:hover {
    background: var(--primary);
    color: var(--white);
}

.logo-container img {
    height: 50px;
}



/* Desktop Nav */
.desktop-nav {
    display: none;
}

.mobile-toggle {
    font-size: 24px;
    cursor: pointer;
    color: var(--primary);
}

/* Mobile Menu Overlay */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    height: 100vh;
    background: var(--white);
    display: flex;
    flex-direction: column;
    padding: 60px 20px;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    transition: 0.4s ease;
    z-index: 1100;
}

.mobile-menu.active {
    right: 0;
}

.close-menu {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 30px;
    cursor: pointer;
}

.mobile-menu ul li {
    margin-bottom: 20px;
}

.mobile-menu ul li a {
    font-size: 18px;
    font-weight: 600;
    display: block;
}

/* --- HERO SECTION --- */
.hero-section {
    position: relative;
    height: 80vh;
    /* Mobile height */
    background: url('../assets/img/Header/header-background.webp') no-repeat center center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-align: center;
    padding: 0 20px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.7));
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.hero-content h1 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
    text-transform: uppercase;
}

.hero-content p {
    font-size: 1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 14px;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(255, 153, 51, 0.4);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--white);
    color: var(--dark);
}

.btn-secondary:hover {
    background: #eee;
    transform: translateY(-2px);
}

/* --- SECTIONS COMMON --- */
section {
    padding: 60px 20px;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--dark);
    margin-bottom: 10px;
    display: inline-block;
    border-bottom: 3px solid var(--primary);
}

/* --- SERVICES GRID --- */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile 1 col */
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.card-image {
    height: 200px;
    overflow: hidden;
}

.card-image img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    transition: 0.5s ease;
}

.service-card:hover .card-image img {
    transform: scale(1.1);
}

.card-content {
    padding: 25px;
    text-align: left;
    /* Aligned left for better read */
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: var(--dark);
}

.card-content p {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 20px;
    flex-grow: 1;
}

.btn-text {
    font-weight: bold;
    color: var(--primary);
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.service-card:hover .btn-text {
    color: var(--primary-dark);
    gap: 12px;
    /* Arrow moves */
}

.service-card:hover .btn-text i {
    transform: translateX(3px);
}

/* About Section Styles */
.about-section {
    background: var(--light);
    /* Slight distinction */
    padding: 80px 20px;
}

.about-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: center;
}

.about-image {
    width: 100%;
}

.image-wrapper {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.image-wrapper img {
    width: 100%;
    display: block;
}

.about-text {
    width: 100%;
}

.lead {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--primary);
    margin-bottom: 15px;
}

.about-features {
    margin: 20px 0 30px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.about-features span {
    font-weight: 600;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.about-features span i {
    color: var(--primary);
}

/* --- FEATURES --- */
.features-section {
    background: var(--white);
}

.features-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.feature-item {
    width: 45%;
    /* 2 cols mobile */
    text-align: center;
    padding: 20px;
    background: var(--light);
    border-radius: var(--radius);
}

.feature-item i {
    font-size: 30px;
    color: var(--primary);
    margin-bottom: 15px;
}

/* --- FOOTER --- */
footer {
    background: var(--dark);
    color: var(--white);
    padding: 50px 20px 20px;
}

.footer-container {
    display: grid;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-col h3 {
    color: var(--primary);
    margin-bottom: 20px;
}

.social-links a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin: 0 5px;
}

.social-links a:hover {
    background: var(--primary);
}

.footer-bottom {
    text-align: center;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--gray);
    font-size: 0.8rem;
}

/* --- FLOATING WA --- */
.float-wa {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 32px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    z-index: 999;
}

/* --- DESKTOP STYLES (Min 768px) --- */
@media (min-width: 768px) {

    /* Nav */
    .mobile-toggle {
        display: none;
    }

    .desktop-nav {
        display: block;
    }

    .desktop-nav ul {
        display: flex;
        gap: 30px;
        align-items: center;
    }

    .desktop-nav ul li a {
        font-weight: 500;
        font-size: 16px;
        position: relative;
        color: rgba(255, 255, 255, 0.8);
        transition: var(--transition);
    }

    .desktop-nav ul li a:hover,
    .desktop-nav ul li a.active {
        color: var(--primary);
    }

    /* About Desktop */
    .about-container {
        flex-direction: row;
        text-align: left;
    }

    .about-image,
    .about-text {
        width: 50%;
    }

    .section-title.left-align {
        text-align: left;
    }

    .section-title.left-align h2 {
        margin-left: 0;
    }

    /* Hero */
    .hero-content h1 {
        font-size: 3.5rem;
    }

    .hero-buttons {
        flex-direction: row;
        justify-content: center;
    }

    /* Services */
    .services-grid {
        grid-template-columns: repeat(3, 1fr);
        /* 3 Cols */
    }

    /* Features */
    .feature-item {
        width: 22%;
    }

    /* Footer */
    .footer-container {
        grid-template-columns: 1fr 1fr;
        text-align: left;
    }
}

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

[dir="rtl"] .about-container {
    text-align: right;
}

[dir="rtl"] .section-title.left-align,
[dir="rtl"] .card-content,
[dir="rtl"] .footer-container {
    text-align: right;
}

[dir="rtl"] .btn-text i {
    transform: rotate(180deg);
}

[dir="rtl"] .service-card:hover .btn-text i {
    transform: translateX(-3px) rotate(180deg);
}

[dir="rtl"] .float-wa {
    left: 25px;
    right: auto;
}

/* Reset margin for RTL */
[dir="rtl"] .section-title.left-align h2 {
    margin-right: 0;
    margin-left: auto;
    /* Fallback if needed */
}

/* --- REDESIGNED MOBILE MENU & LOGO --- */

/* 1. Smaller Logo on Mobile */
@media (max-width: 768px) {
    .logo img {
        height: 40px !important;
        /* Force smaller size as requested */
        width: auto;
    }
}

/* 2. Glassmorphism Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    /* Fallback */
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1100;
    display: flex;
    flex-direction: column;
    padding: 20px;
    transform: translateX(100%);
    transition: transform 0.6s cubic-bezier(0.7, 0, 0.3, 1);
    opacity: 0;
    visibility: hidden;
}

[dir="rtl"] .mobile-menu {
    transform: translateX(-100%);
}

.mobile-menu.active {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
}

/* Header (Close Button) */
.mobile-menu-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 40px;
}

.close-menu {
    font-size: 40px;
    cursor: pointer;
    color: var(--dark);
    line-height: 1;
    transition: 0.3s;
}

.close-menu:hover {
    color: var(--primary);
    transform: rotate(90deg);
}

/* Nav List */
.mobile-nav-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 25px;
    align-items: center;
    margin-bottom: auto;
    /* Push actions to bottom */
}

.mobile-nav-list li {
    opacity: 0;
    transform: translateY(20px);
    transition: 0.4s ease forwards;
    transition-delay: calc(0.1s * var(--i));
}

.mobile-menu.active .mobile-nav-list li {
    opacity: 1;
    transform: translateY(0);
}

.mobile-nav-list a {
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--dark);
    text-transform: uppercase;
    text-decoration: none;
    transition: 0.3s;
    letter-spacing: -1px;
}

.mobile-nav-list a:hover {
    color: var(--primary);
    letter-spacing: 1px;
}

/* Actions Footer */
.mobile-menu-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(20px);
    transition: 0.5s ease 0.6s forwards;
}

.mobile-menu.active .mobile-menu-actions {
    opacity: 1;
    transform: translateY(0);
}

.mobile-lang-btn {
    background: transparent;
    border: 2px solid var(--dark);
    color: var(--dark);
    padding: 15px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    transition: 0.3s;
}

.mobile-lang-btn:active {
    transform: scale(0.98);
}

.mobile-quote-btn {
    background: var(--primary);
    color: white;
    padding: 15px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-decoration: none;
    box-shadow: 0 10px 20px rgba(255, 153, 51, 0.3);
    transition: 0.3s;
}

.mobile-quote-btn:active {
    transform: scale(0.98);
}