@charset "UTF-8";

.chat-bubble{
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    background: var(--azul, #007BFF);
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    z-index: 1500;
}
.chat-bubble:hover{ filter: brightness(1.1); }

.chat-panel{
    position: fixed;
    right: 20px;
    bottom: 90px;
    width: 320px;
    max-width: calc(100vw - 40px);
    height: 420px;
    max-height: 60vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 1500;
}
.chat-panel-header{
    background: var(--primaria, #1C824B);
    color: #fff;
    padding: 10px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
}
.chat-panel-header button{
    background: none;
    border: none;
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
}
.chat-messages{
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.chat-msg{
    max-width: 85%;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: .9rem;
    line-height: 1.4em;
}
.chat-msg-user{
    align-self: flex-end;
    background: var(--azul, #007BFF);
    color: #fff;
}
.chat-msg-assistant{
    align-self: flex-start;
    background: #f0f0f0;
    color: #222;
}
.chat-locked{
    padding: 1em;
    text-align: center;
    color: #777;
    font-size: .9rem;
}
.chat-form{
    display: flex;
    border-top: 1px solid #eee;
}
.chat-form input{
    flex: 1;
    border: none;
    padding: 10px;
    font-size: .9rem;
}
.chat-form input:focus{ outline: none; }
.chat-form button{
    background: var(--primaria, #1C824B);
    color: #fff;
    border: none;
    padding: 0 14px;
    cursor: pointer;
}
.chat-status{
    font-size: .75rem;
    color: #777;
    text-align: center;
    padding: 4px 0;
    margin: 0;
}

@media screen and (max-width: 480px) {
    .chat-panel{
        right: 10px;
        left: 10px;
        width: auto;
        bottom: 80px;
    }
}
