/* General Styles */
@font-face {
    font-family: 'IranSans';
    src: url('../fonts/IRANSansWeb.eot');
    src: url('../fonts/IRANSansWeb.eot?#iefix') format('embedded-opentype'),
         url('../fonts/IRANSansWeb.woff2') format('woff2'),
         url('../fonts/IRANSansWeb.woff') format('woff'),
         url('../fonts/IRANSansWeb.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'IranSans';
    src: url('../fonts/IRANSansWeb_Bold.eot');
    src: url('../fonts/IRANSansWeb_Bold.eot?#iefix') format('embedded-opentype'),
         url('../fonts/IRANSansWeb_Bold.woff2') format('woff2'),
         url('../fonts/IRANSansWeb_Bold.woff') format('woff'),
         url('../fonts/IRANSansWeb_Bold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

body {
    font-family: 'IranSans', Tahoma, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f0f2f5;
    color: #333;
    direction: rtl;
    text-align: right;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

a {
    text-decoration: none;
    color: #007bff;
    transition: color 0.3s ease;
}

a:hover {
    color: #0056b3;
}

img {
    max-width: 100%;
    height: auto;
}

/* Header */
.header {
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    font-size: 14px;
    color: #666;
    border-bottom: 1px solid #f0f0f0;
}

.header-top .date-time {
    display: flex;
    align-items: center;
}

.header-top .date-time i {
    margin-left: 5px;
    color: #007bff;
}

.header-top .social-links a {
    color: #666;
    margin-left: 10px;
    font-size: 16px;
}

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

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

.logo a {
    display: flex;
    align-items: center;
    color: #333;
    font-size: 28px;
    font-weight: bold;
}

.logo img {
    height: 50px;
    margin-left: 10px;
}

.search-box {
    display: flex;
    border: 1px solid #ddd;
    border-radius: 25px;
    overflow: hidden;
    width: 300px;
}

.search-box input {
    border: none;
    padding: 10px 15px;
    flex-grow: 1;
    outline: none;
    font-size: 14px;
}

.search-box button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.search-box button:hover {
    background-color: #0056b3;
}

/* Navigation */
.navigation {
    background-color: #007bff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: flex-start;
}

.nav-menu li a {
    display: block;
    padding: 15px 20px;
    color: white;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    background-color: #0056b3;
}

/* Main Content Layout */


.main-content-area {
    display: grid;
    grid-template-columns: 1fr 300px; /* Main content and sidebar */
    gap: 30px;
    margin-top: 30px;
}

.content-area {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.sidebar {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.news-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

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

.news-card-content {
    padding: 15px;
}

.news-card-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.4;
}

.news-card-title a {
    color: #333;
}

.news-card-title a:hover {
    color: #007bff;
}

.news-card-summary {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

.news-card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: #999;
}

.news-card-meta i {
    margin-left: 5px;
    color: #007bff;
}

/* Featured News / Slider */
.featured-news {
    margin-bottom: 30px;
}

.featured-slider {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.slider-item {
    display: none;
    position: relative;
}

.slider-item.active {
    display: block;
}

.slider-item img {
    width: 100%;
    height: 450px;
    object-fit: cover;
}

.slider-caption {
    position: absolute;
    bottom: 0;
    right: 0;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 20px;
    width: 60%;
    max-width: 600px;
    border-top-right-radius: 8px;
}

.slider-caption h2 {
    margin-top: 0;
    font-size: 24px;
    line-height: 1.3;
}

.slider-caption h2 a {
    color: white;
}

.slider-caption p {
    font-size: 15px;
    color: #eee;
}

.slider-nav-dots {
    text-align: center;
    margin-top: 15px;
}

.dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    background-color: #bbb;
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dot.active {
    background-color: #007bff;
}

/* Breaking News */
.breaking-news-bar {
    background-color: #dc3545;
    color: white;
    padding: 10px 0;
    margin-bottom: 20px;
    font-size: 15px;
    font-weight: bold;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.breaking-news-bar .label {
    background-color: #c82333;
    padding: 8px 15px;
    margin-left: 20px;
    flex-shrink: 0;
}

.breaking-news-bar .news-ticker {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    position: relative;
    height: 20px;
}

.breaking-news-bar .news-ticker span {
    position: absolute;
    animation: ticker 20s linear infinite;
}

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

/* Sidebar Widgets */
.sidebar-widget {
    margin-bottom: 30px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.widget-header {
    background-color: #007bff;
    color: white;
    padding: 12px 15px;
    font-size: 16px;
    font-weight: bold;
    display: flex;
    align-items: center;
}

.widget-header i {
    margin-left: 10px;
}

.widget-content {
    padding: 15px;
}

.latest-news-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px dashed #eee;
}

.latest-news-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.latest-news-item img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 5px;
    margin-left: 10px;
    flex-shrink: 0;
}

.latest-news-content {
    flex-grow: 1;
}

.latest-news-title {
    font-size: 15px;
    font-weight: bold;
    margin-top: 0;
    margin-bottom: 5px;
    line-height: 1.4;
}

.latest-news-title a {
    color: #333;
}

.latest-news-title a:hover {
    color: #007bff;
}

.latest-news-date {
    font-size: 12px;
    color: #999;
}

.categories-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.categories-list li {
    border-bottom: 1px solid #eee;
}

.categories-list li:last-child {
    border-bottom: none;
}

.categories-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    text-decoration: none;
    color: #333;
    transition: color 0.3s;
}

.categories-list a:hover {
    color: #007bff;
}

.categories-list li a span {
    font-size: 15px;
}

/* Footer */
.footer {
    background-color: #333;
    color: white;
    padding: 30px 0;
    margin-top: 50px;
    font-size: 14px;
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #444;
}

.footer-widget h3 {
    color: #007bff;
    font-size: 18px;
    margin-bottom: 20px;
}

.footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-widget ul li a {
    color: #ccc;
    padding: 5px 0;
    display: block;
}

.footer-widget ul li a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    font-size: 13px;
    color: #ccc;
}

/* Responsive Design */
@media (max-width: 992px) {
    .main-content-area {
        grid-template-columns: 1fr; /* Stack content and sidebar */
    }
    .sidebar {
        margin-top: 30px;
    }
    .header-main {
        flex-direction: column;
        align-items: flex-start;
    }
    .search-box {
        width: 100%;
        margin-top: 15px;
    }
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    .nav-menu li a {
        padding: 12px 15px;
    }
    .slider-item img {
        height: 300px;
    }
    .slider-caption {
        width: 100%;
        padding: 15px;
        border-top-right-radius: 0;
    }
    .slider-caption h2 {
        font-size: 20px;
    }
    .slider-caption p {
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .header-top {
        flex-direction: column;
        align-items: flex-start;
    }
    .header-top .social-links {
        margin-top: 10px;
    }
    .news-grid {
        grid-template-columns: 1fr;
    }
    .footer-widgets {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .logo a {
        font-size: 24px;
    }
    .logo img {
        height: 40px;
    }
    .search-box {
        border-radius: 5px;
    }
    .breaking-news-bar .label {
        padding: 5px 10px;
        font-size: 13px;
    }
    .breaking-news-bar .news-ticker span {
        font-size: 14px;
    }
    .slider-item img {
        height: 200px;
    }
    .slider-caption h2 {
        font-size: 18px;
    }
    .slider-caption p {
        display: none;
    }
}
