/* ===== CSS VARIABLES ===== */
:root {
    /* Brand Colors - Extracted from Logo */
    --primary-color: #0a1f44;
    --primary-dark: #071530;
    --primary-light: #152d5c;
    --secondary-color: #1e3a6e;
    --accent-color: #3b82f6;
    --white: #ffffff;
    --light-bg: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-500: #64748b;
    --gray-700: #334155;
    --gray-900: #0f172a;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gradient-accent: linear-gradient(135deg, var(--accent-color) 0%, #60a5fa 100%);
    --gradient-dark: linear-gradient(180deg, var(--primary-dark) 0%, var(--primary-color) 100%);

    /* Typography */
    --font-family: 'Cairo', sans-serif;
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
    --font-size-5xl: 3rem;
    --font-size-6xl: 3.75rem;

    /* Spacing */
    --section-padding: 100px 0;
    --container-width: 1200px;
    --header-height: 80px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-glow: 0 0 40px rgba(59, 130, 246, 0.3);

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-height);
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.7;
    color: var(--gray-700);
    background-color: var(--white);
    width: 100%;
    position: relative;
    padding-top: var(--header-height);
}

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

ul {
    list-style: none;
}

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

/* ===== UTILITY CLASSES ===== */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: var(--section-padding);
}

.section__header {
    text-align: center;
    margin-bottom: 4rem;
}

.section__subtitle {
    display: inline-block;
    color: var(--accent-color);
    font-size: var(--font-size-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    position: relative;
}

.section__subtitle::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: var(--gradient-accent);
    border-radius: var(--radius-full);
}

.section__title {
    font-size: var(--font-size-4xl);
    font-weight: 800;
    color: var(--primary-color);
    margin-top: 1rem;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: 600;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition-base);
    border: 2px solid transparent;
}

.btn--primary {
    background: var(--gradient-accent);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn--primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

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

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

/* ===== PRELOADER ===== */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    width: 120px;
    height: 120px;
    animation: pulse 1.5s ease-in-out infinite;
}

.loader img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

@keyframes pulse {

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

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* ===== HEADER ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100vw;
    height: var(--header-height);
    padding: 10px 0;
    z-index: 99999;
    transition: var(--transition-base);
    background: rgba(10, 31, 68, 0.9);
    backdrop-filter: blur(10px);
}

.header.scrolled {
    background: rgba(10, 31, 68, 0.98);
    box-shadow: var(--shadow-lg);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.nav__logo {
    height: 60px;
    width: auto;
    transition: var(--transition-base);
}

.nav__logo:hover {
    transform: scale(1.05);
}

.nav__logo img {
    height: 100%;
    width: auto;
    object-fit: contain;
}

.nav__list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav__link {
    color: var(--white);
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
}

.nav__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: var(--transition-base);
}

.nav__link:hover::after,
.nav__link.active::after {
    width: 100%;
}

.nav__toggle,
.nav__close {
    display: none;
    font-size: 1.5rem;
    color: var(--white);
    cursor: pointer;
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: var(--gradient-primary);
    overflow: hidden;
    margin-top: calc(-1 * var(--header-height));
    padding-top: var(--header-height);
}

.hero__bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/hero-bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.4;
    z-index: 1;
}

.hero__particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(circle at 20% 80%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(96, 165, 250, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.03) 0%, transparent 30%);
    z-index: 2;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Ccircle cx='30' cy='30' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    animation: float 30s linear infinite;
    z-index: 2;
}

@keyframes float {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }

    100% {
        transform: translate(-50px, -50px) rotate(360deg);
    }
}

.hero__content {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: 2rem 0;
}

.hero__subtitle {
    display: inline-block;
    color: var(--accent-color);
    font-size: var(--font-size-lg);
    font-weight: 500;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}

.hero__title {
    font-size: clamp(2.5rem, 6vw, var(--font-size-6xl));
    font-weight: 800;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease 0.2s backwards;
}

.hero__description {
    max-width: 600px;
    margin: 0 auto 2.5rem;
    color: rgba(255, 255, 255, 0.85);
    font-size: var(--font-size-lg);
    animation: fadeInUp 0.8s ease 0.4s backwards;
}

.hero__buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.6s backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero__scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
}

.hero__scroll-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: var(--white);
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-15px);
    }

    60% {
        transform: translateY(-7px);
    }
}

/* ===== ABOUT SECTION ===== */
.about__content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about__image-wrapper {
    position: relative;
    padding: 2rem;
    background: var(--gradient-primary);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}

.about__image-wrapper::before {
    content: '';
    position: absolute;
    top: -20px;
    right: -20px;
    width: 100%;
    height: 100%;
    border: 3px solid var(--accent-color);
    border-radius: var(--radius-xl);
    z-index: -1;
}

.about__image-wrapper img {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
}

.about__title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.about__description {
    color: var(--gray-500);
    margin-bottom: 2rem;
    line-height: 1.9;
}

.about__features {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.about__feature {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: var(--gray-100);
    border-radius: var(--radius-full);
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--primary-color);
    transition: var(--transition-base);
}

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

.about__feature i {
    color: var(--accent-color);
}

.about__feature:hover i {
    color: var(--white);
}

/* ===== SERVICES SECTION ===== */
.services {
    background: var(--light-bg);
}

.services__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.service__card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

.service__card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition-base);
}

.service__card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.service__card:hover::before {
    transform: scaleX(1);
}

.service__icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg);
    margin-bottom: 1.5rem;
    transition: var(--transition-base);
}

.service__icon i {
    font-size: 1.75rem;
    color: var(--white);
}

.service__card:hover .service__icon {
    transform: rotateY(180deg);
    background: var(--gradient-accent);
}

.service__title {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.service__list {
    color: var(--gray-500);
}

.service__list li {
    position: relative;
    padding-right: 1.5rem;
    margin-bottom: 0.5rem;
}

.service__list li::before {
    content: '✓';
    position: absolute;
    right: 0;
    color: var(--accent-color);
    font-weight: 700;
}

/* ===== WHY US SECTION ===== */
.why-us__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.why-us__card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: var(--transition-base);
    border: 1px solid var(--gray-200);
}

.why-us__card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.why-us__icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-accent);
    border-radius: 50%;
    margin: 0 auto 1rem;
}

.why-us__icon i {
    font-size: 1.5rem;
    color: var(--white);
}

.why-us__card h4 {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.why-us__card p {
    color: var(--gray-500);
    font-size: var(--font-size-sm);
}

/* ===== CONTACT SECTION ===== */
.contact {
    background: var(--gradient-primary);
    color: var(--white);
}

.contact .section__subtitle {
    color: rgba(255, 255, 255, 0.7);
}

.contact .section__subtitle::after {
    background: var(--white);
}

.contact .section__title {
    color: var(--white);
}

.contact__content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.contact__info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact__card {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    transition: var(--transition-base);
}

.contact__card:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(-10px);
}

.contact__card i {
    font-size: 1.5rem;
    color: var(--accent-color);
}

.contact__card h4 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.contact__card p,
.contact__card a {
    color: rgba(255, 255, 255, 0.8);
    font-size: var(--font-size-sm);
}

.contact__card a:hover {
    color: var(--accent-color);
}

.contact__social {
    text-align: center;
}

.contact__social h4 {
    font-size: var(--font-size-xl);
    margin-bottom: 1.5rem;
}

.social__links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.social__link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    font-size: 1.25rem;
    color: var(--white);
    transition: var(--transition-base);
}

.social__link:hover {
    background: var(--accent-color);
    transform: translateY(-5px);
}

/* ===== FLOATING BUTTONS ===== */
.whatsapp-float {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #25d366;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    font-size: 2rem;
    color: var(--white);
    z-index: 9999;
    animation: pulse-float 2s infinite;
    transition: var(--transition-base);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

.scroll-top {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-accent);
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
    font-size: 1.5rem;
    color: var(--white);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: var(--transition-base);
    animation: pulse-float 2s infinite 0.5s;
}

.scroll-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(59, 130, 246, 0.5);
}

@keyframes pulse-float {
    0% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.5);
    }

    70% {
        box-shadow: 0 0 0 20px rgba(59, 130, 246, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    }
}

/* ===== FOOTER ===== */
.footer {
    background: var(--primary-dark);
    padding: 3rem 0 1.5rem;
}

.footer__content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer__logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer__logo img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.footer__logo p {
    color: rgba(255, 255, 255, 0.7);
}

.footer__links {
    display: flex;
    gap: 2rem;
}

.footer__links a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition-base);
}

.footer__links a:hover {
    color: var(--accent-color);
}

.footer__bottom {
    text-align: center;
    padding-top: 1.5rem;
}

.footer__bottom p {
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--font-size-sm);
}

.footer__bottom a {
    color: var(--white);
    font-weight: 600;
    transition: var(--transition-base);
}

.footer__bottom a:hover {
    color: var(--accent-color);
}

/* ===== RESPONSIVE ===== */
@media screen and (max-width: 992px) {
    :root {
        --header-height: 70px;
    }

    .nav__menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: var(--primary-color);
        padding: 5rem 2rem;
        transition: var(--transition-base);
        box-shadow: var(--shadow-xl);
        z-index: 99999;
    }

    .nav__menu.show-menu {
        right: 0;
    }

    .nav__list {
        flex-direction: column;
        gap: 2rem;
    }

    .nav__toggle {
        display: block;
    }

    .nav__close {
        display: block;
        position: absolute;
        top: 1.5rem;
        left: 1.5rem;
    }

    .about__content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .about__image {
        order: -1;
    }

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

@media screen and (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    .section {
        padding: 60px 0;
    }

    .section__title {
        font-size: var(--font-size-3xl);
    }

    .nav__logo {
        height: 50px;
    }

    .hero__buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .about__features {
        flex-direction: column;
    }

    .footer__content {
        flex-direction: column;
        text-align: center;
    }

    .footer__links {
        flex-wrap: wrap;
        justify-content: center;
    }

    .whatsapp-float,
    .scroll-top {
        width: 60px;
        height: 60px;
        bottom: 1.5rem;
    }

    .whatsapp-float {
        right: 1.5rem;
    }

    .scroll-top {
        left: 1.5rem;
    }
}

@media screen and (max-width: 576px) {
    .nav__logo {
        height: 45px;
    }

    .whatsapp-float,
    .scroll-top {
        width: 55px;
        height: 55px;
        font-size: 1.5rem;
        bottom: 1rem;
    }

    .whatsapp-float {
        right: 1rem;
    }

    .scroll-top {
        left: 1rem;
    }
}