/* Gallery & Product Cards */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}
.product-card {
  background: #fff;
  border: 1px solid #EEE6D7;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.05);
  display: grid;
}
.product-media { aspect-ratio: 1 / 1; background: #FFFBF3; display: grid; place-items: center; }
.product-image { width: 100%; height: 100%; object-fit: cover; }
.product-info { padding: 16px; display: grid; gap: 10px; }
.category-badge { display: inline-block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .4px; padding: 4px 10px; border-radius: 4px; background: var(--soft-gold); color: var(--deep-charcoal); margin-bottom: 2px; }
.product-title { margin: 0; font-size: 18px; font-family: "Playfair Display", Georgia, serif; }
.product-desc { margin: 0; color: var(--muted-ink); font-size: 14px; }
.product-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.sizes { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.sizes span { font-size: 12px; background: #fff; border: 1px solid #EEE6D7; padding: 2px 8px; border-radius: 999px; }
.swatches { display: inline-flex; gap: 6px; }
.swatches span { width: 16px; height: 16px; border-radius: 999px; background: var(--c, #ddd); border: 1px solid rgba(0,0,0,.08); box-shadow: 0 1px 2px rgba(0,0,0,.06) inset; position: relative; }
.swatches span[data-name]::after {
  content: attr(data-name);
  position: absolute;
  left: 50%;
  top: 100%;
  transform: translateX(-50%);
  background: #14120F;
  color: #fff;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 6px;
  margin-top: 4px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,.15);
  opacity: 0;
  pointer-events: none;
  transition: opacity 120ms ease;
  z-index: 20;
}
.swatches span[data-name]:hover::after { opacity: 1; }
.card-actions { display: flex; gap: 10px; margin-top: 12px; justify-content: center; }
.product-info { position: relative; }
.product-info .card-actions { margin-left: auto; margin-right: auto; }
.product-card .btn.quick-view { min-width: 132px; text-align: center; }
.product-card .btn.btn-outline + .btn.quick-view { margin-left: 0; }
/* Ensure equal width when two buttons present */
.product-card .card-actions .btn { flex: 0 0 auto; }
/* Make outline buttons readable on white cards (override dark-header style) */
.product-card .btn.btn-outline { border-color: #EEE6D7; color: var(--ink); background: #fff; }
.product-card .btn.btn-outline:hover { background: #FFFBF3; }

/* Toolbar on gallery page */
.gallery-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.gallery-toolbar input[type="search"] { border: 1px solid #EEE6D7; border-radius: 10px; padding: 8px 10px; }
.gallery-toolbar select { border: 1px solid #EEE6D7; border-radius: 10px; padding: 8px 10px; background: #fff; }

/* Sub header */
.sub-header { background: linear-gradient(180deg, #14120F 0%, #1D1A16 100%); color: #fff; }
.sub-header-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; }
.sub-nav { display: flex; gap: 12px; }
.sub-nav a { color: rgba(255,255,255,.92); border: 1px solid rgba(255,255,255,.2); border-radius: 12px; padding: 8px 12px; }
.sub-nav a:hover { background: rgba(255,255,255,.08); }
.gallery-hero { padding-top: 24px; }

/* Quick View Modal */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); display: none; align-items: center; justify-content: center; z-index: 10000; }
.modal-overlay.open { display: flex; }
.modal { background: #fff; width: min(900px, 92vw); border-radius: 14px; overflow: hidden; box-shadow: 0 20px 70px rgba(0,0,0,.35); display: grid; grid-template-columns: 1fr 1fr; }
@media (max-width: 760px) { .modal { grid-template-columns: 1fr; } }
.modal-media { background: #FFFBF3; display: grid; place-items: center; }
.modal-media img { width: 100%; height: 100%; object-fit: cover; }
.modal-info { padding: 18px; display: grid; gap: 10px; }
.modal-title { margin: 0; font-family: "Playfair Display", Georgia, serif; font-size: 22px; }
.modal-desc { margin: 0; color: var(--muted-ink); }
.modal-meta { display: flex; align-items: center; justify-content: space-between; }
.modal-actions { display: flex; gap: 10px; }
/* Icon-only marketplace buttons */
.icon-btn { width: 44px; height: 44px; border-radius: 10px; display:inline-grid; place-items:center; border:1px solid #EEE6D7; background:#fff; box-shadow: 0 6px 16px rgba(0,0,0,.06); transition: transform 150ms ease, box-shadow 150ms ease; }
.icon-btn img { width: 24px; height: 24px; display:block; }
.icon-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.10); }
.btn-tiktok img { filter: none; }
.btn-shopee img { filter: none; }
.btn-lazada img { filter: none; }
.modal-close { position: absolute; top: 10px; right: 10px; background: #fff; border: 1px solid #EEE6D7; border-radius: 999px; padding: 6px 10px; cursor: pointer; }
