/* =====================================================
   MERCH — CSS COMPLETO (pulito, stabile, tuoi colori)
===================================================== */

/* ---------- Page width: 800px solo desktop
@media (min-width: 861px){
  .merch-page .page-content{ max-width: 800px; }
}
---------- */
/* ---------- Grid ---------- */
.grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
@media (max-width: 980px){
  .grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px){
  .grid{ grid-template-columns: 1fr; }
}

/* ---------- Card ---------- */
.item{
  background:#050505;
  border:1px solid #151515;
  border-radius:16px;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  box-shadow: 0 4px 16px rgba(0,0,0,.35);
}

.thumb{
  aspect-ratio: 4 / 3;
  background:#000;
  overflow:hidden;
}
.thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

/* ---------- Inner ---------- */
.pad{
  padding: 14px 16px 16px;
  display:flex;
  flex-direction:column;
  flex: 1 1 auto;
}

/* titolo + sottotitolo (attaccati, niente righe strane) */
.title-block{
  display:flex;
  flex-direction:column;
  gap:0;
}
.title-block h3{
  margin:0;
  line-height:1.15;
  font-size: 1.02rem;
  font-weight: 800;
}
.subtitle{
  margin:0;
  line-height:1.15;
  font-size:0.9rem;
  opacity:.75;
}

/* riga badge + prezzo */
.card-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-top:14px; /* spazio sotto subtitle */
}
.price{
  font-weight:900;
  font-size:1.08rem;
  letter-spacing:.02em;
  font-variant-numeric: tabular-nums;
}

/* riga pulsanti (spazio vero prima dei pulsanti) */
.actions{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  width:100%;
  margin-top:16px;
  padding-top:14px;
  border-top:1px solid rgba(255,255,255,.06);
}

/* =====================================================
   BADGE (tieni i tuoi colori)
===================================================== */
.badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  border: 1px solid currentColor;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  line-height: 1;
  white-space: nowrap;
}

/* OUT OF STOCK (rosso) */
.badge.oos{
  border-color: rgba(239,68,68,.55);
  background: rgba(239,68,68,.10);
  color: rgba(255,255,255,.85);
}

/* AVAILABLE (verde) */
.badge.available{
  border-color: rgba(34,197,94,.55);
  background: rgba(34,197,94,.10);
  color: rgba(255,255,255,.90);
}

/* COMING SOON (verde scuro come nel tuo output) */
.badge.coming{
  border-color: rgba(34,197,94,.35);
  background: rgba(34,197,94,.06);
  color: rgba(255,255,255,.80);
  letter-spacing: .06em;
}

/* =====================================================
   BUTTONS (tieni i tuoi colori)
   - tipografia ACQUISTA = PRE-ORDER (stesso timbro)
===================================================== */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  border:1px solid transparent;
  cursor:pointer;
  user-select:none;
  text-decoration:none;
  line-height:1;
}

/* CTA style comune (preorder + acquista): stesso timbro */
.btn.primary,
.btn.preorder{
  padding:0.45rem 0.85rem;
  font-weight:900;
  letter-spacing:.06em;
  text-transform:uppercase;
  font-size:.78rem;
}

/* ACQUISTA (azzurro come screenshot) */
.btn.primary{
  background:#6ec6ff;
  border-color:#6ec6ff;
  color:#0b0b0b;
}
.btn.primary:hover{
  background:#4db8ff;
  border-color:#4db8ff;
}

/* PRE-ORDER (viola come screenshot) */
.btn.preorder{
  background:#d79bff;
  border-color:#d79bff;
  color:#111;
}
.btn.preorder:hover{
  background:#c07aff;
  border-color:#c07aff;
}

/* ACQUISTA disabilitato (sempre visibile) */
.btn.primary.disabled{
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.15);
  color: rgba(255,255,255,.45);
  cursor: not-allowed;
}
.btn.primary.disabled:hover{
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.15);
}

/* INFO button: i piccola corsiva */
.btn.info{
  width:34px;
  height:34px;
  padding:0;
  border-radius:999px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.14);
  display:flex;
  align-items:center;
  justify-content:center;
  /* blocca eredità tipografica se .btn ha uppercase altrove */
  text-transform:none !important;
  font-size:0 !important;
}
.btn.info:hover{
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.20);
}
.info-icon{
  font-family: Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: 1rem;
  color: rgba(255,255,255,.65);
  line-height: 1;
  transform: translateY(-1px);
}

/* =====================================================
   MODAL
===================================================== */
#ovl{
  position:fixed;
  inset:0;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(2px);
  display:none;
  z-index:9998;
}

#mdl{
  position:fixed;
  top:50%;
  left:50%;
  transform: translate(-50%,-50%);
  width: min(900px, 92vw);
  max-height: 86vh;
  background:#0c0c0c;

  /* contorno visibile (neutro, non rosso, non “blu”) */
  border: 1px solid rgba(255,255,255,.26);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.08),
    0 20px 60px rgba(0,0,0,.7);

  border-radius:16px;
  display:none;
  z-index:9999;
}

#mdl header{
  display:flex;
  justify-content:space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom:1px solid rgba(255,255,255,.10);
  background:#151515;
}

#mdl .modal-body{
  display:grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 16px;
  padding: 16px 18px 18px;
}
@media (max-width:720px){
  #mdl .modal-body{ grid-template-columns: 1fr; }
}

/* immagine modale 1:1 */
.modal-image{
  width:100%;
  aspect-ratio: 1 / 1;
  border-radius:10px;
  overflow:hidden;
  background:#000;
  border:1px solid rgba(255,255,255,.10);
}
.modal-image img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

/* testo modale giustificato */
#modalDesc{
  text-align: justify;
  text-justify: inter-word;
  line-height: 1.6;
  hyphens: auto;
  -webkit-hyphens: auto;
}


/* SOLO desktop largo 
@media (min-width: 1200px){
  .merch-page .page-content{
    max-width: 1320px;
  }
}*/