/* ملف الأنماط الرئيسي للموقع */

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #475569;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --info-color: #3b82f6;
    --light-color: #f8fafc;
    --dark-color: #1e293b;
    --text-dark: #334155;
    --text-light: #94a3b8;
    --border-color: #e2e8f0;
    --card-bg: #ffffff;
    --body-bg: #f1f5f9;
}

body {
    direction: rtl;
    font-family: 'Cairo', sans-serif;
    background-color: var(--body-bg);
    color: var(--text-dark);
}

/* تنسيقات القائمة العلوية */
.navbar {
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    background-color: var(--dark-color) !important;
    padding: 0.25rem 1rem;
    height: auto;
}

.navbar-brand {
    padding: 5px 0;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
}

.navbar-brand img {
    transition: all 0.3s ease;
    width: auto;
    height: 90px;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.nav-link {
    font-weight: 600;
    font-size: 1.1rem;
    position: relative;
    padding: 0.5rem 1rem;
    margin: 0 0.2rem;
    transition: all 0.3s ease;
    color: var(--light-color) !important;
}

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

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
}

.nav-link:hover::after, .nav-link.active::after {
    width: 80%;
    left: 10%;
}

/* تنسيقات المقالات */
.text-truncate-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hover-card {
    transition: all 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
}

.article-img {
    height: 200px;
    object-fit: cover;
}

/* تنسيقات مقال التفاصيل */
.article-container {
    background-color: #ffffff;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 40px;
}

.article-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1a2841;
}

.article-meta {
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eaeaea;
}

.article-excerpt {
    font-size: 1.2rem;
    line-height: 1.7;
    color: #555;
    margin-bottom: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.article-featured-image {
    margin-bottom: 25px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.article-content-main {
    background-color: #ffffff;
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 8px;
    border: 1px solid #eaeaea;
}

.article-content-text {
    font-size: 1.1rem;
    line-height: 1.9;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* تنسيقات الإشعارات */
.notification-icon {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    border-radius: 50%;
    font-size: 0.7rem;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-dropdown {
    min-width: 320px;
    max-height: 480px;
    overflow-y: auto;
}

.notification-item {
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.notification-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.notification-item.unread {
    border-left-color: var(--primary-color);
    background-color: rgba(37, 99, 235, 0.05);
}

.notification-item .notification-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.notification-item .notification-time {
    color: #6c757d;
    font-size: 0.8rem;
}

.notification-type-article {
    border-left-color: var(--success-color) !important;
}

.notification-type-poll {
    border-left-color: var(--info-color) !important;
}

.notification-type-comment {
    border-left-color: var(--warning-color) !important;
}

/* تنسيقات الرعاة */
.sponsors-section {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1) !important;
}

.sponsor-card {
    transition: all 0.3s ease;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background-color: #fff;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.sponsor-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.sponsor-card img {
    max-height: 80px;
    width: auto;
    transition: all 0.3s ease;
}

.sponsor-card:hover img {
    transform: scale(1.05);
}

.sponsors-title {
    font-weight: 600;
}

/* تنسيقات تطبيق PWA */
#pwa-install-prompt {
    background-color: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--primary-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

/* تنسيقات الشاشات المتوسطة والصغيرة */
@media (max-width: 991px) {
    .article-content-text {
        font-size: 1rem;
        line-height: 1.7;
    }
    
    .article-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 767px) {
    .article-content-text {
        font-size: 0.95rem;
    }
    
    .article-title {
        font-size: 1.5rem;
    }
    
    .sponsor-card {
        padding: 10px !important;
    }
    
    .sponsor-card img {
        max-height: 60px;
    }
    
    .sponsor-name {
        font-size: 0.7rem;
    }
    
    .sponsors-carousel .owl-nav {
        display: none;
    }
}