/* RESET BASE */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #333;
  background: #f8f8f8;
}

/* HEADER */
header {
  background: url('tuo-hero.jpg') center/cover no-repeat;
  height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  text-shadow: 0 0 5px rgba(0,0,0,0.7);
}
header h1 {
  font-size: 3em;
  margin: 0;
}

/* NAVBAR */
nav {
  background: #222;
  padding: 10px;
  text-align: center;
}
nav a {
  color: white;
  margin: 0 15px;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}
nav a:hover {
  color: #ffcc00;
}

/* SEZIONI */
section {
  padding: 40px 20px;
  max-width: 1000px;
  margin: auto;
}
section h2 {
  margin-bottom: 15px;
  font-size: 2em;
  border-bottom: 2px solid #ddd;
  display: inline-block;
  padding-bottom: 5px;
}

/* GALLERIA - THUMBNAILS */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}
.gallery img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}
.gallery img:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* FOOTER */
footer {
  background: #222;
  color: white;
  text-align: center;
  padding: 20px;
  margin-top: 40px;
}

/* LIGHTBOX */
.lightbox {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: rgba(0,0,0,0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: 1000;
}
.lightbox.active {
  opacity: 1;
  visibility: visible;
}
.lightbox img {
  max-width: 80%;
  max-height: 80%;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.6);
}
.lightbox button {
  position: absolute;
  background: rgba(255,255,255,0.7);
  border: none;
  font-size: 2rem;
  cursor: pointer;
  padding: 10px 15px;
  border-radius: 50%;
  transition: background 0.3s;
}
.lightbox button:hover {
  background: white;
}
.lightbox .prev { left: 5%; top: 50%; transform: translateY(-50%); }
.lightbox .next { right: 5%; top: 50%; transform: translateY(-50%); }
.lightbox .close {
  top: 5%; right: 5%;
  font-size: 1.5rem;
  background: rgba(255,0,0,0.8);
  color: white;
}
