/*fights.css*/

/* =====================================
   1. STRUCTURE GÉNÉRALE
   ===================================== */
/* 1.1 Conteneur principal */
.battle-details-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
  background-color: var(--dark-bg-primary);
  border-radius: 8px;
  overflow: hidden;
}

/* 1.2 En-tête de la bataille */
.battle-details-container .battle-header {
  position: relative;
  width: 100%;
  padding: 20px 0;
  margin-bottom: 20px;
  text-align: center;
  color: var(--text-light);
}

/* Structure du wrapper pour aligner le bouton et le titre */
.battle-details-container .header-wrapper {
  position: relative;
  width: 100%;
  min-height: 40px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin-bottom: 20px;
}

/* 1.2.1 Bouton retour */
#back-to-battles-btn {
  background-color: transparent;
  color: var(--text-muted);
  border: 1px solid var(--text-muted);
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

#back-to-battles-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

/* Tableau pour l'affichage VS */
.battle-vs-table {
  width: 90%;
  max-width: 600px;
  margin: 15px auto;
  border-spacing: 0;
  table-layout: fixed;
}

/* Cellules pour les noms des dresseurs */
.trainer-cell {
  width: 30%;
  color: var(--text-light);
  font-size: 18px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.trainer-cell-1 {
  text-align: right;
  padding-right: 12px;
}

.trainer-cell-2 {
  text-align: left;
  padding-left: 12px;
}

/* Cellules pour les scores */
.score-cell {
  width: 15%;
  text-align: center;
}

/* Cellule pour le VS */
.vs-cell {
  width: 10%;
  text-align: center;
}

/* Style des scores */
.score-value {
  font-size: 18px;
  font-weight: bold;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  position: relative;
  overflow: hidden;
  margin: 0 auto;
}

.score-value::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0));
  border-radius: 5px 5px 0 0;
}

#trainer1-score {
  background-color: var(--info);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

#trainer2-score {
  background-color: var(--danger);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Style pour le VS au centre */
.versus-icon {
  font-size: 24px;
  color: var(--danger);
  font-weight: bold;
  background-color: rgba(0, 0, 0, 0.3);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(244, 67, 54, 0.3);
  margin: 0 auto;
}

/* Support responsive */
@media (max-width: 768px) {
  .battle-details-container {
    padding: 0 10px;
  }
  
  .battle-vs-table {
    width: 100%;
  }
  
  .trainer-cell {
    font-size: 16px;
    width: 28%;
  }
  
  .trainer-cell-1 {
    padding-right: 8px;
  }
  
  .trainer-cell-2 {
    padding-left: 8px;
  }
  
  .score-cell {
    width: 17%;
  }
  
  .score-value {
    width: 28px;
    height: 28px;
    font-size: 16px;
  }
  
  .vs-text {
    font-size: 18px;
  }
}

/* 1.3 Conteneur des combats */
.fights-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.fights-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
  width: 100%;
  margin-top: 20px;
}

#add-fight-btn {
  margin: 10px 0 20px 0;
}

/* Styles pour l'affichage du vainqueur dans la liste des combats */
.fight-header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex: 1;
  margin-right: 15px;
}

.fight-name {
  font-weight: bold;
}

.fight-winner {
  margin-left: 15px;
  font-weight: 600;
}

/* =====================================
   2. STYLES DE BASE POUR LES SCORES
   ===================================== */
.score-container {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: bold;
}

.score-value {
  padding: 1px 6px;
  min-width: 22px;
  text-align: center;
  border-radius: 4px;
}

.score-separator {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Couleurs pour les vainqueurs */
.winner-trainer1 {
  color: var(--info);
  background-color: rgba(33, 150, 243, 0.1);
}

.winner-trainer2 {
  color: var(--warning);
  background-color: rgba(255, 152, 0, 0.1);
}

/* =====================================
   3. STYLES POUR LA PAGE DE COMBATS
   ===================================== */

/* 3.1 Élément de combat */
.fight-item {
  background-color: var(--dark-bg-secondary);
  color: var(--text-light);
  border-radius: 10px;
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.fight-item:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.fight-header {
  padding: 16px 20px;
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.fight-expand-icon {
  transition: transform 0.3s ease;
}

.fight-expand-icon.open {
  transform: rotate(180deg);
}

.fight-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background-color: var(--dark-bg-primary);
}

.fight-content.open {
  max-height: 2000px; /* Augmenté pour assurer que tout le contenu est visible */
}

.fight-details {
  padding: 20px;
}

/* 3.2 Vue face à face */
.fight-battle-container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 15px;
  width: 100%;
}

.fight-trainer-column {
  flex: 1;
  max-width: 45%;
}

.fight-versus-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 0;
}

.versus-icon {
  font-size: 24px;
  color: var(--danger);
  font-weight: bold;
  background-color: rgba(0, 0, 0, 0.3);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(244, 67, 54, 0.3);
}

.fight-trainer-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 15px;
  text-align: center;
  padding-bottom: 5px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.fight-pokemon-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* 3.3 Boutons d'action */
.fight-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
}

.fight-actions button {
  flex: 1;
  padding: 12px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  font-size: 14px;
  transition: background-color 0.2s ease;
  border: none;
  max-width: 250px;
}

.btn-edit-fight {
  background-color: var(--primary-color);
  color: white;
}

.btn-edit-fight:hover {
  background-color: var(--primary-light);
}

.btn-delete-fight {
  background-color: #7f1d1d;
  color: white;
}

.btn-delete-fight:hover {
  background-color: var(--danger);
}

/* 3.4 Boutons généraux */
.btn-action {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-action:hover {
  background-color: var(--primary-light);
}

.btn-back {
  background-color: transparent;
  color: var(--text-muted);
  border: 1px solid var(--text-muted);
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-back:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

/* =====================================
   4. CARTES POKÉMON
   ===================================== */

/* Conteneur principal (carte + niveau externe) */
.pokemon-container {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  width: 100%;
  position: relative;
}

/* Configuration spécifique pour chaque dresseur */
.trainer-side-1 {
  flex-direction: row; /* Carte puis statut pour le dresseur 1 */
  justify-content: flex-start; /* Aligné à gauche */
}

.trainer-side-2 {
  flex-direction: row; /* Niveau+statut puis carte pour le dresseur 2 */
  justify-content: flex-end; /* Aligné à droite */
}

/* Section externe avec niveau et statut */
.pokemon-external-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 60px;
  flex-shrink: 0;
  gap: 10px;
  margin: 0 10px; /* Marge des deux côtés */
}

.pokemon-external-info.right {
  margin-left: 10px;
}

.pokemon-external-info.left {
  margin-right: 10px;
}

/* Encadré externe contenant niveau et statut */
.pokemon-external-box {
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
}

/* Niveau */
.pokemon-level {
  display: flex;
  align-items: center;
  color: var(--text-light);
  background-color: transparent !important; /* Supprime le fond sombre */
}

.pokemon-level-label {
  font-size: 0.75rem;
  margin-right: 5px;
}

.pokemon-level-value {
  font-size: 0.95rem;
  font-weight: 600;
}

/* Statut du Pokémon avec texte/emoji */
.pokemon-status-text {
  color: white;
  padding: 3px 6px;
  border-radius: 4px;
  text-align: center;
  width: 100%;
  font-weight: 500;
  font-size: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 24px;
}

/* Style pour le texte KO */
.ko-text {
  color: white;
  font-weight: bold;
  text-transform: uppercase;
  font-size: 14px;
}

/* Couleurs des statuts */
.pokemon-status-text.status-fainted { 
  background-color: var(--danger); /* Rouge pour KO */
}
.pokemon-status-text.status-battled { 
  background-color: var(--success); /* Vert pour utilisé */
}
.pokemon-status-text.status-unused { 
  background-color: var(--text-muted); /* Gris pour non utilisé */
}

/* Structure de base de la carte */
.pokemon-card {
  position: relative;
  width: calc(100% - 80px); /* Réserve de l'espace pour le statut */
  height: 120px;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, box-shadow 0.2s;
  flex-grow: 1;
}

/* Fond sans démarcation avec pseudo-élément */
.pokemon-card:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 0;
  border-radius: 12px;
}

/* Dégradés pour les types appliqués au pseudo-élément */
.bg-normal:before { background: linear-gradient(135deg, var(--type-normal), #C6C6A7); }
.bg-fire:before { background: linear-gradient(135deg, var(--type-fire), #F5AC78); }
.bg-water:before { background: linear-gradient(135deg, var(--type-water), #9DB7F5); }
.bg-electric:before { background: linear-gradient(135deg, var(--type-electric), #FAE078); }
.bg-grass:before { background: linear-gradient(135deg, var(--type-grass), #A7DB8D); }
.bg-ice:before { background: linear-gradient(135deg, var(--type-ice), #BCE6E6); }
.bg-fighting:before { background: linear-gradient(135deg, var(--type-fighting), #D67873); }
.bg-poison:before { background: linear-gradient(135deg, var(--type-poison), #C183C1); }
.bg-ground:before { background: linear-gradient(135deg, var(--type-ground), #EBD69D); }
.bg-flying:before { background: linear-gradient(135deg, var(--type-flying), #C6B7F5); }
.bg-psychic:before { background: linear-gradient(135deg, var(--type-psychic), #FA92B2); }
.bg-bug:before { background: linear-gradient(135deg, var(--type-bug), #C6D16E); }
.bg-rock:before { background: linear-gradient(135deg, var(--type-rock), #D1C17D); }
.bg-ghost:before { background: linear-gradient(135deg, var(--type-ghost), #A292BC); }
.bg-dragon:before { background: linear-gradient(135deg, var(--type-dragon), #A27DFA); }
.bg-dark:before { background: linear-gradient(135deg, var(--type-dark), #A29288); }
.bg-steel:before { background: linear-gradient(135deg, var(--type-steel), #D1D1E0); }
.bg-fairy:before { background: linear-gradient(135deg, var(--type-fairy), #F4BDC9); }

/* Double type avec le pseudo-élément */
.pokemon-card[data-secondary-type]:before {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.pokemon-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Partie info de la carte - optimisé avec moins d'espace */
.card-info {
  padding: 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1.8; /* Réduit pour rapprocher de l'image */
  position: relative;
  z-index: 1;
  background: transparent !important;
}

/* Nom du Pokémon - avec taille de police adaptative */
.pokemon-name {
  font-size: 1.4rem; /* Taille par défaut */
  font-weight: 700;
  color: white;
  text-transform: capitalize;
  margin: 0 0 8px 0;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  word-wrap: break-word; /* Autorise les retours à la ligne si nécessaire */
  /* Réduit la taille de police en fonction de la longueur du nom */
  font-size: clamp(1rem, 1.4rem - (var(--name-length, 10) - 8) * 0.05rem, 1.4rem);
}

/* Types de Pokémon - espacement réduit */
.pokemon-types {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.type-badge {
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Section d'information en bas - contient le Pokédex et la région */
.pokemon-info-footer {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
}

/* Numéro Pokédex */
.pokemon-number {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}

/* Région du Pokémon */
.pokemon-region {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.7);
  font-style: italic;
  font-weight: 600;
}

/* Partie image - augmentée pour donner plus d'espace */
.card-image-container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 2.2;
  position: relative;
  z-index: 1;
  background: transparent !important;
  margin-left: -10px;
}

.pokemon-image {
  height: 100%;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.pokemon-image img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
}

/* Couleurs des badges de type */
.type-normal { background-color: var(--type-normal); }
.type-fire { background-color: var(--type-fire); }
.type-water { background-color: var(--type-water); }
.type-electric { background-color: var(--type-electric); }
.type-grass { background-color: var(--type-grass); }
.type-ice { background-color: var(--type-ice); }
.type-fighting { background-color: var(--type-fighting); }
.type-poison { background-color: var(--type-poison); }
.type-ground { background-color: var(--type-ground); }
.type-flying { background-color: var(--type-flying); }
.type-psychic { background-color: var(--type-psychic); }
.type-bug { background-color: var(--type-bug); }
.type-rock { background-color: var(--type-rock); }
.type-ghost { background-color: var(--type-ghost); }
.type-dragon { background-color: var(--type-dragon); }
.type-dark { background-color: var(--type-dark); }
.type-steel { background-color: var(--type-steel); }
.type-fairy { background-color: var(--type-fairy); }

/* =====================================
   5. MODALE D'AJOUT DE COMBAT (FIGHT-MODAL)
   ===================================== */

/* 5.1 Structure de base */
.fight-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.fight-modal.active {
  display: flex;
}

.fight-modal-content {
  background-color: var(--dark-bg-secondary);
  width: 90%;
  max-width: 900px;
  max-height: 90vh;
  border-radius: 10px;
  padding: 25px;
  color: var(--text-light);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  overflow-y: auto;
}

/* 5.2 En-tête de la modale */
.fight-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.fight-modal-title {
  font-size: 20px;
  font-weight: bold;
}

.fight-modal-close {
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 24px;
  cursor: pointer;
}

/* 5.3 Corps de la modale */
.fight-modal-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.fight-name-container {
  margin-bottom: 10px;
}

.fight-name-container label {
  display: block;
  margin-bottom: 5px;
  color: var(--text-muted);
  font-size: 14px;
}

.fight-name-input {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background-color: var(--dark-bg-primary);
  color: var(--text-light);
  font-size: 16px;
}

/* 5.4 Conteneur des dresseurs */
.trainers-container {
  display: flex;
  gap: 30px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.trainer-side {
  flex: 1 1 300px;
}

.trainer-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 15px;
  text-align: center;
  color: var(--text-muted);
}

/* 5.5 Recherche de Pokémon */
.pokemon-search-container {
  position: relative;
  margin-bottom: 15px;
}

.pokemon-search-input {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background-color: var(--dark-bg-primary);
  color: var(--text-light);
  font-size: 16px;
}

.search-results-container {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  max-height: 200px;
  overflow-y: auto;
  background-color: var(--dark-bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 0 0 6px 6px;
  z-index: 10;
  display: none;
}

.search-results-container.active {
  display: block;
}

.search-result {
  padding: 8px 12px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.search-result:hover {
  background-color: var(--dark-bg-tertiary);
}

/* 5.6 Liste des Pokémon ajoutés */

.pokemon-table-header {
    font-size: 1.1rem;
    font-weight: 400;
    margin: 0;
    color: var(--text-light);
}


.trainer-pokemon-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 300px;
  overflow-y: auto;
}

.pokemon-block {
  background-color: rgba(26, 29, 42, 0.7);
  border-radius: 6px;
  border: 1px solid var(--border-color);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 40px;
}

/* Styles pour la disposition en tableau */
.pokemon-table-container {
  background-color: rgba(26, 29, 42, 0.7);
  border-radius: 6px;
  border: 1px solid var(--border-color);
  width: 100%;
  overflow: hidden;
}

/* Style pour les lignes du tableau */
.pokemon-table-row {
  display: flex;
  align-items: center;
  padding: 8px 10px;
  border-bottom: 1px solid rgba(58, 63, 81, 0.5);
}

.pokemon-table-row:last-child {
  border-bottom: none;
}

.pokemon-table-row:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Style pour les colonnes */
.pokemon-col {
  padding: 0 5px;
}

.pokemon-name-col {
  flex: 1;
  min-width: 0; /* Pour éviter le débordement */
  font-weight: bold;
}

.pokemon-level-col {
  width: 70px;
  flex-shrink: 0;
}

.pokemon-status-col {
  width: 110px;
  flex-shrink: 0;
}

.pokemon-actions-col {
  width: 30px;
  flex-shrink: 0;
  text-align: center;
}

/* Style pour les contrôles */
.pokemon-level-input {
  width: 100%;
  padding: 4px;
  font-size: 14px;
  background-color: var(--dark-bg-primary);
  color: var(--text-light);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  text-align: center;
}

.pokemon-level-input::-webkit-inner-spin-button,
.pokemon-level-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.pokemon-status-select {
  width: 100%;
  padding: 4px;
  font-size: 14px;
  border-radius: 4px;
  background-color: var(--dark-bg-primary);
  color: var(--text-light);
  border: 1px solid var(--border-color);
}

.pokemon-remove-btn {
  background: none;
  border: none;
  color: var(--danger);
  font-size: 20px;
  cursor: pointer;
  display: block;
  margin: 0 auto;
}

.pokemon-item {
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  padding: 8px 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.pokemon-info {
  font-weight: bold;
}

.pokemon-level-container {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* 5.7 Boutons d'action */
.btn-add-pokemon {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-add-pokemon:hover {
  background-color: var(--primary-light);
}

.fight-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

.fight-modal-actions .btn-cancel {
  background-color: transparent;
  border: 1px solid var(--text-muted);
  color: var(--text-muted);
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.fight-modal-actions .btn-cancel:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.fight-modal-actions .btn-submit {
  background-color: var(--primary-color);
  border: none;
  color: white;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.fight-modal-actions .btn-submit:hover {
  background-color: var(--primary-light);
}

/* 5.8 Modale de confirmation */
.confirm-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 1100;
}

.confirm-modal.active {
  display: flex;
}

.confirm-modal-content {
  background-color: var(--dark-bg-secondary);
  width: 400px;
  border-radius: 10px;
  padding: 20px;
  color: var(--text-light);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.confirm-modal-header {
  margin-bottom: 15px;
}

.confirm-modal-title {
  font-size: 18px;
  font-weight: bold;
}

.confirm-modal-body {
  margin-bottom: 20px;
}

.confirm-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.btn-danger {
  background-color: var(--danger);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-danger:hover {
  background-color: #c53030;
}

/* =====================================
   6. RESPONSIVE
   ===================================== */
@media (max-width: 768px) {
  /* 6.1 Layout adaptatif */
  .battle-details-container {
    padding: 0 10px;
  }
  
  .battle-details-container .battle-title {
    font-size: 20px;
    width: 80%;
  }
  
  #back-to-battles-btn {
    padding: 6px 10px;
    font-size: 14px;
  }
  
  /* 6.2 Disposition des affrontements sur mobile */
  .trainers-container {
    flex-direction: column;
  }
  
  .trainer-side {
    flex: none;
    width: 100%;
  }
  
  .fight-battle-container {
    flex-direction: column;
    align-items: center;
  }
  
  .fight-trainer-column {
    max-width: 100%;
    width: 100%;
    margin-bottom: 15px;
  }
  
  .fight-versus-container {
    margin: 10px 0;
  }
  
  /* 6.3 Ajustement des cartes Pokémon sur mobile */
  .pokemon-card {
    width: calc(100% - 50px);
    height: 90px;
  }
  
  .card-info {
    padding: 0.7rem;
  }
  
  .pokemon-name {
    font-size: 1.1rem;
  }
  
  .type-badge {
    font-size: 0.6rem;
    padding: 2px 6px;
  }
  
  .pokemon-external-info {
    width: 45px;
    margin: 0 5px;
  }
  
  .pokemon-external-info.right {
    margin-left: 6px;
  }
  
  .pokemon-external-info.left {
    margin-right: 6px;
  }
  
  .pokemon-external-box {
    padding: 6px 4px;
  }
  
  /* Modification pour l'affichage du niveau */
  .pokemon-level {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
  }
  
  .pokemon-level-label {
    margin-right: 0;
    font-size: 0.65rem;
  }
  
  .pokemon-level-value {
    font-size: 0.9rem;
  }
  
  /* Rendre les conteneurs de Pokémon plus compacts */
  .pokemon-container {
    margin-bottom: 8px;
  }
}