.ai-chatbot-container {
    width: 100%;
    max-width: 1200px; /* Widened to 1200px */
    margin: 20px auto;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 14px;
}

.ai-bot-timer {
    background: #f8f9fa;
    border: 1px solid #ddd;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    margin-bottom: 10px;
    border-radius: 5px;
}

.ai-bot-timer.warning {
    color: #d9534f;
    background: #fff5f5;
}

.ai-chatbox {
    border: 1px solid #ccc;
    height: 400px;
    overflow-y: auto;
    padding: 15px;
    background: #fff;
    margin-bottom: 10px;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
}

.message {
    padding: 10px 14px;
    margin: 8px 0;
    border-radius: 12px;
    max-width: 75%;
    line-height: 1.4;
    font-size: 14px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.user-message {
    background: #0078ff;
    color: #fff;
    align-self: flex-end;
    float: right;
    clear: both;
}

.bot-message {
    background: #f1f0f0;
    color: #333;
    align-self: flex-start;
    float: left;
    clear: both;
}

.bot-message code {
    background: #e1e1e1;
    padding: 2px 5px;
    border-radius: 4px;
    font-family: monospace;
}

.typing {
    font-style: italic;
    color: #888;
}

.ai-user-input {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
}

.ai-send-btn, .ai-upload-btn, .ai-export-btn {
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
    font-size: 14px;
}

.ai-send-btn { background: #0078ff; }
.ai-upload-btn { background: #6c757d; }
.ai-export-btn { background: #28a745; }

/* --- MOBILE RESPONSIVENESS --- */
@media (max-width: 768px) {
    .ai-chatbot-container {
        margin: 10px auto;
        padding: 0 10px;
    }
    
    .ai-chatbox {
        height: 350px;
    }

    .message {
        max-width: 90%;
    }

    .ai-chatbot-container > div:last-child {
        flex-wrap: wrap;
    }

    .ai-user-input {
        width: 100%;
        margin-bottom: 10px;
    }

    .ai-send-btn, .ai-upload-btn, .ai-export-btn {
        flex: 1;
        text-align: center;
        margin-bottom: 5px;
    }
}