.newspaper-download-section {
    background: linear-gradient(135deg, var(--primary-color, #1e3a8a), var(--primary-dark, #1e1b4b));
    color: white;
    padding: 30px;
    border-radius: 15px;
    margin-top: 30px;
        text-align: center;
}

.newspaper-download-section h3 {
    margin-bottom: 20px;
    font-size: 24px;
    font-weight: 600;
}

.download-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.download-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.download-btn.primary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    backdrop-filter: blur(10px);
}

.download-btn.primary:hover {
    background: white;
    color: var(--primary-color, #1e3a8a);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.download-btn.secondary {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.download-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-2px);
}

/* Enhanced Post Meta */
.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    padding: 20px;
    background: var(--gray-50, #f8f9fa);
    border-radius: 10px;
    margin-bottom: 30px;
}

.post-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-600, #6c757d);
    font-size: 14px;
    padding: 8px 15px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

/* Newspaper Gallery for Lightbox */
.newspaper-images-section h3 {
    margin-bottom: 20px;
    font-size: 22px;
    color: var(--primary-color, #1e3a8a);
}

.newspaper-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.newspaper-gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.newspaper-gallery-item:hover {
    transform: scale(1.02);
}

.newspaper-gallery-item a {
    display: block;
    text-decoration: none;
}

.newspaper-gallery-image {
    width: 100%;
    height: auto;
    cursor: zoom-in;
    transition: opacity 0.3s ease;
    display: block;
}

.newspaper-gallery-image:hover {
    opacity: 0.8;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .post-meta {
        flex-direction: column;
        gap: 10px;
    }

    .newspaper-download-section {
        padding: 20px;
    }

    .download-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .download-btn {
        padding: 12px 25px;
        font-size: 14px;
    }

    .newspaper-gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .post-meta-item {
        font-size: 12px;
        padding: 6px 12px;
    }

    .newspaper-download-section h3 {
        font-size: 20px;
    }
}
/* Related Newspapers Section - بهبودیافته */
.related-posts {
    margin-top: 50px;
    padding: 30px 0;
    border-top: 1px solid var(--gray-200, #e9ecef);
    background: var(--gray-50, #f8f9fa);
    border-radius: 15px;
}

.related-posts h3 {
    text-align: center;
    font-size: 28px;
    font-weight: 600;
    color: var(--primary-color, #1e3a8a);
    margin-bottom: 40px;
    position: relative;
}

.related-posts h3::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--secondary-color, #fbbf24);
    margin: 10px auto 0;
    border-radius: 2px;
}

.newspaper-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;  /* ارتفاع یکسان برای همه کارت‌ها */
    display: flex;
    flex-direction: column;
    position: relative;  /* برای positioning بهتر */
}

.newspaper-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15) !important;  /* !important برای override */
}

.newspaper-thumbnail {
    position: relative;
    overflow: hidden;
    height: 180px;  /* ارتفاع ثابت برای thumbnail */
    flex-shrink: 0;
}

.newspaper-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    display: block;
}

.newspaper-card:hover .newspaper-thumbnail img {
    transform: scale(1.1);
}

.newspaper-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;  /* برای پر کردن فضا */
}

.newspaper-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;  /* محدود به 2 خط */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.newspaper-title a {
    color: var(--text-primary, #333);
    text-decoration: none;
    transition: color 0.3s ease;
}

.newspaper-title a:hover {
    color: var(--primary-color, #1e3a8a);
}

.newspaper-excerpt {
    color: var(--gray-600, #6c757d);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;  /* محدود به 3 خط */
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.newspaper-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--gray-500, #adb5bd);
    padding-top: 10px;
    border-top: 1px solid var(--gray-200, #e9ecef);
    margin-top: auto;  /* به پایین بچسب */
}

.newspaper-section {
    background: var(--secondary-color, #fbbf24);
    color: white;
    padding: 4px 8px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 11px;
}

.newspaper-date {
    display: flex;
    align-items: center;
    gap: 5px;
}

.newspaper-link {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 16px;
    background: var(--primary-color, #1e3a8a);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
    align-self: flex-start;
}

.newspaper-link:hover {
    background: var(--secondary-color, #fbbf24);
    color: #333;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.3);
}

/* Dark Mode (اگر داری) */
body.dark-mode .related-posts {
    background: #1a1a1a;
    border-top-color: #333;
}

body.dark-mode .newspaper-card {
    background: #2a2a2a;
    box-shadow: 0 5px 20px rgba(255, 255, 255, 0.05);
}

body.dark-mode .newspaper-title a {
    color: #e5e5e5;
}

body.dark-mode .newspaper-excerpt {
    color: #a0a0a0;
}

/* Responsive - سه/چهار ستونه */
@media (min-width: 1200px) {
    /* چهار ستونه در XL */
    .related-posts .row {
        --bs-gutter-x: 1.5rem;  /* gap کم‌تر در دسکتاپ */
    }
}

@media (max-width: 991px) {
    /* سه ستونه در MD */
    .newspaper-thumbnail {
        height: 160px;
    }
}

@media (max-width: 768px) {
    /* دو ستونه در SM */
    .related-posts {
        padding: 20px 0;
    }

    .related-posts h3 {
        font-size: 24px;
        margin-bottom: 25px;
    }

    .newspaper-card {
        margin-bottom: 20px;
    }

    .newspaper-thumbnail {
        height: 140px;
    }

    .newspaper-content {
        padding: 15px;
    }

    .newspaper-title {
        font-size: 16px;
        -webkit-line-clamp: 1;
    }

    .newspaper-excerpt {
        display: none;  /* مخفی در موبایل برای فضا */
    }
}

@media (max-width: 480px) {
    /* تک‌ستونه در XS */
    .col-sm-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .newspaper-link {
        padding: 6px 12px;
        font-size: 12px;
    }
}
/* گرید چهار ستونه برای روزنامه‌های مرتبط */
.newspaper-grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 ستون در دسکتاپ */
    gap: 20px;
    margin-top: 20px;
}

/* تبلت: 3 ستون */
@media (max-width: 992px) {
    .newspaper-grid-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* موبایل بزرگ: 2 ستون */
@media (max-width: 768px) {
    .newspaper-grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

/* موبایل کوچک: 1 ستون */
@media (max-width: 480px) {
    .newspaper-grid-container {
        grid-template-columns: 1fr;
    }
}

/* استایل‌های کارت روزنامه */
.newspaper-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.newspaper-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.newspaper-thumbnail {
    position: relative;
    height: 160px;
    overflow: hidden;
}

.newspaper-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.newspaper-card:hover .newspaper-image {
    transform: scale(1.05);
}

.newspaper-content {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.newspaper-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.3;
}

.newspaper-title a {
    color: #333;
    text-decoration: none;
}

.newspaper-title a:hover {
    color: var(--primary-color);
}

.newspaper-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid #eee;
    font-size: 12px;
}

.newspaper-section {
    background: var(--secondary-color);
    color: white;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 500;
}

.newspaper-date {
    color: #666;
    display: flex;
    align-items: center;
    gap: 4px;
}

.newspaper-link {
    display: inline-block;
    margin-top: 10px;
    padding: 6px 12px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-size: 12px;
    transition: all 0.3s ease;
    align-self: flex-start;
}

.newspaper-link:hover {
    background: var(--primary-light);
}
