/* ============================================================
   "Bases del catálogo GEA" widget (gea_bases) — design-mockup .bases
   (#productos): the 2 catalog bases, cover with title + count over a
   gradient, and the category names fading underneath (assets/js/bases.js).
   ============================================================ */

.elementor-widget-gea_bases,
.elementor-widget-gea_bases > .elementor-widget-container {
	width: 100%;
}

.bases {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(14px, 1.6vw, 22px);
}

.base {
	display: grid;
	grid-template-rows: auto 1fr;
	overflow: hidden;
	background: var(--white);
	border: 1px solid var(--mist-warm);
	border-radius: var(--r-card);
	color: inherit;
	text-decoration: none;
	transition: border-color 0.25s ease;
}

.base__media {
	position: relative;
	display: block;
	height: clamp(170px, 32vh, 400px);
	overflow: hidden;
}

/* title and product count over the cover, with a gradient to read them */
.base__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(10, 28, 46, 0) 40%, rgba(10, 28, 46, 0.78) 100%);
	pointer-events: none;
}

.base__media img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
	-webkit-user-drag: none;
	user-select: none;
}

.base__body {
	display: grid;
	gap: 14px;
	padding: clamp(18px, 1.8vw, 26px) clamp(20px, 2vw, 28px) clamp(20px, 2vw, 26px);
}

.base__head {
	position: absolute;
	inset: auto 0 0;
	z-index: 1;
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 4px 16px;
	padding: 0 clamp(20px, 2vw, 28px) clamp(16px, 1.6vw, 22px);
}

.base__title {
	font-size: clamp(22px, 2vw, 30px);
	font-weight: 500;
	letter-spacing: -0.015em;
	color: #fff;
}

.base__count {
	font-size: 13.5px;
	color: rgba(255, 255, 255, 0.82);
}

/* names fade, the line above them stays */
.base__ticker {
	display: grid;
	gap: 4px;
	padding-top: 14px;
	border-top: 1px solid var(--mist-warm);
}

.base__ticker span {
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	font-size: 15.5px;
	line-height: 1.45;
	color: var(--slate);
	transition: opacity 0.38s ease, transform 0.38s ease;
}

.base__ticker.is-out span {
	opacity: 0;
	transform: translateY(6px);
}

.base__go {
	font-size: 14.5px;
	font-weight: 500;
	color: var(--accent);
}

.base__go span {
	display: inline-block;
	transition: transform 0.25s ease;
}

.base:hover {
	border-color: var(--ink);
}

.base:hover .base__media img {
	transform: scale(1.05);
}

.base:hover .base__go span {
	transform: translateX(3px);
}

@media (prefers-reduced-motion: reduce) {
	.base__media img,
	.base__ticker span {
		transition: none;
	}
}

@media (max-width: 640px) {
	.bases {
		grid-template-columns: 1fr;
	}

	.base__media {
		height: clamp(130px, 20vh, 220px);
	}

	.base__body {
		gap: 10px;
	}

	.base__ticker {
		padding-top: 10px;
	}

	.base__ticker span {
		font-size: 14.5px;
	}
}

/* short phones (e.g. 375×667): lower covers */
@media (max-width: 640px) and (max-height: 720px) {
	.base__media {
		height: 110px;
	}
}

@media (min-width: 1800px) {
	.base__title {
		font-size: clamp(30px, 1.6vw, 40px);
	}

	.base__count,
	.base__go {
		font-size: 16px;
	}

	.base__ticker span {
		font-size: 17.5px;
	}
}
