/**
 * Chatbot Labflow - Standalone CSS
 * Estilos base para o chatbot embeddable
 * 
 * @version 1.0.0
 */

/* Reset básico para o container do chatbot */
#labflow-chatbot-root {
    all: initial;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

#labflow-chatbot-root * {
    box-sizing: border-box;
}

/* Estilos base do ícone - sobrescritos por JS */
.labflow-chatbot-icon {
    position: fixed;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    user-select: none;
}

.labflow-chatbot-icon:active {
    transform: scale(0.95);
}

/* Container do chat */
.labflow-chatbot-container {
    position: fixed;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    display: none;
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    z-index: 99999;
}

.labflow-chatbot-container.labflow-open {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

/* Iframe do chat */
.labflow-chatbot-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Badge de notificação (opcional para uso futuro) */
.labflow-notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background-color: #ff4444;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    border: 2px solid white;
}

/* Loading state */
.labflow-chatbot-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #1a1a1a;
    border-radius: 50%;
    animation: labflow-spin 1s linear infinite;
}

@keyframes labflow-spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Accessibility */
.labflow-chatbot-icon:focus {
    outline: 2px solid #4a90e2;
    outline-offset: 2px;
}

.labflow-chatbot-icon:focus:not(:focus-visible) {
    outline: none;
}

/* Print styles */
@media print {
    #labflow-chatbot-root {
        display: none !important;
    }
}
