/*]]]]]]]]]]-----CHAT BOT CSS-------[[[[[[[[[[[*/

/* Chat Bar */
.chat-bar {
    position: fixed;
    bottom: 20px;
    right: 5%;
    transform: translateX(-5%);
    width: calc(100% - 40px);
    max-width: 180px;
    height: 50px;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: none;
    border-radius: 25px;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0;
    z-index: 1020;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.chat-bar.expanded {
    max-width: 800px;
    height: 600px;
    align-items: flex-end;
    border-radius: 25px;
    bottom: 20px;
    padding: 0;
}

.chat-bar-content {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 15px;
}

.chat-bar.expanded .chat-bar-content {
    display: none;
}

.chat-icon {
    width: 40px;
    height: 40px;
    background: #86DCD3;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.chat-icon svg {
    width: 22px;
    height: 22px;
    fill: #252525;
}

.chat-bar-input {
    flex: 1;
    padding: 10px 18px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    font-family: 'Oswald', sans-serif;
    font-size: 14px;
    outline: none;
    background: rgba(26, 26, 26, 0.7);
    color: #ebebeb;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.chat-bar-input:focus {
    border-color: #0b69ff;
    background: rgba(43, 43, 43, 0.9);
}

.chat-bar-input::placeholder {
    color: #888;
}

.chat-bar-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: #5A3D80;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.chat-bar-btn:hover {
    background: #3385ff;
    transform: scale(1.05);
}

.chat-bar-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.chat-bar-btn svg {
    width: 20px;
    height: 20px;
    fill: #252525;
}

/* Expanded Chat Box */
.chat-box {
    display: none;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background: rgba(20, 20, 20, 0.653);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 25px;
    overflow: hidden;
    animation: slideUpChat 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
}

.chat-bar.expanded .chat-box {
    display: flex;
}

@keyframes slideUpChat {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Chat Header */
.chat-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.chat-header h2 {
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 1px;
    color: #86DCD3;
}

.close-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: rgba(11, 105, 255, 0.2);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: rgba(11, 105, 255, 0.4);
    transform: rotate(90deg);
}

.close-btn svg {
    width: 20px;
    height: 20px;
    fill: #ebebeb;
}

/* Messages Area */
.messages {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.messages::-webkit-scrollbar {
    width: 8px;
}

.messages::-webkit-scrollbar-track {
    background: rgba(26, 26, 26, 0.3);
}

.messages::-webkit-scrollbar-thumb {
    background: #0b69ff;
    border-radius: 4px;
}

.message {
    display: flex;
    gap: 12px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.user {
    flex-direction: row-reverse;
}

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 16px;
}

.message.user .message-avatar {
    background: #86DCD3;
    color: #252525;
}

.message.bot .message-avatar {
    background: #5A3D80;
    color: #fff;
}

.message-content {
    max-width: 70%;
    padding: 14px 18px;
    border-radius: 16px;
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
}

.message.user .message-content {
    background: rgba(134, 220, 211, 0.9);
    color: #252525;
    border-bottom-right-radius: 4px;
}

.message.bot .message-content {
    background: rgba(43, 43, 43, 0.9);
    color: #ebebeb;
    border-bottom-left-radius: 4px;
}

.typing-indicator {
    display: none;
    padding: 14px 18px;
    background: rgba(43, 43, 43, 0.9);
    border-radius: 16px;
    width: fit-content;
}

.typing-indicator.active {
    display: block;
}

.typing-indicator span {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #5A3D80;
    margin: 0 2px;
    animation: typing 1.4s infinite;
}

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

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

@keyframes typing {

    0%,
    60%,
    100% {
        transform: translateY(0);
    }

    30% {
        transform: translateY(-10px);
    }
}

/* Input Area */
.chat-input-area {
    padding: 20px 30px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 12px;
}

.chat-input-area input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid rgba(11, 105, 255, 0.3);
    border-radius: 30px;
    font-family: 'Oswald', sans-serif;
    font-size: 16px;
    outline: none;
    background: rgba(43, 43, 43, 0.7);
    color: #ebebeb;
    transition: all 0.3s ease;
}

.chat-input-area input:focus {
    border-color: #5A3D80;
    background: rgba(43, 43, 43, 0.9);
}

.chat-input-area input::placeholder {
    color: #666;
}

.error-message {
    background: rgba(255, 68, 68, 0.9);
    color: white;
    padding: 12px;
    border-radius: 12px;
    text-align: center;
    font-size: 14px;
    margin: 0 30px 10px;
}

/* Responsive */
@media (max-width: 768px) {
    .chat-bar {
        width: auto;
        max-width: 180px;
        right: 20px;
        transform: none;
        padding: 0;
        bottom: 90px;
        /* Lifted up for tablets too */
    }

    .chat-bar.expanded {
        width: calc(100vw - 40px);
        max-width: none;
        height: 80vh;
        border-radius: 20px;
    }

    .messages {
        padding: 20px;
    }

    .chat-input-area {
        padding: 15px 20px;
    }

    .message-content {
        max-width: 85%;
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .chat-bar {
        width: auto;
        max-width: 180px;
        right: 15px;
        bottom: 90px;
        /* Lifted up to avoid bottom navbar overlap */
        height: 50px;
        padding: 0;
        border-radius: 25px;
    }

    .chat-bar.expanded {
        width: calc(100vw - 30px);
        height: 80vh;
        border-radius: 16px;
    }

    .chat-bar-input {
        font-size: 14px;
    }

    .chat-header h2 {
        font-size: 20px;
    }

    .chat-input-area {
        padding: 10px 10px;
    }
}

/* ============================================ */
/* [PRO] FILE UPLOAD ADDITIONS - Add at the end of your BASE CSS */
/* ============================================ */

/* Modify .chat-input-area to support flex-direction column */
.chat-input-area {
    padding: 20px 30px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    /* Changed from row to column */
    gap: 12px;
}

/* Input Row Wrapper */
.input-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.input-row input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid rgba(11, 105, 255, 0.3);
    border-radius: 30px;
    font-family: 'Oswald', sans-serif;
    font-size: 16px;
    outline: none;
    background: rgba(43, 43, 43, 0.7);
    color: #ebebeb;
    transition: all 0.3s ease;
}

.input-row input:focus {
    border-color: #5A3D80;
    background: rgba(43, 43, 43, 0.9);
}

.input-row input::placeholder {
    color: #666;
}

/* Attach Button */
.attach-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(134, 220, 211, 0.2);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.attach-btn:hover {
    background: rgba(134, 220, 211, 0.4);
    transform: scale(1.05);
}

.attach-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.attach-btn svg {
    width: 20px;
    height: 20px;
    fill: #ebebeb;
}

/* File Preview Area */
.file-preview {
    display: none;
    padding: 12px;
    background: rgba(43, 43, 43, 0.6);
    border-radius: 12px;
    gap: 10px;
    flex-wrap: wrap;
}

.file-preview.active {
    display: flex;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(11, 105, 255, 0.2);
    border-radius: 8px;
    font-size: 14px;
    color: #ebebeb;
}

.file-item-name {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-item-icon {
    font-size: 18px;
}

.file-item-remove {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 68, 68, 0.3);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    margin-left: 4px;
}

.file-item-remove:hover {
    background: rgba(255, 68, 68, 0.6);
}

.file-item-remove svg {
    width: 12px;
    height: 12px;
    fill: #fff;
}

/* [PRO] FILE UPLOAD ADDITIONS END */
/* ============================================ */
/* [PRO] FILE UPLOAD ADDITIONS */
/* ============================================ */

/* Input Area - PRO with File Upload */
.chat-input-area {
    padding: 20px 30px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.input-row {
    display: flex;
    gap: 12px;
    align-items: flex-end;
}

.input-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chat-input {
    width: 100%;
    padding: 14px 20px;
    border: 2px solid rgba(11, 105, 255, 0.3);
    border-radius: 25px;
    font-family: 'Oswald', sans-serif;
    font-size: 16px;
    outline: none;
    background: rgba(43, 43, 43, 0.7);
    color: #ebebeb;
    transition: all 0.3s ease;
    resize: none;
    max-height: 120px;
}

.chat-input:focus {
    border-color: #5A3D80;
    background: rgba(43, 43, 43, 0.9);
}

.chat-input::placeholder {
    color: #666;
}

.input-actions {
    display: flex;
    gap: 8px;
}

.attach-btn,
.send-btn-pro {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.attach-btn {
    background: rgba(134, 220, 211, 0.2);
}

.attach-btn:hover {
    background: rgba(134, 220, 211, 0.4);
    transform: scale(1.05);
}

.send-btn-pro {
    background: #5A3D80;
}

.send-btn-pro:hover {
    background: #3385ff;
    transform: scale(1.05);
}

.attach-btn:disabled,
.send-btn-pro:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.attach-btn svg,
.send-btn-pro svg {
    width: 20px;
    height: 20px;
    fill: #ebebeb;
}

.send-btn-pro svg {
    fill: #252525;
}

/* File Upload Preview */
.file-preview {
    display: none;
    padding: 12px;
    background: rgba(43, 43, 43, 0.6);
    border-radius: 12px;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.file-preview.active {
    display: flex;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(11, 105, 255, 0.2);
    border-radius: 8px;
    font-size: 14px;
    color: #ebebeb;
}

.file-item-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-item-remove {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 68, 68, 0.3);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.file-item-remove:hover {
    background: rgba(255, 68, 68, 0.6);
}

.file-item-remove svg {
    width: 12px;
    height: 12px;
    fill: #fff;
}

/* Hidden File Input */
#fileInput {
    display: none;
}

/* [PRO] FILE UPLOAD ADDITIONS END */


/*[[[[[[[[[[----CHAT BOT CSS ENDS------]]]]]]]]*/