/* ==========================================================================
   Single Article Stylesheet - Modern RTL
   ========================================================================== */

/* چیدمان کلی صفحه */
.article-page {
    background-color: #f8f9fa;
    padding-top: 80px;
    padding-bottom: 60px;
    font-family: 'YekanBakhFaNum-Light', sans-serif;
    color: #333333;
    direction: rtl;
}

.article-container {
    width: 100%;
}

/* مسیر صفحه (Breadcrumbs) */
.article-breadcrumbs {
    background: transparent;
    padding: 15px 0;
    font-size: 14px;
    color: #6c757d;
}

.breadcrumb-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.breadcrumb-list li {
    display: flex;
    align-items: center;
    font-size: 14px;
}

.breadcrumb-list li:not(:last-child)::after {
    content: "/";
    margin-right: 8px;
    color: #adb5bd;
}

.breadcrumb-list a {
    color: #2a4359;
    text-decoration: none;
    transition: color 0.2s ease;
}

.breadcrumb-list a:hover {
    color: #d4b76e;
}

.breadcrumb-list li.active {
    color: #6c757d;
    max-width: 300px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* هدر مقاله */
.article-header {
    text-align: center;
    padding: 20px 0 30px 0;
}

.article-meta-top {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 15px;
}

.article-category-badge {
    background-color: rgba(42, 67, 89, 0.1);
    color: #2a4359;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.2s ease;
}

.article-category-badge:hover {
    background-color: #2a4359;
    color: #ffffff;
}

.article-title {
    font-family: 'YekanBakhFaNum-Bold', sans-serif;
    font-size: 32px;
    line-height: 1.4;
    color: #1a202c;
    margin: 0 0 20px 0;
}

.article-meta-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding-top: 15px;
    border-top: 1px solid #e9ecef;
    font-size: 14px;
    color: #6c757d;
}

.article-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.author-meta .author-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.author-meta .author-name {
    font-weight: bold;
    color: #2a4359;
}

/* تصویر شاخص */
.article-featured-media {
    margin-bottom: 40px;
}

.featured-image-wrapper {
    width: 100%;
    max-height: 520px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.featured-image {
    width: 100%;
    height: 100%;
    max-height: 520px;
    object-fit: cover;
    display: block;
}

/* بدنه مقاله و تایپوگرافی */
.article-body {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.article-content {
    font-size: 18px;
    line-height: 2;
    color: #2d3748;
}

.article-content h2, 
.article-content h3, 
.article-content h4 {
    font-family: 'YekanBakhFaNum-Bold', sans-serif;
    color: #2a4359;
    margin-top: 35px;
    margin-bottom: 15px;
}

.article-content h2 {
    font-size: 24px;
    border-right: 4px solid #d4b76e;
    padding-right: 12px;
}

.article-content h3 {
    font-size: 20px;
}

.article-content p {
    margin-bottom: 24px;
    font-size: 18px;
    line-height: 2;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 20px 0;
}

.article-content blockquote {
    background-color: #f8f9fa;
    border-right: 4px solid #2a4359;
    margin: 30px 0;
    padding: 20px 25px;
    border-radius: 0 12px 12px 0;
    font-style: italic;
    color: #4a5568;
}

.article-content ul, 
.article-content ol {
    margin-bottom: 24px;
    padding-right: 25px;
}

.article-content li {
    margin-bottom: 8px;
    font-size: 18px;
}

/* فوتر مقاله: برچسب ها و اشتراک گذاری */
.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 40px;
    padding-top: 25px;
    border-top: 1px solid #e9ecef;
}

.article-tags {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tags-label, .share-label {
    font-family: 'YekanBakhFaNum-Bold', sans-serif;
    font-size: 14px;
    color: #2a4359;
}

.tags-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tags-list li a {
    background-color: #f1f3f5;
    color: #495057;
    font-size: 13px;
    padding: 4px 10px;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.2s ease;
}

.tags-list li a:hover {
    background-color: #d4b76e;
    color: #ffffff;
}

.article-share {
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-buttons {
    display: flex;
    gap: 8px;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: #ffffff;
    text-decoration: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.share-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.share-telegram { background-color: #0088cc; }
.share-whatsapp { background-color: #25d366; }
.share-linkedin { background-color: #0077b5; }

/* باکس معرفی نویسنده */
.article-author-box {
    display: flex;
    align-items: center;
    gap: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 24px;
    margin-top: 40px;
    border: 1px solid #e9ecef;
}

.author-box-avatar img {
    border-radius: 50%;
    display: block;
}

.author-box-info {
    flex: 1;
}

.author-box-name {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #2a4359;
}

.author-box-bio {
    margin: 0;
    font-size: 14px;
    color: #6c757d;
    line-height: 1.6;
}

/* ناوبری پست ها */
.article-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e9ecef;
}

.nav-previous a, .nav-next a {
    display: flex;
    flex-direction: column;
    padding: 16px;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
    background: #ffffff;
}

.nav-previous a:hover, .nav-next a:hover {
    border-color: #2a4359;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.nav-label {
    font-size: 12px;
    color: #868e96;
    margin-bottom: 4px;
}

.nav-title {
    font-family: 'YekanBakhFaNum-Bold', sans-serif;
    font-size: 15px;
    color: #2a4359;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-next {
    text-align: left;
}

/* مطالب مرتبط */
.related-posts-section {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #e9ecef;
}

.related-title {
    font-size: 22px;
    color: #2a4359;
    margin-bottom: 24px;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.related-card {
    border: 1px solid #e9ecef;
    border-radius: 12px;
    overflow: hidden;
    background: #ffffff;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.related-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.related-thumb-link {
    display: block;
    height: 160px;
    overflow: hidden;
}

.related-thumb-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-card:hover .related-thumb-link img {
    transform: scale(1.05);
}

.related-thumb-placeholder {
    width: 100%;
    height: 100%;
    background-color: #e9ecef;
}

.related-card-content {
    padding: 16px;
}

.related-date {
    font-size: 12px;
    color: #868e96;
    display: block;
    margin-bottom: 6px;
}

.related-card-title {
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
}

.related-card-title a {
    color: #2a4359;
    text-decoration: none;
    transition: color 0.2s ease;
}

.related-card-title a:hover {
    color: #d4b76e;
}

/* استایل های ریسپانسیو */
@media (max-width: 992px) {
    .article-title {
        font-size: 26px;
    }
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .article-header {
        padding: 10px 0 20px 0;
    }
    .article-title {
        font-size: 22px;
    }
    .article-meta-bar {
        gap: 12px;
        font-size: 13px;
    }
    .article-content {
        font-size: 16px;
    }
    .article-content p, .article-content li {
        font-size: 16px;
    }
    .article-footer {
        flex-direction: column;
        align-items: flex-start;
    }
    .article-author-box {
        flex-direction: column;
        text-align: center;
    }
    .article-navigation {
        grid-template-columns: 1fr;
    }
    .nav-next {
        text-align: right;
    }
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
}