/* Container Principal */
.wm-help-fab-container {
    position: fixed;
    bottom: 20px; /* Mantém próximo, mas evita sobrepor o "Voltar ao topo" do Woodmart */
    right: 20px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-family: inherit; /* Herda a tipografia global do Woodmart */
}

/* Woodmart often uses bottom bars on mobile, adjusting position to avoid overlap */
@media (max-width: 768px) {
    .wm-help-fab-container {
        bottom: 70px; /* Distância segura da barra de navegação inferior mobile padrão do Woodmart */
        right: 15px;
    }
}

/* Menu de botões (inicialmente escondido) */
.wm-help-fab-menu {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    margin-bottom: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    pointer-events: none;
}

/* Estado aberto do menu */
.wm-help-fab-container.is-open .wm-help-fab-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* Itens do Menu (Pílulas) */
.wm-help-fab-item {
    display: inline-block !important;
    background-color: #FFFFFF !important;
    color: #777777 !important;
    border: 1px solid #E0E0E0 !important;
    border-radius: 50px !important;
    padding: 8px 18px !important;
    margin-top: 8px !important;
    font-size: 14px !important;
    font-weight: normal !important;
    text-transform: none !important;
    text-decoration: none !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05) !important;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s, transform 0.2s !important;
    white-space: nowrap !important;
}

.wm-help-fab-item:hover,
.wm-help-fab-item:focus {
    background-color: #fdfdfd !important;
    color: #444444 !important;
    border-color: #cccccc !important;
    transform: translateY(-2px) !important;
}

/* Botão Toggle (Principal) */
button#wm-help-fab-toggle.wm-help-fab-toggle {
    background-color: #FFFFFF !important;
    color: #777777 !important;
    border: 1px solid #E0E0E0 !important;
    border-radius: 50px !important; /* Pílula */
    padding: 10px 22px !important;
    font-size: 15px !important;
    font-weight: normal !important;
    text-transform: none !important;
    cursor: pointer !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    height: 48px !important;
    min-width: 100px !important;
    outline: none !important;
}

button#wm-help-fab-toggle.wm-help-fab-toggle:hover {
    box-shadow: 0 6px 16px rgba(0,0,0,0.12) !important;
}

/* Estado aberto do botão principal (vira um círculo com X) */
.wm-help-fab-container.is-open button#wm-help-fab-toggle.wm-help-fab-toggle {
    border-radius: 50% !important;
    min-width: 48px !important;
    width: 48px !important;
    height: 48px !important;
    padding: 0 !important;
    transform: rotate(90deg) !important; /* Animação de giro ao abrir */
}

/* Alternância de ícone e texto */
.wm-help-fab-text,
.wm-help-fab-icon-close {
    transition: opacity 0.2s ease;
}

.wm-help-fab-container.is-open .wm-help-fab-text {
    display: none;
}

.wm-help-fab-icon-close {
    font-size: 26px;
    line-height: 1;
    color: #777777;
}

.wm-help-fab-container.is-open .wm-help-fab-icon-close {
    display: flex !important; /* Mostra o X quando aberto */
    align-items: center;
    justify-content: center;
    transform: rotate(-90deg); /* Desfaz o giro visualmente para o X ficar alinhado */
}
