/* ===== إصلاح CLS من AOS ===== */
[data-aos] { pointer-events: none; }
[data-aos].aos-animate { pointer-events: auto; }
[data-aos^='fade'][data-aos^='fade'] { opacity: 0; transition-property: opacity, transform; }
[data-aos^='fade'][data-aos^='fade'].aos-animate { opacity: 1; transform: none; }

/* ============================================================
   index.css — الصفحة الرئيسية
   ============================================================ */

/* ═══ الحاوية — موحّدة مع index-main-css (1100px) ═══ */
.container {
    margin: 0 auto;
    padding: 0 20px;
}

/* ═══ Navbar ═══ */
.navbar {
    background: rgba(5, 10, 20, 0.96) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(245, 200, 66, 0.1);
    padding: 0.75rem 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1030;
    min-height: 70px;
    transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.navbar.scrolled {
    background: rgba(5, 10, 20, 0.99) !important;
    border-bottom-color: rgba(245, 200, 66, 0.22);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}
.navbar-brand {
    font-size: 1.4rem;
    font-weight: 700;
    background: linear-gradient(135deg, #f5c842, #00d4ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-right: auto;
}
.navbar-toggler {
    border: 1px solid rgba(245, 200, 66, 0.3);
    padding: 0.5rem;
    background: rgba(245, 200, 66, 0.07);
    border-radius: 10px;
    width: 45px; height: 45px;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s;
}
.navbar-toggler:hover { background: rgba(245, 200, 66, 0.14); }
.navbar-toggler:focus { box-shadow: 0 0 0 0.2rem rgba(245, 200, 66, 0.2); }

.navbar-collapse { background: transparent; border: none; border-radius: 0; box-shadow: none; margin-top: 0; }
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: rgba(5, 10, 20, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-radius: 16px;
        margin-top: 1rem;
        border: 1px solid rgba(245, 200, 66, 0.15);
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
        padding: 0.5rem;
    }
}
.nav-link {
    color: rgba(232, 224, 240, 0.8) !important;
    padding: 0.5rem 1rem !important;
    border-radius: 10px;
    transition: all 0.25s ease;
    font-weight: 500;
    display: flex; align-items: center;
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    width: 0; height: 2px;
    bottom: -4px; left: 50%;
    background: linear-gradient(90deg, #f5c842, #00d4ff);
    transition: width 0.3s ease, left 0.3s ease;
    transform: translateX(-50%);
    border-radius: 2px;
}
.nav-link:hover::after { width: 70%; }
.nav-link:hover, .nav-link:focus { background: rgba(245, 200, 66, 0.08); color: #f5c842 !important; }
@media (max-width: 991.98px) {
    .nav-link { padding: 0.75rem 1rem !important; margin-bottom: 0.25rem; min-height: 48px; justify-content: flex-end; }
    .nav-link::after { display: none; }
}

/* ═══ Dropdown ═══ */
.navbar .dropdown-menu {
    background: rgba(8, 6, 18, 0.97);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(245, 200, 66, 0.2);
    border-radius: 16px;
    padding: 10px; min-width: 240px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    margin-top: 12px;
    animation: dropIn 0.25s ease;
    /* إصلاح: تأكيد الـ position على الديسكتوب */
    position: absolute !important;
    top: 100% !important;
    right: 0 !important;
    left: auto !important;
    z-index: 9999 !important;
}

/* على الهاتف: اجعلها static لتندرج ضمن القائمة */
@media (max-width: 991.98px) {
    .navbar .dropdown-menu {
        position: static !important;
        top: auto !important;
        right: auto !important;
        box-shadow: none;
        border: 1px solid rgba(245, 200, 66, 0.1);
        margin-top: 4px;
        margin-bottom: 4px;
        background: rgba(5, 10, 20, 0.6);
        animation: none;
    }
}
@keyframes dropIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.navbar .dropdown-item {
    color: rgba(232, 224, 240, 0.8);
    border-radius: 10px;
    padding: 10px 14px;
    transition: all 0.2s ease;
    font-weight: 500;
}
.navbar .dropdown-item:hover { background: rgba(245, 200, 66, 0.1); color: #f5c842; transform: translateX(-3px); }

/* ═══ Feature cards (FAQ / About) ═══ */
.feature-card {
    background: rgba(14, 11, 26, 0.72);
    border: 1px solid rgba(245, 200, 66, 0.12);
    border-radius: 18px;
    padding: 1.75rem;
    color: #e8e0f0;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}
.feature-card:hover {
    transform: translateY(-4px);
    border-color: rgba(245, 200, 66, 0.32);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}
.feature-card h5 { font-size: 15px; font-weight: 700; margin-bottom: 10px; color: #f5c842; }
.feature-icon {
    width: 54px; height: 54px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.2rem;
    color: #050a14;
    background: linear-gradient(135deg, #f5c842, #e8a820);
    box-shadow: 0 4px 16px rgba(245, 200, 66, 0.25);
}
.feature-icon .fas, .feature-icon .fab, .feature-icon .far,
.feature-icon [class*="fa-"] { color: #050a14 !important; }

/* ═══ زر .btn ═══ */
.btn {
    border-radius: 12px; font-weight: 600;
    transition: all 0.25s ease;
    min-height: 48px;
    display: inline-flex; align-items: center; justify-content: center;
    text-decoration: none;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    font-size: 0.95rem;
    font-family: 'Almarai', 'Cairo', 'Tajawal', sans-serif;
}

/* ═══ Canvas خلفية ═══ */
#nattrade-bg-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

/* ═══ Responsive ═══ */
@media (max-width: 768px) {
    .feature-card { margin-bottom: 1.5rem; padding: 1.5rem 1.25rem; }
    .feature-icon { width: 46px; height: 46px; }
}
@media (max-width: 576px) {
    .feature-card { padding: 1.25rem 1rem; }
    .container { padding: 0 16px; }
}
@media (min-width: 768px) {
    .navbar-collapse { background: transparent; border: none; border-radius: 0; padding: 0; margin-top: 0; box-shadow: none; }
    .navbar-nav { padding: 0; flex-direction: row; }
    .nav-link { margin-bottom: 0; margin-left: 0.5rem; }
}
@media print {
    .navbar, .btn { display: none !important; }
    .container { max-width: 100% !important; padding: 0 !important; }
}