/*
Theme Name: Hesabix2
Theme URI: https://hesabix.ir
Author: Hesabix Team
Author URI: https://hesabix.ir
Description: تم ساده حسابیکس - نسخه دوم برای توسعه و سفارشی‌سازی
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 8.0
Version: 0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: hesabix2

Hesabix2 Theme - یک تم ساده برای کار و توسعه بیشتر
*/

/* تنظیمات پایه */
.container,
.max-w-6xl {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .container, .max-w-6xl { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .container, .max-w-6xl { padding-left: 2rem; padding-right: 2rem; }
}

:root {
    --primary: #0ea5e9;
    --primary-dark: #0284c7;
    --text: #1e293b;
    --text-light: #64748b;
    /* پالت قالب */
    --light-50: #f0f9ff;
    --light-100: #e0f2fe;
    --light-200: #bae6fd;
    --light-300: #7dd3fc;
    --brand-600: #0284c7;
    --brand-500: #0ea5e9;
    --brand-400: #38bdf8;
    --brand-200: #bae6fd;
    --accent-500: #f97316;
    --accent-400: #fb923c;
    --accent-300: #fdba74;
    --success-500: #059669;
    --success-400: #10b981;
    --violet-500: #7c3aed;
    --violet-400: #a78bfa;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    /* طراحی یکپارچه */
    --space: 1rem;
    --space-sm: 0.75rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --radius: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.25rem;
    --radius-2xl: 1.5rem;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
    --shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.06);
    --max-width: 72rem;
}

/* Hero — پس‌زمینه آسمان نرم تا ابرها خوانا باشند */
.hero-with-clouds {
    background: linear-gradient(165deg, #bae6fd 0%, #e0f2fe 35%, #f0f9ff 70%, #fafafa 100%);
    position: relative;
}
.hero-with-clouds h1 {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
    color: var(--slate-800);
}
@media (min-width: 640px) {
    .hero-with-clouds h1 { font-size: 2.75rem; }
}
@media (min-width: 1024px) {
    .hero-with-clouds h1 { font-size: 3.25rem; }
}
.hero-clouds {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}
.hero-clouds canvas {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ——— پرسش و پاسخ (AnsPress) ——— */
.ap-hero-qa {
    background: linear-gradient(152deg, #e0f2fe 0%, #f0f9ff 40%, #f8fafc 85%, #fff 100%);
    position: relative;
    border: 1px solid rgba(14, 165, 233, 0.08);
}
.ap-hero-qa::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 60% at 20% 50%, rgba(14, 165, 233, 0.06) 0%, transparent 50%),
                radial-gradient(ellipse 60% 40% at 85% 20%, rgba(14, 165, 233, 0.04) 0%, transparent 45%);
    pointer-events: none;
    border-radius: inherit;
}
.ap-hero-qa .ap-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--brand-600);
    background: rgba(14, 165, 233, 0.12);
    border-radius: 9999px;
    margin-bottom: 0.75rem;
}
.ap-card-qa {
    transition: box-shadow 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
}
.ap-card-qa:hover {
    box-shadow: 0 10px 40px -12px rgba(14, 165, 233, 0.12), 0 4px 12px -4px rgba(0, 0, 0, 0.06);
    border-color: rgba(14, 165, 233, 0.2);
}
.ap-card-qa.ap-card-qa--solved {
    border-right: 3px solid var(--success-500);
}
.ap-answer-card.ap-best-answer {
    background: linear-gradient(135deg, rgba(5, 150, 105, 0.04) 0%, rgba(5, 150, 105, 0.02) 100%);
    box-shadow: 0 4px 20px -8px rgba(5, 150, 105, 0.2);
}
.ap-filters-bar {
    background: var(--slate-50);
    border: 1px solid var(--slate-100);
}
.ap-empty-illustration {
    opacity: 0.85;
}
.ap-pagination-qa .ap-page-current {
    background: var(--brand-500);
    color: #fff;
    border-color: var(--brand-500);
}
.ap-pagination-qa a:hover {
    background: var(--light-100);
    border-color: var(--brand-400);
    color: var(--brand-600);
}
.ap-sidebar-card-qa {
    border: 1px solid var(--slate-100);
    transition: box-shadow 0.2s ease;
}
.ap-sidebar-card-qa:hover {
    box-shadow: 0 4px 12px -4px rgba(0, 0, 0, 0.06);
}
.ap-stats-num {
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

/* کلاس‌های رنگ و دکمه — کار کنند حتی اگر Tailwind لود نشود */
.bg-light-50 { background-color: var(--light-50) !important; }
.bg-light-100 { background-color: var(--light-100) !important; }
.bg-light-200 { background-color: var(--light-200) !important; }
.bg-brand-500 { background-color: var(--brand-500) !important; }
.bg-brand-600 { background-color: var(--brand-600) !important; }
.bg-accent-500 { background-color: var(--accent-500) !important; }
.bg-accent-400 { background-color: var(--accent-400) !important; }
.bg-white { background-color: #fff !important; }
.bg-slate-50\/80 { background-color: rgba(248, 250, 252, 0.8) !important; }
.bg-slate-800 { background-color: var(--slate-800) !important; }
.bg-slate-900\/40 { background-color: rgba(15, 23, 42, 0.4) !important; }

.text-brand-500 { color: var(--brand-500) !important; }
.text-brand-600 { color: var(--brand-600) !important; }
.text-accent-500 { color: var(--accent-500) !important; }
.text-success-500 { color: var(--success-500) !important; }
.text-slate-400 { color: var(--slate-400) !important; }
.text-slate-500 { color: var(--slate-500) !important; }
.text-slate-600 { color: var(--slate-600) !important; }
.text-slate-700 { color: var(--slate-700) !important; }
.text-slate-800 { color: var(--slate-800) !important; }
.text-white { color: #fff !important; }

.hover\:bg-brand-600:hover { background-color: var(--brand-600) !important; }
.hover\:bg-accent-400:hover { background-color: var(--accent-400) !important; }
.hover\:bg-light-100:hover { background-color: var(--light-100) !important; }
.hover\:bg-light-200:hover { background-color: var(--light-200) !important; }
.hover\:text-brand-600:hover { color: var(--brand-600) !important; }

/* گرادیان نوار و دکمه */
.bg-gradient-to-l.from-brand-500.via-brand-400.to-accent-400,
[class*="from-brand-500"][class*="via-brand-400"][class*="to-accent-400"] {
    background: linear-gradient(to left, var(--brand-500), var(--brand-400), var(--accent-400)) !important;
}
.bg-gradient-to-br.from-brand-500.to-brand-600,
[class*="from-brand-500"][class*="to-brand-600"] {
    background: linear-gradient(to bottom right, var(--brand-500), var(--brand-600)) !important;
}

/* دکمه‌ها — اندازه و سایه یکسان */
a.bg-brand-500,
a[class*="bg-brand-500"].hover\:bg-brand-600,
.inline-flex.bg-brand-500,
a[class*="bg-brand-500"] {
    background-color: var(--brand-500) !important;
    color: #fff !important;
    padding: 0.625rem 1.5rem;
    min-height: 2.75rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: 0.9375rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none !important;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.15s;
    box-shadow: 0 1px 3px rgba(2, 132, 199, 0.25);
}
a.bg-brand-500:hover,
a.hover\:bg-brand-600:hover,
.inline-flex.bg-brand-500:hover {
    background-color: var(--brand-600) !important;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
}

/* دکمه accent (نارنجی) */
a.bg-accent-500,
.inline-flex.bg-accent-500,
a[class*="bg-accent-500"] {
    background-color: var(--accent-500) !important;
    color: #fff !important;
    padding: 0.625rem 1.5rem;
    min-height: 2.75rem;
    border-radius: var(--radius-lg);
    font-weight: 700;
    font-size: 0.9375rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none !important;
    transition: background-color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 3px rgba(249, 115, 22, 0.3);
}
a.bg-accent-500:hover,
.inline-flex.bg-accent-500:hover { background-color: var(--accent-400) !important; box-shadow: 0 4px 12px rgba(249, 115, 22, 0.35); }

/* دکمه حاشیه‌دار (outline) */
a.border-2.border-brand-500,
a[class*="border-brand-500"] {
    color: var(--brand-600) !important;
    text-decoration: none !important;
    padding: 0.625rem 1.5rem;
    min-height: 2.75rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border: 2px solid var(--brand-500) !important;
    background: transparent !important;
    transition: background 0.2s, color 0.2s;
}
a.border-2.border-brand-500:hover,
a[class*="border-brand-500"]:hover {
    background: var(--brand-500) !important;
    color: #fff !important;
}

/* نوار گرادیان بالای هدر/فوتر */
.h-0\.5.w-full.bg-gradient-to-l,
.h-1.w-full.bg-gradient-to-l,
[class*="h-0"][class*="w-full"][class*="from-brand-500"],
[class*="h-1"][class*="w-full"][class*="from-brand-500"] {
    height: 2px;
    width: 100%;
    background: linear-gradient(to left, var(--brand-500), var(--brand-400), var(--accent-400)) !important;
}
.h-1.w-full.bg-gradient-to-l { height: 4px !important; }

/* ========== سیستم طراحی ========== */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Yekan Bakh FaNum', Tahoma, Geneva, Verdana, sans-serif !important;
    direction: rtl;
    margin: 0;
    padding: 0;
    color: var(--text);
    line-height: 1.65;
    background: var(--light-50);
    -webkit-font-smoothing: antialiased;
}

/* سکشن‌های صفحه — فاصله و عرض یکسان */
.site-main section,
section.py-12, section.py-16, section[class*="py-"] {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
}
@media (min-width: 640px) {
    .site-main section,
    section.py-12, section[class*="py-16"], section[class*="py-20"] {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }
}
@media (min-width: 1024px) {
    .site-main section,
    section[class*="py-16"], section[class*="py-20"] {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
}

/* کارت‌ها — سایه و گوشه گرد یکسان */
.rounded-2xl, .rounded-3xl,
[class*="rounded-2xl"], [class*="rounded-3xl"] {
    border-radius: var(--radius-xl) !important;
    box-shadow: var(--shadow-sm);
}
.bg-white.rounded-2xl:hover,
.bg-white.rounded-3xl:hover,
.bg-light-50.rounded-2xl:hover {
    box-shadow: var(--shadow) !important;
}

/* تایتل سکشن‌ها */
h2.text-2xl, h2[class*="text-2xl"], h2[class*="text-3xl"] {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--slate-800);
    margin: 0 0 0.5rem;
    letter-spacing: -0.02em;
}
@media (min-width: 640px) {
    h2.text-2xl, h2[class*="text-3xl"] { font-size: 2rem; }
}
@media (min-width: 1024px) {
    h2[class*="text-3xl"] { font-size: 2.25rem; }
}

/* خط تزئینی بالای تایتل */
[class*="w-10"][class*="h-1"][class*="rounded-full"].bg-brand-500,
[class*="w-10"][class*="h-1"][class*="rounded-full"].bg-accent-500,
[class*="w-10"][class*="h-1"][class*="rounded-full"].bg-success-500,
[class*="w-10"][class*="h-1"][class*="rounded-full"].bg-violet-500 {
    display: block;
    width: 2.5rem;
    height: 4px;
    border-radius: 9999px;
    margin-bottom: 1rem;
}

/* جداسازی سکشن‌ها */
.border-slate-100, .border-t.border-slate-100, .border-y.border-slate-100,
section.bg-white {
    border-color: var(--slate-100) !important;
}
.border-light-200 { border-color: var(--light-200) !important; }
.border-slate-200 { border-color: var(--slate-200) !important; }

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover,
a:focus {
    color: var(--primary-dark);
    text-decoration: none;
}

/* برند و لوگوی هدر - بدون underline در حالت عادی و هاور */
.site-brand,
.site-brand:hover,
.site-brand:focus,
.site-brand:active {
    text-decoration: none !important;
}
.site-brand .site-brand-name:hover {
    text-decoration: none !important;
}
.site-brand-icon,
.site-brand-letter {
    flex-shrink: 0;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.site-brand-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.site-brand-name {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

/* هدر — تمیز و ثابت */
header.sticky {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
}
header .site-brand-name {
    color: var(--slate-800);
    transition: color 0.2s;
}
header .site-brand:hover .site-brand-name {
    color: var(--brand-600);
}
header nav a,
.header-menu a {
    color: var(--slate-600) !important;
    text-decoration: none !important;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    font-weight: 500;
    font-size: 0.9375rem;
    transition: color 0.2s, background 0.2s;
}
header nav a:hover,
.header-menu a:hover {
    color: var(--brand-600) !important;
    background: var(--light-100);
}

/* هدر (legacy) */
.site-header {
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    padding: 1rem 0;
}

.site-header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.site-title a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.site-title a:hover {
    text-decoration: none;
}

/* محتوا */
.site-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* منوی هدر دسکتاپ - فقط آیتم هاور شده تغییر کند */
.site-header nav a,
header nav a,
.header-desktop-nav a {
    color: #475569;
    text-decoration: none;
    transition: color 0.2s, background-color 0.2s;
}
.site-header nav ul,
header nav ul,
.header-desktop-nav ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.header-desktop-nav ul li { margin: 0; }
.header-desktop-nav ul li a,
header nav ul li a {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #475569;
}
/* فقط لینکی که موس روشه هاور بگیره */
.header-desktop-nav ul li a:hover,
.header-desktop-nav ul li a:focus,
header nav ul li a:hover,
header nav ul li a:focus {
    text-decoration: none;
    background-color: #e0f2fe;
    color: var(--primary);
}
.site-header nav a:hover,
.site-header nav a:focus,
header nav a:hover,
header nav a:focus {
    text-decoration: none;
    background-color: #e0f2fe;
    color: var(--primary);
}

/* منوی موبایل - دراور از راست، تاچ‌فرندلی */
.hesabix-mobile-menu {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}
.hesabix-mobile-menu.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.hesabix-mobile-backdrop {
    opacity: 0;
    transition: opacity 0.25s ease;
}
.hesabix-mobile-menu.is-open .hesabix-mobile-backdrop {
    opacity: 1;
}
.hesabix-mobile-drawer {
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}
.hesabix-mobile-menu.is-open .hesabix-mobile-drawer {
    transform: translateX(0);
}
body.hesabix-menu-open {
    overflow: hidden !important;
}

.nav-mobile-list,
.hesabix-mobile-menu nav ul {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-mobile-list li,
.hesabix-mobile-menu nav ul li { margin: 0; }
.nav-mobile-list a,
.hesabix-mobile-menu nav ul li a,
.hesabix-mobile-link {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 1rem 1rem;
    border-radius: 0.75rem;
    color: #334155;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s, background 0.2s;
}
.nav-mobile-list a:hover,
.nav-mobile-list a:focus,
.hesabix-mobile-menu nav ul li a:hover,
.hesabix-mobile-menu nav ul li a:focus,
.hesabix-mobile-link:hover,
.hesabix-mobile-link:focus {
    color: var(--primary);
    background: #e0f2fe;
}
.mobile-nav ul { display: flex; flex-direction: column; gap: 0.25rem; list-style: none; margin: 0; padding: 0; }
.mobile-nav li { margin: 0; }
.mobile-nav a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0.875rem 1rem;
    border-radius: 0.75rem;
    color: #64748b;
    transition: color 0.2s, background 0.2s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
    color: var(--primary);
    background: #e0f2fe;
}

/* فوتر — ساده و خوانا */
.site-footer {
    margin-top: 4rem;
}
.site-footer .footer-brand {
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
}
.site-footer .footer-brand:hover,
.site-footer .footer-brand:focus {
    text-decoration: none !important;
}
.site-footer .footer-brand span:last-child {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--slate-800);
    transition: color 0.2s;
}
.site-footer .footer-brand:hover span:last-child {
    color: var(--brand-600);
}
.site-footer .footer-heading {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--slate-800);
    margin: 0 0 1.25rem 0;
    letter-spacing: -0.01em;
}
.site-footer .footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-footer .footer-links li {
    margin: 0;
}
.site-footer .footer-links a {
    display: inline-block;
    padding: 0.4rem 0;
    color: var(--slate-500);
    text-decoration: none !important;
    font-size: 0.9375rem;
    transition: color 0.2s;
}
.site-footer .footer-links a:hover,
.site-footer .footer-links a:focus {
    color: var(--brand-600);
}
/* چیدمان محتوا — تک‌ستون وقتی سایدبار خالی است */
.layout-wrap {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .layout-wrap { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .layout-wrap { padding-left: 2rem; padding-right: 2rem; }
}

.layout--single .layout-main {
    width: 100%;
    max-width: none;
}

.layout--with-sidebar {
    display: grid;
    gap: 2rem;
    grid-template-columns: 1fr;
}
@media (min-width: 1024px) {
    .layout--with-sidebar {
        grid-template-columns: 1fr 280px;
        gap: 2.5rem;
    }
    .layout--with-sidebar .layout-main {
        min-width: 0;
    }
    .layout--with-sidebar .layout-sidebar {
        min-width: 0;
    }
}

.layout-sidebar {
    order: -1; /* در موبایل سایدبار بالای محتوا */
}
@media (min-width: 1024px) {
    .layout-sidebar { order: 0; }
}

.layout-sidebar .widget {
    margin-bottom: 1.5rem;
}
.layout-sidebar .widget:last-child {
    margin-bottom: 0;
}
.layout-sidebar .widget-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--slate-800);
    margin: 0 0 0.75rem 0;
}

/* گرید فوتر — تعداد ستون بر اساس ویجت؛ تک‌ستونه وقتی فقط برند باشد */
.footer-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: 1fr;
}
@media (min-width: 768px) {
    .footer-grid.footer-cols-2 { grid-template-columns: 1fr 1fr; }
    .footer-grid.footer-cols-3 { grid-template-columns: 1.2fr 1fr 1fr; }
    .footer-grid.footer-cols-4 { grid-template-columns: 1.2fr 1fr 1fr 1fr; }
}
@media (min-width: 1024px) {
    .footer-grid.footer-cols-2 { grid-template-columns: 1.5fr 1fr; }
    .footer-grid.footer-cols-3 { grid-template-columns: 1.5fr 1fr 1fr; }
    .footer-grid.footer-cols-4 { grid-template-columns: 1.3fr 1fr 0.9fr 1.2fr; }
}
.footer-col--brand { min-width: 0; }

.site-footer .bg-slate-800 {
    background: var(--slate-800) !important;
}
.site-footer .bg-slate-800 a {
    text-decoration: none !important;
}
.footer-parspack-link {
    color: var(--brand-400);
    text-decoration: none !important;
}
.footer-parspack-link:hover {
    color: var(--light-300);
}

/* کارت‌های آمار Hero — اعداد درشت و خوانا */
.hero-with-clouds .text-4xl,
.hero-with-clouds .text-5xl,
.hero-with-clouds [class*="text-4xl"],
.hero-with-clouds [class*="text-5xl"] {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}
@media (min-width: 640px) {
    .hero-with-clouds [class*="text-4xl"],
    .hero-with-clouds [class*="text-5xl"] { font-size: 3rem; }
}

/* کارت وبلاگ در صفحه نخست */
.fp-blog-card {
    text-decoration: none !important;
    color: inherit;
    transition: box-shadow 0.25s, border-color 0.25s;
}
.fp-blog-card:hover {
    border-color: var(--brand-400) !important;
    box-shadow: var(--shadow-md) !important;
}
.fp-blog-card--violet:hover { border-color: var(--violet-400) !important; }
.fp-blog-card__title { transition: color 0.2s; }
.fp-blog-card:hover .fp-blog-card__title { color: var(--brand-600) !important; }
.fp-blog-card--accent:hover { border-color: #fb923c !important; }
.fp-blog-card:hover .fp-blog-card__title { color: #0284c7; }
.fp-blog-card--violet:hover .fp-blog-card__title { color: #7c3aed; }
.fp-blog-card--accent:hover .fp-blog-card__title { color: #ea580c; }
.fp-blog-card:hover .fp-blog-card__link { color: #0284c7; }
.fp-blog-card--violet:hover .fp-blog-card__link { color: #7c3aed; }
.fp-blog-card--accent:hover .fp-blog-card__link { color: #ea580c; }
.fp-blog-card__placeholder--brand {
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
}
.fp-blog-card__placeholder--violet {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}
.fp-blog-card__placeholder--accent {
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
}
.fp-blog-card .line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ========== وبلاگ - لیست ========== */
.blog-header { margin-bottom: 3rem; }
.blog-title { font-size: 1.875rem; font-weight: 700; color: #0f172a; letter-spacing: -0.025em; }
.blog-desc { color: #64748b; font-size: 0.9375rem; }

.blog-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* پست برجسته (اول) */
.blog-entry--featured {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 2.5rem;
    margin-bottom: 2rem;
}
.blog-entry--featured .blog-entry__link {
    display: block;
    text-decoration: none;
    color: inherit;
}
.blog-entry--featured .blog-entry__link:hover .blog-entry__title { color: #0284c7; }
.blog-entry--featured .blog-entry__media {
    aspect-ratio: 21/9;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 1.25rem;
    background: #f1f5f9;
}
.blog-entry--featured .blog-entry__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.blog-entry--featured .blog-entry__link:hover .blog-entry__img { transform: scale(1.02); }
.blog-entry--featured .blog-entry__placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0ea5e9 0%, #0369a1 100%);
}
.blog-entry--featured .blog-entry__cat {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #0284c7;
    margin-bottom: 0.5rem;
}
.blog-entry--featured .blog-entry__title--large {
    font-size: 1.75rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.3;
    margin: 0 0 0.75rem;
    letter-spacing: -0.02em;
}
.blog-entry--featured .blog-entry__excerpt {
    color: #64748b;
    font-size: 1rem;
    line-height: 1.65;
    margin: 0 0 1rem;
}
.blog-entry--featured .blog-entry__meta {
    font-size: 0.8125rem;
    color: #94a3b8;
}
.blog-entry--featured .blog-entry__dot {
    display: inline-block;
    width: 3px;
    height: 3px;
    background: #cbd5e1;
    border-radius: 50%;
    margin: 0 0.5rem;
    vertical-align: middle;
}

/* پست‌های لیستی */
.blog-entry:not(.blog-entry--featured) {
    border-bottom: 1px solid #f1f5f9;
}
.blog-entry:not(.blog-entry--featured):last-of-type { border-bottom: none; }
.blog-entry__link--row {
    display: flex;
    gap: 1.25rem;
    padding: 1.25rem 0;
    text-decoration: none;
    color: inherit;
    align-items: flex-start;
}
.blog-entry__link--row:hover .blog-entry__title { color: #0284c7; }
.blog-entry__media--sm {
    flex-shrink: 0;
    width: 140px;
    height: 94px;
    overflow: hidden;
    border-radius: 6px;
    background: #f1f5f9;
}
.blog-entry__media--sm .blog-entry__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.blog-entry__placeholder--sm {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
}
@media (max-width: 480px) {
    .blog-entry__media--sm { width: 100px; height: 67px; }
    .blog-entry__link--row { gap: 0.875rem; padding: 1rem 0; }
    .blog-entry--featured .blog-entry__title--large { font-size: 1.375rem; }
}
.blog-entry__content--sm { flex: 1; min-width: 0; }
.blog-entry__cat--sm {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
}
.blog-entry__title {
    font-size: 1.0625rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0.25rem 0 0.35rem;
    line-height: 1.4;
}
.blog-entry__meta--sm { font-size: 0.75rem; color: #94a3b8; }

/* صفحه خالی و صفحه‌بندی */
.blog-empty { text-align: center; padding: 4rem 2rem; }
.blog-empty__text { color: #64748b; margin-bottom: 1rem; }
.blog-empty__back { color: #0284c7; font-weight: 500; text-decoration: none; }
.blog-empty__back:hover { text-decoration: underline; }
.blog-pagination { margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid #e2e8f0; }
.blog-pagination .nav-links { display: flex; justify-content: center; gap: 0.25rem; }
.blog-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    font-size: 0.875rem;
    color: #475569;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
}
.blog-pagination .page-numbers:hover,
.blog-pagination .page-numbers.current { background: #f1f5f9; color: #0f172a; }

/* لیست وبلاگ - طرح کارتی (الهام از Hesabix) */
.blog-hero-title { text-shadow: 0 1px 2px rgba(0,0,0,0.1); }
.blog-hero-desc { text-shadow: 0 1px 1px rgba(0,0,0,0.05); }
.blog-card-glow {
    background: linear-gradient(to right, var(--brand-500), var(--violet-500));
}
.blog-card-title a { text-decoration: none; }
.blog-card-title a:hover { text-decoration: none; }
.blog-card-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.blog-card-title.line-clamp-2,
.single-nav__title.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.blog-pagination-num { text-decoration: none; }
.blog-pagination-num--current { cursor: default; }
.blog-empty-back { text-decoration: none; }

/* پست تکی - هدر و خلاصه */
.single-post-cat { text-decoration: none; }
.single-summary-box { border-right-width: 4px; }
.single-share-title { margin: 0; }
.single-share-twitter { background: #1da1f2; text-decoration: none; }
.single-share-linkedin { background: #0a66c2; text-decoration: none; }
.single-share-telegram { background: #0088cc; text-decoration: none; }
.single-share-whatsapp { background: #25d366; text-decoration: none; }
.single-sidebar-title { margin: 0; }
.single-related-item { text-decoration: none; color: inherit; }
.single-back-blog-btn { text-decoration: none; }

/* ========== پست تکی ========== */
.single-breadcrumb {
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 0.75rem;
}
.single-breadcrumb a { color: #64748b; text-decoration: none; }
.single-breadcrumb a:hover { color: #0284c7; }
.single-breadcrumb__sep { margin: 0 0.35rem; opacity: 0.6; }
.single-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.3;
    letter-spacing: -0.025em;
    margin: 0 0 1rem;
}
@media (min-width: 640px) {
    .single-title { font-size: 2.25rem; }
}
.single-meta {
    font-size: 0.875rem;
    color: #64748b;
}
.single-meta__author { font-weight: 500; color: #475569; }
.single-meta__sep { margin: 0 0.35rem; opacity: 0.7; }
.single-meta__comments { color: #64748b; text-decoration: none; }
.single-meta__comments:hover { color: #0284c7; }
.single-featured {
    margin: 2rem 0;
    border-radius: 8px;
    overflow: hidden;
    background: #f8fafc;
}
.single-featured__img { width: 100%; height: auto; display: block; }
.single-featured__caption {
    font-size: 0.8125rem;
    color: #64748b;
    padding: 0.75rem 1rem;
    text-align: center;
    border-top: 1px solid #e2e8f0;
}

/* ========== برگه (صفحه) — طراحی تمیز بدون خلاصه ========== */
.page-main {
    min-height: 50vh;
    padding-bottom: 3rem;
}

/* هدر برگه: نوار کم‌رنگ + عنوان */
.page-hero {
    background: linear-gradient(180deg, var(--light-50) 0%, #fff 100%);
    border-bottom: 1px solid var(--slate-100);
    padding: 2rem 0 2.5rem;
}
@media (min-width: 640px) {
    .page-hero { padding: 2.5rem 0 3rem; }
}
.page-hero__inner {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .page-hero__inner { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .page-hero__inner { padding-left: 2rem; padding-right: 2rem; }
}

.page-breadcrumb {
    font-size: 0.8125rem;
    color: var(--slate-500);
    margin-bottom: 0.75rem;
}
.page-breadcrumb a {
    text-decoration: none !important;
    color: var(--slate-500);
    transition: color 0.2s;
}
.page-breadcrumb a:hover {
    color: var(--brand-600);
}
.page-breadcrumb__sep {
    margin: 0 0.35rem;
    opacity: 0.7;
}
.page-breadcrumb [aria-current="page"] {
    color: var(--slate-800);
    font-weight: 500;
}

.page-title {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1.25;
    color: var(--slate-800);
    letter-spacing: -0.02em;
}
@media (min-width: 640px) {
    .page-title { font-size: 2.25rem; }
}
@media (min-width: 1024px) {
    .page-title { font-size: 2.5rem; }
}

/* برگه — استایل مشابه Hesabix (کارت روی پس‌زمینه خاکستری) */
.page-wrap {
    min-height: 70vh;
    background-color: var(--slate-50);
}
.page-outer {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 2rem 1rem 2.5rem;
}
@media (min-width: 640px) {
    .page-outer { padding-left: 1.5rem; padding-right: 1.5rem; padding-top: 2.5rem; padding-bottom: 3rem; }
}
@media (min-width: 1024px) {
    .page-outer { padding-left: 2rem; padding-right: 2rem; }
}
.page-inner {
    max-width: 56rem;
    margin-left: auto;
    margin-right: auto;
}
.page-card {
    background: #fff;
    border-radius: var(--radius-2xl);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 2rem;
}
@media (min-width: 1024px) {
    .page-card { padding: 3rem; }
}
.page-wrap .page-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--slate-900);
    margin-bottom: 2rem;
    line-height: 1.3;
}
@media (min-width: 1024px) {
    .page-wrap .page-title { font-size: 2.25rem; }
}
.page-plain-content {
    width: 100%;
}
.page-prose {
    max-width: none;
    color: var(--slate-700);
    line-height: 1.75;
}
.page-prose p { margin-bottom: 1.25em; }
.page-prose h2 { font-size: 1.875em; font-weight: 700; margin-top: 2em; margin-bottom: 0.5em; color: var(--slate-800); }
.page-prose h3 { font-size: 1.5em; font-weight: 700; margin-top: 1.5em; margin-bottom: 0.5em; color: var(--slate-800); }
.page-prose ul, .page-prose ol { margin-bottom: 1.25em; padding-right: 1.625em; }
.page-prose li { margin-bottom: 0.5em; }
.page-prose a { color: var(--brand-600); text-decoration: underline; }
.page-prose a:hover { color: var(--brand-700); }
.page-prose img { max-width: 100%; height: auto; border-radius: var(--radius); margin: 1.5em 0; }
.page-prose blockquote {
    border-right: 4px solid var(--slate-200);
    padding-right: 1em;
    margin: 1.5em 0;
    font-style: italic;
    color: var(--slate-600);
}
.page-prose code {
    background-color: var(--slate-100);
    padding: 0.125em 0.375em;
    border-radius: 0.25rem;
    font-size: 0.875em;
}
.page-prose pre {
    background-color: var(--slate-800);
    color: var(--slate-100);
    padding: 1em;
    border-radius: var(--radius);
    overflow-x: auto;
    margin: 1.5em 0;
}
.page-prose pre code { background: none; padding: 0; color: inherit; }

/* بدنه محتوا (قالب قدیمی — نگه‌داری برای سازگاری) */
.page-body {
    background: #fff;
    padding: 2rem 0 2.5rem;
}
@media (min-width: 640px) {
    .page-body { padding: 2.5rem 0 3rem; }
}
.page-body__inner {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .page-body__inner { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .page-body__inner { padding-left: 2rem; padding-right: 2rem; }
}

.page-featured {
    margin: 0 0 2rem 0;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid var(--slate-100);
}
.page-featured__img {
    display: block;
    width: 100%;
    height: auto;
    vertical-align: middle;
}
.page-featured__caption {
    font-size: 0.875rem;
    color: var(--slate-500);
    text-align: center;
    padding: 0.75rem 1rem;
    background: var(--slate-50);
    border-top: 1px solid var(--slate-100);
}

/* عرض محتوای برگه از ظرف (page-body__inner) تبعیت می‌کند؛ محدودیت ch حذف شد */

/* صفحه‌بندی چندصفحه‌ای */
.page-pagination {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--slate-200);
}
.page-pagination__label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--slate-600);
    margin: 0 0 0.75rem 0;
}
.page-pagination__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.page-pagination__list li { margin: 0; }
.page-pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.25rem;
    height: 2.25rem;
    padding: 0 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--slate-700);
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    text-decoration: none !important;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.page-pagination a:hover {
    background: var(--brand-500);
    color: #fff;
    border-color: var(--brand-500);
}

/* زیرصفحات */
.page-children {
    background: var(--slate-50);
    border-top: 1px solid var(--slate-100);
    padding: 2rem 0 2.5rem;
}
.page-children__inner {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .page-children__inner { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .page-children__inner { padding-left: 2rem; padding-right: 2rem; }
}
.page-children__title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--slate-800);
    margin: 0 0 1rem 0;
}
.page-children__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: 1fr;
}
@media (min-width: 640px) {
    .page-children__list { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
    .page-children__list { grid-template-columns: repeat(3, 1fr); }
}
.page-children__link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: #fff;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    text-decoration: none !important;
    color: var(--slate-800);
    font-weight: 500;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.page-children__link:hover {
    border-color: var(--brand-400);
    box-shadow: var(--shadow);
}
.page-children__icon {
    width: 2.25rem;
    height: 2.25rem;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--brand-600);
    background: var(--light-100);
    border-radius: var(--radius);
}
.page-children__text {
    flex: 1;
    min-width: 0;
}

/* نظرات در برگه */
.page-comments {
    background: #fff;
    border-top: 1px solid var(--slate-100);
    padding: 2rem 0 2.5rem;
}
.page-comments__inner {
    max-width: min(var(--max-width), 100%);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px) {
    .page-comments__inner { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
    .page-comments__inner { padding-left: 2rem; padding-right: 2rem; }
}

.single-content,
.page-content {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--slate-700);
}
.single-content { max-width: 65ch; }
.page-content { max-width: 100%; }
.single-content h2, .page-content h2 { font-size: 1.375rem; font-weight: 700; color: var(--slate-800); margin: 2rem 0 0.75rem; line-height: 1.35; }
.single-content h3, .page-content h3 { font-size: 1.125rem; font-weight: 700; color: var(--slate-800); margin: 1.5rem 0 0.5rem; }
.single-content p, .page-content p { margin-bottom: 1.25rem; }
.single-content a, .page-content a { color: var(--brand-600); text-decoration: none; }
.single-content a:hover, .page-content a:hover { text-decoration: underline; }
.single-content img, .page-content img { max-width: 100%; height: auto; border-radius: var(--radius); }
.single-content ul, .single-content ol, .page-content ul, .page-content ol { margin: 1rem 0 1.25rem 1.5rem; }
.single-content li, .page-content li { margin-bottom: 0.35rem; }
.single-content blockquote, .page-content blockquote {
    margin: 1.5rem 0;
    padding: 1rem 1.25rem 1rem 1.5rem;
    border-right: 4px solid #0ea5e9;
    background: #f8fafc;
    color: #475569;
    font-style: italic;
}
.single-footer { margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid #e2e8f0; }
.single-footer__label { font-size: 0.8125rem; color: #64748b; margin-left: 0.5rem; }
.single-tag {
    display: inline-block;
    font-size: 0.8125rem;
    color: #64748b;
    background: #f1f5f9;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    text-decoration: none;
    margin: 0.25rem 0.25rem 0 0;
}
.single-tag:hover { background: #e2e8f0; color: #475569; }
.single-pages { margin-top: 1.5rem; font-size: 0.875rem; }
.single-pages ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* ناوبری پست قبلی/بعدی */
.single-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}
.single-nav__item {
    display: block;
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, background 0.2s;
}
.single-nav__item:hover { border-color: #cbd5e1; background: #f8fafc; }
.single-nav__label { display: block; font-size: 0.75rem; color: #94a3b8; margin-bottom: 0.35rem; }
.single-nav__title { font-size: 0.9375rem; font-weight: 600; color: #0f172a; line-height: 1.4; }
.single-nav__item:hover .single-nav__title { color: #0284c7; }
.single-nav__prev { text-align: right; }
.single-nav__next { text-align: left; }

.post-content code {
    background: #f1f5f9;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    font-size: 0.9em;
    color: #475569;
}
.post-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 1rem 1.25rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 1.5rem 0;
    font-size: 0.875rem;
    line-height: 1.6;
}
.post-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}
.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    align-items: center;
    margin-top: 2rem;
}
.nav-links a,
.nav-links span {
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
}
.nav-links a {
    background: #e0f2fe;
    color: #0284c7;
    transition: background 0.2s, color 0.2s;
}
.nav-links a:hover {
    background: #0ea5e9;
    color: white;
}
.pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    border-radius: 0.5rem;
    background: #e0f2fe;
    color: #0284c7;
    font-size: 0.875rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}
.pagination .page-numbers:hover,
.pagination .page-numbers.current {
    background: #0ea5e9;
    color: white;
}
.pagination .nav-links {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* ========== بخش نظرات ========== */
.single-comments {
    margin-top: 3rem;
    padding-top: 2.5rem;
    border-top: 1px solid #e2e8f0;
}
.single-comments__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 1.5rem;
}
.single-comments__list {
    list-style: none !important;
    margin: 0 0 2rem;
    padding: 0;
}
.single-comments__list .children {
    list-style: none !important;
    margin: 1rem 0 0 2.5rem;
    padding: 0;
    border-right: 2px solid #e2e8f0;
}

/* کارت نظر */
.single-comment {
    padding: 1.25rem 0;
    border-bottom: 1px solid #f1f5f9;
}
.single-comment:last-child { border-bottom: none; }
.single-comment__head {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}
.single-comment__avatar { flex-shrink: 0; }
.single-comment__avatar-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}
.single-comment__info { flex: 1; min-width: 0; }
.single-comment__author {
    font-weight: 600;
    font-style: normal;
}
.single-comment__author a {
    color: #0f172a;
    text-decoration: none;
}
.single-comment__author a:hover { color: #0284c7; }
.single-comment__date {
    font-size: 0.8125rem;
    color: #94a3b8;
}
.single-comment__moderation { font-size: 0.8125rem; color: #d97706; margin-top: 0.25rem; }
.single-comment__edit a { font-size: 0.75rem; color: #94a3b8; text-decoration: none; }
.single-comment__edit a:hover { color: #0284c7; }
.single-comment__text {
    margin-right: 3.25rem;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: #475569;
}
.single-comment__text p { margin: 0 0 0.5rem; }
.single-comment__text p:last-child { margin-bottom: 0; }
.single-comment__actions {
    margin-top: 0.75rem;
    margin-right: 3.25rem;
}
.single-comment__actions .comment-reply-link {
    font-size: 0.8125rem;
    color: #64748b;
    text-decoration: none;
}
.single-comment__actions .comment-reply-link:hover { color: #0284c7; }

/* فرم نظر */
.single-comments__form-wrap { margin-top: 2rem; }
.single-comments__form-title {
    font-size: 1rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0 0 1rem;
}
.single-comment-form .comment-form-author,
.single-comment-form .comment-form-email,
.single-comment-form .comment-form-url,
.single-comment-form__field {
    margin-bottom: 1rem;
}
.single-comment-form label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: #475569;
    margin-bottom: 0.35rem;
}
.single-comment-form .required { color: #dc2626; }
.single-comment-form input[type="text"],
.single-comment-form input[type="email"],
.single-comment-form input[type="url"],
.single-comment-form__textarea {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.9375rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #fff;
    color: #334155;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.single-comment-form input:focus,
.single-comment-form__textarea:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.15);
}
.single-comment-form__textarea {
    min-height: 100px;
    resize: vertical;
}
.single-comment-submit {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #fff !important;
    background: #0f172a !important;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}
.single-comment-submit:hover { background: #1e293b !important; }
.single-comment-form .form-submit { margin: 1.25rem 0 0; }
.single-comments__closed {
    text-align: center;
    color: #64748b;
    font-size: 0.9375rem;
    padding: 1.5rem;
}

/* ========== WeDocs — راهنمای داکیومنت ========== */
body.is-wedocs .wedocs-outer { padding-top: 1.5rem; padding-bottom: 3rem; }

/* سایدبار — سازگار با RTL و فارسی */
.wedocs-single-wrap .wedocs-sidebar {
    direction: rtl;
    font-family: inherit;
    line-height: 1.6;
    border-left: 1px solid #e2e8f0;
}
@media (min-width: 1024px) {
    .wedocs-single-wrap .wedocs-sidebar {
        border-left: none;
        border-right: 1px solid #e2e8f0;
        width: 18rem;
    }
}

/* لیست ناوبری درختی */
.wedocs-single-wrap .wedocs-sidebar .doc-nav-list,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li {
    margin: 0;
    position: relative;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li a {
    display: flex;
    align-items: center;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    color: #475569;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
    position: relative;
    font-size: 0.9375rem;
    line-height: 1.5;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li a:hover {
    background: #e0f2fe;
    color: #0284c7;
}

/* فلش باز/بسته — RTL: بسته = راست (به‌سمت فرزندان)، باز = پایین */
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li a .wedocs-caret {
    flex-shrink: 0;
    width: 0;
    height: 0;
    border: 4px solid transparent;
    border-left: 5px solid currentColor;
    border-right: none;
    margin-left: 0.35rem;
    transition: transform 0.2s ease;
    background: none !important;
    font-size: 0 !important;
}
/* باز: فلش رو به پایین */
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li.wd-state-open > a > .wedocs-caret {
    transform: rotate(-90deg);
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li.wd-state-closed ul.children {
    display: none;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_parent > a,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_item > a,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_ancestor > a {
    background: #0ea5e9;
    color: #fff;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_parent > a .wedocs-caret,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_item > a .wedocs-caret,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_ancestor > a .wedocs-caret {
    border-left-color: #fff;
}

/* سطح اول */
.wedocs-single-wrap .wedocs-sidebar .doc-nav-list > ul.doc-nav-list > li {
    margin-bottom: 0.25rem;
}

/* زیرمنوها — تورفتگی از راست برای RTL */
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children {
    list-style: none;
    padding: 0;
    margin: 0.25rem 0 0.5rem 0;
    padding-right: 1rem;
    margin-right: 0.5rem;
    border-right: 2px solid #e2e8f0;
    position: relative;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children li {
    margin: 0;
    position: relative;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children li:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 1rem;
    right: -1rem;
    width: 0.625rem;
    height: 2px;
    background: #e2e8f0;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children a {
    font-size: 0.875rem;
    color: #64748b;
    padding: 0.4rem 0.5rem 0.4rem 0.75rem;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children a:hover {
    color: #0284c7;
}

/* سطوح تو در تو */
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children ul.children {
    padding-right: 1rem;
    margin-right: 0.5rem;
    margin-top: 0.25rem;
    border-right-color: #cbd5e1;
}
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list li ul.children ul.children li:not(:last-child)::after {
    right: -1rem;
}

.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_parent li.current_page_item > a,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_item li.current_page_item > a,
.wedocs-single-wrap .wedocs-sidebar ul.doc-nav-list > li.current_page_ancestor li.current_page_item > a {
    color: #0284c7;
    font-weight: 600;
}

/* سایدبار فقط در دسکتاپ */
@media (max-width: 1023px) {
    .wedocs-sidebar.wedocs-hide-mobile { display: none !important; }
}

/* نان (breadcrumb) */
.wedocs-single-content ol.wedocs-breadcrumb {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem 0;
    font-size: 0.875rem;
    color: #64748b;
}
.wedocs-single-content ol.wedocs-breadcrumb li {
    display: inline;
}
.wedocs-single-content ol.wedocs-breadcrumb li.delimiter {
    margin: 0 0.35rem;
    color: #cbd5e1;
}
.wedocs-single-content ol.wedocs-breadcrumb a {
    color: #64748b;
    text-decoration: none;
}
.wedocs-single-content ol.wedocs-breadcrumb a:hover {
    color: #0ea5e9;
}

/* محتوای مقاله */
.wedocs-entry-content h2 { font-size: 1.25rem; margin: 1.5rem 0 0.75rem; color: #0f172a; }
.wedocs-entry-content h3 { font-size: 1.125rem; margin: 1.25rem 0 0.5rem; color: #1e293b; }
.wedocs-entry-content pre,
.wedocs-entry-content code { background: #f1f5f9; padding: 0.2em 0.4em; border-radius: 0.375rem; font-size: 0.875em; }
.wedocs-entry-content pre { padding: 1rem; overflow-x: auto; margin: 1rem 0; }
.wedocs-entry-content a { color: #0ea5e9; }
.wedocs-entry-content a:hover { text-decoration: underline; }
.wedocs-entry-content .article-child ul { list-style: disc; padding-right: 1.5rem; }
.wedocs-entry-content .article-child a { color: #0ea5e9; }

/* ناوبری قبلی/بعدی */
.wedocs-doc-nav { margin: 1.5rem 0; padding: 1rem 0; border-top: 1px solid #e2e8f0; display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
.wedocs-doc-nav a { color: #0ea5e9; text-decoration: none; font-weight: 500; }
.wedocs-doc-nav a:hover { text-decoration: underline; }

/* مودال جستجو — به‌طور پیش‌فرض مخفی؛ فقط با کلیک یا Ctrl+K نمایش داده شود */
#wedocs-single-doc-search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 200;
    background-color: rgba(0, 0, 0, 0.4);
    align-items: flex-start;
    justify-content: center;
    padding: 12vh 1rem;
    overflow-y: auto;
}
#wedocs-single-doc-search-modal.active {
    display: flex;
}
#wedocs-single-doc-search-modal .doc-search-modal { max-width: 560px; margin: 0 auto; width: 100%; }
#wedocs-single-doc-search-modal .doc-search-hits .doc-search-hit a { color: #0f172a; text-decoration: none; padding: 0.5rem 0; display: block; }
#wedocs-single-doc-search-modal .doc-search-hits .doc-search-hit a:hover { color: #0ea5e9; }
.wedocs-shortcode-wrap ul.wedocs-doc-sections ul.children:not(.active) { display: none; }
.wedocs-shortcode-wrap ul.wedocs-doc-sections ul.children { margin: 0.25rem 0 0.25rem 1rem; padding: 0; list-style: circle; }
.wedocs-shortcode-wrap ul.wedocs-doc-sections ul.children li { margin: 0.25rem 0; }
