/*Reglage généraux*/
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
  list-style: none;
}

body {
  display: grid;
  width: 100%;
}

/*Style pour le tableau*/
table {
  border-collapse: collapse;
  table-layout: auto;
  width: 100%;
}

th,
td {
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
  border: 1px solid #dee2e6;
  padding: 8px;
  color: #212529;
}

th {
  background-color: #343a40;
  border-color: #454d55;
  color: white;
  font-weight: bold;
  text-align: inherit;
}

td {
  padding: .75rem;
  vertical-align: middle;
}

td a.images {
  margin: 0;
  padding: 0;
}

tr:nth-child(even) {
  background-color: rgba(0, 0, 0, .05);
}

/*Bouton et alignement*/

.menu-link {
  position: relative;
  display: block;
  width: 400px;
  height: 250px;
  overflow: hidden;
  text-decoration: none;
  color: black;
  font-weight: bold;
  text-align: center;
  margin: 10px;
}

.listButton {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.top-row {
  display: flex;
  justify-content: center;
}

.bottom-row {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.menu-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter 0.3s ease;
  filter: blur(5px);
}

.menu-link:hover .menu-image {
  filter: blur(0);
}

.menu-link span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(255, 255, 255, 0.8);
  padding: 5px 10px;
  border-radius: 5px;
}

.logout {
  display: flex;
  justify-content: center;
  color: black;
  gap: 10px;
}

.logged_out_message {
  text-align: center;
}

/*Navigation et menu burger*/
nav.navTableau {
  background-color: rgba(0, 0, 0, .05);
  display: flex;
  align-items: center;
  position: relative;
}

.menu-burger {
  display: inline-block;
  position: relative;
  /* Pour ancrer le menu par rapport au nav */
}

button.burger-button {
  background-color: transparent;
  color: black;
  height: 100%;
  border: none;
  cursor: pointer;
  border-radius: 0;
  padding: 20px;
  font-size: 25px;
  /* Taille de l'icône */
}

.burger-content {
  display: none;
  position: absolute;
  left: 0;
  z-index: 1;
  /* Pour s'assurer qu'il s'affiche sous le nav */
  background-color: white;
  border: 1px solid #ddd;
  box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
  padding: 12px;
  /* Pour l'espace intérieur */
}

.burger-content form {
  margin-bottom: 10px;
  /* Espace entre les formulaires */
}

/* Ajouter le bouton Réinitialiser tous les filtres dans le menu déroulant */
.burger-content .resetFilter {
  margin: 10px 0;
  background-color: black;
  color: white;
  text-decoration: none;
  text-align: center;
  padding: 10px 20px;
  border-radius: 10px;
}

/*Formulaire et filtres*/
form.combined-filters {
  margin: 0;
}

/*Bouton telechargerExcel*/
.excelDownload {
  background-color: black;
  color: white;
  text-decoration: none;
  text-align: center;
  padding: 10px 20px;
  margin: 0px 10px 0px 10px;
  border-radius: 10px;
}


/*Derniere maj dans le nav*/
.lastMaj {
  margin-right: 10px;
}

/*Bouton retour vers le menu*/
a.tableauToHome {
  background-color: black;
  color: white;
  text-decoration: none;
  text-align: center;
  padding: 10px 20px;
  margin: 0px 10px 0px;
  border-radius: 10px;
}

/*Formulaire de recherche*/
.searchForm {
  display: flex;
  /* Utiliser un modèle de boîte flexible pour aligner les éléments */
  align-items: center;
  /* Aligner les éléments verticalement */
  margin: 0px;
  background-color: transparent;
}

.searchForm .barreRecherche {
  display: flex;
  flex-direction: column;
}

.searchForm .resetButton {
  display: flex;
  align-items: center;
}

.searchForm img {
  margin-left: 10px;
}

.searchForm input[type="text"] {
  margin-bottom: 0px;
  /* Ajouter une marge à droite pour l'espace entre le bouton de recherche et l'image de réinitialisation */
}

.searchForm button[type="submit"] {
  font-size: 16px;
  margin-right: 10px;
  margin-left: 10px;
  /* Ajouter une marge à droite pour l'espace entre le bouton de recherche et l'image de réinitialisation */
}

.searchForm img {
  cursor: pointer;
  /* Définir le curseur sur pointer pour indiquer que l'image est cliquable */
}

a.resetButton {
  margin: 2.5px 0px 0px 0px;
}

.vertical-separator {
  margin-top: 10px;
}

/*Formulaire de filtrage par date*/
.filter-date {
  display: flex;
  align-items: center;
  margin: 0px;
  background-color: transparent;
}

.filter-date .resetDate {
  margin: 0px 0px 0px 10px;
  margin-top: auto;
}

.filter-date .dates {
  display: flex;
  flex-direction: column;
  margin-top: 10px;
}

.filter-date .dates input {
  margin: 0;
}

/*Bouton reset de tout les filtres*/
.resetFilter {
  margin: 0;
  background-color: black;
  color: white;
  text-decoration: none;
  text-align: center;
  padding: 10px 20px;
  border-radius: 10px;
}

/*bouton d'execution des filtres*/
.submit-button {
  margin-top: 10px;
}

.submit-button button {
  font-size: 16px;
}

/*Bouton de création d'une ligne dans le tableau*/
a.createInter {
  margin: 3.5px 10px 10px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  font-weight: bold;
}

/*Gestion du style pour le chercheur de dragon*/
/*style du form*/
.search-form-drag {
  margin: 0 auto;
  width: auto;
  display: flex;
  align-items: center;
  justify-content: space-evenly;
}

.search-form-drag>.search-block {
  margin-bottom: 0;
  margin-right: 10px;
}

.recherche-drag-div {
  margin: 0 auto;
  width: 50%;
}

a.resetButtonDrag {
  border: none;
  margin: 0;
  cursor: pointer;
  text-align: center;
  display: flex;
  justify-content: center;
}

.suggestion-drag {
  margin-left: 10px;
}

.resultat-drag {
  margin: 0 auto;
}

.dragToHome {
  margin: 0 auto;
  background-color: black;
  color: white;
  text-decoration: none;
  padding: 10px 20px;
  margin-top: 10px;
  margin-bottom: 10px;
  border-radius: 10px;
}


/*Gestion général des formulaire django*/
form {
  padding: 10px 10px 10px 10px;
  margin: 0 auto;
  width: 400px;
  row-gap: 10px;
  background-color: rgba(0, 0, 0, .05);
  border-radius: 10px;
  align-items: center;
}

form label {
  display: block;
  margin-bottom: 10px;
}

form input[type="text"],
form input[type="date"],
form input[type="password"],
form input[type="email"],
form textarea {
  width: 100%;
  padding: 10px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

form input[type="submit"] {
  background-color: black;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 10px;
  margin: 0 auto;
  cursor: pointer;
  display: block;
  text-align: center;
}

form input[type="submit"]:hover {
  background-color: rgb(65, 65, 65);
}

/*elements divers*/
a {
  color: black;
  width: fit-content;
  margin-bottom: 10px;
  text-align: center;
}

.linkMiddle {
  margin: 0 auto;
}

button {
  background-color: black;
  color: white;
  padding: 10px 20px;
  border-radius: 10px;
  border: 0;
}

button:hover {
  background-color: rgb(65, 65, 65);
}

.whoami{
  margin-top: 10px;
  text-align: center;
}

h1 {
  margin: 0 auto;
  text-align: center;
  font-size: 40px;
}

h2 {
  display: flex;
  justify-content: center;
  margin-bottom: 40px;
  font-size: 40px;
  width: 100%;
}

.error {
  color: red;
  /* Choisissez une couleur vive pour indiquer une erreur */
  font-weight: bold;
  margin-bottom: 10px;
}

select#id_treuillage {
  margin-bottom: 20px;
  width: 20%;
}

select#id_dept {
  margin-bottom: 20px;
  width: auto;
}

@media screen and (max-width: 1250px) {
  .menu-link {
    width: 300px;
    height: 200px;
  }

  h1 {
    font-size: 35px;
  }

  h2 {
    font-size: 35px;
  }
}

@media screen and (max-width: 950px) {
  .top-row {
    flex-direction: column;
    align-items: center;
  }

  h1 {
    font-size: 25px;
  }

  h2 {
    font-size: 20px;
  }
}

@media screen and (max-width: 575px) {
  h1 {
    font-size: 20px;
  }

  h2 {
    font-size: 15px;
  }
}
