/* ==================================================
   Beast Mode — estilos propios de la plantilla (hero: la bestia generada por IA)
   Barra, botones, secciones comunes, similares, CTA y WhatsApp vienen de themes/_kit/am-kit.css
   ================================================== */

.bm-hero {
	--red: #c60000;
	--blood: #870000;
	--wx: 50%;
	--wy: 75%;
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	height: 100vh;
	height: 100svh;
	min-height: 680px;
	padding-top: 68px;
	overflow: hidden;
	color: #f5f5f0;
	background: #050000;
	isolation: isolate;
	touch-action: pan-y;
}
.bm-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Escenario: canvas con la bestia (algo más grande que el hero para poder temblar) */
.bm-stage { position: absolute; inset: -18px; z-index: 0; background: #050000 50% 60% / cover no-repeat; }
html:not(.js) .bm-stage { background-image: url(../../wp-content/uploads/revslider/Hero-Slider-with-Midjourney-Image-Effect/beast1.jpg); }
.bm-canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.bm-shade {
	position: absolute;
	inset: 0;
	background:
		linear-gradient(rgba(0, 0, 0, .82) 0%, rgba(0, 0, 0, 0) 26%, rgba(0, 0, 0, 0) 58%, rgba(0, 0, 0, .9) 100%),
		radial-gradient(ellipse at 50% 55%, rgba(0, 0, 0, 0) 35%, rgba(0, 0, 0, .55) 100%);
	pointer-events: none;
}
.bm-hero.is-beast .bm-shade { animation: bm-beat .6s ease-out infinite; }
@keyframes bm-beat {
	0%, 100% { box-shadow: inset 0 0 120px 20px rgba(198, 0, 0, .35); }
	12% { box-shadow: inset 0 0 220px 60px rgba(255, 20, 20, .7); }
}

/* Barrido rojo al pasar por "Entrar ahora" (como el original) */
.bm-wipe {
	position: absolute;
	inset: 0;
	z-index: 2;
	background: var(--blood);
	mix-blend-mode: darken;
	clip-path: circle(0 at var(--wx) var(--wy));
	transition: clip-path .9s cubic-bezier(.77, 0, .18, 1);
	pointer-events: none;
}
.bm-hero.is-enter .bm-wipe { clip-path: circle(150% at var(--wx) var(--wy)); }

/* ---------- Consola /imagine ---------- */
.bm-console {
	position: absolute;
	z-index: 4;
	top: calc(68px + clamp(14px, 2.6vh, 28px));
	left: var(--gutter);
	width: min(500px, 40vw);
	padding: 12px 16px;
	font-family: var(--mb-mono);
	font-size: 12px;
	line-height: 1.55;
	color: rgba(245, 245, 240, .88);
	background: rgba(10, 0, 0, .58);
	border: 1px solid rgba(198, 0, 0, .5);
	border-left: 4px solid var(--red);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
}
.bm-console p { margin: 0; }
.bm-console__cmd b { color: var(--accent); }
.bm-caret { display: inline-block; width: 8px; height: 1.05em; margin-left: 3px; vertical-align: -2px; background: var(--red); animation: bm-blink 1s steps(1) infinite; }
@keyframes bm-blink { 50% { opacity: 0; } }
.bm-console__status { display: flex; align-items: center; gap: 8px; margin-top: 6px !important; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #fff; }
.bm-console__dot { flex: 0 0 auto; width: 8px; height: 8px; background: #19e66b; box-shadow: 0 0 8px #19e66b; }
.bm-console.is-busy .bm-console__dot { background: #ff2a2a; box-shadow: 0 0 10px #ff2a2a; animation: bm-blink .5s steps(1) infinite; }
.bm-hint { margin-top: 6px !important; font-size: 11px; letter-spacing: .03em; color: rgba(245, 245, 240, .62); }
.bm-hint--touch { display: none; }
@media (hover: none) {
	.bm-hint--mouse { display: none; }
	.bm-hint--touch { display: inline; }
}

/* ---------- Medidor de furia ---------- */
.bm-rage { --rage: 0; position: absolute; z-index: 4; left: var(--gutter); top: 40%; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.bm-rage__lab { writing-mode: vertical-rl; transform: rotate(180deg); font-family: var(--mb-mono); font-size: 11px; font-weight: 700; letter-spacing: .32em; text-transform: uppercase; color: rgba(245, 245, 240, .8); }
.bm-rage__bar { position: relative; display: block; width: 10px; height: clamp(110px, 21vh, 210px); overflow: hidden; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .25); }
.bm-rage__bar i { position: absolute; inset: 0; background: linear-gradient(to top, var(--blood), #ff2a2a 70%, #ffb000); transform: scaleY(var(--rage)); transform-origin: 50% 100%; }
.bm-rage__pct { min-width: 4ch; font-family: var(--mb-mono); font-size: 12px; text-align: center; color: #fff; }
.bm-hero.is-beast .bm-rage__bar { border-color: #ff2a2a; box-shadow: 0 0 22px #ff2a2a; }
.bm-hero.is-beast .bm-rage__pct { color: #ff2a2a; }

/* ---------- Variaciones V1…V8 ---------- */
.bm-vars { position: absolute; z-index: 4; right: var(--gutter); top: 50%; display: flex; flex-direction: column; gap: 6px; transform: translateY(-56%); }
.ak-page .bm-var {
	display: grid;
	place-items: center;
	width: 46px;
	height: 38px;
	min-height: 0;
	margin: 0;
	padding: 0;
	font-family: var(--mb-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .04em;
	color: rgba(245, 245, 240, .82);
	background: rgba(10, 0, 0, .5);
	border: 1px solid rgba(255, 255, 255, .24);
	border-radius: 0;
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	cursor: pointer;
	transition: color .2s linear, background-color .2s linear, border-color .2s linear, box-shadow .2s linear;
}
.ak-page .bm-var:hover { color: #fff; background: rgba(135, 0, 0, .7); border-color: var(--red); }
.ak-page .bm-var.is-on { color: #fff; background: var(--red); border-color: var(--red); box-shadow: 0 0 20px rgba(198, 0, 0, .75); }
.ak-page .bm-var--roll { margin-top: 6px; font-size: 19px; color: var(--accent); border-color: rgba(255, 224, 0, .5); }

/* ---------- Título BEAST / MODE ---------- */
.bm-center {
	position: relative;
	z-index: 3;
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-end;
	padding: 0 var(--gutter) clamp(16px, 3.6vh, 40px);
	text-align: center;
	pointer-events: none;
}
.bm-center a { pointer-events: auto; }
.bm-titlewrap { perspective: 900px; }
.bm-page .bm-title {
	margin: 0;
	font-family: 'Unbounded', var(--mb-display);
	font-weight: 900;
	font-size: clamp(54px, 10.6vw, 176px);
	line-height: .88;
	letter-spacing: -.045em;
	text-align: center;
	text-transform: uppercase;
	color: #f5f5f0;
	transform-style: preserve-3d;
}
.bm-line { display: block; }
.bm-line--beast { margin-right: .62em; color: var(--red); text-shadow: 0 0 60px rgba(198, 0, 0, .45); transition: color .5s linear; }
.bm-line--mode { margin-left: .62em; }
.bm-hero.is-enter .bm-line--beast { color: #fffffe; }
.bm-box { position: relative; display: inline-block; }
.bm-word { position: relative; display: inline-block; }
/* Capas de glitch RGB (sólo en modo bestia) */
.bm-word::before,
.bm-word::after { content: attr(data-text); position: absolute; left: 0; top: 0; opacity: 0; pointer-events: none; }
.bm-word::before { color: #00e5ff; mix-blend-mode: screen; }
.bm-word::after { color: #ff003c; mix-blend-mode: screen; }
.bm-hero.is-beast .bm-word::before { opacity: .85; animation: bm-gl-a .32s steps(2) infinite; }
.bm-hero.is-beast .bm-word::after { opacity: .85; animation: bm-gl-b .27s steps(2) infinite; }
@keyframes bm-gl-a {
	0% { transform: translate(-5px, 1px); clip-path: inset(8% 0 58% 0); }
	50% { transform: translate(6px, -2px); clip-path: inset(62% 0 6% 0); }
	100% { transform: translate(-3px, 2px); clip-path: inset(30% 0 38% 0); }
}
@keyframes bm-gl-b {
	0% { transform: translate(5px, -1px); clip-path: inset(48% 0 22% 0); }
	50% { transform: translate(-6px, 2px); clip-path: inset(4% 0 70% 0); }
	100% { transform: translate(3px, 0); clip-path: inset(70% 0 4% 0); }
}

/* Gotas de sangre: tallo que crece desde la letra y gota que cae; el filtro "goo" las funde */
.bm-drips { position: absolute; left: 3%; right: 3%; top: 80%; height: 1.5em; filter: url(#bm-goo); pointer-events: none; }
.bm-drip { --w: .07em; position: absolute; top: 0; width: var(--w); margin-left: calc(var(--w) / -2); }
.bm-drip__stalk { display: block; width: 100%; height: 0; background: var(--red); border-radius: 0 0 999px 999px; }
.bm-drip__drop { position: absolute; left: 50%; top: 0; width: calc(var(--w) * 1.7); height: calc(var(--w) * 1.7); margin: calc(var(--w) * -.85) 0 0 calc(var(--w) * -.85); background: var(--red); border-radius: 50%; transform: scale(0); }

.bm-sub { margin: clamp(14px, 2.6vh, 26px) 0 clamp(12px, 2.2vh, 22px); font-family: var(--mb-mono); font-size: 13px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: rgba(245, 245, 240, .88); text-shadow: 0 2px 12px rgba(0, 0, 0, .8); }
.ak-page .bm-enter {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 58px;
	padding: 0 58px;
	font-family: 'Unbounded', var(--mb-display);
	font-size: 14px;
	font-weight: 800;
	letter-spacing: .16em;
	text-transform: uppercase;
	text-decoration: none;
	color: #fff;
	background: rgba(0, 0, 0, .42);
	clip-path: polygon(18px 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 18px 100%, 0 50%);
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	transition: background-color .35s linear, transform .35s var(--ease);
}
/* Borde del botón con puntas: un segundo polígono 2px más adentro */
.ak-page .bm-enter::before { content: ''; position: absolute; inset: 0; z-index: -1; background: rgba(255, 255, 255, .55); clip-path: polygon(18px 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 18px 100%, 0 50%, 2px 50%, 19px calc(100% - 2px), calc(100% - 19px) calc(100% - 2px), calc(100% - 2px) 50%, calc(100% - 19px) 2px, 19px 2px, 2px 50%, 0 50%); }
.ak-page .bm-enter:hover,
.ak-page .bm-enter:focus-visible { color: #fff; background: var(--red); transform: scale(1.08); }

/* ---------- Pie del hero ---------- */
.bm-foot {
	position: relative;
	z-index: 6;
	flex: 0 0 auto;
	display: grid;
	grid-template-columns: minmax(260px, 1fr) auto auto;
	gap: 14px clamp(20px, 3vw, 44px);
	align-items: center;
	/* a la derecha queda libre el lugar del botón flotante de WhatsApp */
	padding: 14px calc(var(--gutter) + 140px) 16px var(--gutter);
	background: rgba(6, 0, 0, .84);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	border-top: 3px solid var(--accent);
}
.bm-foot__meta { margin: 0 0 4px; font-family: var(--mb-mono); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.bm-foot__lead { max-width: 60ch; margin: 0; font-size: clamp(14px, 1.1vw, 17px); line-height: 1.5; color: rgba(245, 245, 240, .86); }
.bm-ctrl { display: flex; align-items: center; gap: 10px; }
.bm-count { margin: 0 6px 0 0; font-family: var(--mb-mono); font-size: 14px; color: rgba(245, 245, 240, .7); white-space: nowrap; }
.bm-idx { display: inline-block; font-family: var(--mb-display); font-weight: 900; font-size: 34px; line-height: 1; letter-spacing: -.02em; vertical-align: -5px; color: var(--accent); }
@media (max-width: 1180px) {
	.bm-foot { grid-template-columns: minmax(0, 1fr) auto; }
	.bm-foot .ak-actions { grid-column: 1 / -1; }
}
/* Pantallas bajas: título algo menor */
@media (max-height: 800px) and (min-width: 701px) {
	.bm-page .bm-title { font-size: clamp(54px, 9vw, 140px); }
	.bm-hint { display: none; }
}

/* ---------- Móvil: todo en columna; furia y variaciones en fila ---------- */
@media (max-width: 700px) {
	.bm-hero { height: auto; min-height: 100svh; padding-top: 60px; }
	.bm-console { position: relative; order: 1; top: auto; left: auto; width: auto; margin: 14px var(--gutter) 0; padding: 10px 12px; font-size: 11px; }
	.bm-rage { position: relative; order: 2; left: auto; top: auto; flex-direction: row; margin: 10px var(--gutter) 0; }
	.bm-rage__lab { writing-mode: horizontal-tb; transform: none; letter-spacing: .2em; }
	.bm-rage__bar { flex: 1 1 auto; width: auto; height: 8px; }
	.bm-rage__bar i { transform: scaleX(var(--rage)); transform-origin: 0 50%; }
	.bm-center { order: 3; min-height: 52vh; padding-bottom: 18px; }
	.bm-vars { position: relative; order: 4; right: auto; top: auto; flex-direction: row; gap: 4px; margin: 0 var(--gutter) 14px; transform: none; }
	.ak-page .bm-var { flex: 1 1 0; width: auto; height: 34px; font-size: 10px; }
	.ak-page .bm-var--roll { margin-top: 0; font-size: 16px; }
	.bm-foot { order: 5; grid-template-columns: 1fr; padding: 14px var(--gutter) 88px; }
	.bm-ctrl { order: -1; }
	.bm-foot .ak-actions .ak-btn { flex: 1 1 auto; }
	.bm-page .bm-title { font-size: clamp(50px, 15.5vw, 96px); }
	.bm-line--beast { margin-right: .3em; }
	.bm-line--mode { margin-left: .3em; }
	.bm-sub { font-size: 11px; letter-spacing: .14em; }
	.ak-page .bm-enter { min-height: 52px; padding: 0 44px; font-size: 12px; }
}

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
	.bm-caret, .bm-console.is-busy .bm-console__dot { animation: none; }
	.bm-wipe, .bm-line--beast { transition: none; }
	.bm-drips { display: none; }
}
