/* GLIVU Loop — estilos base del contenedor, items, y widgets de campo. */

.glivu-loop-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 20px;
}

.glivu-loop-item {
	min-width: 0;
}

/* Aviso visible sólo en el editor de Elementor (falta plantilla, sin productos, etc). */
.glivu-loop-notice {
	padding: 16px 20px;
	background: #fef2f2;
	color: #991b1b;
	border: 1px dashed #ef4444;
	border-radius: 6px;
	font-size: 14px;
	line-height: 1.5;
}

/* Placeholder de los widgets de campo cuando se editan fuera de un loop y sin producto de muestra disponible. */
.glivu-field-placeholder {
	display: inline-block;
	padding: 4px 10px;
	background: #fef3c7;
	color: #92400e;
	border: 1px dashed #d97706;
	border-radius: 4px;
	font-size: 12px;
	font-family: monospace;
}

.glivu-field-image img {
	max-width: 100%;
	height: auto;
	display: block;
}

.glivu-field-image-empty {
	background: #f0f0f0;
	aspect-ratio: 1 / 1;
	border-radius: 4px;
}

.glivu-field-title,
.glivu-field-title-link {
	color: inherit;
	text-decoration: none;
}

.glivu-field-price {
	display: inline-block;
}

.glivu-field-stock {
	display: inline-block;
	padding: 4px 12px;
	border-radius: 20px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.4;
}

.glivu-stock-agotado {
	background: #e74c3c;
	color: #fff;
}

.glivu-stock-disponible {
	background: #2ecc71;
	color: #fff;
}

.glivu-field-button {
	display: inline-block;
	text-decoration: none;
	cursor: pointer;
	padding: 10px 22px;
	border-radius: 4px;
	background: #1B5E20;
	color: #fff;
	font-weight: 700;
	transition: background-color .2s, color .2s;
}

.glivu-field-button.glivu-button-disabled {
	background: #9e9e9e;
	cursor: not-allowed;
	opacity: .8;
}

.glivu-field-excerpt,
.glivu-field-description {
	line-height: 1.5;
}

.glivu-field-gallery img {
	max-width: 100%;
	height: auto;
	display: block;
}

.glivu-field-add-to-cart .quantity {
	margin-right: 8px;
}

/* Wrapper del template "Detalle de producto" (single product) del GLIVU
   Theme Builder, ver templates/single-product-glivu.php. */
.glivu-hf-single-product {
	width: 100%;
}

.glivu-loop-pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 24px;
}

.glivu-loop-pagination a,
.glivu-loop-pagination span {
	display: inline-block;
	padding: 8px 14px;
	border-radius: 4px;
	background: #f5f5f5;
	color: #333;
	text-decoration: none;
	font-size: 14px;
}

.glivu-loop-pagination .current {
	background: #1B5E20;
	color: #fff;
}
