.wrpc {
	--wrpc-cols: 4;
	--wrpc-gap: 20px;
	position: relative;
}

.wrpc-track {
	display: flex;
	gap: var(--wrpc-gap);
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior-x: contain;
	padding: 4px 0 10px;
}

.wrpc-track::-webkit-scrollbar {
	display: none;
}

.wrpc-slide {
	flex: 0 0 calc((100% - (var(--wrpc-cols) - 1) * var(--wrpc-gap)) / var(--wrpc-cols));
	min-width: 0;
	scroll-snap-align: start;
	background-color: #fff;
}

.wrpc-slide > .elementor,
.wrpc-slide > .e-loop-item {
	height: 100%;
}

/* کارت پیش‌فرض */
.wrpc-card {
	height: 100%;
	display: flex;
	flex-direction: column;
	border: 1px solid #ececec;
	border-radius: 10px;
	overflow: hidden;
	background: #fff;
}

.wrpc-card-img {
	position: relative;
	display: block;
	background: #f7f7f7;
}

.wrpc-card-img img {
	display: block;
	width: 100%;
	height: auto;
}

.wrpc-badge {
	position: absolute;
	top: 10px;
	inset-inline-start: 10px;
	background: #e63946;
	color: #fff;
	font-size: 11px;
	line-height: 1;
	padding: 5px 8px;
	border-radius: 4px;
}

.wrpc-card-body {
	padding: 12px 14px 14px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	flex: 1;
}

.wrpc-card-title {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.6;
	color: #222;
	text-decoration: none;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.wrpc-card-price {
	margin-top: auto;
	font-weight: 700;
	color: #e63946;
}

.wrpc-card-price del {
	color: #999;
	font-weight: 400;
	margin-inline-end: 6px;
}

.wrpc-card-price ins {
	text-decoration: none;
}

/* فلش‌ها */
.wrpc-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 5;
	width: 38px;
	height: 38px;
	padding: 0;
	border: 1px solid #eee;
	border-radius: 50%;
	background: #fff;
	color: #333;
	box-shadow: 0 2px 10px rgba(0, 0, 0, .12);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: opacity .2s ease;
}

.wrpc-prev {
	inset-inline-start: -8px;
}

.wrpc-next {
	inset-inline-end: -8px;
}

.wrpc[dir="rtl"] .wrpc-nav svg {
	transform: scaleX(-1);
}

.wrpc-nav[disabled] {
	opacity: .35;
	cursor: default;
}

/* نقطه‌ها */
.wrpc-dots {
	display: flex;
	justify-content: center;
	gap: 7px;
	margin-top: 8px;
}

.wrpc-dots button {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #ddd;
	cursor: pointer;
	transition: transform .2s ease, background-color .2s ease;
}

.wrpc-dots button.is-active {
	background: #222;
	transform: scale(1.25);
}

.wrpc-empty {
	padding: 20px;
	text-align: center;
	border: 1px dashed #ccc;
	color: #777;
}

@media (max-width: 767px) {
	.wrpc-nav {
		width: 32px;
		height: 32px;
	}
}


/* عنوان تک‌خطی با ... */
.wrpc--oneline .wrpc-card-title,
.wrpc--oneline .wrpc-title,
.wrpc--oneline .woocommerce-loop-product__title,
.wrpc--oneline .elementor-widget-heading .elementor-heading-title,
.wrpc--oneline .elementor-widget-theme-post-title .elementor-heading-title,
.wrpc--oneline .elementor-widget-woocommerce-product-title .elementor-heading-title,
.wrpc--oneline .elementor-widget-woocommerce-product-title .product_title {
	display: block;
	max-width: 100%;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.wrpc--oneline .wrpc-card-title {
	-webkit-line-clamp: unset;
}
