
/* =========================================================
   2. LAYOUT PRINCIPAL BACK-OFFICE
========================================================= */

.container {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
  background-color: var(--color-primary);
  color: white;
}

.header img {
  height: 80px;
  width: auto;
}

.user-name {
  font-weight: bold;
  font-size: 20px;
}

.body {
  display: flex;
  flex: 1;
  position: relative;
}

.sidebar {
  width: 220px;
  background-color: var(--color-primary);
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: 20px;
}

.menu-top {
  display: flex;
  flex-direction: column;
}

.menu-bottom {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
}

.menu-item {
  padding: 15px 20px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.menu-item:hover {
  background-color: #274a7b;
}

.menu-item.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.menu-item.logout {
  background-color: #274a7b;
  text-align: center;
  border-radius: 6px;
  margin: 0 10px;
}

.menu-item.logout:hover {
  background-color: #1f3c63;
}

.main-content {
  flex: 1;
  padding: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.main-content::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 500px;
  height: 500px;
  background-image: url("/shared/images/logo_leers.png");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: 0.05;
  transform: translate(-50%, -50%);
  z-index: 0;
}

.main-content-inner {
  position: relative;
  z-index: 1;
  width: 100%;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-right: 10px;
}

.saison-wrapper {
  display: flex;
  align-items: center;
  background-color: white;
  color: black;
  padding: 5px 10px;
  border-radius: 6px;
  font-weight: bold;
}

.saison-label {
  margin-right: 5px;
  color: black;
}

.saison-select {
  padding: 2px 5px;
  border-radius: 4px;
  border: 1px solid #ccc;
}

.logout-icon {
  width: 26px !important;
  height: 26px !important;
  display: block;
}

.logout-icon:hover {
  transform: scale(1.12);
  opacity: 0.85;
}

/* =========================================================
   3. PAGE LOGIN
========================================================= */

.login-page {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #f0f2f5;
  min-height: 100vh;
}

.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px;
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  width: 300px;
}

.login-container img {
  width: 120px;
  margin-bottom: 10px;
}

.login-container h2 {
  color: #315e9d;
  text-align: center;
  margin: 0 0 20px 0;
  line-height: 1.2;
}

.login-container input {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 16px;
}

.login-container button {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: none;
  background-color: var(--color-primary);
  color: white;
  font-size: 16px;
  cursor: pointer;
  margin-top: 10px;
  transition: background-color 0.2s ease;
}

.login-container button:hover {
  background-color: #274a7b;
}

.login-error {
  color: red;
  margin-top: 10px;
  text-align: center;
}

.login-container button:disabled {
  background-color: #aebed8;
  cursor: not-allowed;
}

/* =========================================================
   4. PAGE PUBLIQUE / FORMULAIRE ESSAIS
========================================================= */

.page-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  padding: 10px;
  width: 100%;
}

.page-title {
  color: #315e9d;
  margin-bottom: 25px;
}

.page-header-inline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 12px;
  flex-wrap: wrap;
  width: 100%;
}

.public-page {
  margin: 0;
  background: #f0f2f5;
  color: #315e9d;
}

.public-wrapper {
  max-width: 900px;
  margin: 40px auto;
  padding: 20px;
}

.public-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 30px;
}

.public-header-box {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
}

.public-header-box img {
  height: 80px;
  width: auto;
}

.public-header-box h1,
.public-card h2 {
  margin-top: 0;
  color: #315e9d;
}

.public-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 20px;
}

.public-card label {
  display: block;
  font-weight: bold;
  margin-bottom: 6px;
  color: #315e9d;
}

.public-card input,
.public-card select,
.public-card textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  box-sizing: border-box;
  font: inherit;
}

.public-card textarea {
  min-height: 100px;
  resize: vertical;
}

.public-section {
  padding: 24px 0;
  border-bottom: 1px solid #d9e2f0;
}

.public-section:last-of-type {
  border-bottom: none;
}

.public-actions {
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  padding-top: 20px;
}

.public-actions button {
  padding: 10px 18px;
  background: #315e9d;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.2s ease;
}

.public-actions button:hover:not(:disabled) {
  background: #274a7b;
}

.public-actions button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.public-info-box {
  background: #f7f9fc;
  border: 1px solid #d9e2f0;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.public-text-block {
  margin-bottom: 20px;
  line-height: 1.6;
  color: #315e9d;
}

.public-checkbox-block {
  margin-bottom: 24px;
}

.public-checkbox-label {
  display: flex !important;
  align-items: flex-start;
  gap: 10px;
  font-weight: normal !important;
  color: #315e9d;
}

.public-checkbox-label input[type="checkbox"] {
  width: auto;
  margin-top: 3px;
  flex-shrink: 0;
}

.message {
  margin-top: 20px;
  padding: 12px 14px;
  border-radius: 6px;
  display: none;
}

.message.success {
  background: #e8f5e9;
  color: #15803d;
  display: block;
}

.message.error {
  background: #fdecec;
  color: #b42318;
  display: block;
}

/* =========================================================
   5. BLOCS / CARTES / PANNEAUX
========================================================= */

.table-card {
  width: 100%;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 20px;
}

.filtres-bloc {
  width: 100%;
  background: #ffffff;
  border: 1px solid #d9e2f0;
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 18px;
  box-shadow: 0 2px 8px rgba(49, 94, 157, 0.08);
}


/* =========================================================
   6. FILTRES / FORMULAIRES
========================================================= */

.filtres-ligne {
  display: flex;
  align-items: flex-end;
  gap: 20px;
  flex-wrap: wrap;
}

.filtres-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 20px;
  width: 100%;
}

.filtre-groupe {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 200px;
}

.filtre-groupe label {
  color: #315e9d;
  font-weight: bold;
  font-size: 14px;
}

.filtre-groupe select,
.filtre-groupe input,
.filtre-groupe textarea {
  padding: 10px 12px;
  border: 1px solid #cfd8e3;
  border-radius: 8px;
  font-size: 14px;
  min-width: 220px;
  background-color: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filtre-groupe select:focus,
.filtre-groupe input:focus,
.filtre-groupe textarea:focus {
  outline: none;
  border-color: #315e9d;
  box-shadow: 0 0 0 3px rgba(49, 94, 157, 0.12);
}


/* =========================================================
   7. TABLEAUX
========================================================= */

table {
  color: #315e9d;
  font-size: 14px;
  border-collapse: collapse;
  border: 1px solid #ddd;
}

table th,
table td {
  border: 1px solid #ddd;
}

table tbody tr:hover {
  background-color: #f1f5fb;
}

.table-liste {
  width: 100%;
  border-collapse: collapse;
}

.table-liste th {
  padding: 10px;
  border: 1px solid #ddd;
  background-color: var(--color-primary);
  color: white;
}

.table-liste td {
  padding: 10px;
  border: 1px solid #ddd;
}

.table-liste tbody tr {
  transition: all 0.15s ease;
}

.table-liste tbody tr:hover {
  background-color: #d6e3fa;
  transform: scale(1.002);
}

.table-liste tbody tr:nth-child(even) {
  background-color: #fafbfd;
}

/* spécifique tableau matchs */
#matchs-table th:nth-child(6),
#matchs-table td:nth-child(6) {
  width: 130px;
  white-space: nowrap;
}

/* =========================================================
   8. STATUTS / BADGES / ACTIONS
========================================================= */

.status-badge {
  padding: 3px 8px;
  border-radius: 12px;
  font-weight: bold;
  color: white;
  display: inline-block;
  text-transform: capitalize;
  font-size: 0.9em;
}

.action-icons {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.action-icons img {
  cursor: pointer;
  width: 28px;
  height: 28px;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.action-icons img:hover {
  transform: scale(1.15);
  opacity: 0.8;
}

.action-icons img.delete:hover {
  filter: brightness(0) saturate(100%) invert(23%) sepia(97%) saturate(7465%) hue-rotate(357deg) brightness(95%) contrast(119%);
}


/* =========================================================
   9. PAGINATION
========================================================= */

.pagination-bloc {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  width: 100%;
  flex-wrap: wrap;
}

.pagination-bloc button {
  background-color: var(--color-primary);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s ease;
}

.pagination-bloc button:hover:not(:disabled) {
  background-color: #274a7c;
}

.pagination-bloc button:disabled {
  background-color: #aebed8;
  cursor: not-allowed;
}

.pagination-info {
  color: #315e9d;
  font-weight: bold;
}


/* =========================================================
   10. RESPONSIVE
========================================================= */

@media (max-width: 900px) {
  .filtres-ligne {
    flex-direction: column;
    align-items: stretch;
  }

  .filtre-groupe {
    width: 100%;
  }

  .filtre-groupe select,
  .filtre-groupe input,
  .filtre-groupe textarea {
    width: 100%;
    min-width: unset;
  }

  .filtres-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .header {
    flex-wrap: wrap;
    gap: 10px;
  }

  .header img {
    height: auto;
    max-height: 64px;
    width: auto;
    max-width: 140px;
    object-fit: contain;
    flex-shrink: 0;
  }

  .header-right {
    flex: 1;
    min-width: 0;
    justify-content: flex-end;
    flex-wrap: wrap;
  }
}

/* =========================================================
   11. RESPONSIVE PUBLIC
========================================================= */

@media (max-width: 768px) {
  .public-wrapper {
    margin: 20px auto;
    padding: 12px;
  }

  .public-card {
    padding: 20px;
  }

  .public-header-box {
    flex-direction: column;
    align-items: flex-start;
  }

  .public-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   12. ONGLETS / FICHE LICENCIE
========================================================= */

.tab-radio {
  display: none;
}

.tabs-header {
  display: flex;
  gap: 10px;
  margin-bottom: 0;
  border-bottom: 1px solid #d9e2f0;
}

.tab-label {
  display: inline-block;
  padding: 10px 16px;
  border: none;
  border-bottom: 3px solid transparent;
  background: none;
  color: #6b7280;
  font-weight: bold;
  cursor: pointer;
}

#tab-radio-infos:checked ~ .tabs-header label[for="tab-radio-infos"],
#tab-radio-cotisation:checked ~ .tabs-header label[for="tab-radio-cotisation"] {
  border-bottom: 3px solid #315e9d;
  color: #315e9d;
}

.tab-panel {
  display: none;
  padding-top: 24px;
}

#tab-radio-infos:checked ~ .tab-panels #panel-infos {
  display: block;
}

#tab-radio-cotisation:checked ~ .tab-panels #panel-cotisation {
  display: block;
}

.resume-box {
  margin-top: 20px;
  background: #f7f9fc;
  border: 1px solid #d9e2f0;
  border-radius: 8px;
  padding: 16px;
}

.resume-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 16px;
}

.resume-label {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 4px;
}

.resume-value {
  font-size: 18px;
  font-weight: bold;
  color: #315e9d;
}

.resume-warning {
  color: #d97706;
}

@media (max-width: 900px) {
  .resume-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   13. FORMULAIRES BACK-OFFICE / FICHE
========================================================= */

.form-card {
  width: 100%;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 30px;
}

.form-card-large {
  max-width: 1000px;
}

.form-group label.required::after {
  content: " *";
  color: #b42318;
}

.licencie-form-layout {
  display: flex;
  flex-direction: column;
  gap: 28px;
  width: 100%;
}

.form-card {
  font-size: 14px;
}

.form-section {
  padding-bottom: 24px;
  margin-bottom: 24px;
  border-bottom: 1px solid #d9e2f0;
}

.form-section:last-child {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.form-section-title {
  color: #315e9d;
  margin: 0 0 15px 0;
  font-size: 18px;
}

.form-section-title.no-margin {
  margin: 0;
}

.form-grid {
  display: grid;
  gap: 20px;
}

.form-grid-1 {
  grid-template-columns: 1fr;
}

.form-grid-2 {
  grid-template-columns: repeat(2, minmax(280px, 1fr));
}

.form-grid-3 {
  grid-template-columns: repeat(3, minmax(220px, 1fr));
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  display: block;
  font-weight: bold;
  color: #315e9d;
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font: inherit;
  background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #315e9d;
  box-shadow: 0 0 0 3px rgba(49, 94, 157, 0.12);
}

.input-readonly {
  border: 1px solid #ddd !important;
  background: #f7f9fc !important;
  color: #315e9d;
}

.section-header-inline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  gap: 12px;
  flex-wrap: wrap;
}

.reglements-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-actions {
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  padding-top: 10px;
}

.btn-primary,
.btn-secondary {
  padding: 10px 18px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
  background: #315e9d;
  color: white;
  border: none;
}

.btn-primary:hover {
  background: #274a7b;
}

.btn-secondary {
  background: #e6ebf4;
  color: #315e9d;
  border: 1px solid #c7d3e6;
}

.btn-secondary:hover {
  background: #dbe4f2;
}

/* =========================================================
   14. RESPONSIVE FICHE
========================================================= */

@media (max-width: 900px) {
  .form-grid-2,
  .form-grid-3 {
    grid-template-columns: 1fr;
  }

  .form-card {
    padding: 20px;
  }
}

/* =========================================================
   15. TOAST
========================================================= */

#toast-container {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%);
  z-index: 99999;

  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;

  pointer-events: none;
}

.toast {
  background: #315e9d;
  color: white;

  padding: 14px 20px;
  border-radius: 10px;

  min-width: 280px;
  max-width: 420px;
  width: max-content;

  text-align: center;
  font-weight: 600;

  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast.success {
  background: #16a34a;
}

.toast.error {
  background: #dc2626;
}

.toast.info {
  background: #315e9d;
}

/* =========================================================
   16. MODAL
========================================================= */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.modal-overlay.hidden {
  display: none;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(80px, 1fr));
  gap: 10px 16px;
  margin-top: 8px;
}

.checkbox-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}

.vestiaires-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 8px;
}

.vestiaires-card {
  background: #f9fafb;
  border: 1px solid #d0d5dd;
  border-radius: 14px;
  padding: 18px;
}

.vestiaires-card-title {
  font-size: 15px;
  font-weight: 700;
  color: #175cd3;
  margin-bottom: 14px;
}

.vestiaires-grid {
  display: grid;
  grid-template-columns: repeat(3, 56px);
  gap: 12px;
}

.vestiaire-pill {
  position: relative;
  cursor: pointer;
}

.vestiaire-pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.vestiaire-pill span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid #d0d5dd;
  background: #ffffff;
  color: #344054;
  font-weight: 700;
  transition: all 0.18s ease;
  user-select: none;
}

.vestiaire-pill:hover span {
  border-color: #84adff;
  background: #eff4ff;
}

.vestiaire-pill input:checked + span {
  background: #175cd3;
  border-color: #175cd3;
  color: white;
  box-shadow: 0 0 0 3px rgba(23, 92, 211, 0.12);
}

.tournoi-tab-panel {
  display: none;
}

.tournoi-tab-panel.active {
  display: block;
}

.campagne-kpi-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(140px, 1fr));
  gap: 16px;
}

.campagne-kpi-card {
  background: white;
  border: 1px solid #d9e2f0;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(49, 94, 157, 0.08);
}

.campagne-kpi-label {
  font-size: 13px;
  color: #667085;
  margin-bottom: 8px;
}

.campagne-kpi-value {
  font-size: 24px;
  font-weight: 700;
  color: #315e9d;
}

.campagne-mini-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.campagne-mini-card {
  background: #f8fafc;
  border: 1px solid #d9e2f0;
  border-radius: 10px;
  padding: 12px 14px;
}

.campagne-mini-card-label {
  font-size: 12px;
  color: #667085;
  margin-bottom: 4px;
}

.campagne-mini-card-value {
  font-size: 18px;
  font-weight: 700;
  color: #315e9d;
}

.campagne-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 12px;
  white-space: nowrap;
}

.campagne-badge.green {
  background: #dcfce7;
  color: #15803d;
}

.campagne-badge.red {
  background: #fee2e2;
  color: #b42318;
}

.campagne-badge.orange {
  background: #ffedd5;
  color: #c2410c;
}

.campagne-badge.blue {
  background: #dbeafe;
  color: #1d4ed8;
}

#tab-radio-envois:checked ~ .tabs-header label[for="tab-radio-envois"],
#tab-radio-reponses:checked ~ .tabs-header label[for="tab-radio-reponses"] {
  border-bottom: 3px solid #315e9d;
  color: #315e9d;
}

#tab-radio-envois:checked ~ .tab-panels #panel-envois,
#tab-radio-reponses:checked ~ .tab-panels #panel-reponses {
  display: block;
}

@media (max-width: 1200px) {
  .campagne-kpi-grid {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }

  .campagne-mini-grid {
    grid-template-columns: repeat(2, minmax(160px, 1fr));
  }
}

@media (max-width: 900px) {
  .campagne-kpi-grid,
  .campagne-mini-grid {
    grid-template-columns: 1fr;
  }
}

.prepare-filtres-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  align-items: start;
}

.prepare-categories-panel,
.prepare-search-panel {
  background: #f8fafc;
  border: 1px solid #d9e2f0;
  border-radius: 12px;
  padding: 16px;
}

.prepare-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.prepare-panel-title {
  font-weight: bold;
  color: #315e9d;
  font-size: 15px;
}

.prepare-categories-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 10px 16px;
}

.prepare-categorie-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: white;
  border: 1px solid #d9e2f0;
  border-radius: 10px;
  padding: 10px 12px;
  min-height: 42px;
}

.prepare-categorie-item input[type="checkbox"] {
  margin: 0;
  flex-shrink: 0;
}

.prepare-categorie-item span {
  color: #315e9d;
  font-weight: 500;
  line-height: 1.2;
}

.prepare-search-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (max-width: 1100px) {
  .prepare-filtres-layout {
    grid-template-columns: 1fr;
  }

  .prepare-categories-grid {
    grid-template-columns: repeat(2, minmax(160px, 1fr));
  }
}

@media (max-width: 700px) {
  .prepare-categories-grid {
    grid-template-columns: 1fr;
  }
}

.preinscription-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.preinscription-choice-card {
  display: flex !important;
  align-items: center;
  gap: 14px;
  border: 1px solid #d9e2f0;
  border-radius: 14px;
  padding: 16px;
  background: #f8fafc;
  cursor: pointer;
  transition: all 0.2s ease;
}

.preinscription-choice-card:hover {
  border-color: #315e9d;
  background: #edf4ff;
  transform: translateY(-1px);
}

.preinscription-choice-card input {
  display: none;
}

.preinscription-choice-card.active {
  border-color: #315e9d;
  background: #edf4ff;
  box-shadow: 0 0 0 3px rgba(49, 94, 157, 0.12);
}

.choice-badge {
  min-width: 50px;
  height: 50px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.preinscription-choice-card strong {
  display: block;
  color: #315e9d;
  font-size: 16px;
}

.preinscription-choice-card small {
  display: block;
  color: #667085;
  margin-top: 4px;
  line-height: 1.3;
}

@media (max-width: 700px) {
  .preinscription-choice-grid {
    grid-template-columns: 1fr;
  }
}

.preinscription-person-title {
  font-size: 20px;
  font-weight: 700;
  color: #315e9d;
  margin-bottom: 4px;
}

.preinscription-question-title {
  font-size: 16px;
  font-weight: 600;
}

.choice-badge.yes {
  background: #dcfce7;
  color: #15803d;
}

.choice-badge.no {
  background: #fee2e2;
  color: #b42318;
}

.preinscription-choice-card:active {
  transform: scale(0.98);
}

.preinscription-choice-card {
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}

.document-box {
  background: #f8fafc;
  border: 1px solid #d9e2f0;
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 16px;
  color: #315e9d;
  line-height: 1.55;
}

.document-box h3 {
  margin-top: 0;
  color: #315e9d;
  font-size: 18px;
}

.document-box p {
  margin: 0 0 10px 0;
}

.document-question {
  background: white;
  border: 1px solid #d9e2f0;
  border-radius: 12px;
  padding: 14px;
  margin-top: 12px;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  background: #fff;
  border-radius: 12px;
  padding: 22px;
  width: min(560px, 100%);
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.25);
}

.btn-icon {
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  outline: none;
  box-shadow: none;
}

.preinscription-whatsapp-box {
  margin-top: 24px;
  padding: 20px;
  border-radius: 16px;
  background: #f5fff7;
  text-align: center;
  border: 2px solid #25d366;
}

.preinscription-whatsapp-box h3 {
  margin-top: 0;
  color: #128c7e;
}

.whatsapp-community-image {
  width: 100%;
  max-width: 420px;
  border-radius: 16px;
  margin-top: 12px;
}

/* =========================================================
   17. PAGE PUBLIQUE PAIEMENT COTISATION
========================================================= */

.paiement-wrapper {
  max-width: 860px;
  margin: 40px auto;
  padding: 20px;
}

.paiement-card {
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 4px 18px rgba(49, 94, 157, 0.12);
  padding: 32px;
}

.paiement-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 26px;
}

.paiement-header img {
  width: 86px;
  height: auto;
}

.paiement-header h1 {
  margin: 0;
  color: #315e9d;
  font-size: 28px;
}

.paiement-header p {
  margin: 6px 0 0 0;
  color: #667085;
  font-weight: 600;
}

.paiement-alert {
  background: #fef2f2;
  border: 2px solid #ef4444;
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 24px;
  color: #7f1d1d;
}

.paiement-alert strong {
  display: block;
  color: #b91c1c;
  font-size: 18px;
  margin-bottom: 6px;
}

.paiement-alert p {
  margin: 0;
  font-weight: 700;
  line-height: 1.5;
}

.paiement-reference {
  background: #f8fafc;
  border: 1px solid #d9e2f0;
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 22px;
}

.paiement-label {
  font-size: 13px;
  color: #667085;
  margin-bottom: 6px;
}

.paiement-reference-value {
  font-size: 22px;
  font-weight: 800;
  color: #315e9d;
  letter-spacing: 0.5px;
}

.paiement-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 26px;
}

.paiement-mini-card {
  background: #f8fafc;
  border: 1px solid #d9e2f0;
  border-radius: 14px;
  padding: 18px;
}

.paiement-mini-card.strong {
  background: #ecfdf3;
  border-color: #bbf7d0;
}

.paiement-value {
  font-size: 26px;
  font-weight: 800;
  color: #315e9d;
}

.paiement-mini-card.strong .paiement-value {
  color: #047857;
}

.paiement-actions {
  text-align: center;
  margin: 30px 0;
}

.paiement-actions .btn-primary {
  font-size: 18px;
  padding: 15px 34px;
  border-radius: 12px;
}

.paiement-info {
  background: #f7f9fc;
  border: 1px solid #d9e2f0;
  border-radius: 14px;
  padding: 18px;
  color: #315e9d;
  line-height: 1.6;
}

.paiement-info ul {
  margin-top: 10px;
  margin-bottom: 10px;
}

.paiement-info p {
  margin-bottom: 0;
  color: #667085;
  font-size: 13px;
}

@media (max-width: 768px) {
  .paiement-wrapper {
    margin: 20px auto;
    padding: 12px;
  }

  .paiement-card {
    padding: 22px;
  }

  .paiement-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .paiement-grid {
    grid-template-columns: 1fr;
  }
}

.paiement-action-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  margin: 30px 0;
}

.paiement-reference-action {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 14px;
  padding: 16px;
}

.paiement-copy-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.paiement-copy-row span {
  font-size: 22px;
  font-weight: 800;
  color: #315e9d;
  letter-spacing: 0.5px;
}

.paiement-actions {
  margin: 0;
  text-align: right;
}

@media (max-width: 768px) {
  .paiement-action-row {
    grid-template-columns: 1fr;
  }

  .paiement-actions {
    text-align: center;
  }

  .paiement-actions .btn-primary {
    width: 100%;
  }
}

.btn-copy-reference {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}

.btn-copy-reference:hover {
  transform: scale(1.08);
}

.btn-copy-reference img {
  width: 28px;
  height: 28px;
  display: block;
}

.btn-copy-reference.copied {
  opacity: 0.45;
  transform: scale(0.95);
}

.paiement-checkout-premium {
  display: block;
  background: linear-gradient(135deg, #315e9d 0%, #1f3c63 100%);
  color: white;
  border-radius: 22px;
  padding: 30px 32px;
  margin: 36px 0 42px;
  box-shadow: 0 16px 34px rgba(49, 94, 157, 0.28);
}

.paiement-checkout-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
  font-weight: 800;
  opacity: 0.85;
  margin-bottom: 8px;
}

.paiement-checkout-title {
  font-size: 26px;
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 22px;
}

.paiement-payment-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 16px;
}

.paiement-payment-field {
  background: #ffffff;
  border-radius: 16px;
  padding: 16px;
}

.paiement-payment-field label {
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: #16335b;
  margin-bottom: 8px;
}

.paiement-payment-field input,
.paiement-payment-field select {
  width: 100%;
  height: 46px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 0 14px;
  font-size: 17px;
  font-weight: 800;
  color: #16335b;
  box-sizing: border-box;
}

.paiement-echeance-preview {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 14px;
  padding: 14px 16px;
  margin: 16px 0 22px;
  color: #ffffff;
  font-size: 15px;
}

.paiement-echeance-preview strong {
  font-size: 22px;
}

.paiement-checkout-button {
  width: 100%;
  border: none;
  background: white;
  color: #315e9d;
  border-radius: 14px;
  padding: 15px 26px;
  font-size: 17px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(0,0,0,0.18);
}

.paiement-checkout-button:hover:not(:disabled) {
  transform: translateY(-1px);
  background: #f8fafc;
}

.paiement-checkout-button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.paiement-helloasso-inline {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin: 18px 0 0;
  color: #ffffff;
  font-weight: 800;
}

.paiement-helloasso-inline img {
  background: #ffffff;
  border-radius: 12px;
  padding: 8px 12px;
  height: 38px;
}

.paiement-info-compact {
  margin-top: 24px;
  background: #eff6ff;
  border-left: 4px solid #60a5fa;
  color: #16335b;
}

@media (max-width: 700px) {
  .paiement-checkout-premium {
    padding: 24px 18px;
  }

  .paiement-payment-grid {
    grid-template-columns: 1fr;
  }

  .paiement-helloasso-inline {
    flex-direction: column;
    text-align: center;
  }
}

.paiement-modal-overlay {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;

  z-index: 999999;

  display: flex;
  align-items: center;
  justify-content: center;

  background: rgba(0,0,0,.55);

  padding: 20px;
}

.paiement-modal {
  width: 100%;
  max-width: 380px;

  background: #fff;

  border-radius: 16px;

  padding: 24px;

  text-align: center;

  box-shadow:
    0 20px 50px rgba(0,0,0,.25);

  animation: popupIn .2s ease;
}

.paiement-modal-icon {
  font-size: 40px;
  margin-bottom: 12px;
}

.paiement-modal h3 {
  margin: 0 0 12px;
  color: #315e9d;
}

.paiement-modal p {
  margin-bottom: 20px;
  line-height: 1.5;
}

.paiement-modal button {
  background: #315e9d;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  font-weight: 600;
  cursor: pointer;
}

@keyframes popupIn {
  from {
    opacity: 0;
    transform: scale(.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.paiement-contact {
  margin-top: 20px;
  padding: 16px 20px;
  border-radius: 12px;
  background: #f8fafc;
  border-left: 4px solid #315e9d;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.paiement-contact-icon {
  font-size: 24px;
}

.paiement-contact p {
  margin: 8px 0;
}

.paiement-contact a {
  color: #315e9d;
  font-weight: 600;
  text-decoration: none;
}

.preinscription-desktop-tabs {
  display: flex;
  gap: 10px;
  margin: 18px 0;
}

.preinscription-desktop-tab {
  border: 1px solid #cfe0f5;
  background: #ffffff;
  color: #315e9d;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 900;
  cursor: pointer;
}

.preinscription-desktop-tab.active {
  background: #315e9d;
  color: #ffffff;
}

#preinscriptions-desktop-list-view,
#preinscriptions-desktop-capacites-view,
.preinscription-desktop-tabs {
  width: 100%;
}

.preinscriptions-actions {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}