:root {
    /* --primary-gradient: linear-gradient(135deg, #6366f1, #8b5cf6); */
    --primary-gradient: linear-gradient(90deg, #3B59A7 0%, #172341 100%);
    --secondary-gradient: linear-gradient(135deg, #f472b6, #db2777);
    --bg-color: #ffffff;
    --chat-bg: #ffffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --bot-message-bg: #f1f5f9;
    --user-message-bg: #3B59A7;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] {
    --bg-color: #0f172a;
    --chat-bg: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --bot-message-bg: #334155;
    --user-message-bg: #3B59A7;
    --border-color: #475569;
}

/* body {
    color: var(--text-primary);
    font-family: "Segoe UI", sans-serif;
} */

.accu-chatbot-box {
    position: fixed;
    bottom: 100px;
    right: 24px;
    width: 350px;
    height: 470px;
    background: var(--chat-bg);
    box-shadow: var(--shadow-lg);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 9999;
}

.accu-chatbot-toggle {
    position: fixed;
    bottom: 35px;
    right: 100px;
    background: var(--user-message-bg);
    color: #fff;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    z-index: 10000;
}

.accu-header {
    padding: 16px;
    background: var(--primary-gradient);
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.accu-header-title {
    display: flex;
}

.accu-header-title h1 {
    font-size: 16px;
    margin: 0;
    display: flex;
}

.accu-bot-status {
    display: flex;
    align-items: center;
    padding-left: 5px;
}

.accu-status-indicator {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    margin-right: 6px;
}

.accu-controls button {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 16px;
    margin-left: 10px;
    cursor: pointer;
}

.accu-chat-container {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    background: var(--chat-bg);
    height: 345px;
    position: relative;
}

.accu-input-container {
    border-top: 1px solid var(--border-color);
    padding: 12px 16px;
    background: var(--chat-bg);
}

.accu-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.accu-message-input {
    flex: 1;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    outline: none;
    font-size: 14px;
    background: var(--bg-color);
    color: var(--text-primary);
}

.accu-send-button {
    background: var(--user-message-bg);
    color: white;
    border: none;
    border-radius: 40px;
    padding: 6px 9px;
    font-size: 14px;
    cursor: pointer;
}

.accu-typing .accu-message-bubble {
    background: var(--bot-message-bg);
    padding: 10px 14px;
    border-radius: 14px;
    display: inline-block;
    position: relative;
    bottom: 18px;
}

.accu-typing-dots {
    display: flex;
    gap: 4px;
    padding: 8px 0;
}

.accu-typing-dot {
    width: 6px;
    height: 6px;
    background: var(--text-secondary);
    border-radius: 50%;
    animation: blink 1.4s infinite both;
}

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

.accu-typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes blink {

    0%,
    80%,
    100% {
        opacity: 0.2;
    }

    40% {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.95);
    }
}

.accu-message {
    display: flex;
    margin: 8px 0;
    align-items: flex-end;
}

.accu-user-message {
    flex-direction: row-reverse;
    text-align: left;
}

.accu-bot-message {
    flex-direction: row;
    text-align: left;
}

.accu-avatar {
    background: var(--user-message-bg);
    color: #fff;
    font-size: 12px;
    font-weight: bold;
    border-radius: 50%;
    width: 30px;
    height: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 8px;
}

.accu-bot-message .accu-avatar {
    background: #94a3b8;
    position: relative;
    bottom: 5px;
}

.accu-avatar-image {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}


.accu-message-content {
    max-width: 75%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    left: 0;
    top: 18px;
}

.accu-user-message .accu-message-content {
    align-items: flex-end;
    margin-bottom: 10px;
}

.accu-user-message .accu-avatar {
    bottom: 15px;
    position: relative;
}

.accu-message-bubble {
    background: var(--bot-message-bg);
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 14px;
    word-wrap: break-word;
    width: 100%;
}

.accu-user-message .accu-message-bubble {
    background: var(--user-message-bg);
    color: #fff;
}

.accu-message-time {
    font-size: 11px;
    color: var(--text-secondary);
    padding-left: 10px;
    padding-top: 5px;
}

.accu-upload-button {
    background: #007bff;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 14px;
    margin-top: 10px;
    cursor: pointer;
    /* transition: background 0.2s ease; */
}

.accu-upload-button:hover {
    background: #0056b3;
}

@keyframes accuSpin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}


@media screen and (max-width: 560px) {

    .accu-chatbot-toggle {
        bottom: 55px;
        right: 85px
    }

    /* Your styles here */
    .accu-chatbot-box {
        position: fixed;
        bottom: 0px;
        right: 0;
        top: 0;
        width: 100%;
        height: 100%;
        background: var(--chat-bg);
        box-shadow: var(--shadow-lg);
        border-radius: 0px;
    }

    .accu-container{
        height: 100%;
    }

    .accu-chat-container {
        flex: 1;
        padding: 16px;
        overflow-y: auto;
        background: var(--chat-bg);
        height: 75vh;
        position: relative;
    }

    .accu-input-container {
        position: absolute;
        bottom: 0px;
        width: 100%;
    }
}