/* ===================================================================
   Stellar Shop Product Grid CSS
   Gandharva Shop Archive & Grid layout with category sidebar,
   real-time filters, search, sort, and responsive mobile drawer.
   =================================================================== */

/* Base Wrapper & Scoped Variables */
.stellar-shop-page {
  --cream: #F9F0E1;
  --paper: #FFFAF1;
  --sage: #9FABA0;
  --sage-ink: #5B7262;
  --forest: #1F3328;
  --forest-2: #2B4535;
  --brass: #A7843F;
  --ink: #23302A;
  --muted: #63705F;
  --line: #E3D8C3;
  --plate: #F3E8D3;
  --ok: #3F7A55;
  --bg: #F9F0E1;
  --surface: #FFFAF1;
  --text: #23302A;
  --onforest: #F4EBDA;
  --radius-card: 18px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.02);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.04);
  --font-serif: "Marcellus", "Palatino Linotype", Palatino, Georgia, serif;
  --font-sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;

  position: relative;
  width: 100%;
  box-sizing: border-box;
  color: var(--text);
  font-family: var(--font-sans);
}

.stellar-shop-page[data-theme="dark"],
[data-theme="dark"] .stellar-shop-page {
  --bg: #15211B;
  --surface: #1C2B23;
  --text: #EDE4D2;
  --muted: #AAB5A6;
  --line: #31463A;
  --plate: #22342A;
  --sage-ink: #A9BDAD;
  --brass: #CDA85F;
  --forest: #0F1914;
  --forest-2: #1A2A21;
}

.stellar-shop-page *,
.stellar-shop-page *::before,
.stellar-shop-page *::after {
  box-sizing: border-box;
}

.stellar-shop-page .wrap {
  max-width: 1760px;
  margin: 0 auto;
  padding: 0 clamp(20px, 3.2vw, 64px);
}

/* Page Title & Breadcrumbs */
.stellar-shop-page .page-title {
  padding: 24px 0 10px;
}

.stellar-shop-page .crumbs {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 8px;
}

.stellar-shop-page .crumbs a {
  text-decoration: none;
  color: inherit;
  transition: color 0.15s ease;
}

.stellar-shop-page .crumbs a:hover {
  color: var(--forest);
  text-decoration: underline;
}

.stellar-shop-page .crumbs span {
  color: var(--text);
  font-weight: 500;
}

.stellar-shop-page .page-title h1,
.stellar-shop-page .page-title h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: .01em;
  line-height: 1.15;
  margin: 0;
  font-size: clamp(34px, 4.6vw, 54px);
  color: var(--text);
}

/* Store Layout: Sidebar + Main Area */
.stellar-shop-page .store {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: clamp(28px, 3vw, 56px);
  padding: 20px 0 60px;
}

.stellar-shop-page.no-sidebar .store {
  grid-template-columns: 1fr;
}

/* Sidebar Filters */
.stellar-shop-page aside.side {
  position: sticky;
  top: 100px;
  align-self: start;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 14px;
  scrollbar-width: thin;
}

.stellar-shop-page aside.side h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  margin: 0 0 14px;
  color: var(--text);
}

.stellar-shop-page .side-group {
  margin-bottom: 12px;
}

.stellar-shop-page .side details {
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}

.stellar-shop-page .side summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text);
  user-select: none;
}

.stellar-shop-page .side summary::-webkit-details-marker {
  display: none;
}

.stellar-shop-page .side summary::after {
  content: "+";
  font-size: 20px;
  color: var(--muted);
  line-height: 1;
}

.stellar-shop-page .side details[open] summary::after {
  content: "–";
}

.stellar-shop-page .side ul {
  list-style: none;
  padding: 6px 0 0;
  margin: 0;
}

.stellar-shop-page .side li {
  margin-bottom: 2px;
}

.stellar-shop-page .side li button,
.stellar-shop-page .side .allbtn {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14.5px;
  font-family: inherit;
  transition: background 0.15s ease, color 0.15s ease;
}

.stellar-shop-page .side li button:hover,
.stellar-shop-page .side .allbtn:hover {
  background: var(--plate);
  color: var(--text);
}

.stellar-shop-page .side button[aria-pressed="true"] {
  background: var(--plate);
  color: var(--text);
  font-weight: 600;
}

.stellar-shop-page .side small {
  color: var(--muted);
  flex: none;
  margin-left: 10px;
  font-size: 12px;
  background: rgba(0, 0, 0, 0.05);
  padding: 2px 7px;
  border-radius: 999px;
}

.stellar-shop-page .side .clear-btn {
  margin-top: 14px;
  background: var(--plate);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 500;
  width: 100%;
  cursor: pointer;
  border: 1px solid var(--line);
  color: var(--text);
  text-align: center;
  transition: background 0.15s ease;
}

.stellar-shop-page .side .clear-btn:hover {
  background: var(--line);
}

/* Toolbar (Search, Filter Button, Sort, Count) */
.stellar-shop-toolbar {
  margin-bottom: 24px;
}

.stellar-shop-page .bar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: nowrap;
}

.stellar-shop-page .filter-btn {
  display: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  height: 48px;
  padding: 0 18px;
  font-weight: 500;
  cursor: pointer;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-size: 14px;
  flex-shrink: 0;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.stellar-shop-page .filter-btn:hover {
  border-color: var(--sage-ink);
  background: var(--plate);
}

.stellar-shop-page .search {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  height: 48px;
  padding: 0 18px;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.stellar-shop-page .search:hover {
  border-color: #D2C5B0;
}

.stellar-shop-page .search:focus-within {
  border-color: var(--sage-ink);
  box-shadow: 0 0 0 3px rgba(91, 114, 98, 0.12);
}

.stellar-shop-page .search .search-icon {
  width: 18px;
  height: 18px;
  color: #718277;
  flex-shrink: 0;
}

.stellar-shop-page .search input {
  border: 0;
  background: transparent;
  outline: 0;
  padding: 0;
  width: 100%;
  font-size: 14.5px;
  color: var(--text);
  font-family: inherit;
  line-height: normal;
  -webkit-appearance: none;
  appearance: none;
}

/* Hide native browser search cancel / clear buttons */
.stellar-shop-page .search input::-webkit-search-decoration,
.stellar-shop-page .search input::-webkit-search-cancel-button,
.stellar-shop-page .search input::-webkit-search-results-button,
.stellar-shop-page .search input::-webkit-search-results-decoration {
  -webkit-appearance: none;
  display: none;
}

.stellar-shop-page .search input::-ms-clear,
.stellar-shop-page .search input::-ms-reveal {
  display: none;
  width: 0;
  height: 0;
}

.stellar-shop-page .search input::placeholder {
  color: #718277;
  opacity: 0.95;
  font-weight: 400;
}

.stellar-shop-page .search-clear-btn {
  background: none;
  border: 0;
  padding: 4px;
  cursor: pointer;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: color 0.15s ease, background 0.15s ease;
  flex-shrink: 0;
}

.stellar-shop-page .search-clear-btn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--text);
}

.stellar-shop-page .sort-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.stellar-shop-page .sort-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  height: 48px;
  padding: 0 36px 0 20px;
  cursor: pointer;
  font-size: 14.5px;
  color: var(--text);
  outline: none;
  font-family: inherit;
  min-width: 120px;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.stellar-shop-page .sort-select:hover {
  border-color: #D2C5B0;
}

.stellar-shop-page .sort-select:focus {
  border-color: var(--sage-ink);
  box-shadow: 0 0 0 3px rgba(91, 114, 98, 0.12);
}

.stellar-shop-page .sort-chevron {
  position: absolute;
  right: 14px;
  pointer-events: none;
  color: var(--text);
  width: 16px;
  height: 16px;
}

.stellar-shop-page .count-row {
  margin-top: 14px;
  display: flex;
  align-items: center;
}

.stellar-shop-page .count-row .count {
  color: #63705F;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  white-space: nowrap;
}

/* Product Grid */
.stellar-shop-page .grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: clamp(18px, 1.6vw, 28px);
}

.stellar-shop-page .grid.g1 { grid-template-columns: 1fr; }
.stellar-shop-page .grid.g2 { grid-template-columns: repeat(2, 1fr); }
.stellar-shop-page .grid.g3 { grid-template-columns: repeat(3, 1fr); }
.stellar-shop-page .grid.g4 { grid-template-columns: repeat(4, 1fr); }
.stellar-shop-page .grid.g5 { grid-template-columns: repeat(5, 1fr); }
.stellar-shop-page .grid.g6 { grid-template-columns: repeat(6, 1fr); }

@media (min-width: 1500px) {
  .stellar-shop-page .grid.g4 {
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
  }
}

/* Product Card */
.stellar-shop-page .card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  text-decoration: none;
  color: inherit;
  box-sizing: border-box;
  transition: transform 0.15s ease;
}

.stellar-shop-page .card:hover .plate {
  outline: 1.5px solid var(--sage-ink);
  outline-offset: -1.5px;
}

/* Image Plate */
.stellar-shop-page .plate {
  position: relative;
  aspect-ratio: 3 / 4;
  width: 100%;
  max-width: 100%;
  background: var(--plate);
  border-radius: var(--radius-card);
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: var(--sage-ink);
  overflow: hidden !important;
  box-sizing: border-box !important;
  transition: outline 0.2s ease, box-shadow 0.2s ease;
}

.stellar-shop-page .plate svg.art {
  width: 65%;
  height: 65%;
  display: block;
  margin: auto;
}

.stellar-shop-page .plate img {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center !important;
  padding: 0 !important;
  box-sizing: border-box !important;
  display: block !important;
  margin: auto !important;
}

/* Tags on Plate */
.stellar-shop-page .tags {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  z-index: 2;
}

.stellar-shop-page .tag {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.stellar-shop-page .tag.save {
  background: var(--brass);
  color: #fff;
}

.stellar-shop-page .tag.new {
  background: var(--sage-ink);
  color: var(--bg);
}

/* Sound Audio Preview Button on Plate */
.stellar-shop-page .hear {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 38px;
  height: 38px;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 50% !important;
  border: 0 !important;
  background: var(--surface);
  color: var(--sage-ink);
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer;
  z-index: 3;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
  transition: transform 0.2s ease, background 0.15s ease, color 0.15s ease;
  overflow: hidden !important;
  line-height: 1 !important;
}

.stellar-shop-page .hear:hover {
  transform: scale(1.08);
  background: var(--forest-2);
  color: var(--onforest);
}

.stellar-shop-page .hear .hear-icon {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 16px !important;
  line-height: 1 !important;
  color: inherit !important;
}

.stellar-shop-page .hear svg,
.stellar-shop-page .hear i {
  width: 18px;
  height: 18px;
  font-size: 16px;
  fill: currentColor;
  stroke: currentColor;
  color: inherit;
  display: inline-block !important;
  margin: auto !important;
  vertical-align: middle !important;
}

.stellar-shop-page .hear.is-playing {
  background: var(--forest-2);
  color: #F7EFDF;
  box-shadow: 0 0 0 3px rgba(169, 189, 173, 0.4);
  animation: stellar-hear-pulse 1.2s infinite;
}

@keyframes stellar-hear-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* Card Meta */
.stellar-shop-page .card .meta {
  text-decoration: none;
  color: inherit;
  display: block;
}

.stellar-shop-page .card .cat-l {
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}

.stellar-shop-page .card h3 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.35;
  margin: 3px 0 6px;
  color: var(--text);
  transition: color 0.15s ease;
  word-break: break-word;
  overflow-wrap: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.stellar-shop-page .card:hover h3 {
  color: var(--sage-ink);
}

/* Price Row */
.stellar-shop-page .price {
  display: flex;
  gap: 10px;
  align-items: baseline;
  flex-wrap: wrap;
  margin-top: 2px;
}

.stellar-shop-page .price b {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
}

.stellar-shop-page .price s {
  color: var(--muted);
  font-size: 14px;
}

.stellar-shop-page .price .tag.save {
  font-size: 11px;
  padding: 2px 8px;
}

/* Add to Cart Button */
.stellar-shop-page .card .add {
  margin-top: 12px;
  align-self: flex-start;
  padding: 9px 18px;
  font-size: 14px;
  font-weight: 600;
  background: var(--forest-2);
  color: var(--onforest);
  border: 1.5px solid var(--forest-2);
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.stellar-shop-page .card .add:hover {
  background: var(--forest);
  border-color: var(--forest);
}

.stellar-shop-page .card .add.loading {
  opacity: 0.7;
  cursor: wait;
}

.stellar-shop-page .card .add.added {
  background: var(--sage-ink) !important;
  border-color: var(--sage-ink) !important;
  color: #fff !important;
}

/* Empty State */
.stellar-shop-page .empty {
  padding: 60px 24px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: var(--radius-card);
  grid-column: 1 / -1;
  background: var(--surface);
}

.stellar-shop-page .empty .empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--plate);
  color: var(--muted);
  margin-bottom: 16px;
}

.stellar-shop-page .empty h3 {
  font-size: 22px;
  margin: 0 0 8px;
  font-family: var(--font-serif);
  color: var(--text);
}

.stellar-shop-page .empty p {
  color: var(--muted);
  font-size: 15px;
  margin: 0 0 20px;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.stellar-shop-page .empty .empty-reset-btn {
  background: var(--forest-2);
  color: var(--onforest);
  border: 0;
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
  font-family: inherit;
}

.stellar-shop-page .empty .empty-reset-btn:hover {
  background: var(--forest);
  transform: translateY(-1px);
}

/* Mobile Scrim Backdrop */
.stellar-shop-scrim {
  position: fixed;
  inset: 0;
  background: rgba(10, 20, 15, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 998;
  display: none;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.stellar-shop-scrim.open {
  display: block;
  opacity: 1;
}

/* Floating Toast Notification */
.stellar-shop-toast {
  position: fixed;
  left: 50%;
  bottom: calc(30px + env(safe-area-inset-bottom, 0px));
  transform: translate(-50%, 20px);
  opacity: 0;
  background: var(--forest-2);
  color: var(--onforest);
  padding: 12px 20px;
  border-radius: 14px;
  z-index: 999;
  display: flex;
  gap: 14px;
  align-items: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease;
  pointer-events: none;
  max-width: calc(100% - 32px);
  font-size: 14.5px;
  font-weight: 500;
}

.stellar-shop-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}

.stellar-shop-toast a {
  color: #E9D5A6;
  font-weight: 600;
  text-decoration: underline;
}

/* ===================================================================
   RESPONSIVE
   =================================================================== */
@media (max-width: 1180px) {
  .stellar-shop-page .store {
    gap: 28px;
  }
}

@media (max-width: 980px) {
  .stellar-shop-page .store {
    grid-template-columns: 1fr !important;
    gap: 20px;
  }

  .stellar-shop-page main.main {
    min-width: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden;
  }

  .stellar-shop-page aside.side {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: min(320px, 86vw);
    max-height: 100vh;
    background: var(--bg);
    z-index: 99999;
    padding: calc(24px + env(safe-area-inset-top, 0px)) 24px 24px;
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
    border-right: 1px solid var(--line);
    box-shadow: 6px 0 24px rgba(0,0,0,0.15);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .stellar-shop-page aside.side.open {
    transform: translateX(0);
  }

  .stellar-shop-page .stellar-shop-scrim {
    z-index: 99998;
  }

  .stellar-shop-page .bar {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    width: 100% !important;
  }

  .stellar-shop-page .bar .search {
    order: 1 !important;
    flex: 1 1 100% !important;
    width: 100% !important;
  }

  .stellar-shop-page .bar .filter-btn {
    order: 2 !important;
    display: inline-flex !important;
    flex: 1 1 auto !important;
    height: 46px !important;
    justify-content: center !important;
    font-size: 14px !important;
    padding: 0 16px !important;
  }

  .stellar-shop-page .bar .sort-wrapper {
    order: 3 !important;
    flex: 1 1 auto !important;
    margin-left: 0 !important;
    width: auto !important;
  }

  .stellar-shop-page .bar .sort-select {
    width: 100% !important;
    height: 46px !important;
    font-size: 14px !important;
    padding: 0 32px 0 16px !important;
    min-width: 110px !important;
  }

  .stellar-shop-page .grid,
  .stellar-shop-page .grid.g3,
  .stellar-shop-page .grid.g4,
  .stellar-shop-page .grid.g5,
  .stellar-shop-page .grid.g6 {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 16px !important;
  }

  .stellar-shop-page .plate img {
    padding: 8px !important;
  }
}

@media (max-width: 768px) {
  .stellar-shop-page .grid,
  .stellar-shop-page .grid.g1,
  .stellar-shop-page .grid.g2,
  .stellar-shop-page .grid.g3,
  .stellar-shop-page .grid.g4,
  .stellar-shop-page .grid.g5,
  .stellar-shop-page .grid.g6 {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 14px !important;
  }

  .stellar-shop-page .grid.g1 {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 560px) {
  .stellar-shop-page .wrap {
    padding: 0 16px;
  }

  .stellar-shop-page .page-title {
    padding: 16px 0 8px;
  }

  .stellar-shop-page .page-title h1,
  .stellar-shop-page .page-title h2 {
    font-size: 24px;
  }

  .stellar-shop-page .grid,
  .stellar-shop-page .grid.g1,
  .stellar-shop-page .grid.g2,
  .stellar-shop-page .grid.g3,
  .stellar-shop-page .grid.g4,
  .stellar-shop-page .grid.g5,
  .stellar-shop-page .grid.g6 {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }

  .stellar-shop-page .grid.g1 {
    grid-template-columns: 1fr !important;
  }

  .stellar-shop-page .plate {
    border-radius: 14px !important;
  }

  .stellar-shop-page .plate img {
    padding: 0 !important;
  }

  .stellar-shop-page .card h3 {
    font-size: 13.5px;
    margin: 3px 0 4px;
  }

  .stellar-shop-page .card .cat-l {
    font-size: 11.5px;
    margin-top: 8px;
  }

  .stellar-shop-page .card .add {
    display: none;
  }

  .stellar-shop-page .hear {
    width: 32px;
    height: 32px;
    right: 8px;
    bottom: 8px;
  }

  .stellar-shop-page .hear svg {
    width: 15px;
    height: 15px;
  }
}

@media (max-width: 400px) {
  .stellar-shop-page .grid,
  .stellar-shop-page .grid.g2,
  .stellar-shop-page .grid.g3,
  .stellar-shop-page .grid.g4,
  .stellar-shop-page .grid.g5,
  .stellar-shop-page .grid.g6 {
    gap: 8px !important;
  }

  .stellar-shop-page .plate {
    border-radius: 12px !important;
  }

  .stellar-shop-page .plate img {
    padding: 0 !important;
  }

  .stellar-shop-page .card h3 {
    font-size: 12.5px;
    margin: 2px 0 4px;
  }

  .stellar-shop-page .price b {
    font-size: 14px;
  }

  .stellar-shop-page .price s {
    font-size: 11.5px;
  }

  .stellar-shop-page .tag {
    font-size: 9.5px;
    padding: 2px 5px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .stellar-shop-page aside.side,
  .stellar-shop-toast,
  .stellar-shop-scrim {
    transition: none !important;
  }
}

/* ===================================================================
   SC-PRODUCT-GRID & SC-PRODUCT-CARD DESIGN SYSTEM
   =================================================================== */
.stellar-shop-page,
.stellar-band-grid-wrap,
.sc-product-grid,
#dealsGrid {
  --font-primary: 'Merriweather', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --color-text-light: #1c1917aa;
  --color-text-lighter: #1c191777;
  --color-bg-secondary: #f9fafb;
  --color-border: #e5e7eb;
  --color-blue: #3B82F6;
  --detail-image-fit: contain;
  --color-blue-dark: #2563EB;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --primary: #B91C1C;
  --color-primary: #166d46;
  --color-primary-dark: #115234;
  --color-accent: #D97706;
  --color-bg: #fffbeb;
  --color-text: #1c1917;
  --font-body: 'Merriweather', sans-serif;
  --font-heading: 'Merriweather', serif;
  --btn-radius: 8px;
  --sc-navy: #0f172a;
  --sc-hero-bg: #fffbeb;
  --sc-strip: #f8fafc;
  --sc-border: #e5e7eb;
  --sc-surface: #ffffff;
  --sc-card-text: #1c1917;
  --sc-card-sub: #1c1917aa;
  --sc-card-muted: #1c191777;
  --sc-radius: 12px;
  --card-image-fit: cover;
  --card-image-position: center;
}

.sc-product-grid,
#dealsGrid,
.stellar-shop-page .grid {
  display: grid !important;
  align-items: stretch !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 16px !important;
  box-sizing: border-box !important;
  margin: 0 !important;
  padding: 0 !important;
}

@media (max-width: 1200px) {
  .sc-product-grid,
  #dealsGrid,
  .stellar-shop-page .grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 12px !important;
  }
}

@media (max-width: 768px) {
  .sc-product-grid,
  #dealsGrid,
  .stellar-shop-page .grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }
}

/* Card Container */
.sc-product-card,
.stellar-shop-page .card {
  background: var(--sc-surface, #ffffff) !important;
  border: 1px solid var(--sc-border, #e5e7eb) !important;
  border-radius: var(--sc-radius, 12px) !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
  box-shadow: var(--shadow-sm, 0 1px 2px 0 rgba(0, 0, 0, 0.05)) !important;
  transition: transform var(--transition-base, 200ms) ease, box-shadow var(--transition-base, 200ms) ease !important;
  cursor: pointer !important;
  box-sizing: border-box !important;
  position: relative !important;
}

.sc-product-card:hover,
.stellar-shop-page .card:hover {
  box-shadow: var(--shadow-md, 0 4px 6px -1px rgba(0, 0, 0, 0.1)) !important;
  transform: translateY(-2px) !important;
}

/* Image Plate Wrap */
.sc-card-img-wrap,
.stellar-shop-page .plate {
  position: relative !important;
  width: 100% !important;
  aspect-ratio: 1 / 1 !important;
  background: var(--color-bg-secondary, #f9fafb) !important;
  overflow: hidden !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 0 !important;
  outline: none !important;
}

.sc-card-img-wrap img,
.stellar-shop-page .plate img {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  display: block !important;
  transition: transform 0.3s ease !important;
  padding: 0 !important;
  margin: 0 !important;
}

.sc-product-card:hover .sc-card-img-wrap img,
.stellar-shop-page .card:hover .plate img {
  transform: scale(1.05) !important;
}

/* Discount Badge */
.sc-card-discount-badge {
  position: absolute !important;
  top: 8px !important;
  left: 8px !important;
  background: #B91C1C !important;
  color: #ffffff !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  padding: 2.5px 7px !important;
  border-radius: 6px !important;
  line-height: 1.2 !important;
  z-index: 2 !important;
  letter-spacing: 0.3px !important;
  text-transform: uppercase !important;
}

/* Wishlist Button */
.sc-card-wishlist {
  position: absolute !important;
  top: 8px !important;
  right: 8px !important;
  z-index: 4 !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  color: #64748b !important;
  font-size: 14px !important;
  transition: all 0.2s ease !important;
  padding: 0 !important;
  line-height: 1 !important;
}

.sc-card-wishlist:hover,
.sc-card-wishlist.active {
  color: #B91C1C !important;
  background: #ffffff !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12) !important;
}

.sc-card-wishlist i {
  font-size: 14px !important;
  line-height: 1 !important;
}

/* Audio Sound Preview Button */
.stellar-shop-page .plate .stellar-sound-btn,
.stellar-shop-page .plate .hear {
  position: absolute !important;
  bottom: 8px !important;
  right: 8px !important;
  z-index: 4 !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.92) !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  color: #166d46 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1) !important;
  transition: all 0.2s ease !important;
  padding: 0 !important;
}

.stellar-shop-page .plate .stellar-sound-btn:hover,
.stellar-shop-page .plate .hear:hover {
  background: #166d46 !important;
  color: #ffffff !important;
  transform: scale(1.08) !important;
}

/* Card Body */
.sc-card-body,
.stellar-shop-page .card .meta {
  cursor: pointer !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 8px 10px 10px !important;
  gap: 4px !important;
  background: transparent !important;
}

/* Card Name */
.sc-card-name,
.stellar-shop-page .card h3 {
  font-family: var(--font-primary, 'Merriweather', serif) !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  color: var(--sc-card-text, #1c1917) !important;
  line-height: 1.35 !important;
  margin: 0 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  min-height: 2.7em !important;
  word-break: break-word !important;
}

.sc-card-name a {
  color: inherit !important;
  text-decoration: none !important;
}

.sc-card-name a:hover {
  color: #B91C1C !important;
}

/* Star Rating */
.sc-card-stars {
  font-size: 12px !important;
  color: #f59e0b !important;
  display: flex !important;
  align-items: center !important;
  gap: 2px !important;
  line-height: 1 !important;
}

.sc-star-empty {
  color: #d1d5db !important;
}

.sc-card-stars span:last-child {
  font-size: 11px !important;
  color: var(--sc-card-muted, #1c191777) !important;
  margin-left: 2px !important;
}

/* Price Row */
.sc-card-price,
.stellar-shop-page .price {
  display: flex !important;
  align-items: baseline !important;
  gap: 6px !important;
  margin: 0 !important;
  flex-wrap: wrap !important;
}

.sc-card-price-main,
.stellar-shop-page .price b {
  font-size: 15.5px !important;
  font-weight: 700 !important;
  color: var(--sc-card-text, #1c1917) !important;
  font-family: var(--font-primary, 'Merriweather', sans-serif) !important;
}

.sc-card-price-sup {
  font-size: 11px !important;
  font-weight: 600 !important;
  vertical-align: baseline !important;
  margin-right: 1px !important;
}

.sc-card-price-orig,
.stellar-shop-page .price s {
  font-size: 12px !important;
  color: var(--sc-card-muted, #1c191777) !important;
  text-decoration: line-through !important;
}

/* Description Clamp */
.sc-card-desc {
  font-size: 11.5px !important;
  color: var(--sc-card-sub, #1c1917aa) !important;
  line-height: 1.4 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  margin-top: 2px !important;
}

/* Spacer */
.sc-card-spacer {
  flex: 1 !important;
  min-height: 4px !important;
}

/* CTA / Add to Cart Button */
.sc-card-cta,
.sc-card-cta.add-to-cart-btn,
.stellar-shop-page .card .add {
  width: 100% !important;
  padding: 8px 12px !important;
  border-radius: var(--btn-radius, 8px) !important;
  background: var(--color-primary, #166d46) !important;
  color: #ffffff !important;
  font-size: 12.5px !important;
  font-weight: 700 !important;
  text-align: center !important;
  border: none !important;
  cursor: pointer !important;
  margin-top: 4px !important;
  box-sizing: border-box !important;
  transition: all var(--transition-base, 200ms) ease !important;
  display: block !important;
  letter-spacing: 0.2px !important;
  font-family: inherit !important;
  line-height: normal !important;
}

.sc-card-cta:hover,
.sc-card-cta.add-to-cart-btn:hover,
.stellar-shop-page .card .add:hover {
  background: var(--color-primary-dark, #115234) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 10px rgba(22, 109, 70, 0.25) !important;
}

