/* ======================
   Styles globaux (communs à toutes les pages)
   ====================== */
body {
  background-color: black;
  color: white;
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
}

/* Favicon */
link[rel="icon"] {
  display: none;
}

/* ======================
   Styles pour index.php
   ====================== */
table {
  width: 50%;
  border-collapse: collapse;
  margin: 20px auto;
}

th, td {
  border: 1px solid white;
  padding: 0px;
  text-align: left;
  color: white;
}

th {
  background-color: #888;
  padding: 8px;
}

td.titre {
  padding: 8px;
  font-weight: bold;
}

td a {
  text-decoration: none;
  color: white;
  display: block;
  width: 100%;
  height: 100%;
  padding: 8px;
  box-sizing: border-box;
}

td a:hover {
  color: black;
  background-color: white;
}

a.pasCetteAnnee {
  pointer-events: none;
  text-decoration: line-through;
}

td.vide {
  border: none;
}

/* Bouton de connexion/édition en bas à gauche */
.auth-button-container {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 100;
}

.auth-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background-color: #4CAF50;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: bold;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  transition: background-color 0.3s, transform 0.2s;
}

.auth-button:hover {
  background-color: #45a049;
  transform: translateY(-2px);
}

.auth-button i {
  font-size: 16px;
}

/* ======================
   Styles pour edit.php
   ====================== */
.edit-container {
  max-width: 1200px;
  margin: 0 auto;
  background-color: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  color: black;
}

.edit-container h1,
.edit-container h2,
.edit-container h3,
.edit-container h4 {
  color: #333;
}

.edit-form {
  margin-bottom: 20px;
  padding: 20px;
  border: 1px solid #ddd;
  border-radius: 5px;
  background-color: #f9f9f9;
}

.edit-form input,
.edit-form select,
.edit-form button {
  padding: 8px;
  margin: 5px 0;
  border: 1px solid #ccc;
  border-radius: 4px;
  width: 100%;
  box-sizing: border-box;
}

.edit-form button {
  background-color: #4CAF50;
  color: white;
  cursor: pointer;
  border: none;
  width: auto;
  padding: 8px 15px;
}

.edit-form button:hover {
  background-color: #45a049;
}

.edit-form table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.edit-form th,
.edit-form td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: left;
}

.edit-form th {
  background-color: #4CAF50;
  color: white;
}

.edit-titre {
  color: #333;
  font-weight: bold;
  padding: 8px;
}

.edit-error {
  color: red;
}

.edit-success {
  color: green;
}

.edit-action-buttons {
  display: flex;
  gap: 5px;
}

.edit-action-buttons a {
  color: white;
  padding: 5px 10px;
  text-decoration: none;
  border-radius: 4px;
  font-size: 12px;
}

.edit-btn {
  background-color: #2196F3;
}

.edit-delete-btn {
  background-color: #f44336;
}

.edit-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.edit-logout-btn {
  color: white;
  text-decoration: none;
  background-color: #f44336;
  padding: 8px 15px;
  border-radius: 4px;
}

.edit-logout-btn:hover {
  background-color: #d32f2f;
}

.edit-link {
  margin-bottom: 20px;
}
/* ======================
   Correction du texte blanc sur fond blanc dans edit.php
   ====================== */
.edit-container {
  max-width: 1200px;
  margin: 0 auto;
  background-color: #f5f5f5; /* Fond gris clair pour éviter le blanc sur blanc */
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  color: #333; /* Texte noir par défaut */
}

.edit-container h1,
.edit-container h2,
.edit-container h3,
.edit-container h4 {
  color: #333; /* Texte noir pour les titres */
}

.edit-form {
  margin-bottom: 20px;
  padding: 20px;
  border: 1px solid #ddd;
  border-radius: 5px;
  background-color: white; /* Fond blanc pour les formulaires */
  color: #333; /* Texte noir */
}

.edit-form input,
.edit-form select,
.edit-form button {
  padding: 8px;
  margin: 5px 0;
  border: 1px solid #ccc;
  border-radius: 4px;
  width: 100%;
  box-sizing: border-box;
  color: #333; /* Texte noir dans les champs */
  background-color: white; /* Fond blanc pour les champs */
}

.edit-form button {
  background-color: #4CAF50;
  color: white;
  cursor: pointer;
  border: none;
  width: auto;
  padding: 8px 15px;
}

.edit-form button:hover {
  background-color: #45a049;
}

/* Style pour le tableau d'édition */
.edit-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.edit-table th,
.edit-table td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: left;
}

.edit-table th {
  background-color: #4CAF50;
  color: white;
}

.edit-table td {
  background-color: white; /* Fond blanc pour les cellules */
  color: #333; /* Texte noir */
}

.edit-table input[type="text"] {
  width: 100%;
  border: 1px solid #ccc;
  padding: 6px;
  box-sizing: border-box;
  background-color: white;
  color: #333;
}

/* Style pour les boutons d'action dans le tableau */
.edit-action-buttons {
  display: flex;
  gap: 5px;
  justify-content: center;
}

.edit-btn {
  background-color: #2196F3;
  color: white;
  border: none;
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
}

.edit-btn:hover {
  background-color: #1976D2;
}

.edit-delete-btn {
  background-color: #f44336;
  color: white;
  padding: 6px 10px;
  border-radius: 4px;
  text-decoration: none;
  font-size: 14px;
}

.edit-delete-btn:hover {
  background-color: #d32f2f;
}

/* Style pour le formulaire d'ajout */
.edit-add-form {
  margin-top: 15px;
  padding: 10px;
  background-color: #f9f9f9;
  border-radius: 5px;
}

.edit-add-fields {
  display: flex;
  gap: 15px;
}

.edit-add-field {
  flex: 1;
}

.edit-add-field label {
  display: block;
  margin-bottom: 5px;
  color: #333;
}

.edit-add-btn {
  background-color: #4CAF50;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 10px;
}

.edit-add-btn:hover {
  background-color: #45a049;
}

/* Style pour le bouton de déconnexion */
.edit-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.edit-logout-btn {
  color: white;
  text-decoration: none;
  background-color: #f44336;
  padding: 8px 15px;
  border-radius: 4px;
}

.edit-logout-btn:hover {
  background-color: #d32f2f;
}

/* Style pour les messages d'erreur et de succès */
.edit-error {
  color: #f44336;
  margin: 10px 0;
}

.edit-success {
  color: #4CAF50;
  margin: 10px 0;
}
