
.slider {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  flex-wrap: nowrap;
  width: 100%;
  height: 80vh;
  margin: 0 auto;
  padding: 0;
  overflow: hidden;
}
.slider li {
  position: relative;
  background: none no-repeat center/cover;
  min-height: 100%;
  overflow: hidden;
  flex-grow: 1;
  transition: 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.slider li:hover {
  flex-grow: 5;
}
.slider li:hover h1 {
  transform: rotateZ(0) translateY(0);bottom:3rem;
}
.slider li:hover p {
  transform: translateY(calc((100% + 2rem) * -1)) rotateZ(0);
}
.slider a {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  display: block;
  width: 100%;
  height: 100%;
  z-index: 1;
}
.slider h1 {
  position: absolute;
  white-space: nowrap;
  bottom:-2rem;
  left: 1rem;
  margin: 0;
  font-size: 32px;
  font-weight:500;
  color: white;
  text-transform: uppercase;
  transform-origin: left top;
  transform: rotateZ(-90deg) translateY(1em);
  transition: 1.5s cubic-bezier(0.35, 0, 0, 1);
  /*text-shadow: 0 0 10px rgba(0, 0, 0, 0.25);*/
  background: rgba(0, 0, 0, 0.1);
  border-radius: 3px;
  padding: 10px 15px;
  letter-spacing: 0px;
}
.slider p {
  position: absolute;
  top: 100%;
  right: 1rem;
  left: 1rem;
  padding: 1rem;
  transform-origin: left top;
  transform: translateY(0) rotateZ(90deg);
  transition: 1.5s cubic-bezier(0.35, 0, 0, 1);
  width: 25em;
  color: rgba(0, 0, 0, 0.65);
  background: rgba(255, 255, 255, 0.9);
  line-height: 1.5;
  border-radius: 0.25rem;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
}
.slider li{ box-shadow: 0 0 25px 10px rgba(0, 0, 0, 0.5);
    -webkit-box-shadow: 0 0 25px 10px rgba(0, 0, 0, 0.5);
    -moz-box-shadow: 0 0 25px 10px rgba(0, 0, 0, 0.5);position: relative;}

.slider li.one::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(163, 140, 112, 0.6); /* Change the color and opacity as needed */
  /* Other styles for the overlay */
}
.slider li.two::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(60, 78, 171, 0.6); /* Change the color and opacity as needed */
  /* Other styles for the overlay */
}
.slider li.three::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(225, 180, 84, 0.6); /* Change the color and opacity as needed */
  /* Other styles for the overlay */
}
.slider li.four::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(143, 147, 157, 0.6); /* Change the color and opacity as needed */
  /* Other styles for the overlay */
} 
.slider li.five::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(219, 142, 94, 0.6); /* Change the color and opacity as needed */
  /* Other styles for the overlay */
}    

.slider li.one::after {
  background-color: rgba(163, 140, 112, 0.6);
}
.slider li.one:hover::after{
  background-color: rgba(163, 140, 112, 0.0);
}

.slider li.two::after {
  background-color: rgba(60, 78, 171, 0.6);
}
.slider li.two:hover::after{
  background-color: rgba(60, 78, 171, 0.0);
}


.slider li.three::after {
  background-color: rgba(225, 180, 84, 0.6);
}
.slider li.three:hover::after{
  background-color: rgba(225, 180, 84, 0.0);
}


.slider li.four::after {
  background-color: rgba(143, 147, 157, 0.6);
}
.slider li.four:hover::after{
  background-color: rgba(143, 147, 157, 0.0);
}

.slider li.five::after {
  background-color: rgba(219, 142, 94, 0.6);
}
.slider li.five:hover::after{
  background-color: rgba(219, 142, 94, 0.0);
}


.slider .one {
  background:url(../images/01.jpg);
  background-size: cover;background-position: center center;
}
.slider .two {
  background:url(../images/02.jpg);
  background-size: cover;background-position: center center;    
}
.slider .three {
  background: url(../images/03.jpg);
  background-size: cover;background-position: center center;   
}
.slider .four {
  background:url(../images/04.jpg);
  background-size: cover;background-position: center center;   
}
.slider .five {
 background:url(../images/05.jpg);
  background-size: cover;background-position: center center;   
}
.slider li.active {
  flex-grow: 5;
}
.slider li.active::after{background-color:rgba(219, 142, 94, 0.0)!important;transition: background-color 0.3s ease;}
.slider li.active h1 {
  transform: rotateZ(0) translateY(0);bottom:4rem;background: rgba(0, 0, 0, 0.1);
}

.slider li.active p {
  transform: translateY(calc((100% + 2rem) * -1)) rotateZ(0);
}