/**
 * Efectos globales — scroll reveal y hovers rojo ↔ azul.
 */

:root {
	--es-fx-red: #E62020;
	--es-fx-red-end: #ff6b35;
	--es-fx-blue: #2A2E65;
	--es-fx-blue-light: #003580;
}

/* Scroll reveal legacy — reemplazado por AOS (ver inc/scroll-animations.php) */
/* Botones — transición de color llamativa, sin movimiento */
.es-cta-btn,
.es-pead-btn,
.es-mini-cart-btn,
.es-shop-btn,
.es-shop-card-btn,
.es-matricula-submit,
.es-matricula-contract-btn,
.es-nosotros-cta-btn,
.es-footer-newsletter-form button,
.theme-saber-header .es-topbar-pill,
button[type="submit"].button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
	position: relative;
	overflow: hidden;
	isolation: isolate;
	transition:
		background 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		border-color 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		color 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		filter 0.45s cubic-bezier(0.22, 1, 0.36, 1);
	transform: none !important;
}

/* Rojo → azul con brillo */
.es-cta-btn:hover,
.es-pead-btn:hover,
.es-shop-btn:hover,
.es-shop-card-btn:hover,
.es-matricula-submit:hover,
.es-matricula-contract-btn:hover,
.es-nosotros-cta-btn:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover {
	background: #2A2E65;
	color: #fff !important;
	filter: brightness(1.05);
}

/* Azul outline → rojo */
.es-mini-cart-btn--outline:hover,
.theme-saber-header .es-topbar-pill--blue:hover {
	background: #E62020;
	color: #fff !important;
	filter: brightness(1.06);
}

.es-topbar-pill--blue{
	color: #fff !important;
}

/* Rojo sólido → azul */
.es-mini-cart-btn--primary:hover {
	background: linear-gradient(90deg, var(--es-fx-blue) 0%, var(--es-fx-blue-light) 100%) !important;
	border-color: var(--es-fx-blue) !important;
	color: #fff !important;
	box-shadow:
		0 0 0 3px rgba(0, 33, 87, 0.2),
		0 8px 28px rgba(0, 33, 87, 0.42) !important;
	filter: brightness(1.06);
}

/* Ghost → azul sólido */
.theme-saber-header .es-topbar-pill--ghost:hover {
	background: var(--es-fx-blue) !important;
	border-color: var(--es-fx-blue) !important;
	color: #fff !important;
	box-shadow: 0 0 18px rgba(0, 33, 87, 0.35) !important;
}

.es-cart-toggle:hover {
	transform: none !important;
	border-color: var(--es-fx-blue) !important;
	color: var(--es-fx-blue) !important;
	background: rgba(0, 33, 87, 0.06) !important;
	box-shadow: 0 0 16px rgba(0, 33, 87, 0.2) !important;
}

.es-pead-card:hover,
.es-pead-plan-card:hover {
	transform: none !important;
	box-shadow: 0 12px 32px rgba(0, 33, 87, 0.12);
	border-color: rgba(0, 33, 87, 0.2);
}

/* Barra de progreso de scroll — fina, colores El Saber */
.es-scroll-progress {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	height: 3px;
	z-index: 99999;
	pointer-events: none;
	background: rgba(42, 46, 101, 0.06);
}

.es-scroll-progress__bar {
	display: block;
	width: 0;
	height: 100%;
	background: linear-gradient(90deg, var(--es-fx-red) 0%, #ff4d4d 42%, var(--es-fx-blue) 100%);
	box-shadow: 0 0 10px rgba(230, 32, 32, 0.35);
	transition: width 0.12s linear;
	will-change: width;
}

@media (prefers-reduced-motion: reduce) {
	.es-scroll-progress__bar {
		transition: none;
	}
}
