/* ==========================================================================
   certana/steps
   Mobil: senkrechte Zeitleiste (Nummer links, gestrichelte Linie, Text rechts).
   Ab 992px: Schritte nebeneinander, Nummern durch gestrichelte Linie verbunden,
   Illustration im runden Feld, Text zentriert.
   ========================================================================== */

.steps {
    --step-number: 44px;
    --step-gap: 1.75rem;
    --step-line: #c5cedb;
    padding-block: clamp(3rem, 6vw, 5rem);
    background: linear-gradient(180deg, #f9fbfe 0%, #f3f7fb 100%);
}

.steps__intro { margin-bottom: clamp(1.5rem, 3vw, 3rem); }
.steps__eyebrow { margin-bottom: 0.75rem; }

.steps__heading {
    margin: 0;
    font-family: var(--font-serif);
    font-size: clamp(1.875rem, 1.1rem + 2.6vw, 3.5rem);
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.015em;
    color: var(--c-ink);
    text-wrap: balance;
}

.steps__lead {
    max-width: 40rem;
    margin: 1rem 0 0;
    font-size: clamp(1rem, 0.94rem + 0.3vw, 1.125rem);
    line-height: 1.55;
    color: #4a5263;
}

/* Liste: mobil als Zeitleiste -------------------------------------------- */
.steps__list {
    display: grid;
    gap: var(--step-gap);
    margin: 0;
    padding: 0;
    list-style: none;
}

.step {
    position: relative;
    display: grid;
    grid-template-columns: var(--step-number) minmax(0, 1fr);
    column-gap: 1.1rem;
    align-items: start;
    align-content: start;
}

/* Gestrichelte Verbindung zum nächsten Schritt (senkrecht) */
.step:not(:last-child)::after {
    content: "";
    position: absolute;
    left: calc(var(--step-number) / 2 - 1px);
    top: calc(var(--step-number) + 0.4rem);
    bottom: calc(-1 * var(--step-gap) + 0.4rem);
    border-left: 2px dashed var(--step-line);
}

.step__number {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--step-number);
    height: var(--step-number);
    border-radius: 50%;
    background: var(--c-accent);
    box-shadow: 0 8px 18px -8px rgba(247, 144, 30, 0.7);
    font-family: var(--font-sans);
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1;
    color: #fff;
}

/* Illustration nur ab Desktop */
.step__media { display: none; }

.step__body { padding-top: 0.45rem; }

.step__title {
    margin: 0 0 0.35rem;
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0;
    color: var(--c-ink);
}

.step__text {
    margin: 0;
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--c-muted);
}

.step__link { color: inherit; text-decoration: none; }
.step__link:hover {
    color: var(--c-accent-strong);
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Desktop: nebeneinander ------------------------------------------------- */
@media (min-width: 992px) {
    .steps {
        --step-number: 64px;
        --step-gap: clamp(1.5rem, 3vw, 3rem);
        --step-media: clamp(140px, 12vw, 172px);
    }

    .steps__list {
        grid-template-columns: repeat(var(--steps-count, 3), minmax(0, 1fr));
        column-gap: var(--step-gap);
    }

    .step {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
    }

    /* Waagerechte Verbindung von Nummer zu Nummer */
    .step:not(:last-child)::after {
        left: calc(50% + var(--step-number) / 2 + 0.5rem);
        right: auto;
        top: calc(var(--step-number) / 2 - 1px);
        bottom: auto;
        width: calc(100% + var(--step-gap) - var(--step-number) - 1rem);
        border-left: 0;
        border-top: 2px dashed var(--step-line);
    }

    .step__number { font-size: 1.625rem; }

    .step__media {
        display: grid;
        place-items: center;
        width: var(--step-media);
        height: var(--step-media);
        margin-top: 0.4rem;
        border-radius: 50%;
        background: #eef4fb;
        overflow: hidden;
    }
    .step__image {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: contain;
    }
    .step__media--icon { color: var(--c-accent); }
    .step__media--icon .icon { width: 44%; height: 44%; stroke-width: 1.6; }

    .step__body {
        max-width: 22rem;
        padding-top: 1.4rem;
    }
    .step__title {
        margin-bottom: 0.6rem;
        font-size: clamp(1.25rem, 0.95rem + 0.7vw, 1.5rem);
        font-weight: 550;
    }
    .step__text { font-size: clamp(1rem, 0.92rem + 0.25vw, 1.125rem); }
}
