* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}
.container {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #161616;
}
.slider {
  position: absolute;
  inset: 10px 50px 10px 10px;
  background: #222;
  border-radius: 20px;
}
.slider .slides {
  position: absolute;
  top: 60%;
  transform: translateY(-50%);
  width: 200px;
  height: 280px;
  background: var(--img);
  background-position: center;
  background-size: cover;
  transition: 0.5s;
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: flex-start;
  align-items: flex-end;
}
.slides:nth-child(1),
.slides:nth-child(2) {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: translateY(0);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0);
}
.slides:nth-child(3) {
  left: calc(50% + 260px);
  background-size: cover;
}
.slides:nth-child(4) {
  left: calc(50% + 480px);
  background-size: cover;
}
.slides:nth-child(5) {
  left: calc(50% + 700px);
  background-size: cover;
}
.slides:nth-child(6) {
  left: calc(50% + 1000px);
  background-size: cover;
}
.buttons {
  position: absolute;
  bottom: 15px;
  display: flex;
  gap: 20px;
}
.buttons span {
  position: relative;
  width: 50px;
  height: 50px;
  background: #000;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}
.buttons span::before {
  content: "";
  position: absolute;
  width: 15px;
  height: 15px;
  border-top: 4px solid #fff;
  border-right: 4px solid #fff;
  transform: rotate(225deg) translate(-4px, 4px);
}
.buttons span:nth-child(2)::before {
  transform: rotate(-315deg) translate(-4px, 4px);
}
.buttons span:active {
  opacity: 0.5;
}
.content {
  position: relative;
  padding: 40px;
  margin-bottom: 50px;
  max-width: 600px;
  transition: 0.5s;
  transition-delay: 0;
  z-index: 100;
  opacity: 0;
  color: #fff;
}
.slides:nth-child(1) .content,
.slides:nth-child(2) .content {
  opacity: 1;
  transition-delay: 0.5s;
}
h2 {
  font-size: 60px;
  font-weight: 600;
}
p {
  font-size: 18px;
}

@media (max-width: 900px) {
  .slider {
    position: absolute;
    inset: 40px 40px 200px 40px;
  }
  .slider .slides {
    width: 100px;
    height: 100px;
    top: initial;
    bottom: -170px;
  }
  .slider .slides:nth-child(1),
  .slider .slides:nth-child(2) {
    top: initial;
    bottom: 0;
    width: 100%;
    height: 100%;
  }
  .slider .slides:nth-child(3) {
    left: 0;
  }
  .slider .slides:nth-child(4) {
    left: 120px;
  }
  .slider .slides:nth-child(5) {
    left: 240px;
  }
  .content {
    margin-bottom: 20px;
    max-width: 400px;
  }
  h2 {
    font-size: 30px;
  }
  p {
    font-size: 14px;
  }
}
