/* ── باکسِ خرید پیشنهادی ─────────────────────────────────────────────── */
.plt-bt {
	padding: 18px;
	border: 2px solid var(--brdcolor-gray-300, #e5e8ec);
	border-radius: 14px;
	background: var(--bgcolor-white, #fff);
}

.plt-bt__title {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 14px;
	font-size: 15px;
	font-weight: 700;
	color: var(--color-gray-900, #1f2430);
}

.plt-bt__title-icon {
	font-size: 20px;
	line-height: 1;
	color: var(--pt-primary-color, #f05a4f);
}

/* سربرگ: عنوان سمتِ راست، نوارِ پیشرفتِ تخفیف سمتِ چپ */
.plt-bt__head {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px 18px;
	margin-bottom: 14px;
}
.plt-bt__head .plt-bt__title { margin-bottom: 0; flex: 0 0 auto; }

.plt-bt__progress {
	flex: 1 1 160px;
	min-width: 140px;
	max-width: 340px;
	margin: 0;
	margin-inline-start: auto;
}
.plt-bt__progress-label {
	display: block;
	margin-bottom: 6px;
	font-size: 12px;
	font-weight: 700;
	color: var(--pt-primary-color, #f05a4f);
	text-align: start;
	transition: color .3s ease;
}
.plt-bt__progress .progress-area { background-color: rgba(0, 0, 0, .07); }
.plt-bt__progress .progress-bar { transition: width .35s ease, background-color .35s ease; }
.plt-bt__progress.is-complete .plt-bt__progress-label { color: #16a34a; }
.plt-bt__progress.is-complete .progress-bar { background-color: #16a34a !important; }

/* دو ستونه در حالتِ پیش‌فرض (کارت‌ها جفت‌جفت کنارِ هم) */
.plt-bt__list {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 10px;
}

.plt-bt__item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px;
	border: 1px solid var(--brdcolor-gray-300, #eef0f4);
	border-radius: 12px;
	background: #fff;
	transition: border-color .15s ease;
}

.plt-bt__item.is-main { background: var(--bgcolor-gray-100, #f7f8fa); }
.plt-bt__item--need { border-color: #ef4444; }

/* چک‌باکسِ سفارشی */
	.plt-bt__check-wrap {
		position: relative;
		display: inline-flex;
		align-items: center;
		gap: 7px;
		margin-top: 6px;
		cursor: pointer;
	}
	.plt-bt__check-text {
		font-size: 12px;
		font-weight: 600;
		color: var(--pt-primary-color, #f05a4f);
		user-select: none;
	}
	.plt-bt__check { position: absolute; opacity: 0; width: 0; height: 0; }
	.plt-bt__check-box {
		width: 22px;
		height: 22px;
		border: 2px solid #c9ced9;
		border-radius: 6px;
		display: inline-block;
		position: relative;
		transition: all .15s ease;
	}
	.plt-bt__check:checked + .plt-bt__check-box {
		background: var(--pt-primary-color, #f05a4f);
		border-color: var(--pt-primary-color, #f05a4f);
	}
	.plt-bt__check:checked + .plt-bt__check-box::after {
		content: "";
		position: absolute;
		inset: 0;
		margin: auto;
		width: 6px;
		height: 11px;
		border: solid #fff;
		border-width: 0 2px 2px 0;
		transform: rotate(45deg) translate(-1px, -1px);
	}

	.plt-bt__main-badge {
		align-self: flex-start;
		margin-bottom: 2px;
		font-size: 11px;
		font-weight: 700;
		color: rgb(255 255 255);
		background: #535660;
		padding: 3px 8px;
		border-radius: 999px;
		white-space: nowrap;
	}

	/* تصویرِ شاخص — سمت چپ، با نسبتِ پیش‌فرضِ تامبنیلِ ووکامرس (۳:۴ ~ ۱۵۰×۲۰۰) */
	.plt-bt .plt-bt__thumb {
		order: 2;
		flex: 0 0 auto;
		display: block;
		width: 60px !important;
		height: 80px !important;
		min-height: 0 !important;
		padding: 0;
		border: 0;
		border-radius: 10px;
		background: #f0f1f4 center/cover no-repeat;
		cursor: pointer;
	}

	/* ترتیب در RTL: محتوا سمتِ راست، تصویر سمتِ چپ */
	.plt-bt__info { order: 1; }

.plt-bt__info { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1 1 auto; }
.plt-bt__name {
	font-size: 14px;
	font-weight: 600;
	color: var(--color-gray-900, #1f2430);
	line-height: 1.6;
}
.plt-bt__price { font-size: 13px; color: var(--color-gray-700, #51596a); }
.plt-bt__price del { opacity: .6; font-size: 12px; margin-inline-start: 6px; }
.plt-bt__price ins { text-decoration: none; }

/* واحدِ پول («تومان») بعد از عدد نمایش داده شود (نه قبل از آن) */
.plt-bt__price .woocommerce-Price-amount {
	display: inline-flex;
	align-items: baseline;
	gap: 3px;
}
.plt-bt__price .woocommerce-Price-currencySymbol { order: 2; }

.plt-bt__variation {
	margin-top: 4px;
	max-width: 220px;
	height: 34px;
	padding: 0 8px;
	border: 1px solid var(--brdcolor-gray-300, #e5e8ec);
	border-radius: 8px;
	background: #fff;
	font-size: 13px;
}

/* پا: جمع + دکمه */
.plt-bt__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	flex-wrap: wrap;
	margin-top: 16px;
	padding-top: 16px;
	border-top: 1px dashed var(--brdcolor-gray-300, #e5e8ec);
}
.plt-bt__total-label { font-size: 13px; color: var(--color-gray-700, #51596a); }
.plt-bt__total {
	font-size: 20px;
	font-weight: 800;
	color: var(--pt-primary-color, #f05a4f);
	margin-inline-start: 8px;
}

.plt-bt .plt-bt__add {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-width: 220px;
	height: 48px;
	padding: 0 22px;
	border: 0;
	border-radius: 12px;
	background: var(--pt-primary-color, #282835);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: filter .15s ease;
}
.plt-bt .plt-bt__add:hover { filter: brightness(.95); }
.plt-bt .plt-bt__add.is-loading { opacity: .7; pointer-events: none; }
.plt-bt .plt-bt__add .picon { font-size: 20px; line-height: 1; }

/* نوتیس‌ها از استایلِ پیش‌فرضِ پوسته (.pt-notice + .woocommerce-message/-error) می‌آیند؛ اینجا فقط فاصله‌ی بالا. */
.plt-bt__msg { margin-top: 12px; }

@media (max-width: 575px) {
	.plt-bt__list { grid-template-columns: 1fr; }
	.plt-bt__foot { flex-direction: column; align-items: stretch; }
	.plt-bt .plt-bt__add { width: 100%; }
}

/* ── Quick view ──────────────────────────────────────────────────────── */
/* ساختار از مودالِ مشترکِ .pt-popup (magnific) می‌آید؛ اینجا فقط محتوا و اندازه. */
.plt-bt-qv.pt-popup {
	--pt-popup-width: 880px;
	--pt-popup-padding: 25px;
	--pt-popup-brd-radius: 20px;
	border-radius: 20px;
	direction: rtl;
}

.plt-bt-qv__grid {
	display: grid;
	/* بدونِ گالری (فقط تصویرِ اصلی) */
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
	gap: 26px;
	align-items: start;
}
/* وقتی محصول گالری دارد، ستونِ رسانه عریض‌تر می‌شود */
.plt-bt-qv.has-gallery .plt-bt-qv__grid {
	grid-template-columns: minmax(0, 2fr) minmax(0, 1.1fr);
}

/* رسانه: کاروسلِ تامبنیل (کنار) + تصویرِ اصلی — مطابقِ اسکرین‌شات */
.plt-bt-qv__media {
	--plt-qv-thumb-w: 66px;
	min-width: 0;
	display: flex;
	gap: 12px;
	align-items: stretch;
}
.plt-bt-qv__main {
	flex: 1 1 auto;
	min-width: 0;
	border-radius: 16px;
	overflow: hidden;
	background: var(--bgcolor-gray-100, #f6f7f9);
	aspect-ratio: 3 / 4;
}
.plt-bt-qv__main-img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* کاروسلِ تامبنیل‌ها: ستونی، هم‌قدِ تصویرِ اصلی (فلش‌ها چسبیده به بالا/پایینِ کادر) */
.plt-bt-qv__gallery {
	flex: 0 0 var(--plt-qv-thumb-w);
	min-height: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
/* بدونِ تامبنیل: کلِ ستونِ گالری مخفی تا تصویرِ اصلی تمامِ عرض را بگیرد */
.plt-bt-qv__gallery:not(.has-thumbs) { display: none; }
.plt-bt-qv__gallery:not(.has-nav) .plt-bt-qv__nav { display: none; }

/* ناحیه‌ی تامبنیل‌ها بینِ دو فلش را پُر می‌کند و دقیقاً ۳ تامبنیل نشان می‌دهد */
.plt-bt-qv__track {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
	overflow: auto;
	scroll-snap-type: y mandatory;
	scrollbar-width: none;
	-ms-overflow-style: none;
}
.plt-bt-qv__track::-webkit-scrollbar { display: none; }
.plt-bt-qv__track:empty { display: none; }

.plt-bt-qv__gallery .plt-bt-qv__thumb {
	position: relative;
	flex: 0 0 auto;
	display: block; /* override برای جلوگیری از flexِ سراسریِ دکمه‌ها */
	width: 100%;
	/* دقیقاً ۳ تامبنیل در ارتفاعِ موجود: (۱۰۰٪ − ۲ فاصله) ÷ ۳ */
	height: calc((100% - 16px) / 3);
	padding: 0;
	border: 0;
	border-radius: 12px;
	overflow: hidden;
	background: var(--bgcolor-gray-100, #f0f1f4);
	cursor: pointer;
	scroll-snap-align: start;
}
.plt-bt-qv__thumb img { width: 100% !important; height: 100% !important; max-width: none !important; object-fit: cover; display: block; }

/* تامبنیلِ فعال: overlay رنگی به‌جای border */
.plt-bt-qv__gallery .plt-bt-qv__thumb.is-active::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
	background: var(--pt-primary-color, #f05a4f);
	opacity: .38;
	pointer-events: none;
}

/* فلش‌های کاروسل: هم‌عرضِ تامبنیل، ارتفاعِ کوتاه، چسبیده به بالا/پایین */
.plt-bt-qv__gallery .plt-bt-qv__nav {
	flex: 0 0 28px;
	width: 100%;
	height: 28px;
	min-height: 0; /* خنثی‌کردنِ min-height سراسریِ دکمه‌ها (:is(button,…)) */
	padding: 0;
	border-radius: 8px;
	background: #e4e4e4;
	cursor: pointer;
	position: relative;
	transition: background .15s ease, border-color .15s ease;
}
.plt-bt-qv__nav:hover { background: #d7d7d7; }
.plt-bt-qv__nav::before {
	content: "";
	position: absolute;
	inset: 0;
	margin: auto;
	width: 8px;
	height: 8px;
	border: solid var(--color-gray-700, #51596a);
	border-width: 0 2px 2px 0;
}
.plt-bt-qv__nav--prev::before { transform: translateY(2px) rotate(-135deg); }
.plt-bt-qv__nav--next::before { transform: translateY(-2px) rotate(45deg); }

/* متن */
.plt-bt-qv__body { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.plt-bt-qv__title { margin: 0; font-size: 22px; font-weight: 700; color: var(--color-gray-900, #1f2430); line-height: 1.5; }
.plt-bt-qv__price { font-size: 20px; font-weight: 700; color: var(--pt-primary-color, #f05a4f); }
.plt-bt-qv__price del { opacity: .6; font-size: 15px; margin-inline-start: 8px; font-weight: 500; }
.plt-bt-qv__price ins { text-decoration: none; }
.plt-bt-qv__excerpt { color: var(--color-gray-700, #51596a); line-height: 1.9; font-size: 14px; }
.plt-bt-qv__excerpt p { margin: 0 0 8px; display: inline; }

/* لینکِ «اطلاعاتِ بیشتر» در ادامه‌ی متنِ خلاصه + آیکونِ Picon */
.plt-bt-qv__more {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	margin-inline-start: 6px;
	color: var(--pt-primary-color, #f05a4f);
	font-weight: 700;
	text-decoration: none;
	white-space: nowrap;
	vertical-align: middle;
}
.plt-bt-qv__more::after {
	content: "\e118"; /* picon-arrow-lt1 */
	font-family: "Picon";
	font-size: 20px;
	line-height: 1;
	font-weight: 400;
}

.plt-bt-qv.is-loading .plt-bt-qv__body { opacity: .4; }

@media (max-width: 680px) {
	.plt-bt-qv.pt-popup { --pt-popup-padding: 18px; }

	/* رسانه (تصویرِ اصلی + استریپِ عمودیِ تامبنیل) بالا، متن پایین —
	   ساختارِ داخلیِ رسانه مثلِ دسکتاپ می‌ماند (تامبنیل‌ها عمودی کنارِ تصویر). */
	.plt-bt-qv__grid,
	.plt-bt-qv.has-gallery .plt-bt-qv__grid { grid-template-columns: 1fr; gap: 18px; }
	.plt-bt-qv__media { max-height: 360px; }

	.plt-bt-qv__title { font-size: 18px; }
	.plt-bt-qv__price { font-size: 17px; }
}
