:root {
  --text-color: #3c3f64;
}

*,
*::before,
*::after {
margin: 0;
padding: 0;
box-sizing: border-box;
}



.timeline ul {
padding: 0;
}

.timeline ul li {
list-style-type: none;
position: relative;
width: 6px;
margin: 0 auto;
padding-top: 50px;
background: #222831;
}

.timeline ul li::after {
content: '';
position: absolute;
left: 50%;
bottom: 0;
transform: translateX(-50%) rotate(45deg);
width: 20px;
height: 20px;
z-index: 2;
background: #F5EEDD;
}

.timeline ul li > div {
position: relative;
bottom: 0;
width: 300px;
padding: 20px;
background: var(--primary-color);
box-shadow: 4px 13px 30px 1px rgba(252, 56, 56, 0.2);
border-radius: 5px;
display: flex;
flex-direction: column;
align-items: center;
visibility: hidden;
opacity: 0;
transition: all 0.5s ease-in-out;
}

.timeline ul li > div time {
position: absolute;
background: #f5af19;
width: 80px;
height: 30px;
top: -15px;
border-radius: 5px;
display: flex;
justify-content: center;
align-items: center;
letter-spacing: 2px;
font-weight: bold;
}

.timeline ul li > div h1 {
text-align: center;
margin-top: 10px;
font-size: 24px;
color: var(--text-color);
}

.timeline ul li > div p,
.timeline ul li > div span {
text-align: center;
margin-top: 5px;
}

.timeline-img {
width: 100%;
max-height: 200px;
object-fit: cover;
border-radius: 10px;
margin: 10px 0;
box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.timeline ul li:nth-of-type(odd) > div {
left: 45px;
transform: translate3d(100px, -10px, 0) rotate(10deg);
}

.timeline ul li:nth-of-type(even) > div {
left: -340px;
transform: translate3d(-100px, -10px, 0) rotate(10deg);
}

.timeline ul li.in-view > div {
transform: none;
visibility: visible;
opacity: 1;
}

@media screen and (max-width: 900px) {
.timeline ul li > div {
width: 250px;
}
.timeline ul li:nth-of-type(even) > div {
left: -289px;
}
}

@media screen and (max-width: 600px) {
  .timeline  {
  display:none ;
    }
.timeline ul li {
margin-left: 20px;
}
.timeline ul li > div {
width: calc(100vw - 91px);
}
.timeline ul li:nth-of-type(even) > div {
left: 45px;
}

.timeline ul li.in-view > div {
  transform: none;
  visibility: visible;
  opacity: 1;
}
}