/* Tarjeta de producto compartida (Carrusel y Grilla). Especificidad baja: los controles de Elementor ({{WRAPPER}}) siempre ganan. */

/* ---------- Tarjeta ---------- */

.wzpy-product {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 16px;
	border: 0 solid transparent;
	background: #fff;
	box-sizing: border-box;
	text-align: left;
	transition: all .2s;
}

.wzpy-products--classic .wzpy-product {
	border-radius: 4px;
}

.wzpy-products--cards .wzpy-product {
	border: 1px solid #e5e5e5;
	border-radius: 8px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .06);
}

.wzpy-product__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 6px;
	min-height: 22px;
}

.wzpy-product__badge {
	align-self: flex-start;
	padding: 4px 8px;
	border: 0 solid transparent;
	border-radius: 20px;
	background: #0b5ed7;
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	line-height: 1.2;
	text-transform: uppercase;
}

.wzpy-product__rating {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-left: auto;
}

.wzpy-stars {
	--wzpy-star: #ff6500;
	--wzpy-star-empty: #d6d6d6;
	font-size: 12px;
	letter-spacing: 1px;
	line-height: 1;
	background: linear-gradient(90deg, var(--wzpy-star) calc(var(--wzpy-rating) / 5 * 100%), var(--wzpy-star-empty) 0);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.wzpy-product__reviews {
	color: #999;
	font-size: 11px;
}

/* Valoración debajo del título: se "aplana" la fila superior y se reordena. */
.wzpy-product__image { order: 1; }
.wzpy-product__title { order: 2; }
.wzpy-product__prices { order: 4; }
.wzpy-product__actions { order: 5; }

.wzpy-products--rating-below .wzpy-product__top {
	display: contents;
}

.wzpy-products--rating-below .wzpy-product__rating {
	order: 3;
	margin-left: 0;
}

.wzpy-product__image {
	position: relative;
	display: block;
	height: 180px;
	overflow: hidden;
}

.wzpy-product__image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	transition: transform .3s ease, opacity .3s ease;
}

.wzpy-product__image .wzpy-product__image-hover {
	position: absolute;
	inset: 0;
	opacity: 0;
}

.wzpy-product:hover .wzpy-product__image-hover {
	opacity: 1;
}

.wzpy-product__title {
	--wzpy-lines: 3;
	display: -webkit-box;
	min-height: calc(1.35em * var(--wzpy-lines));
	overflow: hidden;
	color: #333;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	text-decoration: none;
	-webkit-line-clamp: var(--wzpy-lines);
	-webkit-box-orient: vertical;
}

.wzpy-product__title:hover {
	color: #ff6500;
}

/* Precios y botón siempre al fondo: tarjetas alineadas aunque cambie el contenido. */
.wzpy-product__prices {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-top: auto;
}

.wzpy-product__regular {
	color: #999;
	font-size: 12px;
}

.wzpy-product__price-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
}

.wzpy-product__price {
	color: #ff6500;
	font-size: 22px;
	font-weight: 800;
	line-height: 1.1;
}

.wzpy-product__discount {
	padding: 2px 5px;
	border: 0 solid transparent;
	border-radius: 4px;
	background: #ff6500;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.2;
}

.wzpy-product__note,
.wzpy-product__installments {
	color: #666;
	font-size: 12px;
	line-height: 1.4;
}

.wzpy-product__installments strong {
	color: #333;
}

.wzpy-product__actions {
	margin-top: 8px;
}

.wzpy-product .wzpy-product__button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 40px;
	padding: 10px 16px;
	border: 0 solid transparent;
	border-radius: 4px;
	background: #ff6500;
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	box-sizing: border-box;
	transition: all .2s;
}

.wzpy-product .wzpy-product__button:hover {
	background: #e55a00;
	color: #fff;
}

.wzpy-product .wzpy-product__button.loading {
	opacity: .6;
	pointer-events: none;
}

/* WooCommerce inserta un enlace "Ver carrito" tras añadir; el carrito lateral ya cumple esa función. */
.wzpy-product .added_to_cart {
	display: none;
}
