/* ==========================================================================
   Captain Fresh Mart — storefront design system
   ========================================================================== */

:root {
  --color-primary: #ea580c;
  --color-primary-dark: #c2410c;
  --color-primary-light: #fff1e6;
  --color-secondary: #15803d;
  --color-secondary-light: #ecfdf3;
  --color-accent: #ca8a04;
  --color-ink: #1f2933;
  --color-ink-soft: #52606d;
  --color-muted: #8a94a3;
  --color-bg: #faf8f4;
  --color-surface: #ffffff;
  --color-border: #eee7db;
  --color-danger: #dc2626;

  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 3px rgba(31, 41, 51, 0.06), 0 1px 2px rgba(31, 41, 51, 0.04);
  --shadow-md: 0 8px 24px rgba(31, 41, 51, 0.08);
  --shadow-lg: 0 20px 50px rgba(31, 41, 51, 0.14);

  --container: 1240px;
  --header-h: 78px;
  --mobile-tabbar-h: 0px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-ink);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }
p { margin: 0; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 20px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: var(--radius-pill); border: none;
  font-weight: 700; font-size: 0.95rem; cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--color-primary); color: #fff; box-shadow: 0 10px 24px rgba(234, 88, 12, 0.32); }
.btn-primary:hover { background: var(--color-primary-dark); }
.btn-dark { background: var(--color-ink); color: #fff; }
.btn-dark:hover { background: #000; }
.btn-outline { background: transparent; border: 1.5px solid var(--color-border); color: var(--color-ink); }
.btn-outline:hover { border-color: var(--color-primary); color: var(--color-primary); }
.btn-ghost { background: var(--color-primary-light); color: var(--color-primary-dark); }
.btn-ghost:hover { background: #ffe4cc; }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-icon { width: 40px; height: 40px; padding: 0; border-radius: 50%; }

/* ---------- Header — single colored bar ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60; background: var(--color-primary);
  box-shadow: 0 2px 10px rgba(31, 41, 51, 0.12);
  transition: box-shadow 0.25s ease;
}
.site-header.is-scrolled { box-shadow: 0 6px 20px rgba(31, 41, 51, 0.2); }
.header-row { display: flex; align-items: center; gap: 18px; height: var(--header-h); }

.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.2rem; flex-shrink: 0; color: #fff; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.18);
  display: flex; align-items: center; justify-content: center; font-size: 1.15rem;
}
.brand-logo-img { height: 140px; width: auto; max-width: 260px; object-fit: contain; background: transparent; }
.site-footer .brand-logo-img { height: 38px; }

.header-search { flex: 1 1 auto; position: relative; max-width: 1000px; min-width: 0; }
.header-search form {
  display: flex; border-radius: var(--radius-pill);
  background: var(--color-surface); box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}
.header-search input {
  width: 100%; padding: 15px 20px; font-size: 0.98rem; border: none; outline: none; background: transparent;
  border-radius: var(--radius-pill) 0 0 var(--radius-pill);
}
.header-search button {
  display: flex; align-items: center; justify-content: center;
  border: none; background: var(--color-secondary); color: #fff; flex-shrink: 0;
  padding: 0 24px; border-radius: 0 var(--radius-pill) var(--radius-pill) 0;
}
.search-suggest {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: var(--color-surface);
  border-radius: var(--radius-md); box-shadow: var(--shadow-lg); border: 1px solid var(--color-border);
  overflow: hidden; z-index: 80;
}
.search-suggest:empty { display: none; box-shadow: none; border: none; }
.suggest-item { display: flex; align-items: center; gap: 12px; padding: 10px 14px; }
.suggest-item:hover { background: var(--color-primary-light); }
.suggest-item img { width: 38px; height: 38px; border-radius: 8px; object-fit: cover; }
.suggest-name { font-weight: 600; font-size: 0.9rem; color: var(--color-ink); }
.suggest-price { margin-left: auto; font-weight: 700; color: var(--color-primary-dark); font-size: 0.88rem; }

.header-actions { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.hlink {
  display: flex; align-items: center; gap: 7px; color: #fff; font-weight: 700; font-size: 0.84rem;
  padding: 9px 12px; border-radius: 10px; transition: background-color 0.15s ease; white-space: nowrap;
}
.hlink svg { flex-shrink: 0; }
.hlink:hover { background: rgba(255, 255, 255, 0.14); }
.hlink.cart-link { position: relative; background: rgba(255, 255, 255, 0.14); }
.hlink.cart-link:hover { background: rgba(255, 255, 255, 0.22); }
.badge-count {
  background: #fff; color: var(--color-primary-dark);
  font-size: 0.68rem; font-weight: 800; min-width: 18px; height: 18px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; padding: 0 4px;
}
.icon-link { position: relative; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; color: #fff; }
.icon-link:hover { background: rgba(255, 255, 255, 0.14); }
.hamburger { display: none; }

/* ---------- Category nav bar ---------- */
.category-nav { background: var(--color-surface); box-shadow: 0 4px 12px rgba(31, 41, 51, 0.05); position: relative; z-index: 10; }
.category-nav-row { display: flex; align-items: center; padding: 10px 0; }
.category-nav-links { display: flex; align-items: center; flex-wrap: nowrap; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 4px 28px 4px 2px; }
.category-nav-links::-webkit-scrollbar { display: none; }
.category-nav-links a {
  display: inline-flex; align-items: center; flex-shrink: 0; height: 38px; padding: 0 16px;
  font-size: 0.82rem; font-weight: 700; color: var(--color-ink-soft); white-space: nowrap;
  background: var(--color-bg); border: 1px solid var(--color-border); border-radius: var(--radius-pill);
  transition: transform 0.15s ease, background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.category-nav-links a:hover { color: var(--color-primary-dark); border-color: var(--color-primary); transform: translateY(-1px); box-shadow: 0 4px 10px rgba(31, 41, 51, 0.08); }
.category-nav-links a:first-child {
  color: #fff; background: linear-gradient(135deg, var(--color-accent), var(--color-accent));
  border-color: transparent; box-shadow: 0 4px 10px color-mix(in srgb, var(--color-accent) 35%, transparent);
}
.category-nav-links a:first-child:hover { color: #fff; }
.category-nav-links a.active {
  color: #fff; background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  border-color: transparent; box-shadow: 0 4px 10px color-mix(in srgb, var(--color-primary) 35%, transparent);
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(circle at 15% 20%, #fff7ec 0%, var(--color-bg) 55%);
  padding: 40px 0 64px;
}
.hero-blob {
  position: absolute; border-radius: 50%; filter: blur(2px); opacity: 0.55;
  animation: float 9s ease-in-out infinite;
}
.hero-blob.b1 { width: 320px; height: 320px; background: radial-gradient(circle, #ffd8ad, transparent 70%); top: -80px; right: 8%; }
.hero-blob.b2 { width: 220px; height: 220px; background: radial-gradient(circle, #bbf7d0, transparent 70%); bottom: -60px; right: 28%; animation-delay: -3s; }
.hero-blob.b3 { width: 160px; height: 160px; background: radial-gradient(circle, #fde68a, transparent 70%); top: 30%; left: -40px; animation-delay: -6s; }
@keyframes float {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-24px) translateX(14px); }
}

.hero-grid { position: relative; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; align-items: center; }
.hero-content { max-width: 600px; position: relative; z-index: 2; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px; background: var(--color-secondary-light); color: var(--color-secondary);
  font-weight: 700; font-size: 0.82rem; padding: 8px 16px; border-radius: var(--radius-pill); margin-bottom: 20px;
}
.hero h1 { font-size: clamp(1.75rem, 3.2vw, 2.6rem); margin-bottom: 18px; }
.hero-rotator { color: var(--color-primary); position: relative; display: inline-block; font-size: 0.82em; }
.hero-sub { font-size: 1.08rem; color: var(--color-ink-soft); max-width: 480px; margin-bottom: 30px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-cta .btn-outline { background: rgba(255, 255, 255, 0.92); border-color: var(--color-primary); color: var(--color-primary-dark); }
.hero-cta .btn-outline:hover { background: #fff; }
.hero-stats { display: flex; justify-content: space-between; gap: 16px; width: 100%; margin-top: 26px; }
.hero-stat { flex: 1; min-width: 0; }
.hero-stat b { font-size: 1.7rem; display: block; color: var(--color-ink); white-space: nowrap; }
.hero-stat span { font-size: 0.85rem; color: var(--color-muted); white-space: nowrap; }

/* ---------- Hero visual — small real-product cards, not a fake placeholder ---------- */
.hero-visual { position: relative; height: 420px; }
.hero-photo-card {
  position: relative; width: 100%; height: 100%; border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-lg); background: var(--color-surface);
}
.hero-photo-card img { width: 100%; height: 100%; object-fit: cover; }

/* Full-bleed edge-to-edge photo panel on desktop, spanning the entire page width */
@media (min-width: 981px) {
  .hero-visual.has-photo {
    position: absolute; top: 0; left: 0; right: 0; bottom: 0; width: 100%; height: auto;
  }
  .hero-visual.has-photo .hero-photo-card { border-radius: 0; box-shadow: none; }
  .hero-visual.has-photo .hero-photo-card::before {
    content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 58%; z-index: 1;
    background: linear-gradient(to right, var(--color-bg) 0%, var(--color-bg) 25%, rgba(250, 248, 244, 0) 100%);
  }
  .hero-visual.has-photo .hero-float-chip.c1 { top: 36px; right: 36px; left: auto; }
  .hero-visual.has-photo .hero-float-chip.c2 { bottom: 90px; right: 22%; left: auto; }
  .hero-visual.has-photo .hero-float-chip.c3 { top: 46%; right: 36px; left: auto; }
}
.hero-mini-card {
  position: absolute; width: 190px; background: var(--color-surface); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); overflow: hidden; transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: float 8s ease-in-out infinite;
}
.hero-mini-card:hover { transform: translateY(-6px) scale(1.02) !important; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2); z-index: 5; }
.hero-mini-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
.hero-mini-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.hero-mini-name { font-size: 0.8rem; font-weight: 700; color: var(--color-ink); line-height: 1.3; }
.hero-mini-price { font-size: 0.85rem; font-weight: 800; color: var(--color-primary-dark); display: flex; gap: 6px; align-items: baseline; }
.hero-mini-price s { font-size: 0.72rem; font-weight: 600; color: var(--color-muted); }
.hero-mini-card.mc1 { top: 10px; left: 30px; transform: rotate(-4deg); z-index: 2; }
.hero-mini-card.mc2 { bottom: 20px; right: 0; transform: rotate(3deg); animation-delay: -3s; z-index: 3; }
.hero-float-chip {
  position: absolute; background: #fff; border-radius: var(--radius-md); padding: 12px 16px; box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 0.85rem; animation: float 7s ease-in-out infinite;
}
.hero-float-chip.c1 { top: 0; right: 10px; animation-delay: -1s; }
.hero-float-chip.c2 { bottom: 60px; left: -10px; animation-delay: -4s; }
.hero-float-chip.c3 { top: 46%; left: -10px; animation-delay: -2.5s; }
.hero-float-chip .dot { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; }
.hero-float-chip.c1 .dot { background: var(--color-secondary); }
.hero-float-chip.c2 .dot { background: var(--color-primary); }
.hero-float-chip.c3 .dot { background: var(--color-accent); }

/* ---------- Section shell ---------- */
.section { padding: 78px 0; }
.section-tight { padding: 46px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 36px; flex-wrap: wrap; }
.section-eyebrow { color: var(--color-primary); font-weight: 800; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 8px; display: block; }
.section-head h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
.section-desc { color: var(--color-ink-soft); max-width: 560px; margin-top: 10px; }
.section-alt { background: color-mix(in srgb, var(--color-primary) 6%, var(--color-surface)); }

/* ---------- Category grid — colorful photo/gradient cards, no generic icons ---------- */
.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 20px; }
.category-card {
  position: relative; display: block; aspect-ratio: 5/4; border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: 0 1px 2px rgba(31, 41, 51, 0.06); transition: transform 0.25s cubic-bezier(.2,.8,.2,1), box-shadow 0.25s ease;
}
.category-card:hover { transform: translateY(-5px); box-shadow: 0 16px 32px rgba(31, 41, 51, 0.16); }
.category-card.has-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.45s ease; }
.category-card.has-photo:hover img { transform: scale(1.06); }
.category-card-shade { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.05) 60%, transparent 100%); }

/* Icon-less gradient cards — one giant, softly-cropped initial as the only decoration */
.category-card-watermark {
  position: absolute; right: -0.12em; bottom: -0.3em; font-size: 7rem; font-weight: 800; line-height: 1;
  color: rgba(255, 255, 255, 0.16); font-family: var(--font-body);
  pointer-events: none; user-select: none; letter-spacing: -0.05em;
}
.category-card-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px; color: #fff; z-index: 1; }
.category-card-body h3 { font-size: 1.02rem; font-weight: 800; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2); }
.category-card-body span {
  display: inline-block; margin-top: 5px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.02em;
  color: #fff; opacity: 0.92;
}

/* ---------- Product grid / cards ---------- */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.product-grid-wide { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px; }
.product-card {
  background: var(--color-surface); border: 1px solid rgba(31, 41, 51, 0.07); border-radius: 16px;
  overflow: hidden; position: relative; transition: transform 0.3s cubic-bezier(.2,.8,.2,1), box-shadow 0.3s ease, border-color 0.3s ease;
  display: flex; flex-direction: column; box-shadow: 0 2px 6px rgba(31, 41, 51, 0.05);
}
.product-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--color-primary) 30%, transparent);
  box-shadow: 0 18px 28px -10px color-mix(in srgb, var(--color-primary) 22%, rgba(31,41,51,.14));
}
.product-thumb {
  position: relative; aspect-ratio: 1/1; overflow: hidden; padding: 9px;
  background: linear-gradient(160deg, var(--color-primary-light) 0%, var(--color-bg) 100%);
}
.product-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 11px; transition: transform 0.5s cubic-bezier(.2,.8,.2,1); box-shadow: 0 4px 12px rgba(31,41,51,.08); }
.product-card:hover .product-thumb img { transform: scale(1.06); }
.product-badge {
  position: absolute; top: 9px; left: 9px; z-index: 2;
  background: linear-gradient(135deg, var(--color-secondary), var(--color-secondary)); color: #fff; font-size: 0.6rem;
  font-weight: 800; padding: 4px 9px; border-radius: var(--radius-pill); text-transform: uppercase; letter-spacing: 0.03em;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.18);
}
.product-badge.out { background: var(--color-muted); }
.product-body { padding: 11px 12px 2px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.product-cat {
  align-self: flex-start; font-size: 0.6rem; color: var(--color-primary-dark); background: var(--color-primary-light);
  text-transform: uppercase; letter-spacing: 0.04em; font-weight: 800; padding: 2px 8px; border-radius: var(--radius-pill);
}
.product-title { font-size: 0.85rem; font-weight: 700; line-height: 1.35; min-height: 2.3em; color: var(--color-ink); transition: color 0.15s ease; }
.product-title a:hover { color: var(--color-primary); }
.product-rating { display: flex; align-items: center; gap: 6px; }
.product-rating-stars { color: var(--color-accent); font-size: 0.78rem; letter-spacing: 1px; }
.product-rating-count { font-size: 0.7rem; color: var(--color-muted); font-weight: 600; }
.product-price-row { display: flex; align-items: baseline; gap: 7px; margin-top: 2px; }
.product-price { font-size: 1.02rem; font-weight: 800; color: var(--color-primary-dark); letter-spacing: -0.01em; }
.product-mrp { font-size: 0.74rem; color: var(--color-muted); text-decoration: line-through; }
.product-foot { padding: 8px 12px 12px; margin-top: auto; }
.product-foot .btn { border-radius: var(--radius-pill); font-size: 0.8rem; padding: 9px 16px; }

.qty-add-form { display: flex; }
.btn-addcart {
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-pill);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
  font-size: 0.88rem;
  padding: 11px 20px;
}
.btn-addcart:hover { background: var(--color-primary-dark); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.16); transform: translateY(-1px); }
.add-cart-btn { width: 100%; }
.add-cart-btn.is-added { background: var(--color-secondary); }

/* ---------- Category icon strip ---------- */
.category-icon-strip {
  display: flex; justify-content: space-between; gap: 26px; overflow-x: auto; padding: 0 40px 4px; scrollbar-width: none; width: 100%;
}
.category-icon-strip::-webkit-scrollbar { display: none; }
@media (max-width: 700px) { .category-icon-strip { justify-content: flex-start; padding: 0 20px 4px; } }
.category-icon-item { display: flex; flex-direction: column; align-items: center; gap: 10px; flex-shrink: 0; width: 84px; text-align: center; }
.category-icon-circle {
  width: 74px; height: 74px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  overflow: hidden; font-size: 1.6rem; font-weight: 800; color: #fff; box-shadow: var(--shadow-sm);
  transition: transform 0.2s cubic-bezier(.2,.8,.2,1), box-shadow 0.2s ease; border: 3px solid var(--color-surface);
}
.category-icon-circle img { width: 100%; height: 100%; object-fit: cover; }
.category-icon-item:hover .category-icon-circle { transform: translateY(-4px) scale(1.05); box-shadow: var(--shadow-md); }
.category-icon-label { font-size: 0.78rem; font-weight: 700; color: var(--color-ink); line-height: 1.3; }

/* ---------- Brand strip ---------- */
.brand-strip { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.brand-strip-label { font-size: 0.78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-muted); flex-shrink: 0; }
.brand-strip-names { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.brand-strip-item {
  font-size: 0.86rem; font-weight: 700; color: var(--color-ink-soft); padding: 8px 18px;
  border: 1px solid var(--color-border); border-radius: var(--radius-pill); background: var(--color-surface);
  transition: color 0.15s ease, border-color 0.15s ease;
}
.brand-strip-item:hover { color: var(--color-primary); border-color: var(--color-primary); }

/* ---------- Testimonials slider ---------- */
.testi-slider { position: relative; padding: 0 56px; }
.testi-track {
  display: flex; gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  scrollbar-width: none; padding: 6px 2px 18px;
}
.testi-track::-webkit-scrollbar { display: none; }
.testi-card {
  flex: 0 0 clamp(260px, 32vw, 340px); scroll-snap-align: start;
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  padding: 26px 24px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 10px;
}
.testi-quote-mark { font-size: 2.4rem; line-height: 1; color: var(--color-primary); font-weight: 800; font-family: Georgia, serif; }
.testi-stars { color: var(--color-accent); font-size: 0.95rem; letter-spacing: 2px; margin-top: -6px; }
.testi-quote { color: var(--color-ink-soft); line-height: 1.65; font-size: 0.92rem; flex: 1; }
.testi-person { display: flex; align-items: center; gap: 12px; margin-top: 6px; }
.testi-avatar {
  width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark)); color: #fff; font-weight: 800; font-size: 1rem;
}
.testi-name { font-weight: 700; font-size: 0.9rem; color: var(--color-ink); }
.testi-role { font-size: 0.78rem; color: var(--color-muted); }
.testi-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 42px; height: 42px; border-radius: 50%;
  background: var(--color-surface); border: 1px solid var(--color-border); color: var(--color-ink);
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-sm);
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.testi-nav:hover { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }
.testi-nav.prev { left: 0; }
.testi-nav.next { right: 0; }
.testi-dots { display: flex; justify-content: center; gap: 8px; margin-top: 4px; }
.testi-dots button {
  width: 8px; height: 8px; border-radius: 50%; background: var(--color-border); border: none; padding: 0;
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.testi-dots button.active { background: var(--color-primary); transform: scale(1.3); }
@media (max-width: 640px) {
  .testi-slider { padding: 0 8px; }
  .testi-nav { display: none; }
}

/* ---------- Hero trust strip ---------- */
.hero-trust {
  display: flex; align-items: center; gap: 0; background: var(--color-surface);
  border-radius: var(--radius-md); box-shadow: var(--shadow-sm); margin-top: 26px; padding: 6px 4px;
}
.hero-trust-item {
  flex: 1; display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-right: 1px solid var(--color-border);
}
.hero-trust-item:last-child { border-right: none; }
.hero-trust-icon {
  width: 40px; height: 40px; border-radius: 50%; background: var(--color-primary-light);
  color: var(--color-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.hero-trust-item h4 { font-size: 0.82rem; margin: 0 0 2px; }
.hero-trust-item p { font-size: 0.72rem; color: var(--color-ink-soft); line-height: 1.3; margin: 0; }

/* ---------- Promo banner ---------- */
.promo-banner {
  border-radius: var(--radius-lg); background: linear-gradient(125deg, var(--color-secondary) 0%, var(--color-primary-dark) 100%);
  color: #fff; padding: 50px 48px; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  position: relative; overflow: hidden;
}
.promo-banner::before {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.13) 1.5px, transparent 1.5px);
  background-size: 22px 22px; opacity: 0.5;
}
.promo-banner::after {
  content: ""; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
}
.promo-banner > div, .promo-banner > a { position: relative; z-index: 1; }
.promo-banner h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 8px; }
.promo-banner p { opacity: 0.92; max-width: 420px; }

/* ---------- Reveal-on-scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-stagger.is-visible > * { animation: fadeUp 0.6s ease both; }
.reveal-stagger.is-visible > *:nth-child(1) { animation-delay: 0.02s; }
.reveal-stagger.is-visible > *:nth-child(2) { animation-delay: 0.08s; }
.reveal-stagger.is-visible > *:nth-child(3) { animation-delay: 0.14s; }
.reveal-stagger.is-visible > *:nth-child(4) { animation-delay: 0.2s; }
.reveal-stagger.is-visible > *:nth-child(5) { animation-delay: 0.26s; }
.reveal-stagger.is-visible > *:nth-child(6) { animation-delay: 0.32s; }
.reveal-stagger.is-visible > *:nth-child(n+7) { animation-delay: 0.36s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: 0.85rem; color: var(--color-muted); padding: 18px 0; display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--color-primary); }

/* ---------- Filters / toolbar (listing page) ---------- */
.shop-layout { display: grid; grid-template-columns: 240px 1fr; gap: 32px; align-items: start; }
.filter-panel { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 20px; position: sticky; top: calc(var(--header-h) + 20px); }
.filter-panel h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-muted); margin-bottom: 14px; }
.filter-list { display: flex; flex-direction: column; gap: 4px; margin-bottom: 22px; }
.filter-list a { padding: 9px 10px; border-radius: 8px; font-size: 0.9rem; font-weight: 600; color: var(--color-ink-soft); display: flex; justify-content: space-between; }
.filter-list a:hover { background: var(--color-bg); }
.filter-list a.is-active { background: var(--color-primary-light); color: var(--color-primary-dark); }
.filter-list a .cnt { color: var(--color-muted); font-weight: 500; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.result-count { color: var(--color-ink-soft); font-size: 0.9rem; }
.sort-select { padding: 10px 14px; border-radius: var(--radius-pill); border: 1.5px solid var(--color-border); background: var(--color-surface); font-weight: 600; font-size: 0.88rem; }

.pager { display: flex; gap: 6px; align-items: center; justify-content: center; margin-top: 40px; flex-wrap: wrap; }
.pager-btn, .pager-num { padding: 9px 14px; border-radius: 10px; font-weight: 700; font-size: 0.85rem; border: 1px solid var(--color-border); background: var(--color-surface); }
.pager-num.is-active { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }
.pager-btn.is-disabled { opacity: 0.4; }
.pager-dots { padding: 0 4px; color: var(--color-muted); }

.empty-state { text-align: center; padding: 70px 20px; color: var(--color-ink-soft); }
.empty-state .emoji { font-size: 3rem; margin-bottom: 14px; }

/* ---------- Product detail ---------- */
.pd-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; }
.pd-gallery { position: sticky; top: calc(var(--header-h) + 20px); }
.pd-image { border-radius: var(--radius-lg); overflow: hidden; background: var(--color-surface); border: 1px solid var(--color-border); aspect-ratio: 4/3; }
.pd-image img { width: 100%; height: 100%; object-fit: cover; }
.pd-cat { color: var(--color-primary); font-weight: 700; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.04em; }
.pd-title { font-size: 1.8rem; margin: 8px 0 14px; }
.pd-price-row { display: flex; align-items: baseline; gap: 12px; margin-bottom: 4px; }
.pd-price { font-size: 2rem; font-weight: 800; color: var(--color-primary-dark); }
.pd-mrp { font-size: 1.05rem; color: var(--color-muted); text-decoration: line-through; }
.pd-save {
  color: var(--color-primary-dark); font-weight: 800; font-size: 0.8rem; margin-left: auto;
  background: var(--color-primary-light); border: 1px solid color-mix(in srgb, var(--color-primary) 30%, transparent);
  padding: 4px 12px; border-radius: var(--radius-pill);
}
.pd-meta { display: flex; gap: 18px; color: var(--color-ink-soft); font-size: 0.85rem; margin: 14px 0; flex-wrap: wrap; }
.stock-urgency { margin: 12px 0 4px; }
.stock-urgency-row { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; font-weight: 700; color: var(--color-accent); }
.stock-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--color-accent); flex-shrink: 0; animation: stockPulse 1.5s infinite; }
.stock-units { margin-left: auto; font-weight: 600; color: var(--color-muted); font-size: 0.8rem; }
.stock-bar { height: 3px; border-radius: 2px; margin-top: 6px; background: linear-gradient(90deg, var(--color-accent), var(--color-primary)); }
@keyframes stockPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
.pd-sizes, .pd-colors { margin: 18px 0; }
.pd-sizes label, .pd-colors label { display: block; font-size: 0.78rem; font-weight: 700; color: var(--color-ink-soft); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 9px; }
.size-swatch-row, .color-swatch-row { display: flex; flex-wrap: wrap; gap: 10px; }
.size-swatch {
  min-width: 46px; height: 46px; padding: 0 6px; border-radius: 50%; border: 1.5px solid var(--color-border);
  background: var(--color-surface); color: var(--color-ink); font-weight: 700; font-size: 0.82rem;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
  transition: border-color 0.12s ease, color 0.12s ease, transform 0.12s ease;
}
.size-swatch:hover:not(.oos) { border-color: var(--color-primary); transform: translateY(-1px); }
.size-swatch.active { border-width: 2px; border-color: var(--color-primary); color: var(--color-primary-dark); font-weight: 800; }
.size-swatch.oos { color: var(--color-muted); opacity: 0.45; cursor: not-allowed; }
.size-swatch.oos:hover { transform: none; }
.color-swatch {
  width: 32px; height: 32px; border-radius: 50%; border: 3px solid var(--color-border);
  cursor: pointer; padding: 0; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
  transition: transform 0.12s ease, border-color 0.12s ease, box-shadow 0.12s ease;
}
.color-swatch:hover { transform: scale(1.08); }
.color-swatch.active { border-width: 3px; border-color: var(--color-primary); box-shadow: 0 0 0 3px var(--color-primary-light), 0 1px 3px rgba(0, 0, 0, 0.12); }
.pd-actions { display: flex; gap: 14px; align-items: center; margin: 26px 0; }
.pd-actions .cart-ctrl { min-width: 240px; }
.pd-actions .cart-ctrl .stepper { height: 46px; }
.pd-actions .cart-ctrl .stepper input { height: 100%; }
.stepper { display: flex; align-items: center; border: 1.5px solid var(--color-primary); border-radius: var(--radius-pill); overflow: hidden; background: var(--color-primary-light); }
.stepper button { width: 38px; height: 42px; background: transparent; color: var(--color-primary-dark); font-size: 1.15rem; font-weight: 800; border: none; transition: background-color 0.15s ease; cursor: pointer; }
.stepper button:hover { background: rgba(0, 0, 0, 0.06); }
.stepper input { width: 44px; text-align: center; border: none; background: transparent; font-weight: 800; font-size: 0.95rem; color: var(--color-ink); }
.stepper input::-webkit-outer-spin-button,
.stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper input[type=number] { -moz-appearance: textfield; }
.stepper-block { width: 100%; justify-content: space-between; }
.stepper-block button { flex: 0 0 auto; }
.pd-desc { color: var(--color-ink-soft); line-height: 1.7; }
.trust-badges { display: flex; gap: 20px; margin-top: 30px; flex-wrap: wrap; }
.trust-badges div { display: flex; gap: 8px; align-items: center; font-size: 0.82rem; font-weight: 600; color: var(--color-ink-soft); }

.pd-rating-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 0.9rem; color: var(--color-ink-soft); }
.pd-rating-stars { color: var(--color-accent); letter-spacing: 1px; }
.pd-rating-link strong { color: var(--color-ink); }

/* ---------- Product reviews ---------- */
.reviews-layout { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: start; }
.review-card { padding: 20px 0; border-bottom: 1px solid var(--color-border); }
.review-card:first-child { padding-top: 0; }
.review-card-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.review-stars { color: var(--color-accent); letter-spacing: 1px; font-size: 0.9rem; }
.review-date { color: var(--color-muted); font-size: 0.78rem; margin-left: auto; }
.review-text { color: var(--color-ink-soft); font-size: 0.92rem; line-height: 1.6; }

.review-form-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 26px; position: sticky; top: calc(var(--header-h) + 20px); }
.review-form-card h3 { font-size: 1.05rem; margin-bottom: 16px; }
.review-form-card textarea {
  width: 100%; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--color-border);
  font-family: inherit; font-size: 0.9rem; resize: vertical; outline: none; margin-bottom: 16px;
}
.review-form-card textarea:focus { border-color: var(--color-primary); }

.star-picker { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; margin-bottom: 16px; font-size: 1.8rem; }
.star-picker input { position: absolute; opacity: 0; width: 0; height: 0; }
.star-picker label { cursor: pointer; color: var(--color-border); transition: color 0.15s ease; }
.star-picker label span { pointer-events: none; }
.star-picker input:checked ~ label,
.star-picker label:hover,
.star-picker label:hover ~ label { color: var(--color-accent); }

/* ---------- Cart page ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 32px; align-items: start; }
.cart-row {
  display: grid; grid-template-columns: 74px 1fr auto auto; gap: 16px; align-items: center;
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md);
  padding: 14px; margin-bottom: 14px;
}
.cart-row img { width: 74px; height: 74px; border-radius: 10px; object-fit: cover; }
.cart-row h4 { font-size: 0.95rem; margin-bottom: 4px; }
.cart-row .unit { font-size: 0.78rem; color: var(--color-muted); }
.cart-row .price { font-weight: 700; color: var(--color-primary-dark); }
.cart-row-tags { display: flex; align-items: center; gap: 10px; margin-top: 6px; flex-wrap: wrap; }
.cart-save-tag {
  font-size: 0.72rem; font-weight: 800; color: var(--color-primary-dark); background: var(--color-primary-light);
  padding: 2px 9px; border-radius: var(--radius-pill);
}
.cart-lowstock-tag { display: inline-flex; align-items: center; gap: 5px; font-size: 0.72rem; font-weight: 700; color: var(--color-accent); }
.remove-link { color: var(--color-danger); font-size: 0.8rem; font-weight: 700; }
.summary-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 24px; position: sticky; top: calc(var(--header-h) + 20px); }
.summary-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 0.92rem; color: var(--color-ink-soft); }
.summary-row.total { border-top: 1px dashed var(--color-border); margin-top: 8px; padding-top: 14px; font-size: 1.1rem; font-weight: 800; color: var(--color-ink); }

/* ---------- Forms ---------- */
.auth-shell { max-width: 440px; margin: 0 auto; }
.form-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 34px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 700; font-size: 0.85rem; margin-bottom: 7px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 15px; border-radius: 10px; border: 1.5px solid var(--color-border); outline: none;
  transition: border-color 0.15s ease;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--color-primary); }
.form-alert { padding: 12px 16px; border-radius: 10px; background: #fef2f2; color: var(--color-danger); font-size: 0.88rem; margin-bottom: 18px; font-weight: 600; }
.form-alert.success { background: var(--color-secondary-light); color: var(--color-secondary); }

.pay-options { display: flex; flex-direction: column; gap: 10px; }
.pay-option {
  display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-radius: 12px;
  border: 1.5px solid var(--color-border); cursor: pointer; font-weight: 600; font-size: 0.92rem;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.pay-option:has(input:checked) { border-color: var(--color-primary); background: var(--color-primary-light); }
.pay-option input { accent-color: var(--color-primary); width: 17px; height: 17px; }

/* ---------- UPI QR pay page ---------- */
.qr-pay-card { max-width: 440px; margin: 0 auto; background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 32px; text-align: center; }
.qr-pay-box { background: var(--color-bg); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 22px; margin-bottom: 22px; }
.qr-pay-box #upi-qr { display: flex; justify-content: center; margin-bottom: 14px; }
.qr-pay-box #upi-qr img, .qr-pay-box #upi-qr canvas { border-radius: 8px; background: #fff; padding: 8px; }
.qr-pay-amount { font-size: 0.9rem; color: var(--color-ink-soft); }
.qr-pay-steps { text-align: left; margin: 0 0 22px; padding-left: 20px; color: var(--color-ink-soft); font-size: 0.88rem; line-height: 1.9; }

/* ---------- Orders table ---------- */
.order-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 18px 20px; margin-bottom: 14px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.status-pill { font-size: 0.72rem; font-weight: 800; padding: 5px 12px; border-radius: var(--radius-pill); text-transform: uppercase; letter-spacing: 0.03em; }
.status-pill.pending { background: #fef9c3; color: #854d0e; }
.status-pill.processing { background: #e0f2fe; color: #0369a1; }
.status-pill.shipped { background: #dbeafe; color: #1d4ed8; }
.status-pill.delivered { background: #dcfce7; color: #15803d; }
.status-pill.completed { background: var(--color-secondary-light); color: var(--color-secondary); }
.status-pill.cancelled { background: #fee2e2; color: var(--color-danger); }

/* ---------- Order tracker ---------- */
.tracker-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 30px 24px 24px; margin-bottom: 22px; overflow-x: auto; }
.tracker-steps { display: flex; align-items: flex-start; min-width: 460px; }
.tracker-step { display: flex; flex-direction: column; align-items: center; gap: 8px; flex: 0 0 auto; width: 92px; text-align: center; }
.tracker-step-icon {
  width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--color-border); color: var(--color-muted); background: var(--color-surface); flex-shrink: 0;
}
.tracker-step.done .tracker-step-icon { background: var(--color-secondary); border-color: var(--color-secondary); color: #fff; }
.tracker-step.active .tracker-step-icon { background: var(--color-primary); border-color: var(--color-primary); color: #fff; box-shadow: 0 0 0 5px var(--color-primary-light); }
.tracker-step-label { font-size: 0.76rem; font-weight: 700; color: var(--color-muted); }
.tracker-step.done .tracker-step-label, .tracker-step.active .tracker-step-label { color: var(--color-ink); }
.tracker-connector { flex: 1 1 auto; height: 3px; background: var(--color-border); margin-top: 22px; border-radius: 2px; }
.tracker-connector.done { background: var(--color-secondary); }
.tracker-connector.active { background: var(--color-primary); }
.tracker-cancelled-banner {
  display: flex; align-items: center; gap: 10px; background: #fef2f2; color: var(--color-danger); border: 1px solid #fecaca;
  border-radius: var(--radius-md); padding: 16px 18px; font-weight: 700; margin-bottom: 22px;
}
.order-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 22px; }
.order-info-panel { display: flex; gap: 14px; background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 18px; }
.order-info-icon {
  width: 40px; height: 40px; border-radius: 50%; background: var(--color-primary-light); color: var(--color-primary-dark);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.order-info-label { font-size: 0.68rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-muted); margin-bottom: 4px; }
.order-info-title { font-weight: 800; color: var(--color-ink); margin-bottom: 4px; }
.order-info-text { font-size: 0.85rem; color: var(--color-ink-soft); line-height: 1.5; }
.support-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 30px;
  background: var(--color-primary-light); border: 1px solid color-mix(in srgb, var(--color-primary) 25%, transparent);
  border-radius: var(--radius-md); padding: 16px 20px; font-weight: 700; color: var(--color-primary-dark); font-size: 0.9rem;
}
.support-bar > div { display: flex; align-items: center; gap: 10px; }
@media (max-width: 640px) { .order-info-grid { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--color-ink); color: #cbd2d9; padding: 60px 0 24px; margin-top: 80px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-grid h5 { color: #fff; font-size: 0.95rem; margin-bottom: 16px; }
.footer-grid ul li { margin-bottom: 10px; font-size: 0.88rem; }
.footer-grid ul li a:hover { color: #fff; }
.footer-bottom { display: flex; justify-content: space-between; padding-top: 22px; font-size: 0.8rem; color: #8a94a3; flex-wrap: wrap; gap: 10px; }

/* ---------- Toast ---------- */
#toast-zone { position: fixed; bottom: 22px; right: 22px; z-index: 200; display: flex; flex-direction: column; gap: 10px; }
.toast {
  background: var(--color-ink); color: #fff; padding: 13px 20px; border-radius: 12px; font-weight: 600; font-size: 0.88rem;
  box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 10px; animation: toastIn 0.25s ease;
}
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Mobile ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; height: 280px; margin-bottom: 10px; }
  .hero-visual.has-photo {
    width: 100vw; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); height: 320px;
  }
  .hero-visual.has-photo .hero-photo-card { border-radius: 0; }
  .hero-mini-card { width: 150px; }
  .shop-layout { grid-template-columns: 1fr; }
  .filter-panel { position: static; }
  .pd-grid { grid-template-columns: 1fr; }
  .reviews-layout { grid-template-columns: 1fr; }
  .review-form-card { position: static; }
  .pd-gallery { position: static; }
  .cart-layout { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1080px) {
  .hlink-text { display: none; }
  .hlink { padding: 10px; }
  .hlink.cart-link { padding: 10px 12px; }
}
@media (max-width: 760px) {
  :root { --header-h: 60px; }
  .header-row { height: 60px; gap: 10px; }
  .brand { font-size: 1.05rem; gap: 6px; }
  .brand-logo-img { height: 38px; max-width: 110px; }
  .brand-name { max-width: 22vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .header-search input { padding: 9px 14px; font-size: 0.88rem; }
  .header-search button { padding: 0 16px; }
  .hlink:not(.cart-link) { display: none; }
  .header-actions { gap: 2px; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-trust { flex-direction: column; }
  .hero-trust-item { border-right: none; border-bottom: 1px solid var(--color-border); width: 100%; }
  .hero-trust-item:last-child { border-bottom: none; }
  .cart-row { grid-template-columns: 60px 1fr; grid-template-rows: auto auto; }
  .hamburger { display: flex; }
}

/* ---------- Mobile drawer nav ---------- */
.mobile-drawer {
  position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 100; display: none;
}
.mobile-drawer.is-open { display: block; }
.mobile-drawer-panel {
  position: absolute; top: 0; right: 0; width: 78%; max-width: 320px; height: 100%; background: #fff;
  padding: 24px; overflow-y: auto; animation: slideIn 0.25s ease;
}
@keyframes slideIn { from { transform: translateX(30px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.mobile-drawer-panel a { display: block; padding: 13px 0; font-weight: 700; border-bottom: 1px solid var(--color-border); }
.mobile-search { display: flex; margin-bottom: 20px; }
.mobile-search input { flex: 1; padding: 11px 14px; border: 1.5px solid var(--color-border); border-radius: 10px 0 0 10px; }
.mobile-search button { display: flex; align-items: center; justify-content: center; border-radius: 0 10px 10px 0; border: 1.5px solid var(--color-primary); background: var(--color-primary); color: #fff; padding: 0 14px; }

/* ---------- Chat widget (in-house product search bot, no external AI) ---------- */
.chat-widget { position: fixed; right: 20px; bottom: calc(20px + var(--mobile-tabbar-h)); z-index: 200; }
.chat-toggle {
  width: 58px; height: 58px; border-radius: 50%; border: none; cursor: pointer;
  background: linear-gradient(135deg, var(--color-accent), var(--color-accent)); color: #fff;
  font-size: 1.5rem; box-shadow: 0 10px 24px color-mix(in srgb, var(--color-accent) 40%, transparent);
  display: flex; align-items: center; justify-content: center; transition: transform 0.15s ease;
}
.chat-toggle:hover { transform: scale(1.06); }
.chat-panel {
  position: absolute; right: 0; bottom: 74px; width: 340px; max-width: calc(100vw - 40px);
  height: 460px; max-height: 70vh; background: var(--color-surface); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden;
  opacity: 0; transform: translateY(16px) scale(0.98); pointer-events: none; transition: opacity 0.18s ease, transform 0.18s ease;
}
.chat-panel.is-open { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
.chat-header {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark)); color: #fff;
  padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; font-weight: 800; font-size: 0.95rem;
}
.chat-close { background: none; border: none; color: #fff; font-size: 1rem; cursor: pointer; opacity: 0.85; padding: 0; }
.chat-close:hover { opacity: 1; }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; background: var(--color-bg); }
.chat-msg { display: flex; flex-direction: column; }
.chat-msg.user { align-items: flex-end; }
.chat-msg.bot { align-items: flex-start; }
.chat-bubble { max-width: 84%; padding: 10px 14px; border-radius: 14px; font-size: 0.86rem; line-height: 1.5; }
.chat-msg.bot .chat-bubble { background: var(--color-surface); border: 1px solid var(--color-border); color: var(--color-ink); border-bottom-left-radius: 4px; }
.chat-msg.user .chat-bubble { background: var(--color-primary); color: #fff; border-bottom-right-radius: 4px; }
.chat-typing .chat-bubble { display: flex; gap: 4px; padding: 12px 14px; }
.chat-typing .chat-bubble span { width: 6px; height: 6px; border-radius: 50%; background: var(--color-muted); animation: chatTyping 1s infinite ease-in-out; }
.chat-typing .chat-bubble span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing .chat-bubble span:nth-child(3) { animation-delay: 0.3s; }
@keyframes chatTyping { 0%, 60%, 100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-4px); opacity: 1; } }
.chat-products { display: flex; gap: 10px; overflow-x: auto; margin-top: 4px; padding-bottom: 4px; scrollbar-width: none; max-width: 100%; }
.chat-products::-webkit-scrollbar { display: none; }
.chat-product-card { flex: 0 0 110px; background: var(--color-surface); border: 1px solid var(--color-border); border-radius: 10px; padding: 8px; text-align: left; }
.chat-product-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; border-radius: 6px; margin-bottom: 6px; }
.chat-product-name { font-size: 0.72rem; font-weight: 700; color: var(--color-ink); line-height: 1.3; max-height: 2.6em; overflow: hidden; }
.chat-product-price { font-size: 0.76rem; font-weight: 800; color: var(--color-primary-dark); margin-top: 2px; }
.chat-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--color-border); background: var(--color-surface); }
.chat-input { flex: 1; min-width: 0; padding: 10px 14px; border-radius: var(--radius-pill); border: 1.5px solid var(--color-border); font-size: 0.85rem; outline: none; }
.chat-input:focus { border-color: var(--color-primary); }
.chat-send {
  width: 40px; height: 40px; border-radius: 50%; border: none; background: var(--color-primary); color: #fff;
  display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; font-size: 1rem;
}
.chat-send:hover { background: var(--color-primary-dark); }
@media (max-width: 480px) {
  .chat-widget { right: 12px; bottom: calc(12px + var(--mobile-tabbar-h)); }
  .chat-panel { right: -4px; width: calc(100vw - 24px); }
}

/* ---------- Mobile app-style bottom tab bar ---------- */
.mobile-tabbar { display: none; }
@media (max-width: 640px) {
  :root { --mobile-tabbar-h: 60px; }
  body { padding-bottom: var(--mobile-tabbar-h); }
  .mobile-tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 150; height: var(--mobile-tabbar-h);
    background: var(--color-surface); border-top: 1px solid var(--color-border);
    box-shadow: 0 -6px 18px rgba(31, 41, 51, 0.08); padding-bottom: env(safe-area-inset-bottom, 0);
  }
  .mobile-tab {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    color: var(--color-muted); font-size: 0.66rem; font-weight: 700; transition: color 0.15s ease;
  }
  .mobile-tab.active { color: var(--color-primary); }
  .mobile-tab-icon-wrap { position: relative; display: inline-flex; }
  .mobile-tab-badge {
    position: absolute; top: -4px; right: -9px; background: var(--color-primary); color: #fff;
    font-size: 0.6rem; font-weight: 800; min-width: 15px; height: 15px; border-radius: 50%; line-height: 15px;
    text-align: center; padding: 0 3px;
  }
  .mobile-tab-badge.is-hidden { display: none; }
  /* Product page's Add to Cart becomes a fixed app-style bottom action bar. */
  .pd-actions {
    position: fixed; left: 0; right: 0; bottom: var(--mobile-tabbar-h); z-index: 140; margin: 0;
    background: var(--color-surface); padding: 12px 16px; box-shadow: 0 -6px 18px rgba(31, 41, 51, 0.08);
  }
  .pd-actions .cart-ctrl { min-width: 0; flex: 1; }
  .pd-desc { margin-bottom: 90px; }
}
