/* 🎨 MODERNE CHAT-UI */

.ai-chat-modern {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #f5f7fa;
}

/* Chat Messages Container */
.ai-messages-container {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Message Row */
.ai-message-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* User Message */
.ai-message-row.user {
  justify-content: flex-end;
}

.ai-message-row.user .ai-msg-bubble {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 18px 18px 4px 18px;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.ai-message-row.user .ai-msg-icon {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

/* Assistant Message */
.ai-message-row.assistant {
  justify-content: flex-start;
}

.ai-message-row.assistant .ai-msg-bubble {
  background: white;
  color: #333;
  border: 1px solid #e0e0e0;
  border-radius: 18px 18px 18px 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.ai-message-row.assistant .ai-msg-icon {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

/* Message Icon */
.ai-msg-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

/* Message Bubble */
.ai-msg-bubble {
  max-width: 70%;
  padding: 12px 16px;
  border-radius: 18px;
  word-wrap: break-word;
  line-height: 1.5;
  font-size: 14px;
  font-weight: 500;
}

.ai-msg-bubble p {
  margin: 0;
  padding: 0;
}

.ai-msg-bubble strong {
  font-weight: 700;
}

/* Empty State */
.ai-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #999;
}

.ai-empty-state i {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.ai-empty-state p {
  font-size: 16px;
  margin: 0;
}

.ai-empty-state small {
  font-size: 13px;
  margin-top: 8px;
  opacity: 0.7;
}

/* Input Area */
.ai-input-area {
  padding: 12px;
  background: white;
  border-top: 1px solid #e0e0e0;
  border-radius: 12px 12px 0 0;
}

.ai-input-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}

.ai-input-field {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid #ddd;
  border-radius: 24px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: all 0.2s;
}

.ai-input-field:focus {
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Buttons */
.ai-btn-voice {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
  color: white;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
}

.ai-btn-voice:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

.ai-btn-voice:active {
  transform: scale(0.95);
}

.ai-btn-send {
  padding: 12px 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 24px;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  transition: all 0.2s;
  flex-shrink: 0;
}

.ai-btn-send:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.ai-btn-send:active {
  transform: translateY(0);
}

/* Quick Action Buttons */
.ai-quick-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.ai-quick-btn {
  padding: 8px 14px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 18px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.ai-quick-btn:hover {
  background: #f0f0f0;
  border-color: #667eea;
  color: #667eea;
}

/* Action Buttons Row */
.ai-action-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 12px;
  border-top: 1px solid #eee;
}

.ai-action-btn {
  padding: 8px 14px;
  border: none;
  border-radius: 18px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.ai-action-btn-primary {
  background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
  color: white;
}

.ai-action-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.ai-action-btn-secondary {
  background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
  color: white;
}

.ai-action-btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

.ai-action-btn-tertiary {
  background: linear-gradient(135deg, #FF9800 0%, #F57C00 100%);
  color: white;
}

.ai-action-btn-tertiary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
}

.ai-action-btn-ghost {
  background: #f5f5f5;
  color: #666;
  border: 1px solid #ddd;
}

.ai-action-btn-ghost:hover {
  background: #eee;
  border-color: #999;
}

/* Loading Animation */
.ai-loading {
  display: flex;
  gap: 4px;
  padding: 12px;
  align-items: center;
}

.ai-loading span {
  width: 8px;
  height: 8px;
  background: #667eea;
  border-radius: 50%;
  animation: bounce 1.4s ease-in-out infinite;
}

.ai-loading span:nth-child(1) {
  animation-delay: -0.32s;
}

.ai-loading span:nth-child(2) {
  animation-delay: -0.16s;
}

@keyframes bounce {
  0%, 80%, 100% {
    transform: scale(0);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Scrollbar */
.ai-messages-container::-webkit-scrollbar {
  width: 6px;
}

.ai-messages-container::-webkit-scrollbar-track {
  background: transparent;
}

.ai-messages-container::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 3px;
}

.ai-messages-container::-webkit-scrollbar-thumb:hover {
  background: #999;
}
