/**
 * VetCare Marketing - Chatbot Styles
 * @description Styles for chatbot modal and floating button
 * @author VetCare Team
 * @version 1.0.0
 */

/* ==========================================================================
   CHATBOT OVERLAY
   ========================================================================== */

.chatbot-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(5, 10, 18, 0.95);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.chatbot-overlay--visible {
  opacity: 1;
  visibility: visible;
}

/* ==========================================================================
   CHATBOT CONTAINER
   ========================================================================== */

.chatbot-container {
  position: relative;
  width: 100%;
  max-width: 500px;
  height: 80vh;
  max-height: 700px;
  background: #0d1520;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  transform: scale(0.95) translateY(20px);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.chatbot-overlay--visible .chatbot-container {
  transform: scale(1) translateY(0);
}

@media (min-width: 640px) {
  .chatbot-container {
    width: 90%;
    height: 85vh;
  }
}

/* ==========================================================================
   CHATBOT CLOSE BUTTON
   ========================================================================== */

.chatbot-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  color: #ffffff;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.chatbot-close:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.chatbot-close:active {
  transform: scale(0.95);
}

.chatbot-close svg {
  width: 20px;
  height: 20px;
}

/* ==========================================================================
   CHATBOT IFRAME
   ========================================================================== */

.chatbot-iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: transparent;
}

/* ==========================================================================
   CHATBOT DECORATIVE DOTS
   ========================================================================== */

.chatbot-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #00d1b2;
  border-radius: 50%;
  opacity: 0.5;
}

.chatbot-dot--tl {
  top: 20px;
  left: 20px;
}

.chatbot-dot--br {
  bottom: 20px;
  right: 20px;
}

/* ==========================================================================
   CHATBOT FLOATING BUTTON
   ========================================================================== */

.chatbot-floating-button {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  background: #00d1b2;
  border: none;
  border-radius: 50%;
  box-shadow:
    0 4px 6px -1px rgba(0, 209, 178, 0.3),
    0 2px 4px -1px rgba(0, 209, 178, 0.2),
    0 10px 15px -3px rgba(0, 209, 178, 0.2);
  cursor: pointer;
  transition:
    transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.2s ease;
}

.chatbot-floating-button:hover {
  transform: scale(1.1);
  box-shadow:
    0 10px 15px -3px rgba(0, 209, 178, 0.4),
    0 4px 6px -2px rgba(0, 209, 178, 0.3),
    0 20px 25px -5px rgba(0, 209, 178, 0.3);
}

.chatbot-floating-button:active {
  transform: scale(0.95);
}

.chatbot-floating-button:focus {
  outline: 2px solid #00d1b2;
  outline-offset: 2px;
}

.chatbot-floating-button .material-symbols-outlined {
  font-size: 28px;
  color: #050a12;
}

/* ==========================================================================
   CHATBOT PING ANIMATION
   ========================================================================== */

.chatbot-ping {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #00d1b2;
  opacity: 0;
}

.chatbot-ping--animate {
  animation: chatbot-ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes chatbot-ping {
  75%,
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

/* ==========================================================================
   RESPONSIVE ADJUSTMENTS
   ========================================================================== */

@media (max-width: 640px) {
  .chatbot-floating-button {
    bottom: 16px;
    right: 16px;
    width: 56px;
    height: 56px;
  }

  .chatbot-floating-button .material-symbols-outlined {
    font-size: 24px;
  }

  .chatbot-container {
    height: 100vh;
    max-height: none;
    border-radius: 0;
  }

  .chatbot-close {
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
  }
}

/* ==========================================================================
   ACCESSIBILITY
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .chatbot-overlay,
  .chatbot-container,
  .chatbot-close,
  .chatbot-floating-button,
  .chatbot-ping--animate {
    transition: none;
    animation: none;
  }
}

.chatbot-floating-button:focus-visible {
  outline: 2px solid #00d1b2;
  outline-offset: 2px;
}

/* ==========================================================================
   PRINT STYLES
   ========================================================================== */

@media print {
  .chatbot-overlay,
  .chatbot-floating-button {
    display: none !important;
  }
}
