/* wp-content/custom-assets/timeline-herencia.css */

.herencia-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 20px 10px;
    margin-top: 50px !important;
    margin-bottom: 80px !important; /* Aumentamos a 80px para forzar el espacio */
    font-family: sans-serif;
    overflow-x: auto;
    clear: both; /* Evita que elementos flotantes se peguen */
}

.herencia-step {
    flex: 1;
    min-width: 140px;
    text-align: center;
    display: flex;
    flex-direction: column;
}

.herencia-box {
    /* CAMBIO CLAVE: min-height en lugar de height fijo */
    min-height: 130px; 
    height: auto; 
    
    border-radius: 12px;
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: white;
    font-weight: bold;
    font-size: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    text-transform: uppercase;
    box-sizing: border-box; /* Asegura que el padding no rompa el tamaño */
}

/* Estilo para el texto dentro de la caja para que no quede pegado al icono */
.herencia-box span, 
.herencia-box p {
    margin-bottom: 10px;
    line-height: 1.2;
}

.herencia-box i {
    font-size: 24px;
    /* CAMBIO CLAVE: Empuja el icono al final de la caja */
    margin-top: auto; 
    padding-top: 10px;
}

.herencia-label {
    margin-top: 12px;
    font-size: 13px;
    color: #555;
    font-weight: 600;
    min-height: 40px; /* Ayuda a que los textos de abajo se alineen mejor */
}

/* Colores de la imagen */
.step-1 { background-color: #F1EAE0; color: #1f2937 !important; }
.step-2 { background-color: #B99566; color: #ffffff !important; }
.step-3 { background-color: #F1EAE0; color: #1f2937 !important; }
.step-4 { background-color: #B99566; color: #ffffff !important; }
.step-5 { background-color: #F1EAE0; color: #1f2937 !important; }
.step-6 { background-color: #B99566; color: #ffffff !important; }

.herencia-arrow {
    color: #1e3a8a;
    font-size: 20px;
    /* Ajuste para que la flecha apunte al centro de la caja */
    margin-bottom: 50px; 
}

/* Adaptación para móviles */
@media (max-width: 768px) {
    .herencia-container { 
        flex-direction: column; 
        align-items: center;
    }
    .herencia-arrow { 
        transform: rotate(90deg); 
        margin: 20px 0; 
    }
    .herencia-step { 
        width: 100%; 
        max-width: 250px; /* Evita que en móvil sean gigantes a lo ancho */
    }
}