/* ========================================
   HG Caça Vazamentos - Microanimações
   Animações sutis e elegantes
======================================== */

/* ========================================
   KEYFRAMES
======================================== */

/* Pulse genérico */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

/* Pulse para WhatsApp */
@keyframes whatsapp-pulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }
    100% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0;
    }
}

/* Float suave */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Shimmer */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Slide In */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Scale In */
@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Glow */
@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(0, 180, 216, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(0, 180, 216, 0.5);
    }
}

/* Ripple */
@keyframes ripple {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

/* ========================================
   APLICAÇÃO DE ANIMAÇÕES
======================================== */

/* Hero Badge */
.hero-badge {
    animation: slideInUp 0.6s ease-out;
}

/* Hero Title */
.hero h1 {
    animation: slideInUp 0.6s ease-out 0.1s both;
}

/* Hero Description */
.hero-description {
    animation: slideInUp 0.6s ease-out 0.2s both;
}

/* CTA Group */
.cta-group {
    animation: slideInUp 0.6s ease-out 0.3s both;
}

/* Feature Cards - Stagger */
.feature-card:nth-child(1) { animation: slideInUp 0.5s ease-out 0.1s both; }
.feature-card:nth-child(2) { animation: slideInUp 0.5s ease-out 0.2s both; }
.feature-card:nth-child(3) { animation: slideInUp 0.5s ease-out 0.3s both; }
.feature-card:nth-child(4) { animation: slideInUp 0.5s ease-out 0.4s both; }

/* Logo Icon Glow */
.logo-icon {
    animation: glow 3s ease-in-out infinite;
}

/* ========================================
   HOVER MICRO-INTERACTIONS
======================================== */

/* Botões - Efeito Ripple */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.5s ease;
}

.btn:active::after {
    transform: translate(-50%, -50%) scale(40);
    transition: transform 0s;
}

/* Links - Underline animado */
.footer-section a {
    position: relative;
}

.footer-section a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--cor-accent);
    transition: width 0.3s ease;
}

.footer-section a:hover::after {
    width: 100%;
}

/* Feature Cards - Icon bounce */
.feature-card:hover .feature-icon {
    animation: float 0.6s ease-in-out;
}

/* ========================================
   SCROLL ANIMATIONS (JS controlled)
======================================== */

/* Elementos que serão animados no scroll */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Variações de direção */
.animate-left {
    transform: translateX(-30px);
}

.animate-left.animated {
    transform: translateX(0);
}

.animate-right {
    transform: translateX(30px);
}

.animate-right.animated {
    transform: translateX(0);
}

.animate-scale {
    transform: scale(0.9);
}

.animate-scale.animated {
    transform: scale(1);
}

/* ========================================
   LOADING STATES (sem spinner)
======================================== */

/* Skeleton loader para conteúdo */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--cor-cinza-claro) 25%,
        #e8e8e8 50%,
        var(--cor-cinza-claro) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* ========================================
   FOCUS STATES (Acessibilidade)
======================================== */

/* Focus visible para teclado */
.btn:focus-visible,
a:focus-visible {
    outline: 3px solid var(--cor-accent);
    outline-offset: 3px;
}

/* Remove outline no mouse */
.btn:focus:not(:focus-visible),
a:focus:not(:focus-visible) {
    outline: none;
}

/* ========================================
   TRANSIÇÕES SUAVES
======================================== */

/* Transição padrão para todos elementos interativos */
a,
button,
.btn,
.feature-card,
input,
textarea {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Transição mais lenta para backgrounds */
.header,
.hero,
.footer {
    transition: background 0.5s ease;
}

/* ========================================
   PREFERÊNCIAS DO USUÁRIO
======================================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .animate-on-scroll {
        opacity: 1;
        transform: none;
    }
}


