/* 0. Box-sizing universale */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* 1. Layout base */
html, body {
  height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  font-family: sans-serif;
  text-align: center;
  line-height: 1.5;
}

/* 2. Header con logo e titolo affiancati */
header {
  background: #119647;
  color: #fff;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

/* Logo tondo responsivo */
.logo {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid white;
}

/* Riduzione logo e titolo su schermi molto piccoli */
@media (max-width: 400px) {
  .logo {
    width: 40px;
    height: 40px;
  }
  header h1 {
    font-size: 1.2em;
  }
}

/* 3. Banner Eventi */
.eventi-banner {
  position: relative;
  background-color: #beffcc;
  color: #000;
  margin: 1.5em 0;
  padding: 1.5em 1em;
  border-top: 6px solid #0f541e;
  border-bottom: 6px solid #0f541e;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}
.eventi-banner p {
  margin: 0.5em 0;
  font-size: 1.6em;
  font-weight: bold;
  line-height: 1.2;
}
@media (max-width: 480px) {
  .eventi-banner {
    padding: 1em 0.5em;
  }
  .eventi-banner p {
    font-size: 1.3em;
  }
}

/* 4. Main content */
main {
  flex: 1;
  padding: 20px;
}

/* 5. Contatti (elenco puntato senza pallini) */
.contatti {
  list-style: none;
  margin: 1em 0;
}
.contatti li {
  margin: 0.5em 0;
}

/* 6. CTA (scarica app) */
.cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 0em 0;
}
.cta h2 {
  width: 100%;
  margin-bottom: 0.5em;
}
.cta span {
  display: block;
  width: 100%;
  white-space: normal;
}
.btn {
  display: inline-block;
  flex: 1 1 auto;
  max-width: 140px;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 5px;
  background: #0e8a44;
  color: #fff;
  transition: background 0.2s ease;
}
.btn:hover {
  background: #0c7c3c;
}

/* 7. Sezione Webcam in diretta */
.webcam {
  margin: 2em 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1em;
}
.webcam h2 {
  width: 100%;
  margin-bottom: 0.5em;
}
.webcam-image {
  width: 100%;
  max-width: 800px;
  height: auto;
  display: block;
}

/* 8. Footer sempre in basso e verde scuro */
footer {
  background: #0a5e33;
  padding: 10px;
  font-size: 0.9em;
  color: #fff;
}
