/*--- header ---*/
header{
  width: 1400px;
  max-width: 100%;
  margin: auto;
  height: 50px;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 100;
}
/* --- Navigation --- */
nav{
  width: 100%;
  background-color: #4e4a4a98;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}
.links-container{
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;
}
nav a{
  font-weight: 300;
  height: 100%;
  padding: 0 20px;
  display: flex;
  align-items: center;
  text-decoration: none;
  color: blue;

}
nav a:hover{
  background-color: var(--accent-color);
}
nav .home-link{
  font-weight: 300;
  margin-right: auto;
  color: blue;
}
nav svg{
  fill: var(--text-color);
}
#sidebar-active{
  display: none;
}
.open-sidebar-button, .close-sidebar-button{
  display: none;
}
/* --- Navigation --- */
/* --- carousel --- */
.carousel{
  height: 100vh;
  margin-top: -50px;
  width: 100vw;
  overflow: hidden;
  position: relative;
}
.carousel .list .item{
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0 0 0 0;
}
.carousel .titel{
  position: relative;
  top: 7%;
  left: 5%;
  width: 80%;
  color: #dbdcee;
  background-color: rgba(12, 20, 18, 0.238);
  z-index: 600;
}
.carousel .list .item img{
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.carousel .list .item .content{
  position: absolute;
  top: 20%;
  width: 1140px;
  max-width: 80%;
  left: 50%;
  transform: translateX(-50%);
  padding-right: 30%;
  box-sizing: border-box;
  color: #fff;
  text-shadow: 0 5px 10px #0004;
}
.carousel .list .item .bildzahl{
  position: absolute;
  top: 50px;
  font-weight: 200;
  font-size: 1em;
}
.thumbnail{
  position: absolute;
  bottom: 50px;
  left: 50%;
  width: max-content;
  z-index: 100;
  display: flex;
  gap: 20px;
}
.thumbnail .item{
  position: relative;
  width: 150px;
  height: 220px;
  flex-shrink: 0;  
}
.thumbnail .item img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
}
.thumbnail .item .content{
  color: #fff;
  position: absolute;
  bottom: 10px;
  left: 10px;
  right: 10px;  
}
.thumbnail .item .content .title{
  font-weight: 300;
}

/* -- arrows -- */
.arrows{
  position: absolute;
  top: 80%;
  right: 52%;
  z-index: 100;
  width: 300px;
  max-width: 30%;
  display: flex;
  gap: 10px;
  align-items: center;
}
.arrows button{
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #eee4;
  border: none;
  font-family: monospace;
  color: #fff;
  font-weight: bold;
  transition: .5s;
}
.arrows button:hover{
  background-color: #fff;
  color: #000;
}

/*-- animation --*/
.carousel .list .item:nth-child(1){
  z-index: 1;
}
/*-- animation text --*/
.carousel .list .item:nth-child(1) .bildzahl{
  transform: translateY(50px);
  filter: blur(20px);
  opacity: 0;
  animation: showContent .5s 1s linear 1 forwards;
}
@keyframes showContent{
  to{
    transform: translateY(0px);
    filter: blur(0px);
    opacity: 1;
  }
}
.carousel .list .item:nth-child(1) .content .bildzahl{
  animation-delay: 1.2s!important;
}

.carousel.next .list .item:nth-child(1) img{
  width: 150px;
  height: 220px;
  position: absolute;
  left: 50%;
  bottom: 50px;
  border-radius: 10px;
  animation: showImage .5s linear 1 forwards;
}
@keyframes showImage{
  to{
    left: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    border-radius: 0;
  }
}
.carousel.next .thumbnail .item:nth-last-child(1){
  overflow: hidden;
  animation: showThumbnail .5s linear 1 forwards;
}
.carousel.prev .list .item img{
  z-index: 100;
}

@keyframes showThumbnail{
  from{
    width: 0;
    opacity: 0;
  }
}
.carousel.next .thumbnail{
  animation: effectNext .5s linear 1 forwards;
}

@keyframes effectNext{
  from{
    transform: translateX(150px);
  }
}
/* running time */
.carousel .time{
  position: absolute;
  z-index: 1000;
  width: 0%;
  height: 3px;
  background-color: #f1683a;
  left: 0;
  top: 0;
}

.carousel.next .time
.carousel.prev .time{
  animation: runningTime 3s linear 1 forwards;
}
@keyframes runningTime{
  from{ width: 100%;}
  to{width: 0;}
}

/* prev click */
.carousel.prev .list .item:nth-child(2){
  z-index: 2;
}
.carousel.prev .list .item:nth-child(2) img{
  animation: outFrame 0.5s linear 1 forwards;
  position: absolute;
  bottom: 0;
  left: 0;  
}

@keyframes outFrame{
  to{
    width: 150px;
    height: 220px;
    bottom: 50px;
    left: 50%;
    border-radius: 10px;    
  }
}

.carousel.prev .thumbnail .item:nth-child(1){
  overflow: hidden;
  opacity: 0;
  animation: showThumbnail .5s linear 1 forwards;
}
.carousel.next .arrows button,
.carousel.prev .arrows button{
  pointer-events: none;
}
.carousel.prev .list .item:nth-child(2) .bildzahl{
  animation: contentOut 1.5s linear 1 forwards!important;
}

@keyframes contentOut{
  to{
    transform: translateY(-150px);    
    filter: blur(20px);
    opacity: 0;
  }
}

/* --- Breakpoints --- */
@media screen and (max-width: 678px){
  .carousel .list .item .content{
    padding-right: 0;
  }
  .carousel .list .item .content .bildzahl{
    font-size: 20px;
  }

  .links-container{
    flex-direction: column;
    align-items: flex-start;

    position: fixed;
    top: 0;
    right: -100%;
    z-index: 10;
    width: 300px;

    font-weight: 400;

    background-color: rgba(161, 184, 226, 0.571);
    box-shadow: -5px 0 5px rgba(0, 0, 0, 0.25);
    transition: 0.75s ease-out;
  }
  nav a{
    box-sizing: border-box;
    height: auto;
    width: 100%;
    padding: 20px 30px;
    justify-content: flex-start;
  }
  .open-sidebar-button, .close-sidebar-button{
    padding: 20px;
    display: block;
  }
  #sidebar-active:checked ~ .links-container{
    right: 0;
  }

  #sidebar-active:checked ~ #overlay{
    height: 100%;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9;
  }
  .container{
    top: 40px;
    width: 100vw;
    height: 40vh;
  }

}

