@import url('https://fonts.googleapis.com/css2?family=Almarai:wght@300;400;700;800&family=Outfit:wght@200;400;700;900&display=swap');

:root {
    /* Extreme Premium Palette */
    --clr-bg: #030305;
    --clr-bg-alt: #0a0a0f;
    --clr-surface: rgba(20, 20, 25, 0.4);
    
    --clr-gold: #D4AF37;
    --clr-gold-light: #F8E5A0;
    --clr-coral: #E63946;
    
    --clr-text-main: #FFFFFF;
    --clr-text-muted: #8A8A93;
    
    --clr-border: rgba(255, 255, 255, 0.05);
    --clr-glow: rgba(212, 175, 55, 0.15);
    
    --transition-snappy: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Base Reset & Grain Effect */
* {
    margin: 0; padding: 0; box-sizing: border-box;
    cursor: none; /* Custom Cursor */
}

body {
    background-color: var(--clr-bg);
    color: var(--clr-text-main);
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: ""; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03; z-index: 9999; pointer-events: none;
}

body.lang-ar { font-family: 'Almarai', sans-serif; direction: rtl; }
body.lang-en { font-family: 'Outfit', sans-serif; direction: ltr; }

/* Custom Cursor */
.custom-cursor {
    width: 6px; height: 6px; background: var(--clr-gold); border-radius: 50%;
    position: fixed; top: -3px; left: -3px; pointer-events: none; z-index: 10000;
    transition: width 0.3s, height 0.3s, background 0.3s;
}
.custom-cursor-follower {
    width: 40px; height: 40px; border: 1px solid rgba(212, 175, 55, 0.5); border-radius: 50%;
    position: fixed; top: -20px; left: -20px; pointer-events: none; z-index: 9999;
    transition: width 0.3s, height 0.3s, border-color 0.3s, top 0.3s, left 0.3s, background 0.3s;
}
.custom-cursor.hover-active { width: 0; height: 0; }
.custom-cursor-follower.hover-active {
    width: 60px; height: 60px; top: -30px; left: -30px;
    background: rgba(230, 57, 70, 0.1); border-color: var(--clr-coral); backdrop-filter: blur(2px);
}

/* Typography */
h1, h2, h3 { font-weight: 800; line-height: 1.1; color: var(--clr-text-main); }
a { color: var(--clr-text-main); text-decoration: none; transition: color var(--transition-snappy); }
a:hover { color: var(--clr-gold); }

/* Buttons - Sci-Fi Elegant */
.btn {
    position: relative; display: inline-flex; align-items: center; justify-content: center;
    padding: 16px 40px; font-size: 1.1rem; font-weight: 700; border-radius: 4px;
    overflow: hidden; z-index: 1; transition: var(--transition-snappy); border: none; background: transparent;
    font-family: inherit; color: var(--clr-text-main); text-transform: uppercase; letter-spacing: 1px;
}
.btn::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: var(--clr-gold); z-index: -2; transition: transform var(--transition-snappy);
    transform: scaleX(0); transform-origin: right;
}
body.lang-en .btn::before { transform-origin: left; }
.btn:hover::before { transform: scaleX(1); transform-origin: left; }
body.lang-en .btn:hover::before { transform-origin: right; }
.btn:hover { color: var(--clr-bg); }

.btn-primary { border: 1px solid var(--clr-gold); color: var(--clr-gold); }
.btn-outline { border: 1px solid rgba(255,255,255,0.2); }
.btn-outline::before { background: var(--clr-text-main); }
.btn-outline:hover { border-color: var(--clr-text-main); color: var(--clr-bg); }

.btn-glow { box-shadow: 0 0 30px rgba(212, 175, 55, 0.2); }
.btn-glow:hover { box-shadow: 0 0 50px rgba(212, 175, 55, 0.6); }

/* Header */
.site-header {
    position: fixed; top: 0; left: 0; width: 100%; height: 100px;
    display: flex; align-items: center; z-index: 1000;
    transition: var(--transition-smooth);
    border-bottom: 1px solid transparent;
}
.site-header.scrolled {
    height: 80px; background: rgba(3,3,5,0.8); backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.nav-container { display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 0 40px; gap: 20px; }
.logo { font-size: 1.2rem; font-weight: 900; color: var(--clr-text-main); letter-spacing: 1px; display: flex; align-items: center; white-space: nowrap; }
.logo span { color: var(--clr-gold); }
.nav-links { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav-links a { font-size: 0.9rem; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; position: relative; white-space: nowrap; }
.nav-links a::after {
    content: ''; position: absolute; bottom: -5px; left: 0; width: 0%; height: 2px; background: var(--clr-gold); transition: width var(--transition-snappy);
}
.nav-links a:hover::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: 20px; }
.lang-switch { font-weight: 800; color: var(--clr-text-main); text-transform: uppercase; font-size: 1rem; }
.lang-switch:hover { color: var(--clr-gold); }
.menu-toggle { display: none; flex-direction: column; gap: 6px; cursor: pointer; }
.menu-toggle span { width: 30px; height: 2px; background: var(--clr-text-main); transition: 0.3s; }


/* Advanced Reveal Animations */
.reveal-up { opacity: 0; transform: translateY(60px); transition: var(--transition-smooth); }
.reveal-up.in-view { opacity: 1; transform: translateY(0); }

.reveal-scale { opacity: 0; transform: scale(0.9); transition: var(--transition-smooth); }
.reveal-scale.in-view { opacity: 1; transform: scale(1); }

/* Layout Grid */
.container { width: 100%; max-width: 1400px; margin: 0 auto; padding: 0 20px; }
.section { padding: 150px 0; position: relative; }

/* Dynamic Cards (Glass + Glow) */
.glass-card {
    background: var(--clr-surface);
    backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 50px;
    position: relative;
    overflow: hidden;
    transition: var(--transition-snappy);
}
.glass-card::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(800px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(255,255,255,0.06), transparent 40%);
    opacity: 0; transition: opacity var(--transition-snappy); z-index: 0; pointer-events: none;
}
.glass-card:hover::before { opacity: 1; }
.glass-card > * { position: relative; z-index: 1; }
.realm-interactive-card:hover .realm-icon-3d { transform: translateZ(30px) rotateY(15deg); }

/* Infinite Marquee Animations */
.marquee-wrapper {
    overflow: hidden;
    width: 100%;
    position: relative;
    display: flex;
}
.marquee-wrapper::before, .marquee-wrapper::after {
    content: ''; position: absolute; top: 0; width: 100px; height: 100%; z-index: 2; pointer-events: none;
}
.marquee-wrapper::before {
    left: 0; background: linear-gradient(to right, rgba(10,15,12,1), transparent);
}
.marquee-wrapper::after {
    right: 0; background: linear-gradient(to left, rgba(10,15,12,1), transparent);
}
.interactive-realms {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 40px 20px;
    scrollbar-width: none; /* Hide scrollbar */
}
.marquee-content {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
}
.marquee-content > * {
    flex-shrink: 0;
}

.glass-card:hover { transform: translateY(-10px); border-color: rgba(212, 175, 55, 0.3); box-shadow: 0 30px 60px rgba(0,0,0,0.5); }

/* Hero Ultra-Premium */
.hero-ultra {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    position: relative; overflow: hidden; padding-top: 100px;
}
.hero-ultra h1 {
    font-size: 8vw; line-height: 0.9; text-transform: uppercase;
    background: linear-gradient(180deg, #FFFFFF 0%, rgba(255, 255, 255, 0) 150%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    text-align: center; letter-spacing: -2px; margin-bottom: 30px;
}
.hero-bg-orb {
    position: absolute; width: 800px; height: 800px; border-radius: 50%;
    background: radial-gradient(circle, rgba(212,175,55,0.15) 0%, transparent 60%);
    top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: -1; filter: blur(50px);
}
.hero-bg-orb-coral {
    position: absolute; width: 600px; height: 600px; border-radius: 50%;
    background: radial-gradient(circle, rgba(230,57,70,0.1) 0%, transparent 60%);
    top: 30%; left: 30%; transform: translate(-50%, -50%); z-index: -1; filter: blur(40px);
}

/* Forms & Inputs */
.form-control, .form-select, .form-textarea {
    width: 100%; background: rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.1);
    color: white; padding: 18px 20px; border-radius: 8px; font-family: inherit; font-size: 1rem;
    transition: var(--transition-snappy);
}
.form-control:focus { border-color: var(--clr-gold); outline: none; box-shadow: 0 0 15px rgba(212,175,55,0.2); }
label { display: block; margin-bottom: 10px; color: var(--clr-text-muted); font-size: 0.9rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }

/* Responsive adjustments */
@media (max-width: 1200px) {
    .logo { font-size: 1rem; }
    .nav-links { gap: 15px; }
    .nav-links a { font-size: 0.8rem; }
    .header-actions { gap: 10px; }
    .btn { padding: 12px 20px; font-size: 0.9rem; }
}

@media (max-width: 992px) {
    .hero-ultra h1 { font-size: 12vw; }
    .nav-links { 
        display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; width: 100%; 
        background: rgba(5,8,6,0.98); border-bottom: 1px solid rgba(255,255,255,0.1);
        padding: 0; max-height: 0; overflow: hidden; transition: all 0.4s ease-out; gap: 15px; align-items: center;
        z-index: 999;
    }
    .nav-links.active { max-height: 100vh; padding: 30px 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.8); }
    .menu-toggle { display: flex; z-index: 1001; position: relative; }
    .menu-toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .menu-toggle.active span:nth-child(2) { opacity: 0; }
    .menu-toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
    .logo { 
        font-size: 0.9rem; 
        max-width: 45vw; 
        white-space: normal; 
        line-height: 1.3; 
        text-align: right;
    }
    .footer-content { grid-template-columns: 1fr; gap: 40px; }
}

/* Footer Ultra Premium */
.site-footer {
    background: linear-gradient(to top, #020203, var(--clr-bg));
    border-top: 1px solid var(--clr-border);
    padding: 80px 0 40px;
    position: relative;
    overflow: hidden;
}
.site-footer::before {
    content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 60%; height: 200px; background: radial-gradient(ellipse at bottom, rgba(212, 175, 55, 0.1), transparent 70%);
    z-index: 0; pointer-events: none;
}
.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    position: relative;
    z-index: 1;
    margin-bottom: 60px;
}
.footer-col h4 {
    color: var(--clr-gold);
    font-size: 1.4rem;
    margin-bottom: 25px;
    letter-spacing: 1px;
}
.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.footer-col ul li {
    margin-bottom: 15px;
}
.footer-col ul li a {
    color: var(--clr-text-muted);
    font-size: 1.05rem;
    transition: var(--transition-snappy);
    display: inline-block;
}
.footer-col ul li a:hover {
    color: var(--clr-text-main);
    transform: translateX(-5px);
}
body.lang-en .footer-col ul li a:hover {
    transform: translateX(5px);
}
.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 30px;
    position: relative;
    z-index: 1;
}
.footer-bottom p {
    color: var(--clr-text-muted);
    font-size: 0.95rem;
}
.footer-bottom a {
    color: var(--clr-gold);
    font-weight: 700;
}
.footer-bottom a:hover {
    color: var(--clr-text-main);
}
