/* style.css */
:root {
    --navy: #002b5c;
    --gold: #FF9933;
    --light-bg: #f8f9fa;
}

body {
    font-family: 'Cairo', sans-serif;
}

.bg-navy { background-color: var(--navy); }
.bg-gold { background-color: var(--gold); }
.text-navy { color: #4c4c4c; }
.text-gold { color: var(--gold); }

.navbar {
    padding: 10px 0;
}

.nav-link {
    color: var(--navy) !important;
    font-weight: 1100;
    font-size: 0.915rem;
}

.nav-link:hover, .nav-link.active {
    color: #FF9933 !important;
}

.hero-bg {
    height: 450px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
}

.btn-navy {
    background-color: #FF9933;
    color: white;
}

.btn-navy:hover {
    background-color: #001a38;
    color: white;
}

.stat-item {
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.sector-card {
    text-align: center;
    padding: 20px;
    transition: 0.3s;
}

.sector-card:hover {
    transform: translateY(-5px);
}

.btn-outline-navy {
    border: 2px solid var(--navy);
    color: var(--navy);
    font-weight: bold;
    border-radius: -1px;
}

.btn-outline-navy:hover {
    background: var(--navy);
    color: white;
}

/* News & Events Custom Styles */
.news-card-home {
    transition: 0.3s;
    background: white;
text-align: justify;
}
.news-card-home:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,43,92,0.15) !important;
}

.event-item {
    transition: 0.3s;
}
.event-item:hover {
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
    border-color: var(--gold) !important;
}

.event-date-box {
    min-width: 100px;
    border-left: 4px solid var(--gold);
}

.bg-navy { background-color: var(--navy) !important; }
.text-navy { color: var(--navy); }
.text-gold { color: var(--gold); }
.btn-outline-navy {
    border: 2px solid var(--navy);
    color: var(--navy);
    font-weight: bold;
}
.btn-outline-navy:hover {
    background: var(--navy);
    color: white;
}




/* AI Chatbot Styles */
#ai-chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px; /* للنسخة العربية */
    z-index: 9999;
}

#chat-toggle-btn {
    width: 65px;
    height: 65px;
    background: var(--navy);
    color: white;
    border: 4px solid var(--gold);
    border-radius: 50%;
    font-size: 28px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    cursor: pointer;
    transition: 0.3s;
    position: relative;
}

#chat-toggle-btn:hover { transform: scale(1.1); }

.chat-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--gold);
    color: var(--navy);
    font-size: 10px;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 10px;
}

#chat-window {
    width: 360px;
    height: 500px;
    background: white;
    border-radius: 20px;
    display: none; /* مخفي افتراضياً */
    flex-direction: column;
    overflow: hidden;
    position: absolute;
    bottom: 80px;
    right: 0;
    animation: slideUp 0.4s ease;
}

@keyframes slideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.chat-header {
    background: var(--navy);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bot-avatar {
    width: 35px;
    height: 35px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #f9f9fb;
}

.msg {
    padding: 10px 15px;
    border-radius: 15px;
    margin-bottom: 10px;
    max-width: 85%;
    font-size: 14px;
    line-height: 1.5;
}

.bot-msg {
    background: white;
    color: #333;
    border-bottom-right-radius: 2px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.user-msg {
    background: var(--navy);
    color: white;
    margin-left: auto;
    border-bottom-left-radius: 2px;
}

.chat-footer {
    padding: 15px;
    background: white;
    border-top: 1px solid #eee;
}




/* Video Hero Style */
.hero-video-container {
    position: relative;
    height: 550px; /* يمكنك زيادة الارتفاع لـ 100vh لملء الشاشة بالكامل */
    width: 100%;
    overflow: hidden;
    background: #000; /* خلفية سوداء تظهر قبل تحميل الفيديو */
}

.bg-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: 0;
    transform: translate(-50%, -50%);
    object-fit: cover; /* لضمان عدم تمدد الفيديو */
}

.hero-video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: linear-gradient(rgba(0, 43, 92, 0.6), rgba(0, 43, 92, 0.4)); /* طبقة زرقاء شفافة */
    z-index: 1;
    color: white;
}

/* انيميشن بسيط لظهور النص */
.content-fade-up {
    animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* تنسيق إضافي للأزرار لتظهر بوضوح فوق الفيديو */
.btn-warning {
    background-color: #C5A059 !important;
    border: none;
    color: var(--navy) !important;
}

.btn-warning:hover {
    background-color: #b38d4a !important;
    transform: translateY(-3px);
}




/* تنسيق نماذج المناطق اللوجستية */
.model-card {
    border: none !important;
    border-radius: 20px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.4s ease;
    background: #fff;
    overflow: hidden;
    border-top: 5px solid transparent !important;
}

.model-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 43, 92, 0.1);
    border-top-color: var(--gold) !important;
}

.model-icon {
    width: 80px;
    height: 80px;
    background: rgba(0, 43, 92, 0.05);
    color: var(--navy);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin: 30px auto 10px;
    transition: 0.3s;
}

.model-card:hover .model-icon {
    background: var(--navy);
    color: #fff;
}

.model-footer {
    background: #f8f9fa;
    padding: 12px;
    text-align: center;
    border-top: 1px solid #eee;
    color: var(--gold);
    font-weight: bold;
}

/* حركة الأنيميشن عند التمرير */
.model-card {
    animation: fadeInUp 0.6s ease both;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}


/* تنسيق زر الموبايل ليكون واضحاً */
.navbar-toggler {
    padding: 8px;
    background-color: var(--light-bg);
}

.navbar-toggler-icon {
    filter: invert(12%) sepia(45%) saturate(3062%) hue-rotate(196deg) brightness(91%) contrast(101%);
    /* هذا الفلتر يجعل لون أيقونة الموبايل "كحلي" نفس لون الجهاز */
}

/* تباعد الروابط في الموبايل */
@media (max-width: 991px) {
    .navbar-collapse {
        background: white;
        padding-bottom: 20px;
        border-top: 1px solid #eee;
    }
    .nav-link {
        padding: 12px 0 !important;
        border-bottom: 1px solid #f9f9f9;
    }
}


/* تنسيق إضافي للـ Pop-up */
#announcementModal .modal-content {
    animation: zoomIn 0.4s ease-out;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.bg-navy { background-color: #002b5c !important; }
.text-gold { color: #FF9933 !important; }



/* Accessibility Widget Styles */
#accessibility-widget {
    position: fixed;
    top: 50%;
    right: 0; /* للظهور على الجانب الأيمن */
    transform: translateY(-50%);
    z-index: 10000;
}

#access-btn {
    background: #002b5c;
    color: white;
    border: none;
    border-radius: 10px 0 0 10px;
    padding: 15px;
    font-size: 24px;
    cursor: pointer;
    box-shadow: -2px 0 10px rgba(0,0,0,0.2);
    transition: 0.3s;
}

#access-btn:hover { background: #C5A059; }

#access-menu {
    position: absolute;
    top: 0;
    right: -250px; /* مخفي افتراضياً */
    width: 220px;
    background: white;
    border-radius: 15px 0 0 15px;
    overflow: hidden;
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid #ddd;
}

#access-menu.active {
    right: 65px; /* يظهر بجانب الزر */
}

.access-header {
    background: #002b5c;
    color: white;
    padding: 12px;
    text-align: center;
    font-weight: bold;
    font-size: 14px;
}

.access-body {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.access-body button {
    background: #f8f9fa;
    border: 1px solid #eee;
    padding: 10px;
    text-align: right;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    border-radius: 8px;
    transition: 0.2s;
}

.access-body button:hover {
    background: #eef4f9;
    color: #002b5c;
    border-color: #C5A059;
}

.access-body button i { margin-left: 10px; color: #C5A059; }

/* Classes for Accessibility Logic */
body.grayscale { filter: grayscale(100%) !important; }

body.dark-mode-active {
    background-color: #121212 !important;
    color: #e0e0e0 !important;
}

body.dark-mode-active .navbar, 
body.dark-mode-active .card, 
body.dark-mode-active footer {
    background-color: #1e1e1e !important;
    color: white !important;
    border-color: #333 !important;
}

body.dark-mode-active .text-navy, 
body.dark-mode-active .nav-link {
    color: #C5A059 !important;
}



:root {
    --glass-bg: rgba(255, 255, 255, 0.7);
    --primary-gradient: linear-gradient(135deg, #002b5c 0%, #004a99 100%);
    --gold-gradient: linear-gradient(135deg, #C5A059 0%, #f1d392 100%);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    --border-radius: 24px;
}

body {
    background: radial-gradient(circle at top right, #eef2f7 0%, #f4f7fa 100%);
    min-height: 100vh;
}

/* Sidebar العصري */
.modern-sidebar {
    width: 100px;
    height: calc(100vh - 40px);
    background: var(--navy);
    position: fixed;
    right: 20px;
    top: 20px;
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 30px 0;
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

.modern-sidebar:hover { width: 260px; }

.nav-item-modern {
    width: 80%;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    margin-bottom: 15px;
    border-radius: 16px;
    transition: 0.3s;
    overflow: hidden;
}

.nav-item-modern i { font-size: 20px; min-width: 50px; text-align: center; }
.nav-item-modern span { opacity: 0; white-space: nowrap; transition: 0.3s; font-weight: 600; }
.modern-sidebar:hover .nav-item-modern span { opacity: 1; margin-right: 10px; }

.nav-item-modern.active, .nav-item-modern:hover {
    background: var(--gold-gradient);
    color: var(--navy) !important;
}

/* المحتوى */
.main-content-modern {
    margin-right: 140px;
    padding: 40px 40px 40px 20px;
    transition: 0.4s;
}

.modern-sidebar:hover + .main-content-modern { margin-right: 300px; }

/* كروت الإحصائيات الزجاجية */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.4);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--card-shadow);
    transition: 0.3s;
}

.glass-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.06); }

/* الأيقونات المتدرجة */
.icon-gradient {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    background: var(--primary-gradient);
    color: white;
    margin-bottom: 20px;
}

/* حالة السجل (Badge) */
.status-glow {
    padding: 6px 16px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 0 15px rgba(40, 167, 69, 0.2);
}
/* تنسيق رؤوس الصفحات الموحد */
.page-banner {
    background: linear-gradient(135deg, var(--navy) 0%, #004080 100%);
    padding: 60px 0;
    color: white;
    border-bottom: 5px solid var(--gold);
    text-align: center;
}
.page-banner h1 { font-weight: 900; }

/* تنسيق زر اللغة */
.btn-outline-secondary {
    border: 2px solid #eee;
    color: var(--navy);
    transition: 0.3s;
}

.btn-outline-secondary:hover {
    background-color: var(--gold);
    border-color: var(--gold);
    color: var(--navy);
}

/* تنسيق خاص للأجهزة المحمولة */
@media (max-width: 991px) {
    .d-flex.align-items-center {
        flex-direction: column;
        gap: 10px !important;
        margin-top: 15px;
    }
    .d-flex.align-items-center .btn {
        width: 100%;
    }
}
/* تعريف خط Cairo محلياً */
@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Regular.ttf') format('truetype');
    font-weight: 400;
}
@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Bold.ttf') format('truetype');
    font-weight: 700;
}

:root {
    --navy: #002b5c;
    --gold: #C5A059;
    --light-bg: #f8f9fa;
}


/* تنسيق حاوية شريط الأخبار */
.ticker-wrap {
    width: 100%;
    overflow: hidden;
    background-color: #C5A059; /* اللون الذهبي الخاص بك */
    padding: 10px 0;
    direction: ltr; /* لضمان حركة الانسياب من اليمين لليسار بشكل صحيح */
}

.ticker-container {
    display: flex;
    width: 100%;
}

.ticker-content {
    display: inline-block;
    white-space: nowrap;
    padding-right: 100%; /* لضمان خروج النص بالكامل قبل البدء مرة أخرى */
    animation: ticker-animation 100s linear infinite; /* سرعة الحركة */
}

/* حركة الشريط */
@keyframes ticker-animation {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* تنسيق الروابط داخل الشريط */
.ticker-item {
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    padding: 0 20px;
    display: inline-block;
    direction: rtl; /* العودة للغة العربية داخل الروابط */
}

.ticker-item:hover {
    color: var(--navy); /* يتغير اللون عند تمرير الماوس */
    text-decoration: underline;
}

.ticker-separator {
    color: rgba(255,255,255,0.6);
    font-weight: bold;
}

/* إيقاف الحركة عند تمرير الماوس للقراءة */
.ticker-wrap:hover .ticker-content {
    animation-play-state: paused;

