/* Botão flutuante */
#chat-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #0056b3;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    z-index: 1000;
}
/* Janela do chat */
#chat-box {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 320px;
    max-height: 500px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    display: none;
    flex-direction: column;
    overflow: hidden;
    font-family: Arial, sans-serif;
    z-index: 1000;
}
/* Cabeçalho */
#chat-header {
    background: #0056b3;
    color: #fff;
    padding: 12px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#chat-header span {
    font-size: 14px;
}
#chat-close {
    cursor: pointer;
    font-size: 18px;
}
/* Corpo do chat */
#chat-messages {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    min-height: 300px;
}
.bot-message {
    background: #f1f1f1;
    color: #000;
    padding: 8px;
    border-radius: 8px;
    margin: 6px 0;
    max-width: 80%;
    align-self: flex-start;
    word-wrap: break-word;
    line-height: 1.5;
}
.user-message {
    background: #ffcc00;
    color: #000;
    padding: 8px;
    border-radius: 8px;
    margin: 6px 0;
    max-width: 80%;
    align-self: flex-end;
    word-wrap: break-word;
}
.typing-indicator {
    background: #f1f1f1;
    color: #666;
    padding: 8px;
    border-radius: 8px;
    margin: 6px 0;
    max-width: 80%;
    align-self: flex-start;
    font-style: italic;
}
/* Estilo para links */
.bot-message a,
.user-message a {
    color: #0056b3;
    text-decoration: underline;
    word-break: break-all;
}
.bot-message a:hover {
    color: #003d82;
}
/* Input */
#chat-input-area {
    display: flex;
    border-top: 1px solid #ddd;
}
#chat-input {
    flex: 1;
    border: none;
    padding: 10px;
    font-size: 14px;
}
#chat-send {
    background: #0056b3;
    color: #fff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: background 0.3s;
}
#chat-send:hover {
    background: #004494;
}
#chat-send:disabled {
    background: #cccccc;
    cursor: not-allowed;
}