/* Réinitialisation et fondamentaux */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Montserrat', sans-serif;
  background: linear-gradient(135deg, #0f1923 0%, #1a2a36 100%);
  color: #e0e0e0;
  line-height: 1.6;
  min-height: 100vh;
}

/* NAVBAR */
.navbar {
  background: rgba(22, 33, 46, 0.95);
  height: 70px;
  padding: 0 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-left {
  display: flex;
  align-items: center;
}

.nav-left img {
  height: 100%;
  max-height: 50px;
  max-width: 180px;
  margin-right: 25px;
  filter: drop-shadow(0 0 5px rgba(79, 190, 255, 0.6));
}

.nav-left a, #createLink, #caseCreatorLink {
  color: #c5c5c5;
  text-decoration: none;
  padding: 14px 20px;
  cursor: pointer;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  position: relative;
  transition: all 0.3s ease;
}

.nav-left a:after, #createLink:after, #caseCreatorLink:after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 8px;
  left: 50%;
  background: #4fbbff;
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav-left a:hover, #createLink:hover, #caseCreatorLink:hover {
  color: #fff;
}

.nav-left a:hover:after, #createLink:hover:after, #caseCreatorLink:hover:after {
  width: 70%;
}

/* PROFIL */
.user-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 30px;
  transition: all 0.3s;
}

.user-wrapper:hover {
  background: rgba(255, 255, 255, 0.15);
}

.user-money {
  color: #4fbbff;
  font-weight: 700;
  margin-right: 5px;
  white-space: nowrap;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(79, 187, 255, 0.6);
  box-shadow: 0 0 10px rgba(79, 187, 255, 0.3);
}

.user-name {
  color: #fff;
  font-weight: 600;
}

.signup {
  color: #fff;
  text-decoration: none;
  padding: 10px 22px;
  cursor: pointer;
  background: linear-gradient(45deg, #4f7bff, #4fbbff);
  border-radius: 30px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.3s;
  box-shadow: 0 4px 15px rgba(79, 190, 255, 0.3);
}

.signup:hover {
  background: linear-gradient(45deg, #3a66ff, #3aa8ff);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 190, 255, 0.4);
}

.dropdown-menu {
  display: none;
  position: absolute;
  right: 20px;
  top: 65px;
  background: rgba(22, 33, 46, 0.98);
  min-width: 200px;
  z-index: 3;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.1);
  animation: fadeDown 0.3s ease-out;
}

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

.dropdown-menu a {
  display: block;
  padding: 12px 20px;
  color: #e0e0e0;
  text-decoration: none;
  transition: all 0.2s;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dropdown-menu a:hover {
  background: rgba(79, 187, 255, 0.15);
  color: #fff;
  padding-left: 25px;
}

/* MODAL (générique) */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(7, 15, 24, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  backdrop-filter: blur(5px);
}

.modal {
  background: linear-gradient(135deg, #16212e 0%, #1e2c3a 100%);
  border-radius: 12px;
  width: 90%;
  max-width: 420px;
  padding: 30px 35px 40px;
  position: relative;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
  animation: modalAppear 0.4s ease-out;
}

@keyframes modalAppear {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.close-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 24px;
  font-weight: bold;
  color: #888;
  cursor: pointer;
  transition: all 0.2s;
}

.close-btn:hover {
  color: #fff;
  transform: rotate(90deg);
}

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

form input, form select {
  padding: 12px 15px;
  margin-bottom: 15px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: #e0e0e0;
  font-size: 1rem;
  transition: all 0.3s;
}

form input:focus, form select:focus {
  outline: none;
  border-color: #4fbbff;
  background: rgba(79, 187, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(79, 187, 255, 0.2);
}

form input::placeholder {
  color: #888;
}

form button {
  padding: 12px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(45deg, #4f7bff, #4fbbff);
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 15px rgba(79, 187, 255, 0.2);
}

form button:hover {
  background: linear-gradient(45deg, #3a66ff, #3aa8ff);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 187, 255, 0.3);
}

/* Tabs inscription/connexion */
.tabs {
  display: flex;
  justify-content: space-around;
  margin-bottom: 25px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tab-btn {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  padding: 15px 0;
  font-size: 1.1rem;
  cursor: pointer;
  color: #888;
  transition: all 0.3s;
  position: relative;
}

.tab-btn.active {
  color: #fff;
  font-weight: bold;
}

.tab-btn.active:after {
  content: '';
  position: absolute;
  width: 50%;
  height: 3px;
  background: #4fbbff;
  bottom: -1px;
  left: 25%;
  border-radius: 3px;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.4s ease-out;
}

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

/* MODAL ADMIN */
.admin-modal {
  background: linear-gradient(135deg, #16212e 0%, #1e2c3a 100%);
  border-radius: 12px;
  padding: 30px 35px;
  width: 360px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
}

.admin-modal h3 {
  margin-top: 0;
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 20px;
  position: relative;
}

.admin-modal h3:after {
  content: '';
  position: absolute;
  width: 40px;
  height: 3px;
  background: #4fbbff;
  left: 0;
  bottom: -8px;
  border-radius: 3px;
}

.admin-modal>div>button {
  margin: 0 8px 20px 0;
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #e0e0e0;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.admin-modal>div>button:hover {
  background: rgba(79, 187, 255, 0.2);
  color: #fff;
  transform: translateY(-2px);
}

/* Cases & Items Grids */
.cases-grid, #itemsList {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.case-item, .item-card {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 15px;
  width: 140px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  background: rgba(255, 255, 255, 0.03);
}

.case-item:hover, .item-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  border-color: rgba(79, 187, 255, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.case-item.selected, .item-card.selected {
  border: 2px solid #4fbbff;
  background: rgba(79, 187, 255, 0.1);
  box-shadow: 0 0 15px rgba(79, 187, 255, 0.3);
}

.case-item img, .item-card img {
  width: 100%;
  height: 90px;
  object-fit: contain;
  transition: all 0.3s;
  filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.3));
}

.case-item:hover img, .item-card:hover img {
  transform: scale(1.05);
}

.add-item-btn {
  width: 90px;
  height: 90px;
  border: 2px dashed rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  margin: 20px auto;
  cursor: pointer;
  border-radius: 10px;
  transition: all 0.3s;
  color: rgba(255, 255, 255, 0.4);
}

.add-item-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(79, 187, 255, 0.5);
  color: #4fbbff;
  transform: scale(1.05);
}

.selected-item {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px;
  width: 110px;
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.3s;
}

.selected-item:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
}

.selected-item img {
  width: 100%;
  height: 70px;
  object-fit: contain;
  filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.3));
}

.remove-item {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ff4444;
  color: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 12px;
  font-weight: bold;
  transition: all 0.2s;
  box-shadow: 0 3px 8px rgba(255, 68, 68, 0.4);
}

.remove-item:hover {
  background: #ff2222;
  transform: scale(1.1);
}

.drop-rate-input {
  width: 80px;
  text-align: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
  border-radius: 5px;
  padding: 5px;
  font-size: 0.9rem;
}

.drop-rate-input:focus {
  outline: none;
  border-color: #4fbbff;
}

.item-summary {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 10px;
}

.item-summary img {
  width: 45px;
  height: 45px;
  object-fit: contain;
  margin-right: 15px;
  filter: drop-shadow(0 5px 8px rgba(0, 0, 0, 0.3));
}

#createCaseItems {
  padding: 12px;
  width: 100%;
  border: none;
  border-radius: 8px;
  background: linear-gradient(45deg, #4f7bff, #4fbbff);
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 20px;
  box-shadow: 0 4px 15px rgba(79, 187, 255, 0.2);
}

#createCaseItems:hover:not(:disabled) {
  background: linear-gradient(45deg, #3a66ff, #3aa8ff);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 187, 255, 0.3);
}

#createCaseItems:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.spinner-marker{
  pointer-events:none;
}

#itemSearch {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
  border-radius: 8px;
  padding: 12px 15px;
  font-size: 1rem;
  width: 100%;
  margin-bottom: 15px;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.1);
}

#itemSearch:focus {
  outline: none;
  border-color: #4fbbff;
  box-shadow: 0 0 0 3px rgba(79, 187, 255, 0.2);
}

/* Dans votre CSS */
.games-section {
  padding: 30px;
  margin-top: 20px;
}

.game-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 colonnes */
  grid-template-rows: repeat(2, 1fr);    /* 2 rangées */
  gap: 30px;                             /* Espace plus large entre les cartes */
  max-width: 1000px;                     /* Container plus large */
  margin: 0 auto;
  height: 600px;                         /* Container plus haut */
}

/* Ajoutez ces styles CSS */
.game-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.game-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
  opacity: 0.8; /* Légèrement transparent pour que le texte reste visible */
  transition: opacity 0.3s ease;
}

.game-title {
  position: relative;
  z-index: 2;
  color: #4fbbff;
  font-size: 2rem;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
  margin-bottom: 15px;
}

/* Effet au survol */
.game-card:hover {
  transform: translateY(-5px);
}

.game-card:hover .game-image {
  opacity: 1;
}

.game-modal {
  display: none;
}

.game-content {
  min-height: 200px;
}

    /* Style amélioré pour JetX avec centrage optimal */
    #gameModal2 .modal {
      max-width: 400px;
      background-color: #1a2642;
      color: white;
      border-radius: 8px;
      padding: 20px;
      text-align: center;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 90%;
    }
    
    #gameModal2 h2 {
      font-size: 24px;
      margin-bottom: 20px;
      text-align: center;
    }
    
    #jetxCanvas {
      width: 100%;
      height: 200px;
      background-color: #0c1426;
      margin: 15px 0;
      border-radius: 5px;
    }
    
    .game-content {
      display: flex;
      flex-direction: column;
      align-items: center;
      width: 100%;
    }
    
    .bet-controls {
      display: flex;
      width: 100%;
      justify-content: center;
      margin: 10px 0 20px 0;
      gap: 5px;
    }
    
    #betAmount {
      width: 80px;
      padding: 8px;
      border: 1px solid #2a3a5a;
      background-color: #121a2f;
      color: white;
      border-radius: 4px;
    }
    
    #placeBetBtn, #cashoutBtn {
      padding: 8px 15px;
      border: none;
      border-radius: 4px;
      font-weight: bold;
      cursor: pointer;
    }
    
    #placeBetBtn {
      background-color: #4CAF50;
      color: white;
    }
    
    #cashoutBtn {
      background-color: #BF360C;
      color: white;
    }
    
    #cashoutBtn:disabled {
      opacity: 0.6;
      cursor: not-allowed;
    }
    
    #multiplier {
      font-size: 24px;
      font-weight: bold;
      color: #FFD700;
      margin: 10px 0;
    }
    
    .balance-amount, .potential-win-amount {
      font-weight: bold;
    }
    
    #gameStatus {
      color: #aaa;
      font-size: 14px;
      margin-bottom: 10px;
    }
    
    .history-section h3 {
      margin-top: 15px;
      margin-bottom: 10px;
      font-size: 18px;
      width: 100%;
    }
    
    .history-container {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 8px;
      width: 100%;
    }
    
    .history-item {
      padding: 5px 8px;
      border-radius: 4px;
      font-size: 12px;
      font-weight: bold;
    }
    
    .low-multiplier { background-color: #F44336; }
    .medium-multiplier { background-color: #FF9800; }
    .high-multiplier { background-color: #4CAF50; }
    
    /* Styles pour s'assurer que la modal overlay est correctement positionnée */
    .modal-overlay.game-modal {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(0, 0, 0, 0.8);
      display: flex;
      justify-content: center;
      align-items: center;
      z-index: 1000;
    }
    
    /* Assurez-vous que le bouton de fermeture est visible et bien positionné */
    .close-btn {
      position: absolute;
      top: 10px;
      right: 15px;
      font-size: 24px;
      color: white;
      cursor: pointer;
    }
    .modal-overlay, .game-modal {
      display: none;
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(0, 0, 0, 0.7);
      z-index: 1000;
      justify-content: center;
      align-items: center;
    }

    /* ============ CASE-OPENING ============ */

/* -------- Latest Drops Banner -------- */
.latest-drops-banner{
  display:flex;
  overflow-x:auto;
  gap:18px;
  padding:15px 25px;
  background:rgba(255,255,255,.03);
  border-bottom:1px solid rgba(255,255,255,.05);
  scrollbar-width:none;
}
.latest-drops-banner::-webkit-scrollbar{display:none}

.drop-card{
  flex:0 0 auto;
  display:flex;
  align-items:center;
  gap:12px;
  background:rgba(22,33,46,.9);
  border:1px solid rgba(255,255,255,.08);
  border-radius:10px;
  padding:8px 14px;
  box-shadow:0 6px 15px rgba(0,0,0,.25);
  transition:transform .3s;
}
.drop-card:hover{transform:translateY(-4px)}
.drop-card img{
  width:55px;
  height:55px;
  object-fit:contain;
  filter:drop-shadow(0 4px 8px rgba(0,0,0,.4));
}
.drop-info{
  display:flex;
  flex-direction:column;
  font-size:.78rem;
}
.drop-name{color:#fff;font-weight:600;line-height:1.2}
.drop-price{color:#4fbbff;font-weight:700}
.drop-user{color:#888;font-size:.7rem}

/* -------- Section Titles -------- */
.section-title{
  margin:35px 0 15px;
  padding-left:25px;
  font-size:1.4rem;
  font-weight:700;
  color:#fff;
  position:relative;
}
.section-title:before{
  content:'';
  position:absolute;
  left:0;
  top:50%;
  width:6px;
  height:70%;
  background:#4fbbff;
  border-radius:3px;
  transform:translateY(-50%);
}

/* -------- Latest Cases Grid -------- */
#latestCases,
#caseCategories{
  display:flex;
  flex-wrap:wrap;
  gap:22px;
  padding:0 25px;
}
.case-card{
  width:150px;
  padding:15px;
  border:1px solid rgba(255,255,255,.08);
  border-radius:12px;
  background:rgba(255,255,255,.03);
  text-align:center;
  cursor:pointer;
  transition:all .3s;
}
.case-card:hover{
  transform:translateY(-6px);
  box-shadow:0 10px 20px rgba(0,0,0,.3);
  border-color:rgba(79,187,255,.4);
}
.case-card img{
  width:100%;
  height:95px;
  object-fit:contain;
  filter:drop-shadow(0 5px 12px rgba(0,0,0,.35));
  transition:transform .25s;
}
.case-card:hover img{transform:scale(1.05)}
.case-name{
  margin-top:8px;
  font-size:.9rem;
  font-weight:600;
  color:#e0e0e0;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

/* -------- Case-Open Modal -------- */
.case-open-modal{
  max-width:760px;
  width:95%;
  padding:30px 35px;
}
.case-open-body{
  display:flex;
  flex-wrap:wrap;
  gap:25px;
}
.case-open-img{
  width:260px;
  height:260px;
  object-fit:contain;
  flex:0 0 auto;
  filter:drop-shadow(0 8px 18px rgba(0,0,0,.4));
}
.case-open-info{
  flex:1 1 0;     /* peut grandir ET rétrécir */
  min-width:0;    /* autorise la réduction si le contenu est large */
}
.price-line{
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:15px;
}
#caseOpenPrice{
  font-size:1.4rem;
  font-weight:700;
  color:#4fbbff;
}
#caseOpenQty{
  padding:8px 10px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.1);
  color:#e0e0e0;
  border-radius:6px;
  font-weight:600;
}
#openCaseBtn{
  padding:10px 22px;
  border:none;
  border-radius:8px;
  background:linear-gradient(45deg,#4f7bff,#4fbbff);
  color:#fff;
  font-weight:700;
  cursor:pointer;
  box-shadow:0 4px 15px rgba(79,187,255,.25);
  transition:all .3s;
}
#openCaseBtn:hover{
  transform:translateY(-2px);
  box-shadow:0 8px 25px rgba(79,187,255,.35);
}
.case-items-list{
  flex:1;
  max-height:340px;
  overflow:auto;
  padding-right:6px;      /* for scrollbar */
}
.case-items-list::-webkit-scrollbar{
  width:6px;
}
.case-items-list::-webkit-scrollbar-thumb{
  background:#4fbbff;
  border-radius:3px;
}
.case-item-line{
  display:flex;
  align-items:center;
  gap:14px;
  padding:10px 0;
  border-bottom:1px solid rgba(255,255,255,.05);
  font-size:.9rem;
}
.case-item-line img{
  width:48px;
  height:48px;
  object-fit:contain;
}
.case-item-line span:nth-child(2){
  flex:1;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  color:#e0e0e0;
}
.case-item-line span:last-child{
  font-weight:600;
  color:#4fbbff;
}

/* -------- Drop Result Modal -------- */
.drop-result-modal{
  position:fixed;
  inset:0;
  background:rgba(7,15,24,.8);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:1001;
}
.drop-result{
  background:linear-gradient(135deg,#16212e 0%,#1e2c3a 100%);
  border-radius:12px;
  padding:30px 45px 40px;
  text-align:center;
  border:1px solid rgba(255,255,255,.1);
  box-shadow:0 25px 50px rgba(0,0,0,.35);
  animation:modalAppear .4s ease-out;
}
.drop-result img{
  width:220px;
  height:220px;
  object-fit:contain;
  margin-bottom:20px;
  filter:drop-shadow(0 10px 20px rgba(0,0,0,.4));
}
.drop-result h3{
  font-size:1.3rem;
  color:#fff;
  margin-bottom:8px;
}
.drop-result p{
  font-size:1rem;
  color:#4fbbff;
  margin-bottom:25px;
  font-weight:600;
}
.drop-result button{
  padding:12px 28px;
  margin:0 10px;
  border:none;
  border-radius:8px;
  background:#4fbbff;
  color:#0f1923;
  font-weight:700;
  cursor:pointer;
  transition:all .25s;
}
.drop-result button:first-of-type{background:#4CAF50}
.drop-result button:hover{transform:translateY(-3px)}
@media(max-width:600px){
  .case-open-body{justify-content:center;text-align:center}
  .case-open-img{width:200px;height:200px}
  .case-items-list{max-height:280px}
}

/* === roulette façon CS :GO === */
.case-spinner {
  position: relative;
  width: 100%;
  height: 55px; /* Hauteur réduite */
  overflow: hidden;
  background: rgba(255,255,255,.02);
  border: 1px solid rgba(255,255,255,.05);
  border-radius: 8px;
  margin-bottom: 6px; /* Espace réduit entre les roulettes */
}

.spinner-track {
  display: flex;
  align-items: center;
  height: 100%;
  will-change: transform;
  transition: transform 4s cubic-bezier(.08, .60, 0, 1);
}

.spinner-item img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.3));
}

.spinner-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 3px;
  background: #4fbbff;
  transform: translateX(-50%);
  box-shadow: 0 0 8px rgba(79,187,255,.7);
}

.result-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.85);
  padding: 6px 10px;
  border-radius: 8px;
  text-align: center;
  color: white;
  z-index: 2;
  font-size: 0.75rem;
}

.result-overlay h3 {
  font-size: 0.85rem;
  margin: 2px 0;
}

.result-overlay p {
  margin: 2px 0 6px 0;
  font-size: 0.75rem;
  color: #ccc;
}

.result-overlay button {
  margin: 2px;
  padding: 4px 8px;
  border: none;
  border-radius: 6px;
  font-weight: bold;
  font-size: 0.75rem;
  cursor: pointer;
}

.result-overlay button:first-of-type {
  background: #4CAF50;
  color: white;
}

.result-overlay button:last-of-type {
  background: #f80;
  color: white;
}




/* === INVENTAIRE SECTION === */
#inventorySection {
  padding: 30px;
  display: none;
  animation: fadeIn 0.5s ease-in-out;
}

#inventorySection h2 {
  font-size: 1.6rem;
  margin-bottom: 15px;
  color: #fff;
}

#inventorySort {
  padding: 10px 15px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
  border-radius: 8px;
  margin-bottom: 20px;
  font-weight: 600;
  font-size: 1rem;
}

.inventory-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

/* === ITEM INVENTAIRE === */
.inventory-item {
  width: 120px;
  text-align: center;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px;
  transition: all 0.3s;
}

.inventory-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  border-color: rgba(79, 187, 255, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.inventory-item img {
  width: 100%;
  height: 90px;
  object-fit: contain;
  margin-bottom: 8px;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.3));
}

.inventory-item div {
  font-size: 0.85rem;
  color: #e0e0e0;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* === MODALE INVENTAIRE === */
#inventoryModal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(7, 15, 24, 0.85);
  backdrop-filter: blur(4px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

#inventoryModal .modal-content {
  background: linear-gradient(135deg, #16212e 0%, #1e2c3a 100%);
  border-radius: 12px;
  padding: 30px 35px 40px;
  width: 320px;
  text-align: center;
  color: #e0e0e0;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.1);
  animation: modalAppear 0.4s ease-out;
}

#inventoryModal img {
  width: 160px;
  height: 160px;
  object-fit: contain;
  margin-bottom: 15px;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.4));
}

#inventoryModal h3 {
  font-size: 1.3rem;
  color: #fff;
  margin-bottom: 10px;
}

#inventoryModal p {
  font-size: 1rem;
  color: #4fbbff;
  font-weight: 600;
  margin-bottom: 25px;
}

#inventoryModal button {
  padding: 10px 20px;
  margin: 0 10px;
  border: none;
  border-radius: 8px;
  background: #4fbbff;
  color: #0f1923;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
}

#inventoryModal button:hover {
  transform: translateY(-2px);
  background: #3aa8ff;
}

#closeInventoryModal {
  position: absolute;
  top: 12px;
  right: 18px;
  font-size: 22px;
  color: #999;
  cursor: pointer;
  transition: all 0.3s;
}

#closeInventoryModal:hover {
  color: #fff;
  transform: rotate(90deg);
}

/* ========== MULTI-ROULETTES ========== */

#caseSpinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
  height: auto; /* Pour s'adapter dynamiquement */
  margin-top: 15px;
}

/* Chaque roulette affichée */
.case-spinner {
  position: relative;
  width: 100%;
  height: 130px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
}

.spinner-track {
  display: flex;
  align-items: center;
  height: 100%;
  will-change: transform;
  transition: transform 4s cubic-bezier(.08, .60, 0, 1);
}

.spinner-item {
  flex: 0 0 140px;
  text-align: center;
}

.spinner-item img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.35));
}

.spinner-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background: #4fbbff;
  transform: translateX(-50%);
  box-shadow: 0 0 10px rgba(79, 187, 255, 0.8);
}

