/* web-hero — hero de /web/: fondo aurora + rejilla + haz de luz + grano, título más fino y salida del abanico.
   Carga después de estudio.css y sobrescribe sus reglas .wh. Todo el movimiento es transform/opacity. */

.wh { position: relative; isolation: isolate; background: #121011; }

/* ── Fondo ── */
.wh__fondo { position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.wh__fondo > i { position: absolute; display: block; }

/* Aurora: dos masas de color que derivan muy despacio */
.wh__aurora { inset: -20%; }
.wh__aurora::before, .wh__aurora::after { content: ""; position: absolute; border-radius: 50%; will-change: transform; }
.wh__aurora::before { width: 70%; height: 80%; right: 2%; top: 4%; background: radial-gradient(closest-side, rgba(255, 91, 35, .55), rgba(255, 91, 35, .18) 55%, transparent); animation: wh-deriva-a 22s ease-in-out infinite alternate; }
.wh__aurora::after { width: 55%; height: 60%; left: -4%; bottom: 0; background: radial-gradient(closest-side, rgba(210, 251, 140, .16), rgba(210, 251, 140, .05) 60%, transparent); animation: wh-deriva-b 28s ease-in-out infinite alternate; }
@keyframes wh-deriva-a { to { transform: translate3d(-12%, 10%, 0) scale(1.15) rotate(12deg); } }
@keyframes wh-deriva-b { to { transform: translate3d(14%, -12%, 0) scale(1.2); } }

/* Rejilla fina que se desvanece hacia los bordes */
.wh__rejilla { inset: 0; background-image: linear-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px); background-size: 64px 64px; background-position: center top; -webkit-mask-image: radial-gradient(ellipse 60% 70% at 72% 45%, #000, transparent 75%); mask-image: radial-gradient(ellipse 60% 70% at 72% 45%, #000, transparent 75%); }

/* Haz de luz diagonal que cruza lento */
.wh__haz { top: -50%; left: 0; width: 34%; height: 200%; background: linear-gradient(90deg, transparent, rgba(255, 180, 140, .09) 45%, rgba(255, 255, 255, .12) 50%, rgba(255, 180, 140, .09) 55%, transparent); transform: translate3d(-120%, 0, 0) rotate(18deg); mix-blend-mode: screen; animation: wh-haz 14s cubic-bezier(.45, 0, .25, 1) 1.2s infinite; will-change: transform; }
@keyframes wh-haz { 0% { transform: translate3d(-120%, 0, 0) rotate(18deg); } 55%, 100% { transform: translate3d(360%, 0, 0) rotate(18deg); } }

/* Grano de película */
.wh__grano { inset: 0; opacity: .14; mix-blend-mode: overlay; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

/* Filo de color abajo, cierra la sección contra el blanco */
.wh::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 91, 35, .7) 30%, rgba(210, 251, 140, .6) 70%, transparent); }

/* ── Texto ── */
.wh__txt { position: relative; }
.wh__ceja { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 20px; padding: 7px 14px 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .04); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .82); font-size: 12.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.wh__ceja::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--lima); box-shadow: 0 0 0 4px rgba(210, 251, 140, .16), 0 0 14px rgba(210, 251, 140, .7); }
.wh h1 { max-width: 13ch; font-size: clamp(36px, 4.4vw, 68px); line-height: 1.06 !important; letter-spacing: -.012em !important; word-spacing: .04em; text-wrap: balance; }
.wh h1 .chispa { background: linear-gradient(135deg, #FF5B23 20%, #FF9A5C 60%, #D2FB8C); -webkit-background-clip: text; background-clip: text; color: transparent; }
.wh__txt > p:not(.wh__ceja) { margin-top: 22px; color: rgba(255, 255, 255, .74); }
.wh__acc { margin-top: 32px; }

/* ── Abanico ── */
.wh__fan::before { content: ""; position: absolute; left: 50%; top: 50%; width: 110%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 91, 35, .42), rgba(255, 91, 35, .1) 55%, transparent); transform: translate(-50%, -50%); animation: wh-late 7s ease-in-out infinite alternate; z-index: -1; }
@keyframes wh-late { to { transform: translate(-50%, -50%) scale(1.12); opacity: .75; } }
.wh__fan img { width: 50%; box-shadow: 0 1px 0 rgba(255, 255, 255, .14) inset, 0 0 0 1px rgba(255, 255, 255, .08), 0 34px 70px -28px #000; background: #1c191a; }

/* Salida antes de cambiar de trío; al quitar .is-sale vuelve wh-entra (de estudio.css) y se repite la entrada */
.wh .wh__fan.is-sale img { animation: wh-sale .62s cubic-bezier(.5, 0, .75, 0) both; }
.wh .wh__fan.is-sale img:nth-child(1) { animation-delay: .1s; }
.wh .wh__fan.is-sale img:nth-child(2) { animation-delay: 0s; }
.wh .wh__fan.is-sale img:nth-child(3) { animation-delay: .14s; }
@keyframes wh-sale { to { opacity: 0; translate: 0 -28px; scale: .94; } }

@media (max-width: 960px) {
	.wh h1 { max-width: 16ch; }
	.wh__fan { width: min(100%, 520px); margin-inline: auto; }
	.wh__rejilla { -webkit-mask-image: radial-gradient(ellipse 80% 55% at 50% 70%, #000, transparent 75%); mask-image: radial-gradient(ellipse 80% 55% at 50% 70%, #000, transparent 75%); }
}
@media (max-width: 600px) {
	.wh__fan { height: clamp(250px, 76vw, 340px); margin-top: 12px; }
	.wh__fan img { width: 46%; border-radius: 10px; }
	.wh__haz { width: 60%; }
	.wh__rejilla { background-size: 44px 44px; }
}

@media (prefers-reduced-motion: reduce) {
	.wh__aurora::before, .wh__aurora::after, .wh__fan::before { animation: none; }
	.wh__haz { display: none; }
}
