﻿* {
    box-sizing: border-box;
}

#chat-launcher {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    background: white;
    border: 1px solid #ddd;
    border-radius: 50px;
    padding: 10px 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    z-index: 9999;
    transition: all 0.3s ease;
}

    #chat-launcher:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
    }

.chat-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    margin-right: 12px;
}

.chat-greeting {
    display: flex;
    flex-direction: column;
    font-size: 14px;
    color: #333;
    font-family: 'Segoe UI', sans-serif;
    text-align: left;
}

    .chat-greeting strong {
        font-weight: 600;
        font-size: 15px;
        color: #0073e6;
    }

#chat-container {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 380px;
    height: auto;
    min-height: 500px;
    max-height: 60vh;
    background: white;
    border-radius: 16px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    display: none;
    flex-direction: column;
    font-family: 'Segoe UI', sans-serif;
    z-index: 9999;
}

.chat-header {
    background: #736791;
    color: white;
    padding: 16px;
    font-weight: bold;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

    .chat-header img {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        margin-right: 10px;
        object-fit: cover;
    }

.chat-body {
    padding: 16px;
    flex: 1;
    overflow-y: auto;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    background-color: #fafafa;
}

.chat-bubble {
    background: #f1f1f1;
    border-radius: 14px;
    padding: 12px 14px;
    margin-bottom: 10px;
    max-width: 85%;
    font-size: 14px;
    line-height: 1.4;
}

    .chat-bubble.user {
        background: #0073e6;
        color: white;
        align-self: flex-end;
    }

.chat-footer {
    border-top: 1px solid #eee;
    padding: 12px;
    display: flex;
    gap: 8px;
    background: #fff;
}

    .chat-footer input {
        flex: 1;
        padding: 10px 14px;
        border: 1px solid #ccc;
        border-radius: 8px;
        font-size: 14px;
    }

    .chat-footer button {
        background: #0073e6;
        color: white;
        border: none;
        padding: 10px 16px;
        border-radius: 8px;
        cursor: pointer;
        font-weight: 600;
        font-size: 14px;
    }

.chat-form input {
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 14px;
}

.chat-form button {
    margin-top: 12px;
    padding: 10px 16px;
    border: none;
    background: #736791;
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
}

.chat-welcome button {
    margin-top: 12px;
    padding: 10px 16px;
    border: none;
    background: #736791;
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    box-shadow: none;
}

label {
    font-weight: 500;
    font-size: 15px;
    margin-bottom: 4px;
    color: #333;
}

/* ============================= */
/* 📱 RESPONSIVIDADE PARA MOBILE */
/* ============================= */
@media (max-width: 768px) {
    #chat-launcher {
        bottom: 15px;
        right: 15px;
        padding: 8px 12px;
    }

    .chat-avatar img {
        width: 32px;
        height: 32px;
        margin-right: 8px;
    }

    .chat-greeting {
        font-size: 13px;
    }

    #chat-container {
        bottom: 0;
        right: 0;
        left: 0;
        width: 100%;
        min-height: 80vh;
        max-height: 90vh;
        border-radius: 16px 16px 0 0;
    }

    .chat-header {
        padding: 14px;
        font-size: 15px;
    }

    .chat-body {
        padding: 12px;
        font-size: 13px;
    }

    .chat-footer {
        padding: 10px;
        gap: 6px;
    }

        .chat-footer input {
            padding: 8px 12px;
            font-size: 13px;
        }

        .chat-footer button {
            padding: 8px 12px;
            font-size: 13px;
        }
}

@media (max-width: 480px) {
    .chat-greeting {
        display: none; /* esconde o texto do botão para dar mais espaço */
    }

    #chat-launcher {
        border-radius: 50%;
        padding: 10px;
        justify-content: center;
    }

    .chat-avatar img {
        margin: 0;
    }

    #chat-container {
        min-height: 85vh;
    }
}
