/* ============================================
   EFEITOS DE ROLAGEM E TRANSIÇÕES MODERNAS
   ============================================ */

/* Scroll Reveal - Elementos aparecem ao rolar */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.scroll-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.scroll-reveal.left {
    transform: translateX(-50px);
}

.scroll-reveal.left.active {
    transform: translateX(0);
}

.scroll-reveal.right {
    transform: translateX(50px);
}

.scroll-reveal.right.active {
    transform: translateX(0);
}

/* Parallax Effect */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Fade In Up Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 40px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translate3d(0, -40px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translate3d(-40px, 0, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translate3d(40px, 0, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Animações de Entrada */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.fade-in-down {
    animation: fadeInDown 0.8s ease-out forwards;
}

.fade-in-left {
    animation: fadeInLeft 0.8s ease-out forwards;
}

.fade-in-right {
    animation: fadeInRight 0.8s ease-out forwards;
}

.scale-in {
    animation: scaleIn 0.8s ease-out forwards;
}

/* Delay para efeito em cascata */
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }

/* ============================================
   TRANSIÇÕES MODERNAS PARA CARDS
   ============================================ */

.card {
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(227, 30, 36, 0.05);
    transition: left 0.4s ease;
    z-index: -1;
}

.card:hover::before {
    left: 100%;
}

.card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(227, 30, 36, 0.2);
}

/* ============================================
   TRANSIÇÕES MODERNAS PARA BOTÕES
   ============================================ */

.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
    z-index: 0;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn span {
    position: relative;
    z-index: 1;
}

.btn-primary:hover {
    background: #c41a1f;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(227, 30, 36, 0.4);
}

.btn-secondary:hover {
    background: #E31E24;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(227, 30, 36, 0.3);
}

/* ============================================
   TRANSIÇÕES MODERNAS PARA LINKS
   ============================================ */

nav a {
    position: relative;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #E31E24;
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

nav a:hover::after {
    width: 100%;
}

nav a:hover {
    color: #E31E24;
    transform: translateY(-2px);
}

/* ============================================
   TRANSIÇÕES MODERNAS PARA SEÇÕES
   ============================================ */

section {
    transition: all 0.6s ease;
}

/* ============================================
   EFEITO DE LINHA VERMELHA COM ANIMAÇÃO
   ============================================ */

.red-line {
    height: 3px;
    background: linear-gradient(90deg, transparent, #E31E24, transparent);
    margin: 3rem 0;
    animation: slideIn 0.8s ease-out;
}

@keyframes slideIn {
    from {
        width: 0;
        opacity: 0;
    }
    to {
        width: 100%;
        opacity: 1;
    }
}

/* ============================================
   EFEITO DE HOVER PARA IMAGENS
   ============================================ */

img.fade-in {
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: brightness(1);
}

img.fade-in:hover {
    filter: brightness(1.1);
    transform: scale(1.05);
}

/* ============================================
   EFEITO DE CONTADOR COM ANIMAÇÃO
   ============================================ */

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: #E31E24;
    transition: all 0.4s ease;
}

.stats > div:hover .stat-number {
    transform: scale(1.2) rotate(5deg);
    color: #c41a1f;
}

/* ============================================
   EFEITO DE BADGE COM ANIMAÇÃO
   ============================================ */

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: #FDD7D8;
    color: #E31E24;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 1px;
    animation: slideInDown 0.6s ease-out;
    transition: all 0.3s ease;
}

.badge:hover {
    background: #E31E24;
    color: white;
    transform: translateY(-3px);
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   EFEITO DE SCROLL SUAVE
   ============================================ */

html {
    scroll-behavior: smooth;
}

/* ============================================
   EFEITO DE UNDERLINE ANIMADO
   ============================================ */

.underline-animation {
    position: relative;
    display: inline-block;
}

.underline-animation::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #E31E24;
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.underline-animation:hover::after {
    width: 100%;
}

/* ============================================
   EFEITO DE GRADIENT ANIMADO
   ============================================ */

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.gradient-animated {
    background: linear-gradient(-45deg, #E31E24, #c41a1f, #E31E24, #c41a1f);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

/* ============================================
   EFEITO DE SOMBRA DINÂMICA
   ============================================ */

.shadow-dynamic {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.4s ease;
}

.shadow-dynamic:hover {
    box-shadow: 0 15px 40px rgba(227, 30, 36, 0.2);
}

/* ============================================
   EFEITO DE TEXTO ANIMADO
   ============================================ */

@keyframes textGlow {
    0% {
        text-shadow: 0 0 10px rgba(227, 30, 36, 0.5);
    }
    50% {
        text-shadow: 0 0 20px rgba(227, 30, 36, 0.8);
    }
    100% {
        text-shadow: 0 0 10px rgba(227, 30, 36, 0.5);
    }
}

.text-glow {
    animation: textGlow 2s ease-in-out infinite;
}

/* ============================================
   EFEITO DE PULSE PARA ELEMENTOS
   ============================================ */

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* ============================================
   RESPONSIVIDADE DOS EFEITOS
   ============================================ */

@media (max-width: 768px) {
    .card:hover {
        transform: translateY(-4px) scale(1.01);
    }

    .btn:hover {
        transform: translateY(-2px);
    }

    nav a:hover {
        transform: translateY(-1px);
    }

    .scroll-reveal {
        transition: all 0.6s ease;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
