/**
 * استایل‌های اختصاصی صفحه وبلاگ (RP Blog Page)
 *
 * @package RPKala_Toolkit
 * @since   1.0.0
 */

:root {
    --rp-blog-primary: #23437c;
    --rp-blog-primary-hover: #082c50;
    --rp-blog-bg-card: #ffffff;
    --rp-blog-text-title: #0f172a;
    --rp-blog-text-desc: #64748b;
    --rp-blog-text-muted: #94a3b8;
    --rp-blog-border: #edf2f7;
    --rp-blog-border-subtle: #f1f5f9;
    --rp-blog-radius-card: 22px;
    --rp-blog-radius-thumb: 16px;
    --rp-blog-radius-pill: 9999px;
    --rp-blog-radius-tab: 12px;
    --rp-blog-shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.04), 0 2px 6px -1px rgba(15, 23, 42, 0.02);
    --rp-blog-shadow-hover: 0 14px 30px -4px rgba(15, 23, 42, 0.08), 0 6px 12px -2px rgba(15, 23, 42, 0.03);
    --rp-blog-transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   ۱. کانتینر اصلی صفحه وبلاگ
   فاصله از هدر: 2rem | فاصله از فوتر: 2
   دسکتاپ: 0 | تبلت: 1.5rem | موبایل: 1rem
   ========================================================================== */
.rp-blog-page-wrapper {
    width: 100%;
    max-width: 1230px !important;
    margin-top: 2rem !important;
    margin-bottom: 2rem !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box;
    font-family: inherit;
    direction: rtl;
    text-align: right;
    -webkit-font-smoothing: antialiased;
}

@media (max-width: 1024px) {
    .rp-blog-page-wrapper {
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }
}

@media (max-width: 768px) {
    .rp-blog-page-wrapper {
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
}

.rp-blog-page-wrapper *,
.rp-blog-page-wrapper *::before,
.rp-blog-page-wrapper *::after {
    box-sizing: border-box;
}

/* ==========================================================================
   ۲. بردکرامب (Breadcrumb) - تک‌خطی با اسکرول افقی استاندارد
   ========================================================================== */
.rp-blog-breadcrumb {
    display: flex !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    gap: 0.5rem !important;
    font-size: 0.85rem !important;
    color: var(--rp-blog-text-muted) !important;
    margin-bottom: 1.25rem !important;
    padding: 0 0.25rem 0.4rem 0.25rem !important;
    direction: rtl !important;
}

.rp-blog-breadcrumb::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

.rp-blog-breadcrumb a {
    color: var(--rp-blog-text-desc) !important;
    text-decoration: none !important;
    transition: var(--rp-blog-transition) !important;
    flex-shrink: 0 !important;
    white-space: nowrap !important;
}

.rp-blog-breadcrumb a:hover {
    color: var(--rp-blog-primary) !important;
}

.rp-blog-breadcrumb-sep {
    color: #cbd5e1 !important;
    font-size: 0.75rem !important;
    display: inline-block !important;
    flex-shrink: 0 !important;
}

.rp-blog-breadcrumb-current {
    color: var(--rp-blog-text-title) !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

/* ==========================================================================
   ۳. هدر صفحه وبلاگ (عنوان و باکس جستجو)
   ========================================================================== */
.rp-blog-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 1.5rem !important;
    margin-bottom: 2rem !important;
    flex-wrap: wrap !important;
}

.rp-blog-header-info {
    flex: 1 !important;
    min-width: 280px !important;
}

.rp-blog-title {
    font-size: clamp(1.6rem, 3.5vw, 2.1rem) !important;
    font-weight: 900 !important;
    color: var(--rp-blog-text-title) !important;
    line-height: 1.3 !important;
    margin: 0 0 0.5rem 0 !important;
    letter-spacing: -0.5px !important;
}

.rp-blog-subtitle {
    font-size: 0.95rem !important;
    color: var(--rp-blog-text-desc) !important;
    line-height: 1.6 !important;
    margin: 0 !important;
    font-weight: 400 !important;
}

/* ==========================================================================
   ۳. باکس جستجوی هدر وبلاگ (Pill Search Box)
   مطابق دقیق طرح نمونه: کپسولی با آیکون ذره‌بین در سمت چپ
   ========================================================================== */
.rp-blog-search-box {
    position: relative !important;
    width: 100% !important;
    max-width: 320px !important;
    flex-shrink: 0 !important;
}

.rp-blog-search-form {
    position: relative !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
}

/* اینپوت کپسولی با غلبه قطعی ۱۰۰٪ بر تمامی استایل‌های قالب وردپرس */
.rp-blog-header .rp-blog-search-box .rp-blog-search-input,
#rp-blog-page-wrapper .rp-blog-search-input,
.rp-blog-search-box input.rp-blog-search-input,
input.rp-blog-search-input,
input[type="search"].rp-blog-search-input {
    width: 100% !important;
    height: 46px !important;
    min-height: 46px !important;
    max-height: 46px !important;
    line-height: 46px !important;
    background: #ffffff !important;
    background-color: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 1rem !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-right: 1.25rem !important; /* فاصله مناسب متن از لبه راست (~20px) */
    padding-left: 2.75rem !important;  /* فضای کافی در سمت چپ برای آیکون ذره‌بین */
    font-family: inherit !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    color: #1e293b !important;
    outline: none !important;
    direction: rtl !important;
    text-align: right !important;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04) !important;
    transition: border-color 0.22s ease, box-shadow 0.22s ease, background-color 0.22s ease !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    box-sizing: border-box !important;
    margin: 0 !important;
}

.rp-blog-header .rp-blog-search-box .rp-blog-search-input:focus,
#rp-blog-page-wrapper .rp-blog-search-input:focus,
.rp-blog-search-box input.rp-blog-search-input:focus,
input.rp-blog-search-input:focus,
input[type="search"].rp-blog-search-input:focus {
    border-color: #0070ba !important;
    background-color: #ffffff !important;
    box-shadow: 0 0 0 3px rgba(0, 112, 186, 0.12), 0 2px 12px rgba(15, 23, 42, 0.04) !important;
    outline: none !important;
}

/* حذف کامل دکمه‌ها و تزیینات پیش‌فرض سرچ‌باکس وبکیت مرورگر */
.rp-blog-search-input::-webkit-search-decoration,
.rp-blog-search-input::-webkit-search-cancel-button,
.rp-blog-search-input::-webkit-search-results-button,
.rp-blog-search-input::-webkit-search-results-decoration {
    -webkit-appearance: none !important;
    display: none !important;
}

/* متن پیش‌فرض فیلد جستجو (Placeholder) کاملاً مشابه تصویر ارسالی */
.rp-blog-search-input::-webkit-input-placeholder {
    color: #64748b !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}
.rp-blog-search-input::-moz-placeholder {
    color: #64748b !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}
.rp-blog-search-input:-ms-input-placeholder {
    color: #64748b !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}
.rp-blog-search-input::placeholder {
    color: #64748b !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}

/* آیکون ذره‌بین - ظریف و دقیق در سمت چپ کپسول */
.rp-blog-header .rp-blog-search-box .rp-blog-search-icon,
#rp-blog-page-wrapper .rp-blog-search-icon,
.rp-blog-search-box svg.rp-blog-search-icon,
.rp-blog-search-icon {
    position: absolute !important;
    left: 16px !important;
    right: auto !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 18px !important;
    height: 18px !important;
    color: #94a3b8 !important;
    stroke: currentColor !important;
    stroke-width: 1.6 !important;
    fill: none !important;
    pointer-events: none !important;
    z-index: 2 !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
    transition: color 0.2s ease !important;
}

.rp-blog-search-input:focus ~ .rp-blog-search-icon {
    color: #0070ba !important;
}

/* دکمه پاک‌کردن جستجو */
.rp-blog-header .rp-blog-search-box .rp-blog-search-clear,
#rp-blog-page-wrapper .rp-blog-search-clear,
.rp-blog-search-box button.rp-blog-search-clear,
.rp-blog-search-clear {
    position: absolute !important;
    left: 40px !important;
    right: auto !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: #f1f5f9 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 20px !important;
    height: 20px !important;
    display: none;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    color: #64748b !important;
    font-size: 13px !important;
    line-height: 1 !important;
    padding: 0 !important;
    z-index: 3 !important;
    outline: none !important;
    transition: all 0.2s ease !important;
}

.rp-blog-search-clear:hover {
    background: #e2e8f0 !important;
    color: #0f172a !important;
}

/* ==========================================================================
   ۴. تب‌های دسته‌بندی مقالات
   ========================================================================== */
.rp-blog-categories-wrapper {
    margin-top: -6px;
    margin-bottom: 2rem;
    padding: 6px 4px 18px 4px;
    overflow: visible;
}

.rp-blog-categories-wrapper::-webkit-scrollbar {
    display: none;
}

.rp-blog-categories {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    padding: 4px 2px;
    margin: -4px -2px;
}

.rp-blog-cat-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    padding: 0 1.4rem;
    border-radius: var(--rp-blog-radius-tab);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none !important;
    cursor: pointer;
    transition: var(--rp-blog-transition);
    white-space: nowrap;
    border: 1.5px solid #e2e8f0;
    background: #ffffff;
    color: #334155;
    user-select: none;
    outline: none;
}

.rp-blog-cat-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: var(--rp-blog-primary);
    transform: translateY(-1px);
}

.rp-blog-cat-btn.rp-is-active {
    background: var(--rp-blog-primary) !important;
    border-color: var(--rp-blog-primary) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(35, 67, 124, 0.2);
}

/* ==========================================================================
   ۵. شبکه کارت‌های مقالات (Grid)
   ========================================================================== */
.rp-blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
    margin-bottom: 3rem;
    transition: opacity 0.2s ease;
}

.rp-blog-grid.rp-is-loading {
    opacity: 0.45;
    pointer-events: none;
}

/* کارت مقاله */
.rp-blog-card {
    background: var(--rp-blog-bg-card);
    border-radius: var(--rp-blog-radius-card);
    border: 1px solid var(--rp-blog-border);
    box-shadow: var(--rp-blog-shadow-card);
    padding: 1.15rem;
    display: flex;
    flex-direction: column;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    overflow: hidden;
    position: relative;
}

.rp-blog-card:hover {
    border-color: #cbd5e1 !important;
    box-shadow: 0 10px 25px -3px rgba(15, 23, 42, 0.07), 0 4px 8px -2px rgba(15, 23, 42, 0.03) !important;
}

/* تصویر شاخص کارت */
.rp-blog-card-thumb-link {
    display: block;
    position: relative;
    border-radius: var(--rp-blog-radius-thumb);
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: #f1f5f9;
    text-decoration: none;
    width: 100%;
}

.rp-blog-card-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.rp-blog-card:hover .rp-blog-card-thumb-img {
    transform: scale(1.06);
}

/* بج دسته‌بندی روی تصویر (سمت چپ تصویر مطابق طرح) */
.rp-blog-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    right: auto;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: var(--rp-blog-text-title);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.3rem 0.8rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    z-index: 2;
    pointer-events: none;
    line-height: 1.4;
}

/* بدنه کارت */
.rp-blog-card-body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    padding-top: 1rem;
}

.rp-blog-card-title {
    font-size: 1.05rem;
    font-weight: 800;
    line-height: 1.6;
    color: var(--rp-blog-text-title);
    margin: 0 0 0.55rem 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3.2em;
    transition: color 0.25s ease;
}

.rp-blog-card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.25s ease;
}

.rp-blog-card:hover .rp-blog-card-title,
.rp-blog-card:hover .rp-blog-card-title a {
    color: #0070ba !important;
}

.rp-blog-card-excerpt {
    font-size: 0.85rem;
    line-height: 1.75;
    color: var(--rp-blog-text-desc);
    margin: 0 0 1.25rem 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

/* متادیتای انتهای کارت (تاریخ و زمان مطالعه) */
.rp-blog-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--rp-blog-border-subtle);
    padding-top: 0.85rem;
    color: var(--rp-blog-text-muted);
    font-size: 0.8rem;
    direction: rtl;
}

.rp-blog-card-meta-date,
.rp-blog-card-meta-read {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--rp-blog-text-muted);
    font-weight: 500;
}

.rp-blog-meta-icon {
    width: 15px;
    height: 15px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.8;
    flex-shrink: 0;
}

/* ==========================================================================
   ۶. صفحه‌بندی (Pagination)
   ========================================================================== */
.rp-blog-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2.5rem;
    width: 100%;
}

.rp-blog-pagination-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 50px;
    padding: 0.35rem 0.65rem;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
}

.rp-blog-page-btn {
    min-width: 34px;
    height: 34px;
    padding: 0 0.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    transition: var(--rp-blog-transition);
    cursor: pointer;
    background: transparent;
    border: none;
    outline: none;
}

.rp-blog-page-btn:hover {
    background: #f1f5f9;
    color: var(--rp-blog-primary);
}

.rp-blog-page-btn.rp-is-active {
    background: var(--rp-blog-primary) !important;
    color: #ffffff !important;
    cursor: default;
}

.rp-blog-page-prev,
.rp-blog-page-next {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0 0.85rem;
    height: 34px;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    transition: var(--rp-blog-transition);
    border-radius: 10px;
    cursor: pointer;
    background: transparent;
    border: none;
    outline: none;
}

.rp-blog-page-prev:hover,
.rp-blog-page-next:hover {
    background: #f1f5f9;
    color: var(--rp-blog-primary);
}

.rp-blog-page-prev.rp-is-disabled,
.rp-blog-page-next.rp-is-disabled {
    color: #cbd5e1 !important;
    pointer-events: none;
    cursor: default;
}

.rp-blog-page-arrow-icon {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.2;
}

/* ==========================================================================
   ۷. حالت خالی (Empty State)
   ========================================================================== */
.rp-blog-empty-state {
    grid-column: 1 / -1;
    background: #ffffff;
    border: 1px solid var(--rp-blog-border);
    border-radius: var(--rp-blog-radius-card);
    padding: 4rem 2rem;
    text-align: center;
    box-shadow: var(--rp-blog-shadow-card);
}

.rp-blog-empty-icon {
    width: 56px;
    height: 56px;
    color: #94a3b8;
    margin: 0 auto 1.25rem auto;
    display: block;
    stroke: currentColor;
    fill: none;
}

.rp-blog-empty-title {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--rp-blog-text-title);
    margin: 0 0 0.5rem 0;
}

.rp-blog-empty-desc {
    font-size: 0.9rem;
    color: var(--rp-blog-text-desc);
    margin: 0 0 1.5rem 0;
}

.rp-blog-empty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    padding: 0 1.4rem;
    border-radius: 12px;
    background: var(--rp-blog-primary);
    color: #ffffff;
    font-size: 0.875rem;
    font-weight: 700;
    text-decoration: none;
    transition: var(--rp-blog-transition);
}

.rp-blog-empty-btn:hover {
    background: var(--rp-blog-primary-hover);
    color: #ffffff;
}

/* ==========================================================================
   ۸. ریسپانسیو (Responsive Queries)
   ========================================================================== */
@media (max-width: 1024px) {
    .rp-blog-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .rp-blog-header {
        flex-direction: column;
        align-items: stretch;
        gap: 1.25rem;
    }

    .rp-blog-search-box {
        max-width: 100%;
    }

    .rp-blog-categories-wrapper {
        overflow-x: auto;
        overflow-y: hidden;
        padding-top: 6px;
        padding-bottom: 22px;
        padding-left: 6px;
        padding-right: 6px;
        margin-top: -6px;
        margin-bottom: 1.5rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .rp-blog-categories {
        flex-wrap: nowrap;
        padding: 4px 0;
        margin: -4px 0;
    }

    .rp-blog-cat-btn {
        height: 38px;
        padding: 0 1.15rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 640px) {
    .rp-blog-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .rp-blog-card {
        padding: 1rem;
    }

    .rp-blog-title {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   بخش اختصاصی صفحه تک‌نوشته وبلاگ (RP Single Blog Post)
   مطابق با استانداردهای مدرن UI/UX و هماهنگ با طراحی نمونه‌ها
   ========================================================================== */

#rp-blog-single-wrapper.rp-blog-single-wrapper {
    width: 100%;
    max-width: 1230px !important;
    margin-top: 2rem !important;
    margin-bottom: 2rem !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box;
    direction: rtl;
    font-family: inherit;
}

@media (max-width: 1024px) {
    #rp-blog-single-wrapper.rp-blog-single-wrapper {
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }
}

@media (max-width: 768px) {
    #rp-blog-single-wrapper.rp-blog-single-wrapper {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
}

/* ساختار شبکه دو ستونه اصلی */
.rp-blog-single-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 2.75rem;
    align-items: stretch;
}

/* ستون محتوای اصلی مقاله */
.rp-blog-single-article {
    min-width: 0;
}

/* ۱. راهنمای مسیر (Breadcrumbs) - تک‌خطی با اسکرول افقی استاندارد */
.rp-blog-single-breadcrumbs {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 0.85rem !important;
    color: #64748b !important;
    margin-bottom: 1.75rem !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    text-align: right !important;
    justify-content: flex-start !important;
    line-height: 1.5 !important;
    padding-bottom: 0.4rem !important;
}

.rp-blog-single-breadcrumbs::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

.rp-blog-single-breadcrumbs a {
    color: #64748b !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
    flex-shrink: 0 !important;
    white-space: nowrap !important;
}

.rp-blog-single-breadcrumbs a:hover {
    color: #23437c !important;
}

.rp-single-breadcrumb-arrow {
    stroke: #94a3b8 !important;
    stroke-width: 2.2 !important;
    fill: none !important;
    flex-shrink: 0 !important;
}

.rp-single-breadcrumb-current {
    color: #0f172a !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

/* ۲. بج دسته‌بندی بالای عنوان */
.rp-single-cat-badge-wrap {
    margin-bottom: 0.85rem;
}

.rp-single-cat-badge {
    display: inline-flex;
    align-items: center;
    background: #e8f0f8;
    color: #23437c;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 5px 15px;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.rp-single-cat-badge:hover {
    background: #dbeafe;
    color: #0284c7;
}

/* ۳. عنوان اصلی مقاله */
.rp-single-post-title {
    font-size: 2.15rem;
    font-weight: 900;
    color: #0f172a;
    line-height: 1.45;
    margin: 0 0 1.25rem 0;
    letter-spacing: -0.02em;
    border-bottom: 1px solid #edf2f7;
    padding-bottom: 1.5rem;
}

/* ۴. ردیف مشخصات نویسنده و تاریخ و زمان مطالعه */
.rp-single-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1.25rem;
}

.rp-single-author-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.rp-single-author-avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    background: #f8fafc;
    border: 1.5px solid #edf2f7;
    color: #23437c;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.rp-single-author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 6px;
    box-sizing: border-box;
}

.rp-single-author-avatar svg {
    color: #23437c;
}

.rp-single-author-info {
    display: flex;
    align-items: center;
    text-align: right;
}

.rp-single-author-name {
    font-size: 0.98rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.3;
}

.rp-single-meta-details {
    display: flex;
    align-items: center;
    gap: 20px;
}

.rp-single-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
}

.rp-single-meta-item svg {
    stroke: #94a3b8;
    flex-shrink: 0;
}

/* ۵. تصویر شاخص مقاله */
.rp-single-featured-wrap {
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 2.75rem;
    background: #0b1120;
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.08);
}

.rp-single-featured-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 24px;
    object-fit: cover;
    max-height: 540px;
}

/* ۶. تایپوگرافی و ظاهر متن محتوای مقاله */
.rp-single-content-body {
    color: #334155;
    font-size: 1.05rem;
    line-height: 2.2;
    word-break: break-word;
}

.rp-single-content-body p {
    margin-top: 0;
    margin-bottom: 1.75rem;
}

.rp-single-content-heading,
.rp-single-content-body h2 {
    font-size: 1.55rem;
    font-weight: 800;
    color: #0f172a;
    margin-top: 3.25rem;
    margin-bottom: 1.25rem;
    line-height: 1.5;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid #edf2f7;
    scroll-margin-top: 100px;
}

.rp-single-content-body h3 {
    font-size: 1.3rem;
    font-weight: 800;
    color: #0f172a;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.5;
    scroll-margin-top: 100px;
}

.rp-single-content-body h4 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #0f172a;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    scroll-margin-top: 100px;
}

.rp-single-content-body img {
    max-width: 100%;
    height: auto;
    border-radius: 18px;
    margin: 2rem auto 1rem auto;
    display: block;
}

.rp-single-content-body figure {
    margin: 2.5rem 0;
    text-align: center;
}

.rp-single-content-body figcaption {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 10px;
    font-weight: 500;
}

.rp-single-content-body ul,
.rp-single-content-body ol {
    padding-right: 1.5rem;
    margin-bottom: 1.75rem;
    color: #334155;
    line-height: 2;
}

.rp-single-content-body blockquote {
    background: #f8fafc;
    border-right: 4px solid #23437c;
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    margin: 2.5rem 0;
    color: #475569;
    font-style: normal;
}

.rp-single-content-body a {
    color: #23437c;
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-color: #cbd5e1;
    transition: all 0.2s ease;
}

.rp-single-content-body a:hover {
    color: #0284c7;
    text-decoration-color: #0284c7;
}

/* ۷. باکس معرفی محصول در میان متن مقاله (طراحی مینیمال، جمع‌وجور و بدون کادر رنگی عکس) */
.rp-single-inarticle-product {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 16px !important;
    padding: 12px 18px !important;
    margin: 2rem 0 !important;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
    transition: all 0.25s ease !important;
    box-sizing: border-box !important;
    direction: rtl !important;
}

.rp-single-inarticle-product:hover {
    border-color: #cbd5e1 !important;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.07) !important;
}

.rp-inarticle-product-body {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    direction: rtl !important;
}

/* تصویر محصول: کاملاً شفاف و بدون هیچ کادر رنگی یا بردر */
.rp-inarticle-product-thumb {
    width: 64px !important;
    height: 64px !important;
    min-width: 64px !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 8px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    flex-shrink: 0 !important;
}

.rp-single-content-body .rp-inarticle-product-thumb a,
.rp-inarticle-product-thumb a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
    background: transparent !important;
    border: none !important;
    text-decoration: none !important;
}

.rp-inarticle-product-thumb img {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    background: transparent !important;
    border: none !important;
    transition: transform 0.25s ease !important;
}

.rp-single-inarticle-product:hover .rp-inarticle-product-thumb img {
    transform: scale(1.06) !important;
}

/* جزئیات محصول */
.rp-inarticle-product-details {
    flex: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    gap: 4px !important;
    text-align: right !important;
}

/* بج بالای عنوان داخل ردیف - مینیمال و جمع و جور بدون ایجاد فاصله عمودی */
.rp-inarticle-product-badge-wrap {
    margin-bottom: 2px !important;
    line-height: 1 !important;
}

.rp-inarticle-product-badge {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    background: #eff6ff !important;
    color: #23437c !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    padding: 2px 8px !important;
    border-radius: 6px !important;
    border: 1px solid #dbeafe !important;
    line-height: 1.3 !important;
}

.rp-inarticle-product-badge svg {
    stroke: #23437c !important;
    width: 11px !important;
    height: 11px !important;
    flex-shrink: 0 !important;
}

.rp-inarticle-product-title {
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    margin: 0 !important;
    line-height: 1.4 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.rp-single-content-body .rp-inarticle-product-title a,
.rp-inarticle-product-title a {
    color: #0f172a !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
}

.rp-single-content-body .rp-inarticle-product-title a:hover,
.rp-inarticle-product-title a:hover {
    color: #23437c !important;
}

.rp-inarticle-product-pricing {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
}

.rp-inarticle-pricing-discount {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
}

.rp-inarticle-product-old-price {
    color: #94a3b8 !important;
    font-size: 0.82rem !important;
    text-decoration: line-through !important;
    font-weight: 500 !important;
}

.rp-discount-badge {
    background: #fef2f2 !important;
    color: #ef4444 !important;
    border: 1px solid #fee2e2 !important;
    font-size: 0.7rem !important;
    font-weight: 800 !important;
    padding: 1px 5px !important;
    border-radius: 4px !important;
    line-height: 1.2 !important;
}

.rp-inarticle-pricing-current {
    display: inline-flex !important;
    align-items: baseline !important;
    gap: 4px !important;
}

.rp-inarticle-product-current-price {
    color: #0f172a !important;
    font-size: 1.05rem !important;
    font-weight: 800 !important;
}

.rp-price-currency {
    color: #64748b !important;
    font-size: 0.78rem !important;
    font-weight: 600 !important;
}

.rp-inarticle-product-action {
    display: flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
}

.rp-single-content-body .rp-inarticle-product-btn,
.rp-inarticle-product-btn {
    background: #23437c !important;
    color: #ffffff !important;
    text-decoration: none !important;
    padding: 8px 18px !important;
    border-radius: 10px !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    white-space: nowrap !important;
    transition: all 0.25s ease !important;
    border: none !important;
    box-shadow: 0 2px 6px rgba(35, 67, 124, 0.15) !important;
    height: 38px !important;
    box-sizing: border-box !important;
}

.rp-single-content-body .rp-inarticle-product-btn:hover,
.rp-inarticle-product-btn:hover {
    background: #092c50 !important;
    color: #ffffff !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 10px rgba(35, 67, 124, 0.25) !important;
}

.rp-inarticle-product-btn svg {
    stroke: #ffffff !important;
    transition: transform 0.2s ease !important;
}

.rp-inarticle-product-btn:hover svg {
    transform: translateX(-3px) !important;
}

/* ۸. بخش انتهای مقاله: برچسب‌ها، دکمه لایک و تعداد دیدگاه‌ها */
.rp-single-footer-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-top: 2rem;
    margin-top: 3.5rem;
    border-top: 1px solid #edf2f7;
    flex-wrap: wrap;
}

.rp-single-tags-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.rp-single-tag-pill {
    background: #f1f5f9;
    color: #475569;
    font-size: 0.88rem;
    font-weight: 600;
    padding: 7px 16px;
    border-radius: 12px;
    display: inline-block;
    cursor: default;
    user-select: none;
    line-height: normal;
}

.rp-single-actions-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* دکمه‌های دوقلو لایک و دیدگاه‌ها - دقیقاً یکسان در ابعاد، گوشه‌ها، رنگ و استایل */
.rp-single-actions-wrap button.rp-single-like-btn,
.rp-single-actions-wrap a.rp-single-comments-btn,
.rp-single-like-btn,
.rp-single-comments-btn {
    display: inline-flex !important;
    flex-direction: row !important;
    direction: rtl !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    padding: 0 18px !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    border: 1.5px solid #e2e8f0 !important;
    color: #0f172a !important;
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    font-family: inherit !important;
    line-height: 1 !important;
    text-decoration: none !important;
    box-shadow: none !important;
    outline: none !important;
    cursor: pointer !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease !important;
    margin: 0 !important;
    vertical-align: middle !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}

.rp-single-actions-wrap button.rp-single-like-btn:hover,
.rp-single-actions-wrap a.rp-single-comments-btn:hover,
.rp-single-like-btn:hover,
.rp-single-comments-btn:hover {
    border-color: #cbd5e1 !important;
    background: #f8fafc !important;
    color: #0f172a !important;
    transform: translateY(-1px);
}

.rp-single-like-btn svg,
.rp-single-comments-btn svg {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    stroke: #0f172a !important;
    fill: none !important;
    stroke-width: 2 !important;
    flex-shrink: 0 !important;
    transition: all 0.2s ease !important;
}

.rp-single-like-btn span,
.rp-single-comments-btn span {
    color: #0f172a !important;
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    line-height: 1 !important;
}

/* وضعیت لایک‌شده: کادر و بدنه قرمز ملایم و قلب پر قرمز مطابق با تصویر نمونه */
.rp-single-like-btn.rp-is-liked {
    border-color: #fecdd3 !important;
    background: #fff1f2 !important;
    color: #e11d48 !important;
}

.rp-single-like-btn.rp-is-liked span {
    color: #e11d48 !important;
}

.rp-single-like-btn.rp-is-liked .rp-like-icon {
    stroke: #e11d48 !important;
    fill: #e11d48 !important;
    animation: rpHeartPop 0.35s ease;
}

@keyframes rpHeartPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* ۹. ستون سایدبار چسبان (فهرست مطالب و بنر تبلیغاتی) */
.rp-blog-single-sidebar {
    width: 100%;
    height: 100%;
    position: relative;
    min-width: 0;
}

.rp-blog-sidebar-sticky {
    position: -webkit-sticky;
    position: sticky;
    top: 90px;
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    z-index: 10;
}

body.admin-bar .rp-blog-sidebar-sticky {
    top: 125px;
}

/* کارت فهرست مطالب (TOC) */
.rp-toc-mobile-wrap {
    display: none !important;
}

.rp-toc-desktop-wrap {
    display: block;
    width: 100%;
}

.rp-single-toc-card {
    background: #ffffff;
    border: 1.5px solid #edf2f7;
    border-radius: 24px;
    padding: 24px 22px;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.03);
}

.rp-single-toc-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 1.25rem 0;
    text-align: right;
    display: flex;
    align-items: center;
    gap: 10px;
}

.rp-single-toc-title svg {
    color: #23437c;
    flex-shrink: 0;
}

.rp-single-toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.rp-single-toc-item {
    margin: 0;
}

.rp-single-toc-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: all 0.2s ease;
}

.rp-single-toc-bullet {
    width: 7px;
    height: 7px;
    min-width: 7px;
    border-radius: 50%;
    background-color: #cbd5e1;
    margin-left: 12px;
    transition: all 0.2s ease;
}

.rp-single-toc-text {
    font-size: 0.92rem;
    font-weight: 500;
    color: #64748b;
    line-height: 1.6;
    transition: all 0.2s ease;
}

.rp-single-toc-item.rp-is-active .rp-single-toc-bullet {
    background-color: #23437c;
    transform: scale(1.2);
    box-shadow: 0 0 0 3px rgba(35, 67, 124, 0.15);
}

.rp-single-toc-item.rp-is-active .rp-single-toc-text {
    color: #23437c;
    font-weight: 800;
}

.rp-single-toc-link:hover .rp-single-toc-bullet {
    background-color: #23437c;
}

.rp-single-toc-link:hover .rp-single-toc-text {
    color: #23437c;
}

/* کارت بنر جشنواره و معرفی محصول در سایدبار */
.rp-single-promo-card {
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem 1.5rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.1);
    background-color: #1e293b;
}

.rp-single-promo-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.05) 0%, rgba(15, 23, 42, 0.6) 45%, rgba(15, 23, 42, 0.95) 100%);
    z-index: 1;
    pointer-events: none;
}

.rp-single-promo-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
    width: 100%;
}

.rp-single-promo-badge {
    background: #004b87;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 5px 14px;
    border-radius: 8px;
    margin-bottom: 12px;
    display: inline-block;
}

.rp-single-promo-title {
    color: #ffffff;
    font-size: 1.35rem;
    font-weight: 800;
    margin: 0 0 8px 0;
    line-height: 1.4;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.rp-single-promo-desc {
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.88rem;
    font-weight: 500;
    margin: 0 0 18px 0;
    line-height: 1.6;
}

.rp-single-promo-btn {
    background: #ffffff;
    color: #0f172a;
    font-size: 0.92rem;
    font-weight: 800;
    border-radius: 12px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
    transition: all 0.25s ease;
    box-sizing: border-box;
}

.rp-single-promo-btn:hover {
    background: #f8fafc;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    color: #0f172a;
}

.rp-single-promo-btn svg {
    transition: transform 0.2s ease;
}

.rp-single-promo-btn:hover svg {
    transform: translateX(-4px);
}

/* ==========================================================================
   ۱۰. بخش دیدگاه‌ها و نظرات کاربران (Comments & Nested Replies)
   مطابق با تصاویر ۱ و ۲
   ========================================================================== */

/* خط جداکننده بین بخش مقاله و بخش دیدگاه‌ها */
.rp-single-comments-divider {
    width: 100%;
    max-width: 1230px !important;
    margin: 4rem auto 3.5rem auto;
    border: none;
    border-top: 1.5px solid #edf2f7;
    box-sizing: border-box;
}

.rp-single-comments-section {
    width: 100%;
    max-width: 860px;
    margin: 0 auto 3.5rem auto;
    padding: 0;
    box-sizing: border-box;
}

/* هدر نظرات کاربران */
.rp-comments-header {
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.rp-comments-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.rp-comments-count-pill {
    background: #f1f5f9;
    color: #475569;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    font-weight: 800;
}

/* باکس فرم ارسال نظر (تصویر ۱) */
.rp-comment-form-wrap {
    display: flex !important;
    gap: 18px !important;
    align-items: flex-start !important;
    margin-bottom: 3.5rem !important;
    direction: rtl !important;
}

.rp-comment-form-avatar-col {
    flex-shrink: 0 !important;
}

.rp-comment-form-avatar {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    border-radius: 50% !important;
    background: #f1f5f9 !important;
    border: none !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #94a3b8 !important;
    overflow: hidden !important;
    margin-top: 4px !important;
}

.rp-comment-form-avatar svg {
    stroke: #94a3b8 !important;
}

.rp-comment-form-card {
    flex: 1 !important;
    min-width: 0 !important;
    background: #ffffff !important;
    border: 1.5px solid #edf2f7 !important;
    border-radius: 24px !important;
    padding: 30px 34px !important;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.03) !important;
    box-sizing: border-box !important;
    direction: rtl !important;
}

.rp-comment-form-title {
    font-size: 1.05rem !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    margin: 0 0 1.5rem 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    text-align: right !important;
}

.rp-cancel-reply-btn {
    background: transparent !important;
    border: none !important;
    color: #ef4444 !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    text-decoration: underline !important;
    font-family: inherit !important;
    padding: 0 !important;
}

/* باکس پیام نیاز به ورود جهت ثبت دیدگاه */
.rp-comment-login-required-wrap {
    display: flex !important;
    gap: 18px !important;
    align-items: flex-start !important;
    margin-bottom: 3.5rem !important;
    direction: rtl !important;
}

.rp-comment-login-avatar {
    background: #f1f5f9 !important;
    color: #64748b !important;
}

.rp-comment-login-card {
    flex: 1 !important;
    background: #ffffff !important;
    border: 1.5px solid #edf2f7 !important;
    border-radius: 24px !important;
    padding: 28px 32px !important;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.03) !important;
    box-sizing: border-box !important;
    text-align: right !important;
    transition: all 0.3s ease !important;
}

.rp-comment-login-title {
    font-size: 1.1rem !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    margin: 0 0 8px 0 !important;
    line-height: 1.5 !important;
}

.rp-comment-login-desc {
    font-size: 0.92rem !important;
    color: #64748b !important;
    margin: 0 0 1.25rem 0 !important;
    line-height: 1.7 !important;
}

.rp-comment-login-btn {
    display: inline-flex !important;
    flex-direction: row !important;
    direction: rtl !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    background: #0c3660 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 10px 24px !important;
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    font-family: inherit !important;
    transition: all 0.25s ease !important;
}

.rp-comment-login-btn:hover {
    background: #082645 !important;
    color: #ffffff !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 14px rgba(12, 54, 96, 0.25) !important;
}

.rp-comment-login-btn svg {
    stroke: #ffffff !important;
    flex-shrink: 0 !important;
}

.rp-pulse-highlight {
    animation: rpBoxPulse 1s ease-in-out;
}

@keyframes rpBoxPulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(12, 54, 96, 0.4); }
    50% { transform: scale(1.02); box-shadow: 0 0 0 8px rgba(12, 54, 96, 0); }
    100% { transform: scale(1); box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.03); }
}

/* اعلان بسته بودن دیدگاه‌ها */
.rp-comments-closed-notice {
    display: flex;
    flex-direction: row;
    direction: rtl;
    align-items: center;
    gap: 10px;
    background: #f8fafc;
    border: 1.5px dashed #cbd5e1;
    border-radius: 16px;
    padding: 18px 24px;
    color: #64748b;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 2.5rem;
}

.rp-comments-closed-notice svg {
    stroke: #94a3b8;
    flex-shrink: 0;
}

.rp-comment-form-row {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 16px !important;
    margin-bottom: 16px !important;
}

.rp-comment-form-field {
    margin-bottom: 0 !important;
}

.rp-comment-form-card input[type="text"],
.rp-comment-form-card input[type="email"],
.rp-comment-form-field input[type="text"],
.rp-comment-form-field input[type="email"] {
    width: 100% !important;
    height: 52px !important;
    border: 1.5px solid #edf2f7 !important;
    border-radius: 16px !important;
    padding: 0 20px !important;
    font-size: 0.92rem !important;
    font-family: inherit !important;
    color: #0f172a !important;
    background: #ffffff !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease !important;
    outline: none !important;
    box-shadow: none !important;
}

.rp-comment-form-card input::placeholder,
.rp-comment-form-field input::placeholder {
    color: #94a3b8 !important;
    font-family: inherit !important;
}

.rp-comment-form-card input:focus,
.rp-comment-form-field input:focus {
    border-color: #0c3660 !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(12, 54, 96, 0.08) !important;
}

.rp-comment-form-card textarea,
.rp-comment-form-field textarea {
    width: 100% !important;
    min-height: 130px !important;
    border: 1.5px solid #edf2f7 !important;
    border-radius: 16px !important;
    padding: 16px 20px !important;
    font-size: 0.95rem !important;
    font-family: inherit !important;
    color: #0f172a !important;
    background: #ffffff !important;
    box-sizing: border-box !important;
    resize: vertical !important;
    transition: all 0.2s ease !important;
    outline: none !important;
    box-shadow: none !important;
    margin-top: 16px !important;
}

.rp-comment-form-card textarea::placeholder,
.rp-comment-form-field textarea::placeholder {
    color: #94a3b8 !important;
    font-family: inherit !important;
}

.rp-comment-form-card textarea:focus,
.rp-comment-form-field textarea:focus {
    border-color: #0c3660 !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(12, 54, 96, 0.08) !important;
}

.rp-comment-form-submit-row {
    margin-top: 1.5rem !important;
    display: flex !important;
    justify-content: flex-end !important;
    width: 100% !important;
}

.rp-comment-submit-btn {
    background: #0c3660 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 12px 32px !important;
    font-size: 0.95rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.25s ease !important;
    font-family: inherit !important;
    box-shadow: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.rp-comment-submit-btn:hover {
    background: #082645 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 14px rgba(12, 54, 96, 0.25) !important;
}

/* لیست نظرات و ساختار کارتی (تصویر ۲) */
.rp-comments-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.rp-comment-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    width: 100%;
    box-sizing: border-box;
}

.rp-comment-avatar {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 800;
    overflow: hidden;
    flex-shrink: 0;
}

.rp-avatar-user-initial {
    background: #e0f2fe;
    color: #0284c7;
}

.rp-avatar-admin-rp {
    background: #0f172a;
    color: #ffffff;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.rp-comment-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rp-comment-card {
    flex: 1;
    min-width: 0;
    background: #ffffff;
    border: 1.5px solid #edf2f7;
    border-radius: 20px;
    padding: 22px 26px;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.03);
    box-sizing: border-box;
}

.rp-comment-card-header {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 10px;
}

.rp-comment-author-info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.rp-comment-author-name {
    font-size: 1rem;
    font-weight: 800;
    color: #0f172a;
}

.rp-comment-badge-admin {
    background: #0f172a;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 12px;
    border-radius: 999px;
    line-height: 1.4;
    display: inline-flex;
    align-items: center;
}

.rp-comment-date-row {
    display: inline-flex !important;
    flex-direction: row !important;
    direction: rtl !important;
    align-items: center !important;
    gap: 6px !important;
    color: #94a3b8 !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
    margin-top: 4px !important;
}

.rp-comment-date-row svg {
    stroke: #94a3b8 !important;
    width: 14px !important;
    height: 14px !important;
    flex-shrink: 0 !important;
}

.rp-comment-body {
    color: #334155;
    font-size: 0.95rem;
    line-height: 2;
    margin-bottom: 12px;
    word-break: break-word;
}

.rp-comment-body p {
    margin: 0 0 10px 0;
}

.rp-comment-body p:last-child {
    margin-bottom: 0;
}

.rp-comment-card-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: 12px;
}

.rp-comment-card-footer button.rp-comment-reply-btn,
button.rp-comment-reply-btn,
.rp-comment-reply-btn {
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    border-width: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
    color: #64748b !important;
    font-size: 0.88rem !important;
    font-weight: 600 !important;
    display: inline-flex !important;
    align-items: center !important;
    direction: rtl !important;
    gap: 6px !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 0 !important;
    min-height: unset !important;
    height: auto !important;
    line-height: 1 !important;
    text-decoration: none !important;
    font-family: inherit !important;
    transition: color 0.2s ease, opacity 0.2s ease !important;
}

.rp-comment-card-footer button.rp-comment-reply-btn:hover,
.rp-comment-card-footer button.rp-comment-reply-btn:focus,
.rp-comment-card-footer button.rp-comment-reply-btn:active,
.rp-comment-reply-btn:hover,
.rp-comment-reply-btn:focus,
.rp-comment-reply-btn:active {
    color: #0f172a !important;
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
}

.rp-comment-reply-btn span {
    color: inherit !important;
    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;
}

.rp-comment-reply-btn svg {
    width: 15px !important;
    height: 15px !important;
    stroke: #64748b !important;
    fill: none !important;
    stroke-width: 1.8 !important;
    transition: stroke 0.2s ease, transform 0.2s ease !important;
    flex-shrink: 0 !important;
}

.rp-comment-reply-btn:hover svg {
    stroke: #0f172a !important;
    transform: scale(1.08) !important;
}

/* نظرات تو در تو (پاسخ‌ها) */
.rp-comment-children {
    margin-right: 54px;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

/* وضعیت بدون دیدگاه */
.rp-comments-empty {
    text-align: center;
    padding: 3rem 1.5rem;
    background: #f8fafc;
    border: 1.5px dashed #e2e8f0;
    border-radius: 20px;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.rp-comments-empty-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.rp-comments-empty-text {
    color: #64748b;
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
}

/* ==========================================================================
   ۱۱. بخش مطالب مرتبط (Related Articles)
   مطابق با تصویر ۳
   ========================================================================== */

.rp-single-related-section {
    width: 100%;
    box-sizing: border-box;
    margin-top: 1rem;
    margin-bottom: 0;
}

.rp-single-divider {
    border-top: 1px solid #edf2f7;
    margin: 3.5rem 0 2.5rem 0;
}

.rp-single-related-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.rp-single-related-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
}

.rp-single-related-all {
    color: #23437c;
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.rp-single-related-all:hover {
    color: #0284c7;
}

.rp-single-related-all svg {
    transition: transform 0.2s ease;
}

.rp-single-related-all:hover svg {
    transform: translateX(-4px);
}

.rp-single-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
}

@media (max-width: 1024px) {
    #rp-blog-single-wrapper.rp-blog-single-wrapper {
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }

    .rp-blog-single-layout {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }

    .rp-toc-mobile-wrap {
        display: block !important;
        margin: 1.75rem 0 2.25rem 0 !important;
    }

    .rp-toc-desktop-wrap {
        display: none !important;
    }

    .rp-blog-single-sidebar.rp-sidebar-toc-only {
        display: none !important;
    }

    .rp-single-toc-card.rp-single-toc-card-mobile {
        background: #f8fafc;
        border: 1.5px solid #e2e8f0;
        border-radius: 20px;
        padding: 22px 20px;
        box-shadow: 0 2px 12px rgba(15, 23, 42, 0.03);
    }

    .rp-blog-single-sidebar {
        height: auto;
    }

    .rp-blog-sidebar-sticky {
        position: static;
        top: auto;
    }
}

@media (max-width: 900px) {
    .rp-single-related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    #rp-blog-single-wrapper.rp-blog-single-wrapper {
        margin-top: 2rem !important;
        margin-bottom: 2rem !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
}

@media (max-width: 640px) {
    .rp-single-related-grid {
        grid-template-columns: 1fr;
    }
    .rp-toc-mobile-wrap {
        margin: 1.25rem 0 1.75rem 0 !important;
    }
    .rp-single-toc-card.rp-single-toc-card-mobile {
        padding: 18px 16px;
        border-radius: 16px;
    }
    .rp-single-toc-card.rp-single-toc-card-mobile .rp-single-toc-title {
        font-size: 1.05rem;
        margin-bottom: 1rem;
    }
    .rp-single-toc-card.rp-single-toc-card-mobile .rp-single-toc-list {
        gap: 12px;
    }
    .rp-single-toc-card.rp-single-toc-card-mobile .rp-single-toc-text {
        font-size: 0.88rem;
    }
    .rp-single-comments-section {
        margin: 3rem auto 2rem auto;
        padding: 0 4px;
    }
    .rp-comment-form-card {
        padding: 18px 16px;
        border-radius: 18px;
    }
    .rp-comment-card {
        padding: 16px 18px;
        border-radius: 18px;
    }
    .rp-comment-form-avatar,
    .rp-comment-avatar {
        width: 40px;
        height: 40px;
        min-width: 40px;
        font-size: 1rem;
    }
    .rp-comment-form-row {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    .rp-comment-children {
        margin-right: 1.25rem;
        gap: 1rem;
    }
    .rp-single-inarticle-product {
        padding: 12px 14px !important;
        margin: 1.75rem 0 !important;
    }
    .rp-inarticle-product-body {
        flex-direction: row !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        gap: 12px !important;
    }
    .rp-inarticle-product-thumb {
        width: 56px !important;
        height: 56px !important;
        min-width: 56px !important;
        background: transparent !important;
        border: none !important;
        padding: 0 !important;
    }
    .rp-inarticle-product-title {
        white-space: normal !important;
        font-size: 0.88rem !important;
    }
    .rp-inarticle-product-action {
        width: 100% !important;
        margin-top: 4px !important;
    }
    .rp-single-content-body .rp-inarticle-product-btn,
    .rp-inarticle-product-btn {
        width: 100% !important;
        justify-content: center !important;
        height: 36px !important;
    }
}


