/* استایل‌های پایه */
html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
    overflow-x: hidden;
}

@font-face {
    font-family: 'iranSans';
    src: url("./iran_sans.woff");
}

@font-face {
    font-family: 'Far_TV.ttf';
    src: url("./Far_TV.ttf");
}

* {
    direction: rtl;
    box-sizing: border-box;
}

/* هدر اصلی - واکنش‌گرا */
.header-section {
    font-family: 'iranSans';
    display: flex;
    align-items: center;
    padding: 10px 5%;
    flex-wrap: wrap;
    justify-content: center;
}

.logo {
    width: 80px;
    height: 80px;
    margin: 0 auto;
}

.nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    margin-top: 15px;
}

.nav-links a {
    padding: 5px 15px;
    margin: 5px;
    font-size: 16px;
    text-decoration: none;
    color: #000;
    font-weight: bold;
}

/* بخش هیرو - واکنش‌گرا */
.header-two-section {
    font-family: 'Far_TV.ttf';
    position: relative;
    width: 100%;
    height: auto;
    min-height: 250px;
    overflow: hidden;
}

.header-two-section video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 1;
}

.header-two-section .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.header-two-section .content {
    position: relative;
    z-index: 3;
    color: white;
    text-align: center;
    padding: 100px 20px;
    font-size: 1.5em;
}

/* بخش مقالات - واکنش‌گرا */
.section-1, .section-2 {
    font-family: 'iranSans';
    padding: 20px 5%;
    height: auto;
}

.titr {
    font-family: 'Far_TV.ttf';
    display: inline-block;
    box-shadow: 0 -10px 0 0 #f0f0f0 inset;
    padding-bottom: 2px;
    width: 100%;
    max-width: 350px;
    font-size: 22px;
    text-align: center;
    margin-bottom: 20px;
}

.articles-container, .articles-container2 {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background-size: cover;
    background-position: center;
    height: auto;
    padding: 30px 5%;
}

.article, .article2 {
    background-color: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: center;
    width: 100%;
}

.article img, .article2 img {
    width: 100%;
    height: auto;
    max-height: 200px;
    object-fit: cover;
}

/* اسلایدر ویدیو - واکنش‌گرا */
.slider-container {
    position: relative;
    font-family: 'iranSans';
    width: 90%;
    max-width: 100%;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.video-slider {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.video-slide {
    min-width: 100%;
    scroll-snap-align: start;
    position: relative;
}

.video-slide video {
    width: 100%;
    display: block;
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 10px;
    text-align: center;
    font-size: 14px;
}

/* فوتر - واکنش‌گرا */
.container_1 {
    background-color: gray; 
    color: white; 
    font-family: iransans; 
    font-size: 18px; 
    padding: 30px 5%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.grid-item {
    padding: 15px;
    width: 100%;
}

.grid-item p {
    text-align: justify;
    line-height: 1.6;
}

/* مدیا کوئری برای دستگاه‌های بزرگتر */
@media (min-width: 768px) {
    .header-section {
        justify-content: space-between;
        padding: 10px 10%;
    }
    
    .logo {
        margin: 0;
        width: 110px;
        height: 100px;
    }
    
    .nav-links {
        justify-content: flex-end;
        width: auto;
        margin-top: 0;
    }
    
    .nav-links a {
        padding: 0 25px;
        font-size: 18px;
    }
    
    .header-two-section {
        height: 400px;
    }
    
    .header-two-section .content {
        padding-top: 180px;
        font-size: 2em;
    }
    
    .articles-container, .articles-container2 {
        flex-direction: row;
        flex-wrap: wrap;
        height: auto;
    }
    
    .article, .article2 {
        flex: 1 1 45%;
        min-width: 300px;
    }
    
    .container_1 {
        flex-direction: row;
    }
    
    .grid-item {
        flex: 1;
    }
}

@media (min-width: 992px) {
    .article, .article2 {
        flex: 1 1 22%;
    }
    
    .header-section {
        padding: 10px 150px;
    }
}