:root {
            --primary: #2563eb;
            --primary-dark: #1d4ed8;
            --secondary: #f59e0b;
            --accent: #10b981;
            --dark: #0f172a;
            --darker: #020617;
            --light: #f8fafc;
            --lighter: #ffffff;
            --gray: #64748b;
            --gray-light: #cbd5e1;
            --text: #1e293b;
            --text-light: #94a3b8;
            --card-bg: #ffffff;
            --section-bg: #f1f5f9;
            --border: #e2e8f0;
            --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
            --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
            --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            --navbar-scrolled-bg: rgba(255, 255, 255, 0.92);
            --navbar-scrolled-text: #1e293b;
        }

        [data-theme="dark"] {
            --dark: #f8fafc;
            --darker: #ffffff;
            --light: #0f172a;
            --lighter: #1e293b;
            --gray: #94a3b8;
            --text: #f1f5f9;
            --text-light: #64748b;
            --card-bg: #1e293b;
            --section-bg: #0f172a;
            --border: #334155;
            --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
            --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
            --navbar-scrolled-bg: rgba(15, 23, 42, 0.94);
            --navbar-scrolled-text: #f1f5f9;
        }

        /* RTL Styles */
        [dir="rtl"] body {
            font-family: 'Cairo', sans-serif;
            text-align: right;
        }

        [dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4, [dir="rtl"] h5, [dir="rtl"] h6 {
            font-family: 'Cairo', sans-serif;
        }

        [dir="rtl"] .hero-content,
        [dir="rtl"] .section-header,
        [dir="rtl"] .stat-card,
        [dir="rtl"] .team-info,
        [dir="rtl"] .testimonial-item {
            text-align: center;
        }

        [dir="rtl"] .contact-item i {
            margin-right: 0;
            margin-left: 1rem;
        }

        /* ── RTL overrides ──────────────────────────────────────────────── */        [dir="rtl"] .footer-links a:hover {
            padding-left: 0;
            padding-right: 5px;
        }

        [dir="rtl"] .side-panel {
            right: auto;
            left: -400px;
        }

        [dir="rtl"] .side-panel.active {
            left: 0;
        }

        [dir="rtl"] .side-panel-close {
            right: auto;
            left: 1rem;
        }

        [dir="rtl"] .mobile-nav {
            left: auto;
            right: -100%;
        }

        [dir="rtl"] .mobile-nav.active {
            right: 0;
        }

        [dir="rtl"] .mobile-nav-links a:hover {
            padding-left: 2rem;
            padding-right: 2.5rem;
        }

        [dir="rtl"] .about-image::before {
            left: auto;
            right: -20px;
        }

        [dir="rtl"] .lang-dropdown {
            right: auto;
            left: 0;
        }

        [dir="rtl"] .lang-option {
            text-align: right;
        }

        [dir="rtl"] .lang-current {
            flex-direction: row-reverse;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        html {
            scroll-behavior: smooth;
        }

        body {
            font-family: 'Poppins', sans-serif;
            background: var(--light);
            color: var(--text);
            overflow-x: hidden;
            transition: var(--transition);
        }

        h1, h2, h3, h4, h5, h6 {
            font-family: 'Playfair Display', serif;
        }

        /* Scrollbar */
        ::-webkit-scrollbar {
            width: 10px;
        }

        ::-webkit-scrollbar-track {
            background: var(--section-bg);
        }

        ::-webkit-scrollbar-thumb {
            background: var(--primary);
            border-radius: 5px;
        }

        /* Preloader */
        .preloader {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: #020617;
            z-index: 9999;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-direction: column;
            transition: opacity 0.5s ease-out, visibility 0.5s;
        }

        .preloader.hidden {
            opacity: 0;
            visibility: hidden;
            pointer-events: none;
        }

        .preloader-logo {
            margin-bottom: 2rem;
            animation: pulse 2s infinite;
        }

        .preloader-logo img {
            height: 56px;
            max-width: 200px;
            object-fit: contain;
            display: block;
        }

        .preloader-site-name {
            font-size: 1.8rem;
            font-weight: 700;
            color: var(--primary);
            letter-spacing: .04em;
        }

        .preloader-bar {
            width: 200px;
            height: 4px;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 2px;
            overflow: hidden;
        }

        .preloader-progress {
            width: 0%;
            height: 100%;
            background: var(--primary);
            border-radius: 2px;
            animation: loadProgress 1.5s ease-out forwards;
        }

        @keyframes loadProgress {
            0% { width: 0%; }
            100% { width: 100%; }
        }

        /* Navigation */
        .navbar {
            position: fixed;
            top: 0;
            width: 100%;
            z-index: 1000;
            padding: 1rem 0;
            transition: var(--transition);
            background: transparent;
        }

        .navbar.scrolled {
            background: var(--navbar-scrolled-bg);
            backdrop-filter: blur(12px);
            -webkit-backdrop-filter: blur(12px);
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
            padding: 0.55rem 0;
            border-bottom: 1px solid var(--border);
        }

        [data-theme="dark"] .navbar.scrolled {
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
            border-bottom: 1px solid var(--border);
        }

        .nav-container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 2rem;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .logo {
            font-size: 1.5rem;
            font-weight: 700;
            color: white;
            text-decoration: none;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            transition: var(--transition);
        }

        .logo img {
            height: 38px;
            border-radius: 8px;
            transition: var(--transition);
        }

        /* When both logo versions are present, light mode shows logo-dark-version (dark-ink logo)
           and dark mode shows logo-light (white/light logo) */
        .logo-light { display: none; }
        .logo-dark-version { display: block; }

        [data-theme="dark"] .logo-light { display: block; }
        [data-theme="dark"] .logo-dark-version { display: none; }

        .navbar.scrolled .logo {
            color: var(--navbar-scrolled-text);
        }

        .nav-links {
            display: flex;
            gap: 2rem;
            list-style: none;
        }

        .nav-links a {
            text-decoration: none;
            color: rgba(255, 255, 255, 0.9);
            font-weight: 500;
            transition: var(--transition);
            position: relative;
            font-size: 0.95rem;
        }

        .navbar.scrolled .nav-links a {
            color: var(--navbar-scrolled-text);
        }

        .nav-links a::after {
            content: '';
            position: absolute;
            bottom: -5px;
            left: 0;
            width: 0;
            height: 2px;
            background: var(--primary);
            transition: var(--transition);
        }

        .nav-links a:hover::after {
            width: 100%;
        }

        .nav-links a:hover {
            color: var(--primary);
        }

        .nav-actions {
            display: flex;
            gap: 0.75rem;
            align-items: center;
        }

        .btn-icon {
            background: none;
            border: none;
            color: white;
            font-size: 1.2rem;
            cursor: pointer;
            padding: 0.5rem;
            border-radius: 50%;
            transition: var(--transition);
            width: 40px;
            height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .navbar.scrolled .btn-icon {
            color: var(--navbar-scrolled-text);
        }

        .btn-icon:hover {
            background: var(--primary);
            color: white !important;
        }

        /* Elegant Language Switcher */
        .lang-switcher {
            position: relative;
        }

        .lang-current {
            display: flex;
            align-items: center;
            gap: 0.4rem;
            padding: 0.4rem 0.75rem;
            background: rgba(255, 255, 255, 0.12);
            border: 1px solid rgba(255, 255, 255, 0.3);
            border-radius: 50px;
            color: white;
            cursor: pointer;
            font-size: 0.82rem;
            font-weight: 600;
            letter-spacing: 0.4px;
            transition: var(--transition);
            font-family: 'Poppins', sans-serif;
            white-space: nowrap;
            user-select: none;
            -webkit-tap-highlight-color: transparent;
        }

        .lang-current span {
            line-height: 1;
        }

        .lang-current .lang-chevron {
            font-size: 0.6rem;
            transition: transform 0.3s;
            opacity: 0.8;
        }

        .lang-switcher.open .lang-current .lang-chevron {
            transform: rotate(180deg);
        }

        .navbar.scrolled .lang-current {
            background: var(--section-bg);
            border-color: var(--border);
            color: var(--navbar-scrolled-text);
        }

        .lang-current:hover {
            background: rgba(255, 255, 255, 0.22);
            border-color: rgba(255, 255, 255, 0.5);
        }

        .navbar.scrolled .lang-current:hover {
            background: var(--border);
            border-color: var(--gray-light);
        }

        .lang-dropdown {
            position: absolute;
            top: calc(100% + 0.6rem);
            right: 0;
            background: var(--card-bg);
            border-radius: 14px;
            box-shadow: 0 12px 32px rgba(0, 0, 0, 0.18);
            min-width: 150px;
            overflow: hidden;
            opacity: 0;
            visibility: hidden;
            transform: translateY(-8px) scale(0.96);
            transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
            z-index: 100;
            border: 1px solid var(--border);
        }

        .lang-dropdown.active {
            opacity: 1;
            visibility: visible;
            transform: translateY(0) scale(1);
        }

        .lang-option {
            display: flex;
            align-items: center;
            gap: 0.6rem;
            width: 100%;
            padding: 0.75rem 1.2rem;
            border: none;
            background: transparent;
            color: var(--text);
            cursor: pointer;
            font-size: 0.9rem;
            text-align: left;
            transition: var(--transition);
            font-family: 'Poppins', sans-serif;
            white-space: nowrap;
        }

        .lang-option:hover {
            background: var(--section-bg);
            color: var(--primary);
        }

        .lang-option.active-lang {
            background: rgba(37, 99, 235, 0.08);
            color: var(--primary);
            font-weight: 600;
            pointer-events: none;
        }

        .lang-option .lang-flag {
            font-size: 1.1rem;
            flex-shrink: 0;
        }

        .lang-option .lang-check {
            margin-left: auto;
            font-size: 0.75rem;
            color: var(--primary);
            opacity: 0;
        }

        .lang-option.active-lang .lang-check {
            opacity: 1;
        }

        [dir="rtl"] .lang-option .lang-check {
            margin-left: 0;
            margin-right: auto;
        }

        .mobile-menu {
            display: none;
        }

        /* Hero Section */
        .hero {
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
            overflow: hidden;
            background: linear-gradient(135deg, #020617 0%, #0f172a 100%);
        }

        /* When a background image is uploaded via the CMS */
        .hero-has-bg {
            background-size: cover;
            background-position: center center;
            background-repeat: no-repeat;
        }

        /* Dark overlay so text stays legible over any photo */
        .hero-overlay {
            position: absolute;
            inset: 0;
            background: linear-gradient(135deg, rgba(2,6,23,.82) 0%, rgba(15,23,42,.75) 100%);
            z-index: 1;
        }

        .hero-particles {
            position: absolute;
            width: 100%;
            height: 100%;
            overflow: hidden;
        }

        .particle {
            position: absolute;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 50%;
            animation: float 15s infinite;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0) rotate(0deg); opacity: 0; }
            10% { opacity: 1; }
            90% { opacity: 1; }
            100% { transform: translateY(-100vh) rotate(720deg); opacity: 0; }
        }

        @keyframes pulse {
            0%, 100% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4); }
            50% { box-shadow: 0 0 0 10px rgba(37, 99, 235, 0); }
        }

        .hero-content {
            position: relative;
            z-index: 2;
            text-align: center;
            padding: 0 2rem;
            max-width: 900px;
        }

        .hero-badge {
            display: inline-block;
            padding: 0.5rem 1.5rem;
            background: rgba(37, 99, 235, 0.2);
            border: 1px solid var(--primary);
            border-radius: 50px;
            color: var(--primary);
            font-size: 0.9rem;
            margin-bottom: 2rem;
            animation: pulse 2s infinite;
        }

        .hero h1 {
            font-size: clamp(2.5rem, 5vw, 4.5rem);
            color: white;
            margin-bottom: 1.5rem;
            line-height: 1.1;
        }

        .hero h1 span {
            color: var(--primary);
            position: relative;
        }

        .hero p {
            font-size: 1.2rem;
            color: rgba(255, 255, 255, 0.8);
            margin-bottom: 2.5rem;
            line-height: 1.8;
        }

        .hero-buttons {
            display: flex;
            gap: 1rem;
            justify-content: center;
            flex-wrap: wrap;
        }

        .btn {
            padding: 1rem 2.5rem;
            border-radius: 50px;
            text-decoration: none;
            font-weight: 600;
            transition: var(--transition);
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
            border: none;
            cursor: pointer;
            font-size: 1rem;
        }

        .btn-primary {
            background: var(--primary);
            color: white;
            box-shadow: 0 10px 30px rgba(37, 99, 235, 0.3);
        }

        .btn-primary:hover {
            transform: translateY(-3px);
            box-shadow: 0 20px 40px rgba(37, 99, 235, 0.4);
            background: var(--primary-dark);
        }

        .btn-outline {
            background: transparent;
            color: white;
            border: 2px solid rgba(255, 255, 255, 0.6);
        }

        .btn-outline:hover {
            background: white;
            color: var(--dark);
            transform: translateY(-3px);
        }

        .btn-secondary {
            background: transparent;
            color: white;
            border: 2px solid rgba(255, 255, 255, 0.5);
            font-weight: 600;
        }

        .btn-secondary:hover {
            background: rgba(255, 255, 255, 0.12);
            border-color: white;
            color: white;
            transform: translateY(-3px);
        }

        .hero-scroll {
            position: absolute;
            bottom: 2rem;
            left: 50%;
            transform: translateX(-50%);
            color: white;
            animation: bounce 2s infinite;
            cursor: pointer;
        }

        @keyframes bounce {
            0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
            40% { transform: translateX(-50%) translateY(-10px); }
            60% { transform: translateX(-50%) translateY(-5px); }
        }

        /* Section Styles */
        section {
            padding: 6rem 0;
            position: relative;
        }

        .container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 2rem;
        }

        .section-header {
            text-align: center;
            margin-bottom: 4rem;
        }

        .section-header h2 {
            font-size: clamp(2rem, 4vw, 3rem);
            margin-bottom: 1rem;
            position: relative;
            display: inline-block;
        }

        .section-header h2::after {
            content: '';
            position: absolute;
            bottom: -10px;
            left: 50%;
            transform: translateX(-50%);
            width: 60px;
            height: 4px;
            background: var(--primary);
            border-radius: 2px;
        }

        .section-header p {
            color: var(--gray);
            font-size: 1.1rem;
            max-width: 600px;
            margin: 1.5rem auto 0;
        }

        /* Portfolio Section */
        .portfolio-filter-tabs {
            display: flex;
            flex-wrap: wrap;
            gap: .6rem;
            justify-content: center;
            margin-bottom: 2.5rem;
        }

        .portfolio-filter-btn {
            padding: .5rem 1.3rem;
            border: 2px solid var(--border);
            border-radius: 999px;
            background: transparent;
            color: var(--gray);
            font-size: .875rem;
            font-weight: 600;
            cursor: pointer;
            transition: all .2s;
        }

        .portfolio-filter-btn:hover,
        .portfolio-filter-btn.active {
            border-color: var(--primary);
            background: var(--primary);
            color: #fff;
        }

        .portfolio-item {
            transition: opacity .3s, transform .3s;
        }

        .portfolio-item.portfolio-hidden {
            display: none;
        }

        .portfolio-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 1.5rem;
        }

        .portfolio-item {
            background: var(--card-bg);
            border-radius: 20px;
            overflow: hidden;
            box-shadow: var(--shadow);
            transition: var(--transition);
            cursor: pointer;
        }

        .portfolio-item:hover {
            transform: translateY(-8px);
            box-shadow: var(--shadow-lg);
        }

        .portfolio-image {
            width: 100%;
            height: 240px;
            object-fit: cover;
            display: block;
        }

        .portfolio-caption {
            padding: 1.5rem;
        }

        .portfolio-caption h4 {
            font-size: 1.2rem;
            margin-bottom: 0.3rem;
        }

        .portfolio-caption p {
            color: var(--gray);
            font-size: 0.9rem;
            margin-bottom: 1rem;
        }

        .portfolio-link {
            color: var(--primary);
            font-weight: 600;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            gap: 0.3rem;
            cursor: pointer;
            background: none;
            border: none;
            font-family: inherit;
            font-size: 1rem;
        }

        .portfolio-link i {
            transition: transform 0.2s;
        }

        .portfolio-link:hover i {
            transform: translateX(3px);
        }

        [dir="rtl"] .portfolio-link:hover i {
            transform: translateX(-3px);
        }

        /* About Section */
        .about {
            background: var(--section-bg);
        }

        .about-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 4rem;
            align-items: center;
        }

        .about-image {
            position: relative;
        }

        .about-image img {
            width: 100%;
            border-radius: 20px;
            box-shadow: var(--shadow-lg);
        }

        .about-image::before {
            content: '';
            position: absolute;
            top: -20px;
            left: -20px;
            width: 100%;
            height: 100%;
            border: 3px solid var(--primary);
            border-radius: 20px;
            z-index: -1;
        }

        .about-stats {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 1.5rem;
            margin-top: 2rem;
        }

        .stat-card {
            background: var(--card-bg);
            padding: 1.5rem;
            border-radius: 15px;
            text-align: center;
            box-shadow: var(--shadow);
            transition: var(--transition);
        }

        .stat-card:hover {
            transform: translateY(-5px);
        }

        .stat-card i {
            font-size: 2rem;
            color: var(--primary);
            margin-bottom: 0.5rem;
        }

        .stat-card h4 {
            font-size: 1.5rem;
            margin-bottom: 0.2rem;
        }

        .stat-card p {
            color: var(--gray);
            font-size: 0.9rem;
        }

        .vision-mission {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 2rem;
            margin-top: 3rem;
        }

        .vm-card {
            background: var(--card-bg);
            padding: 2.5rem;
            border-radius: 20px;
            box-shadow: var(--shadow);
            position: relative;
            overflow: hidden;
            transition: var(--transition);
        }

        .vm-card::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 5px;
            background: var(--primary);
        }

        .vm-card:hover {
            transform: translateY(-5px);
        }

        .vm-card i {
            font-size: 3rem;
            color: var(--primary);
            margin-bottom: 1rem;
        }

        .vm-card h3 {
            font-size: 1.5rem;
            margin-bottom: 1rem;
        }

        /* Services Section */
        .services-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 2rem;
        }

        .service-card {
            background: var(--card-bg);
            padding: 2.5rem;
            border-radius: 20px;
            box-shadow: var(--shadow);
            transition: var(--transition);
            position: relative;
            overflow: hidden;
            cursor: pointer;
        }

        .service-card::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 0;
            background: var(--primary);
            transition: var(--transition);
            z-index: 0;
        }

        .service-card:hover::before {
            height: 100%;
        }

        .service-card:hover {
            transform: translateY(-10px);
        }

        .service-card>* {
            position: relative;
            z-index: 1;
        }

        .service-card:hover h3,
        .service-card:hover p,
        .service-card:hover .service-icon {
            color: white;
        }

        .service-icon {
            width: 70px;
            height: 70px;
            background: rgba(37, 99, 235, 0.1);
            border-radius: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.8rem;
            color: var(--primary);
            margin-bottom: 1.5rem;
            transition: var(--transition);
        }

        .service-card:hover .service-icon {
            background: rgba(255, 255, 255, 0.2);
        }

        .service-card h3 {
            font-size: 1.3rem;
            margin-bottom: 1rem;
            transition: var(--transition);
        }

        .service-card p {
            color: var(--gray);
            line-height: 1.7;
            transition: var(--transition);
        }

        .service-card .learn-more {
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
            margin-top: 1.5rem;
            color: var(--primary);
            font-weight: 600;
            text-decoration: none;
            transition: var(--transition);
        }

        .service-card:hover .learn-more {
            color: white;
        }

        /* Products Section */
        .products {
            background: var(--section-bg);
        }

        .products-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
            gap: 2rem;
        }

        .product-card {
            background: var(--card-bg);
            border-radius: 20px;
            overflow: hidden;
            box-shadow: var(--shadow);
            transition: var(--transition);
        }

        .product-card:hover {
            transform: translateY(-10px);
            box-shadow: var(--shadow-lg);
        }

        .product-image {
            height: 250px;
            background: linear-gradient(135deg, var(--primary), var(--primary-dark));
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 4rem;
            color: white;
            position: relative;
            overflow: hidden;
        }

        .product-image::after {
            content: '';
            position: absolute;
            bottom: -50%;
            left: -50%;
            width: 200%;
            height: 200%;
            background: rgba(255, 255, 255, 0.1);
            transform: rotate(45deg);
            transition: var(--transition);
        }

        .product-card:hover .product-image::after {
            bottom: -30%;
        }

        .product-info {
            padding: 2rem;
        }

        .product-info h3 {
            font-size: 1.3rem;
            margin-bottom: 0.5rem;
        }

        .product-info p {
            color: var(--gray);
            margin-bottom: 1rem;
            line-height: 1.6;
        }

        .product-price {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--primary);
        }

        .product-btn {
            width: 100%;
            margin-top: 1rem;
            padding: 0.8rem;
            background: var(--primary);
            color: white;
            border: none;
            border-radius: 10px;
            cursor: pointer;
            font-weight: 600;
            transition: var(--transition);
        }

        .product-btn:hover {
            background: var(--primary-dark);
        }

        /* Counter Section */
        .counter-section {
            background: linear-gradient(135deg, var(--primary), var(--primary-dark));
            padding: 5rem 0;
            position: relative;
            overflow: hidden;
        }

        .counter-section::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.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
        }

        .counter-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 3rem;
            position: relative;
            z-index: 1;
        }

        .counter-item {
            text-align: center;
            color: white;
        }

        .counter-item i {
            font-size: 3rem;
            margin-bottom: 1rem;
            display: block;
        }

        .counter-number {
            font-size: 3rem;
            font-weight: 700;
            margin-bottom: 0.5rem;
            display: inline;
        }

        .counter-number-wrap {
            margin-bottom: 0.5rem;
        }

        .counter-suffix {
            font-size: 2rem;
            font-weight: 700;
        }

        .counter-item p {
            font-size: 1.1rem;
            opacity: 0.9;
        }

        /* Events Section */
        /* ── Events Cards ──────────────────────────────────────── */
        .events-section {
            padding: 5rem 0;
        }

        .events-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 1.75rem;
        }

        .event-card {
            background: var(--card-bg);
            border-radius: 20px;
            overflow: hidden;
            box-shadow: var(--shadow);
            border: 1px solid var(--border);
            transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
            display: flex;
            flex-direction: column;
        }

        .event-card:hover {
            transform: translateY(-8px);
            box-shadow: var(--shadow-lg);
            border-color: var(--primary);
        }

        /* Coloured top band */
        .event-card-top {
            height: 110px;
            background: linear-gradient(135deg, var(--primary), var(--primary-dark));
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
        }

        .event-card-top i {
            font-size: 2.75rem;
            color: rgba(255,255,255,.85);
        }

        /* Past / Upcoming badge */
        .event-badge {
            position: absolute;
            top: .75rem;
            right: .75rem;
            padding: .2rem .65rem;
            border-radius: 999px;
            font-size: .7rem;
            font-weight: 700;
            letter-spacing: .04em;
            text-transform: uppercase;
        }

        [dir="rtl"] .event-badge { right: auto; left: .75rem; }

        .event-badge-upcoming {
            background: rgba(255,255,255,.9);
            color: var(--primary);
        }

        .event-badge-past {
            background: rgba(0,0,0,.25);
            color: rgba(255,255,255,.8);
        }

        /* Card body */
        .event-card-body {
            padding: 1.5rem;
            display: flex;
            gap: 1rem;
            align-items: flex-start;
            flex: 1;
        }

        /* Numeric date stamp */
        .event-stamp {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            background: var(--section-bg);
            border: 2px solid var(--border);
            border-radius: 12px;
            padding: .5rem .75rem;
            min-width: 56px;
            flex-shrink: 0;
            text-align: center;
            line-height: 1;
        }

        .event-stamp-day {
            font-size: 1.6rem;
            font-weight: 800;
            color: var(--primary);
            display: block;
        }

        .event-stamp-month {
            font-size: .6rem;
            font-weight: 700;
            letter-spacing: .08em;
            color: var(--gray);
            display: block;
            margin-top: .1rem;
        }

        .event-stamp-year {
            font-size: .6rem;
            color: var(--text-light);
            display: block;
            margin-top: .1rem;
        }

        /* Text block */
        .event-card-text {
            flex: 1;
        }

        .event-card-text h3 {
            font-size: 1rem;
            font-weight: 700;
            margin: 0 0 .4rem;
            color: var(--text);
            line-height: 1.35;
        }

        .event-card-text p {
            font-size: .85rem;
            color: var(--gray);
            line-height: 1.6;
            margin: 0 0 .6rem;
        }

        .event-location {
            display: flex;
            align-items: center;
            gap: .4rem;
            font-size: .78rem;
            color: var(--text-light);
            margin-top: .25rem;
        }

        .event-location i {
            color: var(--primary);
            font-size: .8rem;
        }

        /* Clients & Partners */
        .clients-section {
            background: var(--section-bg);
        }

        .clients-grid,
        .partners-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
            gap: 2rem;
            align-items: center;
            justify-items: center;
        }

        .client-logo,
        .partner-logo {
            width: 150px;
            height: 80px;
            background: var(--card-bg);
            border-radius: 15px;
            overflow: hidden;
            box-shadow: var(--shadow);
            transition: var(--transition);
            cursor: pointer;
        }

        .client-logo img,
        .partner-logo img {
            width: 100%;
            height: 100%;
            object-fit: contain;
            display: block;
            background: var(--card-bg);
        }

        .client-logo:hover,
        .partner-logo:hover {
            transform: translateY(-5px);
            box-shadow: var(--shadow-lg);
        }

        /* Team Section */
        .team-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 1.75rem;
        }

        .team-card {
            background: var(--card-bg);
            border-radius: 20px;
            overflow: hidden;
            box-shadow: var(--shadow);
            transition: var(--transition);
            border: 1px solid var(--border);
            display: flex;
            flex-direction: column;
        }

        .team-card:hover {
            transform: translateY(-8px);
            box-shadow: var(--shadow-lg);
            border-color: var(--primary);
        }

        /* ── Photo area ── */
        .team-image {
            aspect-ratio: 4 / 3;
            background: linear-gradient(160deg, var(--primary), var(--primary-dark));
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 4rem;
            color: rgba(255,255,255,.7);
            position: relative;
            overflow: hidden;
        }

        .team-image img {
            position: absolute;
            inset: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: top center;
            transition: transform .4s ease;
        }

        .team-card:hover .team-image img {
            transform: scale(1.05);
        }

        .team-image-fallback {
            font-size: 4rem;
        }

        /* ── Card footer (info + social) ── */
        .team-info {
            padding: 1.25rem 1.25rem 1rem;
            text-align: center;
            flex: 1;
            display: flex;
            flex-direction: column;
            gap: .2rem;
        }

        .team-info h3 {
            font-size: 1.05rem;
            font-weight: 700;
            color: var(--text);
            margin: 0;
            letter-spacing: .01em;
        }

        .team-position {
            color: var(--primary);
            font-weight: 600;
            font-size: .82rem;
            text-transform: uppercase;
            letter-spacing: .06em;
            margin: .15rem 0 .3rem;
        }

        .team-bio {
            color: var(--text-light);
            font-size: .82rem;
            line-height: 1.5;
            flex: 1;
        }

        /* ── Social row — sits at the bottom of the card ── */
        .team-social {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: .5rem;
            margin-top: .9rem;
            padding-top: .9rem;
            border-top: 1px solid var(--border);
        }

        .team-social a {
            width: 32px;
            height: 32px;
            border-radius: 8px;
            border: 1px solid var(--border);
            background: var(--section-bg);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            color: var(--gray);
            text-decoration: none;
            font-size: .85rem;
            transition: var(--transition);
        }

        .team-social a:hover {
            background: var(--primary);
            border-color: var(--primary);
            color: #fff;
            transform: translateY(-2px);
        }

        /* Testimonials */
        .testimonials {
            background: var(--section-bg);
        }

        .testimonial-slider {
            max-width: 800px;
            margin: 0 auto;
            position: relative;
        }

        .testimonial-item {
            background: var(--card-bg);
            padding: 3rem;
            border-radius: 20px;
            box-shadow: var(--shadow);
            text-align: center;
            display: none;
        }

        .testimonial-item.active {
            display: block;
            animation: fadeIn 0.5s;
        }

        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(20px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .testimonial-item i.quote {
            font-size: 3rem;
            color: var(--primary);
            opacity: 0.3;
            margin-bottom: 1rem;
        }

        .testimonial-item p {
            font-size: 1.1rem;
            line-height: 1.8;
            margin-bottom: 2rem;
            font-style: italic;
        }

        .testimonial-author {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 1rem;
        }

        .author-avatar {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            background: linear-gradient(135deg, var(--primary), var(--secondary));
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 1.5rem;
            font-weight: 700;
        }

        .author-info {
            text-align: left;
        }

        .author-info h4 {
            margin-bottom: 0.2rem;
        }

        .author-info span {
            color: var(--gray);
            font-size: 0.9rem;
        }

        .testimonial-dots {
            display: flex;
            justify-content: center;
            gap: 0.5rem;
            margin-top: 2rem;
        }

        .dot {
            width: 12px;
            height: 12px;
            border-radius: 50%;
            background: var(--gray-light);
            cursor: pointer;
            transition: var(--transition);
        }

        .dot.active {
            background: var(--primary);
            width: 30px;
            border-radius: 6px;
        }

        /* Download Section */
        .download-section {
            background: linear-gradient(135deg, var(--primary), var(--primary-dark));
            padding: 5rem 0;
            text-align: center;
            color: white;
        }
        .download-section h2 {
            font-size: 2.5rem;
            margin-bottom: 1rem;
        }
        .download-section p {
            font-size: 1.1rem;
            margin-bottom: 2rem;
            opacity: 0.9;
        }
        .download-btn {
            background: white;
            color: var(--primary);
            border: 2px solid white;
            transition: all 0.3s;
        }
        .download-btn:hover {
            background: transparent;
            color: white;
        }

        /* Contact Section */
        .contact-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 4rem;
        }

        .contact-info h3 {
            font-size: 1.8rem;
            margin-bottom: 1.5rem;
        }

        .contact-details {
            margin-top: 2rem;
        }

        .contact-item {
            display: flex;
            align-items: flex-start;
            gap: 1rem;
            margin-bottom: 1.5rem;
        }

        .contact-item i {
            width: 50px;
            height: 50px;
            background: rgba(37, 99, 235, 0.1);
            border-radius: 15px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary);
            font-size: 1.2rem;
            flex-shrink: 0;
        }

        .contact-item div h4 {
            margin-bottom: 0.3rem;
        }

        .contact-item div p {
            color: var(--gray);
        }

        .contact-map {
            margin-top: 2rem;
            border-radius: 15px;
            overflow: hidden;
            box-shadow: var(--shadow);
        }

        .contact-map iframe {
            width: 100%;
            height: 250px;
            border: 0;
        }

        .contact-form {
            background: var(--card-bg);
            padding: 2.5rem;
            border-radius: 20px;
            box-shadow: var(--shadow);
        }

        .form-group {
            margin-bottom: 1.5rem;
        }

        .form-group label {
            display: block;
            margin-bottom: 0.5rem;
            font-weight: 500;
        }

        .form-group input,
        .form-group textarea {
            width: 100%;
            padding: 1rem;
            border: 2px solid var(--border);
            border-radius: 10px;
            background: var(--light);
            color: var(--text);
            font-family: inherit;
            transition: var(--transition);
        }

        .form-group input:focus,
        .form-group textarea:focus {
            outline: none;
            border-color: var(--primary);
        }

        .form-group textarea {
            resize: vertical;
            min-height: 120px;
        }

        .captcha-wrapper {
            display: flex;
            align-items: center;
            gap: 0.8rem;
            flex-wrap: wrap;
        }

        .captcha-input {
            flex: 1;
            min-width: 100px;
        }

        .captcha-question {
            font-weight: 700;
            color: var(--primary);
            white-space: nowrap;
        }

        .captcha-refresh {
            background: none;
            border: none;
            color: var(--primary);
            font-size: 1.2rem;
            cursor: pointer;
            padding: 0.4rem;
            border-radius: 50%;
            transition: var(--transition);
        }

        .captcha-refresh:hover {
            background: rgba(37, 99, 235, 0.1);
        }

        .form-error {
            color: #ef4444;
            font-size: 0.85rem;
            margin-top: 0.3rem;
            display: none;
        }

        /* Footer */
        footer {
            background: #020617;
            color: white;
            padding: 4rem 0 0;
        }

        .footer-grid {
            display: grid;
            grid-template-columns: 2fr 1fr 1fr 1fr;
            gap: 3rem;
            margin-bottom: 3rem;
        }

        .footer-brand h3 {
            font-size: 1.8rem;
            margin-bottom: 1rem;
            color: white;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .footer-brand h3 img {
            height: 30px;
            border-radius: 5px;
        }

        .footer-brand p {
            color: rgba(255, 255, 255, 0.7);
            line-height: 1.8;
            margin-bottom: 1.5rem;
        }

        .social-links {
            display: flex;
            gap: 1rem;
        }

        .social-links a {
            width: 40px;
            height: 40px;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            text-decoration: none;
            transition: var(--transition);
        }

        .social-links a:hover {
            background: var(--primary);
            transform: translateY(-3px);
        }

        .footer-links h4 {
            margin-bottom: 1.5rem;
            color: white;
        }

        .footer-links ul {
            list-style: none;
        }

        .footer-links li {
            margin-bottom: 0.8rem;
        }

        .footer-links a {
            color: rgba(255, 255, 255, 0.7);
            text-decoration: none;
            transition: var(--transition);
        }

        .footer-links a:hover {
            color: var(--primary);
            padding-left: 5px;
        }

        .footer-bottom {
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            padding: 2rem 0;
            text-align: center;
            color: rgba(255, 255, 255, 0.6);
        }

        /* Floating Buttons */
        .floating-buttons {
            position: fixed;
            bottom: 2rem;
            right: 2rem;
            z-index: 999;
            display: flex;
            flex-direction: column;
            gap: 1rem;
        }

        .fab {
            width: 55px;
            height: 55px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 1.5rem;
            cursor: pointer;
            box-shadow: var(--shadow-lg);
            transition: var(--transition);
            text-decoration: none;
            border: none;
        }

        .fab:hover {
            transform: scale(1.1);
        }

        .fab-whatsapp {
            background: #25d366;
        }

        .fab-top {
            background: var(--primary);
            opacity: 0;
            visibility: hidden;
        }

        .fab-top.visible {
            opacity: 1;
            visibility: visible;
        }

        /* Popups */
        .popup-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.5);
            z-index: 2000;
            display: none;
            opacity: 0;
            transition: opacity 0.3s;
        }

        .popup-overlay.active {
            display: block;
            opacity: 1;
        }

        .popup {
            position: fixed;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%) scale(0.9);
            background: var(--card-bg);
            padding: 0;
            border-radius: 20px;
            box-shadow: var(--shadow-lg);
            z-index: 2001;
            max-width: 560px;
            width: 92%;
            max-height: 88vh;
            display: none;
            opacity: 0;
            transition: all 0.3s;
            overflow: hidden;
            flex-direction: column;
        }

        .popup-body {
            padding: 2.5rem;
            overflow-y: auto;
            flex: 1;
            -webkit-overflow-scrolling: touch;
        }

        .popup-header-bar {
            display: flex;
            justify-content: flex-end;
            padding: .6rem .6rem 0;
            flex-shrink: 0;
        }

        .popup.active {
            display: flex;
            opacity: 1;
            transform: translate(-50%, -50%) scale(1);
        }

        .popup-close {
            background: var(--section-bg);
            border: none;
            font-size: 1.1rem;
            cursor: pointer;
            color: var(--gray);
            width: 36px;
            height: 36px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: var(--transition);
            flex-shrink: 0;
        }

        .popup-close:hover {
            background: rgba(0, 0, 0, 0.1);
            color: var(--text);
        }

        /* Side Panel */
        .side-panel {
            position: fixed;
            top: 0;
            right: -400px;
            width: 400px;
            max-width: 90%;
            height: 100%;
            background: var(--card-bg);
            z-index: 2002;
            box-shadow: var(--shadow-lg);
            transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            overflow-y: auto;
        }

        .side-panel.active {
            right: 0;
        }

        .side-panel-header {
            padding: 2rem;
            background: linear-gradient(135deg, var(--primary), var(--primary-dark));
            color: white;
            position: relative;
        }

        .side-panel-close {
            position: absolute;
            top: 1rem;
            right: 1rem;
            background: none;
            border: none;
            color: white;
            font-size: 1.5rem;
            cursor: pointer;
            width: 40px;
            height: 40px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: var(--transition);
        }

        .side-panel-close:hover {
            background: rgba(255, 255, 255, 0.2);
        }

        .side-panel-content {
            padding: 2rem;
        }

        .side-panel-content h4 {
            margin: 1.5rem 0 0.5rem;
            color: var(--primary);
        }

        .side-panel-content ul {
            list-style: none;
            margin-left: 0;
        }

        .side-panel-content li {
            padding: 0.5rem 0;
            color: var(--gray);
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .side-panel-content li i {
            color: var(--primary);
            font-size: 0.8rem;
        }

        /* Mobile Menu */
        .mobile-nav {
            position: fixed;
            top: 0;
            left: -100%;
            width: 300px;
            max-width: 80%;
            height: 100%;
            background: var(--card-bg);
            z-index: 2002;
            box-shadow: var(--shadow-lg);
            transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            overflow-y: auto;
        }

        .mobile-nav.active {
            left: 0;
        }

        .mobile-nav-header {
            padding: 2rem;
            background: var(--primary);
            color: white;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .mobile-nav-links {
            list-style: none;
            padding: 1rem 0;
        }

        .mobile-nav-links li {
            border-bottom: 1px solid var(--border);
        }

        .mobile-nav-links a {
            display: block;
            padding: 1rem 2rem;
            color: var(--text);
            text-decoration: none;
            transition: var(--transition);
        }

        .mobile-nav-links a:hover {
            background: var(--section-bg);
            color: var(--primary);
            padding-left: 2.5rem;
        }

        /* Mobile Language Switcher */
        .mobile-lang-switch {
            display: flex;
            gap: 0.5rem;
            padding: 1rem 2rem;
            border-top: 1px solid var(--border);
            margin-top: 0.5rem;
        }

        .mobile-lang-btn {
            flex: 1;
            padding: 0.6rem;
            border: 2px solid var(--border);
            border-radius: 10px;
            background: transparent;
            color: var(--text);
            cursor: pointer;
            font-weight: 600;
            font-size: 0.9rem;
            transition: var(--transition);
            font-family: inherit;
        }

        .mobile-lang-btn.active {
            background: var(--primary);
            color: white;
            border-color: var(--primary);
        }

        .mobile-lang-btn:hover:not(.active) {
            border-color: var(--primary);
            color: var(--primary);
        }

        /* Responsive */
        @media (max-width: 992px) {
            .about-grid,
            .contact-grid {
                grid-template-columns: 1fr;
            }

            .footer-grid {
                grid-template-columns: 1fr 1fr;
            }

            .events-grid {
                grid-template-columns: repeat(2, 1fr);
            }

            .portfolio-grid {
                grid-template-columns: repeat(2, 1fr);
            }

            .lang-switcher {
                display: none;
            }
        }

        @media (max-width: 768px) {
            .nav-links {
                display: none;
            }

            .mobile-menu {
                display: block;
            }

            .vision-mission {
                grid-template-columns: 1fr;
            }

            .team-grid {
                grid-template-columns: repeat(2, 1fr);
                gap: 1rem;
            }

            .portfolio-grid {
                grid-template-columns: 1fr;
                max-width: 100%;
            }

            .events-grid {
                grid-template-columns: 1fr;
            }

            .footer-grid {
                grid-template-columns: 1fr;
                text-align: center;
            }

            .social-links {
                justify-content: center;
            }

            .hero-buttons {
                flex-direction: column;
                align-items: center;
            }

            .btn {
                width: 100%;
                max-width: 300px;
                justify-content: center;
            }

            .lang-switcher {
                display: none;
            }
        }

        @media (min-width: 993px) {
            .mobile-lang-switch {
                display: none;
            }
        }
        /* Force a repaint on initial load */
#sections-container {
    display: block;
    width: 100%;
    will-change: transform;           /* promote to its own layer */
    animation: fixLayout 0.01s ease;  /* triggers a repaint immediately */
    min-height: 100vh;          /* fallback */
    min-height: 100dvh;         /* use dynamic viewport for modern browsers */
    /* Ensure no overflow issues */
    overflow-x: hidden;
}

/* Tiny animation – invisible but forces reflow */
@keyframes fixLayout {
    0%   { transform: scale(0.9999); }
    100% { transform: scale(1); }
}