/* ==========================================================================
   IS PROCESS TIMELINE
   ========================================================================== */

.is-process__head {
    margin-bottom: 40px;
}

.is-process .is-head__eyebrow {
    margin-bottom: 0;
}

.is-process .is-head__title {
    font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2rem);
    margin-top: var(--is-space-sm);
}

/* --------------------------------------------------------------------------
   STEPS
   -------------------------------------------------------------------------- */
.is-process__steps {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    column-gap: 24px;
    row-gap: 40px;
    counter-reset: is-step;
    margin: 0;
    padding: 0;
    list-style: none;
}

.is-step {
    --is-connector: var(--is-line-strong);
    --is-connector-thickness: 1px;
    --is-arrow-size: 5px;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* --- Number row + connector --- */
.is-step__head {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--is-space-md);
    margin-bottom: 14px;
}

.is-step__number {
    font-family: var(--is-font-display);
    font-size: var(--is-text-lg);
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.01em;
    color: var(--is-fg);
    transition: color var(--is-normal) var(--is-ease);
}

.is-step__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    font-size: 24px;
    color: var(--is-accent);
}

.is-step__icon svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.3;
}

/* The connector runs from the number to the next column. It is a flex child, so
   it simply eats the remaining width — no absolute positioning maths needed. */
.is-step__connector {
    display: none;
    position: relative;
    flex: 1 1 auto;
    height: var(--is-connector-thickness);
    background-color: var(--is-connector);
}

.is-process__steps--connected .is-step:not(.is-step--last) .is-step__connector {
    display: block;
}

.is-process__steps--connected.is-process__steps--arrows
    .is-step:not(.is-step--last)
    .is-step__connector::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: var(--is-arrow-size) solid var(--is-connector);
    border-top: calc(var(--is-arrow-size) * 0.72) solid transparent;
    border-bottom: calc(var(--is-arrow-size) * 0.72) solid transparent;
}

/* --- Hairline rule --- */
.is-step__rule {
    display: block;
    width: 100%;
    height: 1px;
    margin-bottom: 16px;
    background-color: var(--is-line);
}

/* --- Text --- */
.is-step__title {
    font-family: var(--is-font-body);
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.13em;
    line-height: 1.5;
    text-transform: uppercase;
    color: var(--is-fg);
    margin-bottom: 8px;
}

.is-step__description {
    font-size: var(--is-text-xs);
    line-height: 1.7;
    color: var(--is-muted);
    max-width: 26ch;
}

/* --------------------------------------------------------------------------
   RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    .is-process__steps {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 40px;
    }

    /* Kill the connector at the end of each visual row so no arrow points into
       empty space. */
    .is-process__steps--connected .is-step:nth-child(3n) .is-step__connector {
        display: none;
    }
}

@media (max-width: 767px) {
    .is-process__steps {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 0;
    }

    .is-process__steps--connected .is-step .is-step__connector {
        display: none;
    }

    .is-step {
        padding: 24px 0 24px 44px;
    }

    .is-step__head {
        margin-bottom: 10px;
    }

    .is-step__number,
    .is-step__icon {
        position: absolute;
        left: 0;
        top: 33px;
    }

    .is-step:not(.is-step--last)::before {
        content: '';
        position: absolute;
        left: 13px;
        top: 52px;
        bottom: 0;
        width: var(--is-connector-thickness);
        background-color: var(--is-connector);
    }

    .is-step__title{
        font-size: 18px;
    }

    .is-step__rule {
        display: none;
    }

    .is-step__description {
        max-width: none;
        margin-top: 20px !important;
        font-size: 14px;
        line-height: 1.3;
    }
}
