@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;700;900&family=Nunito:wght@400;700;900&display=swap');

:root {
    --bg-center: #475569;
    --bg-edge: #334155;
    --glass-bg: rgba(15, 23, 42, 0.4);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --primary-light: #E5A024;
    --primary-dark: #C07C18;
    --btn-neutral: rgba(255, 255, 255, 0.1);
    --btn-hover: #3b82f6;
    --radius: 16px;
}

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

body {
    font-family: 'Nunito', sans-serif;
    color: var(--text-main);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    background-color: var(--bg-edge);
    background-image: 
        radial-gradient(circle, rgba(255,255,255,0.08) 1.5px, transparent 1.5px),
        radial-gradient(circle at center, var(--bg-center) 0%, var(--bg-edge) 120%);
    background-size: 40px 40px, 100% 100%;
    background-position: 0 0, center center;
    background-attachment: fixed;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

html[dir="rtl"] body {
    font-family: 'Cairo', sans-serif;
}

.lang-ar { display: none; }
html[dir="rtl"] .lang-en { display: none; }
html[dir="rtl"] .lang-ar { display: block; }
span.lang-ar { display: none; }
html[dir="rtl"] span.lang-en { display: none; }
html[dir="rtl"] span.lang-ar { display: inline; }

a { text-decoration: none; color: inherit; transition: all 0.3s ease; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

.header {
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    padding: 18px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    font-size: 28px;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: var(--text-main);
    text-shadow: 0 3px 5px rgba(0,0,0,0.5);
}

html[dir="rtl"] .logo { letter-spacing: 0; }

/* توزيع مريح للكمبيوتر */
.nav-links { display: flex; align-items: center; gap: 40px; font-size: 17px; font-weight: 800; }
.nav-links a:hover, .nav-links a.active-link, .sidebar-links a.active-link { color: var(--primary-light); }

.btn-lang {
    background: rgba(255,255,255,0.1);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 8px 18px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 800;
    font-size: 15px;
    transition: all 0.3s ease;
}
.btn-lang:hover { background: rgba(255,255,255,0.2); }

.btn-premium, .btn-nav-download {
    background: var(--btn-neutral);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff !important;
    border-radius: 30px;
    font-weight: 900;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
    text-shadow: 0 2px 3px rgba(0,0,0,0.4);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

html[dir="rtl"] .btn-premium, html[dir="rtl"] .btn-nav-download { letter-spacing: 0; }

.btn-nav-download { padding: 10px 24px; font-size: 15px; }
.btn-premium { padding: 14px 32px; font-size: 16px; text-transform: uppercase; }

.btn-premium:hover, .btn-nav-download:hover {
    background: var(--btn-hover);
    border-color: var(--btn-hover);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4), 0 4px 8px rgba(0,0,0,0.4);
}

.mobile-menu-btn { display: none; background: none; border: none; cursor: pointer; color: var(--text-main); }
.mobile-menu-btn svg { width: 32px; height: 32px; }

.sidebar {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(15px);
    z-index: 200; display: flex; flex-direction: column; justify-content: center; align-items: center;
    opacity: 0; visibility: hidden; transform: scale(0.98);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.sidebar.active { opacity: 1; visibility: visible; transform: scale(1); }
.close-btn { position: absolute; top: 20px; right: 20px; background: none; border: none; cursor: pointer; color: var(--text-main); transition: transform 0.3s ease; }
html[dir="rtl"] .close-btn { right: auto; left: 20px; }
.close-btn:hover { transform: rotate(90deg); color: var(--primary-light); }
.close-btn svg { width: 32px; height: 32px; }

.sidebar-links { display: flex; flex-direction: column; align-items: center; gap: 24px; font-size: 22px; font-weight: 800; width: 100%; }

.main-content {
    padding: 48px 40px;
    max-width: 1100px;
    margin: 32px auto;
    border-radius: var(--radius);
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.hero { text-align: center; margin-bottom: 40px; }

h1 { font-size: 40px; margin-bottom: 12px; font-weight: 900; color: var(--text-main); text-shadow: 0 3px 6px rgba(0,0,0,0.4); }
h2 { font-size: 22px; margin: 32px 0 16px; font-weight: 700; color: var(--primary-light); display: flex; align-items: center; gap: 10px; text-shadow: 0 2px 4px rgba(0,0,0,0.3); }
h2::before { content: ""; display: block; width: 6px; height: 20px; background: var(--primary-light); border-radius: 4px; box-shadow: 0 0 8px rgba(229, 160, 36, 0.5); }

p { margin-bottom: 20px; color: var(--text-muted); font-size: 16px; }
strong { color: var(--text-main); font-weight: 700; }

.video-container { width: 100%; max-width: 320px; aspect-ratio: 9 / 16; margin: 24px auto; background: #000; border-radius: 12px; overflow: hidden; box-shadow: 0 8px 24px rgba(0,0,0,0.5); border: 3px solid rgba(255,255,255,0.1); }
iframe { width: 100%; height: 100%; border: none; }

.footer { 
    margin-top: auto;
    padding: 24px 0; 
    text-align: center; 
    color: var(--text-muted); 
    font-size: 14px; 
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--glass-border); 
}
html[dir="rtl"] .footer { direction: ltr; }

@media (min-width: 769px) { .mobile-menu-btn { display: none !important; } }
@media (max-width: 768px) {
    .nav-links { display: none; }
    .mobile-menu-btn { display: flex !important; }
    .main-content { margin: 16px auto; padding: 32px 20px; }
    h1 { font-size: 28px; }
    h2 { font-size: 18px; margin: 24px 0 12px; }
    p { font-size: 15px; margin-bottom: 16px; }
    .logo { font-size: 20px; white-space: nowrap; }
    .header { padding: 14px 0; }
    .btn-premium { padding: 12px 24px; font-size: 14px; }
    .video-container { margin: 16px auto; }
}

.floating-404 { background: transparent !important; border: none !important; box-shadow: none !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
.floating-404 h1 { font-size: 140px; margin-bottom: 0; text-shadow: 0 6px 12px rgba(0,0,0,0.6); }
.floating-404 h2 { justify-content: center; font-size: 28px; color: #fff; margin-top: 0; border-bottom: none; }

@media (max-width: 768px) {
    .floating-404 h1 { font-size: 90px; }
    .floating-404 h2 { font-size: 22px; }
    .floating-404 p { font-size: 15px; margin-bottom: 24px; }
}
