/* ms-mascot.v1-20261001.css — Escenario de la mascota M y globito de diálogo (las seis salas). Decorativo: sin clics. */
.ms-mascot {
  position: fixed;
  inset: 0;
  z-index: 79; /* apenas sobre el botón M (78); por debajo de modales y juegos */
  pointer-events: none;
  contain: layout style;
}
.ms-mascot__stage {
  position: fixed;
  left: var(--ms-mascot-left, auto);
  bottom: var(--ms-mascot-bottom, 0);
  width: var(--ms-mascot-w, 220px);
  height: var(--ms-mascot-h, 260px);
  opacity: 0;
  visibility: hidden;
  transition: opacity .18s ease, visibility 0s linear .18s;
}
.ms-mascot.is-on .ms-mascot__stage { opacity: 1; visibility: visible; transition: opacity .12s ease; }

.ms-mascot__bubble {
  --ms-bubble-a: #ff3fa8;
  --ms-bubble-b: #ffcf40;
  position: fixed;
  right: var(--ms-mascot-bubble-right, 90px);
  bottom: var(--ms-mascot-bubble-bottom, 160px);
  max-width: var(--ms-mascot-bubble-max, 230px);
  padding: 11px 15px 12px;
  border-radius: 18px 18px 6px 18px;
  color: #fff;
  font: 750 14px/1.38 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: .005em;
  text-wrap: pretty;
  background:
    linear-gradient(#1b0b24e8, #12071ae8) padding-box,
    linear-gradient(135deg, var(--ms-bubble-b), var(--ms-bubble-a)) border-box;
  border: 1.5px solid transparent;
  box-shadow: 0 14px 34px #000a, 0 0 22px color-mix(in srgb, var(--ms-bubble-a) 28%, transparent);
  backdrop-filter: blur(12px) saturate(1.2);
  opacity: 0;
  visibility: hidden;
  transform: translate3d(10px, 8px, 0) scale(.86);
  transform-origin: 100% 100%;
  transition: opacity .2s ease, transform .2s ease, visibility 0s linear .2s;
}
.ms-mascot__bubble.is-on {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity .22s ease, transform .38s cubic-bezier(.2, 1.4, .4, 1);
}
.ms-mascot__bubble::after { /* colita hacia la mascota */
  content: "";
  position: absolute;
  right: -7px;
  bottom: 9px;
  width: 14px;
  height: 14px;
  background: #13071b;
  border-right: 1.5px solid var(--ms-bubble-a);
  border-bottom: 1.5px solid var(--ms-bubble-a);
  transform: rotate(-45deg);
  border-bottom-right-radius: 3px;
}
.ms-mascot__text { display: block; min-height: 1.38em; }
.ms-mascot__bubble.has-cta { pointer-events: auto; }
.ms-mascot__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  margin-top: 9px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  color: #1c0a00;
  font: 850 14px/1 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  background: linear-gradient(135deg, #ffe58a, #ffb300 55%, #ff8a00);
  box-shadow: 0 6px 18px #ffb30055, inset 0 1px 0 #fff8;
  cursor: pointer;
  touch-action: manipulation;
}
.ms-mascot__cta[hidden] { display: none; }
.ms-mascot__cta:hover { filter: brightness(1.06); }
.ms-mascot__cta:active { transform: scale(.97); }
.ms-mascot__cta:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
/* Botón para silenciar o activar la voz de la M (esquina del globito; zona táctil ampliada). */
.ms-mascot__mute {
  position: absolute;
  top: -12px;
  right: -12px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1.5px solid var(--ms-bubble-a);
  border-radius: 50%;
  color: #fff;
  font: 400 14px/1 system-ui, sans-serif;
  background: #1b0b24;
  box-shadow: 0 4px 12px #0009;
  pointer-events: auto;
  cursor: pointer;
  touch-action: manipulation;
}
.ms-mascot__mute::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; }
.ms-mascot__mute:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.ms-mascot__sr {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.ms-mascot[data-room="celuapuestas"] .ms-mascot__bubble { --ms-bubble-a: #ef4c7e; --ms-bubble-b: #ffd166; }
.ms-mascot[data-room="betados"] .ms-mascot__bubble { --ms-bubble-a: #f49a1b; --ms-bubble-b: #ffe08a; }
.ms-mascot[data-room="tioricojuegos"] .ms-mascot__bubble { --ms-bubble-a: #f1871c; --ms-bubble-b: #ffd27a; }
.ms-mascot[data-room="ganamos"] .ms-mascot__bubble { --ms-bubble-a: #d53dde; --ms-bubble-b: #ffcf40; }
.ms-mascot[data-room="futurebet"] .ms-mascot__bubble { --ms-bubble-a: #19b8ff; --ms-bubble-b: #b388ff; }

/* Mientras la M actúa afuera, el logo plano del botón se achica y se apaga; al volver, reaparece con su rebote. */
.multisala-actions .multisala-trigger.ms-mascot-out img {
  animation: none !important;
  opacity: 0;
  transform: scale(.55) !important;
  transition: opacity .16s ease, transform .2s ease;
}

@media (prefers-reduced-motion: reduce) {
  .ms-mascot { display: none; }
}

/* Modo ayudante (carga y retiro): la M camina sobre el fondo del modal, fuera del recuadro (arriba o al costado), y el
   globito se ubica con coordenadas propias. Sigue sin capturar toques, salvo el botón del globito. */
.ms-mascot.is-helper { z-index: 95; }
.ms-mascot.is-helper .ms-mascot__bubble {
  right: auto;
  bottom: auto;
  left: var(--ms-mascot-bubble-left, 12px);
  top: var(--ms-mascot-bubble-top, 12px);
  max-width: var(--ms-mascot-bubble-max, 260px);
  border-radius: 18px 18px 18px 6px;
  transform-origin: 0 100%;
}
.ms-mascot.is-helper .ms-mascot__bubble::after { display: none; }

/* Página de retiros: asistente flotante abajo a la derecha; el globito, arriba de la M y con la colita hacia ella. */
.ms-mascot.is-helper.is-dock .ms-mascot__bubble {
  left: auto;
  top: auto;
  right: var(--ms-mascot-bubble-right, 12px);
  bottom: var(--ms-mascot-bubble-bottom, 170px);
  border-radius: 18px 18px 6px 18px;
  transform-origin: 100% 100%;
}
.ms-mascot.is-helper.is-dock .ms-mascot__bubble::after { display: block; right: 26px; bottom: -8px; transform: rotate(45deg); }
/* Mientras se escribe en pantallas chicas (teclado abierto), nada tapa el campo. */
.ms-mascot.is-helper.is-hushed .ms-mascot__stage,
.ms-mascot.is-helper.is-hushed .ms-mascot__bubble { visibility: hidden !important; opacity: 0 !important; transition: none !important; }
