﻿/* ═══════════════════════════════════════════
   RESET & BASE - نشر آوا گستر پویا
   اندازه فونت‌ها: 12-14px (عمومی) | 16-18px (تیترها)
   ═══════════════════════════════════════════ */
:root {
    --navy: #0f1b33;
    --navy-2: #16243f;
    --gold: #c9a227;
    --gold-2: #e0b93b;
    --cream: #f5f1e8;
    --cream-2: #ebe5d8;
    --white: #ffffff;
    --text: #1a2236;
    --text-2: #4a4a4a;
    --text-3: #6b7280;
    --border: #e5e1d8;
    --font-body: 'BNazanin', 'Tahoma', sans-serif;
    --font-head: 'BTitrBd', 'BNazanin', 'Tahoma', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background: var(--cream);
    color: var(--text);
    line-height: 1.9;
    font-size: 13px; /* ← عمومی 13px */
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all .2s;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ═══════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════ */
.site-header {
    background: var(--navy);
    color: var(--white);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 12px rgba(0, 0, 0, .15);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    height: 72px;
}

/* ─── لوگو ─── */
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.brand-icon {
    width: 38px;
    height: 38px;
    color: var(--gold);
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-text {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-right: 10px;
    border-right: 1px solid rgba(201, 162, 39, .35);
}

.brand-title {
    font-family: var(--font-head);
    font-size: 16px;
    color: var(--white);
    letter-spacing: 2px;
    line-height: 1;
}

.brand-sub {
    font-size: 12px;
    color: var(--gold);
    line-height: 1.4;
}

/* ─── منو ─── */
.main-nav ul {
    display: flex;
    align-items: center;
    gap: 2px;
}

.main-nav a {
    display: inline-block;
    padding: 8px 14px;
    font-size: 13px;
    color: #cdd5e0;
    border-radius: 8px;
    transition: all .2s;
}

    .main-nav a:hover,
    .main-nav a.active {
        color: var(--gold);
        background: rgba(201, 162, 39, .1);
    }

/* ─── جستجو (دسکتاپ) ─── */
.header-search {
    position: relative;
    flex: 0 1 220px;
}

    .header-search i {
        position: absolute;
        right: 12px;
        top: 50%;
        transform: translateY(-50%);
        color: #7a8394;
        font-size: 12px;
    }

    .header-search input {
        width: 100%;
        height: 36px;
        background: rgba(255, 255, 255, .05);
        border: 1px solid rgba(255, 255, 255, .1);
        border-radius: 4px;
        padding: 0 34px 0 12px;
        color: var(--white);
        font-family: var(--font-body);
        font-size: 12px;
        outline: none;
    }

        .header-search input::placeholder {
            color: #7a8394;
        }

        .header-search input:focus {
            border-color: var(--gold);
        }

/* ─── دکمه‌های موبایل (فقط در موبایل دیده می‌شن) ─── */
.mobile-actions {
    display: none;
    align-items: center;
    gap: 4px;
}

.header-icon-btn {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--white);
    font-size: 16px;
    cursor: pointer;
    border-radius: 6px;
    transition: all .2s;
}

    .header-icon-btn:hover {
        background: rgba(201, 162, 39, .12);
        color: var(--gold);
    }

/* ─── باکس جستجوی موبایل (بازشو) ─── */
.mobile-search-box {
    display: none;
    background: var(--navy-2);
    border-top: 1px solid rgba(255, 255, 255, .08);
    padding: 12px 0;
    transform: translateY(-100%);
    transition: transform .3s;
}

    .mobile-search-box.open {
        transform: translateY(0);
        display: block;
    }

    .mobile-search-box .container {
        display: flex;
        align-items: center;
        gap: 10px;
        position: relative;
    }

    .mobile-search-box i {
        position: absolute;
        right: 30px;
        color: #7a8394;
        font-size: 13px;
        pointer-events: none;
    }

    .mobile-search-box input {
        flex: 1;
        height: 40px;
        background: rgba(255, 255, 255, .06);
        border: 1px solid rgba(255, 255, 255, .1);
        border-radius: 4px;
        padding: 0 34px 0 14px;
        color: var(--white);
        font-family: var(--font-body);
        font-size: 13px;
        outline: none;
    }

        .mobile-search-box input::placeholder {
            color: #7a8394;
        }

        .mobile-search-box input:focus {
            border-color: var(--gold);
        }

.mobile-search-close {
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 4px;
    color: var(--white);
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .2s;
}

    .mobile-search-close:hover {
        border-color: var(--gold);
        color: var(--gold);
    }

/* ─── نمایش منوی موبایل و دکمه‌ها ─── */
@media (max-width: 768px) {

    /* ─── مخفی کردن جستجو و منوی دسکتاپ ─── */
    .header-search {
        display: none;
    }

    .main-nav {
        display: none;
    }

    /* ─── نمایش دکمه‌های موبایل ─── */
    .mobile-actions {
        display: flex;
    }

    .mobile-toggle {
        display: flex;
    }

    /* ─── منوی موبایل بازشو ─── */
    .main-nav.open {
        display: block;
        position: fixed;
        top: 64px;
        right: 0;
        left: 0;
        background: var(--navy);
        padding: 16px 24px;
        max-height: calc(100vh - 64px);
        overflow-y: auto;
        box-shadow: 0 8px 20px rgba(0, 0, 0, .3);
        z-index: 99;
    }

        .main-nav.open ul {
            flex-direction: column;
            align-items: stretch;
            gap: 2px;
        }

        .main-nav.open a {
            display: block;
            padding: 10px 14px;
            font-size: 13px;
            border-bottom: 1px solid rgba(255, 255, 255, .06);
        }

    .header-inner {
        height: 64px;
    }

    .container {
        padding: 0 16px;
    }

    .mobile-search-box i {
        right: 22px;
    }
}
/* ═══════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════ */
.hero {
    background: var(--navy);
    color: var(--white);
    position: relative;
    overflow: hidden;
    padding: 40px 0 50px;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 40px;
    align-items: center;
    position: relative;
}

.hero-content {
    padding: 20px 0;
}

.hero-title {
    font-family: var(--font-head);
    font-size: 18px; /* ← حداکثر 18px */
    font-weight: normal;
    line-height: 1.5;
    margin-bottom: 14px;
    color: var(--white);
}

    .hero-title span {
        display: block;
    }

.hero-subtitle {
    font-size: 13px;
    color: #a8b2c1;
    margin-bottom: 22px;
    max-width: 420px;
    line-height: 2;
}

.hero-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ─── دکمه‌ها ─── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 22px;
    font-family: var(--font-body);
    font-size: 13px;
    border: 1.5px solid transparent;
    border-radius: 4px;
    cursor: pointer;
    transition: all .25s;
}

.btn-gold {
    background: var(--gold);
    color: var(--navy);
    border-color: var(--gold);
}

    .btn-gold:hover {
        background: var(--gold-2);
        border-color: var(--gold-2);
    }

.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: rgba(255, 255, 255, .4);
}

    .btn-outline:hover {
        border-color: var(--gold);
        color: var(--gold);
    }

/* ─── تصویر Hero ─── */
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 320px;
}

    .hero-image img {
        max-height: 340px;
        filter: drop-shadow(-16px 16px 32px rgba(0, 0, 0, .5));
        border-radius: 4px;
    }

.hero-dots {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 6px;
}

    .hero-dots .dot {
        width: 22px;
        height: 2px;
        background: rgba(255, 255, 255, .25);
        cursor: pointer;
        transition: all .3s;
    }

        .hero-dots .dot.active {
            background: var(--gold);
            width: 34px;
        }

/* ═══════════════════════════════════════════
   SECTION
   ═══════════════════════════════════════════ */
.section {
    padding: 50px 0;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-title {
    position: relative;
    padding-bottom: 12px;
}

    .section-title h2 {
        font-family: var(--font-head);
        font-size: 16px; /* ← تیتر بخش 16px */
        font-weight: normal;
        color: var(--text);
        letter-spacing: 0;
    }

    .section-title::after {
        content: '';
        position: absolute;
        bottom: 0;
        right: 0;
        width: 40px;
        height: 3px;
        background: var(--gold);
    }

.link-more {
    font-size: 12px;
    color: var(--text-3);
}

    .link-more:hover {
        color: var(--gold);
    }

/* ═══════════════════════════════════════════
   BOOK GRID - 6 کتاب در دسکتاپ، 3 کتاب در موبایل
   ═══════════════════════════════════════════ */
.book-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr); /* ← 6 ستون دسکتاپ */
    gap: 20px;
}

.book-card {
    text-align: center;
    transition: transform .3s;
}

    .book-card:hover {
        transform: translateY(-4px);
    }

.book-cover {
    display: block;
    aspect-ratio: 5 / 7;
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .12);
    margin-bottom: 12px;
    background: var(--cream-2);
    transition: box-shadow .3s;
}

.book-card:hover .book-cover {
    box-shadow: 0 10px 24px rgba(0, 0, 0, .2);
}

.book-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.book-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #c9bfa8;
    font-size: 32px;
    background: linear-gradient(135deg, var(--cream-2) 0%, #e0d8c4 100%);
}

.book-title {
    font-family: var(--font-head);
    font-size: 14px; /* ← عنوان کتاب 14px */
    font-weight: normal;
    color: var(--text);
    margin-bottom: 4px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.book-author {
    font-size: 12px;
    color: var(--text-3);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ═══════════════════════════════════════════
   FEATURED BOOKS (سرمه‌ای)
   ═══════════════════════════════════════════ */
.featured-books {
    background: var(--navy-2);
    color: var(--white);
    text-align: center;
    padding: 50px 0;
}

    .featured-books .section-header {
        justify-content: center;
        text-align: center;
        margin-bottom: 32px;
    }

    .featured-books .section-title h2 {
        color: var(--gold);
        font-size: 18px; /* ← تیتر ویژه 18px */
    }

    .featured-books .section-title::after {
        right: 50%;
        transform: translateX(50%);
        width: 50px;
    }

    .featured-books .book-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .featured-books .book-cover {
        box-shadow: 0 6px 20px rgba(0, 0, 0, .4);
    }

    .featured-books .book-title {
        color: var(--white);
    }

    .featured-books .book-author {
        color: #8a95a8;
    }

/* ═══════════════════════════════════════════
   AUTHORS
   ═══════════════════════════════════════════ */
.authors-section {
    background: var(--cream);
}

.author-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
}

.author-card {
    text-align: center;
    transition: transform .3s;
}

    .author-card:hover {
        transform: translateY(-4px);
    }

.author-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .1);
    margin-bottom: 12px;
    background: #2a2a2a;
    transition: box-shadow .3s;
}

.author-card:hover .author-image {
    box-shadow: 0 10px 24px rgba(0, 0, 0, .2);
}

.author-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter .4s;
}

.author-card:hover .author-image img {
    filter: grayscale(0%);
}

.author-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a5a5a;
    font-size: 44px;
    background: #2a2a2a;
}

.author-name {
    font-family: var(--font-head);
    font-size: 14px; /* ← نام نویسنده 14px */
    font-weight: normal;
    margin-bottom: 3px;
    color: var(--text);
}

.author-role {
    font-size: 12px;
    color: var(--text-3);
}

/* ═══════════════════════════════════════════
   CULTURAL
   ═══════════════════════════════════════════ */
.cultural-section {
    background: var(--cream-2);
}

.cultural-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
}

.cultural-item {
    text-align: center;
    padding: 14px 8px;
    transition: transform .3s;
}

    .cultural-item:hover {
        transform: translateY(-3px);
    }

    .cultural-item i {
        font-size: 26px;
        color: var(--text);
        margin-bottom: 12px;
        display: block;
        transition: color .3s;
    }

    .cultural-item:hover i {
        color: var(--gold);
    }

    .cultural-item h4 {
        font-family: var(--font-head);
        font-size: 14px; /* ← تیتر فعالیت 14px */
        font-weight: normal;
        margin-bottom: 4px;
        color: var(--text);
    }

    .cultural-item p {
        font-size: 12px;
        color: var(--text-3);
        line-height: 1.7;
    }

/* ═══════════════════════════════════════════
   FOREIGN RIGHTS
   ═══════════════════════════════════════════ */
.rights-section {
    background: var(--navy);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.rights-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    min-height: 220px;
}

.rights-content {
    padding: 40px 30px 40px 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

    .rights-content h2 {
        font-family: var(--font-head);
        font-size: 16px; /* ← تیتر 16px */
        font-weight: normal;
        margin-bottom: 12px;
        color: var(--white);
        letter-spacing: 0;
    }

    .rights-content p {
        color: #a8b2c1;
        font-size: 13px;
        line-height: 2;
        margin-bottom: 18px;
        max-width: 420px;
    }

.rights-image {
    position: relative;
    background: linear-gradient(135deg, #14203a 0%, #0f1b33 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

    .rights-image img {
        max-height: 180px;
        opacity: .95;
    }

.rights-image-placeholder {
    color: rgba(201, 162, 39, .3);
    font-size: 90px;
}

/* ═══════════════════════════════════════════
   ARTICLES (افقی)
   ═══════════════════════════════════════════ */
.articles-section {
    background: var(--cream);
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.article-card {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 14px;
    align-items: center;
    transition: transform .3s;
}

    .article-card:hover {
        transform: translateY(-2px);
    }

.article-image {
    display: block;
    aspect-ratio: 1 / 1;
    border-radius: 3px;
    overflow: hidden;
    background: var(--cream-2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .1);
}

    .article-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.article-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #c9bfa8;
    font-size: 26px;
    background: linear-gradient(135deg, var(--cream-2) 0%, #e0d8c4 100%);
}

.article-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.article-kind {
    display: inline-block;
    font-size: 11px;
    color: var(--gold);
    margin-bottom: 4px;
}

.article-title {
    font-family: var(--font-head);
    font-size: 14px; /* ← تیتر مقاله 14px */
    font-weight: normal;
    line-height: 1.5;
    margin-bottom: 6px;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-date {
    font-size: 12px;
    color: var(--text-3);
}

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
.site-footer {
    background: var(--navy);
    color: #8a95a8;
    padding-top: 24px;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    flex-wrap: wrap;
    gap: 16px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .footer-brand .brand-icon {
        font-size: 18px;
    }

    .footer-brand .brand-title {
        color: var(--white);
        font-family: var(--font-head);
        font-size: 16px;
        letter-spacing: 2px;
    }

    .footer-brand .brand-sub {
        color: var(--gold);
        font-size: 12px;
    }

.footer-links {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
}

    .footer-links a {
        font-size: 13px;
        color: #8a95a8;
    }

        .footer-links a:hover {
            color: var(--gold);
        }

.footer-social {
    display: flex;
    gap: 8px;
}

    .footer-social a {
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #8a95a8;
        font-size: 13px;
        border: 1px solid rgba(255, 255, 255, .1);
        border-radius: 4px;
        transition: all .25s;
    }

        .footer-social a:hover {
            color: var(--gold);
            border-color: var(--gold);
        }

.footer-bottom {
    padding: 16px 0;
    text-align: center;
    font-size: 12px;
    color: #6a7382;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */

/* ─── تبلت بزرگ (تا 1100px) ─── */
@media (max-width: 1100px) {
    .hero-inner {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-image {
        display: none;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }

    .book-grid,
    .featured-books .book-grid {
        grid-template-columns: repeat(4, 1fr); /* 4 کتاب */
    }

    .author-grid,
    .cultural-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .article-grid {
        grid-template-columns: 1fr 1fr;
    }

    .rights-inner {
        grid-template-columns: 1fr;
    }

    .rights-image {
        display: none;
    }

    .rights-content {
        padding: 36px 24px;
    }
}

/* ─── تبلت کوچک (تا 900px) ─── */
@media (max-width: 900px) {
    .book-grid,
    .featured-books .book-grid {
        grid-template-columns: repeat(3, 1fr); /* 3 کتاب */
        gap: 16px;
    }
}

/* ─── موبایل (تا 768px) ─── */
@media (max-width: 768px) {
    /* ─── منوی موبایل ─── */
    .main-nav {
        position: fixed;
        top: 72px;
        right: 0;
        left: 0;
        background: var(--navy);
        padding: 16px 24px;
        transform: translateX(100%);
        transition: transform .3s;
        max-height: calc(100vh - 72px);
        overflow-y: auto;
    }

        .main-nav.open {
            transform: translateX(0);
        }

        .main-nav ul {
            flex-direction: column;
            align-items: stretch;
            gap: 2px;
        }

        .main-nav a {
            display: block;
            padding: 10px 14px;
            font-size: 13px;
            border-bottom: 1px solid rgba(255, 255, 255, .06);
        }

    .header-search {
        display: none;
    }

    .mobile-toggle {
        display: block;
    }

    .header-inner {
        height: 64px;
    }

    .container {
        padding: 0 16px;
    }

    .section {
        padding: 36px 0;
    }

    .section-title h2 {
        font-size: 15px;
    }

    .hero {
        padding: 32px 0 40px;
    }

    .hero-title {
        font-size: 16px;
    }

    .hero-subtitle {
        font-size: 12px;
    }

    .featured-books {
        padding: 40px 0;
    }

        .featured-books .section-title h2 {
            font-size: 16px;
        }

        /* ═══ 3 کتاب در هر سطر (موبایل) ═══ */
        .book-grid,
        .featured-books .book-grid {
            grid-template-columns: repeat(3, 1fr);
            gap: 10px;
        }

    .book-title {
        font-size: 12px;
    }

    .book-author {
        font-size: 11px;
    }

    .book-placeholder {
        font-size: 22px;
    }

    .book-cover {
        margin-bottom: 8px;
    }

    .author-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .author-name {
        font-size: 13px;
    }

    .author-role {
        font-size: 11px;
    }

    .cultural-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .cultural-item h4 {
        font-size: 13px;
    }

    .cultural-item p {
        font-size: 11px;
    }

    .cultural-item i {
        font-size: 22px;
        margin-bottom: 8px;
    }

    .article-grid {
        grid-template-columns: 1fr;
    }

    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 14px;
    }

    .footer-links {
        justify-content: center;
    }

    .footer-social {
        justify-content: center;
    }
}

/* ─── موبایل کوچک (تا 480px) ─── */
@media (max-width: 480px) {
    /* ═══ 3 کتاب در هر سطر با فاصله کم ═══ */
    .book-grid,
    .featured-books .book-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .book-title {
        font-size: 11px;
    }

    .book-author {
        font-size: 10px;
    }

    .hero-title {
        font-size: 15px;
    }

    .btn {
        padding: 8px 16px;
        font-size: 12px;
    }

    .hero-actions {
        gap: 8px;
    }
}
