:root {
    --primary-color: #044D7B;   /* لونك الأزرق الداكن */
    --secondary-color: #1F95AD; /* لونك التيل */
    --accent-color: #59B167;    /* لونك الأخضر */
    --dark-text: #333;
    --light-gray: #f8f9fa;
}

body {
    font-family: 'Tajawal', sans-serif;
    color: var(--dark-text);
}

/* --- الهيكل الدقيق للهيدر --- */
.header-container {
    background-color: #fff;
    border-bottom: 1px solid #eee;
}
.top-header {
    padding: 1rem 0;
}
.top-header .contact-info, .top-header .top-actions {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
}
.top-header .contact-info a {
    color: var(--dark-text);
    text-decoration: none;
}
.top-header .contact-info i {
    color: var(--accent-color);
}
.top-header .logo-container {
    text-align: center;
}
.top-header .logo {
    max-height: 100px;
}

/* --- تصميم قائمة اللغة ووسائل التواصل --- */
.top-actions .social-icons a {
    color: var(--primary-color);
    margin: 0 8px;
    transition: color 0.3s;
}
.top-actions .social-icons a:hover {
    color: var(--secondary-color);
}
.lang-dropdown .dropdown-toggle {
    color: var(--dark-text);
    font-weight: 600;
    text-decoration: none;
}
.lang-dropdown .dropdown-menu {
    min-width: auto;
}
.lang-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
}
.lang-dropdown .fi {
    font-size: 1.2rem;
}

/* --- شريط التنقل المنفصل --- */
.navbar-custom-container {
    background-color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.navbar-custom .navbar-nav .nav-link {
    color: #fff;
    font-weight: 700;
    padding: 0.8rem 1.2rem;
    transition: background-color 0.3s;
    border-bottom: 4px solid transparent;
}
.navbar-custom .navbar-nav .nav-link:hover,
.navbar-custom .navbar-nav .nav-link.active {
    background-color: rgba(0,0,0,0.15);
    border-bottom-color: var(--secondary-color);
}

/* --- دعم القوائم المنسدلة --- */
.dropdown-menu {
    border-radius: 0.5rem;
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.15);
}
.dropdown-item {
    font-weight: 600;
    transition: background-color 0.2s, color 0.2s;
}
.dropdown-item:hover {
    background-color: var(--secondary-color);
    color: #fff;
}

/* تعديلات لدعم RTL/LTR */
html[dir="ltr"] .dropdown-toggle::after {
    margin-left: 0.3em;
}
html[dir="rtl"] .dropdown-toggle::after {
    margin-right: 0.3em;
}
html[dir="ltr"] .contact-info a:not(:last-child) {
    margin-right: 1rem;
}
html[dir="rtl"] .contact-info a:not(:last-child) {
    margin-left: 1rem;
}

/* --- بقية الأنماط --- */
.hero-slider { 
    height: 400px; 
    background: url('https://images.unsplash.com/photo-1518611507436-f13815835c47?q=80&w=2074&auto=format&fit=crop') no-repeat center center; 
    background-size: cover; 
    position: relative; 
    display: flex; 
    align-items: center; 
    color: #fff; 
}
.hero-slider::after { 
    content: ''; 
    position: absolute; 
    inset: 0; 
    background: linear-gradient(to top, rgba(4, 77, 123, 0.7), rgba(0,0,0,0.3)); 
}
.hero-slider .container { 
    position: relative; 
    z-index: 2; 
}
.hero-slider h1 { 
    font-size: 3.5rem; 
    font-weight: 700; 
    text-shadow: 2px 2px 8px rgba(0,0,0,0.6); 
}

.section-title { 
    font-weight: 700; 
    color: var(--primary-color); 
    margin-bottom: 40px; 
    text-align: center; 
    position: relative; 
    padding-bottom: 15px; 
}
.section-title::after { 
    content: ''; 
    position: absolute; 
    bottom: 0; 
    left: 50%; 
    transform: translateX(-50%); 
    width: 70px; 
    height: 4px; 
    background-color: var(--secondary-color); 
    border-radius: 2px; 
}

.news-section { 
    padding: 60px 0; 
    background-color: var(--light-gray); 
}

.main-news-card { 
    background-color: #fff; 
    border-radius: 10px; 
    overflow: hidden; 
    box-shadow: 0 5px 20px rgba(0,0,0,0.05); 
    height: 100%; 
    display: flex; 
    flex-direction: column; 
}
.main-news-card img { 
    width: 100%; 
    height: 300px; 
    object-fit: cover; 
}
.main-news-card .card-body { 
    padding: 1.5rem; 
    flex-grow: 1; 
    display: flex; 
    flex-direction: column; 
}
.main-news-card .card-title { 
    color: var(--primary-color); 
    font-weight: 700; 
    flex-grow: 1; 
}

.other-news-item { 
    display: flex; 
    align-items: center; 
    gap: 15px; 
    padding: 15px; 
    background-color: #fff; 
    border-radius: 8px; 
    margin-bottom: 15px; 
    transition: all 0.3s ease; 
    border: 1px solid #eee; 
}
.other-news-item:hover { 
    transform: translateY(-3px); 
    box-shadow: 0 4px 15px rgba(0,0,0,0.08); 
    border-color: var(--secondary-color); 
}
.other-news-item-media {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
}
.other-news-item-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 5px;
}
.other-news-item-title span {
    font-weight: 700;
    color: var(--dark-text);
    transition: color 0.3s ease;
}

.other-news-item-link:hover .other-news-item-title span {
    color: var(--primary-color);
}

/* Style for the video placeholder in the sidebar */
.video-icon-placeholder {
    width: 100%;
    height: 100%;
    background-color: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    font-size: 2rem;
    color: var(--primary-color);
    opacity: 0.7;
}

/* --- تحسين عرض حالة عدم وجود محتوى --- */
.no-content-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    border: 2px dashed #ddd;
}
.no-content-card .icon {
    font-size: 4rem;
    color: var(--secondary-color);
    margin-bottom: 1rem;
    opacity: 0.7;
}
.no-content-card h5 {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.no-content-card p {
    color: #666;
    margin: 0;
}

.services-section { 
    padding: 60px 0; 
}
.service-card { 
    text-align: center; 
    padding: 30px 20px; 
    border-radius: 10px; 
    background-color: #fff; 
    box-shadow: 0 5px 20px rgba(0,0,0,0.05); 
    transition: all 0.3s ease; 
    height: 100%; 
}
.service-card:hover { 
    transform: translateY(-10px); 
    box-shadow: 0 10px 25px rgba(0,0,0,0.1); 
}
.service-card .icon { 
    font-size: 3rem; 
    color: var(--secondary-color); 
    margin-bottom: 20px; 
    transition: transform 0.3s; 
}
.service-card:hover .icon { 
    transform: scale(1.1); 
}
.service-card h5 { 
    font-weight: 700; 
    color: var(--primary-color); 
}

.stats-section { 
    padding: 60px 0; 
    background-color: var(--primary-color); 
    color: #fff; 
}
.stat-item { 
    text-align: center; 
}
.stat-item .icon { 
    font-size: 3rem; 
    margin-bottom: 15px; 
    opacity: 0.8; 
}
.stat-item .counter { 
    font-size: 2.5rem; 
    font-weight: 700; 
}
.stat-item p { 
    font-size: 1.1rem; 
    opacity: 0.9; 
}

.footer { 
    background-color: var(--dark-text); 
    color: #ccc; 
    padding: 50px 0 20px; 
}
.footer h5 { 
    color: #fff; 
    font-weight: 700; 
    margin-bottom: 20px; 
}
.footer .footer-links a { 
    color: #ccc; 
    text-decoration: none; 
    display: block; 
    margin-bottom: 10px; 
    transition: color 0.3s; 
}
.footer .footer-links a:hover { 
    color: var(--secondary-color); 
}
.footer .copyright { 
    border-top: 1px solid #444; 
    padding-top: 20px; 
    margin-top: 30px; 
    font-size: 0.9rem; 
}
.footer .social-icons-footer a { 
    color: #ccc; 
    margin-right: 15px; 
    font-size: 1.2rem; 
    transition: color 0.3s; 
}
.footer .social-icons-footer a:hover { 
    color: #fff; 
}

/* --- Appended News Detail Page Improvements --- */

/* Style for the article title to make it stand out */
.article-title {
    font-weight: 700; /* Ensure title is bold */
    color: var(--primary-color);
    margin-bottom: 1rem !important; /* Add some space below the title */
}

/* Improve readability of the article content */
.article-content {
    font-size: 1.15rem; /* Increase font size from default */
    line-height: 1.8;   /* Increase line spacing for easier reading */
    color: #444;       /* Slightly softer text color than pure black */
}

/* Add some spacing to paragraphs inside the article for better flow */
.article-content p {
    margin-bottom: 1.5rem;
}

/* Styling for the new sidebar */
.sidebar .widget {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    border: 1px solid #eee;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.sidebar .widget-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--secondary-color);
}

/* Helper class for the sidebar link wrapper */
.other-news-item-link {
    display: block; /* Make the anchor a block element */
    text-decoration: none;
    color: inherit;
}
.other-news-item-link:hover {
    color: inherit; /* Prevent text color change on hover */
}
