/* ==============================
   Bloque: Equipos y Componentes
   Desktop-first
   ============================== */

.hec-bloque {
	box-sizing: border-box;
	background-color: #f9f9f9;
	padding-top: var(--hec-pad-dt, 65px);
	padding-bottom: var(--hec-pad-db, 65px);
	width: 100%;
	overflow: hidden;
}

.hec-inner {
	max-width: var(--wp--style--global--wide-size);
	margin: 0 auto;
	width: 100%;
	overflow: visible;
}

.hec-bloque *,
.hec-bloque *::before,
.hec-bloque *::after {
	box-sizing: border-box;
}

/* ---- Header de sección ---- */
.hec-seccion__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 32px;
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto;
	margin-right: auto;
}

.hec-seccion__titulo-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
}

.hec-triangle {
	flex-shrink: 0;
}

.hec-seccion__titulo {
	font-family: var(--wp--preset--font-family--soho-gothic-pro);
	font-size: 24px;
	font-weight: 700;
	line-height: 1.1;
	margin: 0;
	color: var(--wp--preset--color--custom-negro);
}

.hec-seccion__btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 16px 23px;
	border: 1px solid var(--wp--preset--color--custom-rojo-principal);
	border-radius: 0;
	background: var(--wp--preset--color--custom-rojo-principal);
	color: var(--wp--preset--color--custom-blanco);
	font-family: var(--wp--preset--font-family--jetbrains-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	text-decoration: none;
	transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
	white-space: nowrap;
}

.hec-seccion__btn:hover {
	background-color: var(--wp--preset--color--custom-negro);
	border-color: var(--wp--preset--color--custom-negro);
	color: var(--wp--preset--color--custom-blanco);
}

.hec-seccion__btn-arrow {
	display: inline-flex;
	transition: transform 0.3s ease;
}

.hec-seccion__btn:hover .hec-seccion__btn-arrow {
	transform: translateX(4px);
}

/* ---- Carrusel (Equipos) ---- */
.hec-seccion--equipos {
	margin-bottom: 55px;
}

.hec-bloque .hec-carousel.swiper {
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto;
	margin-right: auto;
	overflow: visible;
	clip-path: inset(0 calc(-1 * max((100vw - var(--wp--style--global--wide-size)) / 2, 0px)) 0 0);
}

.hec-carousel .swiper-wrapper {
	display: flex;
	align-items: stretch;
}

.hec-carousel .swiper-slide {
	flex-shrink: 0;
	height: auto;
}

.hec-carousel:not(.swiper-initialized) .swiper-wrapper {
	flex-wrap: wrap;
	gap: 15px;
}

.hec-carousel:not(.swiper-initialized) .swiper-slide {
	flex: 0 0 calc((100% - 45px) / 4);
	width: calc((100% - 45px) / 4);
}

/* ---- Navegación carrusel ---- */
.hec-nav {
	display: flex;
	gap: 10px;
	justify-content: flex-end;
	margin-top: 38px;
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto;
	margin-right: auto;
}

.hec-nav__btn {
	width: 35px;
	height: 35px;
	border-radius: 50%;
	border: 0;
	background: rgba(102, 102, 102, 0.45);
	color: var(--wp--preset--color--custom-blanco);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background-color 0.3s ease, color 0.3s ease;
	padding: 0;
}

.hec-nav__btn:hover {
	background-color: var(--wp--preset--color--custom-rojo-principal);
	color: var(--wp--preset--color--custom-blanco);
}

.hec-nav__btn--next {
	background-color: var(--wp--preset--color--custom-rojo-principal);
	color: var(--wp--preset--color--custom-blanco);
}

.hec-nav__btn--next:hover {
	background-color: var(--wp--preset--color--custom-negro);
}

/* ---- Grid (Componentes) ---- */
.hec-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 15px;
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto;
	margin-right: auto;
}

/* ---- Card ---- */
.hec-card {
	background: var(--wp--preset--color--custom-blanco);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	height: 100%;
	position: relative;
	isolation: isolate;
	transition: box-shadow 0.35s ease;
}

.hec-card__link {
	text-decoration: none;
	color: inherit;
	display: flex;
	flex-direction: column;
	height: 100%;
	pointer-events: auto;
}

.hec-card__img-wrap {
	width: 100%;
	height: 115px;
	overflow: hidden;
}

.hec-card__img-wrap img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	filter: grayscale(0);
	transition: transform 0.4s ease, filter 0.4s ease;
}

.hec-card__img-wrap::after {
	content: '';
	position: absolute;
	inset: 0;
	background: var(--wp--preset--color--custom-rojo-principal);
	mix-blend-mode: multiply;
	opacity: 0;
	transition: opacity 0.4s ease;
	pointer-events: none;
	z-index: 2;
}


.hec-card__img-wrap {
	position: relative;
}

.hec-card:hover .hec-card__img-wrap img {
	transform: scale(1.05);
}

.hec-card--has-featured-image:hover .hec-card__img-wrap img {
	filter: grayscale(1);
}

.hec-card--has-featured-image:hover .hec-card__img-wrap::after {
	opacity: 0.88;
}

.hec-card__content {
	padding: 45px 30px 50px 30px;
	display: flex;
	flex-direction: column;
	flex: 1;
	justify-content: space-between;

	align-items: flex-start;
	gap: 40px;
	position: relative;
	overflow: hidden;
}

.hec-card__content::before {
	content: '';
	position: absolute;
	inset: 0;
	background: var(--wp--preset--color--custom-rojo-principal);
	transform: translateX(-102%);
	transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
	z-index: 0;
}

.hec-card__content::after {
	content: '';
	position: absolute;
	inset: -88px auto -88px -32px;
	width: 376px;
	background: rgba(255, 255, 255, 0.13);
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 88 190'%3E%3Cpath d='M18 24L60 95L18 166' fill='none' stroke='white' stroke-width='34' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 88 190'%3E%3Cpath d='M18 24L60 95L18 166' fill='none' stroke='white' stroke-width='34' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-position: left center;
	mask-position: left center;
	-webkit-mask-size: 296px calc(100% + 176px);
	mask-size: 296px calc(100% + 176px);
	opacity: 0;
	transform: translateX(-144px);
	transition: opacity 0.28s ease, transform 0.86s cubic-bezier(0.22, 1, 0.36, 1);
	transition-delay: 0s;
	pointer-events: none;
	z-index: 1;
}

.hec-card__copy {
	display: flex;
	flex-direction: column;
	gap: 13px;
	width: 100%;
	max-width: 343px;
	position: relative;
	z-index: 2;
	transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.hec-card__title {
	font-family: var(--wp--preset--font-family--soho-gothic-pro);
	font-size: var(--hec-title-fs, 28px);
	font-weight: 700;
	line-height: 1.05;
	letter-spacing: -0.56px;
	margin: 0;
	color: var(--wp--preset--color--custom-negro);
	position: relative;
	z-index: 2;
	transition: color 0.3s ease;
}

.hec-card__desc {
	font-family: var(--wp--preset--font-family--inter-display);
	font-size: var(--hec-desc-fs, 16px);
	font-weight: 400;
	line-height: 1.35;
	margin: 0;
	opacity: 0.8;
	color: var(--wp--preset--color--custom-gris);
	position: relative;
	z-index: 2;
	transition: color 0.3s ease, opacity 0.3s ease;
}

.hec-card__more {
	display: inline-flex;
	align-items: center;
	gap: 11px;
	font-family: var(--wp--preset--font-family--jetbrains-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	color: var(--wp--preset--color--custom-gris);
	position: relative;
	z-index: 2;
	transition: color 0.3s ease, transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.hec-card__arrow {
	display: inline-flex;
	transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.hec-card:hover {
	box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.hec-card:hover .hec-card__content::before {
	transform: translateX(0);
}

.hec-card:hover .hec-card__content::after {
	opacity: 1;
	transform: translateX(0);
	transition-delay: 0.18s;
}

@media (min-width: 1024px) {
	.hec-card--has-featured-image:hover .hec-card__content::after {
		opacity: 0.4;
	}
}

.hec-card:hover .hec-card__copy {
	transform: translateX(4px);
}

.hec-card:hover .hec-card__title,
.hec-card:hover .hec-card__desc {
	color: var(--wp--preset--color--custom-blanco);
}

.hec-card:hover .hec-card__desc {
	opacity: 1;
}

.hec-card:hover .hec-card__more {
	color: var(--wp--preset--color--custom-blanco);
}

.hec-card:hover .hec-card__arrow {
	transform: translateX(4px);
}

/* ---- Empty ---- */
.hec-empty {
	max-width: var(--wp--style--global--wide-size);
	margin: 20px auto;
	font-family: var(--wp--preset--font-family--inter);
	font-size: 14px;
	color: var(--wp--preset--color--custom-gris);
}

/* =============================
   Responsive ≤ 1023px
   ============================= */
@media (max-width: 1023px) {
	.hec-bloque {
		padding-top: var(--hec-pad-mt, 60px);
		padding-bottom: var(--hec-pad-mb, 60px);

	}

	.hec-seccion__header {
		flex-direction: column;
		align-items: flex-start;
		gap: 16px;
		margin-bottom: 22px;
	}

	.hec-seccion__btn {
		width: 100%;
		justify-content: center;
	}

	.hec-seccion__titulo {
		font-size: 24px;
	}

	.hec-grid {
		grid-template-columns: 1fr;
		gap: 12px;
	}

	.hec-carousel .swiper-wrapper {
		align-items: flex-start;
	}

	.hec-carousel:not(.swiper-initialized) .swiper-slide {
		flex-basis: calc((100% - 15px) / 2);
		width: calc((100% - 15px) / 2);
	}

	.hec-card,
	.hec-card__link {
		height: auto;
	}

	.hec-card__title {
		font-size: var(--hec-title-fs-mob, 22px);
	}

	.hec-card__desc {
		font-size: var(--hec-desc-fs-mob, 14px);
	}

	.hec-card__img-wrap {
		height: 104px;
	}

	.hec-card__content {
		padding: 28px 20px 12px;
		flex: 0 0 auto;
		justify-content: flex-start;
		gap: 18px;
	}

	.hec-card__copy {
		gap: 10px;
		max-width: none;
	}

	.hec-card:hover .hec-card__img-wrap img {
		transform: none;
	}

	.hec-card:hover .hec-card__img-wrap::after {
		opacity: 0;
	}

	.hec-card:hover {
		box-shadow: none;
	}

	.hec-card:hover .hec-card__content::before {
		transform: translateX(-102%);
	}

	.hec-card:hover .hec-card__content::after {
		opacity: 0;
		transform: translateX(-20px);
		transition-delay: 0s;
	}

	.hec-card:hover .hec-card__copy {
		transform: none;
	}

	.hec-card:hover .hec-card__title {
		color: var(--wp--preset--color--custom-negro);
	}

	.hec-card:hover .hec-card__desc {
		color: var(--wp--preset--color--custom-gris);
		opacity: 0.8;
	}

	.hec-card:hover .hec-card__more {
		color: var(--wp--preset--color--custom-gris);
	}

	.hec-card:hover .hec-card__arrow {
		transform: none;
	}

	.hec-seccion--equipos {
		margin-bottom: 60px;
	}

	.hec-nav {
		margin-top: 24px;
	}
}

@media (max-width: 767px) {
	.hec-carousel:not(.swiper-initialized) .swiper-slide {
		flex-basis: 100%;
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.hec-card,
	.hec-card__copy,
	.hec-card__img-wrap img,
	.hec-card__img-wrap::after,
	.hec-card__content::before,
	.hec-card__content::after,
	.hec-card__title,
	.hec-card__desc,
	.hec-card__more,
	.hec-card__arrow {
		transition: none;
	}
}
