/* Global module - Home: Joining Steps (numbered circles joined by a dotted line, on a pale orange tint) */
.el-join {
    --el-join-dot: clamp(56px, calc(56px + 8 * (100vw - 1280px) / 640), 64px);
    background: #fdeee7;
}

.el-join-head {
    max-width: 1200px;
    margin: 0 auto clamp(40px, calc(40px + 20 * (100vw - 1280px) / 640), 60px);
    text-align: center;
}

.el-join-title {
    margin: 0;
}

.el-join-steps {
    position: relative;
    display: grid;
    grid-template-columns: repeat(var(--el-join-cols, 5), minmax(0, 1fr));
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: el-join;
}

/* Dotted line from the first circle's centre to the last one's. */
.el-join-steps::before {
    content: "";
    position: absolute;
    top: calc(var(--el-join-dot) / 2 - 1px);
    right: calc(50% / var(--el-join-cols, 5));
    left: calc(50% / var(--el-join-cols, 5));
    height: 2px;
    background: repeating-linear-gradient(90deg, var(--el-color-orange) 0 8px, transparent 8px 14px);
}

.el-join-step {
    position: relative;
    padding: 0 14px;
    text-align: center;
    counter-increment: el-join;
}

.el-join-step::before {
    content: counter(el-join);
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: var(--el-join-dot);
    height: var(--el-join-dot);
    margin: 0 auto 18px;
    border: 2px solid var(--el-color-orange);
    border-radius: 50%;
    background: var(--el-color-white);
    font-family: var(--el-font-heading);
    font-size: clamp(22px, calc(22px + 4 * (100vw - 1280px) / 640), 26px);
    color: var(--el-color-orange-text);
}

.el-join-step.is-highlight::before {
    background: var(--el-color-orange);
    color: var(--el-color-white);
}

.el-join-step-title {
    margin: 0 0 8px;
    font-size: clamp(19px, calc(19px + 5 * (100vw - 1280px) / 640), 24px);
    line-height: 1.25;
}

.el-join-step-text {
    margin: 0;
    font-size: clamp(14px, calc(14px + 2 * (100vw - 1280px) / 640), 16px);
    color: var(--el-color-muted);
}

.el-join-when {
    display: inline-block;
    margin-top: 10px;
    padding: 3px 10px;
    border: 1px solid #dde3e8;
    border-radius: 999px;
    background: var(--el-color-white);
    font-size: 12px;
    font-weight: 600;
    color: var(--el-color-heading);
}

.el-join-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
    margin-top: clamp(40px, calc(40px + 16 * (100vw - 1280px) / 640), 56px);
}

/* Tablet and phones: one step per row, circle on the left, the dotted line runs down. */
@media (max-width: 991px) {
    .el-join-steps {
        grid-template-columns: minmax(0, 1fr);
        gap: 26px;
        max-width: 620px;
        margin-inline: auto;
    }

    /* One line piece per step, from its circle down to the next circle, so the line stops at the last one. */
    .el-join-steps::before {
        content: none;
    }

    .el-join-step:not(:last-child)::after {
        content: "";
        position: absolute;
        top: calc(var(--el-join-dot) / 2);
        bottom: -26px; /* the gap between steps */
        left: calc(var(--el-join-dot) / 2 - 1px);
        width: 2px;
        background: repeating-linear-gradient(180deg, var(--el-color-orange) 0 8px, transparent 8px 14px);
    }

    .el-join-step {
        display: grid;
        grid-template-columns: var(--el-join-dot) minmax(0, 1fr);
        gap: 18px;
        padding: 0;
        text-align: left;
    }

    .el-join-step::before {
        margin: 0;
    }
}

@media (max-width: 767px) {
    .el-join-actions .btn {
        width: 100%;
    }
}
