/**
 * ====================================================================
 * MAIN.CSS - ملف التنسيقات الرئيسي لشبكة إيجاز الإخبارية
 * ====================================================================
 * يشمل: Header, Footer, Navigation, Typography, Utilities, Animations
 * متوافق مع: Bootstrap 5.3.7 RTL
 * الاتجاه: RTL (من اليمين لليسار)
 * @version 3.0
 * @author Riyadh Ali
 * ====================================================================
 */

/* ====================================================================
   1. CSS VARIABLES - متغيرات الألوان والمسافات
   ==================================================================== */
:root {
    /* الألوان الأساسية */
    --primary-blue: #1e40af;
    --secondary-blue: #2563eb;
    --accent-red: #dc2626;
    --accent-red-light: #ef4444;
    --dark-blue: #1e3a8a;
    --light-bg: #f8fafc;
    --white: #ffffff;
    --dark-gray: #1f2937;
    --medium-gray: #6b7280;
    --light-gray: #e5e7eb;
    --border-color: #d1d5db;
    
    /* ألوان إضافية للحالات */
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --info-color: #3b82f6;
    --danger-color: #ef4444;
    
    /* المسافات والأبعاد */
    --header-height: 80px;
    --header-height-mobile: 70px;
    --container-max-width: 1400px;
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --border-radius-lg: 20px;
    --transition-speed: 0.3s;
    
    /* الظلال */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 15px 40px rgba(0, 0, 0, 0.15);
    
    /* الخطوط */
    --font-primary: 'Cairo', 'Tajawal', sans-serif;
    --font-size-base: 16px;
    --line-height-base: 1.8;
}
.cairo-<uniquifier> {
  font-family: "Cairo", sans-serif;
  font-optical-sizing: auto;
  font-weight: <weight>;
  font-style: normal;
  font-variation-settings:
    "slnt" 0;
}
/* ====================================================================
   2. RESET & BASE STYLES - إعادة تعيين وأنماط أساسية
   ==================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: var(--font-size-base);
    scroll-behavior: smooth;
}
.logo-image {
    max-height: 70px;
    width: auto;
}
body {
    font-family: var(--font-primary);
    background: var(--light-bg);
    color: var(--dark-gray);
    line-height: var(--line-height-base);
    font-size: var(--font-size-base);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* إزالة التنسيقات الافتراضية للروابط */
a {
    color: inherit;
    text-decoration: none;
    transition: all var(--transition-speed) ease;
}

a:hover {
    color: var(--primary-blue);
}

/* الصور */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* القوائم */
ul, ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* الأزرار */
button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    transition: all var(--transition-speed) ease;
}

/* الحقول */
input, textarea, select {
    font-family: inherit;
    font-size: inherit;
}

/* ====================================================================
   3. TYPOGRAPHY - أنماط الخطوط والنصوص
   ==================================================================== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--dark-gray);
    margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
    line-height: var(--line-height-base);
}

/* النصوص القوية */
strong, b {
    font-weight: 700;
}

/* النصوص المائلة */
em, i {
    font-style: italic;
}

/* الاقتباسات */
blockquote {
    padding: 1.5rem;
    background: var(--light-bg);
    border-right: 4px solid var(--primary-blue);
    margin: 1.5rem 0;
    font-style: italic;
    color: var(--medium-gray);
}

/* الكود */
code {
    padding: 0.2rem 0.5rem;
    background: var(--light-gray);
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

pre {
    padding: 1rem;
    background: var(--dark-gray);
    color: var(--white);
    border-radius: var(--border-radius);
    overflow-x: auto;
    margin: 1rem 0;
}

pre code {
    background: none;
    padding: 0;
    color: inherit;
}

/* ====================================================================
   4. BREAKING NEWS BAR - شريط الأخبار العاجلة
   ==================================================================== */
.breaking-news {
    background: linear-gradient(90deg, var(--accent-red), var(--accent-red-light));
    color: white;
    padding: 12px 0;
    font-size: 15px;
    position: relative;
    overflow: hidden;
    z-index: 1001;
}

.breaking-news .badge {
    background: white;
    color: var(--accent-red);
    font-weight: bold;
    padding: 6px 18px;
    margin-left: 15px;
    font-size: 14px;
    border-radius: 20px;
    display: inline-block;
    animation: pulse 2s ease-in-out infinite;
}

.breaking-news-content {
    display: inline-block;
    white-space: nowrap;
    animation: scrollText 30s linear infinite;
}

@keyframes scrollText {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* إيقاف الحركة عند التمرير */
.breaking-news:hover .breaking-news-content {
    animation-play-state: paused;
}

/* ====================================================================
   5. MAIN HEADER - الهيدر الرئيسي
   ==================================================================== */
.main-header {
    background: white;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all var(--transition-speed) ease;
}

/* تأثير التمرير */
.main-header.scrolled {
    box-shadow: var(--shadow-lg);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    gap: 20px;
}

/* ====================================================================
   6. LOGO - الشعار النصي
   ==================================================================== */
.logo-section {
    flex-shrink: 0;
}

.logo {
    font-size: 3.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -2px;
    line-height: 1;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    display: inline-block;
}

.logo:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Logo مع صورة (احتياطي) */
.logo-with-image {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-with-image img {
    height: 70px;
    width: auto;
}

.logo-with-image .logo-text {
    font-size: 2rem;
    font-weight: 900;
    color: var(--primary-blue);
}

/* ====================================================================
   7. NAVIGATION - القائمة الرئيسية
   ==================================================================== */
.main-nav-desktop {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-menu-desktop {
    display: flex;
    list-style: none;
    gap: 0;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.nav-menu-desktop > li {
    position: relative;
}

/* تحسين القائمة الرئيسية لتناسب شاشات متوسطة */
@media (min-width: 992px) and (max-width: 1200px) {
    .nav-menu-desktop {
        gap: 5px;
    }
    
    .nav-menu-desktop > li > a {
        padding: 10px 12px;
        font-size: 15px;
    }
}

/* القوائم الفرعية المحسنة */
.nav-menu-desktop > li.has-submenu {
    position: relative;
}

.nav-menu-desktop > li.has-submenu:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.nav-menu-desktop > li.has-submenu > a .fa-chevron-down {
    font-size: 12px;
    margin-right: 5px;
    transition: transform 0.3s ease;
}

.nav-menu-desktop > li.has-submenu:hover > a .fa-chevron-down {
    transform: rotate(180deg);
}

.sub-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    min-width: 220px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s ease;
    z-index: 1000;
    padding: 8px 0;
    margin-top: 5px;
    border: 1px solid var(--light-gray);
}

.sub-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 20px;
    width: 16px;
    height: 16px;
    background: white;
    transform: rotate(45deg);
    border-top: 1px solid var(--light-gray);
    border-left: 1px solid var(--light-gray);
}

.sub-menu li {
    border-bottom: 1px solid var(--light-gray);
}

.sub-menu li:last-child {
    border-bottom: none;
}

.sub-menu li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    color: var(--dark-gray);
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.sub-menu li a:hover {
    background: var(--light-bg);
    color: var(--primary-blue);
    padding-right: 25px;
}

/* القائمة المتنقلة مع القوائم الفرعية */
.nav-menu-mobile .has-submenu .sub-menu {
    display: none;
    background: var(--light-bg);
    padding: 10px 0;
    margin-top: 5px;
}

.nav-menu-mobile .has-submenu.open .sub-menu {
    display: block;
}

.nav-menu-mobile .sub-menu li a {
    padding: 12px 20px 12px 40px;
    font-size: 14px;
    color: var(--medium-gray);
}

.nav-menu-mobile .sub-menu li a:hover {
    background: rgba(30, 64, 175, 0.05);
    color: var(--primary-blue);
}

.nav-menu-mobile .has-submenu > a .submenu-toggle {
    margin-right: auto;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.nav-menu-mobile .has-submenu.open > a .submenu-toggle {
    transform: rotate(180deg);
}

/* تحسين التجاوب للشاشات الصغيرة */
@media (max-width: 991px) {
    .nav-menu-desktop {
        display: none;
    }
    
    .header-container {
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .logo-section {
        order: 1;
    }
    
    .header-actions {
        order: 2;
        margin-right: auto;
    }
    
    .main-nav-desktop {
        order: 3;
        flex-basis: 100%;
        margin-top: 15px;
    }
}

/* تحسين الشعار */
.logo-image {
    max-height: 70px;
    width: auto;
    transition: all 0.3s ease;
}

.logo-section:hover .logo-image {
    transform: scale(1.05);
}

/* تحسين أزرار البحث والقائمة */
.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-toggle,
.mobile-menu-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--light-bg);
    color: var(--dark-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.search-toggle:hover,
.mobile-menu-toggle:hover {
    background: var(--primary-blue);
    color: white;
    transform: scale(1.1);
}
/* الفواصل بين عناصر القائمة */
.nav-menu-desktop > li:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 20px;
    background: var(--light-gray);
}

.nav-menu-desktop > li > a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 12px;
    color: var(--dark-gray);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    border-radius: 25px;
    transition: all var(--transition-speed) ease;
    white-space: nowrap;
}

.nav-menu-desktop > li > a:hover,
.nav-menu-desktop > li > a.active {
    background: linear-gradient(135deg, var(--primary-blue), var(--secondary-blue));
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(30, 64, 175, 0.3);
}

/* ====================================================================
   8. SUB-MENU - القوائم الفرعية (Dropdown)
   ==================================================================== */
.nav-menu-desktop > li {
    position: relative;
}

/* القائمة الفرعية */
.sub-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    min-width: 220px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--transition-speed) ease;
    z-index: 1000;
    padding: 10px 0;
    margin-top: 10px;
}

/* عرض القائمة الفرعية عند التمرير */
.nav-menu-desktop > li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* عناصر القائمة الفرعية */
.sub-menu li {
    border-bottom: 1px solid var(--light-gray);
}

.sub-menu li:last-child {
    border-bottom: none;
}

.sub-menu li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    color: var(--dark-gray);
    font-size: 15px;
    font-weight: 500;
    transition: all var(--transition-speed) ease;
}

.sub-menu li a:hover {
    background: var(--light-bg);
    color: var(--primary-blue);
    padding-right: 25px;
}

.sub-menu li a i {
    font-size: 14px;
    color: var(--primary-blue);
}

/* مؤشر القائمة الفرعية */
.has-submenu > a::before {
    content: '\f107'; /* Font Awesome chevron-down */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    margin-right: 5px;
    font-size: 12px;
    transition: transform var(--transition-speed) ease;
}

.has-submenu:hover > a::before {
    transform: rotate(180deg);
}

/* قائمة فرعية متعددة المستويات */
.sub-menu .has-submenu {
    position: relative;
}

.sub-menu .has-submenu > a::after {
    content: '\f104'; /* Font Awesome chevron-left (RTL) */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    margin-right: auto;
    font-size: 12px;
}

.sub-menu .sub-menu {
    top: 0;
    right: 100%;
    margin-top: 0;
    margin-right: 5px;
}

/* ====================================================================
   9. HEADER INFO & SOCIAL - معلومات الهيدر وأيقونات التواصل
   ==================================================================== */
.header-info-section {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    flex-shrink: 0;
}

.header-info {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 14px;
    color: var(--medium-gray);
}

.header-info > div {
    display: flex;
    align-items: center;
    gap: 6px;
}

.header-info i {
    color: var(--primary-blue);
}

/* أيقونات التواصل الاجتماعي */
.social-header {
    display: flex;
    gap: 10px;
}

.social-header a {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-blue);
    transition: all var(--transition-speed) ease;
    text-decoration: none;
}

.social-header a:hover {
    background: var(--primary-blue);
    color: white;
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

/* ====================================================================
   10. MOBILE MENU - القائمة المتحركة للهواتف
   ==================================================================== */
.mobile-menu-toggle {
    display: none;
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: var(--border-radius-sm);
    font-size: 1.5rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.mobile-menu-toggle:hover {
    background: var(--secondary-blue);
    transform: scale(1.05);
}

/* تراكب الشاشة (Overlay) */
.mobile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity var(--transition-speed) ease;
}

.mobile-overlay.active {
    display: block;
    opacity: 1;
}

/* القائمة الجانبية للموبايل */
.main-nav-mobile {
    display: none;
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.1);
    z-index: 2000;
    transition: right var(--transition-speed) ease;
    overflow-y: auto;
}

.main-nav-mobile.active {
    right: 0;
}

/* رأس القائمة المتحركة */
.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 2px solid var(--light-gray);
    background: linear-gradient(135deg, #9196a400, #2563eb1a);
}

.mobile-menu-header .logo {
    font-size: 2rem;
    color: white;
    background: none;
    -webkit-text-fill-color: white;
}

.mobile-menu-close {
    background: var(--accent-red);
    color: white;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-speed) ease;
}

.mobile-menu-close:hover {
    background: var(--accent-red-light);
    transform: rotate(90deg);
}

/* عناصر القائمة المتحركة */
.nav-menu-mobile {
    list-style: none;
    padding: 20px 0;
}

.nav-menu-mobile > li {
    border-bottom: 1px solid var(--light-gray);
}

.nav-menu-mobile > li > a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    color: var(--dark-gray);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: all var(--transition-speed) ease;
}

.nav-menu-mobile > li > a:hover,
.nav-menu-mobile > li > a.active {
    background: var(--light-bg);
    color: var(--primary-blue);
    padding-right: 30px;
}

.nav-menu-mobile > li > a i {
    font-size: 18px;
}

/* قوائم فرعية في الموبايل */
.nav-menu-mobile .has-submenu > a::after {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    margin-right: auto;
    font-size: 14px;
    transition: transform var(--transition-speed) ease;
}

.nav-menu-mobile .has-submenu.open > a::after {
    transform: rotate(180deg);
}

.nav-menu-mobile .sub-menu {
    display: none;
    background: var(--light-bg);
    padding: 10px 0;
}

.nav-menu-mobile .has-submenu.open > .sub-menu {
    display: block;
}

.nav-menu-mobile .sub-menu li a {
    padding: 12px 20px 12px 70px;
    font-size: 15px;
    font-weight: 500;
}

/* ====================================================================
   11. FOOTER - الفوتر
   ==================================================================== */
.footer {
    background: linear-gradient(135deg, #1f2937, #111827);
    color: white;
    padding: 50px 0 20px;
    margin-top: 60px;
}

.footer-section {
    margin-bottom: 30px;
}

.footer-title {
    font-size: 1.4rem;
    font-weight: bold;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-red);
    display: inline-block;
	color: #fff;
}

/* روابط الفوتر */
.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all var(--transition-speed) ease;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
}

.footer-links a:hover {
    color: white;
    padding-right: 10px;
}

.footer-links a i {
    font-size: 14px;
    color: var(--primary-blue);
}

/* أيقونات التواصل في الفوتر */
.footer-social {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.footer-social a {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all var(--transition-speed) ease;
    text-decoration: none;
}

.footer-social a:hover {
    background: var(--accent-red);
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* أسفل الفوتر */
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 25px;
    margin-top: 40px;
    text-align: center;
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
}

/* ====================================================================
   12. UTILITY CLASSES - فئات مساعدة
   ==================================================================== */


/* النصوص */
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }

.fw-light { font-weight: 300 !important; }
.fw-normal { font-weight: 400 !important; }
.fw-semibold { font-weight: 600 !important; }
.fw-bold { font-weight: 700 !important; }
.fw-bolder { font-weight: 900 !important; }

.text-primary { color: var(--primary-blue) !important; }
.text-secondary { color: var(--secondary-blue) !important; }
.text-danger { color: var(--accent-red) !important; }
.text-success { color: var(--success-color) !important; }
.text-warning { color: var(--warning-color) !important; }
.text-muted { color: var(--medium-gray) !important; }

/* الخلفيات */
.bg-light { background-color: var(--light-bg) !important; }
.bg-white { background-color: var(--white) !important; }
.bg-primary { background-color: var(--primary-blue) !important; }
.bg-danger { background-color: var(--accent-red) !important; }

/* الحدود */
.rounded { border-radius: var(--border-radius) !important; }
.rounded-sm { border-radius: var(--border-radius-sm) !important; }
.rounded-lg { border-radius: var(--border-radius-lg) !important; }
.rounded-circle { border-radius: 50% !important; }

/* الظلال */
.shadow-sm { box-shadow: var(--shadow-sm) !important; }
.shadow { box-shadow: var(--shadow-md) !important; }
.shadow-lg { box-shadow: var(--shadow-lg) !important; }

/* العرض والارتفاع */
.w-100 { width: 100% !important; }
.h-100 { height: 100% !important; }

/* ====================================================================
   13. BUTTONS - الأزرار
   ==================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-weight: 600;
    font-size: 1rem;
    border-radius: 25px;
    transition: all var(--transition-speed) ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-blue), var(--secondary-blue));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(30, 64, 175, 0.3);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, var(--accent-red), var(--accent-red-light));
    color: white;
}

.btn-danger:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(220, 38, 38, 0.3);
    color: white;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-blue);
    color: var(--primary-blue);
}

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

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 1.1rem;
}

/* ====================================================================
   14. CARDS - البطاقات (احتياطي عام)
   ==================================================================== */
.card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-speed) ease;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-body {
    padding: 10px;
}
/*
.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--dark-gray);
}
*/
.card-text {
    font-size: 1rem;
    color: var(--medium-gray);
    line-height: 1.6;
}

.card-footer {
    padding: 15px 20px;
    background: var(--light-bg);
    border-top: 1px solid var(--light-gray);
    font-size: 0.9rem;
    color: var(--medium-gray);
}

/* ====================================================================
   15. BADGES & TAGS - الشارات والوسوم
   ==================================================================== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-primary {
    background: var(--primary-blue);
    color: white;
}

.badge-danger {
    background: var(--accent-red);
    color: white;
}

.badge-success {
    background: var(--success-color);
    color: white;
}

.badge-warning {
    background: var(--warning-color);
    color: white;
}

.badge-light {
    background: var(--light-gray);
    color: var(--dark-gray);
}

/* الوسوم (Tags) */
.tag {
    display: inline-block;
    padding: 5px 12px;
    background: var(--light-bg);
    color: var(--dark-gray);
    border-radius: 15px;
    font-size: 14px;
    margin: 3px;
    transition: all var(--transition-speed) ease;
}

.tag:hover {
    background: var(--primary-blue);
    color: white;
    transform: translateY(-2px);
}

/* ====================================================================
   16. FORMS - النماذج
   ==================================================================== */
.form-control {
    width: 100%;
    padding: 12px 16px;
    font-size: 1rem;
    border: 2px solid var(--light-gray);
    border-radius: var(--border-radius-sm);
    transition: all var(--transition-speed) ease;
    background: white;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark-gray);
}

.form-group {
    margin-bottom: 20px;
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* ====================================================================
   17. PAGINATION - الترقيم
   ==================================================================== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: white;
    border: 2px solid var(--light-gray);
    border-radius: var(--border-radius-sm);
    color: var(--dark-gray);
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-speed) ease;
}

.pagination a:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: white;
    transform: translateY(-2px);
}

.pagination .active {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: white;
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* ====================================================================
   18. ANIMATIONS - الحركات
   ==================================================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

.animate-in {
    animation: fadeInUp 0.6s ease-out;
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease-out;
}

/* ====================================================================
   19. LOADING & SPINNERS - التحميل
   ==================================================================== */
.spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid var(--light-gray);
    border-top-color: var(--primary-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* ====================================================================
   20. RESPONSIVE - التجاوب مع الشاشات
   ==================================================================== */

/* Tablets and below (992px) */
@media (max-width: 991px) {
    :root {
        --header-height: var(--header-height-mobile);
    }
	
	
 .footer .col-lg-4 {
    flex: 0 0 auto;
    width: 33.33333333%;
  }
    .main-nav-desktop {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .main-nav-mobile {
        display: block;
    }

    .header-container {
        gap: 20px;
        padding: 15px 0;
    }

    .logo {
        font-size: 2.5rem;
    }
    
    .header-info-section {
        display: none;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
    h4 { font-size: 1.25rem; }
}

/* Mobile (768px) */
@media (max-width: 768px) {
    .logo {
        font-size: 2rem;
    }
 .footer .col-lg-4 {
    flex: 0 auto;
    width: 50%;
  }

    .breaking-news {
        font-size: 14px;
        padding: 10px 0;
    }

    .breaking-news .badge {
        padding: 4px 12px;
        font-size: 12px;
        margin-left: 10px;
    }
}

/* Small Mobile (576px) */
@media (max-width: 576px) {
    :root {
        --font-size-base: 15px;
    }

    .logo {
        font-size: 1.75rem;
    }

    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
    h4 { font-size: 1.1rem; }

    .btn {
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    .footer {
        padding: 30px 0 15px;
    }

    .footer-section {
        margin-bottom: 25px;
    }
}

/* ====================================================================
   21. PRINT STYLES - أنماط الطباعة
   ==================================================================== */
@media print {
    .breaking-news,
    .main-header,
    .footer,
    .mobile-menu-toggle,
    .mobile-overlay,
    .main-nav-mobile,
    .social-header,
    .footer-social,
    .btn {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }

    a {
        color: black;
        text-decoration: underline;
    }
}

/* ====================================================================
   22. ACCESSIBILITY - إمكانية الوصول
   ==================================================================== */
/* Focus styles للوحة المفاتيح */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 3px solid var(--primary-blue);
    outline-offset: 2px;
}

/* تحسين تباين النصوص */
.high-contrast {
    filter: contrast(1.2);
}

/* تقليل الحركة للمستخدمين الذين يفضلون ذلك */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
/* Top Bar Styles */
.top-bar {
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    padding: 8px 0;
    font-size: 14px;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-info {
    display: flex;
    gap: 20px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #6c757d;
}

.top-bar-social {
    display: flex;
    gap: 15px;
}

.top-bar-social a {
    color: #6c757d;
    transition: color 0.3s;
}

.top-bar-social a:hover {
    color: #007bff;
}

/* Search Styles */
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.search-toggle {
    background: none;
    border: none;
    font-size: 18px;
    color: #333;
    cursor: pointer;
    padding: 5px;
}

.search-container {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: white;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
}

.search-container.active {
    display: block;
}

.search-input-group {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    border-right: none;
}

.search-button, .search-close {
    background: #007bff;
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
}

.search-close {
    background: #6c757d;
    margin-left: 5px;
    border-radius: 0 4px 4px 0;
}

/* Mobile Menu Updates */
.mobile-search-container {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.mobile-footer-info {
    padding: 15px;
    border-top: 1px solid #eee;
    margin-top: auto;
}

.mobile-date-time {
    margin-bottom: 10px;
}

.date-item {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 5px;
    color: #6c757d;
    font-size: 14px;
}

.mobile-social {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* Responsive */
@media (max-width: 768px) {
    .top-bar-content {
        flex-direction: column;
        gap: 10px;
    }
    
    .top-bar-info {
        justify-content: center;
    }
}
/* ====================================================================
   END OF MAIN.CSS
   ==================================================================== */
.p-3 {
  padding: 0rem !important;
}
.py-5 {
  padding-top: 1rem !important;
  padding-bottom: 1rem !important;
}