:root {
            --bg-dark: #030712;
            --bg-card: rgba(17, 24, 39, 0.6);
            --primary: #3b82f6;
            /* Bright Blue */
            --primary-glow: rgba(59, 130, 246, 0.7);
            --secondary: #a855f7;
            /* Vibrant Purple */
            --secondary-glow: rgba(168, 85, 247, 0.7);
            --accent: #22d3ee;
            /* Cyan */
            --text-main: #f9fafb;
            --text-muted: #9ca3af;
            --border-color: rgba(255, 255, 255, 0.1);
            --font-ar: 'Cairo', sans-serif;
            --font-en: 'Outfit', sans-serif;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            scroll-behavior: smooth;
        }

        body {
            font-family: var(--font-en);
            /* Default English Font */
            background-color: var(--bg-dark);
            color: var(--text-main);
            overflow-x: hidden;
            line-height: 1.7;
            transition: font-family 0.3s ease;
            text-align: left;
            direction: ltr;
        }

        body[lang="ar"] {
            font-family: var(--font-ar);
            text-align: right;
            direction: rtl;
        }

        /* Animated Grid Background */
        .grid-bg {
            position: fixed;
            top: 0;
            left: 0;
            width: 100vw;
            height: 100vh;
            background-image:
                linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
                linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
            background-size: 50px 50px;
            z-index: -2;
            perspective: 500px;
        }

        /* Glowing Orbs */
        .orb {
            position: fixed;
            border-radius: 50%;
            filter: blur(120px);
            z-index: -1;
            opacity: 0.6;
            animation: floatOrb 20s infinite alternate ease-in-out;
        }

        .orb-1 {
            width: 500px;
            height: 500px;
            background: var(--primary);
            top: -150px;
            right: -100px;
        }

        .orb-2 {
            width: 600px;
            height: 600px;
            background: var(--secondary);
            bottom: -200px;
            left: -200px;
            animation-duration: 25s;
        }

        .orb-3 {
            width: 400px;
            height: 400px;
            background: var(--accent);
            top: 40%;
            left: 30%;
            opacity: 0.3;
            animation-duration: 30s;
        }

        @keyframes floatOrb {
            0% {
                transform: translate(0, 0) scale(1);
            }

            50% {
                transform: translate(-50px, 50px) scale(1.1);
            }

            100% {
                transform: translate(50px, -50px) scale(0.9);
            }
        }

        .container {
            max-width: 1280px;
            margin: 0 auto;
            padding: 0 2rem;
            position: relative;
        }

        /* Navbar */
        .navbar {
            position: fixed;
            top: 0;
            width: 100%;
            z-index: 1000;
            padding: 1.5rem 0;
            transition: all 0.4s ease;
            backdrop-filter: blur(0px);
            background: rgba(3, 7, 18, 0);
        }

        .navbar.scrolled {
            padding: 1rem 0;
            background: rgba(3, 7, 18, 0.85);
            backdrop-filter: blur(16px);
            -webkit-backdrop-filter: blur(16px);
            border-bottom: 1px solid var(--border-color);
        }

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

        .brand {
            display: flex;
            align-items: center;
            gap: 1rem;
            text-decoration: none;
        }

        /* 🔥 UPGRADED LOGO ANIMATION (Holographic Spin & Float) 🔥 */
        @keyframes holographicSpin {
            0% {
                transform: perspective(600px) rotateY(-10deg) translateY(0) scale(1);
                filter: drop-shadow(0 0 10px var(--primary-glow));
            }

            50% {
                transform: perspective(600px) rotateY(15deg) translateY(-8px) scale(1.05);
                filter: drop-shadow(0 0 25px var(--accent)) drop-shadow(0 0 5px #fff);
            }

            100% {
                transform: perspective(600px) rotateY(-10deg) translateY(0) scale(1);
                filter: drop-shadow(0 0 10px var(--secondary-glow));
            }
        }

        .brand img {
            height: 45px;
            mix-blend-mode: screen;
            /* Removes the black background box */
            animation: holographicSpin 5s infinite ease-in-out alternate;
        }

        .brand span {
            font-family: var(--font-en);
            font-size: 2rem;
            font-weight: 900;
            background: linear-gradient(135deg, #ffffff 10%, var(--accent) 50%, var(--primary) 90%);
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
            letter-spacing: 2px;
            filter: drop-shadow(0 0 15px rgba(34, 211, 238, 0.4));
        }

        .nav-actions {
            display: flex;
            align-items: center;
            gap: 2rem;
        }

        .nav-links {
            display: flex;
            gap: 2rem;
            /* Closer gap for English */
            list-style: none;
        }

        body[lang="ar"] .nav-links {
            gap: 2.5rem;
        }

        .nav-links a {
            color: var(--text-main);
            text-decoration: none;
            font-weight: 600;
            font-size: 1.1rem;
            position: relative;
            transition: color 0.3s;
        }

        .nav-links a::after {
            content: '';
            position: absolute;
            width: 0;
            height: 2px;
            bottom: -5px;
            left: 0;
            background: linear-gradient(90deg, var(--primary), var(--secondary));
            transition: width 0.3s ease;
        }

        body[lang="ar"] .nav-links a::after {
            left: auto;
            right: 0;
        }

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

        .nav-links a:hover::after {
            width: 100%;
        }

        /* Lang Toggle Button */
        .lang-toggle {
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid var(--border-color);
            color: #fff;
            padding: 0.4rem 1rem;
            border-radius: 20px;
            cursor: pointer;
            font-weight: 600;
            font-family: var(--font-en);
            transition: all 0.3s ease;
        }

        .lang-toggle:hover {
            background: rgba(255, 255, 255, 0.2);
            box-shadow: 0 0 10px var(--primary-glow);
        }

        /* Premium Buttons */
        .btn-neon {
            background: transparent;
            color: #fff;
            padding: 0.8rem 2.5rem;
            font-size: 1.1rem;
            font-weight: 700;
            border-radius: 50px;
            text-decoration: none;
            position: relative;
            border: 2px solid transparent;
            background-clip: padding-box;
            cursor: pointer;
            transition: all 0.3s ease;
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
        }

        .btn-neon::before {
            content: '';
            position: absolute;
            top: 0;
            right: 0;
            bottom: 0;
            left: 0;
            z-index: -1;
            margin: -2px;
            border-radius: 50px;
            background: linear-gradient(90deg, var(--primary), var(--secondary));
        }

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

        .btn-solid {
            background: linear-gradient(90deg, var(--primary), var(--secondary));
            color: #fff;
            padding: 0.8rem 2.5rem;
            font-size: 1.1rem;
            font-weight: 700;
            border-radius: 50px;
            text-decoration: none;
            transition: all 0.3s ease;
            display: inline-block;
            border: none;
        }

        .btn-solid:hover {
            transform: translateY(-3px) scale(1.02);
            box-shadow: 0 10px 30px var(--secondary-glow);
        }

        /* Hero Section */
        .hero {
            min-height: 100vh;
            display: flex;
            align-items: center;
            padding-top: 100px;
            position: relative;
        }

        .hero-layout {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 4rem;
            align-items: center;
        }

        .hero-text h1 {
            font-size: 3.5rem;
            line-height: 1.2;
            font-weight: 900;
            margin-bottom: 1.5rem;
        }

        body[lang="ar"] .hero-text h1 {
            font-size: 4rem;
        }

        .hero-text h1 .gradient-text {
            background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent), var(--primary));
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
            background-size: 200% auto;
        }

        body[lang="ar"] .hero-text h1 .gradient-text {
            animation: shine-ar 5s linear infinite;
        }

        body[lang="en"] .hero-text h1 .gradient-text {
            animation: shine-en 5s linear infinite;
        }

        @keyframes shine-ar {
            to {
                background-position: 200% center;
            }
        }

        @keyframes shine-en {
            to {
                background-position: -200% center;
            }
        }

        .hero-text p {
            font-size: 1.3rem;
            color: var(--text-muted);
            margin-bottom: 2.5rem;
            max-width: 90%;
        }

        .hero-actions {
            display: flex;
            gap: 1.5rem;
        }

        /* 3D Floating Element in Hero */
        .hero-visual {
            position: relative;
            perspective: 1000px;
        }

        .glass-panel {
            background: rgba(255, 255, 255, 0.03);
            border-radius: 24px;
            padding: 3rem;
            backdrop-filter: blur(20px);
            -webkit-backdrop-filter: blur(20px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            transform: rotateY(15deg) rotateX(10deg);
            transform-style: preserve-3d;
            animation: floatPanelEN 6s ease-in-out infinite alternate;
            box-shadow: 20px 20px 50px rgba(0, 0, 0, 0.5);
            direction: ltr;
            /* Keeps the progress bars looking logic-like */
        }

        body[lang="ar"] .glass-panel {
            transform: rotateY(-15deg) rotateX(10deg);
            animation: floatPanel 6s ease-in-out infinite alternate;
        }

        .glass-panel::before {
            content: '';
            position: absolute;
            inset: 0;
            border-radius: 24px;
            padding: 2px;
            background: linear-gradient(135deg, var(--primary), transparent, var(--secondary));
            -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
            -webkit-mask-composite: xor;
            mask-composite: exclude;
            pointer-events: none;
        }

        @keyframes floatPanel {
            0% {
                transform: rotateY(-15deg) rotateX(10deg) translateY(0);
            }

            100% {
                transform: rotateY(-5deg) rotateX(5deg) translateY(-20px);
            }
        }

        @keyframes floatPanelEN {
            0% {
                transform: rotateY(15deg) rotateX(10deg) translateY(0);
            }

            100% {
                transform: rotateY(5deg) rotateX(5deg) translateY(-20px);
            }
        }

        /* Section Titles */
        .section-header {
            text-align: center;
            margin-bottom: 5rem;
        }

        .section-header h2 {
            font-size: 3rem;
            font-weight: 800;
            margin-bottom: 1rem;
        }

        .section-header p {
            font-size: 1.2rem;
            color: var(--text-muted);
        }

        /* Features Section */
        .features {
            padding: 8rem 0;
        }

        .features-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
            gap: 2.5rem;
        }

        .feature-card {
            background: var(--bg-card);
            border: 1px solid var(--border-color);
            border-radius: 20px;
            padding: 3rem 2rem;
            backdrop-filter: blur(10px);
            transition: all 0.4s ease;
            position: relative;
            overflow: hidden;
            z-index: 1;
        }

        .feature-card::after {
            content: '';
            position: absolute;
            top: 0;
            right: 0;
            width: 100%;
            height: 100%;
            background: radial-gradient(circle at top left, var(--primary-glow), transparent 70%);
            /* LTR Default */
            opacity: 0;
            z-index: -1;
            transition: opacity 0.4s ease;
        }

        body[lang="ar"] .feature-card::after {
            background: radial-gradient(circle at top right, var(--primary-glow), transparent 70%);
            /* RTL Override */
        }

        .feature-card:hover {
            transform: translateY(-10px);
            border-color: var(--primary);
            box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
        }

        .feature-card:hover::after {
            opacity: 0.3;
        }

        .icon-box {
            width: 70px;
            height: 70px;
            border-radius: 16px;
            background: rgba(255, 255, 255, 0.05);
            display: flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 2rem;
            font-size: 2rem;
            color: var(--accent);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }

        .feature-card h3 {
            font-size: 1.6rem;
            margin-bottom: 1rem;
        }

        .feature-card p {
            color: var(--text-muted);
            font-size: 1.1rem;
        }

        /* Stats Section */
        .stats {
            padding: 5rem 0;
            background: linear-gradient(90deg, rgba(59, 130, 246, 0.05), rgba(168, 85, 247, 0.05));
            border-top: 1px solid var(--border-color);
            border-bottom: 1px solid var(--border-color);
        }

        .stats-grid {
            display: flex;
            justify-content: space-around;
            flex-wrap: wrap;
            gap: 2rem;
            text-align: center;
        }

        .stat-item h4 {
            font-size: 4rem;
            font-weight: 900;
            color: var(--text-main);
            margin-bottom: 0.5rem;
            background: linear-gradient(135deg, #fff, var(--text-muted));
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
        }

        .stat-item p {
            font-size: 1.2rem;
            color: var(--accent);
            font-weight: 600;
        }

        /* CTA Section */
        .cta-section {
            padding: 8rem 0;
            text-align: center;
        }

        .cta-box {
            background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(168, 85, 247, 0.1));
            border-radius: 30px;
            padding: 5rem 2rem;
            border: 1px solid rgba(255, 255, 255, 0.15);
            backdrop-filter: blur(10px);
            position: relative;
            overflow: hidden;
        }

        .cta-box h2 {
            font-size: 3rem;
            margin-bottom: 1.5rem;
        }

        .cta-box p {
            font-size: 1.3rem;
            color: var(--text-muted);
            max-width: 600px;
            margin: 0 auto 3rem auto;
        }

        /* Footer */
        .footer {
            background: #010308;
            padding: 4rem 0 2rem 0;
            border-top: 1px solid rgba(255, 255, 255, 0.05);
        }

        .footer-content {
            display: grid;
            grid-template-columns: 1.5fr 1fr 1fr;
            gap: 4rem;
            margin-bottom: 4rem;
        }

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

        .footer-links h4 {
            font-size: 1.3rem;
            margin-bottom: 1.5rem;
            color: #fff;
        }

        .footer-links ul {
            list-style: none;
        }

        .footer-links ul li {
            margin-bottom: 0.8rem;
        }

        .footer-links ul a {
            color: var(--text-muted);
            text-decoration: none;
            transition: color 0.3s;
        }

        .footer-links ul a:hover {
            color: var(--primary);
        }

        .footer-bottom {
            text-align: center;
            padding-top: 2rem;
            border-top: 1px solid rgba(255, 255, 255, 0.05);
            color: var(--text-muted);
        }

        /* Welcome Toast */
        .welcome-toast {
            position: fixed;
            bottom: 20px;
            right: -600px;
            max-width: 380px;
            background: rgba(17, 24, 39, 0.9);
            backdrop-filter: blur(10px);
            border: 1px solid var(--primary);
            color: var(--text-main);
            padding: 1rem 1.5rem;
            border-radius: 12px;
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), 0 0 15px var(--primary-glow);
            z-index: 9999;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 1rem;
            transition: right 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        }

        body[lang="ar"] .welcome-toast {
            right: auto;
            left: -600px;
            transition: left 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
            flex-direction: row-reverse;
        }

        .welcome-toast.show {
            right: 20px;
        }

        body[lang="ar"] .welcome-toast.show {
            left: 20px;
        }

        .toast-content {
            display: flex;
            align-items: center;
            gap: 0.8rem;
            line-height: 1.5;
        }

        .toast-icon {
            font-size: 1.5rem;
        }

        .toast-close {
            background: transparent;
            border: none;
            color: var(--text-muted);
            font-size: 1.5rem;
            cursor: pointer;
            transition: color 0.3s;
        }

        .toast-close:hover {
            color: var(--accent);
        }

        /* Utility animations */
        .reveal {
            opacity: 0;
            transform: translateY(40px);
            transition: all 1s cubic-bezier(0.5, 0, 0, 1);
        }

        .reveal.active {
            opacity: 1;
            transform: translateY(0);
        }

        @media (max-width: 992px) {
            .hero-layout {
                grid-template-columns: 1fr;
            }

            .hero-visual {
                display: none;
            }

            .hero-actions {
                justify-content: center;
            }

            .hero-text h1 {
                font-size: 3rem;
            }

            .footer-content {
                grid-template-columns: 1fr;
                text-align: center;
            }
        }

        @media (max-width: 768px) {

            /* Navbar Mobile Simplification */
            .nav-content {
                flex-direction: row !important;
                justify-content: space-between !important;
                align-items: center !important;
                padding: 0 1rem;
            }

            .navbar {
                padding: 1rem 0;
            }

            .nav-links {
                display: none !important;
            }

            .nav-actions {
                margin-top: 0 !important;
                gap: 0.5rem !important;
            }

            .nav-actions .btn-solid {
                display: none !important;
                /* Hide Start Now from navbar to save screen space */
            }

            .brand img {
                height: 35px !important;
            }

            .brand span {
                font-size: 1.3rem !important;
                letter-spacing: 1px !important;
            }

            .lang-toggle {
                padding: 0.3rem 0.8rem;
                font-size: 0.9rem;
            }

            /* Hero Mobile Fixes */
            .hero {
                padding-top: 130px;
                /* Small navbar needs less padding */
                padding-bottom: 50px;
                align-items: center;
                min-height: auto;
            }

            .hero-text h1 {
                font-size: 2.2rem !important;
                margin-bottom: 1.5rem !important;
            }

            .hero-text p {
                font-size: 1.1rem !important;
                max-width: 100%;
            }

            .hero-actions {
                flex-direction: column;
                gap: 1rem;
            }

            .hero-actions a {
                display: block;
                width: 100%;
                text-align: center;
                padding: 1rem;
            }

            /* Stats & General */
            .stats-grid {
                flex-direction: column;
                gap: 3rem;
            }

            .container {
                padding: 0 1.5rem;
            }
        }

/* --- MOBILE MENU & ANIMATIONS --- */
.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    font-size: 2rem;
    padding: 0.5rem;
    margin-left: 1rem;
}

body[lang="ar"] .mobile-menu-btn {
    margin-left: 0;
    margin-right: 1rem;
}

.lang-transition {
    transition: opacity 0.3s ease-in-out;
}

.lang-fade-out {
    opacity: 0;
}

/* Stat Circles */
.stat-circle {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    border: 4px solid rgba(59, 130, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    position: relative;
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.2);
}

.stat-circle::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 4px solid transparent;
    border-top-color: var(--primary);
    border-right-color: var(--secondary);
    animation: spin 8s linear infinite;
}

.stat-circle-alt::before {
    border-top-color: var(--accent);
    border-left-color: var(--primary);
    animation: spin 6s linear infinite reverse;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block !important;
    }
    
    .start-btn {
        display: none !important; /* hide on small mobiles in header to save space */
    }

    .nav-links {
        display: flex !important;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(3, 7, 18, 0.95);
        backdrop-filter: blur(10px);
        padding: 2rem 0;
        gap: 2rem;
        border-bottom: 1px solid var(--border-color);
        transform: translateY(-150%);
        opacity: 0;
        transition: transform 0.4s ease, opacity 0.4s ease;
        z-index: -1;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
    }
}
