/* ==========================================================================
   Premium Redesign UI/UX - Auto Confiança Motores
   ========================================================================== */

/* Melhorias em Botões (Micro-interações) */
.flat-button, button, input[type="button"], input[type="submit"] {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    border-radius: 4px !important;
    position: relative;
    overflow: hidden;
}
.flat-button:hover, button:hover, input[type="button"]:hover, input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(242, 194, 26, 0.4) !important;
}

/* Melhorias em Cards (Produtos/Serviços) */
.product .content-product, .item-border {
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    border-radius: 8px !important;
    border: 1px solid rgba(0,0,0,0.05) !important;
}
.product:hover .content-product, .item-border:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(15, 54, 97, 0.1) !important;
}

/* Glassmorphism sutil para overlay do slider e cabeçalhos fixos */
.header.downscrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05) !important;
}

/* Tipografia */
h1, h2, h3, h4, h5, h6 {
    letter-spacing: -0.5px;
}

/* ==========================================================================
   WhatsApp Floating Widget 
   ========================================================================== */
.whatsapp-floating {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none !important;
}

.whatsapp-floating:before {
    content: '';
    position: absolute;
    z-index: -1;
    left: 50%;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: block;
    width: 60px;
    height: 60px;
    background: #25d366;
    border-radius: 50%;
    animation: pulse-border 1.5s ease-out infinite;
}

.whatsapp-floating:hover {
    background-color: #20b858;
    color: white;
    transform: scale(1.1);
    box-shadow: 0 6px 15px rgba(37,211,102,0.4);
}

.whatsapp-floating i {
    margin-top: 2px;
}

/* Tooltip do WhatsApp */
.whatsapp-tooltip {
    position: absolute;
    right: 75px;
    background-color: #fff;
    color: #333;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateX(20px);
    transition: all 0.3s ease;
    white-space: nowrap;
    pointer-events: none;
    font-family: 'Work Sans', sans-serif;
}

.whatsapp-tooltip::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent transparent #fff;
}

.whatsapp-floating:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* Esconder o WhatsApp antigo na home */
.whatswidget-link {
    display: none !important;
}

/* Esconder classe whatsapp antiga se houver */
.whatsapp {
    display: none !important;
}

@keyframes pulse-border {
    0% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(1.5);
        opacity: 0;
    }
}

/* Otimização responsiva WhatsApp */
@media (max-width: 768px) {
    .whatsapp-floating {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 26px;
    }
    .whatsapp-floating:before {
        width: 50px;
        height: 50px;
    }
    .whatsapp-tooltip {
        display: none; /* No tooltip on mobile to prevent overflow issues */
    }
}
