/* ============================================
   AI CHATBOT WIDGET STYLES
   ============================================ */

/* Chat Button (Bottom Right) */
.chat-button {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
    transition: all 0.3s ease;
    z-index: 9998;
    animation: chatButtonPulse 2s ease-in-out infinite;
}

.chat-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(212, 175, 55, 0.6);
}

.chat-button.active {
    background: linear-gradient(135deg, #f43f5e 0%, #ef4444 100%);
}

.chat-button svg {
    color: #0a0e1a;
    width: 28px;
    height: 28px;
}

.chat-notification {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ef4444;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    border: 3px solid #0a0e1a;
    animation: notificationBounce 0.5s ease-in-out;
}

@keyframes chatButtonPulse {
    0%, 100% {
        box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
    }
    50% {
        box-shadow: 0 4px 30px rgba(212, 175, 55, 0.8);
    }
}

@keyframes notificationBounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* Chat Window */
.chat-window {
    position: fixed;
    bottom: 100px;
    right: 24px;
    width: 380px;
    height: 600px;
    background: #1a2138;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    transform: scale(0.8) translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9999;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.chat-window.open {
    transform: scale(1) translateY(0);
    opacity: 1;
    pointer-events: all;
}

/* Chat Header */
.chat-header {
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    padding: 16px 20px;
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #0a0e1a;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: rgba(10, 14, 26, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.chat-title {
    font-weight: 700;
    font-size: 16px;
    color: #0a0e1a;
}

.chat-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(10, 14, 26, 0.8);
    margin-top: 2px;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: statusPulse 2s ease-in-out infinite;
}

@keyframes statusPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.chat-close {
    background: rgba(10, 14, 26, 0.2);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-close:hover {
    background: rgba(10, 14, 26, 0.4);
    transform: rotate(90deg);
}

.chat-close svg {
    color: #0a0e1a;
}

/* Chat Messages */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: #0f1421;
}

.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: rgba(212, 175, 55, 0.1);
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 55, 0.3);
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(212, 175, 55, 0.5);
}

.chat-message {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    animation: messageSlideIn 0.3s ease-out;
}

.chat-message.user {
    flex-direction: row-reverse;
}

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

.message-avatar {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.message-bubble {
    background: #1a2138;
    padding: 12px 16px;
    border-radius: 12px;
    max-width: 70%;
    color: #e2e8f0;
    font-size: 14px;
    line-height: 1.6;
    border: 1px solid rgba(212, 175, 55, 0.1);
}

.chat-message.user .message-bubble {
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    color: #0a0e1a;
    border: none;
}

.message-bubble a {
    color: #f4d03f;
    text-decoration: underline;
}

.chat-message.user .message-bubble a {
    color: #0a0e1a;
}

.message-bubble strong {
    color: #f4d03f;
    font-weight: 600;
}

.chat-message.user .message-bubble strong {
    color: #0a0e1a;
}

/* Quick Replies */
.chat-quick-replies {
    padding: 12px 20px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    background: #1a2138;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
}

.quick-reply {
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.3);
    color: #d4af37;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.quick-reply:hover {
    background: rgba(212, 175, 55, 0.2);
    border-color: rgba(212, 175, 55, 0.5);
    transform: translateY(-2px);
}

/* Chat Input */
.chat-input-area {
    padding: 16px 20px;
    background: #1a2138;
    border-radius: 0 0 16px 16px;
    display: flex;
    gap: 12px;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
}

.chat-input {
    flex: 1;
    background: #0f1421;
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 24px;
    padding: 12px 16px;
    color: #e2e8f0;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
}

.chat-input:focus {
    border-color: rgba(212, 175, 55, 0.5);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.chat-input::placeholder {
    color: rgba(226, 232, 240, 0.4);
}

.chat-send {
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.chat-send:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.4);
}

.chat-send svg {
    color: #0a0e1a;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .chat-window {
        width: calc(100% - 32px);
        right: 16px;
        bottom: 90px;
        height: 500px;
    }

    .chat-button {
        right: 16px;
        bottom: 16px;
    }

    .message-bubble {
        max-width: 80%;
    }
}
