/*
COULEURS:
  gris:         #D3D3D3;
  gris-foncé:   #4F5F5D;
  rouge:        #C5645B;
  jaune:        #FFCC66;
  bleu clair:   #9BB5BB;
  bleu fonce:   #415C71;
*/
/* TIMELINE
–––––––––––––––––––––––––––––––––––––––––––––––––– */
.timeline h5{
  font-size: 1.3em;
  margin: 8px 0;
  color: #C5645B;
}
.timeline ul {
  background: #f9f9f9;
  padding: 30px 0 0 0;
}

.timeline ul li {
  list-style-type: none;
  position: relative;
  width: 1px;
  margin: 0 auto;
  padding-top: 50px;
  color: #415C71;
  background: #415C71;
}

.timeline ul li::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: inherit;
}

.timeline ul li div {
  position: relative;
  top: 8px;
  bottom: 0;
  width: 450px;
  padding: 15px;
  border-radius: 3px;
  border: 1px solid #C5645B;
  box-sizing: border-box;
  background: #f1f1f1;
}

.timeline ul li div::before {
  content: '';
  position: absolute;
  bottom: 10px;
  width: 0;
  height: 0;
  border-style: solid;
}

.timeline ul li:nth-child(odd) div {
  left: 45px;
}

.timeline ul li:nth-child(odd) div::before {
  left: -17px;
  border-width: 8px 16px 8px 0;
  border-color: transparent #C5645B transparent transparent;
}

.timeline ul li:nth-child(even) div {
  left: -493px; /** POSITION TUILE GAUCHE **/
}

.timeline ul li:nth-child(even) div::before {
  right: -15px;
  border-width: 8px 0 8px 16px;
  border-color: transparent transparent transparent #C5645B;
}

time {
  display: block;
  font-size: 1.2rem;
  font-weight: bold;
  margin-bottom: 8px;
}


/* EFFECTS
–––––––––––––––––––––––––––––––––––––––––––––––––– */

.timeline ul li::after {
  transition: background .5s ease-in-out;
}

.timeline ul li.in-view::after {
  background: #415C71; /** DOT TIMELINE **/
}

.timeline ul li div {
  visibility: hidden;
  opacity: 0;
  transition: all .5s ease-in-out;
}

.timeline ul li:nth-child(odd) div {
  transform: translate3d(200px, 0, 0);
}

.timeline ul li:nth-child(even) div {
  transform: translate3d(-200px, 0, 0);
}

.timeline ul li.in-view div {
  transform: none;
  visibility: visible;
  opacity: 1;

}
.timeline button{
  position: relative;
  color: #415C71;
  border: 1px solid #C5645B;
  margin: 15px 10px 0px 10px;
  padding: 10px;
  left: 30%;
  border-radius: 3px;
  cursor: pointer;
  transition: .5s;
}
.timeline button:hover{
  background-color: rgba(65, 92, 113, .5);
  color: #f9f9f9;
}

/* GENERAL MEDIA QUERIES
–––––––––––––––––––––––––––––––––––––––––––––––––– */

@media screen and (max-width: 900px) {
  .timeline ul li div {
    width: 250px;
  }
  .timeline ul li:nth-child(even) div {
    left: -289px;
    /*250+45-6*/
  }
}

@media screen and (max-width: 600px) {
  .timeline ul li {
    margin-left: 20px;
  }
  .timeline ul li div {
    width: calc(100vw - 91px);
  }
  .timeline ul li:nth-child(even) div {
    left: 45px;
  }
  .timeline ul li:nth-child(even) div::before {
    left: -15px;
    border-width: 8px 16px 8px 0;
    border-color: transparent #C5645B transparent transparent;
  }
}
