/* Chat toggle squish and bounce animation */
.chat-toggle-btn i.squish-bounce-open {
  animation: squishBounceOpen 0.5s cubic-bezier(0.68,-0.55,0.27,1.55);
}
.chat-toggle-btn i.squish-bounce-close {
  animation: squishBounceClose 0.45s cubic-bezier(0.68,-0.55,0.27,1.55);
}

@keyframes squishBounceOpen {
  0% { transform: scale(1,1); }
  20% { transform: scale(1.25,0.7); }
  40% { transform: scale(0.85,1.3); }
  60% { transform: scale(1.15,0.85); }
  80% { transform: scale(0.95,1.08); }
  100% { transform: scale(1,1); }
}
@keyframes squishBounceClose {
  0% { transform: scale(1,1); }
  30% { transform: scale(1.2,0.7); }
  60% { transform: scale(0.7,1.2); }
  80% { transform: scale(1.05,0.95); }
  100% { transform: scale(1,1); }
}
/* Liquid Glass Chat Theme - Shared Styles */
/* Universal liquid glass chat styles for all pages */

/* Updated Chat Popup Styling with Perfect Liquid Glass Theme Match */
.chat-popup {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 1111px;
  height: 747px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(40px) saturate(180%);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1), 
              inset 0 1px 0 rgba(255, 255, 255, 0.4);
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 10000;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.chat-popup.active {
  display: flex;
  animation: slideUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes slideUp {
  from { 
    transform: translateY(100%) scale(0.9);
    opacity: 0;
  }
  to { 
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.chat-popup-header {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  color: rgba(0, 0, 0, 0.9) !important;
  padding: 16px 20px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.1em;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.1);
  position: relative;
  z-index: 20;
}

.chat-popup-body {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.02);
  /* Enhance scrollbar styling */
}

.chat-popup-body::-webkit-scrollbar {
  width: 8px;
}

.chat-popup-body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.chat-popup-body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}

.chat-popup-body::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.3);
}

.chat-popup-input {
  display: flex;
  border-top: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
}

.chat-popup-input input {
  flex: 1;
  border: none;
  padding: 16px 20px;
  outline: none;
  background: transparent;
  color: rgba(0, 0, 0, 0.95) !important;
  font-size: 1em;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.1);
  /* Enhanced mobile responsiveness */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  /* Prevent zoom on focus for mobile */
  font-size: 16px;
  /* Better touch target */
  min-height: 44px;
}

.chat-popup-input input::placeholder {
  color: rgba(0, 0, 0, 0.7) !important;
  font-weight: 500;
}

.chat-popup-input input:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.1) !important;
  box-shadow: inset 0 0 0 2px rgba(106, 17, 203, 0.3);
}

.chat-popup-input button {
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.2) !important;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.35) !important;
  color: rgba(0, 0, 0, 0.9) !important;
  border-radius: 0;
  border-left: none;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.1);
}

.chat-popup-input button:hover {
  background: rgba(255, 255, 255, 0.3) !important;
  border-color: rgba(255, 255, 255, 0.45) !important;
  color: rgba(0, 0, 0, 0.95) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1),
              inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

/* Chat message styles with liquid glass theme */
.chat-message {
  margin-bottom: 12px !important;
  display: flex !important;
  opacity: 1 !important;
  animation: messageSlideIn 0.3s ease-out !important;
}

.chat-message.user {
  justify-content: flex-end;
}

.chat-message.bot {
  justify-content: flex-start;
}

.chat-message .message-content {
  padding: 12px 16px;
  border-radius: 16px;
  max-width: 70%;
  word-wrap: break-word;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08),
              inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  position: relative;
  opacity: 1 !important;
  visibility: visible !important;
}

.chat-message .message-content:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12), 
              inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* Enhanced desktop text visibility for light mode */
.chat-message .message-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: inherit;
  backdrop-filter: blur(5px) brightness(1.1);
  -webkit-backdrop-filter: blur(5px) brightness(1.1);
  z-index: -1;
}

.chat-message.user .message-content {
  background: rgba(0, 0, 0, 0.12) !important;
  border-color: rgba(0, 0, 0, 0.3) !important;
  color: rgba(0, 0, 0, 0.95) !important;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.2);
}

.chat-message.bot .message-content {
  background: rgba(255, 255, 255, 0.2) !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  color: rgba(0, 0, 0, 0.95) !important;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.3);
}

@keyframes messageSlideIn {
  from {
    opacity: 1;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Enhanced close button styling for liquid glass theme */
/* Custom close (X) button for chat popup */
/* Use the same style for chat close button as planet popup close for consistency */


/* Dark mode liquid glass chat support */
body.dark-mode .chat-popup {
  background: rgba(0, 0, 0, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 
              inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

body.dark-mode .chat-popup-header {
  background: rgba(255, 255, 255, 0.06);
  border-bottom-color: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.95) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

body.dark-mode .chat-popup-body {
  background: rgba(255, 255, 255, 0.01);
}

body.dark-mode .chat-popup-input {
  border-top-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .chat-popup-input input {
  color: rgba(255, 255, 255, 0.98) !important;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

body.dark-mode .chat-popup-input input::placeholder {
  color: rgba(255, 255, 255, 0.7) !important;
  font-weight: 500;
}

body.dark-mode .chat-popup-input input:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.15) !important;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.3);
}

body.dark-mode .chat-popup-input button {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
  color: rgba(255, 255, 255, 0.95) !important;
}

body.dark-mode .chat-popup-input button:hover {
  background: rgba(255, 255, 255, 0.18) !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  color: rgba(255, 255, 255, 1) !important;
}

body.dark-mode .chat-message.user .message-content {
  background: rgba(106, 17, 203, 0.7) !important;
  border-color: rgba(106, 17, 203, 0.8) !important;
  color: rgba(255, 255, 255, 0.99) !important;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

body.dark-mode .chat-message.bot .message-content {
  background: rgba(255, 255, 255, 0.12) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  color: rgba(255, 255, 255, 0.98) !important;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

body.dark-mode .chat-message .message-content:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3), 
              inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Auth tooltip with liquid glass theme */
.auth-tooltip {
  position: absolute;
  bottom: 70px;
  right: 20px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(40px) saturate(180%);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(0, 0, 0, 0.85);
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1), 
              inset 0 1px 0 rgba(255, 255, 255, 0.3);
  display: none;
  width: 200px;
  text-align: center;
  z-index: 999;
  font-weight: 500;
}

body.dark-mode .auth-tooltip {
  background: rgba(0, 0, 0, 0.15);
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 
              inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.auth-tooltip.show {
  display: block;
  animation: fadeIn 0.3s;
}

@keyframes fadeIn {
  from {opacity: 0; transform: translateY(10px);}
  to {opacity: 1; transform: translateY(0);}
}

/* Restricted overlay with liquid glass theme */
.restricted-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 10;
  color: rgba(255, 255, 255, 0.95);
  text-align: center;
  padding: 2rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.restricted-overlay h4 {
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.95);
  font-weight: 600;
}

.restricted-overlay p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 0.5rem;
}

.restricted-overlay .btn {
  margin-top: 1rem;
}

.chat-toggle-btn.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
  /* Make chat popup responsive with liquid glass theme */
  .chat-popup {
    width: 95vw !important;
    height: 70vh !important;
    left: 2.5vw !important;
    right: auto !important;
    bottom: 80px !important;
    max-width: none !important;
    background: rgba(255, 255, 255, 0.12) !important;
    backdrop-filter: blur(40px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 16px !important;
  }
  
  /* CRITICAL: Override base max-width for bot messages on mobile */
  .chat-popup .chat-message.bot .message-content {
    max-width: 95% !important;
    width: auto !important;
    flex: 1 1 auto !important;
  }
  
  /* Extra specific override to ensure bot messages are wide on mobile */
  .chat-popup .chat-popup-body .chat-message.bot .message-content {
    max-width: 96% !important;
    min-width: 90% !important;
  }
  
  .chat-popup-header {
    padding: 12px 16px !important;
    font-size: 1em !important;
    background: rgba(106, 17, 203, 0.2) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
  }
  
  /* Ensure proper mobile chat text visibility with liquid glass */
  .chat-popup-body {
    padding: 8px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    background: rgba(255, 255, 255, 0.05) !important;
  }
  
  .chat-popup-input {
    background: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
  }
  
  .chat-popup-input input {
    padding: 12px 16px !important;
    font-size: 16px !important; /* Prevent zoom on iOS */
    background: transparent !important;
    min-height: 44px !important; /* Better touch target */
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
  }
  
  .chat-popup-input button {
    padding: 12px 16px !important;
    font-size: 14px !important;
  }
  
  .chat-message .message-content {
    padding: 8px 12px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    max-width: 85% !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    font-weight: 600 !important;
  }
  
  /* Make bot messages take up much more width on mobile for better readability */
  .chat-message.bot .message-content {
    max-width: 98% !important;
    padding: 8px 10px !important;
  }
  
  /* Force override the base max-width for bot messages on mobile */
  @media (max-width: 768px) {
    .chat-message.bot .message-content {
      max-width: 98% !important;
      width: 98% !important;
      flex: 1 1 auto !important;
    }
  }
  
  /* Mobile light mode message text fixes */
  .chat-message.bot .message-content {
    background: rgba(255, 255, 255, 0.5) !important;
    border-color: rgba(255, 255, 255, 0.6) !important;
    color: rgba(0, 0, 0, 0.95) !important;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.2) !important;
  }
  
  .chat-message.user .message-content {
    background: rgba(106, 17, 203, 0.6) !important;
    border-color: rgba(106, 17, 203, 0.7) !important;
    color: rgba(255, 255, 255, 0.98) !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3) !important;
  }
  
  /* Mobile input text improvements */
  .chat-popup-input input {
    color: rgba(0, 0, 0, 0.95) !important;
    font-weight: 600 !important;
  }
  
  .chat-popup-input input::placeholder {
    color: rgba(0, 0, 0, 0.7) !important;
  }
  
  /* Mobile dark mode liquid glass fixes */
  body.dark-mode .chat-popup {
    background: rgba(0, 0, 0, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
  }
  
  body.dark-mode .chat-popup-header {
    background: rgba(106, 17, 203, 0.4) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    border-bottom-color: rgba(255, 255, 255, 0.15) !important;
  }
  
  body.dark-mode .chat-popup-body {
    background: rgba(255, 255, 255, 0.03) !important;
  }
  
  body.dark-mode .chat-popup-input {
    background: rgba(255, 255, 255, 0.08) !important;
    border-top-color: rgba(255, 255, 255, 0.15) !important;
  }
  
  body.dark-mode .chat-popup-input input {
    color: rgba(255, 255, 255, 0.98) !important;
    font-weight: 600 !important;
  }
  
  body.dark-mode .chat-popup-input input::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
  }
  
  body.dark-mode .chat-popup-input button {
    background: rgba(106, 17, 203, 0.5) !important;
    border-color: rgba(106, 17, 203, 0.6) !important;
    color: rgba(255, 255, 255, 0.95) !important;
  }
  
  body.dark-mode .chat-message.bot .message-content {
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
    color: rgba(255, 255, 255, 0.98) !important;
    font-weight: 600 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3) !important;
  }
  
  body.dark-mode .chat-message.user .message-content {
    background: rgba(106, 17, 203, 0.6) !important;
    border-color: rgba(106, 17, 203, 0.7) !important;
    color: rgba(255, 255, 255, 0.99) !important;
    font-weight: 600 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4) !important;
  }
}

@media (max-width: 480px) {
  /* Further adjust for very small screens */
  .chat-popup {
    width: 98vw !important;
    height: 65vh !important;
    left: 1vw !important;
    bottom: 70px !important;
    border-radius: 12px !important;
  }
  
  .chat-popup-header {
    padding: 10px 12px !important;
    font-size: 0.9em !important;
  }
  
  .chat-popup-body {
    padding: 10px !important;
    font-size: 13px !important;
  }
  
  .chat-popup-input input {
    padding: 10px 12px !important;
    font-size: 16px !important; /* Prevent zoom on iOS */
    min-height: 44px !important; /* Better touch target */
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
  }
  
  .chat-popup-input button {
    padding: 10px 12px !important;
    font-size: 13px !important;
  }
  
  .chat-message .message-content {
    padding: 8px 12px !important;
    font-size: 13px !important;
    max-width: 90% !important;
  }
}

/* ======================
   UNIFIED SKIP BUTTON STYLES
   Mobile-Optimized for All Chatbots
   ====================== */

/* Base skip button styles - consistent across all chatbot pages */
.skip-btn {
  position: absolute;
  right: 16px;
  /* Position below header area to avoid X button conflict */
  /* Header height is ~50px (16px padding top/bottom + content), so 60px ensures clearance */
  top: 60px;
  background: rgba(0, 0, 0, 0.15) !important;
  border: none !important;
  border-radius: 6px !important;
  padding: 6px 12px !important;
  font-size: 12px !important;
  color: rgba(0, 0, 0, 0.8) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  z-index: 20 !important; /* Lower than header elements to avoid interference */
  font-weight: 500 !important;
  text-shadow: none !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
}

.skip-btn:hover {
  background: rgba(0, 0, 0, 0.25) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.skip-btn:active {
  transform: translateY(0) !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
}

/* Dark mode skip button styles */
body.dark-mode .skip-btn {
  background: rgba(255, 255, 255, 0.15) !important;
  color: rgba(255, 255, 255, 0.9) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

body.dark-mode .skip-btn:hover {
  background: rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
}

body.dark-mode .skip-btn:active {
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5) !important;
}

/* Mobile-optimized skip button styles - FIXED VIEWPORT POSITIONING */
@media (max-width: 768px) {
  .skip-btn {
    /* CRITICAL: Fixed positioning for always-accessible skip button */
    position: fixed !important;
    bottom: 160px !important;              /* Above chat input area */
    right: 20px !important;                /* Right edge of screen */
    top: auto !important;                  /* Override any top positioning */
    left: auto !important;                 /* Override any left positioning */
    z-index: 10001 !important;             /* Above all chat content */

    /* FAB-style mobile button design */
    min-width: 56px !important;            /* Larger touch target */
    min-height: 56px !important;
    width: 56px !important;                /* Fixed circular size */
    height: 56px !important;
    padding: 0 !important;                 /* Remove padding for circular design */
    border-radius: 50% !important;         /* Circular FAB design */

    /* Enhanced visual styling */
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    /* Enhanced mobile shadows and effects */
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;

    /* Mobile touch optimizations */
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1) !important;
    touch-action: manipulation !important;
    user-select: none !important;
    -webkit-user-select: none !important;

    /* Attention-grabbing pulse animation */
    animation: skipButtonPulse 2s infinite !important;
  }

  /* Mobile skip button icon adjustments for FAB design */
  .skip-btn i {
    margin-right: 2px !important;
    font-size: 10px !important;
  }

  /* Skip button fade-out animation for smooth disappearance */
  .skip-btn.fade-out {
    opacity: 0 !important;
    transform: scale(0.8) !important;
    transition: opacity 0.3s ease, transform 0.3s ease !important;
    animation: none !important;
  }

  .skip-btn:hover {
    /* Remove hover effects on mobile to prevent sticky states */
    background: rgba(0, 0, 0, 0.15) !important;
    transform: none !important;
    animation: none !important;
  }

  .skip-btn:active {
    background: rgba(0, 0, 0, 0.35) !important;
    transform: scale(0.9) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
    animation: none !important;
  }

  body.dark-mode .skip-btn:hover {
    background: rgba(255, 255, 255, 0.15) !important;
    transform: none !important;
    animation: none !important;
  }

  body.dark-mode .skip-btn:active {
    background: rgba(255, 255, 255, 0.35) !important;
    transform: scale(0.9) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
    animation: none !important;
  }
}

/* Extra small mobile devices - Enhanced FAB design */
@media (max-width: 480px) {
  .skip-btn {
    /* Larger FAB for small screens */
    min-width: 60px !important;
    min-height: 60px !important;
    width: 60px !important;
    height: 60px !important;
    bottom: 140px !important;               /* Adjust for smaller screens */
    right: 15px !important;
    font-size: 13px !important;
    font-weight: 800 !important;

    /* Enhanced shadow for small screens */
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3) !important;
  }
}

/* Skip button pulse animation for attention */
@keyframes skipButtonPulse {
  0% {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
    transform: scale(1.05);
  }
  100% {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    transform: scale(1);
  }
}

/* Dark mode pulse animation */
body.dark-mode .skip-btn {
  animation: skipButtonPulseDark 2s infinite !important;
}

@keyframes skipButtonPulseDark {
  0% {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
    transform: scale(1.05);
  }
  100% {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    transform: scale(1);
  }
}

/* Desktop skip button - Positioned to avoid X button conflict */
@media (min-width: 769px) {
  .skip-btn {
    /* Desktop: Position within chat body but away from header area */
    position: absolute !important;
    /* Consistent with base styles - position below header to avoid X button */
    top: 60px !important;
    right: 16px !important;
    bottom: auto !important;
    left: auto !important;

    /* Desktop sizing - smaller and rectangular */
    min-width: auto !important;
    min-height: auto !important;
    width: auto !important;
    height: auto !important;
    padding: 6px 12px !important;
    border-radius: 6px !important;

    /* Remove mobile-specific styles */
    animation: none !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;

    /* Ensure skip button doesn't interfere with chat header */
    z-index: 20 !important; /* Lower than header elements */
  }

  .skip-btn:hover {
    background: rgba(0, 0, 0, 0.25) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
  }

  .skip-btn:active {
    transform: translateY(0) !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
  }

  body.dark-mode .skip-btn:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
  }

  body.dark-mode .skip-btn:active {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5) !important;
  }
}

/* Desktop Specific Liquid Glass Styles - Ensure transparency matches mobile */
@media (min-width: 769px) {
  .chat-popup {
    background: rgba(255, 255, 255, 0.12) !important;
    backdrop-filter: blur(40px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
  }
  
  .chat-popup-header {
    background: rgba(106, 17, 203, 0.2) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
  }
  
  .chat-popup-body {
    background: rgba(255, 255, 255, 0.05) !important;
  }
  
  .chat-popup-input {
    background: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
  }
  
  /* Desktop message bubbles to match mobile colors */
  .chat-message.bot .message-content {
    background: rgba(255, 255, 255, 0.5) !important;
    border-color: rgba(255, 255, 255, 0.6) !important;
    color: rgba(0, 0, 0, 0.95) !important;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.2) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    font-weight: 600 !important;
  }
  
  .chat-message.user .message-content {
    background: rgba(106, 17, 203, 0.6) !important;
    border-color: rgba(106, 17, 203, 0.7) !important;
    color: rgba(255, 255, 255, 0.98) !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    font-weight: 600 !important;
  }
  
  /* Desktop dark mode to match mobile */
  body.dark-mode .chat-popup {
    background: rgba(0, 0, 0, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
  }
  
  body.dark-mode .chat-popup-header {
    background: rgba(106, 17, 203, 0.4) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    border-bottom-color: rgba(255, 255, 255, 0.15) !important;
  }
  
  body.dark-mode .chat-popup-body {
    background: rgba(255, 255, 255, 0.03) !important;
  }
  
  body.dark-mode .chat-popup-input {
    background: rgba(255, 255, 255, 0.08) !important;
    border-top-color: rgba(255, 255, 255, 0.15) !important;
  }
  
  body.dark-mode .chat-popup-input input {
    color: rgba(255, 255, 255, 0.98) !important;
    font-weight: 600 !important;
  }
  
  body.dark-mode .chat-popup-input input::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
  }
  
  body.dark-mode .chat-popup-input button {
    background: rgba(106, 17, 203, 0.5) !important;
    border-color: rgba(106, 17, 203, 0.6) !important;
    color: rgba(255, 255, 255, 0.95) !important;
  }
  
  body.dark-mode .chat-message.bot .message-content {
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
    color: rgba(255, 255, 255, 0.98) !important;
    font-weight: 600 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3) !important;
  }
  
  body.dark-mode .chat-message.user .message-content {
    background: rgba(106, 17, 203, 0.6) !important;
    border-color: rgba(106, 17, 203, 0.7) !important;
    color: rgba(255, 255, 255, 0.99) !important;
    font-weight: 600 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4) !important;
  }
}
