/* ===========================
   || 1. Wrapper principal  ||
   =========================== */
.filter-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px; /* espace entre les étages */
  padding: 0 10px;
}

/* Structure par étage */
.filter-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* Libellé de chaque filtre */
.filter-label {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  color: #aaa;
  margin-bottom: 6px;
  letter-spacing: 1px;
}

/* Groupe de boutons horizontaux */
.filter-section {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  gap: 10px;
  justify-content: center;
}

/* Boutons cliquables (tiers, enchant, villes) */
.filter-button {
  background-color: #222;
  color: #ccc;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
  text-transform: uppercase;
}

/* Survol */
.filter-button:hover {
  background-color: #2d80ff33;
  border-color: #2d80ff;
  color: #fff;
}

/* État actif */
.filter-button.active {
  background-color: #2d80ff;
  color: #fff;
  border-color: #2d80ff;
  box-shadow: 0 0 6px #2d80ff88;
}

.filter-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 10px 18px;
    font-weight: 600;
    font-size: 15px;
    color: #e0e0e0;
    cursor: pointer;
    backdrop-filter: blur(12px);
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
    min-width: 160px;
    text-align: center;
    box-shadow: 0 0 8px rgba(45, 128, 255, 0.08);
}

.filter-toggle:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
    box-shadow: 0 0 10px #2d80ff55;
}

#etage1
{
    gap: 0 20px;
}

#villeFilters, #etage1
{
    justify-content: center;
    align-items: center;
    flex-direction: row;
}

#searchInput {
    padding: 10px 16px;
    font-size: 15px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    color: #e0e0e0;
    font-family: 'Rajdhani', sans-serif;
    width: 220px;
    outline: none;
    box-shadow: inset 0 0 6px rgba(255, 255, 255, 0.05), 0 0 8px rgba(45, 128, 255, 0.08);
    transition: all 0.2s ease;
}

#searchInput::placeholder {
    color: #aaa;
    font-style: italic;
}

#searchInput:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: #2d80ff;
    box-shadow: 0 0 8px #2d80ff55, inset 0 0 4px #2d80ff33;
}

/* Conteneur du menu principal */
.filter-menu {
  display: none;
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(14px);
  padding: 10px;
  z-index: 999;
  box-shadow: 0 0 12px rgba(0,0,0,0.2);
  min-width: 180px;
}

/* Colonne verticale de catégories */
.menu-column {
  display: flex;
  flex-direction: column;
  min-width: 180px;
}

/* Élément de menu cliquable */
.menu-item {
  padding: 8px 12px;
  color: #e0e0e0;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  transition: background 0.2s;
  white-space: nowrap;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Ajoute une flèche pour les sous-menus */
.menu-item.has-children::after {
  content: "▸";
  position: absolute;
  right: 10px;
  top: 8px;
  font-size: 12px;
  opacity: 0.5;
}

/* Sous-menu déroulant */
.submenu-column {
  display: none;
  position: absolute;
  top: 0;
  left: 100%;
  z-index: 1000;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  backdrop-filter: blur(12px);
  padding: 10px;
  box-shadow: 2px 2px 6px rgba(0,0,0,0.2);
}

/* Affichage du sous-menu au survol */
.menu-item:hover > .submenu-column {
  display: flex;
}

.filter-group {
  position: relative; /* ✅ Clé du positionnement local */
  display: flex;
  flex-direction: column;
  align-items: center;
}

.selected-items-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;  /* Centrage horizontal */
    max-width: 90%;
    overflow-x: auto;
}

.selected-item-tag {
    display: flex;
    align-items: center;
    padding: 6px 14px;
    margin: 4px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 18px;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #e0e0e0;
    box-shadow: 0 0 8px rgba(45, 128, 255, 0.15);
    transition: background 0.2s, box-shadow 0.3s;
}

.selected-item-tag:hover {
    background: rgba(45, 128, 255, 0.12);
    box-shadow: 0 0 10px rgba(45, 128, 255, 0.25);
}

.selected-item-tag span {
    margin-right: 8px;
}

.selected-item-tag .remove {
    cursor: pointer;
    font-weight: bold;
    color: #ff6b6b;
    font-size: 16px;
    transition: transform 0.2s, color 0.2s;
}

.selected-item-tag .remove:hover {
    transform: scale(1.2);
    color: #ff4444;
}

.enchant-diamond
{
    display: inline-block;
    width: 5px;       /* largeur + grande */
    height: 5px;       /* hauteur + petite */
    margin: 0 2px;
    transform: rotate(45deg);
    background-color: gray; /* remplacé par .enchant-X */
    vertical-align: middle;
}

/* Couleurs par niveau */
.enchant-1 { background-color: rgb(0, 212, 0); }
.enchant-2 { background-color: rgb(46, 104, 251); }
.enchant-3 { background-color: rgb(187, 2, 187); }
.enchant-4 { background-color: gold; }

.clear-button {
    margin: 0px 0 10px 0;
    padding: 8px 16px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
    color: #ff6b6b;
    font-weight: bold;
    cursor: pointer;
    backdrop-filter: blur(12px);
    box-shadow: 0 0 6px rgba(255, 100, 100, 0.2);
    transition: background 0.2s, box-shadow 0.2s;
}

.clear-button:hover {
    background: rgba(255, 50, 50, 0.12);
    box-shadow: 0 0 10px rgba(255, 50, 50, 0.4);
    color: #fff;
}
#clear-selected-items {
    display: none; /* masqué par défaut */
}

#scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    box-shadow: 0 0 10px rgba(0, 128, 255, 0.25);
    cursor: pointer;
    z-index: 1000;
    display: none;
    transition: background 0.3s, box-shadow 0.3s;
}

#scroll-to-top:hover {
    background: rgba(0, 128, 255, 0.12);
    box-shadow: 0 0 12px rgba(0, 128, 255, 0.5);
}

/* Flèche CSS au centre */
#scroll-to-top::before {
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    border-left: 2px solid white;
    border-top: 2px solid white;
    transform: rotate(45deg);
    position: absolute;
    top: 50%;
    left: 50%;
    margin-left: -6px;
    margin-top: -6px;
}

.no-results-message {
    background: rgba(30, 30, 30, 0.4); /* fond plus sombre et plus opaque */
    color: #ffffff;
    padding: 20px 28px;
    margin: 30px auto;
    max-width: 600px;
    text-align: center;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    box-shadow: 0 0 16px rgba(0, 128, 255, 0.15);
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.4s ease-out;
}


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


@media screen and (max-width: 600px) {
  .filter-button {
    font-size: 12px;
    padding: 5px 10px;
  }

  .filter-label {
    font-size: 12px;
  }
}