/* هسته استایل مدرن و فوق‌سبک قالب آیین فطرت v1.3.0 — فونت وزیرمتن + طراحی شکیل */
:root {
	--af-primary: #5fad35;
	--af-primary-dark: #28510e;
	--af-primary-soft: #eef8e8;
	--af-red: #ef394e;
	--af-cyan: #0ea5b7;
	--af-bg: #f5f7fa;
	--af-surface: #ffffff;
	--af-text: #1e293b;
	--af-muted: #64748b;
	--af-border: #e2e8f0;
	--af-radius: 16px;
	--af-radius-sm: 11px;
	--af-shadow: 0 6px 24px rgba(15, 23, 42, 0.06);
	--af-font: 'Vazirmatn', Tahoma, system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; max-width: 100%; }
body {
	margin: 0;
	font-family: var(--af-font) !important;
	background: var(--af-bg);
	color: var(--af-text);
	line-height: 1.75;
	font-size: 14.5px;
	direction: rtl;
	overflow-x: clip;
	max-width: 100%;
	-webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5, h6, p, a, li, span, div, button, input, select, textarea, .woocommerce {
	font-family: var(--af-font);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--af-primary-dark); text-decoration: none; transition: all .2s ease; }
a:hover { color: var(--af-primary); }
button, input, select, textarea { font-size: inherit; }

.af-container { width: 100%; max-width: 1340px; margin: 0 auto; padding: 0 18px; }
.af-page-pad { padding-top: 28px; padding-bottom: 52px; }
.af-muted { color: var(--af-muted); }

/* دکمه‌های مدرن و لمسی */
.af-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	padding: 11px 20px; border-radius: 12px; font-weight: 700; font-size: 14px;
	border: 1.5px solid transparent; cursor: pointer; transition: all .2s ease; text-align: center;
	line-height: 1.4;
}
.af-btn-block { width: 100%; }
.af-btn-primary {
	background: linear-gradient(135deg, var(--af-primary), #4e9a28); color: #fff;
	box-shadow: 0 4px 14px rgba(95, 173, 53, 0.28);
}
.af-btn-primary:hover {
	background: linear-gradient(135deg, var(--af-primary-dark), #356c15); color: #fff;
	transform: translateY(-1px); box-shadow: 0 6px 18px rgba(40, 81, 14, 0.32);
}
.af-btn-outline { background: #fff; color: var(--af-primary-dark); border-color: #cbe3be; }
.af-btn-outline:hover { background: var(--af-primary-soft); border-color: var(--af-primary); color: var(--af-primary-dark); }
.af-btn-ghost { background: #f1f5f9; color: var(--af-text); }
.af-btn-ghost:hover { background: #e2e8f0; }

/* نوار اطلاع‌رسانی بالا */
.af-topbar {
	background: linear-gradient(90deg, var(--af-primary-dark), #3b761c);
	color: #fff; font-size: 13px; padding: 8px 0; text-align: center; font-weight: 500;
}
.af-topbar a { color: #fff; font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }

/* هدر مدرن شیشه‌ای */
.af-header {
	background: rgba(255, 255, 255, 0.96);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border-bottom: 1px solid #e6ecf2;
	z-index: 900;
}
.af-header-sticky { position: sticky; top: 0; box-shadow: 0 4px 20px rgba(15,23,42,.05); }
.af-header-main { display: flex; align-items: center; gap: 20px; padding: 13px 0; }
.af-mobile-toggle {
	display: none; background: #f1f5f9; border: 1px solid #e2e8f0; border-radius: 11px;
	padding: 8px 9px; cursor: pointer; color: var(--af-text);
}
.af-brand { flex-shrink: 0; }
.af-logo-link { display: flex; align-items: center; gap: 11px; color: var(--af-text); }
.af-logo-img { max-height: 52px; width: auto; }
.af-logo-mark {
	width: 46px; height: 46px; border-radius: 13px;
	background: linear-gradient(135deg, var(--af-primary-soft), #dcf2d0);
	color: var(--af-primary-dark); display: grid; place-items: center;
}
.af-logo-text { display: flex; flex-direction: column; line-height: 1.35; }
.af-logo-text strong { font-size: 17.5px; font-weight: 800; color: var(--af-primary-dark); }
.af-logo-text small { font-size: 11.5px; color: var(--af-muted); font-weight: 500; }

/* جستجوی زنده آژاکس */
.af-search-wrap { position: relative; flex: 1; max-width: 580px; }
.af-search-form {
	display: flex; align-items: center; background: #f1f5f9; border-radius: 14px;
	border: 1.5px solid transparent; transition: all .2s ease; padding: 2px;
}
.af-search-form:focus-within { background: #fff; border-color: var(--af-primary); box-shadow: 0 0 0 4px rgba(95,173,53,.14); }
.af-search-input { flex: 1; border: none; background: transparent; padding: 10px 15px; outline: none; color: var(--af-text); font-size: 14px; }
.af-search-btn {
	border: none; background: var(--af-primary); color: #fff; border-radius: 11px;
	width: 38px; height: 38px; margin-left: 3px; cursor: pointer; display: grid; place-items: center;
	transition: background .2s;
}
.af-search-btn:hover { background: var(--af-primary-dark); }
.af-search-results {
	position: absolute; top: calc(100% + 8px); right: 0; left: 0; background: #fff;
	border: 1px solid var(--af-border); border-radius: 14px; box-shadow: 0 18px 42px rgba(15,23,42,.15);
	z-index: 1000; max-height: 440px; overflow-y: auto; padding: 8px;
}
.af-sr-item { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 11px; color: var(--af-text); }
.af-sr-item:hover { background: var(--af-bg); }
.af-sr-item img { width: 46px; height: 60px; object-fit: cover; border-radius: 7px; flex-shrink: 0; }
.af-sr-meta { flex: 1; min-width: 0; }
.af-sr-meta strong { display: block; font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.af-sr-meta small { display: block; color: var(--af-muted); font-size: 12px; }
.af-sr-price { font-size: 13px; font-weight: 700; color: var(--af-primary-dark); white-space: nowrap; }
.af-sr-all { display: block; text-align: center; padding: 11px; font-weight: 700; border-top: 1px solid var(--af-border); margin-top: 6px; color: var(--af-primary); }

/* دکمه‌های حساب کاربری و سبد خرید */
.af-header-actions { display: flex; align-items: center; gap: 10px; margin-right: auto; }
.af-account-dropdown-wrap { position: relative; }
.af-account-btn {
	display: inline-flex; align-items: center; gap: 8px; padding: 9px 15px;
	border: 1.5px solid #e2e8f0; border-radius: 12px; color: var(--af-text);
	font-weight: 700; font-size: 13.5px; background: #fff;
}
.af-account-btn:hover { border-color: var(--af-primary); color: var(--af-primary-dark); background: var(--af-primary-soft); }
.af-account-dropdown {
	position: absolute; top: calc(100% + 8px); left: 0; min-width: 215px; background: #fff;
	border: 1px solid var(--af-border); border-radius: 14px; box-shadow: 0 14px 36px rgba(15,23,42,.13);
	padding: 8px; display: none; z-index: 999;
}
.af-account-dropdown-wrap:hover .af-account-dropdown { display: block; }
.af-account-dropdown a { display: block; padding: 9px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 600; color: var(--af-text); }
.af-account-dropdown a:hover { background: var(--af-primary-soft); color: var(--af-primary-dark); }
.af-account-dropdown .af-logout-link { color: var(--af-red); border-top: 1px solid #f1f5f9; margin-top: 5px; padding-top: 10px; }

.af-cart-trigger {
	position: relative; display: inline-flex; align-items: center; justify-content: center;
	width: 46px; height: 44px; border-radius: 12px; border: 1.5px solid #cde8be;
	background: var(--af-primary-soft); color: var(--af-primary-dark); cursor: pointer;
	transition: all .2s ease;
}
.af-cart-trigger:hover { background: var(--af-primary); color: #fff; border-color: var(--af-primary); transform: translateY(-1px); }
.af-cart-count {
	position: absolute; top: -6px; left: -6px; min-width: 22px; height: 22px; padding: 0 5px;
	border-radius: 99px; background: var(--af-red); color: #fff; font-size: 11.5px; font-weight: 800;
	display: grid; place-items: center; box-shadow: 0 2px 8px rgba(239,57,78,.35);
}

/* نوار ناوبری و مگامنو شکیل */
.af-nav-bar { border-top: 1px solid #f1f5f9; background: #fff; }
.af-nav-inner { display: flex; align-items: center; justify-content: space-between; min-height: 50px; }
.af-main-menu { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.af-main-menu > li { position: relative; }
.af-main-menu > li > a {
	display: flex; align-items: center; gap: 5px; padding: 12px 15px; font-weight: 700;
	font-size: 13.8px; color: #334155; border-radius: 10px; position: relative;
}
.af-main-menu > li > a:hover, .af-main-menu > li.current-menu-item > a {
	color: var(--af-primary-dark); background: var(--af-primary-soft);
}
.af-main-menu > li.menu-item-has-children > a::after {
	content: '▾'; font-size: 11px; opacity: .65; margin-right: 2px;
}
.af-main-menu .sub-menu {
	position: absolute; top: calc(100% + 4px); right: 0; min-width: 235px; background: #fff;
	border: 1px solid #e2e8f0; border-radius: 14px; box-shadow: 0 18px 44px rgba(15,23,42,.13);
	padding: 8px; list-style: none; opacity: 0; visibility: hidden; pointer-events: none;
	transform: translateY(8px); transition: opacity .18s ease, transform .18s ease, visibility .18s; z-index: 950;
}
.af-main-menu li:hover > .sub-menu,
.af-main-menu li:focus-within > .sub-menu {
	opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0);
}
.af-main-menu .sub-menu li { position: relative; }
.af-main-menu .sub-menu a {
	display: flex; align-items: center; justify-content: space-between; gap: 8px;
	padding: 9px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 500; color: #334155;
}
.af-main-menu .sub-menu a:hover { background: var(--af-primary-soft); color: var(--af-primary-dark); font-weight: 700; }
.af-main-menu .sub-menu li.menu-item-has-children > a::after {
	content: '‹'; font-size: 16px; font-weight: 700; opacity: .55; line-height: 1;
}
/* باز شدن زیرمنوهای سطح دوم و سوم دقیقاً روبه‌رو در سمت چپ (RTL Flyout) */
.af-main-menu .sub-menu .sub-menu {
	top: -8px;
	right: calc(100% + 6px);
	left: auto;
	transform: translateX(8px);
	z-index: 960;
}
/* پل نامرئی برای جلوگیری از بسته شدن زیرمنو هنگام حرکت ماوس به سمت چپ */
.af-main-menu .sub-menu .sub-menu::before {
	content: '';
	position: absolute;
	top: 0;
	bottom: 0;
	right: -12px;
	width: 12px;
}
.af-main-menu .sub-menu li:hover > .sub-menu,
.af-main-menu .sub-menu li:focus-within > .sub-menu {
	opacity: 1; visibility: visible; pointer-events: auto; transform: translateX(0);
}
/* مگامنو برای آیتم‌های دارای کلاس af-mega-menu */
.af-main-menu > li.af-mega-menu > .sub-menu {
	display: grid; grid-template-columns: repeat(3, minmax(180px, 1fr)); gap: 14px; min-width: 600px; padding: 18px;
}
.af-main-menu > li.af-mega-menu > .sub-menu > li > a {
	font-weight: 800; color: var(--af-primary-dark); border-bottom: 2px solid var(--af-primary-soft);
	margin-bottom: 6px; border-radius: 0; padding-bottom: 7px;
}
.af-main-menu > li.af-mega-menu > .sub-menu > li > a::after { display: none; }
.af-main-menu > li.af-mega-menu .sub-menu .sub-menu {
	position: static; top: auto; right: auto; opacity: 1; visibility: visible; pointer-events: auto;
	transform: none; box-shadow: none; border: none; padding: 0; min-width: 0;
}
.af-main-menu > li.af-mega-menu .sub-menu .sub-menu::before { display: none; }
.af-nav-cta {
	display: inline-flex; align-items: center; gap: 6px; padding: 7px 16px; border-radius: 99px;
	background: linear-gradient(135deg, #ef394e, #d9263c); color: #fff; font-weight: 700; font-size: 13px;
	box-shadow: 0 4px 12px rgba(239,57,78,.25);
}
.af-nav-cta:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 6px 16px rgba(239,57,78,.34); }

/* کارت کتاب مدرن */
.af-products-grid { display: grid; gap: 18px; }
.af-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.af-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.af-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.af-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }

.af-book-card {
	background: #fff; border: 1px solid #e6ecf2; border-radius: var(--af-radius);
	padding: 13px; display: flex; flex-direction: column; transition: all .22s ease;
	position: relative;
}
.af-book-card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px rgba(15,23,42,.09); border-color: #cde8be; }
.af-book-thumb-wrap { position: relative; aspect-ratio: 3/4; background: #f8fafc; border-radius: 12px; overflow: hidden; margin-bottom: 12px; display: grid; place-items: center; }
.af-book-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 8px; transition: transform .3s ease; }
.af-book-card:hover .af-book-thumb img { transform: scale(1.05); }
.af-discount-badge {
	position: absolute; top: 9px; right: 9px; background: linear-gradient(135deg, #ef394e, #d9263c); color: #fff;
	font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 99px; z-index: 2;
}
.af-stock-badge {
	position: absolute; bottom: 9px; right: 9px; background: rgba(15,23,42,.78); color: #fff;
	font-size: 11.5px; padding: 3px 9px; border-radius: 7px; z-index: 2;
}
.af-qv-trigger {
	position: absolute; top: 9px; left: 9px; width: 34px; height: 34px; border-radius: 50%;
	border: 1px solid var(--af-border); background: rgba(255,255,255,.95); color: var(--af-text);
	display: grid; place-items: center; cursor: pointer; opacity: 0; transition: all .2s; z-index: 2;
}
.af-book-card:hover .af-qv-trigger { opacity: 1; }
.af-book-body { display: flex; flex-direction: column; flex: 1; }
.af-book-title { margin: 0 0 5px; font-size: 14.2px; line-height: 1.55; font-weight: 700; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.af-book-title a { color: var(--af-text); }
.af-book-title a:hover { color: var(--af-primary); }
.af-book-sub { margin: 0 0 10px; font-size: 12px; color: var(--af-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.af-book-footer { margin-top: auto; padding-top: 11px; border-top: 1px solid #f1f5f9; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.af-book-price { font-size: 14px; font-weight: 800; color: var(--af-primary-dark); line-height: 1.3; }
.af-book-price del { display: block; font-size: 11.5px; color: var(--af-muted); font-weight: 400; }
.af-book-price ins { text-decoration: none; color: var(--af-primary-dark); }
.af-add-btn {
	display: inline-flex; align-items: center; gap: 5px; padding: 7px 13px; border-radius: 10px;
	background: var(--af-primary); color: #fff; border: none; font-size: 12.8px; font-weight: 700;
	cursor: pointer; white-space: nowrap; transition: all .2s;
}
.af-add-btn:hover { background: var(--af-primary-dark); color: #fff; transform: translateY(-1px); }
.af-add-btn-outline { background: #f1f5f9; color: var(--af-text); }

/* کشوها (منوی موبایل و سبد خرید کشویی با اسکرول ۱۰۰٪ تضمینی برای محصولات زیاد) */
.af-drawer-backdrop { position: fixed; inset: 0; background: rgba(15,23,42,.52); backdrop-filter: blur(2px); z-index: 1100; }
.af-mobile-drawer, .af-cart-drawer {
	position: fixed; top: 0; bottom: 0; height: 100vh; height: 100dvh; max-height: 100dvh;
	width: 390px; max-width: 92vw; background: #fff; z-index: 1200;
	display: flex; flex-direction: column; overflow: hidden;
	transition: transform .26s cubic-bezier(.4,0,.2,1); box-shadow: 0 0 40px rgba(15,23,42,.22);
}
.af-mobile-drawer, .af-cart-drawer {
	display: none !important;
	visibility: hidden;
	pointer-events: none;
}
.af-mobile-drawer { right: 0; }
.af-cart-drawer { left: 0; }
.af-mobile-drawer.is-open, .af-cart-drawer.is-open {
	display: flex !important;
	visibility: visible;
	pointer-events: auto;
	transform: none;
}
.af-drawer-backdrop[hidden] { display: none !important; }
.af-drawer-head {
	flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between;
	padding: 16px 20px; border-bottom: 1px solid #e6ecf2; background: #fff;
}
.af-drawer-title-group { display: flex; align-items: center; gap: 10px; }
.af-drawer-title-group strong { font-size: 16px; font-weight: 800; color: var(--af-text); }
.af-drawer-pill-count { background: var(--af-primary-soft); color: var(--af-primary-dark); font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.af-drawer-close {
	background: #f1f5f9; border: none; width: 34px; height: 34px; border-radius: 10px;
	font-size: 21px; line-height: 1; cursor: pointer; color: #475569; display: grid; place-items: center;
}
.af-drawer-close:hover { background: #fee2e2; color: var(--af-red); }
.af-drawer-body {
	flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch; padding: 16px 18px; background: #f8fafc;
}
.af-drawer-foot {
	flex: 0 0 auto; padding: 16px 18px; border-top: 1px solid #e6ecf2;
	background: #fff; box-shadow: 0 -6px 20px rgba(15,23,42,.05);
}
.af-mobile-menu { list-style: none; margin: 0; padding: 0; }
.af-mobile-menu a { display: block; padding: 11px 10px; border-bottom: 1px solid #edf2f7; color: var(--af-text); font-weight: 600; }
.af-mobile-menu .sub-menu { list-style: none; padding-right: 18px; margin: 0; }

/* آیتم‌های مدرن سبد خرید کشویی */
.af-mini-cart-empty { text-align: center; padding: 44px 16px; }
.af-mc-empty-ico { font-size: 46px; margin-bottom: 10px; opacity: .75; }
.af-mini-cart-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.af-mc-item {
	display: flex; align-items: stretch; gap: 12px; background: #fff;
	border: 1px solid #e6ecf2; border-radius: 13px; padding: 11px;
	box-shadow: 0 2px 8px rgba(15,23,42,.03);
}
.af-mc-thumb-link { flex-shrink: 0; }
.af-mc-thumb { width: 58px; height: 76px; object-fit: cover; border-radius: 8px; background: #f1f5f9; }
.af-mc-info { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-between; gap: 8px; }
.af-mc-top-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.af-mc-title {
	font-size: 13.5px; font-weight: 700; color: var(--af-text); line-height: 1.45;
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.af-mc-remove {
	border: none; background: #fff1f2; color: var(--af-red); width: 28px; height: 28px;
	border-radius: 8px; cursor: pointer; display: grid; place-items: center; flex-shrink: 0;
}
.af-mc-remove:hover { background: var(--af-red); color: #fff; }
.af-mc-bottom-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.af-mc-qty {
	display: inline-flex; align-items: center; gap: 6px; background: #f1f5f9;
	border: 1px solid #e2e8f0; border-radius: 9px; padding: 2px 4px;
}
.af-mc-qty-btn {
	border: none; background: #fff; color: var(--af-text); width: 24px; height: 24px;
	border-radius: 7px; cursor: pointer; font-weight: 800; font-size: 15px; display: grid; place-items: center;
}
.af-mc-qty-btn:hover { background: var(--af-primary); color: #fff; }
.af-mc-qty-val { min-width: 22px; text-align: center; font-weight: 700; font-size: 13.5px; }
.af-mc-price { font-size: 13.5px; color: var(--af-primary-dark); font-weight: 800; white-space: nowrap; }
.af-mc-total { display: flex; justify-content: space-between; align-items: center; margin-bottom: 13px; font-size: 15px; }
.af-mc-total strong { font-size: 16.5px; color: var(--af-primary-dark); font-weight: 800; }
.af-mc-actions { display: grid; gap: 8px; }

/* مودال آژاکس افزودن به سبد و مشاهده سریع */
.af-modal { position: fixed; inset: 0; z-index: 1300; background: rgba(15,23,42,.56); backdrop-filter: blur(2px); display: grid; place-items: center; padding: 16px; }
.af-modal[hidden] { display: none; }
.af-modal-dialog {
	position: relative; background: #fff; border-radius: 18px; width: 100%; max-width: 480px;
	padding: 26px; box-shadow: 0 24px 54px rgba(15,23,42,.24);
}
.af-modal-lg { max-width: 700px; }
.af-modal-close { position: absolute; top: 14px; left: 14px; width: 34px; height: 34px; border: none; border-radius: 10px; background: #f1f5f9; font-size: 20px; cursor: pointer; }
.af-cm-badge { display: inline-block; background: var(--af-primary-soft); color: var(--af-primary-dark); font-weight: 700; padding: 5px 13px; border-radius: 99px; font-size: 13px; margin-bottom: 10px; }
.af-cm-title { margin: 0 0 14px; font-size: 16.5px; font-weight: 800; }
.af-cm-product { display: flex; gap: 14px; align-items: center; background: #f8fafc; padding: 13px; border-radius: 13px; margin-bottom: 18px; border: 1px solid #edf2f7; }
.af-cm-product img { width: 64px; height: 84px; object-fit: cover; border-radius: 8px; }
.af-cm-price { font-weight: 800; color: var(--af-primary-dark); margin-bottom: 6px; }
.af-cm-summary { font-size: 13px; color: var(--af-muted); }
.af-cm-actions { display: grid; gap: 9px; }
.af-qv-grid { display: grid; grid-template-columns: 220px 1fr; gap: 22px; align-items: start; }
.af-qv-info h3 { margin-top: 0; }
.af-qv-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

/* فوتر */
.af-footer { background: #eceff1; border-top: 1px solid #dfe5ec; margin-top: 52px; }
.af-footer-features { background: #fff; border-bottom: 1px solid var(--af-border); padding: 22px 0; }
.af-features-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.af-feature-item { display: flex; align-items: center; gap: 12px; }
.af-feat-ico { font-size: 26px; }
.af-feature-item strong { display: block; font-size: 13.8px; }
.af-feature-item small { color: var(--af-muted); font-size: 12px; }
.af-footer-main { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 24px; padding: 36px 18px; }
.af-footer-col h4 { margin: 0 0 14px; font-size: 15.5px; font-weight: 800; color: var(--af-primary-dark); }
.af-footer-menu { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.af-footer-menu a { color: #334155; font-size: 13.5px; font-weight: 500; }
.af-socials { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.af-socials a { background: #fff; padding: 6px 13px; border-radius: 9px; font-size: 12.5px; font-weight: 600; border: 1px solid var(--af-border); }
.af-footer-bottom { background: #d7dee0; padding: 14px 0; font-size: 13px; }
.af-footer-bottom-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.af-back-top { background: #fff; border: 1px solid #cbd5e1; padding: 6px 14px; border-radius: 9px; cursor: pointer; font-weight: 700; }
.af-footer-minimal { text-align: center; padding: 18px 0; color: var(--af-muted); font-size: 13px; }

/* برگه‌ها و وبلاگ */
.af-card, .af-page-article, .af-single-post { background: #fff; border: 1px solid #e6ecf2; border-radius: var(--af-radius); padding: 24px; }
.af-page-header { margin-bottom: 18px; border-bottom: 1px solid #f1f5f9; padding-bottom: 12px; }
.af-page-header h1 { margin: 0; font-size: 22px; font-weight: 800; }
.af-blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.af-post-card { background: #fff; border: 1px solid var(--af-border); border-radius: var(--af-radius); overflow: hidden; }
.af-post-body { padding: 16px; }
.af-post-title { margin: 0 0 8px; font-size: 16px; }
.af-pagination { margin-top: 26px; text-align: center; }
.af-empty-state { text-align: center; padding: 56px 20px; background: #fff; border-radius: var(--af-radius); border: 1px solid var(--af-border); }
.af-breadcrumb-bar { margin: 16px 0; font-size: 13px; color: var(--af-muted); }

/* امکانات پیشرفته: علاقه‌مندی‌ها، نوار ارسال رایگان، نمونه PDF، نوار پایین موبایل */
.af-wish-btn {
	position: absolute; top: 48px; left: 9px; width: 34px; height: 34px; border-radius: 50%;
	border: 1px solid var(--af-border); background: rgba(255,255,255,.95); color: #94a3b8;
	display: grid; place-items: center; cursor: pointer; z-index: 2; font-size: 16px; transition: all .2s;
}
.af-wish-btn:hover, .af-wish-btn.is-wished { color: var(--af-red); border-color: #fecdd3; background: #fff1f2; }
.af-sample-pdf-btn { width: 100%; margin-top: 12px; }
.af-ship-progress { background: var(--af-primary-soft); border: 1px solid #cce9bb; border-radius: 12px; padding: 11px 13px; margin-bottom: 14px; font-size: 12.8px; color: var(--af-primary-dark); }
.af-ship-bar { height: 7px; background: #dbead2; border-radius: 99px; overflow: hidden; margin-top: 7px; }
.af-ship-bar span { display: block; height: 100%; background: var(--af-primary); border-radius: 99px; transition: width .3s ease; }

.af-mobile-bottom-nav {
	display: none; position: fixed; bottom: 0; right: 0; left: 0; z-index: 980;
	background: rgba(255,255,255,.97); backdrop-filter: blur(8px);
	border-top: 1px solid var(--af-border); box-shadow: 0 -4px 18px rgba(15,23,42,.08);
	grid-template-columns: repeat(4, 1fr); padding: 7px 4px;
}
.af-mobile-bottom-nav a, .af-mobile-bottom-nav button {
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
	background: transparent; border: none; color: var(--af-muted); font-size: 11.5px; font-weight: 700;
	position: relative; cursor: pointer; padding: 3px 0;
}
.af-mobile-bottom-nav a.is-active { color: var(--af-primary-dark); }
.af-mobile-bottom-nav span { font-size: 19px; line-height: 1.1; }
.af-mbn-cart em {
	position: absolute; top: 0; left: 26%; min-width: 18px; height: 18px; border-radius: 99px;
	background: var(--af-red); color: #fff; font-style: normal; font-size: 10.5px; display: grid; place-items: center;
}

@media (max-width: 1024px) {
	.af-cols-4, .af-cols-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.af-footer-main { grid-template-columns: repeat(2, 1fr); }
	.af-features-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
	.af-mobile-toggle { display: inline-flex; }
	.af-nav-bar { display: none; }
	.af-header-main { flex-wrap: wrap; gap: 10px; }
	.af-search-wrap { order: 3; flex-basis: 100%; max-width: none; }
	.af-account-label { display: none; }
	.af-cols-3, .af-cols-4, .af-cols-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.af-blog-grid, .af-footer-main, .af-qv-grid { grid-template-columns: 1fr; }
	.af-mobile-bottom-nav { display: grid; }
	body { padding-bottom: 68px; }
}

/* استایل پاپ‌آپ پیشرفته سبد خرید (لیست کامل کتاب‌های انتخاب‌شده با اسکرول داخلی) */
.af-cm-pro-dialog {
	max-width: 560px; padding: 0; overflow: hidden; display: flex; flex-direction: column;
	max-height: 88dvh;
}
.af-cm-head {
	display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
	padding: 18px 22px 14px; border-bottom: 1px solid #e6ecf2; background: #fff;
}
.af-cm-list-label {
	display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap;
	padding: 10px 22px; background: #f1f5f9; font-size: 13px; font-weight: 700; color: #334155;
}
.af-cm-list-label small { font-weight: 500; color: var(--af-muted); }
.af-cm-scroll-list {
	flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
	padding: 14px 20px; background: #f8fafc;
}
.af-cm-foot {
	flex: 0 0 auto; padding: 16px 22px 20px; background: #fff;
	border-top: 1px solid #e6ecf2; box-shadow: 0 -6px 20px rgba(15,23,42,.04);
}
.af-cm-btn-row { display: grid; grid-template-columns: 1.35fr 1fr .85fr; gap: 8px; }
@media (max-width: 600px) {
	.af-cm-btn-row { grid-template-columns: 1fr; }
}

/* بهینه‌سازی دقیق چیدمان موبایل و جلوگیری از اسکرول افقی */
.af-site-main { overflow-x: clip; max-width: 100%; }
@media (max-width: 768px) {
	.af-container { padding: 0 12px; }
	.af-header-main { padding: 10px 0; gap: 8px; }
	.af-logo-text strong { font-size: 15px; }
	.af-logo-text small { display: none; }
	.af-book-card { padding: 10px; }
	.af-book-title { font-size: 13px; }
	.af-book-footer { flex-direction: column; align-items: stretch; gap: 7px; }
	.af-add-btn { width: 100%; justify-content: center; padding: 8px 10px; }
	.af-products-grid { gap: 10px; }
}

/* استایل منوی همبرگری حرفه‌ای موبایل و فوتر ارتقایافته نسخه ۱.۸ */
.af-mob-head-brand { background: linear-gradient(135deg, #28510e, #5fad35); color: #fff; }
.af-mob-head-brand strong { color: #fff; }
.af-mob-head-brand .af-drawer-close { background: rgba(255,255,255,.2); color: #fff; }
.af-mob-user-card { background: #fff; border: 1px solid #e2e8f0; border-radius: 13px; padding: 11px 13px; margin-bottom: 12px; }
.af-mob-user-link { display: flex; align-items: center; gap: 10px; color: var(--af-text); }
.af-mob-u-ico { width: 38px; height: 38px; border-radius: 10px; background: var(--af-primary-soft); display: grid; place-items: center; font-size: 18px; flex-shrink: 0; }
.af-mob-user-link strong { display: block; font-size: 13.8px; }
.af-mob-user-link small { color: var(--af-primary); font-size: 12px; font-weight: 600; }
.af-mob-search { display: flex; background: #fff; border: 1.5px solid #e2e8f0; border-radius: 11px; overflow: hidden; margin-bottom: 12px; }
.af-mob-search input { flex: 1; border: none; padding: 9px 12px; outline: none; font-size: 13.5px; }
.af-mob-search button { border: none; background: var(--af-primary); color: #fff; padding: 0 13px; cursor: pointer; }
.af-mob-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; background: #e2e8f0; padding: 4px; border-radius: 11px; margin-bottom: 12px; }
.af-mob-tab { border: none; background: transparent; padding: 8px; border-radius: 8px; font-weight: 700; font-size: 13px; color: #475569; cursor: pointer; }
.af-mob-tab.is-active { background: #fff; color: var(--af-primary-dark); box-shadow: 0 2px 6px rgba(15,23,42,.08); }
.af-mob-panel { display: none; }
.af-mob-panel.is-active { display: block; }
.af-mob-cat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.af-mob-all-books { display: block; background: var(--af-primary-soft); color: var(--af-primary-dark); font-weight: 800; padding: 10px 13px; border-radius: 10px; font-size: 13.5px; }
.af-mob-acc-item { background: #fff; border: 1px solid #e6ecf2; border-radius: 11px; overflow: hidden; }
.af-mob-acc-row { display: flex; align-items: center; }
.af-mob-acc-row a { flex: 1; display: flex; justify-content: space-between; align-items: center; padding: 10px 13px; font-size: 13.5px; font-weight: 700; color: var(--af-text); }
.af-mob-acc-row a small { background: #f1f5f9; color: var(--af-muted); padding: 1px 7px; border-radius: 99px; font-size: 11.5px; }
.af-mob-acc-toggle { width: 38px; height: 38px; border: none; border-right: 1px solid #f1f5f9; background: #f8fafc; font-size: 17px; font-weight: 800; color: var(--af-primary-dark); cursor: pointer; }
.af-mob-sublist { display: none; list-style: none; margin: 0; padding: 6px 14px 10px; background: #f8fafc; border-top: 1px solid #f1f5f9; }
.af-mob-acc-item.is-open > .af-mob-sublist { display: block; }
.af-mob-sublist a { display: block; padding: 6px 6px; font-size: 13px; color: #334155; font-weight: 500; }

/* فوتر حرفه‌ای: نوار تصاویر افقی، شورت‌کد، کارت تماس و دکمه شناور بازگشت به بالا */
.af-footer-strip-wrap { background: #fff; padding: 20px 0; border-bottom: 1px solid var(--af-border); }
.af-footer-img-strip { display: grid; gap: 14px; }
.af-strip-cols-1 { grid-template-columns: 1fr; }
.af-strip-cols-2 { grid-template-columns: repeat(2, 1fr); }
.af-strip-cols-3 { grid-template-columns: repeat(3, 1fr); }
.af-strip-cols-4 { grid-template-columns: repeat(4, 1fr); }
.af-footer-strip-card { display: block; border-radius: 12px; overflow: hidden; border: 1px solid #e6ecf2; transition: transform .2s; }
.af-footer-strip-card:hover { transform: translateY(-2px); }
.af-footer-strip-card img { width: 100%; height: auto; object-fit: cover; }
.af-footer-shortcode-bar { background: #f1f5f9; padding: 18px 0; border-bottom: 1px solid #e2e8f0; }
.af-footer-contact-card { margin-top: 12px; background: #fff; border: 1px solid #dfe5ec; border-radius: 11px; padding: 10px 13px; font-size: 13px; display: grid; gap: 6px; }
.af-float-top {
	position: fixed; bottom: 80px; left: 18px; width: 42px; height: 42px; border-radius: 50%;
	border: none; background: var(--af-primary); color: #fff; font-size: 20px; font-weight: 800;
	cursor: pointer; z-index: 940; box-shadow: 0 8px 22px rgba(40,81,14,.3); display: grid; place-items: center;
}
.af-float-top[hidden] { display: none; }
.af-float-top:hover { background: var(--af-primary-dark); transform: translateY(-2px); }
@media (max-width: 768px) {
	.af-strip-cols-3, .af-strip-cols-4 { grid-template-columns: repeat(2, 1fr); }
}

/* اعمال سراسری فونت وزیرمتن روی تمام بخش‌ها و افزونه‌ها */
body, button, input, select, textarea, h1, h2, h3, h4, h5, h6,
.woocommerce, .woocommerce input, .woocommerce button, .woocommerce select, .woocommerce textarea,
.af-account-content, .af-account-sidebar {
	font-family: var(--af-font) !important;
}
/* بنرها و تصاویر بدون لینک: غیرقابل کلیک اما دارای افکت هاور زیبا */
.af-no-link { cursor: default !important; }
