/* AI Assistant Widget */
.ai-widget { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999; }
.ai-widget-btn { width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(135deg, var(--accent-coral), var(--ai-purple)); border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 8px 32px rgba(232, 93, 76, 0.4); transition: all 0.3s; position: relative; overflow: hidden; }
.ai-widget-btn::before { content: ''; position: absolute; inset: 2px; background: var(--bg-dark); border-radius: 50%; }
.ai-widget-btn svg { width: 28px; height: 28px; fill: white; position: relative; z-index: 2; }
.ai-widget-btn:hover { transform: scale(1.1); box-shadow: 0 12px 40px rgba(232, 93, 76, 0.5); }
.ai-widget-btn .badge { position: absolute; top: -4px; right: -4px; width: 20px; height: 20px; background: #10B981; border-radius: 50%; font-size: 0.7rem; color: white; display: flex; align-items: center; justify-content: center; z-index: 3; animation: pulse 2s infinite; }

.ai-chat-window { position: absolute; bottom: 80px; right: 0; width: 400px; max-height: 600px; background: white; border-radius: 24px; box-shadow: 0 25px 80px rgba(0,0,0,0.2); display: none; flex-direction: column; overflow: hidden; transform: translateY(20px) scale(0.95); opacity: 0; transition: all 0.3s var(--transition-smooth); }
.ai-chat-window.active { display: flex; transform: translateY(0) scale(1); opacity: 1; }
.ai-chat-header { background: linear-gradient(135deg, var(--bg-dark), var(--bg-charcoal)); padding: 1.25rem 1.5rem; display: flex; justify-content: space-between; align-items: center; }
.ai-chat-header h4 { color: white; font-size: 1rem; display: flex; align-items: center; gap: 0.5rem; }
.ai-chat-header .status { width: 8px; height: 8px; background: #10B981; border-radius: 50%; animation: pulse 2s infinite; }
.ai-chat-close { background: none; border: none; color: rgba(255,255,255,0.6); font-size: 1.5rem; cursor: pointer; width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; transition: all 0.3s; }
.ai-chat-close:hover { background: rgba(255,255,255,0.1); color: white; }
.ai-chat-body { flex: 1; overflow-y: auto; padding: 1.5rem; display: flex; flex-direction: column; gap: 1rem; max-height: 400px; background: var(--bg-cream); }
.ai-msg { max-width: 85%; padding: 0.875rem 1.125rem; border-radius: 18px; font-size: 0.9rem; line-height: 1.5; animation: msgIn 0.3s var(--transition-smooth); }
@keyframes msgIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.ai-msg.bot { background: white; color: var(--text-dark); align-self: flex-start; border-bottom-left-radius: 4px; box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.ai-msg.user { background: var(--accent-coral); color: white; align-self: flex-end; border-bottom-right-radius: 4px; }
.ai-msg.typing { background: white; display: flex; gap: 4px; padding: 1rem 1.25rem; }
.ai-msg.typing span { width: 8px; height: 8px; background: var(--text-light); border-radius: 50%; animation: typing 1.4s infinite; }
.ai-msg.typing span:nth-child(2) { animation-delay: 0.2s; }
.ai-msg.typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.ai-suggestions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.5rem; }
.ai-suggestion { background: var(--bg-warm); border: 1px solid var(--border-light); padding: 0.5rem 0.875rem; border-radius: 100px; font-size: 0.8rem; color: var(--text-medium); cursor: pointer; transition: all 0.3s; }
.ai-suggestion:hover { background: var(--accent-coral); color: white; border-color: var(--accent-coral); }
.ai-chat-input { padding: 1rem 1.5rem; border-top: 1px solid var(--border-light); display: flex; gap: 0.75rem; background: white; }
.ai-chat-input input { flex: 1; border: 1px solid var(--border-light); border-radius: 100px; padding: 0.75rem 1.25rem; font-size: 0.9rem; font-family: var(--font-body); outline: none; transition: border-color 0.3s; }
.ai-chat-input input:focus { border-color: var(--accent-coral); }
.ai-chat-input button { width: 44px; height: 44px; border-radius: 50%; background: var(--accent-coral); border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.3s; }
.ai-chat-input button:hover { background: #D14A3A; transform: scale(1.05); }
.ai-chat-input button svg { width: 20px; height: 20px; stroke: white; fill: none; }

@media (max-width: 768px) {
  .ai-chat-window { width: calc(100vw - 2rem); right: -0.5rem; }
}
