/* Widget Container */
#customChatWidget {
  position: fixed;
  bottom: 100px;
  right: -160px;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: slideRight 1.2s ease forwards;
  z-index: 99;
}

/* Avatar */
.avatar-container {
  position: relative;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  background: white;
  border: 3px solid #0b5d7e;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.avatar {
  width: 42px;
  height: 42px;
}

/* Waving hand */
.wave-hand {
  position: absolute;
  top: -10px;
  right: -10px;
  animation: wave 1.5s ease-in-out infinite;
  font-size: 18px;
}

/* Bubble */
.chat-greet {
  background: #0b5d7e;
  color: white;
  padding: 6px 12px;
  border-radius: 14px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  animation: showBubble 1.5s ease 1.2s forwards;
  position: relative;
  white-space: nowrap;
  transition: opacity 0.8s ease;
}

/* Arrow pointing to avatar */
.chat-greet .arrow {
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 8px solid #0b5d7e;
  position: absolute;
  left: -7px;
  animation: bounceArrow 1.5s ease-in-out infinite;
}

/* Animations */
@keyframes slideRight {
  to { right: 10px; }
}

@keyframes wave {
  0% { transform: rotate(0); }
  50% { transform: rotate(20deg); }
  100% { transform: rotate(0); }
}

@keyframes showBubble {
  0% { opacity: 0; transform: translateY(10px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes bounceArrow {
  0% { transform: translateX(0); }
  50% { transform: translateX(-2px); }
  100% { transform: translateX(0); }
}

/* Mobile View Fix â€” move widget above bottom nav */
@media (max-width: 768px) {
  #customChatWidget {
    bottom: 14% !important;
    right: 2% !important;
    transform: scale(0.9);
  }

  .chat-greet {
    font-size: 10px;
    padding: 5px 10px;
    /*display: none;*/
  }

  .avatar-container {
    width: 44px;
    height: 44px;
  }

  .avatar {
    width: 30px;
    height: 30px;
  }
}
