﻿.akonini-ai-chatbot-icon {
    width: auto;
    height: auto;
    background: #000; /* Button color */
    border-radius: 10px; /* Smooth rounded corners */
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 999998;
    overflow: hidden;
    transition: all .3s ease;
    padding: 10px;
}
.akonini-ai-chatbot-icon.hide {
    height: 0;
    width: 0;
    padding: 0;
}

    .akonini-ai-chatbot-icon::after {
        content: "";
        position: absolute;
        bottom: -10px; /* Move tail down */
        left: 50%;
        transform: translateX(-50%);
        width: 24px;
        height: 24px;
        background: #000; /* Same as button color */
        border-radius: 6px;
        clip-path: polygon(50% 100%, 0 0, 100% 0);
        z-index: 0;
    }

.icon-wrap {
    position: relative;
    z-index: 2; /* above triangle */
}

.akonini-ai-chatbot-icon > .icon-wrap > img {
    width: 30px;
    height: 30px;
    margin-top: 5px;
}

.akonini-ai-chatbot-div {
    position: fixed;
    bottom: 25px;
    right: 10px;
    z-index: 999999;
    width: 400px;
    height: 550px;
    background-color: #fff;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 12px 28px 0px, rgba(0, 0, 0, 0.1) 0px 2px 4px 0px;
    display: grid;
    grid-template-rows: 65px 1fr;
    border-radius: 25px;
    overflow: hidden;
    transform: translateY(150%);
    transition: all .3s ease;
}
.akonini-ai-chatbot-div.show {
    transform: translateY(0);
}

.akonini-ai-chatbot-header {
    width: 100%;
    height: 100%;
    background-color: #FFB606;
    display: flex;
    justify-content: space-between;
    align-items: center;
    overflow: hidden;
}

.akonini-ai-chatbot-header-logo {
    height: 100%;
    display: flex;
    align-items: center;
    margin-left: 25px;
}

    .akonini-ai-chatbot-header-logo > img {
        width: 25px;
        height: 25px;
    }

.akonini-ai-chatbot-header-icon-wrapper {
    width: 150px;
    height: 100%;
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: end;
    margin-right: 25px;
}

    .akonini-ai-chatbot-header-icon-wrapper > span > svg {
        height: 12px;
        fill: #000;
    }

.akonini-ai-chatbot-body {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-rows: 1fr 75px;
    overflow: hidden;
}

.akonini-ai-chatbot-message-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 25px;
    padding: 10px;
    padding-top: 25px;
    overflow-y: scroll;
}

.akonini-ai-message-item {
    padding: 10px;
    border-radius: 10px;
    background: #d5d5d5;
    max-width: 70%;
    font-size: 14px;
    word-wrap: break-word; /* ✅ breaks long words */
    overflow-wrap: break-word; /* ✅ ensures compatibility */
}
.akonini-ai-message-item.user-message {
    background: #FFB606;
    color: #fff;
    align-self: flex-end;
}


.akonini-ai-chatbot-typebox {
    width: 100%;
    height: 100%;
    padding: 10px 25px;
}

.akonini-ai-chatbot-input-wrapper {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 1fr 35px;
    gap: 15px;
    align-items: center;
}

    .akonini-ai-chatbot-input-wrapper > input {
        border: none;
        outline: none;
        height: 45px;
        font-size: 15px;
    }

    .akonini-ai-chatbot-input-wrapper > span > svg {
        height: 25px;
        fill: #000;
    }

.akonini-ai-chatbot-div.fullscreen {
    width: 100%;
    height: 100%;
    bottom: 0;
    right: 0;
    border-radius: 0;
}


.akonini-ai-chatbot-header-icon-wrapper span {
    cursor: pointer;
}

.akonini-ai-chatbot-input-wrapper .send {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}


.ai-bubble {
    background: #f0f4ff4a;
    padding: 10px 16px;
    border-radius: 12px;
    display: inline-block;
}

.typing-indicator {
    width: 40px;
    display: flex;
    justify-content: space-between;
}

.typing-indicator span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #555;
    animation: blink 1.4s infinite both;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes blink {
    0% {
        opacity: 0.2;
        transform: translateY(0);
    }

    20% {
        opacity: 1;
        transform: translateY(-3px);
    }

    100% {
        opacity: 0.2;
        transform: translateY(0);
    }
}



@media screen and (max-width: 500px) {
    .akonini-ai-chatbot-div {
        width: 100%;
        height: 100%;
        bottom: 0;
        right: 0;
        border-radius: 0;
    }

    .akonini-ai-chatbot-header-icon-wrapper .expand {
        display: none;
    }
}