  #mascot-wrap {
    position: fixed;
    bottom: 0; left: 0;
    z-index: 999;
    display: flex;
    align-items: flex-end;
    gap: 0;
    opacity: 1;
    pointer-events: none;
    /* começa escondida embaixo */
    transform: translateY(110%);
    transition: transform 0.7s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.4s ease;
  }
  #mascot-wrap.visible {
    transform: translateY(0);
  }
  #mascot-wrap.hide {
    transform: translateY(110%);
    transition: transform 0.5s ease-in;
  }

  #mascot-img {
    width: 220px;
    display: block;
    filter: drop-shadow(0 8px 32px rgba(132,90,223,0.45));
    flex-shrink: 0;
    animation: mascotFloat 4s ease-in-out infinite;
  }
  @keyframes mascotFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
  }

  #mascot-bubble {
    position: absolute;
    bottom: 210px;
    left: 100px;
    background: rgba(18,14,40,0.96);
    border: 1px solid rgba(132,90,223,0.5);
    border-radius: 18px 18px 18px 4px;
    padding: 16px 20px;
    width: max-content;
    max-width: min(250px, calc(100vw - 220px));
    box-shadow: 0 8px 40px rgba(0,0,0,0.5), 0 0 0 1px rgba(132,90,223,0.15);
    pointer-events: auto;
    opacity: 0;
    transform: scale(0.85) translateY(8px);
    transform-origin: bottom left;
    transition: opacity 0.4s ease 0.5s, transform 0.4s ease 0.5s;
  }
  #mascot-wrap.visible #mascot-bubble {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
  /* quando a Victoria sai de cena, o balão some junto (vence o opacity inline do mascotSay) */
  #mascot-wrap:not(.visible) #mascot-bubble {
    opacity: 0 !important;
    transition: opacity 0.3s ease;
  }

  /* Triângulo do balão */
  #mascot-bubble::before {
    content: '';
    position: absolute;
    bottom: -8px; left: 20px;
    width: 16px; height: 8px;
    background: rgba(18,14,40,0.96);
    clip-path: polygon(0 0, 100% 0, 50% 100%);
    border-left: 1px solid rgba(132,90,223,0.5);
    border-right: 1px solid rgba(132,90,223,0.5);
  }

  #mascot-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    line-height: 1.6;
    color: rgba(240,240,248,0.9);
  }

  @media (max-width: 480px) {
    #mascot-img { width: 170px; }
    #mascot-bubble { bottom: 185px; left: 78px; max-width: min(220px, calc(100vw - 170px)); }
    #mascot-glow { width: 210px; }
  }
  #mascot-text strong {
    color: var(--purple-light);
    font-weight: 600;
  }

  /* Indicador de digitando */
  .typing-dots {
    display: inline-flex; gap: 4px; align-items: center;
    margin-top: 8px;
  }
  .typing-dots span {
    width: 5px; height: 5px; border-radius: 50%;
    background: var(--purple-light);
    animation: typingBounce 1.2s ease-in-out infinite;
  }
  .typing-dots span:nth-child(2) { animation-delay: 0.2s; }
  .typing-dots span:nth-child(3) { animation-delay: 0.4s; }
  @keyframes typingBounce {
    0%,60%,100% { transform: translateY(0); opacity: 0.4; }
    30% { transform: translateY(-5px); opacity: 1; }
  }

  /* Botão fechar */
  #mascot-close {
    position: absolute;
    top: 8px; right: 8px;
    width: 20px; height: 20px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,0.06);
    border-radius: 50%; cursor: pointer;
    color: rgba(240,240,248,0.4);
    font-size: 0.7rem; font-weight: 700;
    pointer-events: auto;
    transition: background 0.2s, color 0.2s;
    line-height: 1;
  }
  #mascot-close:hover { background: rgba(255,255,255,0.12); color: rgba(240,240,248,0.8); }

  /* Glow roxo nos pés da personagem */
  #mascot-glow {
    position: absolute;
    bottom: 0; left: -20px;
    width: 240px; height: 60px;
    background: radial-gradient(ellipse at center bottom, rgba(132,90,223,0.35) 0%, transparent 70%);
    pointer-events: none;
  }
