/* Reset و فونت */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
@font-face {
  font-family: 'titr';
  src: url('fonts/B Titr Bold_0.ttf') format('ttf');
}
@font-face {
  font-family: 'iran';
  src: url('fonts/fa-Iran-sans-web-bold.woff2') format('woff2');
}
@font-face {
  font-family: 'vazir';
  src: url('fonts/Vazirmatn-Bold.woff2') format('woff2');
}
body {
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
    text-align: right; /* برای راست چین شدن محتوا */
}

/* هدر و نویگیشن */
header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    position: relative;
    top: 0;
    z-index: 100;
}

.header-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 1rem;
}

.site-logo {
    width: 100px;
    height: 100px;
    object-fit: contain;
    margin-left: 10px;
    transition: transform 0.3s ease;
}

.site-logo:hover {
    transform: rotate(15deg) scale(1.1);
}

.site-title {
        font-family: 'iran' !important;
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.site-title .highlight-text {
        font-family: 'titr' !important;
    color: #f1c40f;
    font-weight: 700;
    position: relative;
    display: inline-block;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    padding-bottom: 3px;
}

.site-title .highlight-text::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 2px;
    background: #f1c40f;
    transform-origin: left center;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.site-title .highlight-text:hover::after {
    transform: scaleX(0);
    transform-origin: right center;
}

.main-nav {
    width: 100%;
}

.nav-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
    padding: 0;
    margin: 0;
}

/* استایل آیتم‌های منو */
.nav-list li {
    position: relative;
    padding: 15px 20px;
    /* خط افقی زیر هر آیتم */
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    margin-bottom: -1px; /* برای اتصال خطوط */
}

/* حذف خط برای آیتم‌های سطر آخر */
.nav-list li.last-row {
    border-bottom: none;
}
.nav-list li a {
    font-family: 'iran' !important;
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: inline-block;
}

.nav-list li a:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* محتوای اصلی */
main {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}
.main-title {
    font-family: 'titr' !important;
    text-align: center;
    font-size: 2.2rem;
    color: #1e3c72;
    margin-bottom: 1.5rem;
    font-weight: 700;
    position: relative;
    padding-bottom: 1rem;
    display: inline-block;
    width: 100%;
}

.main-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    transform: translateX(50%) scaleX(0.3);
    width: 80%;
    height: 4px;
    background: linear-gradient(90deg, #1e3c72 0%, #2a5298 100%);
    border-radius: 4px;
    transition: all 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
    opacity: 0.8;
}

.main-title:hover::after {
    transform: translateX(50%) scaleX(1);
    opacity: 1;
    height: 5px;
}
@keyframes lineWave {
    0% { transform: translateX(50%) scaleX(1); }
    50% { transform: translateX(50%) scaleX(1.05); }
    100% { transform: translateX(50%) scaleX(1); }
}

.main-title:hover::after {
    animation: lineWave 0.8s ease 0.3s;
}

/* کارت ها */
.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.card-img {
    width: 100%;
    height: 200px;
    transition: transform 0.5s ease;
}

.card:hover .card-img {
    transform: scale(1.05);
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
}

.card-content h3 {
     font-family: 'titr' !important;
    margin-bottom: 0.5rem;
    color: #1e3c72;
    font-size: 1.6rem;
}

.card-content p {
    font-family: 'iran' !important;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.card-btn {
        font-family: 'vazir' !important;
    display: block;
    text-align: center;
    padding: 0.8rem;
    background: linear-gradient(90deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.card-btn:hover {
    background: linear-gradient(90deg, #2a5298 0%, #1e3c72 100%);
    letter-spacing: 1px;
}

/* فوتر */
footer {
    background: #1e3c72;
    color: white;
    text-align: center;
    padding: 1.5rem;
    margin-top: 3rem;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #f1c40f, #e67e22);
}
/* بخش اخبار بهبود یافته */
.news-section {
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8eb 100%);
    padding: 2.5rem 1rem;
    margin: 4rem 0;
    overflow: hidden;
    position: relative;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.news-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #1e3c72 0%, #2a5298 100%);
}

.news-title {
    font-family: 'titr' !important;
    text-align: center;
    font-size: 2.2rem;
    color: #1e3c72;
    margin-bottom: 1.5rem;
    font-weight: 700;
    position: relative;
    padding-bottom: 1rem;
    display: inline-block;
    width: 100%;
}

.news-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    transform: translateX(50%) scaleX(0.3);
    width: 80%;
    height: 4px;
    background: linear-gradient(90deg, #1e3c72 0%, #2a5298 100%);
    border-radius: 4px;
    transition: all 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
    opacity: 0.8;
}

.news-title:hover::after {
    transform: translateX(50%) scaleX(1);
    opacity: 1;
    height: 5px;
}

.news-container {
    position: relative;
    padding: 1rem 0;
}

.news-item {
    flex: 0 0 auto;
    margin: 0 1.5rem;
    position: relative;
    transition: all 0.4s ease;
}

.news-item:hover {
    transform: scale(1.05);
}

.news-link {
    font-family: 'vazir' !important;
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    padding: 1rem 1.8rem;
    color: #333;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.news-link:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    color: #1e3c72;
}

.news-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #1e3c72 0%, #2a5298 100%);
    transition: width 0.3s ease;
}

.news-link:hover::after {
    width: 100%;
    right: auto;
    left: 0;
}

/* نشانگر خبر ویژه */
.breaking-news {
    position: absolute;
    top: -10px;
    left: -10px;
    background: #e74c3c;
    color: white;
    font-size: 0.7rem;
    font-weight: bold;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    z-index: 2;
}

/* حذف keyframes قبلی و جایگزینی با این کد */
.news-scroll {
    display: flex;
    white-space: nowrap;
    padding: 1rem 0;
    animation: scrollLeft 20s linear infinite;
    min-width: 2000px; /* مقدار ثابت مناسب برای پروژه شما */
}

@keyframes scrollLeft {
    0% { transform: translateX(-70%); }
    100% { transform: translateX(100%); }
}

.news-scroll:hover {
    animation-play-state: paused;
}

/* دکمه‌های کنترل اخبار */
.news-controls {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    gap: 1rem;
}

.news-btn {
    background: rgba(30, 60, 114, 0.8);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.news-btn:hover {
    background: #1e3c72;
    transform: translateY(-2px);
}

/* رسپانسیو */
@media (max-width: 768px) {
    .news-section {
        padding: 2rem 0.5rem;
        margin: 3rem 0;
    }
    
    .news-title {
        font-size: 1.8rem;
    }
    
    .news-link {
        font-size: 0.95rem;
        padding: 0.8rem 1.2rem;
    }
    
    .news-item {
        margin: 0 1rem;
    }
}

@media (max-width: 480px) {
    .news-title {
        font-size: 1.5rem;
    }
    
    .news-link {
        font-size: 0.85rem;
        padding: 0.6rem 1rem;
    }
    
    .news-item {
        margin: 0 0.8rem;
    }
}
.copy
{
    font-family: 'vazir' !important;
}
@media (max-width: 768px) {
    .header-container {
        padding: 0 1rem;
    }
    
    .logo-container {
        flex-direction: column;
        text-align: center;
    }
    
    .site-logo {
        margin-left: 0;
        margin-bottom: 0.5rem;
    }
    
    .site-title {
        font-size: 1.3rem;
    }
    
    .highlight-text {
        margin-bottom: 5px;
        font-size: 1.5rem;
    }
    
    .highlight-text::after {
        bottom: -3px;
        height: 2px;
    }
    
    .nav-list {
        gap: 0.5rem;
    }
    
    .nav-list li a {
        font-size: 0.9rem;
        padding: 0.3rem 0.6rem;
    }
    
    .main-title {
        font-size: 1.8rem;
        padding-bottom: 0.8rem;
    }
    
    .main-title::after {
        height: 2px;
        transform: translateX(50%) scaleX(0.2);
    }
    
    .card-container {
        grid-template-columns: 1fr;
    }
}
}

@media (max-width: 480px) {
    .site-title {
        font-size: 1.1rem;
    }
    
    .highlight-text {
        font-size: 1.3rem;
    }
    
    .main-title {
        font-size: 1.5rem;
    }
}
}