/* ============================================================
   DISPONIBILITÉS — assets/css/disponibilites.css
   Préfixe : dispo-
   ============================================================ */

/* ── Hero ── */
.dispo-hero {
  background: linear-gradient(135deg, #faf6e4 0%, #eef7f1 100%);
  padding: 60px 40px 50px;
  text-align: center;
  border-bottom: 1px solid #ede8dc;
}

.dispo-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #e8f5ec;
  color: #54a66a;
  border: 1px solid #c3e6cb;
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.dispo-hero-titre {
  font-family: 'Schoolbell', cursive;
  font-size: 2.4rem;
  color: #b5833e;
  margin: 0 0 12px 0;
}

.dispo-hero-desc {
  font-family: 'Nunito', sans-serif;
  font-size: 1rem;
  color: #6b5644;
  max-width: 500px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ── Conteneur ── */
.dispo-container {
  max-width: 860px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

/* ── Légende ── */
.dispo-legende {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 32px;
}

.dispo-legende-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.88rem;
  color: #6b5644;
  font-weight: 600;
}

.dispo-dot {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dispo-dot.disponible { background: #54a66a; }
.dispo-dot.complet    { background: #d9534f; }
.dispo-dot.ferme      { background: #c0ac98; }

/* ── Calendrier wrapper ── */
.dispo-calendrier-wrapper {
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 4px 28px rgba(181,131,62,0.10);
  border: 1px solid #ede8dc;
  overflow: hidden;
  margin-bottom: 24px;
}

/* ── Navigation ── */
.dispo-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #ede8dc;
  background: #fdfaf5;
}

.dispo-nav-titre {
  font-family: 'Schoolbell', cursive;
  font-size: 1.5rem;
  color: #b5833e;
  margin: 0;
}

.dispo-nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  border: 1.5px solid #e8dfd0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b5833e;
  font-size: 0.85rem;
  text-decoration: none;
  transition: all 0.15s;
}

.dispo-nav-btn:hover {
  background: #b5833e;
  color: #fff;
  border-color: #b5833e;
}

/* ── Grille ── */
.dispo-grille {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  background: #ede8dc;
  padding: 1px;
}

.dispo-jour-header {
  background: #fdfaf5;
  text-align: center;
  padding: 10px 4px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  color: #8a7060;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ── Cases ── */
.dispo-case {
  background: #ffffff;
  min-height: 76px;
  padding: 8px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  position: relative;
  transition: background 0.12s;
}

.dispo-case.vide          { background: #fafafa; }
.dispo-case.non-renseigne { background: #fafafa; }
.dispo-case.passe         { opacity: 0.4; }

.dispo-case.cliquable { cursor: pointer; }
.dispo-case.cliquable:hover { background: #fdfaf5; }

/* Bordure colorée en bas */
.dispo-case.disponible { border-bottom: 4px solid #54a66a; background: #f6fff9; }
.dispo-case.complet    { border-bottom: 4px solid #d9534f; background: #fff9f9; }
.dispo-case.ferme      { border-bottom: 4px solid #c0ac98; background: #f8f5f2; }

/* Jour aujourd'hui */
.dispo-case.aujourd-hui .dispo-num {
  background: #b5833e;
  color: #fff;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Case active (sélectionnée) */
.dispo-case.active {
  outline: 2px solid #b5833e;
  outline-offset: -2px;
  z-index: 2;
}

.dispo-num {
  font-family: 'Nunito', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: #3d2b1f;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dispo-places {
  font-family: 'Nunito', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 8px;
}

.dispo-case.disponible .dispo-places { background: #c8efd4; color: #1a6b35; }
.dispo-case.complet    .dispo-places { background: #fcd9d7; color: #a02020; }
.dispo-case.ferme      .dispo-places { background: #e8dfd0; color: #7a6050; font-size: 0.65rem; }

/* ── Panneau détail ── */
.dispo-detail {
  background: #fff;
  border-radius: 16px;
  border: 1px solid #ede8dc;
  box-shadow: 0 4px 20px rgba(181,131,62,0.09);
  margin-bottom: 32px;
  animation: dispoSlideDown 0.2s ease;
}

@keyframes dispoSlideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dispo-detail-inner  { padding: 22px 24px; }

.dispo-detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}

.dispo-detail-date {
  font-family: 'Schoolbell', cursive;
  font-size: 1.3rem;
  color: #b5833e;
  margin-bottom: 6px;
}

.dispo-detail-statut {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 20px;
}

.dispo-detail-statut.disponible { background: #e8f5ec; color: #2e7d47; }
.dispo-detail-statut.complet    { background: #fdecea; color: #c0392b; }
.dispo-detail-statut.ferme      { background: #f0ebe4; color: #7a6050; }

.dispo-detail-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid #e8dfd0;
  background: transparent;
  color: #8a7060;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: all 0.15s;
  flex-shrink: 0;
}

.dispo-detail-close:hover {
  background: #fdecea;
  border-color: #f5c6cb;
  color: #c0392b;
}

.dispo-detail-info {
  font-family: 'Nunito', sans-serif;
  font-size: 0.95rem;
  color: #3d2b1f;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.dispo-detail-notes {
  font-family: 'Nunito', sans-serif;
  font-size: 0.88rem;
  color: #6b5644;
  background: #fdfaf5;
  border-left: 3px solid #eec9ae;
  padding: 10px 14px;
  border-radius: 0 8px 8px 0;
  margin-bottom: 16px;
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.dispo-detail-footer {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ── Boutons détail ── */
.btn-reserver {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  background: #54a66a;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}

.btn-reserver:hover {
  background: #3d8a55;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(84,166,106,0.25);
  color: #fff;
}

.btn-login {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  background: #fff;
  color: #b5833e;
  border: 2px solid #b5833e;
  border-radius: 10px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.15s;
}

.btn-login:hover {
  background: #b5833e;
  color: #fff;
  transform: translateY(-1px);
}

/* ── CTA bas ── */
.dispo-cta-section {
  text-align: center;
  padding: 40px 20px;
  background: #fdfaf5;
  border-radius: 20px;
  border: 1px dashed #eec9ae;
  margin-top: 16px;
}

.dispo-cta-icon {
  font-size: 2rem;
  color: #eec9ae;
  margin-bottom: 12px;
  display: block;
}

.dispo-cta-titre {
  font-family: 'Schoolbell', cursive;
  font-size: 1.4rem;
  color: #b5833e;
  margin: 0 0 8px 0;
}

.dispo-cta-desc {
  font-family: 'Nunito', sans-serif;
  font-size: 0.9rem;
  color: #8a7060;
  margin-bottom: 20px;
}

.dispo-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 26px;
  background: #b5833e;
  color: #fff;
  border-radius: 12px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.15s;
}

.dispo-cta-btn:hover {
  background: #9c6e30;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(181,131,62,0.25);
  color: #fff;
}

/* ── Modale ── */
.dispo-modale {
  position: fixed;
  inset: 0;
  background: rgba(61,43,31,0.45);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: dispoFadeIn 0.15s ease;
}

@keyframes dispoFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.dispo-modale-box {
  background: #fff;
  border-radius: 20px;
  padding: 32px 30px;
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 12px 48px rgba(61,43,31,0.18);
  animation: dispoSlideUp 0.2s ease;
}

@keyframes dispoSlideUp {
  from { transform: translateY(16px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.dispo-modale-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.dispo-modale-titre {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: 'Schoolbell', cursive;
  font-size: 1.4rem;
  color: #b5833e;
  margin: 0;
}

.dispo-modale-titre i { color: #54a66a; }

.dispo-modale-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid #e8dfd0;
  background: transparent;
  color: #8a7060;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  transition: all 0.15s;
}

.dispo-modale-close:hover {
  background: #fdecea;
  border-color: #f5c6cb;
  color: #c0392b;
}

.dispo-modale-date {
  font-family: 'Nunito', sans-serif;
  font-size: 0.85rem;
  color: #6b5644;
  margin-bottom: 22px;
  padding: 9px 14px;
  background: #fdfaf5;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #ede8dc;
}

.dispo-modale-date i { color: #54a66a; }

.dispo-form-group { margin-bottom: 16px; }

.dispo-label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #b5833e;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 7px;
}

.dispo-required { color: #e05252; }

#formReservation input,
#formReservation textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1.5px solid #e8dfd0;
  border-radius: 10px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.92rem;
  color: #3d2b1f;
  background: #fdfaf5;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

#formReservation input:focus,
#formReservation textarea:focus {
  border-color: #54a66a;
  box-shadow: 0 0 0 3px rgba(84,166,106,0.12);
  background: #fff;
}

#formReservation textarea {
  resize: vertical;
  min-height: 90px;
}

.dispo-btn-envoyer {
  width: 100%;
  padding: 13px;
  background: #54a66a;
  color: #fff;
  border: none;
  border-radius: 11px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  transition: background 0.2s, transform 0.15s;
  margin-top: 4px;
}

.dispo-btn-envoyer:hover   { background: #3d8a55; transform: translateY(-1px); }
.dispo-btn-envoyer:disabled { opacity: 0.65; cursor: not-allowed; transform: none; }

.dispo-feedback {
  display: none;
  align-items: center;
  gap: 9px;
  margin-top: 14px;
  padding: 11px 14px;
  border-radius: 10px;
  font-family: 'Nunito', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
}

.dispo-feedback.success { background: #e8f5ec; color: #2e7d47; border: 1px solid #c3e6cb; }
.dispo-feedback.error   { background: #fdecea; color: #c0392b; border: 1px solid #f5c6cb; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .dispo-hero       { padding: 40px 20px 35px; }
  .dispo-hero-titre { font-size: 1.8rem; }
  .dispo-container  { padding: 28px 16px 60px; }
  .dispo-case       { min-height: 54px; }
  .dispo-places     { display: none; }
}

@media (max-width: 480px) {
  .dispo-case   { min-height: 42px; padding: 4px 2px; }
  .dispo-num    { font-size: 0.76rem; width: 22px; height: 22px; }
  .dispo-nav-titre { font-size: 1.2rem; }
}