/* Animación de entrada para el título */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Clases para activar las animaciones */
.title-animate {
    animation: slideDown 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.subtitle-animate {
    animation: slideDown 1s cubic-bezier(0.16, 1, 0.3, 1) 0.4s forwards;
}

/* Estilos para la animación de las tarjetas */
.step {
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1), 
                transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity;
}

.step-animate {
    opacity: 1;
    transform: translateY(0);
}

/* Estilos para la sección de Metodología */
.methodology-section {
    padding: 40px 0;
    background-color: #f8f9fa;
    position: relative;
    overflow: hidden;
}

.methodology-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.methodology-header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
}

.methodology-header .section-title {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 15px;
    font-weight: 700;
    opacity: 0; /* Inicialmente oculto */
    transform: translateY(-30px); /* Posición inicial para la animación */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.methodology-header .section-subtitle {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    margin: 0 auto;
}

.steps-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 50px;
}

.step {
    flex: 1;
    min-width: 300px;
    background: white;
    border-radius: 12px;
    padding: 40px 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.step:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1), 0 5px 15px rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.05);
}

/* Efecto sutil de brillo al hacer hover */
.step::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.step:hover::before {
    opacity: 1;
}

.step-number {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #f20784, #e60679);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.step:hover .step-number {
    background: linear-gradient(135deg, #e60679, #c40568);
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(226, 6, 121, 0.3);
}

.step-number::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: scale(1.5);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.step:hover .step-number::before {
    transform: scale(1.2);
    opacity: 0.3;
}

.step h3 {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 15px;
    font-weight: 600;
}

.step p {
    color: #666;
    line-height: 1.6;
    font-size: 1rem;
}

/* Línea decorativa entre pasos */
.step:not(:last-child)::after {
    content: '→';
    position: absolute;
    right: -30px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2rem;
    color: #ddd;
    font-weight: 300;
}

/* Responsive */
@media (max-width: 992px) {
    .methodology-section {
        padding: 30px 0 40px;
    }
    
    .methodology-header {
        margin-bottom: 30px;
        padding: 0 15px;
    }
    
    .methodology-header .section-title {
        font-size: 2rem;
        line-height: 1.3;
        margin-bottom: 10px;
    }
    
    .methodology-header .section-subtitle {
        font-size: 1rem;
        max-width: 100%;
        line-height: 1.5;
    }
    
    .steps-container {
        flex-direction: column;
        align-items: center;
    }
    
    .step {
        max-width: 400px;
        width: 100%;
    }
    
    .step:not(:last-child)::after {
        display: none;
    }
    
    .step:not(:last-child) {
        margin-bottom: 10px;
    }
    
    .step::before {
        content: '';
        position: absolute;
        bottom: -25px;
        left: 50%;
        transform: translateX(-50%);
        width: 2px;
        height: 30px;
        background: #eee;
    }
    
    .step:last-child::before {
        display: none;
    }
}

@media (max-width: 576px) {
    .methodology-header .section-title {
        font-size: 1.8rem;
        text-align: center;
    }
    
    .methodology-header .section-subtitle {
        text-align: center;
        padding: 0 10px;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .step {
        padding: 30px 20px;
    }
    
    .step h3 {
        font-size: 1.3rem;
    }
}