/* Antigravity Design System */
:root {
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.4);
    --secondary: #a855f7;
    --accent: #ec4899;
    --font-en: 'Inter', sans-serif;
    --font-ar: 'Cairo', sans-serif;
    --font: var(--font-en);
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

html[lang="ar"] {
    --font: var(--font-ar);
}

[data-theme="dark"] {
    --bg-main: #060913;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --glass-bg: rgba(17, 24, 39, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
    --card-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    --hover-shadow: 0 30px 60px -12px rgba(99, 102, 241, 0.3);
    --navbar-bg: rgba(6, 9, 19, 0.8);
    --input-bg: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] {
    --bg-main: #f4f6f8;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.6);
    --card-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.08);
    --hover-shadow: 0 30px 60px -12px rgba(99, 102, 241, 0.2);
    --navbar-bg: rgba(244, 246, 248, 0.8);
    --input-bg: rgba(0, 0, 0, 0.05);
}

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

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

/* Background Particles Container */
#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* Typography & Utilities */
h1,
h2,
h3,
h4 {
    line-height: 1.2;
    font-weight: 700;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-center {
    text-align: center;
}

/* Buttons & Inputs */
button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    box-shadow: 0 10px 20px -5px var(--primary-glow);
}

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

.btn-glass {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-weight: 600;
    backdrop-filter: blur(10px);
}

.btn-glass:hover {
    background: rgba(150, 150, 150, 0.1);
    transform: translateY(-3px);
}

.icon-btn {
    background: transparent;
    color: var(--text-main);
    font-size: 1.2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-btn:hover {
    background: var(--glass-bg);
}

.glass-input {
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 1rem 1.5rem;
    border-radius: 50px;
    font-size: 1rem;
    outline: none;
    width: 100%;
    max-width: 350px;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.glass-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.2rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    background: var(--navbar-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 5%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.5rem;
    font-weight: 800;
}

.logo-img {
    height: 75px;
    width: auto;
    object-fit: contain;
}

.logo-icon {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    transition: var(--transition);
}

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

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

/* Antigravity Glass Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    padding: 2.5rem;
    transition: var(--transition);
    position: relative;
    z-index: 1;
}

.glass-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--hover-shadow);
    border-color: rgba(99, 102, 241, 0.4);
}

/* Sections Common */
.section {
    padding: 6rem 5%;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.section-heading {
    max-width: 700px;
    margin: 0 auto 4rem;
}

/* Hero */
.hero {
    min-height: 90vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    padding-top: 8rem;
}

.badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    border-radius: 50px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2.5rem;
}

.hero-visual {
    position: relative;
    height: 500px;
}

.hero-stat-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    width: 280px;
}

.hero-stat-card i {
    font-size: 2rem;
}

.hero-stat-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.2rem;
}

.hero-stat-card p {
    font-size: 0.9rem;
    margin: 0;
}

.floating-1 {
    top: 10%;
    right: 10%;
    animation: float 6s ease-in-out infinite;
}

.floating-2 {
    top: 45%;
    left: 0;
    animation: float 8s ease-in-out infinite 1s;
}

.floating-3 {
    bottom: 10%;
    right: 20%;
    animation: float 7s ease-in-out infinite 2s;
}

.floating-slow {
    animation: float 10s ease-in-out infinite;
}

.glow-orb {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    filter: blur(50px);
}

.journey-orb {
    background: radial-gradient(circle, rgba(236, 72, 153, 0.3) 0%, transparent 70%);
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.icon-box {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
}

.features-grid h3 {
    margin-bottom: 1rem;
}

/* Journey */
.journey-container,
.events-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.journey-steps {
    margin-top: 2.5rem;
    position: relative;
}

.journey-steps::before {
    content: '';
    position: absolute;
    left: 11px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--glass-border);
}

.step {
    display: flex;
    gap: 2rem;
    margin-bottom: 2.5rem;
    position: relative;
}

.step-dot {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg-main);
    border: 3px solid var(--primary);
    position: relative;
    z-index: 1;
    box-shadow: 0 0 15px var(--primary-glow);
}

.step-text h4 {
    margin-bottom: 0.5rem;
}

/* Progress Bars */
.dashboard-widget {
    padding: 2rem;
    width: 100%;
    max-width: 450px;
    margin: 0 auto;
}

.widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.progress-bar-container {
    margin-bottom: 1.5rem;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.progress-track {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

[data-theme="light"] .progress-track {
    background: rgba(0, 0, 0, 0.05);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 10px;
    transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Auth Grid */
.auth-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.auth-card {
    text-align: center;
}

.auth-icon {
    font-size: 3rem;
    color: var(--secondary);
    margin-bottom: 1.5rem;
}

.auth-card h3 {
    margin-bottom: 1rem;
}

/* Events */
.feature-list {
    list-style: none;
    margin-top: 2rem;
}

.feature-list li {
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.1rem;
}

.qr-badge {
    width: 320px;
    margin: 0 auto;
    padding: 0;
    overflow: hidden;
}

.badge-header {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(99, 102, 241, 0.1);
}

.avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--primary));
}

.qr-code {
    padding: 3rem;
    text-align: center;
    font-size: 8rem;
    color: var(--text-main);
}

.badge-footer {
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    border-top: 1px solid var(--glass-border);
}

.status-verified {
    color: #10b981;
    font-weight: 600;
}

/* Admin Mockup */
.admin-mockup {
    display: flex;
    padding: 0;
    height: 500px;
    overflow: hidden;
    border-radius: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.mockup-sidebar {
    width: 80px;
    border-right: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 0;
    gap: 1.5rem;
    background: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .mockup-sidebar {
    background: rgba(0, 0, 0, 0.02);
}

.mockup-logo {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    margin-bottom: 2rem;
}

.mockup-menu-item {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--glass-border);
    transition: var(--transition);
}

.mockup-menu-item.active {
    background: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.mockup-main {
    flex: 1;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.mockup-header {
    display: flex;
    justify-content: space-between;
}

.mockup-search {
    width: 250px;
    height: 36px;
    border-radius: 18px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
}

.mockup-profile {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--glass-border);
}

.mockup-stats {
    display: flex;
    gap: 1.5rem;
}

.mockup-stat-card {
    flex: 1;
    height: 100px;
    border-radius: 16px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    padding: 1rem;
    display: flex;
    align-items: flex-end;
}

.stat-inner {
    height: 8px;
    border-radius: 4px;
    background: var(--primary);
}

.w-50 {
    width: 50%;
}

.w-80 {
    width: 80%;
}

.w-30 {
    width: 30%;
}

.mockup-chart {
    flex: 1;
    border-radius: 16px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    position: relative;
    overflow: hidden;
}

.mockup-chart::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    background: linear-gradient(180deg, transparent, var(--primary-glow));
    clip-path: polygon(0 100%, 0 60%, 15% 40%, 30% 70%, 50% 30%, 70% 50%, 85% 20%, 100% 40%, 100% 100%);
}

/* CTA & Footer */
.cta-card {
    padding: 4rem 2rem;
    text-align: center;
}

.cta-form {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

footer {
    text-align: center;
    padding: 3rem 5%;
    border-top: 1px solid var(--glass-border);
    margin-top: 4rem;
    color: var(--text-muted);
}

/* Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Responsive */
@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 7rem;
    }

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

    .hero-visual {
        display: none;
    }

    .journey-container,
    .events-container {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .nav-links {
        display: none;
    }

    .admin-mockup {
        flex-direction: column;
        height: auto;
    }

    .mockup-sidebar {
        width: 100%;
        flex-direction: row;
        justify-content: space-around;
        padding: 1rem;
        border-right: none;
        border-bottom: 1px solid var(--glass-border);
    }

    .mockup-logo {
        margin-bottom: 0;
    }

    .mockup-stats {
        flex-direction: column;
    }

    .mockup-chart {
        min-height: 200px;
    }
}

/* ----------------------------------
   RTL Adjustments for Arabic Language
   ---------------------------------- */
html[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

html[dir="rtl"] .journey-steps::before {
    left: auto;
    right: 11px;
}

html[dir="rtl"] .mockup-sidebar {
    border-right: none;
    border-left: 1px solid var(--glass-border);
}

@media (max-width: 900px) {
    html[dir="rtl"] .mockup-sidebar {
        border-left: none;
        border-bottom: 1px solid var(--glass-border);
    }
}