.app-sidebar-menu {
  background-color: #228b22;
}

:root {
  --bs-success: #228b22 !important;
  --orange-base: #fd7e14;
  --orange-dark: #e66f10;
}

.app-sidebar-menu .menu-icon {
  color: #fff !important;
}

.app-sidebar-menu .menu-title {
  color: #fff !important;
}
.svg-icon .bi {
  color: white !important;
}
.app-login {
  /* DA SISTEMARE */
  background-image: url("../../..//images/bg_mediquadro.JPG");
}

.th_sottotitolo {
  background-color: #eee;
  padding: 8px 15px;
  margin-bottom: 7px;
  margin-top: 15px;
}

.th_sottotitolo h5 {
  margin-bottom: 0;
}

/* Checkbox stile “quasi default” ma con border-radius */
.picking-item,
#check_all_picking {
  -webkit-appearance: none;
  appearance: none;

  width: 18px;
  height: 18px;
  cursor: pointer;

  border: 1px solid #6c757d; /* colore bordo simile a quello nativo */
  border-radius: 3px; /* leggero arrotondamento */
  background-color: #fff;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15); /* leggerissimo effetto default */

  display: inline-flex;
  align-items: center;
  justify-content: center;

  transition: background-color 0.15s ease, border-color 0.15s ease,
    box-shadow 0.15s ease;
}

/* Hover */
.picking-item:hover,
#check_all_picking:hover {
  border-color: #198754;
}

/* Checked */
.picking-item:checked,
#check_all_picking:checked {
  background-color: #198754;
  border-color: #198754;
  box-shadow: none;
}

/* Spunta */
.picking-item:checked::after,
#check_all_picking:checked::after {
  content: "";
  width: 8px;
  height: 4px;
  border: solid white;
  border-width: 0 0 2px 2px;
  transform: rotate(-45deg);
}

/* intestazione armadio sopra la griglia */
.mediquadro-grid-header-row {
  display: flex;
  justify-content: flex-start;
  margin: 0 0 2px 0;
}

/* etichetta armadio: stesso look delle intestazioni, ma a “barra” */
.mediquadro-grid-header {
  background: #e9ecef;
  color: #212529;
  font-weight: 600;
  font-size: var(--font-s);
  padding: 4px 10px;
  border-radius: 4px 4px 0 0;
  border: 1px solid #dee2e6;
  border-bottom: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

#picking-selected-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  min-height: 1.5rem;
}

.badge-picking {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.6rem;
  font-size: 0.75rem;
  border-radius: 999px;
  background-color: #f3f4f6;
  border: 1px solid #e1e4ea;
  color: #495057;
  font-weight: 500;
}

.badge-picking:hover {
  background-color: #e7eaf0;
}

.pagination-picking .page-link {
  min-width: 3rem;
  text-align: center;
  padding-left: 1rem;
  padding-right: 1rem;
}

.pagination-picking .page-item.active .page-link {
  background-color: var(--bs-primary);
  border-color: var(--bs-primary);
  color: #fff;
}

.pagination-picking .page-item:not(.active):not(.disabled) .page-link:hover {
  background-color: rgba(13, 110, 253, 0.08);
}

.btn-orange {
  color: #fff !important;
  background-color: var(--orange-base) !important;
  border-color: var(--orange-base) !important;
}

.btn-orange i {
  color: #fff !important;
}

.btn-orange:hover {
  background-color: var(--bs-orange) !important;
  border-color: var(--bs-orange) !important;
  color: #fff !important;
}

.btn-orange:hover i {
  color: #fff !important;
}

.btn-orange:focus,
.btn-orange:focus-visible {
  box-shadow: 0 0 0 0.25rem rgba(253, 126, 20, 0.5);
}

.btn-orange:active {
  background-color: var(--orange-dark) !important;
  border-color: var(--orange-dark) !important;
}

/* INIZIO DETTAGLIO CASSETTO */

.blocchetti-container {
  padding: 8px;
  max-width: 1200px;
  margin: 0 auto;
  height: 100vh;
  overflow-y: auto;
  position: relative;
}
.blocchetti-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}
@media (min-width: 768px) {
  .blocchetti-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(20, minmax(0, auto));
    grid-auto-flow: column; /* riempie 1..20 nella prima colonna, 21..40 nella seconda */
  }
}
.blocchetto-item {
  position: relative;
  background: #ffffff;
  border-left: 3px solid;
  border-radius: 4px;
  padding: 6px 10px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 32px;
  font-size: 13px;
}
.blocchetto-item:hover {
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.12);
  transform: translateY(-0.5px);
}
.blocchetto-item.stato-0 {
  border-left-color: #6c757d;
  background-color: #f8f9fa;
  cursor: default;
}
.blocchetto-item.stato-1 {
  border-left-color: #198754;
  background-color: #d1f4e0;
  cursor: pointer;
}
.blocchetto-item.stato-2 {
  border-left-color: #dc3545;
  background-color: #fde8ea;
  cursor: pointer;
}
.blocchetto-item.stato-3 {
  border-left-color: #ffc107;
  background-color: #fff3cd;
  cursor: pointer;
}
.blocchetto-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.blocchetto-numero {
  font-size: 12px;
  font-weight: 700;
  color: #212529;
  min-width: 22px;
}
.blocchetto-codice {
  font-size: 12px;
  color: #495057;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

/* FINE DETTAGLIO CASSETTO */




/* =========================================
   BASE: input, select, textarea
   (esclusi checkbox / radio)
   ========================================= */

.readonly input:not([type="checkbox"]):not([type="radio"]),
.readonly select,
.readonly textarea,
input.readonly:not([type="checkbox"]):not([type="radio"]),
select.readonly,
textarea.readonly {
    background-color: #e9ecef !important;  /* come .form-control[disabled] */
    color: #6c757d !important;
    border-color: #ced4da !important;
    cursor: not-allowed !important;
    pointer-events: none !important;       /* blocca click, scroll wheel ecc. */
}

/* niente focus “attivo” */
.readonly input:focus,
.readonly select:focus,
.readonly textarea:focus,
input.readonly:focus,
select.readonly:focus,
textarea.readonly:focus {
    box-shadow: none !important;
    outline: 0 !important;
}

/* =========================================
   INPUT NUMBER: blocco freccette e scroll
   ========================================= */

/* WebKit: rimuove spin buttons */
.readonly input[type="number"]::-webkit-inner-spin-button,
.readonly input[type="number"]::-webkit-outer-spin-button,
input[type="number"].readonly::-webkit-inner-spin-button,
input[type="number"].readonly::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox: stile textfield */
.readonly input[type="number"],
input[type="number"].readonly {
    -moz-appearance: textfield;
    pointer-events: none !important; /* niente click/scroll */
    touch-action: none !important;
}

/* =========================================
   CHECKBOX & RADIO (inclusi Bootstrap .form-check-input)
   ========================================= */

/* blocco dell’input vero e proprio */
.readonly .form-check-input,
.form-check-input.readonly,
.readonly input[type="checkbox"],
.readonly input[type="radio"],
input[type="checkbox"].readonly,
input[type="radio"].readonly {
    cursor: not-allowed !important;
    pointer-events: none !important;  /* niente click sull’input */
    opacity: 1 !important;            /* stato sempre ben visibile */
}

/* blocco click sul label associato (che altrimenti toggle-a l’input) */
.readonly .form-check-label,
.form-check-label.readonly,
.readonly label[for],
label.readonly[for] {
    cursor: default !important;
    pointer-events: none !important;
}

/* stato NON selezionato: grigio ma leggibile */
.readonly .form-check-input:not(:checked),
.form-check-input.readonly:not(:checked),
.readonly input[type="checkbox"]:not(:checked),
.readonly input[type="radio"]:not(:checked),
input[type="checkbox"].readonly:not(:checked),
input[type="radio"].readonly:not(:checked) {
    background-color: #f8f9fa !important;
    border-color: #ced4da !important;
}

/* stato SELEZIONATO: ancora ben distinto ma meno “attivo” */
.readonly .form-check-input:checked,
.form-check-input.readonly:checked,
.readonly input[type="checkbox"]:checked,
.readonly input[type="radio"]:checked,
input[type="checkbox"].readonly:checked,
input[type="radio"].readonly:checked {
    background-color: #6c757d !important; /* grigio Bootstrap */
    border-color: #6c757d !important;
}

/* =========================================
   SELECT2 + tema Bootstrap 5
   ========================================= */

.readonly .select2-container--bootstrap5 .select2-selection,
.select2-container--bootstrap5 .select2-selection.readonly {
    background-color: #e9ecef !important;
    color: #6c757d !important;
    border-color: #ced4da !important;
    pointer-events: none !important;  /* niente click sulla selezione */
    cursor: not-allowed !important;
}

/* testo interno */
.readonly .select2-container--bootstrap5 .select2-selection__rendered {
    color: #6c757d !important;
}

/* freccia: solo resa “spenta” */
.readonly .select2-container--bootstrap5 .select2-selection__arrow {
    opacity: 0.5 !important;
    pointer-events: none !important;
}

/* campo di ricerca dentro il dropdown (nel caso in cui fosse aperto) */
.readonly .select2-container--bootstrap5 .select2-search__field {
    pointer-events: none !important;
}

/* =========================================
   Variante: classe direttamente sul controllo
   (utile se non è dentro .readonly)
   ========================================= */

.select2-container--bootstrap5.readonly .select2-selection {
    background-color: #e9ecef !important;
    color: #6c757d !important;
    border-color: #ced4da !important;
    pointer-events: none !important;
    cursor: not-allowed !important;
}


input[type="number"][readonly] {
    background-color: #e9ecef !important; /* stesso stile dei disabled */
    color: #6c757d !important;
    border-color: #ced4da !important;
    cursor: not-allowed !important;
    pointer-events: none !important; /* impedisce click + rotellina */
    -moz-appearance: textfield !important; /* Firefox */
    touch-action: none !important;
}

/* WebKit – rimozione spin buttons */
input[type="number"][readonly]::-webkit-inner-spin-button,
input[type="number"][readonly]::-webkit-outer-spin-button {
    -webkit-appearance: none !important;
    margin: 0;
}

/* Rimozione focus attivo */
input[type="number"][readonly]:focus {
    box-shadow: none !important;
    outline: 0 !important;
}