.timeline-wrapper {
    align-items: center;
    row-gap: var(--section-gap);
}

.timeline-wrapper .text-wrapper {
    margin-top: var(--content-gap);
    margin-bottom: 0;
}
.timeline-wrapper .timeline {
    padding: 2rem 1rem 0;
}
.timeline-wrapper .text-wrapper div {
    padding-top: 1.5rem;
}
.timeline__block {
    display: grid;
    grid-template-columns: var(--row-size-x) auto;
    grid-template-rows: var(--row-size-x) var(--row-size-y);

    column-gap: var(--content-gap);
    width: 100%; 
}
.timeline__block {
    display: grid;
    grid-template-columns: var(--row-size-x) 1fr;
    grid-template-rows: var(--row-size-x) auto; /* altezza variabile per il testo */
    column-gap: var(--content-gap);
    width: 100%;
}
.timeline__bullet {
    grid-column: 1;
    grid-row: 1;
    align-self: center;
    margin: 0 auto;

    width: calc(var(--row-size-x) / 100 * 39);
    height: calc(var(--row-size-x) / 100 * 39);
    display: flex;
    align-items: center;
    justify-content: center;
    
    border: solid 1px var(--color-white);
    border-radius: 50%;

    transition: all .3s ease-out;
}
.timeline__bullet::before {
    content: " ";

    width: 0;
    height: 0;

    background-color: var(--color-white);
    border-radius: 50%;
    transition: all .3s ease-in-out;
}
.timeline__block:hover .timeline__bullet,
.timeline-wrapper:not(:has(.timeline__block:hover)) .timeline__bullet.the_first {
    width: var(--row-size-x);
    height: var(--row-size-x);
}
.timeline__block:hover .timeline__bullet::before,
.timeline-wrapper:not(:has(.timeline__block:hover)) .timeline__bullet.the_first::before  {
    width: calc(var(--row-size-x) / 100 * 39);
    height: calc(var(--row-size-x) / 100 * 39);
}

.timeline__title {
    grid-column: 2;
    grid-row: 1;
    height: var(--row-size-x);
    display: flex;
    align-items: center;
}

.timeline__decor {
    grid-column: 1;
    grid-row: 2;
    width: var(--row-size-x);

    display: flex;
    justify-content: center;
}
.timeline__decor::before {
    content: "";
    width: 1px;
    height: 100%;

    background-color: var(--color-white);
}
.timeline__block:last-of-type {
    grid-template-columns: var(--row-size-x) auto;
    grid-template-rows: var(--row-size-x) auto;
}
.timeline__block:last-of-type .timeline__decor {
    min-height: 0;
    height: 0;
}
.timeline__description {
    display: flex;
    flex-direction: column;
    row-gap: 1rem;
    padding-bottom: var(--content-gap);
}
@media screen and (min-width: 768px) {
    .timeline-wrapper .timeline {
        padding: 0;
        max-width: 75%;
        flex-grow: 1;
    }
}
@media screen and (min-width: 998px) {
    .timeline-wrapper {
        align-items: flex-start;
    }
}
@media screen and (min-width: 1200px) {
    .timeline-wrapper .text-wrapper {
        margin-top: var(--content-gap);
        margin-bottom: 0;
    }
}