/* Reset default styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body styling */
body {
    font-family: 'Roboto', sans-serif;
    background-color: #f5f5f5;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    padding: 0;
}

/* Chat container */
.chat-container {
    width: 100%;
    max-width: 400px;
    height: 600px;
    margin: 0 auto;
    border-radius: 15px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* Header styling */
.header {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    text-align: center;
    padding: 20px;
    font-size: 1.25rem;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header h1 {
    margin: 0;
    font-size: 1.5rem;
}

/* Message section */
.message-section {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background-color: #f8f9fa;
}

/* Message styling */
.message {
    padding: 12px 16px;
    margin-bottom: 8px;
    border-radius: 18px;
    max-width: 80%;
    word-wrap: break-word;
    line-height: 1.4;
    font-size: 0.95rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* User message */
.user-message {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

/* Bot message */
.bot-message {
    background-color: white;
    color: #333;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    border: 1px solid #e9ecef;
}

/* Input section */
.input-section {
    display: flex;
    padding: 15px;
    border-top: 1px solid #e9ecef;
    background: white;
    gap: 10px;
}

/* Input field */
#input {
    flex: 1;
    padding: 12px 16px;
    border-radius: 25px;
    border: 1px solid #e9ecef;
    outline: none;
    font-size: 0.95rem;
    transition: border-color 0.3s ease;
    background-color: #f8f9fa;
}

#input:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

/* Send button */
.send {
    width: 45px;
    height: 45px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.send:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.send .icon {
    font-size: 1.2rem;
}

/* Question section */
.question-section {
    padding: 15px;
    background-color: white;
    border-top: 1px solid #e9ecef;
}

.question-section h2 {
    font-size: 1rem;
    color: #666;
    margin-bottom: 12px;
}

.question-button {
    width: 100%;
    padding: 10px 15px;
    margin-bottom: 8px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    background-color: #f8f9fa;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-size: 0.9rem;
}

.question-button:hover {
    background-color: #e9ecef;
    transform: translateX(5px);
}

/* Custom scrollbar */
.message-section::-webkit-scrollbar {
    width: 6px;
}

.message-section::-webkit-scrollbar-track {
    background: #f1f1f1;
}

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

.message-section::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Responsive design */
@media (max-width: 480px) {
    .chat-container {
        height: 100vh;
        max-width: 100%;
        border-radius: 0;
    }
    
    .message {
        max-width: 90%;
    }
}