/* M.H.A Support Station — GPU-friendly, fault isolated */
#mha-support-station {
  -webkit-font-smoothing: antialiased;
  pointer-events: none;
}
#mha-support-station * {
  pointer-events: auto;
}

#mha-support-station .mha-fab {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, #fde047 0%, #ca8a04 55%, #eab308 100%);
  color: #0a0a0a;
  border: 2px solid #fef08a;
  box-shadow: 0 0 22px rgba(229, 184, 11, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.45);
  font-weight: 900;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
#mha-support-station .mha-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 0 28px rgba(229, 184, 11, 0.75);
}
#mha-support-station .mha-fab:active {
  transform: scale(0.95);
}

#mha-chat-box {
  width: min(380px, calc(100vw - 1.5rem));
  height: min(520px, calc(100vh - 6rem));
  background: linear-gradient(180deg, #070a10 0%, #05070a 100%);
  border: 2px solid #e5b80b;
  border-radius: 0.85rem;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.95), 0 0 0 1px rgba(229, 184, 11, 0.15);
  transform: translateZ(0);
  will-change: transform, opacity;
}

#mha-chat-feed {
  transform: translateZ(0);
  will-change: scroll-position;
  content-visibility: auto;
  background-color: #05070a;
  background-image: radial-gradient(circle at 1px 1px, rgba(229, 184, 11, 0.04) 1px, transparent 0);
  background-size: 12px 12px;
}

#mha-support-station .mha-btn-quick {
  background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
  color: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-weight: 800;
  transition: transform 0.1s ease;
}
#mha-support-station .mha-btn-quick:active {
  transform: scale(0.97);
}

#mha-support-station .mha-msg-user {
  align-self: flex-end;
  max-width: 88%;
  background: linear-gradient(135deg, #1e293b, #0f172a);
  border: 1px solid #334155;
  border-radius: 0.75rem 0.75rem 0.15rem 0.75rem;
}

#mha-support-station .mha-msg-ai {
  background: rgba(30, 58, 138, 0.18);
  border-left: 4px solid #e5b80b;
  border-radius: 0 0.5rem 0.5rem 0;
}

#mha-support-station .mha-msg-system {
  background: rgba(34, 197, 94, 0.08);
  border-left: 4px solid #22c55e;
  border-radius: 0 0.5rem 0.5rem 0;
}

#mha-support-station .mha-scrollbar::-webkit-scrollbar {
  width: 4px;
}
#mha-support-station .mha-scrollbar::-webkit-scrollbar-thumb {
  background: #e5b80b;
  border-radius: 10px;
}

@keyframes mhaSlideIn {
  from {
    transform: translateY(12px) translateZ(0);
    opacity: 0;
  }
  to {
    transform: translateY(0) translateZ(0);
    opacity: 1;
  }
}
@keyframes mhaPop {
  from {
    transform: scale(0.92) translateZ(0);
    opacity: 0;
  }
  to {
    transform: scale(1) translateZ(0);
    opacity: 1;
  }
}
#mha-chat-box.mha-open {
  animation: mhaSlideIn 0.28s ease-out;
}
#mha-chat-box .mha-pop {
  animation: mhaPop 0.35s ease-out;
}

#mha-support-station .mha-typing {
  display: inline-flex;
  gap: 4px;
  align-items: center;
}
#mha-support-station .mha-typing span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #e5b80b;
  animation: mhaDot 1s infinite ease-in-out;
}
#mha-support-station .mha-typing span:nth-child(2) { animation-delay: 0.15s; }
#mha-support-station .mha-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes mhaDot {
  0%, 80%, 100% { opacity: 0.25; transform: scale(0.85); }
  40% { opacity: 1; transform: scale(1); }
}
