/* ==========================================================================
   SNUSLAB — Custom Shop Page (template-shop.php)
   Fully own namespace (sl- prefix), no Astra/WooCommerce classes targeted.
   This page bypasses Astra's WooCommerce archive markup entirely, so there
   is nothing here to fight against — safe to style freely.
   ========================================================================== */

:root {
  --sl-ink: #0a0a0a;
  --sl-muted: #6b7280;
  --sl-border: #e4e6e8;
  --sl-mist: #f4f5f6;
}

.sl-shop-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px 60px;
}

.sl-shop-head {
  border-bottom: 1px solid var(--sl-border);
  padding-bottom: 18px;
  margin-bottom: 24px;
}
.sl-shop-title {
  font-size: clamp(34px, 8vw, 54px);
  line-height: .95;
  letter-spacing: .5px;
  text-transform: uppercase;
  font-weight: 800;
  color: var(--sl-ink);
  margin: 0 0 8px;
}
.sl-shop-sub {
  font-size: 13.5px;
  color: var(--sl-muted);
  margin: 0;
}

.sl-shop-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.sl-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid var(--sl-border);
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  position: relative;
}
.sl-card:hover { border-color: #c7cbd0; }

.sl-card-media {
  position: relative;
  aspect-ratio: 1;
  background: var(--sl-mist);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.sl-card-media img {
  width: 78%;
  height: 78%;
  object-fit: contain;
}

.sl-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .6px;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 6px;
  color: #ffffff;
}
.sl-badge--sold { background: #9aa0a6; }

.sl-card--sold .sl-card-media img { opacity: .55; }

.sl-card-body {
  padding: 13px 13px 15px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex: 1;
}
.sl-card-name {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--sl-ink);
  text-decoration: none;
  flex: 1;
}
.sl-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 4px;
}
.sl-card-price {
  font-size: 19px;
  font-weight: 800;
  color: var(--sl-ink);
}
.sl-card-price del { color: #9aa0a6; font-weight: 400; font-size: 14px; margin-right: 4px; }
.sl-card-price ins { text-decoration: none; }

.sl-add-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--sl-ink);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  text-decoration: none;
  transition: background .15s;
}
.sl-add-btn:hover { background: #2c2f33; }
.sl-add-btn--disabled {
  background: var(--sl-mist);
  color: #9aa0a6;
  cursor: not-allowed;
}
.sl-ic {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sl-pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 32px;
}
.sl-pagination .page-numbers {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--sl-border);
  border-radius: 8px;
  color: var(--sl-ink);
  text-decoration: none;
  font-size: 13px;
}
.sl-pagination .page-numbers.current {
  background: var(--sl-ink);
  color: #ffffff;
  border-color: var(--sl-ink);
}

.sl-empty {
  text-align: center;
  color: var(--sl-muted);
  padding: 60px 0;
}

@media (min-width: 700px) {
  .sl-shop-grid { grid-template-columns: repeat(3, 1fr); gap: 16px; }
}
@media (min-width: 1000px) {
  .sl-shop-grid { grid-template-columns: repeat(4, 1fr); gap: 16px; }
}

/* ---------- count + sorting ---------- */
.sl-shop-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 16px 0 18px;
}
.sl-shop-count { font-size: 13px; color: #6b7280; }
.sl-shop-ordering { margin: 0; }
.sl-orderby {
  background: #ffffff !important;
  border: 1px solid #e4e6e8 !important;
  border-radius: 10px !important;
  color: #0a0a0a !important;
  padding: 9px 12px !important;
  font-size: 13px !important;
  box-shadow: none !important;
  cursor: pointer;
}
.sl-orderby:focus { border-color: #0a0a0a !important; outline: none !important; }
