:root{
  --bg:#0b0f18; --panel:#0f1720; --accent:#ff6b6b; --muted:#94a3b8;
  --glass: rgba(255,255,255,0.03);
  font-family: Inter, Arial, sans-serif;
}
*{box-sizing:border-box}
body{margin:0;min-height:100vh;background:linear-gradient(180deg,#061025,#071226);color:#e9f0fb}
.topnav{display:flex;gap:18px;padding:12px 20px;background:rgba(0,0,0,0.2)}
.topnav a{color:#e9f0fb;text-decoration:none;font-weight:600}
.container{padding:16px;max-width:980px;margin:0 auto}
.panel{background:var(--panel);padding:16px;border-radius:12px;margin-bottom:12px;box-shadow:0 8px 24px rgba(2,6,23,0.6)}
.stats{font-weight:700}
.controls{
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
  flex-wrap: wrap; /* Ajouté pour permettre le retour à la ligne sur mobile */
}
button{background:linear-gradient(90deg,var(--accent),#ff9a9a);border:none;padding:8px 12px;border-radius:8px;color:#111;font-weight:700;cursor:pointer}
button:disabled{opacity:0.5;cursor:not-allowed}
.muted{color:var(--muted);font-size:13px;margin-top:8px}
.arena-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-top:10px}
.slot{height:110px;border-radius:10px;background:var(--glass);display:flex;align-items:center;justify-content:center;position:relative;border:1px solid rgba(255,255,255,0.03);cursor:pointer}
.monster{display:flex;flex-direction:column;align-items:center;justify-content:center;border-radius:8px;color:#000;font-weight:800;box-shadow:0 6px 16px rgba(2,6,23,0.5)}
.monster .lv{font-size:12px;opacity:0.8;margin-top:6px}
.selected{outline:3px solid rgba(123,97,255,0.22);box-shadow:0 8px 24px rgba(123,97,255,0.06)}
.small{font-size:12px;color:var(--muted)}

/* --- Styles Spécifiques aux Boutons de Fin de Partie --- */

#gameOverBtn {
  background-color: #d9534f; /* Rouge vif pour le Game Over */
  color: white; 
  padding: 10px 16px;
  font-weight: bold;
}

#purgeBtn {
  background-color: #3b82f6; /* Bleu pour la Purge */
  color: white;
  padding: 10px 16px;
  font-weight: bold;
}

@media(max-width:720px){ .arena-grid{grid-template-columns:repeat(3,1fr)} .slot{height:90px} }
