/* ═══════════════════════════════════════════════════
   ShopZone Products Grid — style.css  v5.0.0
═══════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+Bengali:wght@400;500;600;700;800&display=swap');

:root {
  --szp-accent:   #FF4A1C;
  --szp-navy:     #0D1B3E;
  --szp-dark:     #0F0F0F;
  --szp-bg:       #F5F3EF;
  --szp-card:     #FFFFFF;
  --szp-border:   #E8E5E0;
  --szp-muted:    #888888;
  --szp-star:     #F5A623;
  --szp-radius:   18px;
  --szp-font:     'Noto Serif Bengali', serif;
  --szp-head:     'Noto Serif Bengali', serif;
}

/* ── Section ── */
.szp-section { padding: 60px 0; font-family: var(--szp-font); }

.szp-header { margin-bottom: 36px; }
.szp-title {
  font-family: var(--szp-head);
  font-weight: 800;
  font-size: clamp(24px, 3vw, 36px);
  color: var(--szp-dark);
  margin: 0 0 8px;
  line-height: 1.15;
}
.szp-title span { color: var(--szp-accent); }
.szp-subtitle  { color: var(--szp-muted); font-size: 14px; margin: 0; }

/* ── Grid ── */
.szp-grid {
  display: grid;
  gap: 24px;
}
.szp-cols-2 { grid-template-columns: repeat(2, 1fr); }
.szp-cols-3 { grid-template-columns: repeat(3, 1fr); }
.szp-cols-4 { grid-template-columns: repeat(4, 1fr); }
.szp-cols-5 { grid-template-columns: repeat(5, 1fr); }

@media (max-width: 1024px) {
  .szp-cols-4, .szp-cols-5 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .szp-cols-3, .szp-cols-4, .szp-cols-5 { grid-template-columns: repeat(2, 1fr); }
  .szp-section { padding: 40px 0; }
  .szp-grid { gap: 14px; }
}
@media (max-width: 480px) {
  .szp-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}

/* ── Card ── */
.szp-card {
  background: var(--szp-card);
  border: 1px solid var(--szp-border);
  border-radius: var(--szp-radius);
  overflow: hidden;
  position: relative;
  transition: transform .3s ease, box-shadow .3s ease;
  font-family: var(--szp-font);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.szp-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 48px rgba(0,0,0,.10);
}

/* ── Badges ── */
.szp-badge {
  position: absolute;
  top: 12px; left: 12px;
  font-size: 11px; font-weight: 700;
  padding: 4px 12px;
  border-radius: 50px;
  z-index: 3;
  background: var(--szp-dark);
  color: #fff;
  font-family: var(--szp-font);
}
.szp-badge--hot      { background: var(--szp-accent); }
.szp-badge--new      { background: #16A34A; }
.szp-badge--featured { background: var(--szp-navy); }

/* ── Top buttons (wishlist, share, quickview) ── */
.szp-card-actions {
  position: absolute;
  top: 12px; right: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 4;
}
.szp-wishlist,
.szp-share-btn,
.szp-quickview-btn {
  width: 34px; height: 34px;
  background: #fff;
  border: 1px solid var(--szp-border);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 15px; line-height: 1;
  transition: background .2s, transform .2s, color .2s;
  color: var(--szp-muted);
  text-decoration: none;
}
.szp-wishlist:hover,
.szp-share-btn:hover,
.szp-quickview-btn:hover { background: #f5f5f5; transform: scale(1.12); color: var(--szp-accent); }
.szp-wishlist.szp-wished { color: var(--szp-accent); background: #fff0ee; }

/* ── Share Panel ── */
.szp-share-panel {
  position: absolute;
  top: 12px; right: 50px;
  background: #fff;
  border: 1px solid var(--szp-border);
  border-radius: 12px;
  padding: 10px;
  display: none;
  gap: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
  z-index: 5;
  white-space: nowrap;
}
.szp-share-panel.szp-share-open { display: flex; }
.szp-share-panel a {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; text-decoration: none;
  transition: transform .15s;
}
.szp-share-panel a:hover { transform: scale(1.15); }
.szp-share-panel [data-share="whatsapp"] { background: #25d366; color: #fff; }
.szp-share-panel [data-share="facebook"] { background: #1877f2; color: #fff; }
.szp-share-panel [data-share="twitter"]  { background: #1da1f2; color: #fff; }
.szp-share-panel [data-share="copy"]     { background: var(--szp-border); color: var(--szp-dark); font-size: 13px; }

/* ── Product Image ── */
.szp-img-wrap {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #F0EDE8;
  overflow: hidden;
}
.szp-img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.szp-card:hover .szp-img-wrap img { transform: scale(1.06); }

/* ── Card Body ── */
.szp-body {
  padding: 16px 16px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.szp-cat { display: none; }
.szp-name {
  display: block;
  font-family: var(--szp-head);
  font-weight: 700;
  font-size: 14px;
  color: var(--szp-dark);
  text-decoration: none;
  margin-bottom: 10px;
  line-height: 1.5;
  transition: color .2s;
  flex: 1;
}
.szp-name:hover { color: var(--szp-accent); }

/* ── Rating ── */
.szp-rating { display: flex; align-items: center; gap: 7px; margin-bottom: 13px; }
.szp-stars  { color: var(--szp-star); font-size: 13px; letter-spacing: 1px; }
.szp-rating-num {
  background: var(--szp-star); color: #fff;
  font-size: 11px; font-weight: 700;
  padding: 2px 8px; border-radius: 50px;
}
.szp-review-count { font-size: 12px; color: var(--szp-muted); }

/* ── Price + Button ── */
.szp-price-row {
  display: flex; align-items: center;
  justify-content: space-between;
  gap: 10px; flex-wrap: wrap;
  margin-top: auto;
}
.szp-price { font-family: var(--szp-head); font-weight: 800; font-size: 20px; color: var(--szp-dark); line-height: 1; }
.szp-price .woocommerce-Price-amount { font-family: var(--szp-head); font-weight: 800; }
.szp-price del { font-size: 13px; color: var(--szp-muted); font-weight: 400; margin-left: 4px; }
.szp-price ins { text-decoration: none; }

/* ── Order Button ── */
.szp-order-btn {
  background: var(--szp-navy);
  color: #fff !important;
  border: none;
  padding: 10px 16px;
  border-radius: 50px;
  font-size: 12px; font-weight: 600;
  cursor: pointer;
  font-family: var(--szp-font);
  display: inline-flex; align-items: center; gap: 6px;
  text-decoration: none !important;
  transition: background .2s, transform .15s;
  white-space: nowrap;
}
.szp-order-btn:hover           { background: var(--szp-accent) !important; transform: scale(1.04); }
.szp-order-btn svg             { width: 14px; height: 14px; flex-shrink: 0; }
.szp-order-btn--out            { background: var(--szp-muted) !important; cursor: not-allowed; }
.szp-order-btn--out:hover      { background: var(--szp-muted) !important; transform: none; }
.szp-order-btn.szp-added       { background: #16a34a !important; }

/* ── Search Bar ── */
.szp-search-wrap {
  position: relative;
  max-width: 480px;
  margin: 0 auto 32px;
}
.szp-search-input {
  width: 100%;
  padding: 13px 48px 13px 20px;
  border: 1.5px solid var(--szp-border);
  border-radius: 50px;
  font-family: var(--szp-font);
  font-size: 14px; color: var(--szp-dark);
  background: #fff; outline: none;
  transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.szp-search-input:focus {
  border-color: var(--szp-accent);
  box-shadow: 0 0 0 3px rgba(255,74,28,.12);
}
.szp-search-icon {
  position: absolute; right: 16px; top: 50%;
  transform: translateY(-50%);
  font-size: 18px; pointer-events: none; color: var(--szp-muted);
}
.szp-search-empty {
  text-align: center; color: var(--szp-muted);
  padding: 30px; font-size: 15px;
  display: none;
}

/* ── Load More ── */
.szp-loadmore-wrap { text-align: center; margin-top: 40px; }
.szp-loadmore-btn {
  background: var(--szp-navy); color: #fff;
  border: none; padding: 14px 44px;
  border-radius: 50px;
  font-family: var(--szp-font); font-size: 15px; font-weight: 600;
  cursor: pointer;
  transition: background .2s, transform .15s;
}
.szp-loadmore-btn:hover    { background: var(--szp-accent); transform: translateY(-2px); }
.szp-loadmore-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }

/* ── Pagination ── */
.szp-pagination { margin-top: 40px; text-align: center; }
.szp-pagination .page-numbers {
  display: inline-flex; gap: 8px;
  list-style: none; padding: 0; margin: 0;
  flex-wrap: wrap; justify-content: center;
}
.szp-pagination .page-numbers li a,
.szp-pagination .page-numbers li span {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--szp-border);
  font-family: var(--szp-font); font-size: 14px; font-weight: 600;
  text-decoration: none; color: var(--szp-dark);
  transition: all .2s;
}
.szp-pagination .page-numbers li a:hover            { background: var(--szp-accent); border-color: var(--szp-accent); color: #fff; }
.szp-pagination .page-numbers li span.current       { background: var(--szp-navy);   border-color: var(--szp-navy);   color: #fff; }

/* ── Empty ── */
.szp-empty {
  text-align: center; color: var(--szp-muted);
  padding: 40px; font-size: 15px; font-family: var(--szp-font);
}

/* ══════════════════════════════════════════════════
   PRODUCT MODAL
══════════════════════════════════════════════════ */
.szp-no-scroll { overflow: hidden; }

.szp-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  transition: opacity .3s ease;
  font-family: var(--szp-font);
}
.szp-modal--open { opacity: 1; pointer-events: all; }

.szp-modal-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.szp-modal-box {
  position: relative;
  background: #fff;
  border-radius: 24px;
  max-width: 860px; width: 92%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 32px 80px rgba(0,0,0,.25);
  transform: scale(.92) translateY(20px);
  transition: transform .35s cubic-bezier(.34,1.3,.64,1);
  z-index: 1;
}
.szp-modal--open .szp-modal-box { transform: scale(1) translateY(0); }

.szp-modal-x {
  position: absolute; top: 16px; right: 16px;
  width: 36px; height: 36px;
  border-radius: 50%; border: 1px solid var(--szp-border);
  background: #fff; font-size: 20px; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--szp-muted); transition: all .2s; z-index: 2;
}
.szp-modal-x:hover { background: var(--szp-accent); color: #fff; border-color: var(--szp-accent); }

.szp-modal-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
@media (max-width: 600px) { .szp-modal-inner { grid-template-columns: 1fr; } }

.szp-modal-img-wrap {
  background: #F0EDE8;
  border-radius: 24px 0 0 24px;
  overflow: hidden;
  aspect-ratio: 1/1;
  display: flex; align-items: center; justify-content: center;
}
@media (max-width: 600px) { .szp-modal-img-wrap { border-radius: 24px 24px 0 0; } }
.szp-modal-img { width: 100%; height: 100%; object-fit: cover; }

.szp-modal--loading .szp-modal-img-wrap::after {
  content: '';
  display: block; width: 40px; height: 40px;
  border: 3px solid var(--szp-border);
  border-top-color: var(--szp-accent);
  border-radius: 50%;
  animation: szpSpin .8s linear infinite;
  position: absolute;
}
@keyframes szpSpin { to { transform: rotate(360deg); } }

.szp-modal-info {
  padding: 32px;
  display: flex; flex-direction: column; gap: 12px;
}
.szp-modal-cat { font-size: 11px; font-weight: 600; color: var(--szp-muted); text-transform: uppercase; letter-spacing: 1px; margin: 0; }
.szp-modal-name { font-family: var(--szp-head); font-weight: 800; font-size: 20px; color: var(--szp-dark); margin: 0; line-height: 1.3; }
.szp-modal-rating { display: flex; align-items: center; gap: 8px; }
.szp-modal-price { font-family: var(--szp-head); font-weight: 800; font-size: 26px; color: var(--szp-dark); }
.szp-modal-price del { font-size: 16px; color: var(--szp-muted); font-weight: 400; margin-left: 8px; }
.szp-modal-price ins { text-decoration: none; }
.szp-modal-desc { font-size: 13px; color: var(--szp-muted); line-height: 1.7; margin: 0; flex: 1; }
.szp-modal-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: auto; }
.szp-modal-detail { color: var(--szp-accent); font-size: 13px; font-weight: 600; text-decoration: none; }
.szp-modal-detail:hover { text-decoration: underline; }

/* ── Toast ── */
.szp-toast {
  position: fixed; bottom: 28px; right: 28px;
  background: var(--szp-dark); color: #fff;
  padding: 13px 20px; border-radius: 12px;
  font-family: var(--szp-font); font-size: 14px; font-weight: 500;
  display: flex; align-items: center; gap: 9px;
  box-shadow: 0 12px 32px rgba(0,0,0,.25);
  transform: translateY(120px); opacity: 0;
  transition: all .35s cubic-bezier(.34,1.56,.64,1);
  z-index: 9999999; pointer-events: none;
}
.szp-toast.szp-show { transform: translateY(0); opacity: 1; }
