* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Cormorant Garamond', serif;
}

.slider {
  position: relative;
  height: 100vh;
  overflow: hidden;

  /* fallback neutro */
  background: #777;
}

/* fallback immagine iniziale sul contenitore (NON interferisce con le slide) */
.slider.has-bg {
  background-image: url("images/img1.jpg");
  background-size: cover;
  background-position: center;
}

.slides {
  position: absolute;
  inset: 0;
}

.slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;

  opacity: 0;
  transform: scale(1);
  pointer-events: none;

  transition: opacity 1.4s ease-in-out, transform 6s ease-in-out;
  will-change: opacity, transform;
}

/* SOLO la slide attiva è visibile */
.slide.is-active {
  opacity: 1;
  transform: scale(1.05);
}

/* overlay */
.overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.25), rgba(0,0,0,0.65));
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  z-index: 2;
}

.overlay h1 {
  font-size: 5rem;
  letter-spacing: 6px;
  font-weight: 400;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.5s ease forwards;
  animation-delay: 0.5s;
}

.overlay p {
  margin-top: 10px;
  font-size: 1.2rem;
  font-family: Arial, sans-serif;
  letter-spacing: 1px;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.5s ease forwards;
  animation-delay: 1.2s;
}

.icons {
  margin-top: 30px;
}

.icons a {
  color: white;
  font-size: 1.5rem;
  margin: 0 15px;
  transition: opacity 0.3s;
}

.icons a:hover {
  opacity: 0.7;
}

@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

/* Responsive */
@media (max-width: 768px) {
  .overlay h1 { font-size: 3rem; letter-spacing: 3px; }
  .overlay p { font-size: 1rem; }
}
@media (max-width: 480px) {
  .overlay h1 { font-size: 2.2rem; letter-spacing: 2px; }
  .overlay p { font-size: 0.9rem; }
  .icons a { font-size: 1.2rem; margin: 0 10px; }
}
