/* ===================================================
   Chatbot CSOTE — Widget
   =================================================== */
.csote-chat-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #1a365d;
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1.5rem;
    box-shadow: 0 8px 24px rgba(26,54,93,0.35);
    z-index: 9998;
    transition: transform 0.25s ease, background 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.csote-chat-btn:hover { transform: scale(1.08); background: #c85536; }

.csote-chat-box {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 360px;
    max-width: calc(100vw - 40px);
    height: 520px;
    max-height: calc(100vh - 140px);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 9999;
    font-family: 'Open Sans', 'Segoe UI', sans-serif;
}
.csote-chat-box.aberto { display: flex; }

.csote-chat-header {
    background: #1a365d;
    color: #fff;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.csote-chat-header img { height: 38px; width: 38px; background: #fff; border-radius: 50%; padding: 4px; }
.csote-chat-header .t { font-weight: 700; font-size: 1rem; line-height: 1.2; }
.csote-chat-header .s { font-size: 0.78rem; color: rgba(255,255,255,0.75); }
.csote-chat-header .fechar { margin-left: auto; background: none; border: none; color: #fff; font-size: 1.2rem; cursor: pointer; }

.csote-chat-msgs {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    background: #f7fafc;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.csote-msg {
    max-width: 80%;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 0.92rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
}
.csote-msg.bot { background: #fff; color: #2d3748; border: 1px solid #e2e8f0; align-self: flex-start; border-bottom-left-radius: 4px; }
.csote-msg.user { background: #c85536; color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.csote-typing { font-size: 0.85rem; color: #718096; font-style: italic; align-self: flex-start; }

.csote-chat-input {
    display: flex;
    border-top: 1px solid #e2e8f0;
    padding: 10px;
    gap: 8px;
    background: #fff;
}
.csote-chat-input input {
    flex: 1;
    border: 1.5px solid #e2e8f0;
    border-radius: 24px;
    padding: 10px 16px;
    font-size: 0.92rem;
    outline: none;
}
.csote-chat-input input:focus { border-color: #c85536; }
.csote-chat-input button {
    background: #c85536;
    color: #fff;
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    flex-shrink: 0;
    transition: background 0.2s;
}
.csote-chat-input button:hover { background: #1a365d; }
.csote-chat-input button:disabled { opacity: 0.5; cursor: not-allowed; }
