/**
 * Cartão de produto (product-card-low) — partilhado.
 * Usado por Product_Card::render() em vários sítios (grid de
 * filtros AJAX, widget de grelha de produtos, etc.) — por isso vive
 * aqui, em vez de dentro da pasta de um widget específico.
 */

/* ==========================================================
   DESKTOP
========================================================== */

.product-card-low {
	border-radius: 10px;
	overflow: hidden;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card-low:hover {
	transform: scale(1.05);
}

.product-image-container {
	position: relative;
	display: flex;
	align-items: center;
	width: 100%;
	aspect-ratio: 2 / 2.2;
	overflow: hidden;
	border-radius: 15px;
}

.product-image {
	width: 100%;
	height: auto;
	object-fit: cover;
}

.product-price-overlay {
	position: absolute;
	bottom: 10px;
	right: 10px;
	background: white;
	color: black;
	padding: 4px 15px;
	font-size: 1.3rem;
	font-weight: bold;
	border-radius: 15px;
	box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.3);
}

.discounted-price {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
}

.discounted-price .old-price {
	text-decoration: line-through;
	color: grey;
	font-size: 1rem;
}

.discounted-price .new-price {
	color: #0274be;
	font-size: 1.2rem;
	font-weight: bold;
}

.product-card-low h4 {
	margin: 10px 0 5px;
	color: #333;
	text-align: center;
}

.product-card-low .product-categories {
	color: #888;
	text-align: center;
	margin-bottom: 10px;
	font-style: italic;
}

.product-card-low .posted_in {
	display: block;
	color: #666;
	font-style: italic;
}

.product-card-low .posted_in a {
	color: #0073aa;
	text-decoration: none;
}

.product-card-low .posted_in a:hover {
	text-decoration: underline;
	color: #005177;
}

/* ==========================================================
   MOBILE (até 768px)
========================================================== */
@media (max-width: 768px) {

	.product-card-low {
		border-radius: 20px;
	}

	.product-image-container {
		display: inline-block;
		aspect-ratio: 2 / 2.45;
	}

	.product-image {
		border-radius: 8px;
	}

	.product-price-overlay {
		padding: 2px 12px;
		font-size: 1.2rem;
		border-radius: 10px;
	}

	.discounted-price {
		flex-direction: row;
		justify-content: flex-end;
		align-items: center;
		gap: 5px;
	}

	.discounted-price .old-price {
		font-size: 0.6rem;
	}

	.discounted-price .new-price {
		font-size: 0.7rem;
	}

	.product-card-low h4 {
		font-size: 1.3em;
	}

	.product-card-low .product-categories {
		margin-bottom: 20px;
		font-size: 0.9em;
	}
}