/* ============================================================
   ANIMAÇÕES PREMIUM - CARVING SURF SCHOOL
   Arquivo adicional. NÃO altera o style.css original.
   Basta linkar DEPOIS do style.css no <head>.
   ============================================================ */

/* ---------- 1. ONDAS ANIMADAS (HEADER E FOOTER) ---------- */
.wave-container {
    position: absolute;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    pointer-events: none;
    z-index: 2;
}

/* Ondas na base do HERO (logo abaixo do header) */
.wave-container--hero {
    bottom: -1px;
}

/* Ondas no topo do FOOTER */
.wave-container--footer {
    top: -1px;
    transform: rotate(180deg);
}

.wave-container svg {
    position: relative;
    display: block;
    width: calc(130% + 1.3px);
    height: 90px;
}

.wave-container .wave-fill {
    fill: #00c6fb;
    opacity: 0.25;
}

/* Três camadas de onda com velocidades diferentes = profundidade */
.wave-parallax > use {
    animation: wave-move 22s cubic-bezier(.55,.5,.45,.5) infinite;
}
.wave-parallax > use:nth-child(1) { animation-delay: -2s;  animation-duration: 11s; opacity: 0.30; }
.wave-parallax > use:nth-child(2) { animation-delay: -4s;  animation-duration: 15s; opacity: 0.20; }
.wave-parallax > use:nth-child(3) { animation-delay: -6s;  animation-duration: 19s; opacity: 0.15; }
.wave-parallax > use:nth-child(4) { animation-delay: -8s;  animation-duration: 23s; opacity: 0.40; }

@keyframes wave-move {
    0%   { transform: translate3d(-90px, 0, 0); }
    100% { transform: translate3d(85px, 0, 0); }
}

/* Garante que o hero e o footer comportem as ondas */
.hero { position: relative; overflow: hidden; }
.footer { position: relative; }

/* ---------- 2. BOTÕES COM BRILHO / PULSO ---------- */
.btn--primary {
    position: relative;
    overflow: hidden;
    animation: btn-pulse 2.8s ease-in-out infinite;
}

@keyframes btn-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0, 198, 251, 0.45); }
    50%      { box-shadow: 0 0 22px 4px rgba(0, 198, 251, 0.35); }
}

/* Brilho que atravessa o botão ao passar o mouse */
.btn--primary::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255,255,255,0.45), transparent);
    transform: skewX(-20deg);
    transition: left 0.6s ease;
}
.btn--primary:hover::after { left: 140%; }

/* ---------- 3. CARDS COM ENTRADA SUAVE E HOVER 3D ---------- */
.card, .level-card {
    transition: transform 0.45s cubic-bezier(.2,.8,.2,1), box-shadow 0.45s ease;
}
.card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 18px 40px rgba(0, 198, 251, 0.18);
}
.level-card:hover {
    transform: translateY(-8px) scale(1.015);
    box-shadow: 0 20px 45px rgba(0,0,0,0.35);
}

/* Ícone dos cards com leve flutuação */
.card__icon {
    animation: icon-float 3.5s ease-in-out infinite;
}
@keyframes icon-float {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-7px); }
}

/* ---------- 4. BADGES DO HERO COM ENTRADA ESCALONADA ---------- */
.hero__badges .badge {
    opacity: 0;
    animation: badge-in 0.6s ease forwards;
}
.hero__badges .badge:nth-child(1) { animation-delay: 0.7s; }
.hero__badges .badge:nth-child(2) { animation-delay: 0.9s; }
.hero__badges .badge:nth-child(3) { animation-delay: 1.1s; }

@keyframes badge-in {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ---------- 5. BOTÃO FLUTUANTE WHATSAPP COM PULSO ---------- */
.whatsapp-float {
    animation: whats-pulse 2s ease-in-out infinite;
}
@keyframes whats-pulse {
    0%, 100% { transform: scale(1);    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
    50%      { transform: scale(1.08); box-shadow: 0 0 0 12px rgba(37, 211, 102, 0); }
}

/* ---------- 6. REVELAÇÃO AO ROLAR A PÁGINA (scroll reveal) ---------- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(.2,.8,.2,1);
}
.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- 7. GRADIENTE DE TEXTO ANIMADO ---------- */
.text-gradient {
    background: linear-gradient(90deg, #00c6fb, #005bea, #00c6fb);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-slide 4s linear infinite;
}
@keyframes gradient-slide {
    to { background-position: 200% center; }
}

/* ---------- 8. LOGO DO HEADER COM LEVE RESPIRO ---------- */
.logo-img--header {
    transition: transform 0.4s ease;
}
.logo-img--header:hover {
    transform: scale(1.06) rotate(-2deg);
}

/* ---------- RESPEITA QUEM PREFERE MENOS MOVIMENTO ---------- */
@media (prefers-reduced-motion: reduce) {
    *, .wave-parallax > use, .btn--primary, .card__icon,
    .whatsapp-float, .text-gradient {
        animation: none !important;
        transition: none !important;
    }
}
