/* AI Chat Assistant Styles - Modern & Responsive */
:root {
    --chat-primary: #00B7EA;
    --chat-primary-dark: #008CB3;
    --chat-dark: #1A1A1A;
    --chat-darker: #0A0A0A;
    --chat-light: #FFFFFF;
    --chat-gray: #888888;
    --chat-bg-user: #00B7EA;
    --chat-bg-bot: #2A2A2A;
}

/* Floating Button */
.chat-button {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #00B7EA, #008CB3);
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(0,183,234,0.4);
    z-index: 10000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-button:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(0,183,234,0.5);
}

.chat-button i {
    font-size: 28px;
}

.chat-button.active {
    transform: rotate(90deg);
}

/* Chat Window */
.chat-window {
    position: fixed;
    bottom: 110px;
    right: 30px;
    width: 380px;
    height: 550px;
    background: var(--chat-darker);
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    display: none;
    flex-direction: column;
    z-index: 10000;
    overflow: hidden;
    border: 1px solid rgba(255,215,0,0.2);
    animation: slideIn 0.3s ease;
}

.chat-window.open {
    display: flex;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Chat Header */
.chat-header {
    background: linear-gradient(135deg, #00B7EA, #008CB3);
    padding: 18px 20px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-avatar i {
    font-size: 22px;
}

.chat-header-text h4 {
    font-size: 16px;
    margin: 0;
    font-weight: 600;
}

.chat-header-text p {
    font-size: 11px;
    margin: 3px 0 0;
    opacity: 0.8;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.chat-close:hover {
    background: rgba(255,255,255,0.2);
}

/* Chat Messages Area */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: var(--chat-darker);
}

/* Message Bubbles */
.message {
    display: flex;
    gap: 10px;
    max-width: 85%;
    animation: messageFadeIn 0.3s ease;
}

@keyframes messageFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message.bot {
    align-self: flex-start;
}

.message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.message.bot .message-avatar {
    background: linear-gradient(135deg, #00B7EA, #008CB3);
    color: white;
}

.message.user .message-avatar {
    background: var(--chat-gray);
    color: white;
}

.message-avatar i {
    font-size: 16px;
}

.message-content {
    background: var(--chat-bg-bot);
    padding: 12px 16px;
    border-radius: 18px;
    color: white;
    font-size: 14px;
    line-height: 1.5;
    word-wrap: break-word;
}

.message.user .message-content {
    background: var(--chat-bg-user);
    color: white;
}

.message-content p {
    margin: 0;
}

.message-time {
    font-size: 10px;
    color: var(--chat-gray);
    margin-top: 5px;
    text-align: right;
}

/* Typing Indicator */
.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
    background: var(--chat-bg-bot);
    border-radius: 18px;
    width: fit-content;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--chat-gray);
    border-radius: 50%;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Chat Input Area */
.chat-input-container {
    padding: 15px 20px;
    background: var(--chat-dark);
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.chat-input {
    flex: 1;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 25px;
    padding: 12px 18px;
    color: white;
    font-size: 14px;
    resize: none;
    font-family: inherit;
    max-height: 100px;
    overflow-y: auto;
}

.chat-input:focus {
    outline: none;
    border-color: #00B7EA;
}

.chat-input::placeholder {
    color: var(--chat-gray);
}

.chat-send {
    background: linear-gradient(135deg, #00B7EA, #008CB3);
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.chat-send:hover {
    transform: scale(1.05);
}

.chat-send i {
    font-size: 18px;
}

/* Suggestion Chips */
.suggestion-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.suggestion-chip {
    background: rgba(0,183,234,0.15);
    border: 1px solid rgba(0,183,234,0.3);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    color: #00B7EA;
    cursor: pointer;
    transition: all 0.2s;
}

.suggestion-chip:hover {
    background: rgba(0,183,234,0.3);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .chat-button {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
    
    .chat-button i {
        font-size: 24px;
    }
    
    .chat-window {
        bottom: 90px;
        right: 20px;
        left: 20px;
        width: auto;
        height: 70vh;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .message {
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    .chat-window {
        bottom: 80px;
        right: 10px;
        left: 10px;
        height: 65vh;
    }
    
    .chat-header {
        padding: 12px 15px;
    }
    
    .chat-messages {
        padding: 15px;
    }
    
    .chat-input-container {
        padding: 10px 15px;
    }
}

/* Festival Theme Variation */
.festival-theme .chat-button {
    background: linear-gradient(135deg, #FFD700, #DAA520);
    box-shadow: 0 5px 20px rgba(255,215,0,0.4);
}

.festival-theme .chat-header {
    background: linear-gradient(135deg, #FFD700, #DAA520);
}

.festival-theme .message.user .message-content {
    background: #FFD700;
    color: #0A0A0A;
}

.festival-theme .chat-send {
    background: linear-gradient(135deg, #FFD700, #DAA520);
}

.festival-theme .suggestion-chip {
    background: rgba(255,215,0,0.15);
    border-color: rgba(255,215,0,0.3);
    color: #FFD700;
}

.festival-theme .chat-input:focus {
    border-color: #FFD700;
}

/* Floating AI Agent Indicator - Add to your stylesheet */
.ai-agent-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 10000;
    font-family: 'Poppins', 'Inter', system-ui, sans-serif;
}

/* Floating Button */
.ai-agent-button {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #e6b422, #f5c542);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(230, 180, 34, 0.4);
    transition: all 0.3s ease;
    position: relative;
    animation: agentPulse 2s infinite;
    border: none;
}

.ai-agent-button:hover {
    transform: scale(1.08);
    box-shadow: 0 15px 40px rgba(230, 180, 34, 0.6);
}

.ai-agent-button i {
    font-size: 32px;
    color: #0b0c10;
}

/* Notification Badge */
.ai-agent-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ff4444;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: agentBounce 1s infinite;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* "Ask SNR AI Agent" Label */
.ai-agent-label {
    position: absolute;
    right: 80px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #e6b422, #f5c542);
    color: #0b0c10;
    padding: 8px 16px;
    border-radius: 40px;
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.ai-agent-button:hover .ai-agent-label {
    opacity: 1;
    visibility: visible;
    right: 85px;
}

/* Tooltip Arrow */
.ai-agent-label::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 5px 0 5px 8px;
    border-style: solid;
    border-color: transparent transparent transparent #e6b422;
}

/* Voice Wave Effect */
.agent-wave {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(230, 180, 34, 0.4);
    animation: agentWave 1.5s infinite;
    pointer-events: none;
}

.agent-wave:nth-child(2) {
    animation-delay: 0.5s;
}

.agent-wave:nth-child(3) {
    animation-delay: 1s;
}

/* Animations */
@keyframes agentPulse {
    0% { box-shadow: 0 0 0 0 rgba(230, 180, 34, 0.5); }
    70% { box-shadow: 0 0 0 15px rgba(230, 180, 34, 0); }
    100% { box-shadow: 0 0 0 0 rgba(230, 180, 34, 0); }
}

@keyframes agentBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

@keyframes agentWave {
    0% {
        transform: scale(1);
        opacity: 0.5;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .ai-agent-float {
        bottom: 20px;
        right: 20px;
    }
    
    .ai-agent-button {
        width: 60px;
        height: 60px;
    }
    
    .ai-agent-button i {
        font-size: 28px;
    }
    
    .ai-agent-label {
        display: none;
    }
}