/* WholesaleBhai — navy + orange. Assets are final; do not redraw. */
:root {
  --ink: #333333;
  --muted: #5c6b7a;
  --bg: #F5F7FA;
  --card: #ffffff;
  --line: #e2e8f0;
  --brand: #0B2D52;
  --brand-deep: #0B2D52;
  --brand-soft: #e8eef4;
  --coral: #FF7A00;
  --coral-soft: #fff1e3;
  --gold: #FF7A00;
  --gold-soft: #fff1e3;
  --plum: #0B2D52;
  --plum-soft: #e8eef4;
  --shadow: 0 12px 32px rgba(11, 45, 82, 0.08);
  --green: var(--brand);
  --green-dark: var(--brand-deep);
  --green-soft: var(--brand-soft);
  font-family: Poppins, "Segoe UI", system-ui, sans-serif;
  --page-max: 1600px;
  --page-pad: 12px;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); min-height: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }

.site-head {
  position: sticky;
  top: 0;
  z-index: 30;
}
.util-bar {
  background: var(--brand-deep);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.page-wrap {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding-left: var(--page-pad);
  padding-right: var(--page-pad);
  box-sizing: border-box;
}
.util-inner {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 6px var(--page-pad);
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  box-sizing: border-box;
  width: 100%;
}
.util-link, .util-bar a, .util-bar button {
  color: #fff;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 650;
  text-decoration: none;
}
.util-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.util-link svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}
.util-link:hover, .util-bar a:hover { opacity: 0.88; }
.util-link[hidden],
.nav-guest[hidden],
.nav-auth[hidden] {
  display: none !important;
}
.util-spacer { flex: 1; }
.account-menu { position: relative; }
.account-toggle {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  gap: 1px;
  padding: 2px 0;
}
.account-hi { font-size: 13px; font-weight: 500; }
.account-hi strong { font-weight: 800; }
.account-toggle small,
#nav-shop {
  display: none;
}
.account-drop {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 260px;
  background: #fff;
  color: var(--ink);
  border-radius: 12px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  overflow: hidden;
  z-index: 40;
}
.account-drop[hidden] { display: none; }
.account-card {
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  color: #fff;
  padding: 12px 14px;
}
.account-card strong { display: block; font-size: 13px; }
.account-card span { display: block; margin-top: 4px; font-size: 12px; opacity: 0.95; }
.account-drop a, .account-drop button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  color: var(--ink);
  font-weight: 600;
  font-size: 14px;
  background: #fff;
  border: 0;
  border-top: 1px solid var(--line);
  cursor: pointer;
}
.account-drop a:hover, .account-drop button:hover { background: var(--gold-soft); }

.topbar {
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: center;
  padding-top: 8px;
  padding-bottom: 8px;
}
.topbar-mid {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.brand { display: flex; gap: 10px; align-items: center; flex: 0 0 auto; }
.brand-lockup,
.brand-lockup.is-custom {
  display: block;
  height: 68px;
  width: 124px;
  max-width: none;
  object-fit: fill;
  object-position: left center;
  border-radius: 0;
  background: #ffffff;
}
.brand-logo {
  width: 44px; height: 44px; border-radius: 14px;
  object-fit: cover; background: var(--brand);
  box-shadow: 0 4px 12px rgba(11, 45, 82, 0.18);
}
.brand-mark {
  width: 42px; height: 42px; border-radius: 12px;
  background: var(--brand); color: #fff; font-weight: 800;
  display: grid; place-items: center;
}
.brand small { display: block; color: var(--muted); font-size: 12px; }
.loc-chip {
  display: flex; gap: 8px; align-items: center;
  background: var(--gold-soft); color: #92400e;
  border: 0; border-radius: 12px; padding: 6px 12px 6px 8px;
  cursor: default; text-align: left;
  flex: 0 0 auto;
}
.loc-chip svg { width: 22px; height: 22px; flex: 0 0 auto; color: var(--plum); }
.loc-chip b, .loc-chip small { display: block; }
.loc-chip b { font-size: 13px; }
.loc-chip small { font-size: 11px; color: var(--muted); font-weight: 500; }
.search { display: flex; flex: 1; min-width: 0; max-width: none; width: 100%; margin: 0; position: relative; }
.search input {
  flex: 1; border: 1px solid var(--line); border-right: 0;
  border-radius: 999px 0 0 999px; padding: 10px 16px; background: #fff;
}
.search button[type="submit"] {
  background: var(--coral); color: #fff; border: 0;
  border-radius: 0 999px 999px 0; padding: 10px 18px; cursor: pointer; font-weight: 700;
}
.search-suggest {
  position: absolute;
  left: 0; right: 0; top: calc(100% + 8px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
  z-index: 40;
  margin: 0;
  padding: 6px;
  list-style: none;
  max-height: min(70vh, 380px);
  overflow: auto;
}
.search-suggest[hidden] { display: none; }
.search-suggest li button {
  width: 100%;
  display: flex;
  align-items: baseline;
  gap: 10px;
  text-align: left;
  border: 0;
  background: transparent;
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
}
.search-suggest li button:hover,
.search-suggest li.on button { background: var(--gold-soft); }
.search-suggest .sg-label { flex: 1; font-weight: 650; }
.search-suggest .sg-label b { font-weight: 800; color: var(--plum); }
.search-suggest .sg-hint { color: var(--muted); font-size: 12px; font-weight: 500; }
.search-suggest .sg-all {
  border-top: 1px solid var(--line);
  margin-top: 4px;
  padding-top: 4px;
}
.search-suggest .sg-all button { color: var(--coral); font-weight: 800; }
.top-actions { display: flex; gap: 14px; align-items: center; font-weight: 600; font-size: 14px; }
.top-actions a:hover { color: var(--plum); }
.cart-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--coral); color: #fff; border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
}
.cart-btn svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}
#cart-count {
  background: var(--gold); color: var(--ink); border-radius: 999px; padding: 1px 7px; margin-left: 4px;
}

#app { max-width: var(--page-max); margin: 0 auto; padding: 20px var(--page-pad) 88px; box-sizing: border-box; width: 100%; }

.hero {
  background:
    radial-gradient(900px 280px at 92% -10%, rgba(225, 29, 72, 0.42), transparent 52%),
    radial-gradient(700px 220px at 8% 110%, rgba(232, 163, 23, 0.38), transparent 48%),
    linear-gradient(135deg, #0B2D52 0%, #123a68 46%, #FF7A00 100%);
  color: #fff; border-radius: 22px; padding: 32px 28px; margin-bottom: 22px;
  box-shadow: var(--shadow);
}
.hero h1 { margin: 0 0 8px; font-size: 32px; letter-spacing: -0.03em; }
.hero p { margin: 0 0 16px; opacity: 0.95; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-pill {
  background: rgba(255,255,255,0.16); border: 1px solid rgba(255,255,255,0.32);
  border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600;
}
.chip-pill:nth-child(2) { background: rgba(232, 163, 23, 0.28); }
.chip-pill:nth-child(3) { background: rgba(225, 29, 72, 0.28); }
.toast {
  position: fixed; top: 108px; right: 16px; z-index: 40;
  background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 10px;
  font-weight: 700; box-shadow: var(--shadow);
}
.toast[hidden] { display: none; }

.section-head { display: flex; justify-content: space-between; align-items: baseline; margin: 8px 0 12px; }
.section-head h2 { margin: 0; font-size: 20px; }
.section-head a { color: var(--coral); font-weight: 700; font-size: 14px; }
.muted { color: var(--muted); }

.cat-row {
  display: flex; gap: 18px; overflow-x: auto; padding: 6px 2px 18px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.cat-row::-webkit-scrollbar { height: 6px; }
.cat-row::-webkit-scrollbar-thumb { background: #d4c4b0; border-radius: 99px; }

.cat-round {
  flex: 0 0 96px; width: 96px; text-align: center; scroll-snap-align: start;
}
.cat-round strong {
  display: block; margin-top: 8px; font-size: 12px; line-height: 1.3; font-weight: 600;
}
.cat-photo, .cat-ico {
  width: 80px; height: 80px; border-radius: 50%;
  object-fit: cover; display: grid; place-items: center;
  margin: 0 auto; background: var(--brand-soft); color: var(--brand-deep);
  border: 2px solid #fff; box-shadow: 0 6px 16px rgba(23, 20, 31, 0.10);
}
.cat-round:nth-child(4n+2) .cat-ico { background: var(--coral-soft); color: var(--coral); }
.cat-round:nth-child(4n+3) .cat-ico { background: var(--gold-soft); color: #b45309; }
.cat-round:nth-child(4n+4) .cat-ico { background: var(--plum-soft); color: var(--plum); }
.cat-ico svg { width: 34px; height: 34px; display: block; }

.cat-grid, .prod-grid { display: grid; gap: 14px; }
.cat-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.prod-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.home-section { margin-bottom: 22px; }
.section-scroller {
  display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 16px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.section-scroller::-webkit-scrollbar { height: 6px; }
.section-scroller::-webkit-scrollbar-thumb { background: #d4c4b0; border-radius: 99px; }
.section-scroller .prod-tile {
  flex: 0 0 210px; width: 210px; scroll-snap-align: start;
}

.tile, .card {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow);
}
.tile { padding: 16px; min-height: 104px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.tile .cat-photo { width: 64px; height: 64px; margin: 0; }
.tile .cat-ico {
  width: 44px; height: 44px; border-radius: 12px; margin: 0;
  background: var(--brand-soft); color: var(--brand-deep);
}
.tile:nth-child(4n+2) .cat-ico { background: var(--coral-soft); color: var(--coral); }
.tile:nth-child(4n+3) .cat-ico { background: var(--gold-soft); color: #b45309; }
.tile:nth-child(4n+4) .cat-ico { background: var(--plum-soft); color: var(--plum); }
.tile.brand-tile .cat-ico {
  background: var(--plum-soft); color: var(--plum); font-size: 18px; border-radius: 12px;
}
.tile.brand-tile .cat-photo { border-radius: 12px; object-fit: contain; background: #fff; }
.tile strong { display: block; }
.tile span { color: var(--muted); font-size: 13px; }

.card { overflow: hidden; display: flex; flex-direction: column; }
.card .thumb {
  height: 140px; background: var(--gold-soft); display: grid; place-items: center;
  color: var(--plum); font-weight: 800; font-size: 28px;
}
.card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.card .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card h3 { margin: 0; font-size: 16px; line-height: 1.3; }
.from { color: var(--plum); font-weight: 800; font-size: 18px; }
.moq { font-size: 12px; color: var(--muted); }

.prod-tile {
  background: #fff;
  border: 1px solid #ece7e0;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  box-shadow: 0 1px 0 rgba(23, 20, 31, 0.04);
}
.prod-tile-link {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  color: inherit;
}
.prod-tile-media {
  position: relative;
  height: 168px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid #f3eee8;
}
.prod-tile-media img {
  max-width: 86%;
  max-height: 86%;
  width: auto;
  height: auto;
  object-fit: contain;
}
.prod-tile-fallback {
  color: var(--plum);
  font-weight: 800;
  font-size: 28px;
}
.off-badge {
  position: absolute;
  left: 0;
  top: 10px;
  z-index: 1;
  background: #e11d48;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 4px 10px 4px 9px;
  border-radius: 0 999px 999px 0;
  box-shadow: 0 2px 8px rgba(225, 29, 72, 0.35);
}
.prod-tile h3 {
  margin: 8px 10px 4px;
  font-size: 13.5px;
  font-weight: 650;
  line-height: 1.35;
  min-height: 2.7em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.prod-hero-price {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin: 0 10px 8px;
}
.prod-hero-price .prod-mrp {
  margin: 0;
  font-size: 17px;
  font-weight: 650;
  color: var(--muted);
  line-height: 1.2;
}
.prod-hero-price .prod-mrp s {
  color: #6b7280;
  text-decoration-thickness: 2px;
}
.prod-hero-price .prod-deal {
  font-size: 20px;
  font-weight: 800;
  color: #15803d;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.prod-slabs {
  margin: 0 10px 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.prod-slab {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  font-size: 12px;
  line-height: 1.4;
}
.prod-slab .qty { color: var(--muted); }
.prod-slab .rate { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; align-items: baseline; }
.prod-slab .price { color: #15803d; font-weight: 700; }
.prod-slab .pct { color: #16a34a; font-size: 11px; font-weight: 650; }
.prod-mrp {
  margin: 0 10px 8px;
  font-size: 12px;
  color: var(--muted);
}
.prod-mrp s { color: #9ca3af; }
.prod-add {
  margin: 0 10px 10px;
  width: calc(100% - 20px);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--brand); color: #fff; border: 0; border-radius: 8px;
  padding: 9px 12px; cursor: pointer; font-weight: 700;
}
.btn.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.crumbs { color: var(--muted); margin-bottom: 12px; font-size: 14px; }
.subs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.chip {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 12px; font-size: 13px;
}
.chip.on { background: var(--coral-soft); border-color: var(--coral); color: var(--coral); font-weight: 700; }

.pdp { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.pdp .gallery {
  background: #fff; border-radius: 16px; min-height: 280px;
  display: grid; place-items: center; border: 1px solid var(--line);
}
.pdp .gallery img { max-width: 100%; max-height: 360px; }
.slabs { width: 100%; border-collapse: collapse; margin: 12px 0; background: #fff; }
.slabs th, .slabs td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; }
.slabs tr.hit { background: var(--gold-soft); font-weight: 700; }
.qty-row { display: flex; gap: 8px; align-items: center; margin: 12px 0; }
.qty-row input { width: 88px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; text-align: center; }

.cart-line {
  display: grid; grid-template-columns: 1fr auto auto; gap: 12px;
  background: #fff; padding: 12px; border-radius: 12px; margin-bottom: 10px;
  border: 1px solid var(--line);
}
.totals { background: #fff; padding: 16px; border-radius: 12px; border: 1px solid var(--line); }
.auth, .notice {
  max-width: 420px; margin: 0 auto; background: #fff; padding: 22px;
  border-radius: 16px; border: 1px solid var(--line);
}
.auth-lockup,
.auth-logo {
  display: block;
  height: 72px;
  width: auto;
  max-width: min(320px, 100%);
  margin: 0 auto 14px;
  object-fit: contain;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}
.auth label { display: block; font-size: 13px; margin: 10px 0 4px; }
.auth input, .auth select, .auth textarea {
  width: 100%; padding: 10px; border: 1px solid var(--line); border-radius: 8px;
}
.err { color: var(--coral); font-size: 14px; }
.ok { color: var(--brand-deep); }
.table { width: 100%; border-collapse: collapse; background: #fff; }
.table th, .table td { border-bottom: 1px solid var(--line); padding: 10px; text-align: left; }
.track-pill {
  display: inline-block; background: var(--gold-soft); color: #92400e;
  font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px;
}
.site-foot { text-align: center; color: var(--muted); padding: 16px var(--page-pad); font-size: 13px; max-width: var(--page-max); margin: 0 auto; box-sizing: border-box; width: 100%; }
.mobile-nav { display: none; }
.empty { padding: 40px 12px; text-align: center; color: var(--muted); }
.banner-wrap { position: relative; margin-bottom: 20px; border-radius: 18px; overflow: hidden; background: #17141f; min-height: 160px; }
.banner-slide { display: none; }
.banner-slide.on { display: block; }
.banner-slide img { width: 100%; height: 200px; object-fit: cover; display: block; }
.banner-caption {
  position: absolute; left: 16px; bottom: 16px; color: #fff;
  background: rgba(23, 20, 31, 0.55); padding: 8px 12px; border-radius: 10px; font-weight: 700;
}
.banner-dots { position: absolute; right: 12px; bottom: 12px; display: flex; gap: 6px; }
.banner-dots button {
  width: 8px; height: 8px; border-radius: 999px; border: 0; background: rgba(255,255,255,0.45); padding: 0; cursor: pointer;
}
.banner-dots button.on { background: var(--gold); }
.banner-fallback {
  min-height: 160px;
  background: linear-gradient(135deg, #0B2D52, #123a68 55%, #FF7A00);
}
.banner-fallback-title {
  display: block; color: #fff; font-size: 28px; font-weight: 800;
  padding: 56px 24px 40px;
}
.offer-badge {
  display: inline-block; background: var(--coral-soft); color: var(--coral);
  font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
}
.strike { text-decoration: line-through; color: var(--muted); font-weight: 600; margin-right: 6px; }

@media (max-width: 960px) {
  .topbar-inner { grid-template-columns: auto 1fr auto; }
  .brand-lockup,
  .brand-lockup.is-custom {
    height: 58px;
    width: 106px;
  }
}
@media (max-width: 840px) {
  .topbar-inner { grid-template-columns: 1fr auto; }
  .topbar-mid { grid-column: 1 / -1; }
  .search { max-width: none; }
  .pdp { grid-template-columns: 1fr; }
  .mobile-nav {
    display: grid; grid-template-columns: repeat(3, 1fr);
    position: fixed; bottom: 0; left: 0; right: 0;
    background: #fff; border-top: 1px solid var(--line);
    padding: 8px 4px 10px; font-size: 12px; text-align: center; z-index: 20;
  }
  body.is-logged-in .mobile-nav { grid-template-columns: repeat(4, 1fr); }
  .mobile-nav a[href="#/cart"] { color: var(--coral); font-weight: 700; }
  #app { padding-bottom: 96px; }
}
