/* GM Product Cards — estrutura: badge, preço, parcelas, pix, ações */

ul.products li.product.gm-product-card {
	list-style: none;
	margin: 0 !important;
	padding: 0 !important;
	position: relative;
	overflow: visible;
	align-self: start;
}

.gm-product-card__inner {
	display: flex;
	flex-direction: column;
	height: 100%;
	box-sizing: border-box;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 15px;
	overflow: hidden;
	position: relative;
}

.gm-product-card:hover {
	filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.12));
}

/* Imagem */
.gm-product-card__image-link {
	display: block;
	overflow: hidden;
	line-height: 0;
}

.gm-product-card__image-link img {
	width: 100%;
	height: auto;
	display: block;
	transition: transform 0.3s ease;
}

.gm-product-card__inner:hover .gm-product-card__image-link img {
	transform: scale(1.03);
}

/* Corpo do card */
.gm-product-card__body {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 14px 14px 16px;
	flex: 1;
	gap: 0;
}

/* Título */
.elementor-widget-woocommerce-products .gm-product-card .woocommerce-loop-product__title,
.elementor-widget-wc-archive-products .gm-product-card .woocommerce-loop-product__title,
.elementor-widget-woocommerce-product-related .gm-product-card .woocommerce-loop-product__title,
.gm-product-card .woocommerce-loop-product__title {
	font-family: "Montserrat", sans-serif;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.35;
	color: #1a1a1a !important;
	margin: 0 0 8px;
	padding: 0;
}

/* Badge Licença Digital */
.gm-product-card__badge {
	display: block;
	font-family: "Montserrat", sans-serif;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #666;
	margin: 0 0 10px;
	line-height: 1.2;
}

/* Preço */
.elementor-widget-woocommerce-products .gm-product-card .price,
.elementor-widget-wc-archive-products .gm-product-card .price,
.elementor-widget-woocommerce-product-related .gm-product-card .price,
.gm-product-card .price {
	font-family: "Montserrat", sans-serif;
	font-size: 26px;
	font-weight: 700;
	color: #1a1a1a !important;
	margin: 0 0 8px;
	line-height: 1.2;
}

.gm-product-card .price del {
	display: none;
}

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

.gm-product-card .price .woocommerce-Price-amount,
.gm-product-card .price .woocommerce-Price-amount .amount,
.gm-product-card .price ins .amount {
	color: #1a1a1a !important;
}

.gm-product-card .price .amount bdi {
	white-space: nowrap;
}

/* Parcelamento */
.gm-product-card__installments {
	display: block;
	font-family: "Montserrat", sans-serif;
	font-size: 12px;
	font-weight: 400;
	color: #333;
	margin: 0 0 6px;
	line-height: 1.3;
	width: 100%;
	text-align: center;
}

.gm-product-card__installments strong {
	font-weight: 700;
}

/* Preço Pix */
.gm-product-card__pix {
	display: block;
	font-family: "Montserrat", sans-serif;
	font-size: 13px;
	font-weight: 400;
	color: #333;
	margin: 0 0 14px;
	line-height: 1.3;
	width: 100%;
	text-align: center;
}

.gm-product-card__pix strong {
	font-weight: 700;
}

/* Ações — Comprar + ícone Espiar */
.gm-product-card__actions {
	display: flex;
	align-items: stretch;
	gap: 8px;
	width: 100%;
	margin-top: auto;
	padding-top: 4px;
}

.gm-product-card__actions a.gm-btn {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	box-sizing: border-box !important;
	min-height: 42px !important;
	height: 42px !important;
	margin: 0 !important;
	padding: 0 16px !important;
	font-family: "Montserrat", sans-serif !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	line-height: 1 !important;
	text-decoration: none !important;
	text-transform: uppercase;
	border-radius: 8px !important;
	border: none !important;
	cursor: pointer !important;
	white-space: nowrap !important;
	float: none !important;
	vertical-align: top !important;
}

.gm-product-card__actions a.gm-btn--comprar {
	flex: 1 1 auto;
	width: auto !important;
	background: #1a1a1a !important;
	color: #fff !important;
}

.gm-product-card__actions a.gm-btn--comprar:hover,
.gm-product-card__actions a.gm-btn--comprar.button:hover {
	background: #333 !important;
	color: #fff !important;
}

.gm-product-card__actions a.gm-btn--comprar.added {
	background: #2e7d32 !important;
}

.gm-product-card__actions a.gm-btn--espiar {
	flex: 0 0 42px;
	width: 42px !important;
	min-width: 42px !important;
	padding: 0 !important;
	background: #fff !important;
	color: #1a1a1a !important;
	border: 1px solid #1a1a1a !important;
}

.gm-product-card__actions a.gm-btn--espiar:hover {
	background: #f5f5f5 !important;
}

.gm-product-card__espiar-icon {
	display: block;
	width: 18px;
	height: 18px;
	background-color: currentColor;
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
	mask-size: contain;
	mask-repeat: no-repeat;
	mask-position: center;
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
	-webkit-mask-size: contain;
	-webkit-mask-repeat: no-repeat;
	-webkit-mask-position: center;
}

/* Esconde link "Ver carrinho" após add-to-cart AJAX (listagem e PDP) */
a.added_to_cart.wc-forward {
	display: none !important;
}

/* Esconde botão padrão do WooCommerce */
.gm-product-card > .button,
.gm-product-card > .add_to_cart_button:not(.gm-btn--comprar) {
	display: none !important;
}

/* Elementor widget — grid de produtos */
.elementor-widget-woocommerce-products .gm-product-card__inner,
.elementor-widget-wc-archive-products .gm-product-card__inner,
.elementor-widget-woocommerce-product-related .gm-product-card__inner {
	height: 100%;
}

.elementor-widget-woocommerce-products ul.products li.product.gm-product-card,
.elementor-widget-wc-archive-products ul.products li.product.gm-product-card,
.elementor-widget-woocommerce-product-related ul.products li.product.gm-product-card {
	display: flex;
	flex-direction: column;
}

.elementor-widget-woocommerce-products ul.products,
.elementor-widget-wc-archive-products ul.products,
.elementor-widget-woocommerce-product-related ul.products {
	overflow: visible;
}

.elementor-widget-woocommerce-products,
.elementor-widget-woocommerce-products .elementor-widget-container,
.elementor-widget-woocommerce-products .woocommerce,
.elementor-widget-wc-archive-products,
.elementor-widget-wc-archive-products .elementor-widget-container,
.elementor-widget-wc-archive-products .woocommerce,
.elementor-widget-woocommerce-product-related,
.elementor-widget-woocommerce-product-related .elementor-widget-container,
.elementor-widget-woocommerce-product-related .woocommerce {
	overflow: visible !important;
}

@media (max-width: 767px) {
	.gm-product-card .woocommerce-loop-product__title {
		font-size: 13px;
	}

	.gm-product-card .price {
		font-size: 22px;
	}

	.gm-product-card__installments,
	.gm-product-card__pix {
		font-size: 11px;
	}

	.gm-product-card__actions a.gm-btn {
		font-size: 12px !important;
		min-height: 40px !important;
		height: 40px !important;
	}

	.gm-product-card__actions a.gm-btn--espiar {
		flex: 0 0 40px;
		width: 40px !important;
		min-width: 40px !important;
	}
}
