/* ============================
   🔹 VERSION DÉSTOP — GRILLE
   ============================ */

.pxn-grid-dropdown {
  display: none;
}

.pxn-grid-icons {
  display: block;
}

.pxn-grid-item {
  display: inline-block;
  position: relative;
  margin: 6px 6px 0 0;
  background: #fff;
  box-shadow: 0 0 2px #ccc;
  border-radius: 5px;
  height: 32px;
  overflow: hidden;
  cursor: pointer;
  text-align: center;
  vertical-align: middle;
}

.pxn-grid-item.has-icon{
  width: 32px;
}

.pxn-grid-item.has-text{
  min-width: 200px;
}

/* le lien couvre toute la surface */
.pxn-grid-item a {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
  text-decoration: none;
  border-radius: inherit;
}

/* image ou icône centrée */
.pxn-grid-item img {
  width: 24px;
  height: 24px;
  display: block;
  z-index: 2;
  /* pointer-events: none; /* permet le clic à travers */
}

/* si pas d'image : label centré */
.pxn-grid-label {
  font-size: 12px;
  color: #333;
  display: inline-block;
  padding: 5px;
  line-height: 1.1em;
  text-align: center;
  white-space: nowrap;
}

/* effet hover */
.pxn-grid-item:hover {
  box-shadow: 0 0 8px #5873ff;
}

/* ============================
   🔹 VERSION MOBILE — DROPDOWN
   ============================ */

@media (max-width: 767px) {

  .pxn-grid-icons {
    display: none !important;
  }

  .pxn-grid-dropdown {
    position: relative;
    display: inline-block !important;
    width: 100%;
    max-width: 300px;
    font-family: sans-serif;
    color: #333;
  }

  .pxn-grid-dropdown-toggle {
    width: 100%;
    padding: 10px 14px;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .pxn-grid-arrow {
    font-size: 12px;
    transition: transform 0.2s;
  }

  .pxn-grid-dropdown.open .pxn-grid-arrow {
    transform: rotate(180deg);
  }

  .pxn-grid-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    max-height: 250px;
    overflow-y: auto;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 999;
    display: none;
  }

  .pxn-grid-dropdown.open .pxn-grid-dropdown-menu {
    display: block;
  }

  .pxn-grid-dropdown-item {
    padding: 5px 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .pxn-grid-dropdown-item:hover {
    background-color: #e6edff;
  }

  .pxn-grid-dropdown-item span {
    padding-left: 5px;
    color: #000;
    vertical-align: middle;
	font-size:14px;
  }

  .pxn-grid-dropdown-item img.icon-dropdown {
    width: 24px;
    height: 24px;
    object-fit: contain;
    vertical-align: middle;
  }
}
