/**
 * Módulo: Pasos (línea de tiempo)
 * Se arma desde el editor de bloques: un Grupo con la clase "ch-steps" que
 * contiene un Grupo "ch-step" por paso (título + texto + nota opcional
 * "ch-step-meta"). La numeración y la línea vertical salen de CSS.
 */

.ch-lead {
    font-size: 1.15rem;
    color: var(--text-light);
    margin-bottom: 40px;
}

.ch-steps {
    counter-reset: ch-step;
    margin: 0 0 40px;
}

.ch-step {
    counter-increment: ch-step;
    position: relative;
    padding: 0 0 36px 76px;
    min-height: 56px;
}

/* Número del paso */
.ch-step::before {
    content: counter(ch-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--color-primary);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ch-step:nth-child(even)::before {
    background: var(--color-danger);
}

/* Línea que une los pasos */
.ch-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 25px;
    top: 60px;
    bottom: 8px;
    width: 2px;
    background: var(--border-color);
}

.page-content .ch-step h3 {
    margin: 10px 0 6px;
    color: var(--color-primary);
    font-size: 1.25rem;
    line-height: 1.35;
}

.ch-step p {
    margin: 0 0 6px;
}

.ch-step-meta {
    font-size: 0.9rem;
    color: var(--text-light);
}

.ch-step .ch-step-meta::before {
    content: '\2713';
    color: var(--color-secondary);
    font-weight: 700;
    margin-right: 6px;
}

/* Cierre con llamado a la acción */
.ch-cta {
    background: var(--bg-body);
    border-left: 4px solid var(--color-danger);
    padding: 24px 28px;
}

.ch-cta p {
    margin: 0 0 12px;
}

.ch-cta .wp-block-buttons {
    margin-bottom: 12px;
}

/* El personalizador pinta ".page-content a" con !important: el botón necesita ganarle */
.page-content .ch-cta .wp-block-button__link {
    background: var(--color-primary);
    color: #fff !important;
    border-radius: 0;
    padding: 12px 28px;
    font-weight: 700;
    text-decoration: none;
}

.page-content .ch-cta .wp-block-button__link:hover {
    background: var(--color-danger);
}

@media (max-width: 600px) {
    .ch-step {
        padding-left: 60px;
    }

    .ch-step::before {
        width: 42px;
        height: 42px;
        font-size: 1.15rem;
    }

    .ch-step:not(:last-child)::after {
        left: 20px;
        top: 50px;
    }

    .page-content .ch-step h3 {
        margin-top: 6px;
    }

    .ch-cta {
        padding: 20px;
    }
}
