/* Chat Widget CSS */
.chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 300px;
    z-index: 999999;
    font-family: Arial, sans-serif;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 10px;
    overflow: hidden;
    /* Ensure the chat widget is positioned correctly */
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    will-change: transform;
}

.chat-header {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    padding: 12px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
    font-size: 14px;
}

.chat-body {
    background: #f9f9f9;
    height: 350px;
    display: flex;
    flex-direction: column;
    border: 1px solid #ddd;
    border-top: none;
}

.chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    max-height: 200px;
    background: white;
}

.chat-input-area {
    padding: 12px;
    background: #f0f0f0;
    border-top: 1px solid #ddd;
}

.chat-topic-select {
    width: 100%;
    padding: 6px;
    margin-bottom: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 13px;
}

.chat-input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 13px;
    resize: none;
    margin-bottom: 8px;
    box-sizing: border-box;
}

.chat-file-upload {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    gap: 10px;
}

.file-upload-label {
    background: #4CAF50;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    display: inline-block;
}

.file-input {
    display: none;
}

.file-name {
    font-size: 12px;
    color: #666;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.send-button {
    background: #2196F3;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    width: 100%;
    font-size: 13px;
}

.send-button:hover {
    background: #0b7dda;
}

.message {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 8px;
    max-width: 80%;
}

.message.user {
    background: #E3F2FD;
    margin-left: auto;
}

.message.support {
    background: #F5F5F5;
    margin-right: auto;
}

.message-header {
    font-weight: bold;
    margin-bottom: 5px;
    font-size: 11px;
}

.message.support .message-header {
    color: #2196F3;
}

.message.user .message-header {
    color: #1976D2;
}

.message-content {
    font-size: 13px;
    line-height: 1.4;
}

.message-image {
    max-width: 100%;
    border-radius: 4px;
    margin-top: 5px;
}

.timestamp {
    font-size: 10px;
    color: #999;
    text-align: right;
    margin-top: 5px;
}

.loading {
    color: #666;
    font-style: italic;
}

.translation-controls {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #ddd;
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.translate-button {
    background: #ff9800;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    font-weight: bold;
    flex: 1;
    min-width: 100px;
}

.translate-button:hover {
    background: #f57c00;
}

.translate-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.translated-content {
    margin-top: 8px;
    padding: 8px;
    background: #e3f2fd;
    border-radius: 4px;
    font-size: 12px;
    border-left: 3px solid #2196F3;

}
