* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
}

.slider {
  position: relative;
  width: 100%;
  height: 80vh;
  min-height: 400px;
  overflow: hidden;
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease;
}

.slide.active {
  opacity: 1;
  z-index: 1;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slide.active img {
  animation: zoom 7s linear forwards;
}

@keyframes zoom {
  from { transform: scale(1); }
  to   { transform: scale(1.15); }
}

/* TEXT */
.caption {
  position: absolute;
  top: 50%;
  left: 10%;
  transform: translateY(-50%);
  color:  #C9A14A;
  z-index: 2;
}

.caption h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  opacity: 0;
  transform: translateY(40px);
}

.caption p {
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  margin-top: 10px;
  opacity: 0;
  transform: translateY(40px);
}

.slide.active .caption h1 {
  animation: textIn 1s ease forwards;
}

.slide.active .caption p {
  animation: textIn 1s ease forwards;
  animation-delay: 0.4s;
}

@keyframes textIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* NAV BUTTONS */
.nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.6);
  color: white;
  border: none;
  font-size: 2rem;
  padding: 8px 14px;
  cursor: pointer;
  z-index: 3;
}

.prev { left: 15px; }
.next { right: 15px; }

@media (max-width: 768px) {
  .caption {
    left: 5%;
    right: 5%;
    text-align: center;
  }
}

