/* =========================================
   استایل اختصاصی صفحه تکی مقالات (Single Post)
   ========================================= */

.up-single-blog {
    background: #f8f9fa;
    padding: 60px 0;
    min-height: 70vh;
    font-family: 'Vazirmatn', Tahoma, sans-serif;
}

.up-single-blog .container {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.up-single-card {
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 15px 50px rgba(26, 43, 76, 0.06);
    overflow: hidden;
    border: 1px solid #eaeaea;
    margin-bottom: 40px;
}

.up-post-content-wrapper {
    padding: 50px;
}

/* =========================================
   چیدمان هدر: عکس بزرگ کنار عنوان
   ========================================= */
.up-post-header-layout {
    display: flex;
    align-items: center; /* تراز کردن عمودی در مرکز */
    gap: 40px;
    margin-bottom: 40px;
    border-bottom: 1px dashed #eee;
    padding-bottom: 30px;
}

/* بخش عنوان (سمت راست) */
.up-post-title-box {
    flex: 1; /* گرفتن فضای باقی‌مانده */
}

.up-post-cat {
    display: inline-block;
    background: rgba(212, 175, 55, 0.1);
    color: #b8972f;
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
    margin-bottom: 15px;
}

.up-single-title {
    font-size: 2.4rem;
    color: #1a2b4c;
    font-weight: 900;
    line-height: 1.4;
    margin-bottom: 20px;
}

.up-post-meta-top {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 14px;
    color: #666;
}

/* بخش عکس (سمت چپ - بزرگتر و بازتر) */
.up-post-hero-image {
    flex: 0 0 45%; /* عکس ۴۵ درصد عرض کل را می‌گیرد */
    max-width: 500px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    background: #f4f5f7;
    display: flex;
    align-items: center;
    justify-content: center;
}

.up-post-hero-image img {
    width: 100%;
    height: auto;
    max-height: 350px; /* جلوگیری از خیلی بلند شدن عکس */
    object-fit: contain; /* نمایش کامل عکس بدون بریدگی */
    display: block;
}

/* =========================================
   محتوای اصلی (تمام عرض)
   ========================================= */
.up-post-body {
    font-size: 16px;
    line-height: 2.2;
    color: #444;
    text-align: justify;
}

.up-post-body h2 { color: #1a2b4c; margin-top: 40px; margin-bottom: 20px; font-size: 1.8rem; font-weight: 800; }
.up-post-body h3 { color: #1a2b4c; margin-top: 30px; margin-bottom: 15px; font-size: 1.4rem; font-weight: 800; }
.up-post-body p { margin-bottom: 25px; }
.up-post-body img { max-width: 100%; height: auto; border-radius: 12px; margin: 25px 0; box-shadow: 0 5px 20px rgba(0,0,0,0.05); }
.up-post-body blockquote { border-right: 5px solid #D4AF37; background: #fdfbf7; padding: 25px; margin: 30px 0; border-radius: 0 12px 12px 0; font-style: italic; color: #555; font-size: 1.1rem; }
.up-post-body ul, .up-post-body ol { margin-bottom: 25px; padding-right: 20px; }
.up-post-body li { margin-bottom: 12px; }

/* بخش برچسب‌ها */
.up-post-tags {
    margin-top: 40px;
    padding-top: 25px;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 14px;
}

.up-post-tags a {
    background: #f0f4f8;
    color: #1a2b4c;
    padding: 5px 14px;
    border-radius: 8px;
    text-decoration: none;
    transition: 0.3s;
}

.up-post-tags a:hover {
    background: #D4AF37;
    color: #fff;
}

/* =========================================
   مقالات مرتبط
   ========================================= */
.up-related-section {
    margin-top: 50px;
    margin-bottom: 50px;
}

.up-related-title {
    font-size: 1.5rem;
    font-weight: 900;
    color: #1a2b4c;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.up-related-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50px;
    height: 3px;
    background: #D4AF37;
    border-radius: 2px;
}

.up-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.up-related-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    box-shadow: 0 5px 20px rgba(0,0,0,0.04);
    border: 1px solid #eee;
    transition: 0.3s;
}

.up-related-card:hover {
    transform: translateY(-5px);
    border-color: #D4AF37;
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.15);
}

.up-rel-img {
    width: 100%;
    height: 160px;
    background: #f8f9fa;
    overflow: hidden;
}

.up-rel-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.4s;
}

.up-related-card:hover .up-rel-img img {
    transform: scale(1.05);
}

.up-rel-content {
    padding: 20px;
}

.up-rel-content h4 {
    margin: 0 0 10px;
    color: #1a2b4c;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.up-rel-date {
    font-size: 12px;
    color: #888;
}

/* =========================================
   ناوبری و کامنت‌ها
   ========================================= */
.up-post-navigation {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 30px;
    margin-bottom: 40px;
}

.up-post-navigation a {
    flex: 1;
    background: #fff;
    padding: 25px;
    border-radius: 20px;
    text-decoration: none;
    box-shadow: 0 5px 20px rgba(0,0,0,0.04);
    border: 1px solid #eee;
    transition: 0.3s;
}

.up-post-navigation a:hover {
    transform: translateY(-5px);
    border-color: #D4AF37;
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.15);
}

.up-nav-label { display: block; font-size: 13px; color: #888; margin-bottom: 8px; }
.up-nav-title { color: #1a2b4c; font-size: 16px; font-weight: 800; line-height: 1.5; }

.up-comments-section {
    background: #fff;
    border-radius: 24px;
    padding: 40px 50px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.04);
    border: 1px solid #eaeaea;
}

.comment-reply-title, .comments-title { display: block; font-size: 1.5rem; font-weight: 900; color: #1a2b4c; margin-bottom: 30px; padding-bottom: 15px; border-bottom: 2px solid #f4f5f7; }
.comment-form { display: flex; flex-direction: column; gap: 20px; }
.comment-form label { font-weight: 700; color: #1a2b4c; margin-bottom: 8px; display: block; font-size: 14px; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea { width: 100%; padding: 16px 20px; border: 1.5px solid #e0e0e0; border-radius: 12px; font-family: inherit; font-size: 15px; background: #fafbfc; transition: all 0.3s ease; outline: none; }
.comment-form textarea { min-height: 150px; resize: vertical; }
.comment-form input:focus, .comment-form textarea:focus { border-color: #D4AF37; background: #fff; box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1); }
.form-submit { margin-top: 10px; }
.comment-form .submit { background: linear-gradient(135deg, #D4AF37, #b8972f); color: #fff; border: none; padding: 15px 40px; border-radius: 12px; font-size: 16px; font-weight: 800; cursor: pointer; transition: 0.3s; box-shadow: 0 8px 20px rgba(212, 175, 55, 0.3); font-family: inherit; }
.comment-form .submit:hover { transform: translateY(-3px); box-shadow: 0 12px 25px rgba(212, 175, 55, 0.5); }
.comment-list { list-style: none; padding: 0; margin: 0 0 40px 0; }
.comment-list .comment-body { background: #f8f9fa; padding: 25px; border-radius: 16px; margin-bottom: 20px; border-right: 4px solid #D4AF37; }
.comment-author img { border-radius: 50%; border: 2px solid #D4AF37; margin-left: 10px; }
.comment-author .fn { font-weight: 800; color: #1a2b4c; font-style: normal; }
.comment-metadata { font-size: 12px; color: #888; margin-top: 5px; margin-bottom: 10px; }
.comment-content { line-height: 1.8; color: #333; font-size: 14px; }
.reply a { display: inline-block; margin-top: 10px; color: #b8972f; font-weight: bold; text-decoration: none; font-size: 13px; background: #fff; padding: 5px 12px; border-radius: 20px; border: 1px solid #D4AF37; transition: 0.3s; }
.reply a:hover { background: #D4AF37; color: #fff; }

.up-back-to-blog { text-align: center; margin-top: 40px; }
.up-back-btn { display: inline-flex; align-items: center; gap: 10px; background: #1a2b4c; color: #fff; padding: 14px 35px; border-radius: 50px; text-decoration: none; font-weight: bold; transition: 0.3s; box-shadow: 0 10px 25px rgba(26, 43, 76, 0.2); }
.up-back-btn:hover { background: #D4AF37; transform: translateY(-3px); box-shadow: 0 10px 25px rgba(212, 175, 55, 0.4); }

/* =========================================
   ریسپانسیو (تبدیل به یک ستون در موبایل)
   ========================================= */
@media (max-width: 992px) {
    .up-post-header-layout {
        flex-direction: column-reverse; /* در موبایل عکس بالا، متن پایین */
        align-items: flex-start;
        gap: 20px;
    }
    .up-post-hero-image {
        flex: 1 1 100%;
        width: 100%;
        max-width: 100%;
    }
    .up-related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .up-post-content-wrapper { padding: 30px 20px; }
    .up-single-title { font-size: 1.8rem; }
    .up-related-grid { grid-template-columns: 1fr; }
    .up-post-navigation { flex-direction: column; }
    .up-comments-section { padding: 30px 20px; }
}



/* =========================================
   استایل صفحه دسته‌بندی مقالات (Category Landing)
   ========================================= */
.up-category-landing {
    background: #f8f9fa;
    padding: 60px 0 80px;
    font-family: 'Vazirmatn', Tahoma, sans-serif;
}

.up-category-landing .container {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

/* هدر دسته‌بندی */
.category-hero {
    text-align: center;
    margin-bottom: 50px;
    padding: 40px 20px;
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(26, 43, 76, 0.04);
    border-bottom: 4px solid #D4AF37;
}

.hero-eyebrow {
    color: #D4AF37;
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 2px;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.hero-title {
    font-size: 2.8rem;
    color: #1a2b4c;
    font-weight: 900;
    margin-bottom: 15px;
}

.hero-desc {
    color: #666;
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

/* گرید کارت‌های مقاله */
.up-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.up-post-card {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #eaeaea;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
}

.up-post-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(212, 175, 55, 0.15);
    border-color: #D4AF37;
}

/* تصویر کارت */
.up-card-img-wrapper {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f8f9fa;
    display: block;
}

.up-card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.up-post-card:hover .up-card-img-wrapper img {
    transform: scale(1.05);
}

.up-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #aaa;
    font-size: 14px;
}

/* محتوای کارت */
.up-card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.up-card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #888;
    margin-bottom: 15px;
}

.up-card-title {
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 1.6;
    margin-bottom: 15px;
}

.up-card-title a {
    color: #1a2b4c;
    text-decoration: none;
    transition: color 0.3s;
}

.up-card-title a:hover {
    color: #D4AF37;
}

.up-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.8;
    margin-bottom: 25px;
    flex: 1;
}

.up-card-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #b8972f;
    font-weight: 800;
    text-decoration: none;
    font-size: 14px;
    transition: gap 0.3s ease;
    margin-top: auto;
}

.up-card-btn:hover {
    gap: 12px;
    color: #1a2b4c;
}

/* صفحه‌بندی */
.up-pagination-wrapper {
    margin-top: 60px;
    text-align: center;
}

.up-pagination-wrapper ul.page-numbers {
    list-style: none;
    padding: 0;
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.up-pagination-wrapper .page-numbers li a,
.up-pagination-wrapper .page-numbers li span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    padding: 0 15px;
    background: #fff;
    border-radius: 12px;
    color: #1a2b4c;
    font-weight: bold;
    text-decoration: none;
    border: 1px solid #eee;
    transition: all 0.3s;
}

.up-pagination-wrapper .page-numbers li span.current {
    background: #1a2b4c;
    color: #fff;
    border-color: #1a2b4c;
}

.up-pagination-wrapper .page-numbers li a:hover {
    background: #D4AF37;
    color: #fff;
    border-color: #D4AF37;
    transform: translateY(-2px);
}

/* ریسپانسیو */
@media (max-width: 900px) {
    .up-posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    .hero-title { font-size: 2rem; }
}

@media (max-width: 600px) {
    .up-posts-grid {
        grid-template-columns: 1fr;
    }
    .up-category-landing { padding: 40px 0; }
    .hero-title { font-size: 1.8rem; }
    .up-card-img-wrapper { height: 220px; }
}