/* ==================== OWA AI CHATBOT - BEAUTIFUL + BOTTOM RIGHT ==================== */
#a1-chat-widget {
    position: fixed !important;
    bottom: 20px !important;
    right: 20px !important;
    z-index: 99999 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
}

/* Toggle Button */
#a1-chat-toggle.chat-toggle-btn {
    width: 68px !important;
    height: 68px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, var(--primary), #00d084) !important;
    color: white !important;
    border: 3px solid rgba(255,255,255,0.35) !important;
    font-size: 1.85rem !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 10px 30px rgba(0, 168, 255, 0.5) !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    animation: owa-pulse 2s infinite !important;
}

@keyframes owa-pulse {
    0%, 100% { box-shadow: 0 10px 30px rgba(0, 168, 255, 0.5); }
    50% { box-shadow: 0 15px 40px rgba(0, 168, 255, 0.75); }
}

#a1-chat-toggle:hover {
    transform: scale(1.1) !important;
}

/* Chat Window */
#a1-chat-window.chat-window {
    position: fixed !important;
    bottom: 105px !important;
    right: 20px !important;
    width: 380px !important;
    height: 540px !important;
    background: #ffffff !important;
    border: 2px solid var(--primary) !important;
    border-radius: 18px !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.22) !important;
    overflow: hidden !important;
    z-index: 99998 !important;
    display: none !important;
    flex-direction: column !important;
}

#a1-chat-window.active {
    display: flex !important;
}

/* ====================== MOBILE OPTIMIZATION ====================== */
@media (max-width: 480px) {
    #a1-chat-window.chat-window {
        width: 92vw !important;
        height: 70vh !important;
        bottom: 95px !important;
        right: 4vw !important;
        border-radius: 16px !important;
    }
    
    #a1-chat-toggle.chat-toggle-btn {
        width: 62px !important;
        height: 62px !important;
        font-size: 1.7rem !important;
    }
}

/* Header */
.chat-header {
    background: linear-gradient(to right, var(--navy), #1a2a44) !important;
    color: white !important;
    padding: 16px 20px !important;
    font-weight: 700 !important;
    font-size: 1.18rem !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
}

#a1-chat-close {
    background: none !important;
    border: none !important;
    color: white !important;
    font-size: 1.85rem !important;
    cursor: pointer !important;
    padding: 4px 10px !important;
    border-radius: 6px !important;
    transition: all 0.25s ease !important;
}

#a1-chat-close:hover {
    background: rgba(255,255,255,0.2) !important;
    transform: rotate(90deg) !important;
}

/* Messages & Input - Clean and modern */
.chat-messages {
    flex: 1 !important;
    padding: 22px !important;
    overflow-y: auto !important;
    background: #f8fafc !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
}

.chat-message {
    max-width: 85% !important;
    padding: 14px 18px !important;
    border-radius: 14px !important;
    line-height: 1.5 !important;
    font-size: 0.98rem !important;
}

.user-message {
    align-self: flex-end !important;
    background: var(--primary) !important;
    color: white !important;
}

.ai-message {
    align-self: flex-start !important;
    background: white !important;
    border: 1px solid #e2e8f0 !important;
    border-left: 5px solid var(--primary) !important;
    color: var(--navy) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
}

.chat-input-area {
    padding: 16px !important;
    border-top: 1px solid #e2e8f0 !important;
    background: white !important;
    display: flex !important;
    gap: 10px !important;
}

#a1-chat-input {
    flex: 1 !important;
    background: #f8fafc !important;
    border: 2px solid #e2e8f0 !important;
    color: var(--navy) !important;
    padding: 14px 20px !important;
    border-radius: 9999px !important;
    font-size: 1rem !important;
}

#a1-chat-input:focus {
    border-color: var(--primary) !important;
    outline: none !important;
}

#a1-chat-send {
    background: var(--primary) !important;
    color: white !important;
    border: none !important;
    padding: 0 26px !important;
    border-radius: 9999px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
}

#a1-chat-send:hover {
    background: #00d084 !important;
}