.slider{
  width: 100%;
  height: auto;
  border-radius: 10px;
  overflow: hidden;
  position:relative;
}

.slides{
  width: 500%;
  height: 510px;
  display: flex;
}

.slides input{
  display: none;
}

.slide{
  width: 20%;
  transition: 2s;
}

.slide img{
  width: 100%;
  height: auto;
}

/*css for manual slide navigation*/

.navigation-manual{
  position: absolute;
  width: 800px;
  margin-top: -50px;
  display: flex;
  justify-content: center;
   margin-left: 40px;
}

.manual-btn{
  border: 2px solid #FFF;
  padding: 5px;
  border-radius: 10px;
  cursor: pointer;
  transition: 1s;
}

.manual-btn:not(:last-child){
  margin-right: 40px;
}

.manual-btn:hover{
  background: #FFF;
}

#radio1:checked ~ .first{
  margin-left: 0;
}

#radio2:checked ~ .first{
  margin-left: -20%;
}

#radio3:checked ~ .first{
  margin-left: -40%;
}

#radio4:checked ~ .first{
  margin-left: -60%;
}

/*css for automatic navigation*/

.navigation-auto{
  position: absolute;
  display: flex;
  width: 800px;
  justify-content: center;
  margin-top: 460px;
  margin-left: 40px;
}

.navigation-auto div{
  border: 2px solid #FFF;
  padding: 5px;
  border-radius: 10px;
  transition: 1s;
}

.navigation-auto div:not(:last-child){
  margin-right: 40px;
}

#radio1:checked ~ .navigation-auto .auto-btn1{
  background: #FFF;
}

#radio2:checked ~ .navigation-auto .auto-btn2{
  background: #FFF;
}

#radio3:checked ~ .navigation-auto .auto-btn3{
  background: #FFF;
}

#radio4:checked ~ .navigation-auto .auto-btn4{
  background: #FFF;
}

@media only screen and (max-width:320px) {
	.navigation-auto {width: auto; margin-top: 160px; margin-left: 65px;}
	.navigation-manual {width: auto; margin-top: 180px; margin-left: 80px;}
	.slides{height: auto;}
}

@media only screen and (max-width:400px) and (min-width:360px) {
	.navigation-auto {width: auto; margin-top: 180px; margin-left: 80px;}
	.navigation-manual {width: auto; margin-top: 180px; margin-left: 80px;}
	.slides{height: auto;}
}

@media only screen and (max-width:667px) and (min-width:400px) {
	.navigation-auto {width: auto; margin-top: 220px; margin-left: 100px;}
	.navigation-manual {width: auto; margin-top: 220px; margin-left: 100px;}
	.slides {height: auto;}
}