/* assets/css/mobile.css
   path: frontend/assets/css/mobile.css
   UPGRADED: sticky add-to-cart bar, bottom sheet filter drawer,
             horizontal product cards, trust strip, scarcity badges */

/* ══════════════════════════════════════════════════════════════
   EXISTING: GLOBAL TOUCH TARGETS
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .btn { min-height: 48px; }
  .btn--sm { min-height: 40px; }
  input, select, textarea { font-size: 16px !important; }
  .form-control { padding: 14px 16px; }
}

/* ══════════════════════════════════════════════════════════════
   EXISTING: SEARCH BAR
   ══════════════════════════════════════════════════════════════ */
.search-bar-wrap {
  position: relative;
  width: 100%;
  max-width: 560px;
}

.search-bar-wrap svg.search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--white-dim);
  pointer-events: none;
  flex-shrink: 0;
}

.search-bar {
  width: 100%;
  padding: 13px 16px 13px 46px;
  background: var(--black-card);
  border: 1px solid var(--black-border);
  border-radius: var(--radius-sm);
  color: var(--white);
  font-size: 0.9rem;
  font-family: var(--font-ui);
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
  -webkit-appearance: none;
}

.search-bar:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.search-bar::placeholder { color: var(--text-muted, rgba(200,191,181,0.4)); }

[data-theme="light"] .search-bar {
  background: #fff;
  border-color: var(--border-color);
  color: var(--text-primary);
}

.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--black-soft);
  border: 1px solid var(--black-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-elevation);
  z-index: 500;
  max-height: 420px;
  overflow-y: auto;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}

.search-dropdown.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

[data-theme="light"] .search-dropdown { background: #fff; border-color: var(--border-color); }

.search-result-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid var(--black-border);
  text-decoration: none;
  color: inherit;
}

.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--white-faint); }
[data-theme="light"] .search-result-item:hover { background: var(--bg-hover); }

.search-result-item img {
  width: 44px;
  height: 55px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--black-card);
  flex-shrink: 0;
}

.search-result-item__info { flex: 1; min-width: 0; }

.search-result-item__name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 3px;
}

[data-theme="light"] .search-result-item__name { color: var(--text-primary); }

.search-result-item__price {
  font-size: 0.78rem;
  color: var(--gold);
  font-weight: 600;
}

.search-result-item__cat {
  font-size: 0.68rem;
  color: var(--white-dim);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.search-no-results {
  padding: 28px 16px;
  text-align: center;
  color: var(--white-dim);
  font-size: 0.85rem;
}

/* ══════════════════════════════════════════════════════════════
   EXISTING: WHATSAPP WIDGET
   ══════════════════════════════════════════════════════════════ */
.wa-widget {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

.wa-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(37,211,102,0.45);
  border: none;
  transition: transform 0.3s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.3s;
  position: relative;
  flex-shrink: 0;
}

.wa-btn:hover { transform: scale(1.1); box-shadow: 0 10px 32px rgba(37,211,102,0.55); }
.wa-btn svg  { flex-shrink: 0; }

.wa-pulse {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: rgba(37,211,102,0.3);
  animation: wa-ping 2s ease-out infinite;
}

@keyframes wa-ping {
  0%   { transform: scale(0.9); opacity: 0.8; }
  70%  { transform: scale(1.4); opacity: 0; }
  100% { opacity: 0; }
}

.wa-tooltip {
  background: var(--black-soft);
  border: 1px solid var(--black-border);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  max-width: 260px;
  box-shadow: var(--shadow-elevation);
  opacity: 0;
  transform: translateY(8px) scale(0.95);
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
}

.wa-widget.open .wa-tooltip {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
}

[data-theme="light"] .wa-tooltip { background: #fff; border-color: var(--border-color); }

.wa-tooltip__title { font-weight: 700; font-size: 0.85rem; color: var(--white); margin-bottom: 4px; }
[data-theme="light"] .wa-tooltip__title { color: var(--text-primary); }

.wa-tooltip__sub { font-size: 0.78rem; color: var(--white-dim); margin-bottom: 14px; line-height: 1.5; }
[data-theme="light"] .wa-tooltip__sub { color: var(--text-secondary); }

.wa-tooltip__cta {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: #25D366;
  color: #fff;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.2s;
}

.wa-tooltip__cta:hover { background: #1ebe5d; }

@media (max-width: 480px) {
  /* UPGRADED: wa-widget lifted above sticky cart bar */
  .wa-widget {
    bottom: calc(80px + env(safe-area-inset-bottom, 0px));
    right: 14px;
  }
  .wa-btn { width: 50px; height: 50px; }
}

/* ══════════════════════════════════════════════════════════════
   EXISTING: CURRENCY SWITCHER
   ══════════════════════════════════════════════════════════════ */
.currency-switcher { position: relative; }

.currency-switcher__btn {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 14px;
  background: var(--white-faint);
  border: 1px solid var(--black-border);
  border-radius: var(--radius-sm);
  color: var(--white-dim);
  cursor: pointer;
  transition: all 0.2s;
}

.currency-switcher__btn:hover { border-color: var(--gold); color: var(--gold); }

.currency-switcher__dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: var(--black-soft);
  border: 1px solid var(--black-border);
  border-radius: var(--radius-md);
  min-width: 160px;
  box-shadow: var(--shadow-elevation);
  z-index: 300;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}

.currency-switcher.open .currency-switcher__dropdown {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

[data-theme="light"] .currency-switcher__dropdown { background: #fff; border-color: var(--border-color); }

.currency-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  font-size: 0.82rem;
  color: var(--white-dim);
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid var(--black-border);
}

.currency-opt:last-child { border-bottom: none; }
.currency-opt:hover      { background: var(--white-faint); color: var(--white); }
.currency-opt.active     { color: var(--gold); }
[data-theme="light"] .currency-opt       { color: var(--text-secondary); }
[data-theme="light"] .currency-opt:hover { background: var(--bg-hover); color: var(--text-primary); }
.currency-opt__flag { font-size: 1rem; }
.currency-opt__code { font-weight: 700; letter-spacing: 0.08em; }
.currency-opt__sym  { font-size: 0.75rem; color: var(--gold); }

/* ══════════════════════════════════════════════════════════════
   EXISTING: ORDER TRACKER
   ══════════════════════════════════════════════════════════════ */
.tracker-wrap { margin: 24px 0; padding: 20px 24px; background: var(--black-card); border: 1px solid var(--black-border); border-radius: var(--radius-md); }
.tracker-steps { display: flex; align-items: center; gap: 0; position: relative; }
.tracker-step { flex: 1; display: flex; flex-direction: column; align-items: center; position: relative; z-index: 1; }
.tracker-step__dot { width: 32px; height: 32px; border-radius: 50%; background: var(--black-border); border: 2px solid var(--black-border); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; color: var(--white-dim); transition: all 0.4s; }
.tracker-step.done   .tracker-step__dot { background: var(--green-africa); border-color: var(--green-africa); color: #fff; }
.tracker-step.active .tracker-step__dot { background: var(--gold); border-color: var(--gold); color: var(--black); box-shadow: 0 0 0 6px rgba(201,151,44,0.15); }
.tracker-step__label { font-size: 0.65rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--white-dim); margin-top: 8px; text-align: center; }
.tracker-step.done  .tracker-step__label,
.tracker-step.active .tracker-step__label { color: var(--white); }
.tracker-connector { flex: 1; height: 2px; background: var(--black-border); position: relative; top: -10px; z-index: 0; }
.tracker-connector.done { background: var(--green-africa); }
@media (max-width: 480px) {
  .tracker-step__label { font-size: 0.58rem; letter-spacing: 0.05em; }
  .tracker-step__dot   { width: 26px; height: 26px; font-size: 0.65rem; }
}

/* ══════════════════════════════════════════════════════════════
   EXISTING: ADMIN / UPLOAD
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .admin-layout    { flex-direction: column; }
  .admin-content   { padding: 16px; }
  .upload-zone     { padding: 28px 16px; }
  .admin-form-grid,
  .admin-form-grid--3 { grid-template-columns: 1fr; }
  .form-group--full   { grid-column: 1; }
  .admin-stats        { grid-template-columns: 1fr 1fr; gap: 12px; }
  .admin-topbar       { padding: 0 16px; }
  .admin-table th,
  .admin-table td     { padding: 12px 14px; font-size: 0.78rem; }
}

.upload-zone { border: 2px dashed var(--black-border); border-radius: var(--radius-md); padding: 36px 24px; text-align: center; cursor: pointer; transition: all 0.3s; position: relative; overflow: hidden; }
.upload-zone:hover, .upload-zone.drag-over { border-color: var(--gold); background: var(--gold-glow); }
.upload-zone__input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.upload-zone__icon  { font-size: 2.2rem; opacity: 0.35; margin-bottom: 12px; }
.upload-zone__title { font-size: 0.88rem; font-weight: 600; margin-bottom: 6px; color: var(--white); }
[data-theme="light"] .upload-zone__title { color: var(--text-primary); }
.upload-zone__hint  { font-size: 0.72rem; color: var(--white-dim); }

.upload-preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 10px; margin-top: 14px; }
.upload-preview-item { aspect-ratio: 3/4; position: relative; border-radius: var(--radius-sm); overflow: hidden; background: var(--black-card); border: 1px solid var(--black-border); }
.upload-preview-item img, .upload-preview-item video { width: 100%; height: 100%; object-fit: cover; }
.upload-preview-item__remove { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; background: rgba(155,27,48,0.85); border: none; color: #fff; font-size: 0.7rem; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background 0.2s; }
.upload-preview-item__remove:hover { background: var(--ruby-bright); }
.upload-progress { height: 3px; background: var(--black-border); border-radius: 2px; margin-top: 8px; overflow: hidden; }
.upload-progress__bar { height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-bright)); transition: width 0.3s; border-radius: 2px; }

/* ══════════════════════════════════════════════════════════════
   EXISTING: SAFE AREA / NOTCH
   ══════════════════════════════════════════════════════════════ */
@supports (padding: env(safe-area-inset-bottom)) {
  .wa-widget    { right: calc(14px + env(safe-area-inset-right)); }
  .cart-drawer  { padding-bottom: env(safe-area-inset-bottom); }
  .navbar       { padding-top: env(safe-area-inset-top); }
}

/* ══════════════════════════════════════════════════════════════
   NEW: TRUST STRIP — delivery threshold banner below hero
   ══════════════════════════════════════════════════════════════ */
.trust-strip {
  width: 100%;
  background: var(--black-card, #161616);
  border-bottom: 1px solid var(--black-border, #222);
  padding: 0;
  overflow: hidden;
}

.trust-strip__inner {
  display: flex;
  align-items: stretch;
  justify-content: center;
}

.trust-strip__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-right: 1px solid var(--black-border, #222);
  flex: 1;
  justify-content: center;
}

.trust-strip__item:last-child { border-right: none; }

.trust-strip__icon {
  font-size: 1rem;
  flex-shrink: 0;
  line-height: 1;
}

.trust-strip__text {
  font-family: var(--font-ui);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white-dim, #C8BFB5);
  line-height: 1.3;
  white-space: nowrap;
}

.trust-strip__text strong {
  color: var(--gold, #C9972C);
  font-weight: 700;
}

[data-theme="light"] .trust-strip { background: #f8f5f0; border-color: var(--border-color); }
[data-theme="light"] .trust-strip__item { border-color: var(--border-color); }
[data-theme="light"] .trust-strip__text { color: var(--text-secondary); }

@media (max-width: 480px) {
  .trust-strip__item { padding: 10px 10px; gap: 5px; }
  .trust-strip__text { font-size: 0.58rem; letter-spacing: 0.03em; }
  .trust-strip__icon { font-size: 0.85rem; }
}

/* ══════════════════════════════════════════════════════════════
   NEW: STICKY ADD-TO-CART BAR (product.html only)
   Pins to bottom of screen on product detail page.
   JS adds .sticky-cart-bar--visible when user scrolls past CTA.
   ══════════════════════════════════════════════════════════════ */
.sticky-cart-bar {
  display: none; /* hidden on desktop */
}

@media (max-width: 768px) {
  .sticky-cart-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 800;
    padding: 10px 16px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    background: var(--black-soft, #111);
    border-top: 1px solid var(--black-border, #222);
    /* starts hidden; slides up when JS adds .visible */
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.25,0.46,0.45,0.94);
    box-shadow: 0 -8px 32px rgba(0,0,0,0.55);
    will-change: transform;
  }

  .sticky-cart-bar.visible {
    transform: translateY(0);
  }

  [data-theme="light"] .sticky-cart-bar {
    background: #fff;
    border-color: var(--border-color);
    box-shadow: 0 -8px 32px rgba(0,0,0,0.12);
  }

  .sticky-cart-bar__info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
  }

  .sticky-cart-bar__name {
    font-family: var(--font-ui);
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--white, #F5F0EB);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
  }

  [data-theme="light"] .sticky-cart-bar__name { color: var(--text-primary); }

  .sticky-cart-bar__price {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 300;
    color: var(--gold, #C9972C);
  }

  /* Quantity stepper */
  .sticky-cart-bar__qty {
    display: flex;
    align-items: center;
    border: 1px solid var(--black-border, #222);
    border-radius: var(--radius-sm, 4px);
    overflow: hidden;
    flex-shrink: 0;
    background: var(--black-card, #161616);
  }

  [data-theme="light"] .sticky-cart-bar__qty {
    background: var(--bg-hover, #f5f0eb);
    border-color: var(--border-color);
  }

  .sticky-cart-bar__qty-btn {
    width: 36px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: var(--white-dim, #C8BFB5);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
    font-family: var(--font-ui);
    -webkit-tap-highlight-color: transparent;
  }

  .sticky-cart-bar__qty-btn:active { background: var(--gold-glow); color: var(--gold); }
  [data-theme="light"] .sticky-cart-bar__qty-btn { color: var(--text-secondary); }

  .sticky-cart-bar__qty-val {
    font-family: var(--font-ui);
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--white, #F5F0EB);
    min-width: 28px;
    text-align: center;
    user-select: none;
  }

  [data-theme="light"] .sticky-cart-bar__qty-val { color: var(--text-primary); }

  /* Add to cart CTA */
  .sticky-cart-bar__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 22px;
    background: var(--gold, #C9972C);
    color: #0a0a0a;
    border: none;
    border-radius: var(--radius-sm, 4px);
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.2s, transform 0.15s;
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
  }

  .sticky-cart-bar__cta:active { transform: scale(0.97); background: var(--gold-bright); }

  .sticky-cart-bar__cta:disabled {
    background: var(--black-border);
    color: var(--white-dim);
    cursor: not-allowed;
    transform: none;
  }

  /* Push page content up so nothing hides behind the bar */
  body.has-sticky-cart { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
}

/* ══════════════════════════════════════════════════════════════
   NEW: PRODUCTS PAGE — FILTER / SORT / VIEW TOOLBAR
   Replaces overflowing chip row on mobile
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* Hide the old horizontal chip row */
  .filter-chips-row { display: none; }

  /* New compact toolbar */
  .mobile-filter-toolbar {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
  }

  .mobile-filter-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 11px 8px;
    background: var(--black-card, #161616);
    border: 1px solid var(--black-border, #222);
    border-radius: var(--radius-sm, 4px);
    font-family: var(--font-ui);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--white-dim, #C8BFB5);
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-filter-btn:active,
  .mobile-filter-btn.active {
    border-color: var(--gold, #C9972C);
    color: var(--gold, #C9972C);
  }

  .mobile-filter-btn svg { flex-shrink: 0; }

  /* Active filter count badge */
  .mobile-filter-btn__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--gold, #C9972C);
    color: #0a0a0a;
    font-size: 0.6rem;
    font-weight: 700;
    margin-left: 2px;
  }

  [data-theme="light"] .mobile-filter-btn { background: #fff; border-color: var(--border-color); color: var(--text-secondary); }
}

/* Always hide the toolbar on desktop */
@media (min-width: 769px) {
  .mobile-filter-toolbar { display: none; }
}

/* ══════════════════════════════════════════════════════════════
   NEW: BOTTOM SHEET — Filter/Sort drawer
   ══════════════════════════════════════════════════════════════ */
.bottom-sheet-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.28s;
  -webkit-tap-highlight-color: transparent;
}

.bottom-sheet-backdrop.open { opacity: 1; }

.bottom-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  background: var(--black-soft, #111);
  border-top: 1px solid var(--black-border, #222);
  border-radius: 16px 16px 0 0;
  padding: 0 0 env(safe-area-inset-bottom, 0px);
  max-height: 85svh;
  overflow-y: auto;
  transform: translateY(100%);
  transition: transform 0.32s cubic-bezier(0.32,0.72,0,1);
  will-change: transform;
  overscroll-behavior: contain;
}

.bottom-sheet.open { transform: translateY(0); }

[data-theme="light"] .bottom-sheet {
  background: #fff;
  border-color: var(--border-color);
}

.bottom-sheet__handle {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: var(--black-border, #333);
  margin: 12px auto 0;
}

[data-theme="light"] .bottom-sheet__handle { background: var(--border-color); }

.bottom-sheet__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 12px;
  border-bottom: 1px solid var(--black-border, #222);
}

[data-theme="light"] .bottom-sheet__header { border-color: var(--border-color); }

.bottom-sheet__title {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--white, #F5F0EB);
}

[data-theme="light"] .bottom-sheet__title { color: var(--text-primary); }

.bottom-sheet__close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--white-faint);
  border: 1px solid var(--black-border);
  color: var(--white-dim);
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
}

.bottom-sheet__close:hover { background: var(--ruby-glow); color: var(--ruby-bright); }

.bottom-sheet__body { padding: 16px 20px 24px; }

/* Category chips inside bottom sheet — full width, proper tap targets */
.bs-category-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 20px;
}

.bs-category-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 13px 14px;
  background: var(--black-card, #161616);
  border: 1px solid var(--black-border, #222);
  border-radius: var(--radius-sm, 4px);
  font-family: var(--font-ui);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--white-dim, #C8BFB5);
  cursor: pointer;
  transition: border-color 0.18s, color 0.18s, background 0.18s;
  -webkit-tap-highlight-color: transparent;
  text-align: left;
}

.bs-category-chip .chip-icon { font-size: 1rem; flex-shrink: 0; line-height: 1; }

.bs-category-chip:hover,
.bs-category-chip.active {
  border-color: var(--gold, #C9972C);
  color: var(--gold, #C9972C);
  background: var(--gold-glow, rgba(201,151,44,0.08));
}

[data-theme="light"] .bs-category-chip { background: #f8f5f0; border-color: var(--border-color); color: var(--text-secondary); }
[data-theme="light"] .bs-category-chip.active { border-color: var(--gold); color: var(--gold); background: rgba(201,151,44,0.06); }

/* Price range section inside sheet */
.bs-section-label {
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold, #C9972C);
  margin-bottom: 12px;
}

/* Apply button at bottom of sheet */
.bs-apply-btn {
  width: 100%;
  padding: 15px;
  background: var(--gold, #C9972C);
  color: #0a0a0a;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  margin-top: 20px;
  transition: background 0.2s;
}

.bs-apply-btn:active { background: var(--gold-bright); }

/* ══════════════════════════════════════════════════════════════
   NEW: HORIZONTAL PRODUCT CARDS (mobile list view)
   Shown on mobile instead of 2-column grid
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* Switch grid to single column */
  .products-grid,
  .products-grid--4,
  .products-grid--3 {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  /* Horizontal card layout */
  .product-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch;
    min-height: 0;
  }

  /* Image slot: fixed square, contained */
  .product-card__image-wrap {
    width: 96px !important;
    min-width: 96px;
    height: 96px !important;
    flex-shrink: 0;
    border-radius: var(--radius-sm) 0 0 var(--radius-sm) !important;
    overflow: hidden;
    position: relative;
  }

  .product-card__image {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important; /* contain: no blurry stretch */
    object-position: center;
    background: var(--black-card);
  }

  /* Overlay & quick-add hidden on mobile cards (we have + Cart inline) */
  .product-card__overlay,
  .product-card__quick-add { display: none !important; }

  /* Body: flex column, fills remaining width */
  .product-card__body {
    flex: 1;
    min-width: 0;
    padding: 12px 14px !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0;
  }

  .product-card__category {
    font-size: 0.58rem !important;
    margin-bottom: 3px;
    letter-spacing: 0.1em;
  }

  .product-card__name {
    font-size: 0.85rem !important;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
  }

  .product-card__pricing {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
  }

  .product-card__price {
    font-size: 1rem !important;
    font-family: var(--font-display);
    color: var(--gold) !important;
  }

  .product-card__price-old {
    font-size: 0.75rem !important;
    text-decoration: line-through;
  }

  /* Inline +Cart button replaces hover quick-add */
  .product-card__inline-cart {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-top: 8px;
  }

  .product-card__inline-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 13px;
    background: var(--gold, #C9972C);
    color: #0a0a0a;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-ui);
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s, transform 0.12s;
    -webkit-tap-highlight-color: transparent;
  }

  .product-card__inline-cart-btn:active { transform: scale(0.96); background: var(--gold-bright); }

  /* Badges repositioned for horizontal layout */
  .product-card__badges {
    position: absolute;
    top: 5px;
    left: 5px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    z-index: 2;
  }

  .product-card__badges .badge {
    font-size: 0.55rem !important;
    padding: 2px 5px !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   NEW: SCARCITY BADGE — "Only N left"
   ══════════════════════════════════════════════════════════════ */
.scarcity-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ruby-bright, #C0213A);
  margin-top: 4px;
}

.scarcity-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ruby-bright, #C0213A);
  flex-shrink: 0;
  animation: scarcity-pulse 1.8s ease-in-out infinite;
}

@keyframes scarcity-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.35; }
}

/* ══════════════════════════════════════════════════════════════
   NEW: STAR RATING COMPONENT
   ══════════════════════════════════════════════════════════════ */
.star-rating {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 4px;
}

.star-rating__stars {
  display: flex;
  gap: 1px;
}

.star-rating__star {
  font-size: 0.72rem;
  line-height: 1;
  color: var(--gold, #C9972C);
}

.star-rating__star.empty { color: var(--black-border, #333); }

.star-rating__count {
  font-family: var(--font-ui);
  font-size: 0.65rem;
  color: var(--white-dim, #C8BFB5);
}

[data-theme="light"] .star-rating__count { color: var(--text-secondary); }

/* ══════════════════════════════════════════════════════════════
   NEW: CATEGORY HORIZONTAL SCROLLER
   Per-category swipe rows on products page
   ══════════════════════════════════════════════════════════════ */
.category-section {
  margin-bottom: 40px;
}

.category-section__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 0 2px;
}

.category-section__title {
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold, #C9972C);
  display: flex;
  align-items: center;
  gap: 8px;
}

.category-section__see-all {
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white-dim, #C8BFB5);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s;
}

.category-section__see-all:hover { color: var(--gold); }

@media (max-width: 768px) {
  .category-section__scroll-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    scroll-snap-type: x mandatory;
    scroll-padding: 0 16px;
    margin: 0 -16px;
    padding: 0 16px;
  }

  .category-section__scroll-wrap::-webkit-scrollbar { display: none; }

  .category-section__scroll-track {
    display: flex;
    gap: 10px;
    /* 2.5 cards visible: signals swipeability */
    width: max-content;
    padding-right: 16px;
  }

  /* Each card in the swipe row */
  .category-section__card {
    width: 140px;
    flex-shrink: 0;
    scroll-snap-align: start;
    background: var(--black-card, #161616);
    border: 1px solid var(--black-border, #222);
    border-radius: var(--radius-md, 8px);
    overflow: hidden;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .category-section__card:active { border-color: var(--gold); }

  [data-theme="light"] .category-section__card { background: #fff; border-color: var(--border-color); }

  .category-section__card-img {
    width: 100%;
    height: 130px;
    object-fit: contain;
    object-position: center;
    background: var(--black-soft);
    display: block;
  }

  .category-section__card-body {
    padding: 10px 10px 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
  }

  .category-section__card-name {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--white, #F5F0EB);
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  [data-theme="light"] .category-section__card-name { color: var(--text-primary); }

  .category-section__card-price {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--gold, #C9972C);
    margin-top: auto;
    padding-top: 6px;
  }

  .category-section__card-add {
    width: 100%;
    padding: 8px;
    background: rgba(201,151,44,0.1);
    border: 1px solid rgba(201,151,44,0.25);
    border-radius: var(--radius-sm);
    font-family: var(--font-ui);
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gold);
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .category-section__card-add:active { background: rgba(201,151,44,0.22); }
}

/* ── PRODUCTS PAGE ── */
#products-section {
  padding-top: 96px;
}

@media (max-width: 768px) {
  #products-section {
    padding-top: 88px;
  }
}