:root {
    --green: #006D36;
    --green-dark: #004D26;
    --red: #D7262B;
    --blue: #0B3768;
    --light: #F6F8F9;
}

/* ==========================================
   TIMELINE
   ========================================== */

.timeline {
    position: relative;
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px 0;
}

/* Ligne centrale */
.timeline::after {
    content: "";
    position: absolute;

    width: 4px;

    background: #d9dee5;

    top: 0;
    bottom: 0;

    left: 50%;

    transform: translateX(-50%);

    z-index: 1;
}


/* ==========================================
   ITEM
   ========================================== */

.timeline-item {
    position: relative;

    width: 50%;

    padding: 20px 50px;

    box-sizing: border-box;

    z-index: 2;
}


/* Gauche */
.timeline-item.left {
    margin-right: 50%;
}


/* Droite */
.timeline-item.right {
    margin-left: 50%;
}


/* ==========================================
   NUMERO
   ========================================== */

.timeline-number {
    position: absolute;

    width: 50px;
    height: 50px;

    background: var(--blue);
    color: white;

    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 18px;
    font-weight: 800;

    top: 20px;

    z-index: 10;

    border: 4px solid white;

    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
}


/* Item gauche */
.timeline-item.left .timeline-number {
    right: -25px;
}


/* Item droite */
.timeline-item.right .timeline-number {
    left: -25px;
}


/* ==========================================
   CONTENU
   ========================================== */

.timeline-content {
    background: white;

    border-radius: 15px;

    padding: 25px;

    box-shadow: 0 5px 20px rgba(0, 0, 0, .08);

    border: 1px solid #e5e7eb;

    transition: all .3s ease;
}

.timeline-content:hover {
    transform: translateY(-3px);

    box-shadow: 0 10px 30px rgba(0, 0, 0, .12);
}


/* ==========================================
   MOBILE
   ========================================== */

@media (max-width: 768px) {

    .timeline {
        width: 100%;

        margin: 30px 0;

        padding: 10px 0;
    }

    /* Ligne à gauche */
    .timeline::after {
        left: 25px;

        transform: none;

        width: 4px;
    }

    /* Tous les éléments prennent toute la largeur */
    .timeline-item,
    .timeline-item.left,
    .timeline-item.right {

        width: 100%;

        margin: 0;

        padding-top: 20px;
        padding-bottom: 20px;

        padding-left: 65px;
        padding-right: 15px;

        box-sizing: border-box;
    }

    /* Numéro */
    .timeline-number,
    .timeline-item.left .timeline-number,
    .timeline-item.right .timeline-number {

        left: 0;

        right: auto;

        width: 50px;
        height: 50px;

        top: 20px;
    }

    /* Contenu */
    .timeline-content {
        width: 100%;

        padding: 20px;

        box-sizing: border-box;

        text-align: right;
    }

    /* Empêcher les textes longs de provoquer un débordement */
    .timeline-content h3,
    .timeline-content h4,
    .timeline-content p {
        max-width: 100%;

        overflow-wrap: break-word;

        word-wrap: break-word;
    }
}


/* ==========================================
   PETITS TELEPHONES
   ========================================== */

@media (max-width: 480px) {

    .timeline::after {
        left: 20px;
    }

    .timeline-item,
    .timeline-item.left,
    .timeline-item.right {

        padding-left: 55px;
        padding-right: 10px;
    }

    .timeline-number,
    .timeline-item.left .timeline-number,
    .timeline-item.right .timeline-number {

        width: 40px;
        height: 40px;

        font-size: 14px;

        left: 0;
    }

    .timeline-content {
        padding: 15px;

        border-radius: 12px;
    }
}