.chat-widget {
    font-family: "Roboto", sans-serif;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 350px;
    border: 1px solid #ccc;
    border-radius: 10px;
    background: #fcf9f3;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    box-sizing: border-box;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.chat-widget.collapsed {
    width: 180px;
    height: 50px !important;
    overflow: hidden;
    border-radius: 999px;
}

.chat-close-icon {
    position: absolute;
    right: 12px;
    top: 3px;
    font-size: 25px;
    font-weight: bold;
    color: #ffffff;
    opacity: 0.7;
    pointer-events: none;
}

.chat-widget.collapsed .chat-close-icon {
    display: none;
}

.chat-widget.expanded {
    height: 500px;
    border-radius: 10px;
}

.chat-header {
    position: relative;
    padding: 20px 4px 4px 4px;
    /* padding: 4px; */
    background: #DFB672;
    color: #232f3c;
    border-radius: 0;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 40px;
}

.chat-header span.expanded-title {
    display: block;
    border-radius: 0;
    margin-top: 15px;
    margin-bottom: 5px;
    font-weight: 450;
    font-size: 17px;
}

.chat-header span.collapsed-title {
    display: inline-flex;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 6px;
    font-size: 14px;
    background: transparent;
    margin-top: -36px;
    margin-left: -4px;
    font-weight: 600;
    position: relative;
}

.chat-widget.expanded .collapsed-title {
    display: none;
}

.mini-bubble {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    background: #ffffff;
    padding: 2px 6px;
    border-radius: 14px;
    position: relative;
    height: 18px;
    min-width: auto;
}

.mini-bubble::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 50%;
    transform: translateY(10%)  translateX(110%) rotate(65deg);
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-right: 8px solid white;
}


.mini-bubble .dot {
    width: 4px;
    height: 4px;
    background: #DFB672;
    border-radius: 50%;
}

.collapsed-stack {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 6px;
    transform: translateY(1px); 
}


.chat-text {
    font-size: 17px;
    color: #232f3c;
    line-height: 1.1;
    padding-top: 2px;
    padding-left: 5px;
}


.chat-widget.collapsed .chat-header span.expanded-title {
    display: none;
}

.chat-widget.collapsed .chat-header span.collapsed-title {
    display: block;
}

.toggle-button {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.767);
    font-size: 20px;
    cursor: pointer;
    padding: 0 5px;
    cursor: pointer;
}

.chat-messages {
    flex-grow: 1;
    overflow-y: auto;
    padding: 10px;
    min-height: 0;
    position: relative;
    scrollbar-width: thin;
    scrollbar-color: #DFB672 #f4eee4;
}

.message {
    margin: 10px;
    padding: 8px;
    border-radius: 10px;
    max-width: 80%;
    font-size: 15px;
}

.user-message {
    background: #dab170;
    color: #ffffff;
    margin-left: auto;
    font-size: 15px;
    padding: 13px 12px;
    border: 1px solid #c6a76f;
}

.bot-message {
    background: #ffffff;
    color: #232f3c;
    margin-right: auto;
    font-size: 15px;
    border: 1px solid #ddd;
    box-shadow: 1px 2px 5px rgba(0, 0, 0, 0.1);
    padding: 13px 12px;
}

.chat-input {
    padding: 8px;
    border-top: 1px solid #ccc;
    display: none;
    gap: 8px;
    box-sizing: border-box;
    align-items: center;
    background: white;
}

.chat-input input {
    flex-grow: 1;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
    height: 34px;
    box-sizing: border-box;
    margin: 0;
}

.chat-input button {
    background: #E0B772;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    height: 34px;
    white-space: nowrap;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
}

.contact-form input {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
}
.contact-form button {
    padding: 8px;
    background-color: #E0B772;
    border: 1px solid #c6a76f;
    color: white;
    border-radius: 8px;
    font-size: 15px;
    cursor: pointer;
}
.back-button {
    padding: 8px;
    background-color: #b19f7d !important;
    border: 1px solid #eee3cc !important;
}

.button-action {
    width: 100%;
    box-sizing: border-box;
    margin: 5px 0;
    padding: 10px 12px;
    border-radius: 8px;
    border: none;
    background-color: #E0B772;
    color: white;
    cursor: pointer;
    font-size: 15px;
    text-align: center;
    border: 1px solid #c6a76f; 
    cursor: pointer;
}

.client-confirmation-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 10px;
}

.client-confirmation-buttons button {
    padding: 7px;
    font-size: 15px;
    font-weight: 500;
    border: none;
    border-radius: 8px;
    background-color: #DFB672;
    color: white;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border: 1px solid #c6a76f;
}

.client-confirmation-buttons button:hover {
    background-color: #b4904c;
}

#clientStatusPrompt {
    text-align: center;
    line-height: 1.5;
    padding: 10px;
    font-size: 14px;
    max-width: 260px; 
    margin: 10px auto; 
    border: 1px solid #DFB672; 
    border-radius: 10px; 
    background: #fcf9f3; 
    margin: 15px auto 10px auto;
}

.typing-indicator {
    display: flex;
    align-items: center;
    margin: 2px;
    padding: 6px;
    border-radius: 10px;
    background: #ffffff;
    width: fit-content;
    height: 16px;
    gap: 3px;
}


.typing-indicator span {
    width: 5px;
    height: 5px;
    background: #aaa;
    border-radius: 50%;
    display: inline-block;
    animation: typing 1.2s infinite ease-in-out;
}

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

.header-shadow {
    height: 15px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.1), transparent);
    width: 100%;
    z-index: 1;
}
.chat-logo-wrapper {
    position: fixed;
    right: 190px;
    bottom: 490px;
    z-index: 1000;
    pointer-events: none;
    justify-content: center;

    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    display: flex;
}

.chat-logo-offset {
    position: fixed;
    right: 135px;
    bottom: 490px;
    z-index: 1000;
    pointer-events: none;
    justify-content: center;

    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    display: flex;
    }

.chat-logo-wrapper.expanded {
    opacity: 1;
    transform: translateY(0);
}
.chat-logo-wrapper.logo-offset {
    right: 135px; 
}

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

.chat-messages::-webkit-scrollbar-track {
    background: #f4eee4;
    border-radius: 10px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background-color: #DFB672;
    border-radius: 10px;
    border: 1px solid #c6a76f;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background-color: #cba15d;
}

.chat-logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    border: 3px solid #ffffff;
}

.debt-checkbox-label {
display: flex;
align-items: center;
font-size: 14px;
cursor: pointer;
}

.debt-checkbox {
appearance: none;
-webkit-appearance: none;
width: 14px;
height: 14px;
border: 2px solid #c6a76f;
border-radius: 4px;
background-color: #fff;
cursor: pointer;
position: relative;
transition: all 0.2s ease;
}

/* Checked style */
.debt-checkbox:checked {
background-color: #E0B772;
border-color: #c6a76f;
}

/* Checkmark */
.debt-checkbox:checked::after {
content: '';
position: absolute;
top: -1px;
left: 3px;
width: 3px;
height: 8px;
border: solid white;
border-width: 0 2px 2px 0;
transform: rotate(45deg);
}

@keyframes typing {
    0%, 80%, 100% {
        transform: scale(0.8);
        opacity: 0.3;
    }
    40% {
        transform: scale(1.2);
        opacity: 1;
    }
}