/* =========================================================================
   HANNOTAKUS LIVE 2.0 — misma lógica (js/live.js), diseño cinematográfico
   Solo se animan transform / opacity / clip-path.
   ========================================================================= */
:root {
  --bg: #07050d;
  --panel: rgba(20, 14, 36, .62);
  --line: rgba(255, 255, 255, .08);
  --line2: rgba(255, 255, 255, .14);
  --ink: #f5f1ff;
  --muted: #aaa0c8;
  --pink: #ff3d8b;
  --violet: #8b5cf6;
  --cyan: #22d3ee;
  --amber: #ffc53d;
  --red: #ff2e4d;
  --twitch: #9146ff;
  --grad: linear-gradient(100deg, #ff3d8b 0%, #b14dff 48%, #22d3ee 100%);
  --f-d: "Unbounded", "Arial Black", Impact, sans-serif;
  --f-b: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-m: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --chat-w: 352px;
  --pad: 12px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; overflow: hidden; background: var(--bg); color: var(--ink); font-family: var(--f-b); -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
p { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; border-radius: 8px; }
.ic { width: 1em; height: 1em; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Fondo ---------- */
.bg2 { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.au { position: absolute; width: 60vmax; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, var(--c), transparent 62%); opacity: .5; animation: drift var(--t, 26s) ease-in-out infinite alternate; }
.au--1 { --c: rgba(255, 61, 139, .45); left: -22vmax; top: -26vmax; }
.au--2 { --c: rgba(139, 92, 246, .45); right: -24vmax; bottom: -20vmax; --t: 32s; }
.au--3 { --c: rgba(34, 211, 238, .22); left: 30vw; top: 30vh; --t: 38s; }
@keyframes drift { 50% { transform: translate3d(5vmax, 4vmax, 0) scale(1.1); } 100% { transform: translate3d(-4vmax, 6vmax, 0) scale(.92); } }
.grid2 { position: absolute; inset: 0; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 72px 72px; -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 40%, #000, transparent 75%); mask-image: radial-gradient(ellipse 70% 70% at 50% 40%, #000, transparent 75%); opacity: .6; }
.grain { position: fixed; inset: -100%; z-index: 50; pointer-events: none; opacity: .05; 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%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); animation: grain 1s steps(6) infinite; }
@keyframes grain { 20% { transform: translate(-3%, 2%); } 40% { transform: translate(2%, -3%); } 60% { transform: translate(-2%, 3%); } 80% { transform: translate(3%, 1%); } }

/* ---------- Layout ---------- */
.app {
  display: grid; height: 100svh; padding: var(--pad); row-gap: var(--pad);
  grid-template-columns: minmax(0, 1fr) var(--chat-w);
  grid-template-rows: minmax(0, 1fr) auto;
  transition: grid-template-columns .5s var(--ease);
}
.app[data-chat="off"] { --chat-w: 0px; }
.stage {
  position: relative; grid-area: 1 / 1; min-width: 0; overflow: hidden; isolation: isolate;
  border-radius: 24px; background: #05030a; border: 1px solid var(--line2);
  box-shadow: 0 40px 100px -40px rgba(177, 77, 255, .55);
  animation: in .8s var(--ease) both;
}
.stage::after { content: ""; position: absolute; inset: 0; z-index: 4; border-radius: inherit; padding: 1px; pointer-events: none; background: var(--grad); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); opacity: .5; }
@keyframes in { from { opacity: 0; transform: translateY(16px) scale(.99); } }
.player { position: absolute; inset: 0; display: grid; place-items: center; }
.player iframe { width: 100%; height: 100%; border: 0; display: block; }
.brandchip { position: absolute; z-index: 5; left: 16px; top: 16px; display: inline-flex; align-items: center; gap: 10px; padding: 6px 14px 6px 6px; border-radius: 999px; font-family: var(--f-d); font-weight: 700; font-size: 13px; letter-spacing: -.02em; background: rgba(7, 5, 13, .55); border: 1px solid var(--line2); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); transition: transform .5s var(--spring), opacity .3s; opacity: .85; }
.brandchip:hover { transform: translateY(-2px); opacity: 1; }
.brandchip__mark { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: var(--grad); font-weight: 900; transform: skewX(-6deg); }
.chat { position: relative; grid-area: 1 / 2; overflow: hidden; animation: in .8s var(--ease) .1s both; }
.chat iframe, .chat__note { position: absolute; top: 0; left: var(--pad); width: calc(352px - var(--pad)); height: 100%; border: 0; border-radius: 24px; background: #18181b; }
.chat__note { display: grid; place-content: center; gap: 8px; padding: 24px; text-align: center; color: var(--muted); font-size: 14px; border: 1px solid var(--line2); }
.chat__note b { color: #fff; font-family: var(--f-m); font-size: 12px; letter-spacing: .1em; }

/* ---------- Cargando ---------- */
.loading { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; font-family: var(--f-m); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.loading__ring { width: 48px; height: 48px; border-radius: 50%; background: conic-gradient(var(--pink), var(--violet), var(--cyan), transparent 75%); -webkit-mask: radial-gradient(circle, transparent 55%, #000 57%); mask: radial-gradient(circle, transparent 55%, #000 57%); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Pantalla offline (clases generadas por live.js) ---------- */
.off { position: absolute; inset: 0; overflow: hidden; container-type: size; isolation: isolate; animation: in .8s var(--ease); }
.off__bg { position: absolute; inset: -5%; z-index: -3; background: url("../assets/banner.webp") center / cover no-repeat; animation: kb 36s ease-in-out infinite alternate; }
@keyframes kb { to { transform: scale(1.14) translate3d(-2%, 1.5%, 0); } }
.off::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgba(7, 5, 13, .96) 0%, rgba(7, 5, 13, .86) 44%, rgba(7, 5, 13, .4) 74%, rgba(7, 5, 13, .7) 100%), linear-gradient(0deg, rgba(7, 5, 13, .85), transparent 45%); }
.off::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px); background-size: 48px 48px; -webkit-mask-image: linear-gradient(90deg, #000, transparent 60%); mask-image: linear-gradient(90deg, #000, transparent 60%); }
.off__spark { position: absolute; left: var(--x); top: var(--y); width: var(--s); height: var(--s); color: var(--c); opacity: 0; animation: tw 5s ease-in-out var(--d) infinite; }
.off__spark svg { width: 100%; height: 100%; filter: drop-shadow(0 0 6px currentColor); }
@keyframes tw { 50% { opacity: .9; transform: scale(1) rotate(45deg); } 0%, 100% { transform: scale(.4); } }
.off__left { position: absolute; left: 5.5cqw; top: 10cqh; bottom: 10cqh; display: flex; flex-direction: column; justify-content: center; gap: 2.8cqh; max-width: 58cqw; }
.off__tag { display: inline-flex; align-items: center; gap: .8em; width: max-content; padding: .55em 1.1em; border-radius: 999px; font-family: var(--f-m); font-size: max(10px, 1.25cqw); font-weight: 700; letter-spacing: .22em; background: rgba(255, 255, 255, .07); border: 1px solid var(--line2); }
.off__tag i { width: .65em; height: .65em; border-radius: 50%; background: #8f86a5; animation: dot 2s infinite; }
@keyframes dot { 0% { box-shadow: 0 0 0 0 rgba(143, 134, 165, .6); } 70%, 100% { box-shadow: 0 0 0 .8em rgba(143, 134, 165, 0); } }
.glitch { position: relative; font-family: var(--f-d); font-weight: 900; font-size: max(38px, 11.5cqw); line-height: .86; letter-spacing: -.055em; color: transparent; -webkit-text-stroke: 2px rgba(255, 255, 255, .9); }
.glitch::before { content: attr(data-text); position: absolute; inset: 0; -webkit-text-stroke: 0; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; clip-path: inset(0 100% 0 0); animation: sweep 7s var(--ease) infinite; }
.glitch::after { content: attr(data-text); position: absolute; inset: 0; -webkit-text-stroke: 0; color: var(--cyan); opacity: 0; mix-blend-mode: screen; animation: gl 5s steps(1) infinite; }
@keyframes sweep { 0%, 8% { clip-path: inset(0 100% 0 0); } 40%, 70% { clip-path: inset(0 0 0 0); } 100% { clip-path: inset(0 0 0 100%); } }
@keyframes gl { 0%, 88%, 100% { opacity: 0; transform: none; } 89% { opacity: .7; transform: translate(-.04em, .02em); } 92% { opacity: .7; transform: translate(.03em, -.02em); } 95% { opacity: 0; } }
.off__socials { display: grid; gap: 1.4cqh; }
.off__socials a { display: inline-flex; align-items: center; gap: .7em; width: max-content; font-weight: 800; font-size: max(12px, 1.9cqw); opacity: 0; transform: translateX(-14px); animation: soc .7s var(--ease) forwards; animation-delay: calc(.3s + var(--i) * .08s); transition: color .2s; }
.off__socials a:hover { color: var(--pink); }
.off__socials .ic { font-size: 1.15em; padding: .25em; box-sizing: content-box; border-radius: .5em; background: rgba(255, 255, 255, .08); transition: transform .4s var(--spring), background-color .3s; }
.off__socials a:hover .ic { transform: rotate(-10deg) scale(1.1); background: var(--pink); }
@keyframes soc { to { opacity: 1; transform: none; } }
.off__yt { font-family: var(--f-m); font-weight: 700; font-size: max(10px, 1.2cqw); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.off__yt a { display: block; margin-top: .4em; font-family: var(--f-d); font-size: 1.5em; letter-spacing: -.02em; text-transform: none; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.off__avatar { position: absolute; right: 8cqw; top: 9cqh; width: 15cqw; aspect-ratio: 1; padding: .45cqw; border-radius: 50%; background: conic-gradient(#ff3d8b, #b14dff, #22d3ee, #ffc53d, #ff3d8b); animation: spin 10s linear infinite; box-shadow: 0 0 70px -10px rgba(177, 77, 255, .7); }
.off__avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: .45cqw solid #07050d; animation: spin 10s linear infinite reverse; }
.off__right { position: absolute; right: 4.5cqw; bottom: 7cqh; display: grid; gap: 1.6cqh; width: 31cqw; }
.glass { background: var(--panel); border: 1px solid var(--line2); -webkit-backdrop-filter: blur(14px) saturate(1.3); backdrop-filter: blur(14px) saturate(1.3); border-radius: 18px; }
.next { padding: 1.5cqw 1.7cqw; }
.next__label { font-family: var(--f-m); font-size: max(9px, .95cqw); font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--pink); }
.next__day { margin-top: .35em; font-family: var(--f-d); font-weight: 700; font-size: max(12px, 1.55cqw); letter-spacing: -.02em; }
.next__nums { display: flex; gap: .7cqw; margin-top: 1.2cqh; }
.next__u { flex: 1; display: grid; justify-items: center; padding: .8cqw .4cqw .55cqw; border-radius: 12px; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); overflow: hidden; }
.next__u b { font-family: var(--f-d); font-weight: 900; font-size: max(14px, 2.5cqw); line-height: 1; font-variant-numeric: tabular-nums; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.next__u b.tick { animation: roll .5s var(--ease); }
@keyframes roll { from { transform: translateY(60%); opacity: 0; } }
.next__u small { margin-top: .35em; font-family: var(--f-m); font-size: max(8px, .75cqw); letter-spacing: .14em; color: var(--muted); }
.lastvid { display: grid; grid-template-columns: 42% 1fr; gap: 1.2cqw; align-items: center; padding: .9cqw; text-align: left; transition: transform .5s var(--spring), border-color .3s; }
.lastvid:hover { transform: translateY(-4px); border-color: rgba(255, 61, 139, .6); }
.lastvid__img { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 12px; background: #000; }
.lastvid__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.lastvid:hover .lastvid__img img { transform: scale(1.08); }
.lastvid__img .ic { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: max(28px, 3.4cqw); height: max(28px, 3.4cqw); padding: .7cqw; border-radius: 50%; color: #fff; background: rgba(255, 255, 255, .18); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: background-color .3s; }
.lastvid:hover .lastvid__img .ic { background: var(--pink); }
.lastvid__k { font-family: var(--f-m); font-size: max(8px, .85cqw); font-weight: 700; letter-spacing: .18em; color: var(--pink); text-transform: uppercase; }
.lastvid__t { margin-top: .35em; font-size: max(10px, 1.15cqw); font-weight: 700; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@container (max-width: 560px) { .off__right, .off__avatar, .off__yt { display: none; } .off__left { max-width: 90cqw; } }

/* ---------- Reproductor de Kick sin marca (recorte de franjas superior e inferior) ---------- */
.kwrap { position: absolute; inset: 0; overflow: hidden; background: #000; container-type: size; }
/* El video es 16:9: si el hueco no lo es, se agranda un poco para no dejar franjas negras
   (solo si la diferencia es pequeña: recorta como mucho un 8 % del borde). */
.player .kwrap > iframe { position: absolute !important; inset: auto !important; left: 50% !important; top: 50% !important; translate: -50% -50%; border: 0; pointer-events: none;
  width: 100%; height: 100% !important; }
@container (min-aspect-ratio: 1.64) and (max-aspect-ratio: 1.93) {
  .player .kwrap > iframe { width: max(100cqw, 177.78cqh); height: max(100cqh, 56.25cqw) !important; }
}
/* Bandas que tapan la marca de Kick durante los primeros segundos (después Kick la oculta sola) */
/* Telón breve mientras carga el reproductor de Kick (solo entonces muestra su logo y barras) */
.kwrap__curtain { position: absolute; inset: 0; z-index: 2; display: grid; place-content: center; justify-items: center; gap: 14px; background: radial-gradient(ellipse at center, #15101f, #000 70%); color: rgba(255,255,255,.75); font-weight: 600; letter-spacing: .02em; pointer-events: none; opacity: 0; transition: opacity .8s var(--ease); }
.kwrap.is-masked .kwrap__curtain { opacity: 1; transition: none; }
.kwrap.is-ended .kwrap__curtain { opacity: 1; transition: none; }
.kwrap__curtain-e { display: none; font-size: 18px; color: #fff; }
.kwrap.is-ended .kwrap__curtain-e { display: block; }
.kwrap.is-ended .kwrap__curtain-t, .kwrap.is-ended .loading__ring, .kwrap.is-ended .kwrap__sound, .kwrap.is-ended .kwrap__ctrls { display: none; }
.kwrap:not(.is-masked) .kwrap__curtain .loading__ring { animation: none; }
.kwrap.is-masked .kwrap__sound { top: auto; bottom: 18%; }
.kwrap__shield { position: absolute; inset: 0; z-index: 1; }
.kwrap__sound { position: absolute; z-index: 3; left: 50%; top: 50%; translate: -50% -50%; display: inline-flex; align-items: center; gap: 10px; padding: 14px 24px; border-radius: 999px; font-weight: 800; font-size: 15px; color: #fff; background: var(--grad); box-shadow: 0 20px 50px -14px rgba(255, 61, 139, .8); transition: transform .4s var(--spring), opacity .3s; }
.kwrap__sound:hover { transform: scale(1.06); }
.kwrap.is-sound .kwrap__sound { opacity: 0; pointer-events: none; }
.kwrap__ctrls { position: absolute; z-index: 3; left: 14px; bottom: 14px; display: flex; gap: 8px; opacity: 0; transition: opacity .3s; }
.kwrap:hover .kwrap__ctrls, .kwrap:focus-within .kwrap__ctrls, .kwrap.is-sound .kwrap__ctrls:hover { opacity: 1; }
.kwrap__ctrls button { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; font-size: 17px; color: #fff; background: rgba(7, 5, 13, .7); border: 1px solid rgba(255, 255, 255, .2); backdrop-filter: blur(8px); }
.kwrap__ctrls button:hover { background: var(--twitch); }
.kwrap:fullscreen { background: #000; }

/* ---------- Modo película: emisión de Kick en grande + cámara de Twitch en pequeño ---------- */
.player iframe { position: absolute; inset: 0; }
.pip {
  position: absolute; z-index: 6; right: 16px; bottom: 16px; width: clamp(220px, 24%, 380px); aspect-ratio: 16 / 9.8;
  display: grid; grid-template-rows: auto 1fr; overflow: hidden; border-radius: 16px;
  background: #000; border: 1px solid rgba(255, 255, 255, .25); box-shadow: 0 24px 60px -16px rgba(0, 0, 0, .9), 0 0 0 1px rgba(145, 70, 255, .4);
  animation: in .6s var(--ease); transition: width .4s var(--ease), transform .4s var(--ease);
}
.pip iframe { position: relative !important; inset: auto; width: 100%; height: 100%; border: 0; }
.pip__bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 8px 6px 12px; font-size: 11px; font-weight: 800; background: rgba(13, 9, 24, .92); }
.pip__bar span { display: inline-flex; align-items: center; gap: 6px; }
.pip__bar i { width: 7px; height: 7px; border-radius: 50%; background: var(--red); box-shadow: 0 0 8px var(--red); }
.pip__bar button { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; font-size: 16px; font-weight: 900; background: rgba(255, 255, 255, .1); }
.pip__bar button:hover { background: var(--twitch); }
.pip.is-min { width: 190px; aspect-ratio: auto; }
.pip.is-min iframe { display: none; }
.status.is-peli { background: rgba(255, 197, 61, .16); border-color: rgba(255, 197, 61, .5); }
.status.is-peli i { background: var(--amber); }
.status.is-peli i::after { border-color: var(--amber); }
@media (max-width: 820px) { .pip { width: 42%; right: 8px; bottom: 8px; } }

/* Video de YouTube dentro del escenario */
.yt { position: absolute; inset: 0; z-index: 3; display: grid; grid-template-rows: auto minmax(0, 1fr); background: #000; animation: in .5s var(--ease); }
.yt iframe { width: 100%; height: 100%; border: 0; }
.yt__bar { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 12px; background: var(--bg); border-bottom: 1px solid var(--line); }
.yt__x { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 999px; font-size: 12px; font-weight: 800; background: rgba(255, 255, 255, .08); border: 1px solid var(--line2); transition: background-color .2s; }
.yt__x:hover { background: var(--pink); }

/* ---------- Dock inferior ---------- */
.bar {
  grid-column: 1 / -1; grid-row: 2; position: relative; z-index: 10;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; min-height: 62px; padding: 8px 10px 8px 14px;
  border-radius: 22px; background: rgba(13, 9, 24, .7); border: 1px solid var(--line2);
  -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .8);
  animation: in .8s var(--ease) .15s both;
}
.bar__l, .bar__r { display: flex; align-items: center; gap: 12px; min-width: 0; }
.bar__r { justify-content: flex-end; }
.bar__c { display: flex; align-items: center; gap: 8px; }
.sw { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 800; color: var(--muted); user-select: none; }
.sw__track { position: relative; width: 40px; height: 22px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid var(--line2); transition: background-color .3s; }
.sw__track::after { content: ""; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .4); transition: transform .45s var(--spring); }
.sw[aria-checked="true"] .sw__track { background: var(--grad); border-color: transparent; }
.sw[aria-checked="true"] .sw__track::after { transform: translateX(18px); }
.sw .ic { font-size: 16px; transition: color .2s; }
.sw[aria-checked="true"] { color: #fff; }
.sw:hover { color: #fff; }
.sw[aria-checked="true"].sw--bell .ic { animation: ring 1.2s var(--ease); transform-origin: 50% 10%; }
@keyframes ring { 15% { transform: rotate(18deg); } 30% { transform: rotate(-16deg); } 45% { transform: rotate(10deg); } 60% { transform: rotate(-6deg); } 75% { transform: none; } }
.status { display: inline-flex; align-items: center; gap: 9px; min-width: 0; padding: 7px 14px 7px 12px; border-radius: 999px; font-family: var(--f-m); font-size: 11px; font-weight: 700; letter-spacing: .12em; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); }
.status i { position: relative; width: 8px; height: 8px; border-radius: 50%; background: #6f6690; flex: none; }
.status__t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 26vw; font-family: var(--f-b); font-weight: 600; letter-spacing: 0; color: var(--muted); }
.status.is-live { background: rgba(255, 46, 77, .16); border-color: rgba(255, 46, 77, .5); }
.status.is-live i { background: var(--red); }
.status.is-live i::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--red); animation: ping 1.5s var(--ease) infinite; }
.status.is-live b { color: #fff; }
@keyframes ping { from { transform: scale(.4); opacity: 1; } to { transform: scale(1.7); opacity: 0; } }

.bb {
  --c: #444;
  position: relative; display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 16px; overflow: hidden; isolation: isolate;
  font-size: 13px; font-weight: 800; color: #fff; border-radius: 999px;
  background: color-mix(in srgb, var(--c) 22%, transparent); border: 1px solid color-mix(in srgb, var(--c) 55%, transparent);
  transition: transform .5s var(--spring), background-color .3s, box-shadow .4s var(--ease);
}
.bb::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%); transform: translateX(-120%); transition: transform .8s var(--ease); }
.bb:hover { transform: translateY(-3px); background: var(--c); box-shadow: 0 12px 30px -10px var(--c); }
.bb:hover::before { transform: translateX(120%); }
.bb:active { transform: scale(.96); }
.bb .ic { font-size: 16px; color: var(--c); transition: color .3s; }
.bb:hover .ic { color: #fff; }
.bb--dark:hover { color: #07050d; }
.bb--dark:hover .ic { color: #07050d; }
.bb--soft { --c: #9146ff; }
.bb[aria-expanded="true"] { background: var(--c); box-shadow: 0 0 0 2px rgba(255, 255, 255, .7); }
.bb[aria-expanded="true"] .ic { color: #fff; }

/* Menú de redes */
.pop {
  position: absolute; bottom: calc(100% + 12px); left: 50%; translate: -50% 0; z-index: 20;
  width: min(92vw, 380px); padding: 16px; border-radius: 22px;
  background: rgba(16, 11, 30, .94); border: 1px solid var(--line2); box-shadow: 0 30px 70px -20px rgba(0, 0, 0, .9);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); transform-origin: 50% 100%;
  opacity: 0; transform: translateY(12px) scale(.94); pointer-events: none; visibility: hidden;
  transition: opacity .25s, transform .45s var(--spring), visibility 0s .45s;
}
.pop.is-open { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition: opacity .25s, transform .45s var(--spring), visibility 0s; }
.pop__t { margin: 2px 4px 12px; font-family: var(--f-m); font-size: 10px; font-weight: 700; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }
.pop__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pop__grid a { --c: #fff; display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 14px; font-size: 13px; font-weight: 800; background: rgba(255, 255, 255, .05); border: 1px solid var(--line); opacity: 0; transform: translateY(10px); transition: background-color .25s, border-color .25s, transform .4s var(--spring), opacity .3s; }
.pop.is-open .pop__grid a { opacity: 1; transform: none; transition-delay: calc(var(--i) * 40ms); }
.pop__grid a:hover { background: color-mix(in srgb, var(--c) 22%, transparent); border-color: color-mix(in srgb, var(--c) 60%, transparent); transform: translateY(-3px); transition-delay: 0s; }
.pop__grid .ic { font-size: 18px; color: var(--c); }
.pop__grid a.wide { grid-column: 1 / -1; justify-content: center; }

.toast { position: fixed; left: 50%; bottom: 96px; z-index: 30; translate: -50% 0; max-width: min(92vw, 440px); padding: 12px 18px; border-radius: 14px; font-size: 13px; font-weight: 700; color: #07050d; background: #fff; box-shadow: 0 20px 50px -14px rgba(0, 0, 0, .8); opacity: 0; transform: translateY(12px); transition: opacity .25s, transform .45s var(--spring); pointer-events: none; }
.toast.is-on { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) { .bb span { display: none; } .bb { width: 42px; padding: 0; justify-content: center; } .status__t { display: none; } }
@media (max-width: 820px) {
  :root { --pad: 8px; }
  body { overflow: auto; }
  .app { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr) auto; }
  .stage { grid-area: 1 / 1; aspect-ratio: 16 / 9; border-radius: 18px; }
  .chat { grid-area: 2 / 1; }
  .chat iframe, .chat__note { left: 0; width: 100%; border-radius: 18px; }
  .app[data-chat="off"] .chat { display: none; }
  .app[data-chat="off"] { grid-template-rows: auto 1fr auto; }
  .bar { grid-row: 3; grid-template-columns: auto 1fr auto; padding: 8px; border-radius: 18px; margin-bottom: env(safe-area-inset-bottom); }
  .bar__c { justify-content: center; flex-wrap: wrap; gap: 6px; }
  .sw__label { display: none; }
  .brandchip__name { display: none; }
  .toast { bottom: 90px; }
}
@media (max-width: 520px) {
  .status, .bb--soft, .brandchip { display: none; }
  .bar { gap: 6px; }
  .bar__c { flex-wrap: nowrap; gap: 4px; }
  .bb { width: 34px; height: 34px; }
  .bb .ic { font-size: 15px; }
  .sw__track { width: 36px; }
  .sw[aria-checked="true"] .sw__track::after { transform: translateX(14px); }
}
@container (max-width: 420px) { .off__tag { display: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .off__socials a { opacity: 1; transform: none; }
}
