/* Supprime tout défilement et assure que l'image couvre l'écran */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  font-family: 'Work Sans', sans-serif;
}

/* Applique l’image de fond */
body {
  position: relative;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: white;
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
}

.overlay {
  position: fixed; /* ← fixe à l'écran */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.25); /* filtre noir semi-transparent */
  z-index: 1;
  pointer-events: none; /* ← pour que ça ne bloque pas les clics sur le contenu */
}

/* Fond noir semi-transparent uniquement sur l'image */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0);
  pointer-events: none;
  z-index: 0;
}

/* Dashboard */
.dashboard {
  flex: 1; /* Prend tout l’espace restant */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  box-sizing: border-box;
  z-index: 1;
}

/* Titre */
.dashboard h1 {
  margin-top: 1rem;
  margin-bottom: 5rem;
  color: white;
  margin-bottom: 50px;
  font-size: 7.5rem;
  font-weight: 300;
  text-align: center;
}

/* Tuiles */
.tiles {
  display: grid;
  background: rgba(20, 20, 20, 0.75);
  backdrop-filter: blur(4px);
  padding: 1.5rem;
  border-radius: 1rem;
  gap: 1.5rem;
  width: 100%;
  max-width: 650px;
  box-sizing: border-box;
  grid-template-columns: repeat(3, 1fr); /* Valeur par défaut */
}

/* Tuile individuelle */
.tile {
  background: rgba(125, 125, 125, 0.25);
  backdrop-filter: blur(0px);
  color: white;
  border-radius: 15px;
  aspect-ratio: 3 / 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  text-decoration: none;
  font-size: 1.1rem;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease, background 0.3s;
  padding: 10px;
  min-width: 0;
  min-height: 0;
}

.tile i {
  font-size: 2rem;
  margin-bottom: 10px;
  display: block;
}

.tile:hover {
  transform: translateY(-5px);
  background: white;
  color: rgba(20, 20, 20, 0.75);
}

/* Footer */
.footer {
  text-align: center;
  color: #bbb;
  font-size: 0.9rem;
  z-index: 10;
  padding: 10px;
}

/* Responsive : 2 colonnes */
/* Responsive : 2 colonnes */
@media (max-width: 700px) {
  .tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 400px;
    padding: 1.5rem;
    border-radius: 1rem;
    gap: 1.5rem;
    margin: 0 auto; /* Centrage horizontal */
  }

  .tile {
    aspect-ratio: auto; /* Désactive le ratio */
    height: 140px;       /* Hauteur fixe */
    font-size: 1rem;
    padding: 10px;
  }

  .dashboard h1 {
    font-size: 4rem;
    margin-bottom: 25px;
    margin-top: 1rem;
  }

  .dashboard {
    padding: 1rem;
  }
}

/* Responsive : 1 colonne */
@media (max-width: 450px) {
  .tiles {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }

  .tile {
    aspect-ratio: auto; /* Permet à la tuile de s’adapter naturellement */
    height: auto;
    padding: 12px;
  }

  .dashboard h1 {
    font-size: 3rem;
    margin-top: 1rem;
    margin-bottom: 25px;
  }
}