body {
  font-family: 'Inter', sans-serif;
  background-color: #f4f4f4;
  margin: 0;
  padding: 0;
  color: #222;
  overflow-y: auto; /* <-- aggiunto */
}

header {
  background-color: #001f3f;
  color: white;
  padding: 1rem;
  text-align: center;
  position: relative; /* <-- AGGIUNGI */
  z-index: 2;         /* <-- AGGIUNGI */
}


header img {
  height: 50px;
  margin-bottom: 0.5rem;
}

main {
  padding: 2rem;
}

.filtro-leghe {
  margin-bottom: 2rem;
  text-align: center;
}

.filtro-leghe select {
  padding: 0.5rem 1rem;
  font-size: 1rem;
  border-radius: 5px;
  border: 1px solid #ccc;
}

.lega {
  background-color: #ffffff;
  border-radius: 10px;
  padding: 1.5rem;
  margin-bottom: 3rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.lega h2 {
  text-align: center;
  color: #003366;
  margin-bottom: 1.5rem;
}

.squadre {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.squadra {
  background-color: #e6ecf0;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.squadra:hover {
  transform: translateY(-5px);
}

footer {
  background-color: #001f3f;
  color: white;
  text-align: center;
  padding: 1rem;
  font-size: 0.9rem;
}

/* Menu di navigazione */
nav {
  margin-top: 1rem;
  text-align: center;
}

nav a {
  display: inline-block;
  margin: 0 1rem;
  padding: 0.5rem 1rem;
  color: white;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: background-color 0.3s ease;
  background-color: #003366;
}

nav a:hover {
  background-color: #0050aa;
  color: #fff;
}
/* Forza deploy Netlify */
/* Loghi squadre - dimensioni uniformi */
.squadra img {
  max-width: 100px;
  max-height: 100px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto 1rem;
}

/* Centra tutto nel box squadra */
.squadra {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.squadra {
  display: flex;
  flex-direction: column;
  align-items: center;       /* centra verticalmente e orizzontalmente */
  justify-content: flex-start;
}

.squadra img {
  max-width: 100px;
  max-height: 100px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto 0.5rem;
}
.squadra {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  height: 200px;
}

.squadra img {
  max-width: 80px;
  max-height: 80px;
  object-fit: contain;
  margin-bottom: 0.5rem;
}
/* Colori di sfondo diversi per ogni lega */
.lega.inglese   { background-color: #e8f0ff; }
.lega.italiana  { background-color: #fff4e6; }
.lega.spagnola  { background-color: #f2f0ff; }
.lega.tedesca   { background-color: #e6fff2; }
.lega.francese  { background-color: #fff0f5; }
.lega.serieb    { background-color: #f0f0f0; }
.inglese .squadra { border: 2px solid #0044cc; }
.italiana .squadra { border: 2px solid #009246; }
.spagnola .squadra { border: 2px solid #c60b1e; }
.tedesca .squadra { border: 2px solid #000000; }
.francese .squadra { border: 2px solid #0055a4; }
.serieb .squadra { border: 2px solid #999999; }
.squadra img:hover {
  transform: scale(1.1);
  transition: transform 0.2s ease-in-out;
}
.lega.inglese {
  background: url('../images/sfondi/inglese.png') center/cover no-repeat;
}
.lega.italiana {
  background: url('../images/sfondi/italiana.png') center/cover no-repeat;
}
.lega.spagnola {
  background: url('../images/sfondi/spagnola.png') center/cover no-repeat;
}
.lega.tedesca {
  background: url('../images/sfondi/tedesca.png') center/cover no-repeat;
}
.lega.francese {
  background: url('../images/sfondi/francese.png') center/cover no-repeat;
}
.lega.serieb {
  background: url('../images/sfondi/serieb.png') center/cover no-repeat;
}
.tabella-container {
  padding: 2rem;
  overflow-x: auto;
}

.tabella-rosa {
  width: 100%;
  border-collapse: collapse;
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.1);
}

.tabella-rosa th,
.tabella-rosa td {
  border: 1px solid #ddd;
  padding: 0.6rem;
  text-align: center;
  font-size: 0.95rem;
}

.tabella-rosa thead {
  background-color: #001f3f;
  color: white;
}

.tabella-rosa tbody tr:nth-child(even) {
  background-color: #f2f2f2;
}
/* Hero section ispirata allo stadio */
.hero {
  background-image: url("images/bg-stadio.jpg");
  background-size: contain; /* Mostra tutto lo sfondo */
  background-repeat: no-repeat;
  background-position: center top;
 height: 90vh; /* Lascia spazio per header/footer */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 0; /* aggiunto */
}

.hero-overlay {
  position: relative;
  text-align: center;
  color: white;
  background-color: rgba(0, 0, 0, 0.4);
  padding: 40px;
  border-radius: 12px;
  z-index: 1; /* <-- AGGIUNGI */
}

.hero-overlay h1 {
  font-size: 3rem;
  letter-spacing: 2px;
  margin-bottom: 10px;
}

.hero-overlay p {
  font-size: 1.2rem;
  opacity: 0.9;
}

.hero-overlay .intro {
  font-size: 1.5rem;
  margin-top: 30px;
  color: white;
  text-shadow: 1px 1px 4px black;
}

.hero-overlay .intro-text {
  font-size: 1rem;
  max-width: 600px;
  margin: 0 auto;
  color: white;
  text-shadow: 1px 1px 3px black;
}
.intro-section {
  background: linear-gradient(to bottom, #001933, #002244);
  color: white;
  text-align: center;
  padding: 60px 20px;
  font-family: 'Inter', sans-serif;
}

.intro-section h2 {
  font-size: 2rem;
  margin-bottom: 20px;
  text-shadow: 1px 1px 2px black;
}

.intro-section p {
  font-size: 1.1rem;
  max-width: 700px;
  margin: 0 auto;
  text-shadow: 1px 1px 2px black;
}
.classifica {
  margin: 2rem auto;
  width: 95%;
  max-width: 1000px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 15px rgba(0,0,0,0.1);
  font-family: 'Inter', sans-serif;
}

.classifica h2 {
  text-align: center;
  background-color: #001f3f;
  color: white;
  padding: 1rem;
  font-size: 1.5rem;
}

.tabella-classifica {
  width: 100%;
  border-collapse: collapse;
}

.tabella-classifica th,
.tabella-classifica td {
  padding: 0.8rem;
  text-align: center;
  border: 1px solid #ccc;
  font-size: 0.95rem;
}

.tabella-classifica th {
  background-color: #f8f8f8;
  color: #333;
}

.tabella-classifica tr:nth-child(even) {
  background-color: #f2f2f2;
}

/* Colori per lega */
.classifica.inglese h2 {
  background: linear-gradient(90deg, #d00027, #034694);
}
.classifica.italiana h2 {
  background: linear-gradient(90deg, #0074b7, #831c1c);
}
.classifica.spagnola h2 {
  background: linear-gradient(90deg, #a50044, #febd11);
}
.classifica.tedesca h2 {
  background: linear-gradient(90deg, #dc052d, #fce100);
}
.classifica.francese h2 {
  background: linear-gradient(90deg, #004170, #e30613);
}
.classifica.serieb h2 {
  background: linear-gradient(90deg, #fce600, #2945a0);
}
.giornata-blocco {
  background: #f5f5f5;
  padding: 15px;
  margin: 10px auto;
  border-radius: 10px;
  width: 90%;
  box-shadow: 0 0 5px rgba(0,0,0,0.1);
}
.giornata-blocco h3 {
  margin-top: 0;
  color: #003366;
}
