/* ── Botones galería y detalles en la card ──────────────────── */
.p-card-actions { display:flex; gap:5px; margin-bottom:6px; }
.btn-ver-fotos {
  flex:1; background:rgba(0,242,254,.1); border:1px solid rgba(0,242,254,.3);
  color:#00f2fe; border-radius:8px; padding:6px 4px; font-size:10px;
  cursor:pointer; font-family:inherit; transition:background .2s; white-space:nowrap;
}
.btn-ver-fotos:hover { background:rgba(0,242,254,.2); }
.btn-ver-detalles {
  flex:1; background:rgba(255,255,255,.06); border:1px solid rgba(255,255,255,.12);
  color:rgba(255,255,255,.75); border-radius:8px; padding:6px 4px; font-size:10px;
  cursor:pointer; font-family:inherit; transition:background .2s; white-space:nowrap;
}
.btn-ver-detalles:hover { background:rgba(255,255,255,.12); }

/* ── Modal overlay ──────────────────────────────────────────── */
#product-modal-overlay {
  display:none; position:fixed; inset:0; background:rgba(0,0,0,.8);
  z-index:2000; align-items:center; justify-content:center; padding:12px;
}
#product-modal-overlay.open { display:flex; }

.pm-box {
  background:#1a0b3b; border-radius:16px; width:100%; max-width:480px;
  max-height:92vh; display:flex; flex-direction:column;
  border:1px solid rgba(255,255,255,.12); overflow:hidden;
}
.pm-header {
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 16px; border-bottom:1px solid rgba(255,255,255,.08);
  flex-shrink:0; background:#13082b;
}
.pm-title { color:#fff; font-size:13px; font-weight:600; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:85%; }
.pm-close {
  background:rgba(255,255,255,.1); border:none; color:#fff;
  width:28px; height:28px; border-radius:50%; cursor:pointer; font-size:13px;
  display:flex; align-items:center; justify-content:center; flex-shrink:0;
}

/* ── Galería ─────────────────────────────────────────────────── */
.pm-gallery-body { flex:1; overflow-y:auto; padding:12px; display:flex; flex-direction:column; gap:10px; }
.pm-main-img-wrap { position:relative; border-radius:10px; overflow:hidden; background:#0f0628; }
.pm-main-img { width:100%; height:525px; display:flex; align-items:center; justify-content:center; }
.pm-main-img img { max-width:100%; max-height:525px; object-fit:contain; width:100%; }
.pm-nav {
  position:absolute; top:50%; transform:translateY(-50%);
  background:rgba(0,0,0,.55); border:none; color:#fff; font-size:24px;
  width:36px; height:36px; border-radius:50%; cursor:pointer;
  display:flex; align-items:center; justify-content:center; line-height:1;
}
.pm-prev { left:8px; }
.pm-next { right:8px; }
.pm-counter {
  position:absolute; bottom:8px; right:10px; background:rgba(0,0,0,.65);
  color:#fff; font-size:10px; padding:2px 8px; border-radius:10px;
}
.pm-masonry { display:grid; grid-template-columns:repeat(4,1fr); gap:5px; }
.pm-thumb { border-radius:8px; overflow:hidden; cursor:pointer; border:2px solid transparent; transition:border-color .2s; aspect-ratio:1; background:#2d1a6e; }
.pm-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.pm-thumb.active { border-color:#00f2fe; }

/* ── Detalles ────────────────────────────────────────────────── */
.pm-details-body { flex:1; overflow-y:auto; padding:14px; }
.pm-prod-mini { display:flex; gap:12px; align-items:center; margin-bottom:14px; padding-bottom:14px; border-bottom:1px solid rgba(255,255,255,.08); }
.pm-mini-img { width:72px; height:72px; border-radius:10px; object-fit:cover; flex-shrink:0; background:#2d1a6e; }
.pm-mini-img-ph { width:72px; height:72px; border-radius:10px; background:#2d1a6e; display:flex; align-items:center; justify-content:center; font-size:28px; flex-shrink:0; }
.pm-det-name { color:#fff; font-size:14px; font-weight:700; margin-bottom:4px; line-height:1.3; }
.pm-det-price { color:#00f2fe; font-size:16px; font-weight:700; }
.pm-det-pct { background:#db2777; color:#fff; font-size:10px; padding:1px 6px; border-radius:10px; margin-left:6px; vertical-align:middle; }
.pm-det-cat { color:rgba(255,255,255,.4); font-size:10px; margin-top:4px; text-transform:uppercase; letter-spacing:.5px; }
.pm-attrs-list { display:flex; flex-direction:column; }
.pm-attr-row { display:flex; justify-content:space-between; align-items:flex-start; padding:9px 0; border-bottom:1px solid rgba(255,255,255,.05); gap:12px; }
.pm-attr-row:last-child { border-bottom:none; }
.pm-attr-label { font-size:11px; color:rgba(255,255,255,.4); min-width:90px; flex-shrink:0; padding-top:1px; }
.pm-attr-val { font-size:11px; font-weight:500; color:#fff; text-align:right; line-height:1.5; }

/* ── Footer ──────────────────────────────────────────────────── */
.pm-footer { display:none; }
.pm-price { color:#00f2fe; font-size:16px; font-weight:700; white-space:nowrap; }
.pm-add-btn { flex:1; background:linear-gradient(90deg,#4facfe,#db2777); border:none; color:#fff; border-radius:10px; padding:10px; font-size:13px; font-weight:700; cursor:pointer; font-family:inherit; }
.pm-btn-fotos { background:rgba(0,242,254,.1); border:1px solid rgba(0,242,254,.3); color:#00f2fe; border-radius:10px; padding:10px 14px; font-size:12px; cursor:pointer; font-family:inherit; white-space:nowrap; }

@media(max-width:480px) {
  .pm-box { max-height:96vh; border-radius:12px; }
  .pm-main-img { width:100%; height:525px; display:flex; align-items:center; justify-content:center; }
  .pm-masonry { display:grid; grid-template-columns:repeat(4,1fr); gap:5px; }
}

.p-card-img img { object-fit:contain !important; background:#fff; }
.btn-share { background:none; border:none; color:rgba(255,255,255,.5); cursor:pointer; font-size:14px; padding:2px 6px; transition:color .2s; vertical-align:middle; line-height:1; }
.btn-share:hover { color:#25D366; }
.pm-share-btn { position:absolute; top:10px; left:10px; background:rgba(0,0,0,.5); border:none; color:#fff; width:32px; height:32px; border-radius:50%; cursor:pointer; font-size:14px; display:flex; align-items:center; justify-content:center; transition:background .2s; z-index:10; }
.pm-share-btn:hover { background:#25D366; }
@media(max-width:480px){ .pm-main-img { height:320px; } .pm-main-img img { max-height:320px; } }
