/* -----------------------------
   CSS Variables (Design System)
----------------------------- */
:root {
    /* Color Palette */
    --clr-primary: #0a2342;
    /* Deep Blue */
    --clr-secondary: #17b890;
    /* Turquoise */
    --clr-secondary-dark: #129071;
    --clr-accent: #f9a03f;
    /* Warm Accent if needed */
    --clr-text-main: #333333;
    --clr-text-muted: #666666;
    --clr-bg-main: #ffffff;
    --clr-bg-light: #f4f7f9;
    --clr-white: #ffffff;

    /* Typography */
    --font-main: 'Cairo', sans-serif;

    /* Transitions */
    --transition: all 0.3s ease;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* Dark Theme Variables */
body.dark-theme {
    --clr-primary: #1e3a5f;
    /* Lighter deep blue for dark mode */
    --clr-text-main: #f0f0f0;
    --clr-text-muted: #aaaaaa;
    --clr-bg-main: #121212;
    --clr-bg-light: #1e1e1e;
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* -----------------------------
   Reset & Base Styles
----------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--clr-bg-main);
    color: var(--clr-text-main);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--transition), color var(--transition);
}

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

ul {
    list-style: none;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    color: var(--clr-primary);
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

body.dark-theme .section-title {
    color: var(--clr-secondary);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: 0;
    /* RTL */
    width: 60px;
    height: 4px;
    background-color: var(--clr-secondary);
    border-radius: 2px;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header .section-title::after {
    right: 50%;
    transform: translateX(50%);
}

.section-header p {
    color: var(--clr-text-muted);
    font-size: 1.1rem;
    margin-top: 1.5rem;
}

.bg-light {
    background-color: var(--clr-bg-light);
}

/* -----------------------------
   Buttons
----------------------------- */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    border: 2px solid transparent;
    text-align: center;
    transition: var(--transition);
}

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

.btn-primary:hover {
    background-color: var(--clr-secondary-dark);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--clr-secondary);
    color: var(--clr-secondary);
}

.btn-outline:hover {
    background-color: var(--clr-secondary);
    color: var(--clr-white);
}

/* -----------------------------
   Navigation (Header)
----------------------------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

body.dark-theme .header {
    background-color: rgba(18, 18, 18, 0.95);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--clr-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

body.dark-theme .logo {
    color: var(--clr-white);
}

.logo i {
    color: var(--clr-secondary);
}

.nav-menu {
    display: flex;
    gap: 30px;
}

.nav-link {
    font-weight: 600;
    color: var(--clr-text-main);
    position: relative;
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    /* RTL */
    width: 0;
    height: 2px;
    background-color: var(--clr-secondary);
    transition: width 0.3s ease;
}

.nav-link:hover::before,
.nav-link.active::before {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.theme-toggle {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: var(--clr-text-main);
    cursor: pointer;
    transition: var(--transition);
}

.theme-toggle:hover {
    color: var(--clr-secondary);
}

/* Hamburger Menu (Mobile) */
.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.hamburger .bar {
    width: 25px;
    height: 3px;
    background-color: var(--clr-text-main);
    transition: var(--transition);
}

/* -----------------------------
   Hero Section
----------------------------- */
.hero {
    height: 100vh;
    min-height: 600px;
    background: url('https://images.unsplash.com/photo-1544550581-5f7ceaf7f992?auto=format&fit=crop&w=1920&q=80') center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px;
    /* Offset for header */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(10, 35, 66, 0.6), rgba(10, 35, 66, 0.8));
}

.hero-content {
    position: relative;
    z-index: 1;
    color: var(--clr-white);
    max-width: 800px;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.hero-tagline {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* -----------------------------
   About Section
----------------------------- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: var(--clr-text-muted);
}

.features-list {
    margin-top: 2rem;
}

.features-list li {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 15px;
    font-weight: 600;
}

.features-list i {
    color: var(--clr-secondary);
    font-size: 1.2rem;
}

.about-image {
    position: relative;
}

.about-image img {
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
}

.about-image::before {
    content: '';
    position: absolute;
    top: -20px;
    right: -20px;
    /* RTL */
    width: 100%;
    height: 100%;
    border: 4px solid var(--clr-secondary);
    border-radius: 20px;
    z-index: -1;
}

/* -----------------------------
   Services Section
----------------------------- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: var(--clr-bg-main);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.service-img {
    height: 200px;
    overflow: hidden;
}

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

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

.service-content {
    padding: 25px;
    text-align: center;
}

.service-content h3 {
    color: var(--clr-primary);
    margin-bottom: 15px;
    font-size: 1.3rem;
}

body.dark-theme .service-content h3 {
    color: var(--clr-white);
}

.service-content p {
    color: var(--clr-text-muted);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

/* -----------------------------
   Gallery Section
----------------------------- */
.gallery {
    overflow: hidden;
}

.gallery-scroll {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    padding: 20px 0;
}

.gallery-track {
    display: inline-flex;
    animation: scroll-rtl 30s linear infinite;
    gap: 20px;
}

.gallery-track img {
    width: 400px;
    height: 300px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: var(--shadow-md);
    flex-shrink: 0;
}

@keyframes scroll-rtl {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc((400px + 20px) * 5));
    }
}

/* -----------------------------
   Testimonials Section
----------------------------- */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.testimonial-card {
    background-color: var(--clr-bg-main);
    padding: 30px;
    border-radius: 15px;
    box-shadow: var(--shadow-md);
    text-align: center;
}

.testimonial-card .stars {
    color: #ffc107;
    margin-bottom: 15px;
}

.testimonial-card p {
    font-style: italic;
    color: var(--clr-text-muted);
    margin-bottom: 20px;
}

.testimonial-card h4 {
    color: var(--clr-primary);
    font-weight: 700;
}

body.dark-theme .testimonial-card h4 {
    color: var(--clr-white);
}

/* -----------------------------
   FAQ Section
----------------------------- */
.faq-accordion {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: var(--clr-bg-light);
    border-radius: 10px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: var(--transition);
}

body.dark-theme .faq-item {
    background-color: var(--clr-bg-light);
}

.faq-question {
    width: 100%;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    text-align: right;
    /* RTL */
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--clr-primary);
    cursor: pointer;
    font-family: inherit;
}

body.dark-theme .faq-question {
    color: var(--clr-white);
}

.faq-question i {
    color: var(--clr-secondary);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0 20px;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    /* Arbitrary large number */
    padding: 0 20px 20px 20px;
}

.faq-answer p {
    color: var(--clr-text-muted);
}

/* -----------------------------
   Footer
----------------------------- */
.footer {
    background-color: var(--clr-primary);
    color: var(--clr-white);
    padding: 60px 0 20px;
}

body.dark-theme .footer {
    background-color: #0d1b2a;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    color: var(--clr-white);
    margin-bottom: 20px;
    display: inline-flex;
}

.business-objective {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-contact h3,
.footer-social h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-contact h3::after,
.footer-social h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    /* RTL */
    width: 40px;
    height: 2px;
    background-color: var(--clr-secondary);
}

.footer-contact ul li {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    color: rgba(255, 255, 255, 0.8);
}

.footer-contact ul li i {
    color: var(--clr-secondary);
}

.footer-contact ul li a:hover {
    color: var(--clr-secondary);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--clr-white);
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--clr-secondary);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

/* -----------------------------
   Floating Buttons
----------------------------- */
.floating-buttons {
    position: fixed;
    bottom: 30px;
    left: 30px;
    /* Best on left for RTL */
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.float-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    position: relative;
}

.float-whatsapp {
    background-color: #25d366;
}

.float-call {
    background-color: var(--clr-primary);
}

.float-btn:hover {
    transform: scale(1.1);
}

/* Pulsing effect for Whatsapp */
.float-whatsapp::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: #25d366;
    z-index: -1;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* -----------------------------
   Animations & Responsive
----------------------------- */
.fade-in {
    opacity: 0;
    transition: opacity 0.8s ease;
}

.fade-in.appear {
    opacity: 1;
}

.slide-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.slide-up.appear {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 992px) {
    .hero-title {
        font-size: 3rem;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        right: -100%;
        /* Changed to right for RTL sliding */
        top: 80px;
        flex-direction: column;
        background-color: var(--clr-bg-main);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-sm);
        padding: 20px 0;
    }

    .nav-menu.active {
        right: 0;
        /* Changed to right for RTL sliding */
    }

    .nav-item {
        margin: 15px 0;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .gallery-track {
        animation: scroll-rtl-mobile 30s linear infinite;
    }

    .gallery-track img {
        width: 300px;
        height: 220px;
    }
}

@keyframes scroll-rtl-mobile {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc((300px + 20px) * 5));
    }
}