/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.1);
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    padding: 1.5rem 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #f39c12 0%, #e74c3c 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    animation: pulse 2s infinite;
}

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

.header-text h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.header-text p {
    font-size: 0.9rem;
    opacity: 0.9;
    font-weight: 400;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    animation: blink 2s infinite;
}

.status-dot.online {
    background: #2ecc71;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.3; }
}

/* Chat Container */
.chat-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: calc(100vh - 200px);
}

.chat-messages {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    scroll-behavior: smooth;
}

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

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Message Styles */
.message {
    display: flex;
    margin-bottom: 1.5rem;
    animation: slideIn 0.3s ease-out;
}

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

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    flex-shrink: 0;
}

.bot-message .message-avatar {
    background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
    color: white;
}

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

.user-message .message-avatar {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    margin-right: 0;
    margin-left: 1rem;
}

.message-content {
    flex: 1;
    max-width: 70%;
}

.user-message .message-content {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.message-bubble {
    background: white;
    padding: 1rem 1.25rem;
    border-radius: 18px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: relative;
    transition: all 0.2s ease;
}

.message-bubble:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.bot-message .message-bubble {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom-left-radius: 6px;
}

.user-message .message-bubble {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border-bottom-right-radius: 6px;
}

.message-bubble p {
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.message-bubble p:last-child {
    margin-bottom: 0;
}

.message-bubble ul {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.message-bubble li {
    margin-bottom: 0.25rem;
    line-height: 1.4;
}

.message-time {
    font-size: 0.75rem;
    color: #666;
    margin-top: 0.5rem;
    padding: 0 0.5rem;
}

.user-message .message-time {
    text-align: right;
    color: #999;
}

/* Typing Indicator */
.typing-indicator {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0 2rem;
}

.typing-dots {
    background: #f1f3f4;
    padding: 1rem 1.25rem;
    border-radius: 18px;
    border-bottom-left-radius: 6px;
    display: flex;
    gap: 4px;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    background: #666;
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots 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;
    }
}

/* Input Container */
.input-container {
    padding: 1.5rem 2rem 2rem;
    background: white;
    border-top: 1px solid #e1e5e9;
}

.input-wrapper {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

#messageInput {
    flex: 1;
    padding: 1rem 1.25rem;
    border: 2px solid #e1e5e9;
    border-radius: 25px;
    font-size: 1rem;
    outline: none;
    transition: all 0.2s ease;
    background: #f8f9fa;
}

#messageInput:focus {
    border-color: #3498db;
    background: white;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.send-button {
    width: 50px;
    height: 50px;
    border: none;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: all 0.2s ease;
}

.send-button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.send-button:active {
    transform: scale(0.95);
}

.send-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.quick-action {
    padding: 0.5rem 1rem;
    border: 1px solid #e1e5e9;
    background: white;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
    color: #666;
}

.quick-action:hover {
    background: #3498db;
    color: white;
    border-color: #3498db;
    transform: translateY(-1px);
}

.quick-action i {
    font-size: 0.8rem;
}

/* Footer */
.footer {
    background: #2c3e50;
    color: white;
    padding: 1.5rem 2rem;
    margin-top: auto;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: #3498db;
}

.footer-text {
    font-size: 0.85rem;
    opacity: 0.8;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-spinner {
    text-align: center;
    color: white;
}

.loading-spinner i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #3498db;
}

.loading-spinner p {
    font-size: 1.1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        margin: 0;
        border-radius: 0;
    }
    
    .header {
        padding: 1rem;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .logo-section {
        justify-content: center;
    }
    
    .chat-messages {
        padding: 1rem;
    }
    
    .message-content {
        max-width: 85%;
    }
    
    .input-container {
        padding: 1rem;
    }
    
    .quick-actions {
        justify-content: center;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .header-text h1 {
        font-size: 1.4rem;
    }
    
    .header-text p {
        font-size: 0.8rem;
    }
    
    .message-content {
        max-width: 90%;
    }
    
    .quick-action {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}

