/* Seynod Roller Hockey - Bénévoles / Matchs à domicile
   Complète style.css du site (à charger APRÈS lui).
   Ne redéfinit que ce qui est propre à cette page. */

section#matchs-intro {
  background: #fff;
  padding-bottom: 1rem;
}
section#matchs-intro p {
  margin: 0;
}
section#matchs {
  background: linear-gradient(to bottom, #eee, #fff);
  padding-bottom: 3rem;
}

.matchs-intro {
  font-size: 0.9rem;
  font-weight: 300;
  margin: 0 0 0.5rem;
}

.legende {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  font-size: 0.8rem;
  font-weight: 300;
  color: #555;
  margin: 0 0 1.2rem;
}
.legende span { display: inline-flex; align-items: center; gap: 0.4rem; }

/* Accordéon : un mois peut contenir beaucoup de lignes */
.horaire-jour.active .horaire-contenu { max-height: 4000px; }

.mois-compte {
  margin-left: auto;
  margin-right: 0.8rem;
  font-weight: 300;
  font-size: 0.8rem;
  color: #777;
}

/* Tableau des matchs (4 colonnes au lieu des 2 des horaires) */
.horaire-table.matchs-table th:nth-child(1),
.horaire-table.matchs-table td:nth-child(1) { width: 24%; }
.horaire-table.matchs-table th:nth-child(2),
.horaire-table.matchs-table td:nth-child(2) { width: 20%; }
.horaire-table.matchs-table th:nth-child(3),
.horaire-table.matchs-table td:nth-child(3) { width: 38%; }
.horaire-table.matchs-table th:nth-child(4),
.horaire-table.matchs-table td:nth-child(4) { width: 18%; }

.matchs-table tr.match-row { cursor: pointer; transition: background-color 0.2s; }
.matchs-table tr.match-row:hover { background-color: #f5f5f5; }
.matchs-table tr.match-row:focus-visible { outline: 2px solid #d51217; outline-offset: -2px; }

.date-jour { display: block; font-weight: 600; }

.pastille {
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  flex-shrink: 0;
}
.pastille.ok      { background: #2e9e44; }
.pastille.partiel { background: #f0a020; }
.pastille.vide    { background: #d51217; }

.statut { display: inline-flex; align-items: center; gap: 0.45rem; }
.statut-compte { font-size: 0.8rem; color: #777; }
.statut-cellule { display: flex; align-items: center; justify-content: space-between; gap: 0.4rem; }
.chevron-ligne { color: #bbb; font-size: 0.8rem; transition: transform 0.2s, color 0.2s; }
.matchs-table tr.match-row:hover .chevron-ligne { color: #d51217; transform: translateX(3px); }
.matchs-table tr.match-row:active { background-color: #eee; }

/* ---------- Pop-up de détail ---------- */
.popup-content.popup-match {
  max-height: 88vh;
  overflow-y: auto;
  box-sizing: border-box;
}
.popup-match .popup-title { margin: 0; padding-right: 2rem; }

.popup-infos p { margin: 0.3rem 0; font-size: 0.9rem; }
.popup-infos i, .popup-infos svg { width: 1.3em; color: #d51217; }

.popup-match h3 {
  font-size: 1rem;
  margin: 0 0 0.6rem;
}
.popup-match h3 i, .popup-match h3 svg { color: #d51217; margin-right: 0.3rem; }
.icone-crosse { width: 1.2em; height: 1.2em; vertical-align: -0.2em; }

.liste-matchs { list-style: none; margin: 0; padding: 0; font-size: 0.85rem; }
.liste-matchs li { padding: 0.25rem 0; border-bottom: 1px solid #ddd; }
.liste-matchs li:last-child { border-bottom: none; }
.liste-matchs strong { display: inline-block; min-width: 3.5rem; }

.tache-bloc + .tache-bloc {
  border-top: 1px solid #d9d9d9;   /* même trait que hr.separateur du site */
  margin-top: 1.5rem;
  padding-top: 1.5rem;
}
.tache-titre { font-weight: 600; font-size: 1.05rem; margin: 0 0 0.4rem; }
.tache-titre i, .tache-titre svg { width: 1.3em; color: #d51217; }
.tache-mention { font-weight: 300; font-size: 0.75rem; color: #555; margin-left: 0.3rem; }

.poste {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.82rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid #ddd;
}
.poste:last-of-type { border-bottom: none; }
.poste-libelle { flex: 1; }
.poste-prenoms { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.3rem; }
.prenom {
  font-size: 0.78rem;
  font-weight: 600;
  color: #333;
  background: #fff;
  border: 1px solid #ccc;
  padding: 0.1rem 0.6rem;
  border-radius: 999px;
  white-space: nowrap;
}
.prenom-equipe { font-weight: 300; color: #666; margin-left: 0.3rem; }
.poste-places {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #ccc;
  white-space: nowrap;
}
.poste.complet .poste-places { background: #2e9e44; border-color: #2e9e44; color: #fff; }
.poste.partiel .poste-places { background: #f0a020; border-color: #f0a020; color: #fff; }
.poste.vide    .poste-places { background: #d51217; border-color: #d51217; color: #fff; }

.btn-inscription {
  display: block;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  margin-top: 0.8rem;
  background: #d51217;
  color: #fff;
  padding: 0.6rem 1.2rem;
  border-radius: 4px;
  font-weight: bold;
  font-size: 0.9rem;
  transition: background-color 0.2s;
}
.btn-inscription:hover { background: #a50f12; }
.btn-inscription.complet { background: #999; cursor: default; pointer-events: none; }

.autre-match {
  display: block;
  margin-top: 0.8rem;
  font-size: 0.82rem;
  text-align: center;
}

.th-court { display: none; }

.badge-competition {
  display: inline-block;
  margin-top: 0.25rem;
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.3;
  color: #d51217;
  border: 1px solid #d51217;
  background: #fff;
  padding: 0.05rem 0.5rem;
  border-radius: 999px;
}
.badge-competition i, .badge-competition svg { margin-right: 0.15rem; }
.marque-competition { white-space: nowrap; }
.trophee { color: #d4a017; }   /* or */
.popup-badge { margin: -0.4rem 0 0.8rem; }
.popup-badge .badge-competition { font-size: 0.8rem; padding: 0.15rem 0.7rem; margin-top: 0; }

.aucun-match { font-weight: 300; font-size: 0.9rem; color: #555; }

@media (max-width: 600px) {
  .legende { flex-wrap: nowrap; gap: 0.9rem; white-space: nowrap; }
  .popup-content { padding: 1.5rem 1.2rem; }
  .statut-compte { display: none; }
  .horaire-table.matchs-table th, .horaire-table.matchs-table td { padding: 8px 6px; }
  .horaire-table.matchs-table td { padding-top: 12px; padding-bottom: 12px; }
  .horaire-table.matchs-table th, .horaire-table.matchs-table td { word-wrap: normal; overflow-wrap: normal; hyphens: auto; }
  .horaire-table.matchs-table th:nth-child(1), .horaire-table.matchs-table td:nth-child(1) { width: 25%; }
  .horaire-table.matchs-table th:nth-child(2), .horaire-table.matchs-table td:nth-child(2) { width: 25%; }
  .horaire-table.matchs-table th:nth-child(3), .horaire-table.matchs-table td:nth-child(3) { width: 38%; }
  .horaire-table.matchs-table th:nth-child(4), .horaire-table.matchs-table td:nth-child(4) { width: 12%; text-align: center; }
  .th-long { display: none; }
  .th-court { display: inline; }
  .matchs-table th .th-texte-benevoles { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .horaire-contenu, .icon { transition: none !important; }
}

@media (max-width: 360px) {
  .legende { gap: 0.6rem; font-size: 0.74rem; }
}

/* =====================================================================
   FORMULAIRE D'INSCRIPTION (inscription.html / .php)
   Même design que le formulaire des notes de frais (/ndf/).
   Les sélecteurs sont préfixés .ins pour neutraliser les règles
   génériques « form input / form button » de style.css.
   ===================================================================== */
.ins > * { max-width: 720px; margin-left: auto; margin-right: auto; }
.ins form { margin-top: 0; }

.ins-carte {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.10);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}
.ins-titre-carte {
  font-weight: 600;
  font-size: 1rem;
  color: #d51217;
  margin: 0 0 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.ins-titre-carte::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 1.1em;
  background: #d51217;
  border-radius: 2px;
}

/* Le match */
.ins-match { display: flex; align-items: center; gap: 1rem; }
.ins-match-titre { margin: 0; font-size: 1.2rem; font-weight: 600; }
.ins-match-titre .badge-competition { vertical-align: middle; margin-top: 0; font-size: 0.75rem; }
.ins-match-infos { margin: 0.2rem 0 0; font-size: 0.9rem; font-weight: 300; color: #555; }
.ins-changer { display: inline-block; margin-top: 1rem; font-size: 0.82rem; }

/* Champs (identiques aux notes de frais) */
.ins-ligne { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 540px) { .ins-ligne { grid-template-columns: 1fr; gap: 0; } }

.ins-champ { display: flex; flex-direction: column; margin-bottom: 1rem; }
.ins-champ label { font-size: 0.82rem; font-weight: 600; margin-bottom: 0.3rem; color: #333; }
.ins .req { color: #d51217; }
.ins .ins-champ input,
.ins .ins-champ select {
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 0.6rem 0.75rem;
  border: 1.5px solid #ddd;
  border-radius: 6px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  background: #fafafa;
  transition: border-color 0.2s;
  color: #000;
}
.ins .ins-champ input:focus,
.ins .ins-champ select:focus { outline: none; border-color: #d51217; background: #fff; }
.ins .ins-champ input.error,
.ins .ins-champ select.error { border-color: #d51217; background: #fff5f5; }
.ins .err-msg { font-size: 0.78rem; color: #d51217; margin-top: 0.2rem; display: none; }
.ins .has-error > .err-msg { display: block; }

/* Postes à cocher : toute la ligne est cliquable */
.ins-tache + .ins-tache { border-top: 1px solid #d9d9d9; margin-top: 1.2rem; padding-top: 1.2rem; }
.ins-poste {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 48px;
  padding: 0.4rem 0.75rem;
  margin-bottom: 0.5rem;
  border: 1.5px solid #e8e8e8;
  border-radius: 8px;
  background: #f9f9f9;
  cursor: pointer;
  font-size: 0.88rem;
  transition: border-color 0.2s, background 0.2s;
}
.ins-poste:hover { border-color: #d51217; }
.ins-poste:has(input:checked) { border-color: #d51217; background: #fff5f5; }
.ins-poste.est-complet { opacity: 0.55; cursor: not-allowed; }
.ins-poste.est-complet:hover { border-color: #e8e8e8; }
.ins .ins-poste input[type="checkbox"] { width: 1.15rem; height: 1.15rem; margin: 0; padding: 0; accent-color: #d51217; flex-shrink: 0; }
.ins-poste-libelle { flex: 1; }
.ins-poste .poste { border: none; padding: 0; }
.ins-tache-choisie .tache-titre { color: #d51217; }
.ins-poste.est-bloque { opacity: 0.45; cursor: not-allowed; }
.ins-poste.est-bloque:hover { border-color: #e8e8e8; }
.ins-aide { font-size: 0.8rem; font-weight: 300; color: #666; margin: -0.6rem 0 1rem; }

.ins-consigne {
  font-size: 0.82rem;
  background: #fff5f5;
  border-left: 3px solid #d51217;
  padding: 0.6rem 0.75rem;
  border-radius: 0 6px 6px 0;
  margin: 0.4rem 0 0;
}
.ins-consigne i, .ins-consigne svg { color: #d51217; margin-right: 0.2rem; }
#f-postes.has-error { box-shadow: 0 0 0 2px #d51217, 0 6px 20px rgba(0, 0, 0, 0.10); }

/* Cases rappel / RGPD */
.ins-case { display: flex; align-items: flex-start; gap: 0.75rem; font-size: 0.88rem; cursor: pointer; padding: 0.35rem 0; }
.ins .ins-case input[type="checkbox"] { width: 1.15rem; height: 1.15rem; margin: 0.15rem 0 0; padding: 0; accent-color: #d51217; flex-shrink: 0; }
.ins-mention { font-size: 0.75rem; font-weight: 300; color: #888; text-align: center; margin: 1rem 0 0; line-height: 1.5; }

/* Boutons */
.ins .ins-btn {
  display: block;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  background: #d51217;
  color: #fff;
  border: none;
  padding: 0.9rem 1.5rem;
  border-radius: 8px;
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  letter-spacing: 0.03em;
}
.ins .ins-btn:hover { background: #a50f12; }
.ins .ins-btn:disabled { background: #ccc; cursor: not-allowed; }

/* Confirmation / erreurs */
.ins-succes { text-align: center; padding: 2.5rem 1.75rem; }
.ins-succes-icone { font-size: 3rem; color: #2e9e44; margin-bottom: 0.75rem; }
.ins-succes h3 { color: #2e7d32; font-size: 1.3rem; margin: 0 0 0.75rem; }
.ins-succes p { color: #555; margin: 0 0 0.5rem; }
.ins-recap-postes { list-style: none; padding: 0; margin: 0.5rem 0 1.25rem; }
.ins-recap-postes li { padding: 0.3rem 0; }
.ins-recap-postes i, .ins-recap-postes svg { color: #d51217; }
.ins-petit { font-size: 0.82rem; margin-bottom: 1.5rem !important; }
.ins-succes .ins-btn { display: inline-block; width: auto; padding: 0.75rem 1.5rem; margin-top: 0.5rem; }
.ins-alerte {
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  background: #fff5f5;
  color: #c62828;
  border-left: 4px solid #d51217;
}
.ins-piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 540px) {
  .ins-carte { padding: 1.25rem; }
  .ins-match .popup-img { width: 48px; }
}
.ins .ins-btn-annuler { background: #333; }
.ins .ins-btn-annuler:hover { background: #000; }

/* Matchs déjà joués : toujours consultables, mais en retrait */
.matchs-table tr.match-passe td { color: #999; }
.matchs-table tr.match-passe .pastille { opacity: 0.45; }
.match-termine { text-align: center; font-size: 0.85rem; color: #777; margin: 1.5rem 0 0; }
.match-termine i, .match-termine svg { color: #999; margin-right: 0.3rem; }

/* Lien discret vers le back-office, sous les accordéons */
.acces-bureau { text-align: right; margin: 1.5rem 0 0; font-size: 0.75rem; }
.acces-bureau a { color: #aaa; }
.acces-bureau a:hover { color: #d51217; }
.acces-bureau i, .acces-bureau svg { margin-right: 0.25rem; }

/* Icône « sifflet » maison (absente de Font Awesome gratuit) : s'utilise comme les autres, classe fa-sifflet */
.fa-sifflet { display: inline-block; width: 1em; height: 1em; vertical-align: -0.125em; background-color: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22%3E%3Cpath d=%22M11 7H13.5A1.5 1.5 0 0 0 16.5 7H22A1 1 0 0 1 23 8V11A1 1 0 0 1 22 12H17.71A7 7 0 1 1 11 7ZM4.3 14A1.85 1.85 0 0 1 0.6 14A1.85 1.85 0 0 1 4.3 14ZM3.25 14A0.8 0.8 0 0 0 1.65 14A0.8 0.8 0 0 0 3.25 14Z%22/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22%3E%3Cpath d=%22M11 7H13.5A1.5 1.5 0 0 0 16.5 7H22A1 1 0 0 1 23 8V11A1 1 0 0 1 22 12H17.71A7 7 0 1 1 11 7ZM4.3 14A1.85 1.85 0 0 1 0.6 14A1.85 1.85 0 0 1 4.3 14ZM3.25 14A0.8 0.8 0 0 0 1.65 14A0.8 0.8 0 0 0 3.25 14Z%22/%3E%3C/svg%3E") center / contain no-repeat; }
.fa-sifflet::before { content: none !important; }

/* Bandeau temporaire « module en cours de développement » */
.bandeau-dev { background: #fff3cd; color: #7a5b00; border-left: 4px solid #f0a020; border-radius: 0 6px 6px 0;
               padding: 0.6rem 0.9rem; margin: 0 0 1rem; font-size: 0.88rem; font-weight: 600; }
.bandeau-dev i, .bandeau-dev svg { color: #f0a020; margin-right: 0.35rem; }

/* Bloc d'infos de la pop-up (note pour les bénévoles + live vidéo) : bleu pastel, texte bleu soutenu */
.popup-bloc-info { background: #e7f0fd; color: #1a4f9c; border-left: 3px solid #2f6fd0; border-radius: 0 6px 6px 0;
                   padding: 0.55rem 0.75rem; margin: 0.8rem 0 0; font-size: 0.85rem; }
.popup-bloc-info p, .popup-bloc-info a { display: flex; gap: 0.5rem; align-items: baseline; margin: 0; }
.popup-bloc-info > * + * { margin-top: 0.4rem; }
.popup-bloc-info i, .popup-bloc-info svg { color: #2f6fd0; width: 1.1em; flex-shrink: 0; }
.popup-bloc-info a { color: #1a4f9c; font-weight: 600; }
.popup-bloc-info a span { text-decoration: underline; text-underline-offset: 2px; }
.popup-bloc-info a:hover span { color: #0f3a7a; }
