/* ==========================================
   CHAT WIDGET - FLOATING BUBBLE
   ========================================== */

#anju-chat-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9999;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Chat bubble */
#chat-bubble {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
  transition: transform 0.2s;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
  }
  50% {
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.6);
  }
}

#chat-bubble:hover {
  transform: scale(1.1);
}

#chat-bubble span {
  font-size: 28px;
}

/* Chat container */
#chat-container {
  position: absolute;
  bottom: 80px;
  right: 0;
  width: 350px;
  height: 500px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  transition: opacity 0.3s, transform 0.3s;
}

#chat-container.chat-hidden {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}

/* Header */
#chat-header {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
  padding: 16px;
  border-radius: 12px 12px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#chat-header h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

#close-btn {
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#close-btn:hover {
  opacity: 0.8;
}

/* Messages area */
#chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #f9fafb;
}

.user-message,
.bot-message {
  max-width: 80%;
  padding: 10px 14px;
  border-radius: 12px;
  word-wrap: break-word;
  line-height: 1.5;
}

.user-message {
  background: #10b981;
  color: white;
  align-self: flex-end;
  margin-left: auto;
}

.bot-message {
  background: white;
  color: #1f2937;
  align-self: flex-start;
  border: 1px solid #e5e7eb;
}

.user-message p,
.bot-message p {
  margin: 0;
  line-height: 1.5;
}

/* Input area */
#chat-input-area {
  padding: 12px;
  border-top: 1px solid #e5e7eb;
  background: white;
  display: flex;
  gap: 8px;
}

#chat-input {
  flex: 1;
  padding: 10px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  outline: none;
}

#chat-input:focus {
  border-color: #10b981;
}

#send-btn {
  background: #10b981;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s;
}

#send-btn:hover {
  background: #059669;
}

/* Scrollbar styling */
#chat-messages::-webkit-scrollbar {
  width: 6px;
}

#chat-messages::-webkit-scrollbar-track {
  background: #f1f1f1;
}

#chat-messages::-webkit-scrollbar-thumb {
  background: #10b981;
  border-radius: 3px;
}

#chat-messages::-webkit-scrollbar-thumb:hover {
  background: #059669;
}

/* ==========================================
   AI CHAT BANNER (STICKY)
   ========================================== */

.ai-chat-banner {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  padding: 12px 0;
  position: sticky;
  top: 70px;
  z-index: 998;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
  animation: slideDown 0.5s ease-out;
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.banner-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: white;
  font-size: 15px;
}

.banner-icon {
  font-size: 24px;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.banner-text strong {
  font-weight: 600;
}

.banner-cta {
  background: rgba(255, 255, 255, 0.2);
  padding: 4px 12px;
  border-radius: 20px;
  font-weight: 600;
}

/* ==========================================
   AI ASSISTANT SECTION
   ========================================== */

.ai-assistant-section {
  background: #1a1a1a;
  padding: 80px 0;
  border-top: 2px solid #10b981;
}

.ai-subtitle {
  text-align: center;
  color: #9ca3af;
  font-size: 18px;
  margin-bottom: 50px;
}

.ai-demo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  max-width: 1100px;
  margin: 0 auto;
}

.ai-info h3 {
  color: #10b981;
  margin-bottom: 20px;
  font-size: 24px;
}

.ai-info h4 {
  color: #e5e7eb;
  margin: 30px 0 15px 0;
  font-size: 18px;
}

.ai-info p {
  color: #d1d5db;
  line-height: 1.7;
  margin-bottom: 20px;
}

.ai-example-questions {
  list-style: none;
  padding: 0;
  margin: 0 0 30px 0;
}

.ai-example-questions li {
  background: #2a2a2a;
  padding: 12px 16px;
  margin-bottom: 10px;
  border-radius: 8px;
  color: #10b981;
  border-left: 3px solid #10b981;
  font-family: 'Fira Sans', monospace;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.ai-example-questions li:hover {
  background: #333;
  transform: translateX(5px);
}

.ai-tech-note {
  background: #2a2a2a;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #374151;
  color: #9ca3af;
  font-size: 14px;
}

.ai-tech-note strong {
  color: #10b981;
}

/* Chat Demo Box */
.chat-demo-box {
  background: #2a2a2a;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #374151;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.demo-header {
  background: #1f1f1f;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #374151;
}

.demo-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #4b5563;
}

.demo-dot:first-child {
  background: #ef4444;
}

.demo-dot:nth-child(2) {
  background: #fbbf24;
}

.demo-dot:nth-child(3) {
  background: #10b981;
}

.demo-title {
  color: #e5e7eb;
  font-weight: 600;
  margin-left: auto;
  font-size: 14px;
}

.demo-content {
  padding: 20px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.demo-message {
  padding: 12px 16px;
  border-radius: 12px;
  max-width: 80%;
  font-size: 14px;
  line-height: 1.5;
}

.demo-message.bot {
  background: #374151;
  color: #e5e7eb;
  align-self: flex-start;
}

.demo-message.user {
  background: #10b981;
  color: white;
  align-self: flex-end;
  margin-left: auto;
}

.demo-cta {
  background: #10b981;
  color: white;
  padding: 16px;
  text-align: center;
  font-size: 16px;
  border-top: 1px solid #374151;
  font-weight: 600;
}

/* Mobile responsive */
@media (max-width: 768px) {
  #chat-container {
    width: calc(100vw - 40px);
    height: 80vh;
    bottom: 20px;
    right: 20px;
  }
  
  .ai-demo-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .banner-content {
    flex-direction: column;
    gap: 8px;
    text-align: center;
    font-size: 13px;
  }
  
  .banner-cta {
    font-size: 12px;
  }
}