/* ========================================
   RESET
======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --purple: #6c2bd9;
    --purple-main: #5b168f;
    --purple-dark: #4b1fa8;
    --black: #111111;
    --white: #ffffff;
    --gray: #f5f5f5;
    --border: #dddddd;
    --text-light: #777777;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #ffffff;
    color: #111111;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

.container {
    width: 92%;
    max-width: 1280px;
    margin: 0 auto;
}


/* ========================================
   HEADER
======================================== */

.site-header {
    width: 100%;
    background: var(--purple-main);
}


/*
   نکته اصلی:
   دیگر absolute نداریم.
   لوگو و لینک‌ها دو ردیف مستقل هستند.
*/

.header-main {
    width: 100%;
    background: var(--purple-main);
}


/* LOGO BANNER */

.header-logo {
    width: 100%;
    height: 170px;
    overflow: hidden;
    background: var(--purple-main);
}

.header-logo a {
    display: block;
    width: 100%;
    height: 100%;
}

.header-logo img {
    display: block;
    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center;
}


/* LANGUAGE + SOCIAL ROW */

.header-bottom {
    min-height: 60px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    color: #ffffff;
}

.language {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.language a {
    color: #ffffff;
    font-size: 13px;
    opacity: 0.8;
}

.language a.active {
    opacity: 1;
    font-weight: 700;
}

.language span {
    color: rgba(255, 255, 255, 0.75);
}

.social-links {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-shrink: 0;
}

.social-links a {
    color: #ffffff;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0.94;
    transition: opacity 0.2s;
}

.social-links a:hover {
    opacity: 0.65;
}


/* ========================================
   NAVIGATION
======================================== */

.main-nav {
    width: 100%;
    background: var(--purple-dark);
    border-top: 1px solid rgba(255,255,255,0.15);
}

.main-nav .nav-inner {
    min-height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 45px;

    overflow-x: auto;
    scrollbar-width: none;
}

.main-nav .nav-inner::-webkit-scrollbar {
    display: none;
}

.main-nav .nav-inner a {
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.main-nav .nav-inner a:hover {
    opacity: 0.7;
}


/* ========================================
   HERO
======================================== */

.hero-section {
    padding: 28px 0 50px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 25px;
}

.hero-main {
    display: block;
    color: inherit;
    position: relative;
}

.hero-image {
    height: 500px;

    background:
        linear-gradient(
            135deg,
            #2b155c,
            #111111
        );

    position: relative;
}

.image-label {
    position: absolute;
    top: 20px;
    left: 20px;

    background: var(--purple);
    color: #ffffff;

    padding: 7px 13px;

    font-size: 11px;
    font-weight: 700;
}

.hero-text {
    width: 90%;
    margin: -100px auto 0;

    position: relative;
    z-index: 2;

    background: #ffffff;
    padding: 28px;
}

.category {
    display: block;

    color: var(--purple);

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1px;

    margin-bottom: 8px;
}

.hero-text h1 {
    font-size: 40px;
    line-height: 1.15;
    margin-bottom: 12px;
}

.hero-text p {
    color: var(--text-light);
    font-size: 16px;
}


/* ========================================
   SIDE STORIES
======================================== */

.side-stories {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.story {
    border-bottom: 1px solid var(--border);
    padding-bottom: 20px;
}

.story-image {
    height: 220px;
    background: #dddddd;
    margin-bottom: 15px;
}

.story h2 {
    font-size: 22px;
    line-height: 1.25;
}


/* ========================================
   GENERAL SECTIONS
======================================== */

.section {
    padding: 60px 0;
}

.gray-section {
    background: var(--gray);
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    border-bottom: 2px solid var(--black);

    margin-bottom: 30px;
    padding-bottom: 12px;
}

.section-header h1,
.section-header h2 {
    font-size: 30px;
    line-height: 1.2;
}

.section-header a {
    color: var(--purple);
    font-size: 13px;
    font-weight: 700;
}


/* ========================================
   NEWS
======================================== */

.news-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px;
}

.news-card {
    display: block;
    border-bottom: 1px solid var(--border);
    padding-bottom: 20px;
}

.card-image {
    width: 100%;
    height: 230px;
    background: #dddddd;
    margin-bottom: 18px;
}

.article-card-image {
    display: block;
    width: 100%;
    height: 230px;
    object-fit: cover;
}

.card-content h3 {
    font-size: 22px;
    line-height: 1.3;
    margin-bottom: 10px;
}

.card-content p {
    color: var(--text-light);
    font-size: 14px;
}


/* ========================================
   FILM
======================================== */

.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px;
}

.large-image {
    width: 100%;
    height: 400px;
    background: #cccccc;
    margin-bottom: 15px;
}

.feature-card h2 {
    font-size: 28px;
    line-height: 1.2;
}


/* ========================================
   TV
======================================== */

.tv-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px;
}

.small-image {
    width: 100%;
    height: 220px;
    background: #dddddd;
    margin-bottom: 15px;
}

.tv-grid h3 {
    font-size: 21px;
    line-height: 1.3;
}


/* ========================================
   ARTICLE
======================================== */

.article-page {
    padding: 65px 0 80px;
}

.article-category {
    color: var(--purple);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1.5px;
    margin-bottom: 15px;
}

.article-title {
    max-width: 950px;
    font-size: 56px;
    line-height: 1.12;
    margin-bottom: 20px;
}

.article-excerpt {
    max-width: 800px;
    color: var(--text-light);
    font-size: 20px;
    line-height: 1.7;
    margin-bottom: 22px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;

    color: #777777;
    font-size: 13px;

    margin-bottom: 35px;
}

.article-hero {
    width: 100%;
    height: 600px;

    margin-bottom: 45px;

    background:
        linear-gradient(
            135deg,
            #2b155c,
            #111111
        );
}


/* ARTICLE IMAGE — SHOW COMPLETE IMAGE */

.article-main-image {
    display: block;
    width: 100%;
    height: auto;
    max-height: none;
    object-fit: contain;
    object-position: center center;
    margin-bottom: 45px;
}


.article-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 70px;

    max-width: 1100px;
}

.article-content {
    font-size: 18px;
    line-height: 2;
}

.article-content p {
    margin-bottom: 25px;
}

.article-content h2 {
    font-size: 32px;
    line-height: 1.3;
    margin: 45px 0 20px;
}

.article-sidebar {
    border-top: 3px solid var(--black);
    align-self: start;
}

.sidebar-title {
    font-size: 22px;
    font-weight: 800;

    padding: 15px 0;

    border-bottom: 1px solid var(--border);
}

.sidebar-story {
    display: block;

    padding: 18px 0;

    border-bottom: 1px solid var(--border);
}

.sidebar-story:hover {
    color: var(--purple);
}


/* ========================================
   FOOTER
======================================== */

footer {
    background: var(--black);
    color: #ffffff;

    padding: 60px 0;
    margin-top: 40px;
}

.footer-inner {
    text-align: center;
}

.footer-logo {
    font-size: 30px;
    font-weight: 900;
    margin-bottom: 15px;
}

.footer-logo span {
    color: var(--purple);
}

.footer-inner p {
    color: #aaaaaa;
    margin-bottom: 25px;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;

    gap: 25px;
    margin-bottom: 30px;
}

.footer-links a:hover {
    color: var(--purple);
}

.copyright {
    color: #666666;
    font-size: 12px;
}


/* ========================================
   PERSIAN / RTL
======================================== */

.rtl-page {
    direction: rtl;
}

.rtl-page .header-bottom {
    direction: ltr;
}

.rtl-page main {
    direction: rtl;
}

.rtl-page .section-header {
    direction: rtl;
}

.rtl-page .card-content,
.rtl-page .hero-text,
.rtl-page .story-content {
    text-align: right;
}

.rtl-page .image-label {
    left: auto;
    right: 20px;
}


/* ========================================
   TABLET
======================================== */

@media (max-width: 900px) {

    .header-logo {
        height: 140px;
    }

    .header-bottom {
        min-height: 50px;
    }

    .social-links {
        gap: 16px;
    }

    .social-links a {
        font-size: 12px;
    }

    .main-nav .nav-inner {
        justify-content: flex-start;
        gap: 28px;
        padding: 0 15px;
    }

    .hero-image {
        height: 430px;
    }

    .article-layout {
        gap: 40px;
    }
}


/* ========================================
   MOBILE
======================================== */

@media (max-width: 768px) {

    .container {
        width: 94%;
    }


    /* HEADER */

    .header-logo {
        height: 105px;
    }

    .header-bottom {
        min-height: 45px;
    }

    .language {
        gap: 8px;
    }

    .language a {
        font-size: 11px;
    }

    .social-links {
        gap: 9px;
    }

    .social-links a {
        font-size: 10px;
    }

    .main-nav .nav-inner {
        min-height: 45px;

        justify-content: flex-start;

        gap: 22px;

        padding: 0 18px;
    }

    .main-nav .nav-inner a {
        font-size: 11px;
    }


    /* HERO */

    .hero-grid {
        grid-template-columns: 1fr;
    }

    .hero-image {
        height: 350px;
    }

    .hero-text {
        width: 94%;
        margin-top: -70px;
        padding: 22px;
    }

    .hero-text h1 {
        font-size: 30px;
    }

    .hero-text p {
        font-size: 15px;
    }

    .side-stories {
        margin-top: 10px;
    }


    /* CONTENT GRIDS */

    .news-grid,
    .feature-grid,
    .tv-grid {
        grid-template-columns: 1fr;
    }

    .card-image,
    .article-card-image {
        height: 240px;
    }

    .large-image {
        height: 300px;
    }

    .small-image {
        height: 230px;
    }

    .section {
        padding: 45px 0;
    }


    /* ARTICLE */

    .article-page {
        padding: 40px 0 60px;
    }

    .article-title {
        font-size: 36px;
    }

    .article-excerpt {
        font-size: 17px;
    }

    .article-hero {
        height: 330px;
    }

    .article-main-image {
        width: 100%;
        height: auto;
        max-height: none;
        object-fit: contain;
    }

    .article-layout {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .article-content {
        font-size: 17px;
    }
}


/* ========================================
   SMALL MOBILE
======================================== */

@media (max-width: 430px) {

    .header-logo {
        height: 100px;
    }

    .language a {
        font-size: 10px;
    }

    .social-links {
        gap: 7px;
    }

    .social-links a {
        font-size: 9px;
    }

    .hero-image {
        height: 330px;
    }

    .hero-text h1 {
        font-size: 28px;
    }
}
