/* Styles globaux du site */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: #333;
    margin: 0;
    padding-bottom: 70px; /* Espace réservé au footer */
    position: relative;
}

/* Header avec titre et navigation */
header {
    background-color: #444;
    color: white;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

header h1 {
    margin: 0;
    text-align: center;
    font-family: 'Poppins', sans-serif;

}

/* Barre de navigation */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    flex-wrap: wrap;
}

.nav-left {
    display: flex;
    gap: 10px;
}

.nav-right {
    display: flex;
    gap: 10px;
}

nav button {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

nav button:hover {
    background-color: #888;
}

/* Contenu principal */
main {
    max-width: 1000px;
    margin: auto;
    padding: 20px;
    min-height: 360px;
}

.message-success {
  background-color: #d4edda;
  color: #155724;
  padding: 1em;
  border: 1px solid #c3e6cb;
  border-radius: 5px;
  margin-bottom: 20px;
  transition: opacity 0.5s ease;
}

/* Cartes (cards) pour affichage des informations */
.card {
    background-color: #fff;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);

}


.card h3 {
    margin-top: 0;
}

.card button {
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.card button:hover {
    background-color: #218838;
}

.card button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.erreur-messages {
    color: red;
    font-weight: bold;
    margin-top: 10px;
}

.position-boutton{
  display: flex;
}

.nav-left-mobile,
.nav-center-mobile,
.nav-right-mobile {
  display: none;
  position: absolute;
  z-index: 100;
  flex-direction: column;
}




  .card-chien {
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.card-chien-info {
  flex: 1;
}
.card-chien-info h4 {
  margin: 0 0 8px 0;
}
.card-chien-info p {
    margin: 4px 0;
}
.card-chien-actions {
    margin-left: 16px;
}
.card-chien-actions a {
  text-decoration: none;
  background: #4CAF50;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.9rem;
}

.card-chien-supprimer a{
    text-decoration: none;
  background: #007bff;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.9rem;
  display: flex;

}


.card-chien-supprimer {
  margin-left: 12px;
}

.boutton-supprimer-modifier{
  display: flex;
  align-items: baseline;
}

.liste-reservations {
  list-style: none;
  padding: 0;
}

.reservation-item {
  display: flex;
  flex-direction: inherit;
  align-items: flex-start;
  margin-bottom: 8px;
  justify-content: space-between;
  
}


.card-membre {
  border: 1px solid #00000067;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  justify-content: space-between;
  align-items: center;
}

.modifier-cours {
  margin-left: 16px;
  text-decoration: none;
  background: #4CAF50;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.9rem;
}



/* conteneur */
.dogs-wrap{
  display:flex;
  flex-wrap:wrap;
  gap:.6rem .8rem;
  margin-top:.5rem;
}

/* puce “chien” */
.dog-chip{
  background:#f9fafb;
  border:1px solid #e2e8f0;
  border-radius:2rem;
  box-shadow:0 1px 2px rgba(0,0,0,.05);
  display:inline-flex;
  align-items:center;
  gap:.55rem;
  padding:.35rem .8rem;
  line-height:1;
}

/* nom (toujours gris foncé) */
.dog-name{
  font-weight:600;
  font-size:.85rem;
  color:#334155;      /* ← fixe : n’hérite plus de vert */
}

/* badge d’état (seul élément coloré) */
.dog-state{
  font-size:.72rem;
  font-weight:600;
  padding:.15rem .55rem;
  border-radius:1rem;
  background:#4CAF50; /* vert ou la couleur que tu veux */
  color:#fff;
  text-transform:capitalize;
}

/* message si aucun chien */
.aucun-chien{
  font-style:italic;
  color:#64748b;
  margin-top:.4rem;
}



/* Styles des formulaires */
form {
    background-color: #fff;
    padding: 10px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

form label {
    font-weight: bold;
}

form input[type="text"],
form input[type="email"],
form input[type="password"],
form input[type="number"] {
    width: 100%;
    padding: 8px;
    margin-top: 4px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
}

form button[type="submit"] {
    margin-top: 10px;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

form button[type="submit"]:hover {
    background-color: #0056b3;
}

  .btn-edit,
  .card-chien-actions {
    margin-left: 16px;
}
.card-chien-actions a {
  text-decoration: none;
  background: #4CAF50;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.9rem;
  }



  .crop-area {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 200px;
      height: 200px;
      cursor: move;
    }

    .crop-wrapper {
      width: 100%;
      height: 100%;
      border: 3px dashed tomato;
      border-radius: 50%;
      position: relative;
      box-sizing: border-box;
    }

    .image-container {
      position: relative;
      width: fit-content;
      height: fit-content;
    }

    .resize-handle {
      position: absolute;
      width: 20px;
      height: 20px;
      background-color: red;
      bottom: -10px;
      right: -10px;
      cursor: nwse-resize;
      border-radius: 4px;
    }

    #result-circle {
      border-radius: 50%;
    }



footer {
    background-color: #444;
    color: white;
    text-align: center;
    padding: 15px 0;
    width: 100%;
    margin-bottom: 20px; /* Ajout d'un espace entre le contenu et le footer */

}


/* Responsive design pour mobiles */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
    }

    .nav-left, .nav-right {
        width: 100%;
        justify-content: center;
        margin-bottom: 10px;
    }

    .nav-right {
        order: -1; /* Boutons Connexion & Inscription en haut sur mobiles */
    }

    main {
        padding: 10px;
    }

    .card {
        padding: 10px;
    }

    form {
        padding: 15px;
    }
    
}
.videoChien {
    display: flex;
    justify-content: center;
    margin: 40px auto;
}

.videoChien video {
    width: 100%;
    max-width: 90%;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0,0,0,0.2);
    height: auto;
}

.nav-center {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

/* Ce sélecteur reprend le style global de tous les boutons nav */
.nav-left button,
.nav-right button,
.nav-center button {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.nav-left button:hover,
.nav-right button:hover,
.nav-center button:hover {
    background-color: #888;
}

.header-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
  }
  
  .header-logo img {
    height: 60px;
  }
  
  .accueil {
    text-align: center;
    padding: 30px;
  }
  
  .accueil p {
    max-width: 700px;
    margin: auto;
  }
  
  .hero-img {
    margin: 30px auto;
  }
  
  .hero-img img {
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 0 0 10px #ccc;
  }
  
  .features {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin: 40px 0;
  }
  
  .feature {
    max-width: 250px;
  }
  
  .feature img {
    width: 100%;
    border-radius: 10px;
  }
  
  .join-button {
    margin: 20px;
  }

  .profil-card {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
  }
  
  .profil-photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid #ccc;
  }
  
  .chien-photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
    border: 3px solid #ccc;
  }
  
  .profil-info {
    flex: 1;
  }
  
  .profil-btn {
    text-align: center;
    margin-top: 30px;
  }
  
  @media (max-width: 600px) {
    .profil-card {
      flex-direction: column;
      text-align: center;
    }
    
    .profil-info {
      width: 100%;
    }
    th,td {
    text-overflow: ellipsis;
    overflow: hidden;
    text-align: left;
    font-size: x-small;
  }

form button[type="submit"] {
  padding: 6px 10px;
  
  }

  nav{
    width: 100%;
    min-width: 100%;
    flex-direction: row;
    flex-wrap: nowrap;
    display: flex;
    justify-content: space-evenly;
    align-items: flex-start;
    margin-top: 15px;

  }

   /* Cacher les menus desktop */
  .nav-left,
  .nav-right,
  .nav-center {
    display: none;
  }

  /* Afficher les menus mobiles */
  .nav-left-mobile,
  .nav-right-mobile {
    display: flex;
    flex-direction: column;
    gap: 5px;
    position: relative;
    margin-bottom: 10px;
  }


.nav-center-mobile {
    display: flex;
    flex-direction: row;
    gap: 5px;
    position: relative;
    margin-bottom: 10px;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
}
  

  .nav-center-mobile button{
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    max-width: 126px;   /* ✅ Limite la taille sans forcer le conteneur */
    margin: auto;
    margin-top: 2px;
}
  
  
  nav button {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    max-width: 126px;   /* ✅ Limite la taille sans forcer le conteneur */
    margin: auto;
    margin-top: 2px;
}

  /* Labels des menus (boutons visibles toujours affichés) */
  .menu-mobile-left,
  .menu-mobile-right {
    background-color: #6c757d;
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    display: inline-block;
    cursor: pointer;
    margin-bottom: 5px;
  }
  .col-email{
    display: none;
  }

  .menu-deroulant-left,
  .menu-deroulant-right {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #444;
    flex-direction: column;
    width: 150px;
    z-index: 999;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
  }

  .menu-deroulant-left a,
  .menu-deroulant-right a {
    color: white;
    padding: 8px 12px;
    text-decoration: none;
  }

  .show-mobile-menu {
    display: flex;
  }

  .nav-left-mobile, .nav-right-mobile {
    position: relative;
  }

.position-boutton {
    display: flex;
    justify-content: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-end;
}

}
  




  
  .cours-dispo {
    border-bottom: 1px solid #ddd;
    padding: 10px 0;
  }
  
  .section-title {
    text-align: left;
    margin-top: 30px;
    margin-bottom: 20px;
  }
  
  .form-ajout-cours {
    background-color: #fff;
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  }
  
  .form-ajout-cours input {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
  }
  
  .form-ajout-cours button {
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  
  .form-ajout-cours button:hover {
    background-color: #218838;
  }
  
  .table-utilisateurs {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    margin-top: 20px;
  }
  
  .table-utilisateurs th,
  .table-utilisateurs td {
    border: 1px solid #ccc;
    padding: 10px;
  }
  
  .table-utilisateurs th {
    background-color: #f1f1f1;
  }
  
  .table-utilisateurs select,
  .table-utilisateurs button {
    margin-top: 5px;
    padding: 6px 12px;
    font-size: 14px;
    border-radius: 4px;
    border: 1px solid #ccc;
  }
  
  .table-utilisateurs button {
    background-color: #007bff;
    color: white;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  
  .table-utilisateurs button:hover {
    background-color: #0056b3;
  }
  
  .elipse {
    word-break: break-all;
  }

  .back-to-top {
    position: fixed;
    top: 7px;
    left: 50%;
    transform: translateX(-50%) rotate(180deg);
    background-color: #6c757d;
    ;
    color: white;
    font-size: 24px;
    text-align: center;
    width: 50px;
    height: 50px;
    line-height: 50px;
    border-radius: 50%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    text-decoration: none;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1000;
  }
  
  .back-to-top.show {
    opacity: 1;
    pointer-events: auto;
  }
  
  .back-to-top:hover {
    background-color: #444;
    transform: translateX(-50%) scale(1.1);
  }
  
  