#mlc-chat-widget {
    position: fixed;
    z-index: 999999;
    font-family: 'IRANSans', 'Tahoma', 'Segoe UI', sans-serif;
    direction: rtl;
}
.mlc-chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    transition: transform 0.2s, box-shadow 0.2s;
}
.mlc-chat-button:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 28px rgba(0,0,0,0.3);
}
.mlc-chat-popup {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
    transform: translateY(20px);
}
#mlc-chat-widget.open .mlc-chat-popup {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.mlc-chat-header {
    padding: 15px 18px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
}
.mlc-chat-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
}
.mlc-chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
}
.message {
    max-width: 80%;
    margin-bottom: 12px;
    clear: both;
}
.message.user {
    align-self: flex-start;
    text-align: left;
}
.message.admin {
    align-self: flex-end;
    text-align: right;
}
.message .bubble {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 20px;
    word-wrap: break-word;
}
.message.user .bubble {
    background: #e4e6eb;
    color: #1e293b;
}
.message-time {
    font-size: 0.7rem;
    margin-top: 4px;
    color: #64748b;
    display: block;
}
.mlc-chat-input-area {
    display: flex;
    padding: 12px;
    border-top: 1px solid #e2e8f0;
    background: white;
    gap: 8px;
}
.mlc-chat-input-area textarea {
    flex: 1;
    border: 1px solid #cbd5e1;
    border-radius: 24px;
    padding: 8px 12px;
    resize: none;
    font-family: inherit;
    direction: rtl;
}
.mlc-chat-send {
    border: none;
    width: 42px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    color: white;
}
@media (max-width: 768px) {
    .mlc-chat-popup {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100% !important;
        height: 100% !important;
        border-radius: 0 !important;
        transform: translateY(100%) !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    #mlc-chat-widget.open .mlc-chat-popup {
        transform: translateY(0) !important;
    }
    .mlc-chat-button {
        width: 55px;
        height: 55px;
    }
}