/*
 * common.css - combined universal public-frontend primitives (generated 2026-06-17; expanded 2026-06-18).
 * Concatenation, IN ORDER, of these source files (still the editable source of truth):
 *   assets/frontend/css/core/tokens-baseline.css
 *   assets/frontend/css/brand/header-baseline.css
 *   assets/frontend/css/brand/footer-baseline.css
 *   assets/frontend/css/brand/buttons-baseline.css
 *   assets/frontend/css/brand/forms-baseline.css
 *   assets/frontend/css/brand/product-card-baseline.css
 *   assets/frontend/css/brand/pagination-baseline.css
 *   assets/frontend/css/brand/breadcrumb-baseline.css
 *   assets/frontend/css/brand/seo-content-baseline.css
 *   assets/frontend/css/components/verified-badge.css
 * Plus exact shared live rules moved out of pages/category.css:
 *   site chrome/search/cart/mobile menu
 *   footer/sitemap
 *   product-card component
 * Purpose: one request instead of many tiny universal CSS files in frontend_layout.php.
 * REGENERATE if any source above changes (concatenate in the same order).
 * NOT included (left as separate links - not universal): brand-chips, price-table, blog-card.
 */

/* ===== tokens-baseline.css ===== */
/* tokens — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

:root {
    --font-sans: 'SolaimanLipi', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --color-text-primary: #1C1C1A;
    --color-text-secondary: #5F5E5A;
    --color-text-tertiary: #6B6964;
    --color-border-secondary: #D3D1C7;
    --color-border-tertiary: #E8E8E4;
    --border-radius-md: 8px;
    /* ── BRAND COLORS (locked to logo) ──
       Green:  #149A49  (BDStall green — house roof, "BD" wordmark)
       Orange: #F58320  (BDStall orange — house body; canonical brand orange) */
    --green: #149A49;
    --green-dark: #0E7A38;
    --green-light: #D9F0E0;
    --green-subtle: #EAF8EE;
    --orange: #F58320;
    --orange-dark: #C56612;
    --orange-light: #FCE4CC;
    --color-bg-subtle: #FAFBFD;
    --color-warning-bg: #FFFBEB;
    --color-warning-border: #FDE68A;
    --color-warning-text: #92400E;
    --color-warning-strong: #78350F;
  }

html { font-size: 16px; margin: 0; padding: 0; background: white; }

* { box-sizing: border-box; }

body {
    margin: 0;
    background: #ECECE6 !important;
    font-family: var(--font-sans);
    color: var(--color-text-primary);
    -webkit-font-smoothing: antialiased;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }

.page-main { flex: 1 0 auto; }

/* Reserve space for the fixed mobile tab bar — mobile only */
@media (max-width: 767px) {
    body { padding-bottom: 62px; }
  }

@keyframes sdFadeIn { from { opacity: 0; } to { opacity: 1; } }

@keyframes search-dropdown-slide-down {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
  }

@keyframes ddFadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

@keyframes mobile-menu-slide-right { from { transform: translateX(-28px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

@keyframes bannerScroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
  }

@keyframes skeleton-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
  }

html { scroll-behavior: smooth; }

/* ===== header-baseline.css ===== */
/* header — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.header {
    background: white;
  }

.header-inner {
    max-width: 1200px; margin: 0 auto;
    padding: 7px 16px;
    display: flex; align-items: center; justify-content: space-between;
  }

.logo { display: flex; align-items: center; gap: 8px; }

.logo img { width: auto; height: 34px; max-width: 160px; display: block; }

.logo-icon { width: 36px; height: 36px; background: #EAF3DE; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 1.125rem; }

.logo-text { font-size: 1.375rem; font-weight: 700; line-height: 1; }

.header-actions { display: flex; align-items: center; gap: 8px; }

.hdr-icon-btn {
    display: inline-flex; align-items: center; gap: 6px;
    height: 34px; padding: 0 12px 0 10px;
    background: var(--orange-light); color: var(--orange-dark); border-radius: 8px;
    font-size: 0.8125rem; font-weight: 700; line-height: 1;
    text-decoration: none;
    border: none; cursor: pointer; font-family: inherit;
    flex-shrink: 0; white-space: nowrap;
    transition: background 0.15s;
}

.hdr-earn-label { display: none; }

.hdr-icon-btn:hover { background: #F9D8B0; }

.hdr-icon-btn:active { background: var(--orange-light); }

/* Sized to match the "Sell Item" button (.btn-sell) — only the colour differs */
.hdr-lang-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 7px;
    background: #EAF3DE; border: none; border-radius: 6px;
    font-size: 0.8125rem; font-weight: 600; line-height: 1.2;
    color: var(--green-dark);
    font-family: inherit; cursor: pointer; text-decoration: none;
    flex-shrink: 0; white-space: nowrap;
    transition: background 0.15s;
  }

.hdr-lang-btn:hover { background: #DCEBC8; }

.hdr-lang-btn:active { background: var(--green-light); }

.hdr-lang-globe { display: flex; align-items: center; }

.hdr-lang-code { letter-spacing: 0.3px; }

.header-cart { display: none; }

.header-actions .cart-icon-wrap { display: none; }

.btn-login { display: none; }

.cart-badge {
    position: absolute;
    top: -6px; right: -8px;
    min-width: 16px; height: 16px;
    padding: 0 4px;
    background: var(--orange); color: white;
    border-radius: 8px;
    font-size: 0.625rem; font-weight: 700;
    display: none; align-items: center; justify-content: center;
    line-height: 1;
    border: 1.5px solid white;
    font-family: var(--font-sans);
  }

.cart-badge.show { display: flex; }

.cart-btn {
    flex: 1; padding: 12px; border: none; border-radius: 8px;
    font-size: 0.875rem; font-weight: 600; cursor: pointer;
    font-family: inherit;
  }

.cart-btn-compare {
    background: white; color: var(--green-dark);
    border: 1.5px solid var(--green);
  }

.cart-btn-compare:active { background: #EAF3DE; }

.cart-btn-checkout {
    background: var(--orange-dark); color: white;
  }

.cart-btn-checkout:active { background: var(--orange-dark); }

.hamburger { display: flex; flex-direction: column; gap: 2px; }

.hamburger span { width: 14px; height: 2px; background: white; border-radius: 1px; display: block; }

@media (min-width: 768px) {
    .header-inner { padding: 8px 0; }
    .header-actions { gap: 10px; align-items: center; }
    .hdr-earn-label { display: inline; }
    #affiliateBtn { height: 34px; padding: 0 10px; gap: 6px; border-radius: 6px; font-size: 0.8125rem; font-weight: 600; line-height: 1; }
    #affiliateBtn svg { width: 14px; height: 14px; }
    .header-cart { display: inline; font-size: 1.25rem; }
    .header-actions .cart-icon-wrap { display: inline-flex; align-items: center; }
    .header-actions .cart-icon-wrap button { display: flex; align-items: center; justify-content: center; height: 28px; width: 28px; }
    .btn-sell  { display: inline-flex !important; align-items: center; height: 28px; padding: 0 10px; gap: 5px; background: var(--orange); color: white; border: none; border-radius: 6px; font-size: 0.75rem; font-weight: 700; text-decoration: none; white-space: nowrap; flex-shrink: 0; cursor: pointer; font-family: inherit; }
    .btn-login { display: inline-flex !important; align-items: center; height: 28px; padding: 0 12px; background: white; color: #1C1C1A; border: 1px solid #D3D1C7; border-radius: 6px; font-size: 0.75rem; font-weight: 600; text-decoration: none; white-space: nowrap; flex-shrink: 0; }
    .cat-nav-inner { padding: 0 16px; }
    .cat-nav a { padding: 12px 14px; font-size: 0.875rem; }
    .cat-nav a.all { padding: 12px 16px; }
  }

/* ── Tablet fix (768px–1249px): restore side padding removed by 768px rule ── */
@media (min-width: 768px) and (max-width: 1249px) {
  .header-inner { padding: 8px 16px; }
  .search-wrap { padding: 0 16px 16px; }
  .search-wrap.pinned { padding: 8px 16px; }
  .search-dropdown { left: 16px; right: 16px; }
  .search-wrap.pinned .search-dropdown { left: 16px; right: 16px; }
}

/* ===== footer-baseline.css ===== */
/* footer — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

/* ── GO TO TOP BUTTON ── */
.go-to-top {
    position: fixed;
    bottom: 32px;
    right: 24px;
    z-index: 950;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    padding: 0;
    background: white;
    color: var(--green-dark);
    box-shadow: 0 4px 16px rgba(0,0,0,0.14);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease, box-shadow 0.18s;
    /* stack ring SVG and arrow on top of each other */
    display: grid;
    place-items: center;
}

.go-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.go-to-top:hover {
    box-shadow: 0 6px 22px rgba(0,0,0,0.20);
}

.go-to-top:active {
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

/* Ring SVG — sits full-size behind the arrow */
.go-to-top-ring {
    position: absolute;
    top: 0; left: 0;
    width: 36px;
    height: 36px;
    /* Start drawing from the top (12 o'clock) */
    transform: rotate(-90deg);
    pointer-events: none;
}

.go-to-top-ring-track {
    fill: none;
    stroke: #E0EFE8;
    stroke-width: 3;
}

.go-to-top-ring-fill {
    fill: none;
    stroke: var(--green);
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.1s linear;
}

/* Arrow icon — centered on top of ring */
.go-to-top-arrow {
    position: relative;
    display: block;
    flex-shrink: 0;
}

/* On mobile push it above the tab bar */
@media (max-width: 767px) {
    .go-to-top {
        bottom: 76px;
        right: 16px;
        width: 32px;
        height: 32px;
    }
    .go-to-top-ring {
        width: 32px;
        height: 32px;
    }
}

.footer-link { color: #fff; font-size: 0.8125rem; line-height: 2; transition: color 0.15s; }

.footer-link:hover { color: white; }

.footer-inner { max-width: 1200px; margin: 0 auto; padding: 28px 16px 16px; }

/* Mobile: logo spans full width, link columns pair as 2×2 */
.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 16px;
    padding-bottom: 24px;
    border-bottom: 1px solid #2E2E2A;
}

.footer-grid > div:first-child { grid-column: 1 / -1; }

.footer-logo-row { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }

.footer-desc { font-size: 0.8125rem; color: #fff; line-height: 1.6; margin: 0 0 16px; }

.footer-social { display: flex; gap: 8px; flex-wrap: wrap; }

.footer-col-title { font-size: 0.8125rem; font-weight: 700; color: white; margin: 0 0 10px; text-transform: uppercase; letter-spacing: 0.6px; }

.trust-items { display: flex; gap: 10px 14px; font-size: 0.75rem; color: #fff; flex-wrap: wrap; }

.footer-trust { display: flex; flex-direction: column; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid #2E2E2A; gap: 12px; }

.trust-check svg { vertical-align: -2px; }

.footer-bottom { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding-top: 16px; }

.footer-copy { font-size: 0.75rem; color: #fff; margin: 0; }

.footer-links { display: flex; gap: 14px; flex-wrap: wrap; }

.footer-links a { font-size: 0.75rem; color: #fff; }

@media (min-width: 768px) {
    .footer-inner { padding: 36px 0 22px; }
    .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr 1.2fr; gap: 32px; padding-bottom: 28px; }
    .footer-grid > div:first-child { grid-column: auto; }
    .footer-col-title { margin-bottom: 14px; }
    .footer-trust { flex-direction: row; justify-content: space-between; align-items: center; padding: 18px 0; gap: 14px; }
    .trust-items { gap: 22px; }
    .footer-bottom { flex-direction: row; justify-content: space-between; align-items: center; padding-top: 18px; gap: 12px; }
    .footer-links { gap: 20px; flex-wrap: nowrap; }
}

/* ── Tablet fix (767px–1249px): restore side padding removed by 768px rule ── */
@media (min-width: 768px) and (max-width: 1249px) {
  .footer-inner { padding: 36px 16px 22px; }
}

/* ===== buttons-baseline.css ===== */
/* shared-buttons — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.btn-sell { display: none; }

.btn-compare { padding: 10px 14px; background: var(--orange-dark); color: white; border: none; border-radius: 6px; font-size: 0.75rem; font-weight: 600; white-space: nowrap; }

.btn-compare-full {
    display: block; box-sizing: border-box; text-align: center;
    width: 100%; padding: 10px;
    background: var(--orange-dark); color: white;
    border: none; border-radius: 6px;
    font-size: 0.8125rem; font-weight: 600; min-height: 44px;
    line-height: 1.4; cursor: pointer;
  }

.btn-visit {
    display: block; box-sizing: border-box; text-align: center;
    width: 100%; padding: 9px 8px;
    background: white; color: var(--orange-dark);
    border: 1px solid var(--orange); border-radius: 6px;
    font-size: 0.8125rem; font-weight: 600; min-height: 44px;
    line-height: 1.4; cursor: pointer;
  }

.btn-open-stall { padding: 13px 24px; background: var(--green); color: white; border: none; border-radius: 6px; font-size: 0.875rem; font-weight: 700; min-height: 44px; flex: 1; }

.btn-seller-learn { padding: 13px 20px; background: white; color: var(--green); border: 1px solid var(--green); border-radius: 6px; font-size: 0.875rem; font-weight: 600; min-height: 44px; flex: 1; }

/* ===== forms-baseline.css ===== */
/* shared-forms — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.filter-option input[type="radio"] {
    width: 16px; height: 16px;
    accent-color: var(--green);
    margin: 0; flex-shrink: 0;
  }

.filter-option input[type="checkbox"] {
    width: 16px; height: 16px;
    accent-color: var(--green);
    margin: 0; flex-shrink: 0;
  }

/* ===== product-card-baseline.css ===== */
/* shared-cards — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.card { background: white; border-radius: 8px; overflow: hidden; border: 1px solid #E8E8E4; }

.card-img { position: relative; aspect-ratio: 1.5; }

.card-tag { position: absolute; top: 8px; left: 8px; color: white; font-size: 0.6875rem; font-weight: 600; padding: 3px 8px; border-radius: 4px; }

.card-year { position: absolute; bottom: 8px; right: 8px; background: rgba(0,0,0,0.7); color: white; font-size: 0.6875rem; padding: 3px 6px; border-radius: 4px; }

.card-body { padding: 12px 14px; }

.card-title { font-size: 0.875rem; font-weight: 600; margin: 0; line-height: 1.3; }

.card-price { font-size: 1rem; font-weight: 700; color: var(--green); margin: 4px 0 2px; }

.card-location { font-size: 0.75rem; color: #6B6964; margin: 0; }

.product-img { position: relative; width: 100%; aspect-ratio: 1 / 1; overflow: hidden; background: #f8f8f8; }
.product-img picture,
.product-img img { display: block; width: 100%; height: 100%; object-fit: contain; }

/* ===== pagination-baseline.css ===== */
/* shared-pagination — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.pgn-context {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--color-text-tertiary, #9CA3AF);
    margin-bottom: 10px;
}

.pagination {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.pgn-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-text-primary, #1F2937);
    text-decoration: none;
    border: 1px solid var(--color-border-secondary, #D1D5DB);
    background: white;
    transition: background 0.12s, border-color 0.12s, color 0.12s;
    white-space: nowrap;
    cursor: pointer;
}

a.pgn-btn:hover {
    background: var(--green-light, #EAF3DE);
    border-color: var(--green, #149A49);
    color: var(--green-dark, #0D6E36);
}

/* Current page */
.pgn-btn.active {
    background: var(--green, #149A49);
    border-color: var(--green, #149A49);
    color: white;
    font-weight: 700;
    pointer-events: none;
    cursor: default;
}

/* Disabled prev on page 1 / next on last page */
.pgn-btn.disabled {
    color: var(--color-text-tertiary, #9CA3AF);
    border-color: var(--color-border-tertiary, #E5E7EB);
    background: var(--color-bg-secondary, #F9FAFB);
    pointer-events: none;
    cursor: default;
}

/* Ellipsis */
.pgn-info {
    color: var(--color-text-tertiary, #9CA3AF);
    padding: 0 4px;
    font-size: 0.875rem;
    line-height: 36px;
}

/* ===== breadcrumb-baseline.css ===== */
/* shared-breadcrumb — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.breadcrumb {
    display: flex; align-items: center; flex-wrap: wrap;
    padding: 12px 16px 6px;
    font-size: 0.75rem; color: var(--color-text-tertiary);
    overflow-x: auto; white-space: nowrap;
    scrollbar-width: none;
  }

.breadcrumb::-webkit-scrollbar { display: none; }

.breadcrumb a { display: inline-flex; align-items: center; gap: 4px; color: var(--color-text-tertiary); }

.breadcrumb a:hover { color: var(--green); }

.breadcrumb .sep { display: inline-flex; align-items: center; margin: 0 6px; color: var(--color-text-tertiary); }
.breadcrumb .sep svg { stroke-width: 3; margin-top: 2px; }

.breadcrumb svg { display: block; }

.breadcrumb .current { display: inline-flex; align-items: center; color: var(--color-text-primary); font-weight: 700; }

@media (min-width: 1024px) {
    .breadcrumb { padding: 14px 0 8px; font-size: 0.8125rem; max-width: 1200px; margin: 0 auto; }
  }

/* ── Tablet fix (1024px–1249px): restore side padding removed by 1024px rule ── */
@media (min-width: 1024px) and (max-width: 1249px) {
  .breadcrumb { padding: 14px 16px 8px; }
}

/* ===== seo-content-baseline.css ===== */
/* shared-seo-content — extracted from v1-category-18.html
   Source of truth — based on baseline file. */

.faq-q {
    font-size: 0.875rem; font-weight: 600;
    margin: 0;
    cursor: pointer;
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 12px;
  }

.faq-q::after {
    content: '+';
    font-size: 1.375rem; font-weight: 400;
    color: var(--green); flex-shrink: 0;
    line-height: 1;
  }

.faq-item.open .faq-q::after { content: '−'; }

.faq-a {
    font-size: 0.875rem; line-height: 1.6;
    color: var(--color-text-secondary);
    margin: 0;
    max-height: 0; overflow: hidden;
    transition: max-height 0.3s ease, margin-top 0.3s ease, padding 0.3s ease;
  }

.faq-item.open .faq-a { max-height: 500px; margin-top: 8px; }

/* ===== verified-badge.css ===== */
/* ============================================================================
   Verified Badge — single shared component
   ----------------------------------------------------------------------------
   One component used across stall list, stall details, product details seller
   card, call panel, and market details. Rendered via verified_badge() /
   stall_verified_badge() (application/helpers/verification_helper.php).

   Tiers (color-coded by what is verified):
     .nid   Blue   #2563EB   NID Verified
     .tl    Green  #149A49   Trade License Verified
     .both  Gold   gradient  NID + Trade License Verified

   Sizes: default 18px · .sm 14px · .lg 22px
   ============================================================================ */

.vbadge-wrap {
  position: relative;
  display: inline-flex;
  vertical-align: middle;
  line-height: 0;
}

.vbadge-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

/* The check comes from svg_icon('check', …); CSS owns its size + weight so the
   tick reads crisply on the small colored circle (stroke-width:3 overrides the
   helper's default of 2). */
.vbadge-circle svg {
  width: 64%;
  height: 64%;
  stroke-width: 3;
}

.vbadge-circle.sm { width: 14px; height: 14px; }
.vbadge-circle.lg { width: 22px; height: 22px; }

.vbadge-circle.nid  { background: #2563EB; }
.vbadge-circle.tl   { background: #149A49; }
.vbadge-circle.both { background: linear-gradient(135deg, #F59E0B, #D97706); }

/* Tooltip — shown on hover (mouse) and focus-within (keyboard). Real text in
   the DOM, so screen readers can reach it. */
.vbadge-tooltip {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: #1A1A1A;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  padding: 4px 8px;
  border-radius: 5px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease, visibility 0.12s ease;
  z-index: 60;
}

.vbadge-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 4px solid transparent;
  border-top-color: #1A1A1A;
}

.vbadge-wrap:hover .vbadge-tooltip,
.vbadge-wrap:focus-within .vbadge-tooltip {
  opacity: 1;
  visibility: visible;
}



/* ===== shared rules moved from pages/category.css (site chrome/footer/product cards) ===== */
/* ═══════════════════════════════════════════════════════════
 * BASE RESETS — element defaults scoped to this page
 * ═══════════════════════════════════════════════════════════ */
button { cursor: pointer; font-family: inherit; }

a { cursor: pointer; text-decoration: none; color: inherit; }


/* ═══════════════════════════════════════════════════════════
 * MOBILE TAB BAR — fixed bottom nav shown on mobile only
 * ═══════════════════════════════════════════════════════════ */
.mobile-tab-bar {
    display: flex;
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 900;
    background: white; border-top: 1px solid #E8E8E4;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.08);
    padding-bottom: env(safe-area-inset-bottom);
  }

.mob-tab {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px; padding: 8px 4px; border: none; background: none;
    font-family: inherit; cursor: pointer; color: #6B6964;
    transition: color 0.15s;
  }

.mob-tab.active, .mob-tab:active { color: var(--green); }

.mob-tab-icon { display: flex; align-items: center; justify-content: center; }

.mob-tab-label { font-size: 0.6875rem; font-weight: 600; }


/* ───────────────────────────────────────────────────────────
 * CART SHEET — slide-up panel contents (items, footer, empty state)
 * ─────────────────────────────────────────────────────────── */
.cart-icon-wrap { position: relative; display: inline-flex; }

.cart-item {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 12px;
    background: white; border: 1px solid #E8E8E4; border-radius: 10px;
    margin-bottom: 8px;
  }

.cart-item-img {
    flex-shrink: 0;
    width: 52px; height: 52px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem;
  }

.cart-item-info { flex: 1; min-width: 0; }

.cart-item-name {
    font-size: 0.875rem; font-weight: 600; color: #1C1C1A;
    margin: 0 0 3px;
    overflow: hidden; text-overflow: ellipsis;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    word-break: break-word;
  }

.cart-item-stall { font-size: 0.75rem; color: #6B6964; margin: 0 0 4px; }

.cart-item-price { font-size: 0.875rem; font-weight: 700; color: var(--green-dark); margin: 0; }

.cart-item-remove {
    flex-shrink: 0;
    width: 28px; height: 28px;
    background: #F5F5F1; border: none; border-radius: 6px;
    color: #6B6964; font-size: 0.875rem; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    font-family: inherit;
  }

.cart-item-remove:active { background: #E8E8E4; color: #1C1C1A; }

.cart-empty {
    text-align: center; padding: 40px 20px;
  }

.cart-empty-icon { font-size: 3rem; margin-bottom: 12px; opacity: 0.5; }

.cart-empty-text { font-size: 0.9375rem; color: #5F5E5A; margin: 0 0 6px; }

.cart-empty-sub { font-size: 0.8125rem; color: #8D8B84; margin: 0; }

.cart-footer {
    flex-shrink: 0;
    padding: 14px 16px;
    border-top: 1px solid #E8E8E4;
    background: white;
  }

.cart-total-row {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 12px;
  }

.cart-total-label { font-size: 0.8125rem; color: #5F5E5A; font-weight: 600; }

.cart-total-amount { font-size: 1.125rem; font-weight: 700; color: #1C1C1A; }

.cart-actions { display: flex; gap: 8px; }


/* Tablet and up — hide mobile tab bar, static header, show sell/login buttons */
@media (min-width: 768px) {
    .mobile-tab-bar { display: none; }
    .btn-sell  { display: inline-flex; align-items: center; height: 28px; gap: 5px; padding: 0 10px; background: var(--orange); color: white; border: none; border-radius: 6px; font-size: 0.75rem; font-weight: 700; text-decoration: none; white-space: nowrap; flex-shrink: 0; }
    .btn-login { display: inline-flex; align-items: center; height: 28px; padding: 0 12px; background: white; color: #1C1C1A; border: 1px solid #D3D1C7; border-radius: 6px; font-size: 0.75rem; font-weight: 600; text-decoration: none; white-space: nowrap; flex-shrink: 0; }
    /* Desktop search — these MQ rules come after all base rules in this file, so they win */
    .search-wrap { padding: 0 16px 16px; }
    .search-wrap.pinned { padding: 8px 16px; }
    .search-box input { padding: 13px 18px; font-size: 0.9375rem; }
    .search-box button { padding: 13px 36px; font-size: 0.875rem; }
    .search-dropdown { top: calc(100% - 16px); left: 16px; right: 16px; }
    .search-wrap.pinned .search-dropdown { top: calc(100% - 8px); left: 16px; right: 16px; }
  }

.search-wrap {
    max-width: 1200px; margin: 0 auto; padding: 0 0 12px;
    background: white;
    transition: box-shadow 0.2s ease;
    position: relative;
  }

.search-wrap.pinned {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 800;
    padding: 8px 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    border-radius: 0px 0px 4px 4px;
  }

.search-wrap-placeholder { display: none; }

.search-wrap-placeholder.active { display: block; }

.search-box {
    display: flex; align-items: center; background: white;
    border: 2px solid var(--green); border-radius: 8px; overflow: hidden;
    box-shadow: 0 2px 8px rgba(99,153,34,0.1);
    transition: border-radius 0.15s ease;
  }

.search-wrap.dropdown-open .search-box {
    border-radius: 8px 8px 0 0;
  }

.search-box input { flex: 1; border: none; padding: 11px 12px; font-size: 0.875rem; outline: none; font-family: inherit; }

.search-box button { padding: 11px 18px; background: var(--green); color: white; border: none; font-size: 0.8125rem; font-weight: 600; white-space: nowrap; cursor: pointer; font-family: inherit; }

#top-search-clear {
    background: none; color: #6B6964; font-size: 1rem; padding: 0 10px;
    display: none; cursor: pointer; border: none;
  }

#top-search-clear.visible { display: inline-block; }

.search-backdrop {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.35);
    z-index: 790;
    animation: sdFadeIn 0.18s ease;
  }

.search-backdrop.open { display: block; }

.search-dropdown {
    display: none;
    position: absolute;
    /* Anchor to bottom of search box (which is the bottom of search-wrap minus its bottom padding) */
    top: calc(100% - 12px);
    left: 0; right: 0;
    background: white;
    /* Match search-box's green border so it reads as one continuous panel */
    border: 2px solid var(--green);
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.14);
    z-index: 810;
    overflow: hidden;
    animation: search-dropdown-slide-down 0.18s ease;
  }

.search-dropdown.open { display: block; }

.search-wrap.pinned .search-dropdown { top: calc(100% - 8px); left: 0; right: 0; }

/* Mobile: add horizontal padding so search bar aligns with page content */
@media (max-width: 767px) {
    .search-wrap { padding: 0 16px 12px; }
    .search-wrap.pinned { padding: 8px 16px; }
    .search-dropdown { left: 16px; right: 16px; }
    .search-wrap.pinned .search-dropdown { left: 16px; right: 16px; }
}

.search-dropdown-body {
    padding: 14px 16px 18px;
    max-height: 70vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }


/* ───────────────────────────────────────────────────────────
 * SEARCH DROPDOWN — chip rows and section labels inside the panel
 * ─────────────────────────────────────────────────────────── */
.search-dropdown-section-label {
    font-size: 0.6875rem; font-weight: 700; color: #6B6964;
    text-transform: uppercase; letter-spacing: 0.7px;
    padding: 6px 4px 8px; margin: 4px 0 2px;
  }

.search-dropdown-section-label:first-child { margin-top: 0; }

.search-dropdown-chip-row {
    display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px;
  }

.search-dropdown-chip {
    padding: 7px 14px; background: #EAF3DE;
    border: 1.5px solid var(--green-light); border-radius: 20px;
    font-size: 0.8125rem; font-weight: 500; color: var(--green-dark);
    font-family: inherit; cursor: pointer;
    transition: background 0.12s, border-color 0.12s;
  }

.search-dropdown-chip:hover { background: var(--green-light); border-color: var(--green); }

/* ── LIVE SEARCH RESULTS inside search dropdown ── */
.live-result-item.active {
    border-color: var(--green);
    background: var(--green-light);
}

.live-result-product {
    flex: 1;
    min-width: 0;
}

.live-result-thumb {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 4px;
    background: #f0f0f0;
    flex-shrink: 0;
}

.live-result-price {
    color: var(--green);
    font-weight: 600;
}

.search-dropdown-view-all {
    display: block;
    margin: 10px -4px -4px;
    padding: 12px 16px;
    text-align: center;
    background: #f8f8f8;
    color: var(--green);
    font-weight: 600;
    font-size: 0.875rem;
    border-top: 1px solid #e8e8e4;
    border-radius: 0 0 6px 6px;
    text-decoration: none;
}

.search-dropdown-view-all:hover {
    background: var(--green);
    color: white;
}

.search-stalls-more-btn {
    display: block;
    width: 100%;
    margin: 2px 0 4px;
    padding: 8px 16px;
    text-align: center;
    background: none;
    border: none;
    color: var(--green);
    font-weight: 600;
    font-size: 0.8125rem;
    cursor: pointer;
}

.search-stalls-more-btn:hover {
    text-decoration: underline;
}


/* ═══════════════════════════════════════════════════════════
 * CATEGORY NAVIGATION — desktop green nav bar + mobile pill strip
 * ═══════════════════════════════════════════════════════════ */
.category-navigation { display: none; background: var(--green); }

.category-navigation-inner {
    max-width: 1200px; margin: 0 auto; padding: 0;
    display: flex; align-items: stretch; overflow-x: auto;
    scrollbar-width: none;
  }

.category-navigation-inner::-webkit-scrollbar { display: none; }

.category-navigation a { padding: 10px 12px; color: white; font-size: 0.8125rem; white-space: nowrap; flex-shrink: 0; }

.category-navigation a.all { padding: 10px 12px; background: var(--green-dark); display: flex; align-items: center; gap: 8px; font-weight: 600; }

.mobile-cats {
    overflow-x: auto; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap; padding: 0 16px 12px;
    background: white;
    display: flex; gap: 8px;
  }

.mobile-cats::-webkit-scrollbar { display: none; }

.mobile-cats-inner { display: inline-flex; gap: 8px; }

.mobile-category-pill {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 5px 10px; border-radius: 6px;
    border: 1.5px solid #E8E8E4; background: white;
    font-size: 0.75rem; font-weight: 500; color: #1C1C1A;
    white-space: nowrap; min-height: 32px; cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
  }

.mobile-category-pill:hover, .mobile-category-pill.active {
    border-color: var(--green); background: #EAF3DE; color: var(--green-dark);
  }


/* 1130px and up — switch to desktop category navigation, hide mobile pill strip */
@media (min-width: 1130px) {
    .category-navigation { display: block; overflow: visible; }
    .mobile-cats { display: none; }
    .category-navigation-inner { overflow: visible; padding: 0; }
  }


/* ───────────────────────────────────────────────────────────
 * DESKTOP DROPDOWN — simple 1-level dropdown off category nav
 * ─────────────────────────────────────────────────────────── */
.category-navigation-item {
    position: relative; display: flex; align-items: stretch;
  }

.category-navigation-item > a {
    display: flex; align-items: center; gap: 4px;
    padding: 12px 14px; color: white; font-size: 0.875rem; white-space: nowrap; flex-shrink: 0;
    transition: background 0.15s;
  }

.category-navigation-item > a:hover { background: rgba(255,255,255,0.12); }

.category-navigation-item .caret { font-size: 0.5625rem; opacity: 0.75; transition: transform 0.2s; }

.category-navigation-item:hover .caret { transform: rotate(180deg); }

.category-dropdown {
    display: none;
    position: absolute; top: 100%; left: 0;
    background: white; border-radius: 0 0 10px 10px;
    border: 1px solid #E8E8E4; border-top: 2px solid var(--green);
    box-shadow: 0 8px 28px rgba(0,0,0,0.12);
    min-width: 220px; z-index: 500;
    padding: 8px 0;
    animation: ddFadeIn 0.15s ease;
  }

.category-navigation-item:hover .category-dropdown { display: block; }

.dd-section-label {
    font-size: 0.625rem; font-weight: 700; color: #6B6964;
    text-transform: uppercase; letter-spacing: 0.7px;
    padding: 8px 16px 4px;
  }

.dd-section-label:first-child { padding-top: 6px; }

.dd-item {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 16px; color: #1C1C1A !important; font-size: 0.8125rem;
    transition: background 0.12s;
    white-space: nowrap; background: white;
  }

.dd-item:hover { background: #EAF3DE !important; color: var(--green-dark) !important; }

.dd-item-icon { font-size: 0.9375rem; width: 20px; text-align: center; flex-shrink: 0; }

.dd-item-count { font-size: 0.6875rem; color: #6B6964; margin-left: auto; }

.dd-divider { height: 1px; background: #F0F0EC; margin: 4px 0; }

.category-dropdown.wide {
    min-width: 420px;
    padding: 10px;
    display: none;
    grid-template-columns: 1fr 1fr;
    gap: 0 4px;
  }

.category-navigation-item:hover .category-dropdown.wide { display: grid; }

.wide .dd-col { padding: 0; }

.category-navigation-all-button {
    padding: 12px 16px; background: var(--green-dark); color: white;
    display: flex; align-items: center; gap: 8px; font-weight: 600;
    font-size: 0.875rem; border: none; cursor: pointer; font-family: inherit;
    flex-shrink: 0; white-space: nowrap;
  }

.category-navigation-all-button:hover { background: var(--green-dark); }


/* ═══════════════════════════════════════════════════════════
 * MOBILE MENU SHEET — full-screen overlay with slide-up panel
 * ═══════════════════════════════════════════════════════════ */
.mobile-menu-overlay {
    /* Stays in DOM at all times; visibility + opacity gates display */
    visibility: hidden;
    opacity: 0;
    position: fixed; inset: 0; z-index: 1000;
    display: flex; flex-direction: column; justify-content: flex-end;
    transition: visibility 0s linear 0.28s, opacity 0.22s ease;
  }

.mobile-menu-overlay.open {
    visibility: visible;
    opacity: 1;
    transition: visibility 0s linear 0s, opacity 0.22s ease;
  }

.mobile-menu-backdrop {
    position: absolute; inset: 0;
    background: rgba(0,0,0,0.45);
  }

.mobile-menu-sheet {
    position: relative; z-index: 1;
    background: #FAFBFD;
    border-radius: 18px 18px 0 0;
    max-height: 82vh;
    display: flex; flex-direction: column;
    overflow: hidden;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.32,0.72,0,1);
    will-change: transform;
  }

.mobile-menu-overlay.open .mobile-menu-sheet {
    transform: translateY(0);
  }

.mobile-menu-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 16px 0;
    flex-shrink: 0;
  }

.mobile-menu-handle {
    width: 36px; height: 4px;
    background: #D3D1C7; border-radius: 2px;
    margin: 0 auto 0;
    position: absolute; left: 50%; transform: translateX(-50%); top: 10px;
  }

.mobile-menu-title-row {
    display: flex; align-items: center; gap: 10px;
    padding: 16px 16px 12px;
    border-bottom: 1px solid #E8E8E4;
    flex-shrink: 0;
  }

.mobile-menu-back {
    width: 32px; height: 32px;
    background: #EAF3DE; border: none; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem; color: var(--green-dark); flex-shrink: 0;
    cursor: pointer; font-family: inherit;
  }

.mobile-menu-back[hidden] { display: none; }

.mobile-menu-heading {
    font-size: 1rem; font-weight: 700; color: #1C1C1A; flex: 1;
  }

.mobile-menu-close {
    width: 32px; height: 32px;
    background: #F2F2EE; border: none; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.125rem; color: #5F5E5A; cursor: pointer; font-family: inherit;
  }

.mobile-menu-body {
    overflow-y: auto; overflow-x: hidden; flex: 1;
    padding: 12px;
    scrollbar-width: none;
  }

.mobile-menu-body::-webkit-scrollbar { display: none; }


/* ───────────────────────────────────────────────────────────
 * MOBILE MENU TILES — 3-column grid for top-level categories
 * ─────────────────────────────────────────────────────────── */
.mobile-menu-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

.mobile-menu-tile {
    background: white; border: 1.5px solid #E8E8E4; border-radius: 12px;
    padding: 14px 8px 12px;
    display: flex; flex-direction: column; align-items: center; gap: 7px;
    cursor: pointer; transition: border-color 0.15s, background 0.15s;
    text-align: center;
  }

.mobile-menu-tile:active { background: #EAF3DE; border-color: var(--green); }

.mobile-menu-tile-icon {
    width: 48px; height: 48px;
    border-radius: 10px;
    background: #E8E8E4;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden; flex-shrink: 0;
  }
.mobile-menu-tile-icon.is-loaded { background: transparent; }
.mobile-menu-tile-icon img {
    width: 100%; height: 100%; display: block;
    border-radius: 10px;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.18s ease;
}
.mobile-menu-tile-icon.is-loaded img { opacity: 1; }

.mobile-menu-list-item-icon {
    width: 28px; height: 28px;
    border-radius: 6px;
    background: #E8E8E4;
    display: inline-flex; align-items: center; justify-content: center;
    overflow: hidden; flex-shrink: 0;
  }
.mobile-menu-list-item-icon.is-loaded { background: transparent; }
.mobile-menu-list-item-icon img {
    width: 100%; height: 100%; display: block;
    border-radius: 6px;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.18s ease;
}
.mobile-menu-list-item-icon.is-loaded img { opacity: 1; }

.mobile-menu-tile-label { font-size: 0.75rem; font-weight: 600; color: #1C1C1A; line-height: 1.2; }

.mobile-menu-tile-count { font-size: 0.625rem; color: var(--green); font-weight: 600; }


/* ───────────────────────────────────────────────────────────
 * MOBILE MENU SUB-LIST — level-2 list items within category sheet
 * ─────────────────────────────────────────────────────────── */
.mm-sublist { display: none; animation: mobile-menu-slide-right 0.2s ease; }

.mm-sublist.active { display: block; }

.mm-subbanner {
    background: linear-gradient(135deg, var(--green-light), #C8E5A8);
    border-radius: 10px; padding: 14px; margin-bottom: 12px;
    display: flex; align-items: center; gap: 12px;
  }

.mm-subbanner-icon { font-size: 2rem; line-height: 1; }

.mm-subbanner-info {}

.mm-subbanner-name { font-size: 0.9375rem; font-weight: 700; color: #1C1C1A; margin: 0; }

.mm-subbanner-desc { font-size: 0.75rem; color: #5F5E5A; margin: 2px 0 0; }

.mm-sub-item {
    display: flex; align-items: center; justify-content: space-between;
    padding: 13px 14px;
    background: white; border: 1px solid #E8E8E4; border-radius: 8px;
    margin-bottom: 10px; cursor: pointer;
    transition: border-color 0.15s;
  }

.mm-sub-item:active { border-color: var(--green); background: var(--green-light); }

.mm-sub-item-left { display: flex; align-items: center; gap: 10px; }

.mm-sub-item-icon { font-size: 1.125rem; width: 32px; text-align: center; }

.mm-sub-item-name { font-size: 0.875rem; font-weight: 500; color: #1C1C1A; word-break: break-word; }

.mm-sub-item-count { font-size: 0.6875rem; color: #6B6964; margin-top: 1px; }

.mm-sub-chevron { font-size: 0.75rem; color: #6B6964; }

.mm-sub-section-label {
    font-size: 0.6875rem; font-weight: 700; color: #6B6964;
    text-transform: uppercase; letter-spacing: 0.7px;
    padding: 6px 4px 8px; margin: 4px 0 2px;
  }

.mobile-menu-body::after { content: ''; display: block; height: 12px; }



/* ===== shared footer/sitemap rules (universal chrome - loads on every page) ===== */
/* FOOTER - dark footer, social links, payments, sitemap */
footer { background: #1C1C1A; color: white; }

.social-btn { width: 34px; height: 34px; background: #2E2E2A; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 0.875rem; color: white; }

.app-btn { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: #2E2E2A; border-radius: 6px; margin-bottom: 8px; }

.app-label-sm { font-size: 0.625rem; color: #C7C5BD; margin: 0; }

.app-label-lg { font-size: 0.8125rem; font-weight: 600; color: white; margin: 0; }

.trust-items { display: flex; gap: 12px; font-size: 0.75rem; color: #fff; flex-wrap: wrap; }

.trust-check { color: var(--green); }

.payment-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.payment-label { font-size: 0.6875rem; color: #fff; margin-right: 4px; }

.payment-chip { padding: 6px 10px; background: white; border-radius: 4px; font-size: 0.6875rem; font-weight: 700; color: #1C1C1A; }

.sitemap-section {
    background: #F5F5F1;
    border-top: 1px solid #E8E8E4;
    border-bottom: 1px solid #E8E8E4;
  }

.sitemap-inner {
    max-width: 1200px; margin: 0 auto;
    padding: 28px 16px;
  }

.sitemap-heading {
    font-size: 0.8125rem; font-weight: 700; color: #6B6964;
    text-transform: uppercase; letter-spacing: 0.8px;
    margin: 0 0 18px;
    display: flex; align-items: center; gap: 8px;
  }

.sitemap-heading::after {
    content: ''; flex: 1; height: 1px; background: #E8E8E4;
  }

.sitemap-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px 16px;
  }

.sitemap-cat-title {
    font-size: 0.8125rem; font-weight: 700; color: #1C1C1A;
    margin: 0 0 8px;
    display: flex; align-items: center; gap: 6px;
  }

.sitemap-cat-title span { font-size: 0.9375rem; }

.sitemap-links {
    display: flex; flex-wrap: wrap; gap: 8px 8px;
  }

.sitemap-links a {
    font-size: 0.75rem; color: #5F5E5A;
    background: white; border: 1px solid #E8E8E4;
    padding: 5px 11px; border-radius: 20px;
    transition: border-color 0.12s, color 0.12s;
    white-space: nowrap;
  }

.sitemap-links a:hover { border-color: var(--green); color: var(--green-dark); }


/* Small tablet - sitemap expands to 3 columns */
@media (min-width: 600px) {
    .sitemap-grid { grid-template-columns: repeat(3, 1fr); }
  }


/* Desktop - sitemap expands to 4 columns */
@media (min-width: 1024px) {
    .sitemap-inner { padding: 32px 24px; }
    .sitemap-grid { grid-template-columns: repeat(4, 1fr); gap: 24px 20px; }
  }



/* ===== shared product-card rules moved from pages/category.css ===== */
.product-card {
    display: flex; flex-direction: column;
    background: white;
    border: 1px solid var(--color-border-tertiary);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color 0.15s, box-shadow 0.15s;
  }

.product-card:hover {
    border-color: var(--green);
    box-shadow: 0 4px 14px rgba(0,0,0,0.05);
  }

.product-card-image-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    background: linear-gradient(90deg, #F1EFE8 0%, #FAFBFD 50%, #F1EFE8 100%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.4s linear infinite;
    overflow: hidden;
  }

.product-card-image-wrap.loaded {
    animation: none; background: #FAFBFD;
  }

.product-card-image-wrap picture {
    display: contents;
  }

.product-card-image {
    position: absolute;
    inset: 8%;
    width: 84%;
    height: 84%;
    object-fit: contain;
    display: block;
    transition: transform 0.3s ease;
  }

.product-card:hover .product-card-image {
    transform: scale(1.08);
  }

.product-card-image-stub { position: absolute; inset: 0; }

.product-card-badges {
    position: absolute; top: 8px; left: 8px; right: 8px;
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 8px;
    pointer-events: none; z-index: 2;
  }

.product-card-badges-left, .product-card-badges-right {
    display: flex; gap: 4px;
    align-items: flex-start;
  }

.product-card-badges-right { justify-content: flex-end; }

.product-card-badge {
    display: inline-flex; align-items: center;
    padding: 3px 8px; border-radius: 4px;
    font-size: 0.6875rem; font-weight: 700;
    line-height: 1.4;
    text-transform: uppercase; letter-spacing: 0.3px;
    white-space: nowrap;
  }

.product-card-badge.new { background: var(--green); color: white; }

/* Location badge (Car & Real Estate) — space between the map-pin icon and the place name */
.product-card-badge-location { gap: 4px; }

.product-card-badge.used { background: var(--orange-dark); color: white; }

.product-card-badge.discount {
    background: #e8380d; color: #fff;
    font-weight: 800; letter-spacing: 0.2px;
    border-radius: 20px; padding: 4px 10px;
    box-shadow: 0 2px 6px rgba(232,56,13,.35);
  }

.product-card-badge.hot {
    background: #6366f1; color: #fff;
    border-radius: 20px; padding: 4px 10px; gap: 6px;
    box-shadow: 0 2px 6px rgba(99,102,241,.4);
    font-size: 0.625rem; letter-spacing: 0.4px;
  }
.product-card-badge.hot svg { stroke: #fff; flex-shrink: 0; }

.product-card-badge.popular {
    background: #6366f1; color: #fff;
    border-radius: 20px; padding: 4px 10px; gap: 6px;
    box-shadow: 0 2px 6px rgba(99,102,241,.4);
    font-size: 0.625rem; letter-spacing: 0.4px;
  }
.product-card-badge.popular svg { stroke: #fff; flex-shrink: 0; }

/* Star rating — floating chip, bottom-right corner of the image */
.product-card-star-float {
    position: absolute;
    bottom: 8px; left: 8px;
    z-index: 2;
    display: inline-flex; align-items: center; gap: 3px;
    padding: 3px 8px;
    background: #fef3c7; border: 1px solid #fbbf24;
    border-radius: 20px;
    font-size: 0.75rem; font-weight: 800;
    color: #92400e;
    white-space: nowrap;
    pointer-events: none;
    box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  }

.product-card-star-float svg {
    stroke: #f59e0b; fill: #f59e0b; flex-shrink: 0;
  }

/* Stock status — floating pill at the image's bottom-right corner */
.product-card-stock-float {
    position: absolute;
    bottom: 8px; right: 8px;
    z-index: 2;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 0.6875rem; font-weight: 700;
    white-space: nowrap;
    pointer-events: none;
    box-shadow: 0 1px 4px rgba(0,0,0,0.12);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
  }
.product-card-stock-float.in-stock {
    background: rgba(220,252,231,0.95); border: 1px solid #34d399; color: #065f46;
  }
.product-card-stock-float.out-of-stock {
    background: rgba(254,226,226,0.95); border: 1px solid #f87171; color: #991b1b;
  }

.product-card-verified-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: var(--orange);
    color: white;
    font-size: 0.6875rem;
    font-weight: 900;
    line-height: 1;
    flex-shrink: 0;
    cursor: help;
  }

.product-card-body {
    padding: 10px 10px 8px;
    display: flex; flex-direction: column;
    gap: 4px;
  }

/* Price column — always flush to the card bottom in equal-height grid rows */
.product-card-price-col {
    margin-top: auto;
    padding: 6px 10px 12px;
  }

.product-card-location {
    display: inline-flex; align-items: center; gap: 4px;
    margin: 0 0 5px;
    font-size: 0.75rem; font-weight: 600;
    color: #1d7a45;
    letter-spacing: 0.1px;
  }
.product-card-location svg { stroke: #1d7a45; flex-shrink: 0; }

.product-card-title {
    margin: 0;
    font-size: 0.875rem; font-weight: 500;
    color: var(--color-text-primary);
    line-height: 1.35;
    /* SEO: full title in HTML, visually clamp to 2 lines */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: calc(1.35em * 2);
  }

.product-card-price-row {
    display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap;
    margin: 0;
    line-height: 1.2;
  }

.product-card-price {
    font-size: 1.25rem; font-weight: 800;
    color: var(--color-text-primary);
    margin: 0;
    letter-spacing: -0.015em;
    line-height: 1.1;
  }

/* Lakh / Crore / Thousand suffix from bd_money_convert() — make it legible */
.product-card-price span[style] { font-size: 0.85em !important; font-weight: 600; }

.product-card-price-old {
    font-size: 0.8125rem;
    color: var(--orange-dark);
    opacity: 0.7;
    text-decoration: line-through;
    text-decoration-color: var(--orange-dark);
  }

.product-card-points {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    margin: 4px 0 0;
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--green-dark, #1f7a37);
  }

.product-card-price-trend {
    display: inline-flex; align-items: center; gap: 2px;
    font-size: 0.75rem; font-weight: 600;
    line-height: 1;
    white-space: nowrap;
  }

.product-card-price-trend.down { color: var(--green-dark); }

.product-card-price-trend.up { color: var(--orange-dark); }

.product-card-rating {
    display: flex; align-items: center; gap: 4px;
    flex-wrap: wrap;
    font-size: 0.8125rem; color: var(--color-text-secondary);
    line-height: 1.2;
    margin: 0;
  }

.product-card-rating .star { color: #F5A623; }

.product-card-rating .count { color: var(--color-text-tertiary); }

.product-card-rating .new-seller { color: var(--color-text-tertiary); font-style: italic; }

.product-card-rating .sep { color: var(--color-border-secondary); margin: 0 2px; }

.product-card-rating .stock { font-weight: 600; }

.product-card-rating .stock.in-stock { color: var(--green-dark); }

.product-card-rating .stock.out-of-stock { color: var(--color-text-tertiary); }

.product-card-rating .posted { color: var(--color-text-tertiary); }

.product-card-stalls-cta {
    display: flex; align-items: center; justify-content: space-between;
    gap: 6px;
    margin: 0;
    padding: 6px 10px;
    background: var(--orange-light);
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--orange-dark);
    line-height: 1.2;
    transition: background 0.15s;
  }

.product-card:hover .product-card-stalls-cta {
    background: #F9D8B0;
  }

.product-card-stalls-cta-label {
    display: inline-flex; align-items: center; gap: 5px;
    white-space: nowrap;
    min-width: 0;
  }

.product-card-stalls-cta-icon {
    font-size: 0.875rem;
    line-height: 1;
  }

.product-card-stalls-cta-arrow {
    font-weight: 900;
    transition: transform 0.15s;
  }

.product-card:hover .product-card-stalls-cta-arrow {
    transform: translateX(2px);
  }

.product-card-stalls-cta.single {
    background: transparent;
    color: var(--color-text-tertiary);
    font-weight: 500;
    padding: 4px 0;
    justify-content: flex-start;
  }

.product-card-stalls-cta.single .product-card-stalls-cta-arrow { display: none; }

@media (min-width: 1024px) {
    .product-card-stalls-cta { font-size: 0.875rem; padding: 7px 12px; }
  }

.product-card.out-of-stock .product-card-image-wrap {
    opacity: 0.55;
  }

.product-card.out-of-stock .product-card-title {
    color: var(--color-text-tertiary);
  }

.product-card.out-of-stock .product-card-price {
    color: var(--color-text-tertiary);
  }

@media (min-width: 600px) {
    .product-card-body { padding: 12px 12px 8px; gap: 5px; }
    .product-card-price-col { padding: 6px 12px 12px; }
    .product-card-price { font-size: 1.1875rem; }
  }

@media (min-width: 1024px) {
    .product-card-body { padding: 14px 14px 8px; gap: 6px; }
    .product-card-price-col { padding: 6px 14px 14px; }
    .product-card-title { font-size: 0.9375rem; }
    .product-card-price { font-size: 1.25rem; }
    .product-card-rating { font-size: 0.875rem; }
    .product-card-price-old { font-size: 0.875rem; }
    .product-card-price-trend { font-size: 0.8125rem; }
  }

/* ===== shared filter option + region sheet rules moved from pages/category.css ===== */
/* Filter options */
.filter-option {
    display: flex; align-items: center; gap: 10px;
    padding: 7px 0;
    font-size: 0.8125rem;
    color: var(--color-text-primary);
    min-height: 34px;
    cursor: pointer;
  }

.filter-option .opt-label { flex: 1; }

.filter-option .opt-count {
    font-size: 0.75rem;
    color: var(--color-text-tertiary, #999);
    min-width: 20px;
    text-align: right;
  }

.filter-option:hover .opt-label { color: var(--green-dark); }


/* Region sheet layout shared by category and product/detail pages */
.region-sheet-overlay {
    visibility: hidden; opacity: 0;
    position: fixed; inset: 0; z-index: 1100;
    display: flex; flex-direction: column; justify-content: flex-end;
    transition: visibility 0s linear 0.32s, opacity 0.22s ease;
  }

.region-sheet-overlay.open {
    visibility: visible; opacity: 1;
    transition: visibility 0s linear 0s, opacity 0.22s ease;
  }

.region-sheet-backdrop {
    position: absolute; inset: 0;
    background: rgba(0,0,0,0.45);
  }

.region-sheet {
    position: relative; z-index: 1;
    background: #FAFBFD;
    border-radius: 18px 18px 0 0;
    max-height: 88vh;
    display: flex; flex-direction: column;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.32,0.72,0,1);
    will-change: transform;
  }

.region-sheet-overlay.open .region-sheet { transform: translateY(0); }

.region-sheet-handle {
    width: 36px; height: 4px;
    background: var(--color-border-secondary);
    border-radius: 2px;
    margin: 10px auto 4px;
  }

.region-sheet-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid var(--color-border-tertiary);
    flex-shrink: 0;
  }

.region-sheet-header h2 {
    font-size: 1.0625rem; font-weight: 700; margin: 0;
  }

.region-sheet-close {
    width: 32px; height: 32px;
    background: none; border: none;
    font-size: 1.375rem; color: var(--color-text-secondary);
    font-family: inherit; cursor: pointer;
  }

.region-sheet-body {
    flex: 1; overflow-y: auto;
    padding: 14px 16px 96px;
  }

.region-search-wrap {
    position: relative;
    margin-bottom: 12px;
  }

.region-search-input {
    width: 100%;
    padding: 11px 36px 11px 38px;
    border: 1.5px solid var(--color-border-secondary);
    border-radius: 10px;
    font-size: 0.875rem; font-family: inherit;
    background: white;
    min-height: 44px;
  }

.region-search-input:focus {
    outline: none;
    border-color: var(--green);
  }

.region-search-icon {
    position: absolute; left: 12px; top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-tertiary);
    pointer-events: none;
  }

.region-search-clear {
    position: absolute; right: 6px; top: 50%;
    transform: translateY(-50%);
    width: 28px; height: 28px;
    background: var(--color-border-tertiary);
    border: none; border-radius: 50%;
    color: var(--color-text-secondary);
    font-size: 0.75rem; cursor: pointer;
    display: none;
    align-items: center; justify-content: center;
  }

.region-search-wrap.has-input .region-search-clear { display: flex; }

.region-hidden { display: none !important; }

.region-no-results {
    padding: 20px 16px; text-align: center;
    color: var(--color-text-tertiary);
    font-size: 0.875rem;
  }

.region-use-location {
    width: 100%;
    display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px;
    background: var(--green-light);
    border: 1px dashed var(--green);
    border-radius: 8px;
    font-size: 0.875rem; font-weight: 600;
    color: var(--green-dark);
    font-family: inherit; cursor: pointer;
    margin-bottom: 16px;
    min-height: 44px;
  }

.region-use-location:hover { background: #EAF3DE; border-style: solid; }

.region-use-location-icon { font-size: 1rem; }

.region-city {
    background: white;
    border: 1px solid var(--color-border-tertiary);
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
  }

.region-city-head {
    display: flex; align-items: center; gap: 8px;
    padding: 13px 14px;
    cursor: pointer; user-select: none;
    min-height: 44px;
  }

.region-city-name { font-size: 0.9375rem; font-weight: 700; color: var(--color-text-primary); }

.region-city-count { font-size: 0.8125rem; color: var(--color-text-tertiary); flex: 1; }

.region-city-toggle { font-size: 0.875rem; color: var(--color-text-tertiary); transition: transform 0.2s; }

.region-city:not(.expanded) .region-city-toggle { transform: rotate(-90deg); }

.region-city-areas {
    padding: 0 14px 12px;
    border-top: 1px solid var(--color-border-tertiary);
  }

.region-city:not(.expanded) .region-city-areas { display: none; }

.region-area .opt-label { padding-left: 18px; position: relative; }

.region-area .opt-label::before {
    content: '';
    position: absolute; left: 6px; top: 50%;
    width: 8px; height: 1px;
    background: var(--color-border-secondary);
  }

.region-show-more {
    background: none; border: none;
    color: var(--green-dark); font-weight: 600;
    font-size: 0.8125rem;
    padding: 8px 0 4px;
    font-family: inherit; cursor: pointer;
    text-align: left;
  }

.region-show-more:hover { text-decoration: underline; }

.region-flat-cities {
    background: white;
    border: 1px solid var(--color-border-tertiary);
    border-radius: 10px;
    padding: 4px 14px;
  }

.region-sheet-footer {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: white;
    border-top: 1px solid var(--color-border-tertiary);
    padding: 12px 16px;
    display: flex; gap: 10px;
  }

.region-reset-btn {
    flex: 1; padding: 12px;
    background: white;
    border: 1px solid var(--color-border-secondary);
    border-radius: 8px;
    font-size: 0.875rem; font-weight: 600;
    min-height: 48px;
    font-family: inherit; cursor: pointer;
  }

.region-apply-btn {
    flex: 2; padding: 12px;
    background: var(--green-dark);
    color: white; border: none;
    border-radius: 8px;
    font-size: 0.875rem; font-weight: 600;
    min-height: 48px;
    font-family: inherit; cursor: pointer;
  }

@media (min-width: 1024px) {
    .region-sheet-overlay {
      justify-content: center; align-items: center;
    }
    .region-sheet {
      width: 480px; max-width: 90vw;
      max-height: 85vh;
      border-radius: 16px;
      transform: translateY(40px);
    }
    .region-sheet-overlay.open .region-sheet { transform: translateY(0); }
    .region-sheet-handle { display: none; }
  }


.region-sheet-section {
    padding: 6px 0 12px;
}

.region-sheet-section-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: #6B6964;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin: 8px 0 6px;
}

.region-empty {
    text-align: center;
    color: #6B6964;
    padding: 28px 16px;
    font-size: 0.875rem;
}
