:root {
  --red: #e31b4b;
  --red-dark: #c9153e;
  --red-soft: #fff0f4;
  --pink: #ff5a7d;
  --ink: #232631;
  --muted: #747b8c;
  --line: #edf0f5;
  --bg: #f6f7fb;
  --card: #ffffff;
  --green: #13a567;
  --orange: #ff9d2e;
  --shadow: 0 16px 40px rgba(24, 32, 52, .08);
  --radius: 18px;
}

/* ============================================================
   GLOBAL MODERN SLEEK SCROLLBAR (LIGHT & DARK THEME)
   ============================================================ */
html, body {
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.4) transparent;
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.35);
  border-radius: 999px;
  transition: background .2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.6);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--bg);
  font-family: "Plus Jakarta Sans", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.hidden { display: none !important; }

.market-header {
  position: sticky;
  top: 0;
  z-index: 30;
  color: #fff;
  background: linear-gradient(135deg, var(--red), #ff3c68 58%, #ff6a47);
  box-shadow: 0 10px 26px rgba(227, 27, 75, .22);
}
.top-strip {
  display: flex;
  justify-content: space-between;
  max-width: 1180px;
  margin: 0 auto;
  padding: 8px 22px 0;
  color: rgba(255,255,255,.78);
  font-size: 12px;
}
.bot-username { font-weight: 700; }
.header-main {
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  gap: 18px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 22px 18px;
}
.store-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 200px;
  text-decoration: none;
}
.brand-bag {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: var(--red);
  background: #fff;
  border-radius: 13px;
  box-shadow: 0 10px 24px rgba(136, 0, 37, .22);
  font-size: 22px;
}
.store-brand strong, .store-brand small { display: block; }
.store-brand strong { max-width: 180px; overflow: hidden; font-size: 19px; font-weight: 900; letter-spacing: -.5px; text-overflow: ellipsis; white-space: nowrap; }
.store-brand small { margin-top: 2px; color: rgba(255,255,255,.75); font-size: 9px; font-weight: 900; letter-spacing: 1.2px; }
.search-bar {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  height: 46px;
  padding: 0 5px 0 14px;
  background: #fff;
  border-radius: 999px;
  box-shadow: 0 14px 32px rgba(117, 0, 36, .18);
}
.search-bar svg { width: 19px; height: 19px; color: #9aa1ae; }
.search-bar input {
  min-width: 0;
  height: 100%;
  padding: 0 10px;
  color: var(--ink);
  background: transparent;
  border: 0;
  outline: 0;
  font-size: 14px;
}
.search-bar input::placeholder { color: #a3a8b4; }
.search-bar button, .header-action {
  height: 36px;
  border: 0;
  border-radius: 999px;
  font-weight: 850;
}
.search-bar button { padding: 0 18px; color: #fff; background: var(--red); }
.search-bar button:hover { background: var(--red-dark); }
.header-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 16px;
  color: #fff;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.24);
}
.header-action:hover { background: rgba(255,255,255,.26); }

main { max-width: 1180px; margin: 0 auto; padding: 26px 22px 90px; }
.hero-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  min-height: 260px;
  overflow: hidden;
  padding: 34px;
  background:
    radial-gradient(circle at 78% 20%, rgba(255,255,255,.38), transparent 26%),
    linear-gradient(135deg, #e31b4b, #ff5378 52%, #ff9a3d);
  border-radius: 28px;
  box-shadow: var(--shadow);
}
.hero-card::after {
  content: "";
  position: absolute;
  inset: auto -80px -160px auto;
  width: 330px;
  height: 330px;
  background: rgba(255,255,255,.18);
  border-radius: 50%;
}
.hero-copy { position: relative; z-index: 1; color: #fff; }
.hero-kicker {
  display: inline-flex;
  margin: 0 0 12px;
  padding: 7px 12px;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 850;
}
.hero-copy h1 { max-width: 640px; margin: 0; font-size: clamp(31px, 4vw, 48px); line-height: 1.05; letter-spacing: -1.6px; }
.hero-copy p:not(.hero-kicker) { max-width: 560px; margin: 14px 0 0; color: rgba(255,255,255,.84); line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.hero-actions button {
  height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 900;
}
#heroShopButton { color: var(--red); background: #fff; border: 0; }
#heroCategoryButton { color: #fff; background: transparent; border: 1px solid rgba(255,255,255,.45); }
.hero-visual { position: relative; z-index: 1; min-height: 210px; }
.promo-card { position: absolute; color: var(--ink); background: #fff; border-radius: 22px; box-shadow: 0 18px 34px rgba(95, 0, 28, .2); }
.promo-main { right: 24px; top: 18px; width: 235px; padding: 24px; }
.promo-main span { display: inline-flex; padding: 5px 10px; color: var(--red); background: var(--red-soft); border-radius: 999px; font-size: 12px; font-weight: 900; }
.promo-main strong { display: block; margin-top: 14px; font-size: 24px; line-height: 1.05; }
.promo-main small { display: block; margin-top: 8px; color: var(--muted); }
.promo-mini { display: grid; width: 74px; height: 74px; place-items: center; font-size: 30px; }
.promo-mini.one { left: 22px; bottom: 26px; transform: rotate(-8deg); }
.promo-mini.two { right: 4px; bottom: 18px; transform: rotate(10deg); }

.stats-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 18px 0; }
.stats-row article { padding: 18px; background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 8px 22px rgba(24,32,52,.04); }
.stats-row strong { display: block; color: var(--red); font-size: 25px; font-weight: 950; }
.stats-row span { color: var(--muted); font-size: 13px; }
.section-card, .filter-panel, .products-section { background: var(--card); border: 1px solid var(--line); box-shadow: 0 10px 26px rgba(24,32,52,.04); }
.section-card { margin-bottom: 18px; padding: 20px; border-radius: var(--radius); }
.section-head, .products-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.section-kicker { margin: 0 0 5px; color: var(--red); font-size: 11px; font-weight: 950; letter-spacing: .6px; text-transform: uppercase; }
h2 { margin: 0; color: var(--ink); font-size: 22px; letter-spacing: -.5px; }
.section-head button { height: 34px; padding: 0 13px; color: var(--red); background: var(--red-soft); border: 1px solid #ffd5df; border-radius: 999px; font-weight: 850; }
.category-chips { display: flex; gap: 10px; margin-top: 16px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.category-chips::-webkit-scrollbar { display: none; }
.category-chip {
  flex: 0 0 auto;
  min-width: 116px;
  padding: 13px 14px;
  text-align: left;
  color: #3a3e4a;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  transition: .16s;
}
.category-chip:hover, .category-chip.active { color: var(--red); border-color: #ffb6c8; background: var(--red-soft); }
.category-chip strong, .category-chip span { display: block; }
.category-chip strong { font-size: 13px; }
.category-chip span { margin-top: 3px; color: var(--muted); font-size: 11px; }

.content-grid { display: grid; grid-template-columns: 245px minmax(0, 1fr); gap: 18px; align-items: start; }
.filter-panel { position: sticky; top: 92px; padding: 18px; border-radius: var(--radius); }
.filter-title { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.filter-title span { display: grid; width: 29px; height: 29px; place-items: center; color: var(--red); background: var(--red-soft); border-radius: 9px; }
.filter-panel label { display: block; margin: 14px 0 7px; color: #555b6b; font-size: 13px; font-weight: 850; }
.filter-panel select { width: 100%; height: 42px; padding: 0 34px 0 12px; color: var(--ink); background-color: #fff; border: 1px solid #dde2eb; border-radius: 12px; outline: 0; font-size: 13px; font-weight: 600; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px 16px; -webkit-appearance: none; -moz-appearance: none; appearance: none; transition: border-color .15s ease, box-shadow .15s ease; }
.filter-panel select:focus { border-color: var(--red); box-shadow: 0 0 0 3px var(--red-soft); }
.filter-panel select option { background-color: #ffffff; color: #1e293b; padding: 8px; }
.check-line { display: flex !important; align-items: center; gap: 8px; font-weight: 750 !important; }
.check-line input { accent-color: var(--red); }
.products-section { padding: 20px; border-radius: var(--radius); }
.result-count { display: inline-flex; padding: 7px 11px; color: var(--red); background: var(--red-soft); border-radius: 999px; font-size: 12px; font-weight: 900; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 18px; }
.product-card { overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 18px; transition: .18s; }
.product-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(24,32,52,.1); border-color: #ffd1dc; }
.product-media {
  position: relative;
  aspect-ratio: 1 / .78;
  overflow: hidden;
  background: linear-gradient(135deg, #fff0f4, #fff7e8);
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.product-card:hover .product-media img {
  transform: scale(1.04);
}
.image-fallback { display: grid; width: 100%; height: 100%; place-items: center; color: var(--red); font-size: 44px; font-weight: 950; }
.product-badge { position: absolute; top: 10px; left: 10px; padding: 5px 8px; color: #fff; background: var(--red); border-radius: 999px; font-size: 10px; font-weight: 900; }
.product-body { padding: 13px; }
.product-name { display: -webkit-box; min-height: 40px; overflow: hidden; margin: 0; color: #2c303a; font-size: 14px; line-height: 1.35; font-weight: 850; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.product-price { display: block; margin-top: 0; color: var(--red); font-size: 16px; font-weight: 950; }
.product-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 6px;
  min-height: 24px;
}
.product-meta-tags {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.product-stock-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 800;
  line-height: 1.2;
}
.product-stock-tag.in-stock { color: #0284c7; background: #e0f2fe; }
.product-stock-tag.ready { color: #059669; background: #d1fae5; }
.product-stock-tag.out { color: #dc2626; background: #fee2e2; }

.product-sold-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  color: #64748b;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 750;
  line-height: 1.2;
}

.header-track-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  font-weight: 800;
  font-size: 12px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.header-track-btn:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.32);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}
.header-track-btn svg {
  width: 15px;
  height: 15px;
}

.product-card.is-out-of-stock .product-media img {
  filter: grayscale(0.45);
  opacity: 0.8;
}
.product-badge.out-of-stock {
  background: #ef4444 !important;
}
.product-badge.auto-qris-badge {
  background: #0284c7 !important;
}

.detail-badge-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.detail-badge.badge-stock {
  color: #0284c7;
  background: #e0f2fe;
}
.detail-badge.badge-out {
  color: #dc2626;
  background: #fee2e2;
}
.detail-badge.badge-sold {
  color: #475569;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.product-desc {
  display: -webkit-box;
  min-height: 36px;
  max-height: 36px;
  overflow: hidden;
  margin: 7px 0 12px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  cursor: pointer;
}
.product-desc:hover {
  color: var(--ink);
}
.product-name {
  cursor: pointer;
}
.product-name:hover {
  color: var(--red);
}

.product-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.product-actions button,
.product-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 38px;
  padding: 0 8px;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  transition: all .18s ease;
  white-space: nowrap;
}
.detail-button {
  color: #334155;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}
.detail-button:hover {
  color: var(--red);
  background: var(--red-soft);
  border-color: #ffd4df;
  transform: translateY(-1px);
}
.card-order {
  padding: 0 10px;
  color: #fff;
  background: var(--green);
  border: 0;
  box-shadow: 0 4px 12px rgba(19, 165, 103, .22);
}
.card-order:hover:not(.disabled) {
  background: #0f925b;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(19, 165, 103, .3);
}
.card-order.auto-qris-btn {
  background: #0284c7;
  box-shadow: 0 4px 12px rgba(2, 132, 199, .25);
}
.card-order.auto-qris-btn:hover {
  background: #0369a1;
  box-shadow: 0 6px 16px rgba(2, 132, 199, .35);
}
.card-order.disabled,
.card-order.out-btn {
  background: #fee2e2 !important;
  color: #dc2626 !important;
  border: 1px solid #fca5a5 !important;
  box-shadow: none !important;
  cursor: not-allowed;
  opacity: 0.9 !important;
}

.skeleton-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 18px; }
.skeleton-grid span { height: 245px; border-radius: 18px; background: linear-gradient(90deg, #eef1f6, #fafbfe, #eef1f6); background-size: 220% 100%; animation: shimmer 1.2s infinite; }
@keyframes shimmer { to { background-position: -220% 0; } }
.empty-state { display: grid; place-items: center; min-height: 260px; padding: 30px; text-align: center; }
.empty-state span { font-size: 42px; }
.empty-state strong { margin-top: 8px; }
.empty-state p { color: var(--muted); }

.modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 16px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 15, 29, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.detail-sheet {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  width: min(860px, 100%);
  max-height: min(620px, calc(100vh - 36px));
  height: 580px;
  background: #ffffff;
  border-radius: 24px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 10;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.65);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.2s ease;
  backdrop-filter: blur(4px);
}

.modal-close:hover {
  background: #ef4444;
  color: #ffffff;
  transform: rotate(90deg);
}

/* Kolom Kiri: Foto Produk Full Cover & Center */
.detail-image-wrap {
  position: relative;
  height: 100%;
  width: 100%;
  background: #080d18;
  overflow: hidden;
  display: block;
  padding: 0;
  border-right: 1px solid #1e293b;
}

.detail-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  border-radius: 0;
  box-shadow: none;
  transition: transform 0.3s ease;
}

.detail-image-wrap:hover img {
  transform: scale(1.04);
}

.detail-image-fallback {
  width: 100%;
  height: 100%;
  font-size: 64px;
  display: grid;
  place-items: center;
  background: #111728;
}

/* Kolom Kanan: Flexbox dengan Scrollable Body & Pinned Footer */
.detail-body {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  background: #ffffff;
}

.detail-content-scroll {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 24px 24px 14px;
  min-height: 0;
}

.detail-badges-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.detail-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.detail-badge.badge-cat {
  background: rgba(227, 27, 75, 0.1);
  color: #e31b4b;
}

.detail-badge.badge-stock {
  background: rgba(2, 132, 199, 0.1);
  color: #0284c7;
}

.detail-badge.badge-out {
  background: rgba(220, 38, 38, 0.12);
  color: #dc2626;
}

.detail-body h2 {
  font-size: 22px;
  font-weight: 850;
  color: #0f172a;
  margin: 0 0 6px;
  line-height: 1.3;
}

.detail-price-box {
  margin-bottom: 14px;
}

.detail-price {
  font-size: 22px;
  font-weight: 900;
  color: #e31b4b;
  letter-spacing: -0.5px;
}

.detail-desc-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 14px 16px;
}

.detail-desc-title {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  margin-bottom: 8px;
}

.detail-description {
  margin: 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.65;
  white-space: pre-wrap;
  word-break: break-word;
}

/* Bottom Action Bar (Selalu Tampil Pas di Bawah Modal) */
.detail-actions {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px 18px;
  background: #ffffff;
  border-top: 1px solid #f1f5f9;
}

.detail-direct-order {
  flex: 1 1 auto;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 44px;
  padding: 0 14px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 850;
  color: #ffffff;
  background: linear-gradient(135deg, #10b981, #059669);
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.28);
  transition: all 0.2s ease;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.detail-direct-order:hover {
  background: linear-gradient(135deg, #059669, #047857);
  box-shadow: 0 8px 22px rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

.detail-direct-order.qris-mode {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.35);
}

.detail-direct-order.qris-mode:hover {
  background: linear-gradient(135deg, #0369a1, #075985);
  box-shadow: 0 8px 22px rgba(2, 132, 199, 0.5);
}

.detail-cart-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 12px;
  color: #0284c7;
  background: rgba(2, 132, 199, 0.1);
  border: 1px solid rgba(2, 132, 199, 0.25);
  cursor: pointer;
  transition: all 0.2s ease;
}

.detail-cart-icon svg {
  width: 20px;
  height: 20px;
}

.detail-cart-icon:hover {
  background: rgba(2, 132, 199, 0.2);
  border-color: #0284c7;
  transform: translateY(-1px);
}

.secondary-detail {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 14px;
  border-radius: 12px;
  font-size: 12.5px;
  font-weight: 750;
  color: #64748b;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.secondary-detail:hover {
  background: #e2e8f0;
  color: #1e293b;
}

.mobile-nav { display: none; }

@media (max-width: 960px) {
  .header-main { grid-template-columns: 1fr; gap: 12px; }
  .store-brand { min-width: 0; }
  .header-action { display: none; }
  .hero-card { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .content-grid { grid-template-columns: 1fr; }
  .filter-panel { position: static; }
  .product-grid, .skeleton-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .top-strip { display: none; }
  .header-main { padding: 12px 14px 15px; }
  .search-bar { height: 43px; }
  .search-bar button { display: none; }
  main { padding: 16px 12px 84px; }
  .hero-card { padding: 24px 20px; border-radius: 22px; }
  .hero-copy h1 { font-size: 30px; }
  .hero-copy p:not(.hero-kicker) { font-size: 13px; }
  .stats-row { grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
  .stats-row article { padding: 12px; }
  .stats-row strong { font-size: 20px; }
  .stats-row span { font-size: 11px; }
  .section-card, .products-section, .filter-panel { padding: 15px; border-radius: 16px; }
  h2 { font-size: 18px; }
  .product-grid, .skeleton-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .product-body { padding: 10px; }
  .product-name { min-height: 38px; font-size: 13px; }
  .product-price { font-size: 14px; }
  .product-desc { display: none; }
  .product-actions { grid-template-columns: 1fr; }
  .card-order { display: none !important; }
  .detail-sheet { grid-template-columns: 1fr; max-height: calc(100vh - 28px); border-radius: 22px; }
  .detail-image-wrap { min-height: 280px; max-height: 42vh; }
  .detail-body { padding: 22px; }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 40; display: grid; grid-template-columns: repeat(4, 1fr); padding: 7px 8px calc(7px + env(safe-area-inset-bottom)); background: rgba(255,255,255,.95); border-top: 1px solid var(--line); backdrop-filter: blur(12px); }
  .mobile-nav button { display: grid; gap: 2px; place-items: center; color: #656d7d; background: transparent; border: 0; font-size: 10px; font-weight: 850; }
  .mobile-nav span { font-size: 18px; }
}
@media (max-width: 390px) {
  .product-grid, .skeleton-grid { grid-template-columns: 1fr; }
}

/* === Responsive polish: tablet & mobile storefront === */
@media (max-width: 1120px) {
  .header-main,
  .top-strip,
  main { max-width: 100%; }
  .hero-card { grid-template-columns: minmax(0, 1fr) 280px; padding: 30px; }
  .promo-main { right: 0; width: 215px; }
  .product-grid, .skeleton-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .market-header { position: sticky; }
  .header-main {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    padding: 13px 18px 16px;
  }
  .store-brand { min-width: 0; }
  .store-brand strong { max-width: 46vw; }
  .search-bar { grid-column: 1 / -1; order: 3; }
  .header-action { display: inline-flex; height: 38px; padding: 0 13px; }
  .hero-card { grid-template-columns: 1fr; min-height: auto; }
  .hero-visual { display: none; }
  .content-grid { grid-template-columns: 1fr; }
  .filter-panel {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
  }
  .filter-title { grid-column: 1 / -1; margin-bottom: 2px; }
  .filter-panel label { margin: 0 0 6px; }
  .filter-panel label:not(.check-line) { align-self: end; }
  .filter-panel select { height: 42px; }
  .check-line { grid-column: 1 / -1; min-height: 38px; margin: 2px 0 0 !important; padding: 0 12px; background: #fff7fa; border: 1px solid #ffd6df; border-radius: 12px; }
  .product-grid, .skeleton-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  body { background: #f7f8fc; }
  .market-header { border-radius: 0 0 18px 18px; }
  .header-main { padding: 11px 12px 14px; }
  .brand-bag { width: 38px; height: 38px; border-radius: 12px; font-size: 20px; }
  .store-brand { gap: 8px; }
  .store-brand strong { max-width: 58vw; font-size: 16px; }
  .store-brand small { font-size: 8px; }
  .header-action { display: none; }
  .search-bar {
    height: 44px;
    grid-template-columns: 21px 1fr;
    padding: 0 13px;
    border-radius: 14px;
  }
  .search-bar button { display: none; }
  main { padding: 14px 12px 96px; }
  .hero-card {
    padding: 23px 18px;
    border-radius: 22px;
    box-shadow: 0 14px 30px rgba(227, 27, 75, .16);
  }
  .hero-kicker { font-size: 11px; padding: 6px 10px; }
  .hero-copy h1 { font-size: clamp(26px, 8vw, 34px); letter-spacing: -1px; }
  .hero-copy p:not(.hero-kicker) { font-size: 13px; line-height: 1.55; }
  .hero-actions { margin-top: 18px; }
  .hero-actions button { flex: 1 1 135px; height: 40px; padding: 0 12px; font-size: 13px; }
  .stats-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 12px 0; }
  .stats-row article { padding: 12px 8px; border-radius: 15px; text-align: center; }
  .stats-row strong { font-size: 19px; }
  .stats-row span { font-size: 10.5px; }
  .section-card,
  .filter-panel,
  .products-section { padding: 14px; border-radius: 16px; }
  .section-head,
  .products-head { align-items: flex-start; }
  .section-head button { height: 32px; padding: 0 10px; font-size: 11px; white-space: nowrap; }
  h2 { font-size: 18px; }
  .category-chips { gap: 8px; margin: 13px -2px 0; padding: 0 2px 2px; }
  .category-chip { min-width: 106px; padding: 11px 12px; border-radius: 14px; }
  .category-chip strong { font-size: 12px; }
  .category-chip span { font-size: 10px; }
  .filter-panel { grid-template-columns: 1fr 1fr; }
  .filter-title { font-size: 14px; }
  .filter-panel label { font-size: 11.5px; }
  .filter-panel select { height: 39px; border-radius: 11px; font-size: 12px; }
  .products-head { gap: 10px; }
  .result-count { padding: 6px 9px; font-size: 11px; white-space: nowrap; }
  .product-grid, .skeleton-grid { gap: 10px; margin-top: 14px; }
  .product-card { border-radius: 15px; }
  .product-card:hover { transform: none; box-shadow: 0 10px 24px rgba(24,32,52,.08); }
  .product-media { aspect-ratio: 1 / .86; }
  .product-badge { top: 7px; left: 7px; padding: 4px 7px; font-size: 9px; }
  .product-body { padding: 10px; }
  .product-name { min-height: 36px; font-size: 12.5px; line-height: 1.35; }
  .product-price { margin-top: 6px; font-size: 14px; }
  .product-desc { display: none; }
  .product-actions { grid-template-columns: 1fr; margin-top: 9px; }
  .product-actions button, .product-actions a { height: 34px; border-radius: 10px; font-size: 11.5px; }
  .card-order { display: none !important; }
  .skeleton-grid span { height: 205px; }
  .mobile-nav { box-shadow: 0 -10px 30px rgba(25, 30, 45, .08); }
}

@media (max-width: 520px) {
  .product-grid, .skeleton-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filter-panel { grid-template-columns: 1fr; }
  .check-line { grid-column: auto; }
  .detail-sheet {
    align-self: end;
    width: 100%;
    height: auto;
    max-height: 88vh;
    border-radius: 24px 24px 0 0;
    grid-template-columns: 1fr;
  }
  .detail-image-wrap {
    height: 180px;
    min-height: 180px;
    padding: 14px;
    border-right: none;
    border-bottom: 1px solid #1e293b;
  }
  .detail-content-scroll {
    padding: 16px 16px 10px;
  }
  .detail-actions {
    padding: 12px 16px calc(14px + env(safe-area-inset-bottom));
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  .detail-direct-order {
    width: 100%;
    height: 42px;
  }
  .detail-cart-icon, .secondary-detail {
    flex: 1 1 40%;
    height: 40px;
    padding: 0 10px;
    font-size: 12px;
  }
}

@media (max-width: 380px) {
  main { padding-left: 10px; padding-right: 10px; }
  .product-grid, .skeleton-grid { grid-template-columns: 1fr; }
  .product-media { aspect-ratio: 1 / .72; }
  .product-actions { grid-template-columns: 1fr auto; }
  .card-order { display: inline-flex !important; }
}


/* Tombol keranjang dibuat lebih jelas */
.product-actions { grid-template-columns: minmax(0, 1fr) minmax(92px, auto); }
.card-order {
  gap: 5px;
  min-width: 92px;
  padding: 0 12px;
  box-shadow: 0 8px 18px rgba(19, 165, 103, .18);
  white-space: nowrap;
}
.card-order:hover:not(.disabled) {
  background: #0f925b;
  transform: translateY(-1px);
}

@media (max-width: 720px) {
  .product-actions { grid-template-columns: 1fr; }
  .card-order {
    display: inline-flex !important;
    width: 100%;
    min-width: 0;
    height: 34px;
  }
}

@media (max-width: 380px) {
  .product-actions { grid-template-columns: 1fr; }
}


/* Logo toko dari admin panel */
.brand-bag { overflow: hidden; }
.store-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
#storeLogoFallback { display: grid; width: 100%; height: 100%; place-items: center; }

/* === Keranjang mengambang kiri bawah === */
.cart-widget {
  position: fixed;
  left: 22px;
  bottom: 22px;
  z-index: 65;
  display: grid;
  gap: 10px;
  justify-items: start;
}
.cart-float {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 174px;
  min-height: 56px;
  padding: 8px 16px 8px 10px;
  color: #fff;
  background: linear-gradient(135deg, #13a567, #0d8f59);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 18px 38px rgba(19, 165, 103, .32);
  text-align: left;
}
.cart-float-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  background: rgba(255,255,255,.18);
  border-radius: 50%;
  font-size: 21px;
}
.cart-float strong, .cart-float small { display: block; line-height: 1.1; }
.cart-float strong { font-size: 13px; font-weight: 950; }
.cart-float small { margin-top: 3px; color: rgba(255,255,255,.82); font-size: 11px; font-weight: 750; }
.cart-float em {
  position: absolute;
  top: -6px;
  right: -4px;
  min-width: 23px;
  height: 23px;
  padding: 0 6px;
  display: grid;
  place-items: center;
  color: var(--red);
  background: #fff;
  border: 2px solid #10a161;
  border-radius: 999px;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
}
.cart-pulse { animation: cartPulse .42s ease; }
@keyframes cartPulse {
  0% { transform: scale(1); }
  45% { transform: scale(1.06); }
  100% { transform: scale(1); }
}
.cart-panel {
  width: min(380px, calc(100vw - 24px));
  max-height: min(620px, calc(100vh - 110px));
  overflow: hidden;
  background: #fff;
  border: 1px solid #dfe6ee;
  border-radius: 22px;
  box-shadow: 0 26px 80px rgba(24,32,52,.23);
}
.cart-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 13px;
  border-bottom: 1px solid var(--line);
}
.cart-panel-head strong, .cart-panel-head small { display: block; }
.cart-panel-head strong { font-size: 16px; }
.cart-panel-head small { margin-top: 3px; color: var(--muted); font-size: 12px; }
.cart-panel-head button {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  color: #687182;
  background: #f4f6fa;
  border: 0;
  border-radius: 50%;
  font-size: 22px;
}
.cart-items {
  display: grid;
  gap: 10px;
  max-height: min(360px, calc(100vh - 330px));
  overflow-y: auto;
  padding: 13px;
}
.cart-item {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 9px;
  background: #fbfcff;
  border: 1px solid var(--line);
  border-radius: 16px;
}
.cart-item-media {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  overflow: hidden;
  color: var(--red);
  background: linear-gradient(135deg, #fff0f4, #fff7e8);
  border-radius: 13px;
  font-size: 24px;
  font-weight: 950;
}
.cart-item-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cart-item-body { min-width: 0; }
.cart-item-body strong {
  display: block;
  overflow: hidden;
  color: #2d3340;
  font-size: 12.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cart-item-body small { display: block; margin-top: 3px; color: var(--red); font-size: 11px; font-weight: 850; }
.cart-qty { display: inline-flex; align-items: center; gap: 4px; margin-top: 7px; background: #fff; border: 1px solid #e0e6ef; border-radius: 999px; }
.cart-qty button {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  color: var(--red);
  background: transparent;
  border: 0;
  font-size: 16px;
  font-weight: 950;
}
.cart-qty span { min-width: 22px; text-align: center; font-size: 12px; font-weight: 900; }
.cart-item-side { display: grid; gap: 8px; justify-items: end; }
.cart-item-side strong { color: #303744; font-size: 12px; white-space: nowrap; }
.cart-item-side button { color: var(--red); background: transparent; border: 0; font-size: 10.5px; font-weight: 850; }
.cart-empty { display: grid; place-items: center; padding: 32px 22px; text-align: center; }
.cart-empty span { font-size: 38px; }
.cart-empty strong { margin-top: 8px; }
.cart-empty p { margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.cart-footer { padding: 13px; border-top: 1px solid var(--line); }
.cart-total-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 11px; }
.cart-total-row span { color: var(--muted); font-size: 12px; font-weight: 750; }
.cart-total-row strong { color: var(--red); font-size: 17px; }
.cart-footer-actions { display: grid; grid-template-columns: .7fr 1.3fr; gap: 8px; }
.cart-clear, .cart-checkout { height: 39px; border-radius: 12px; font-size: 12px; font-weight: 950; }
.cart-clear { color: #687182; background: #f3f5f8; border: 1px solid #e2e7ee; }
.cart-checkout { color: #fff; background: var(--green); border: 0; }
.cart-clear:disabled, .cart-checkout:disabled { cursor: not-allowed; opacity: .55; }
.card-order { border: 0; }
.order-button { border: 0; }

@media (max-width: 720px) {
  .cart-widget { left: 12px; right: 12px; bottom: calc(74px + env(safe-area-inset-bottom)); }
  .cart-float { min-width: 158px; min-height: 50px; padding: 7px 14px 7px 8px; }
  .cart-float-icon { width: 36px; height: 36px; font-size: 19px; }
  .cart-panel { width: 100%; max-height: calc(100vh - 120px); border-radius: 20px; }
  .cart-items { max-height: calc(100vh - 360px); }
}
@media (max-width: 430px) {
  .cart-item { grid-template-columns: 52px minmax(0, 1fr); }
  .cart-item-media { width: 52px; height: 52px; }
  .cart-item-side { grid-column: 2; grid-template-columns: 1fr auto; width: 100%; align-items: center; }
  .cart-footer-actions { grid-template-columns: 1fr; }
}


/* Keranjang dipindah ke kanan bawah dan tidak dibuka otomatis saat klik Pesan */
.cart-widget {
  left: auto;
  right: 22px;
  justify-items: end;
}
@media (max-width: 720px) {
  .cart-widget {
    left: 12px;
    right: 12px;
    justify-items: end;
  }
}


/* Tombol keranjang di modal detail: ikon saja */
.detail-cart-icon {
  width: 52px;
  min-width: 52px;
  padding: 0;
  font-size: 22px;
  line-height: 1;
}
.detail-cart-icon:hover:not(:disabled) {
  background: #0f925b;
  transform: translateY(-1px);
}
@media (max-width: 520px) {
  .detail-actions { grid-template-columns: 56px 1fr; }
  .detail-cart-icon {
    width: 52px !important;
    min-width: 52px;
  }
  .secondary-detail { width: 100%; }
}


/* Tombol pesan langsung di modal detail */
.detail-direct-order {
  min-width: 154px;
  background: var(--green);
}
.detail-direct-order:hover {
  background: #0f925b;
  transform: translateY(-1px);
}
@media (max-width: 520px) {
  .detail-actions {
    display: grid;
    grid-template-columns: 56px 1fr;
  }
  .detail-direct-order {
    grid-column: 1 / -1;
    width: 100%;
  }
  .detail-cart-icon { grid-column: 1; }
  .secondary-detail { grid-column: 2; }
}


/* === Ikon SVG marketplace/e-commerce === */
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.eco-icon {
  width: 1.15em;
  height: 1.15em;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  display: inline-block;
  vertical-align: -0.17em;
}
.brand-bag .eco-icon { width: 24px; height: 24px; stroke-width: 2.2; }
.header-action .eco-icon { width: 17px; height: 17px; }
.promo-mini .eco-icon { width: 34px; height: 34px; stroke-width: 1.85; }
.filter-title span .eco-icon { width: 16px; height: 16px; }
.empty-state > span { display: grid; width: 48px; height: 48px; place-items: center; color: var(--red); background: var(--red-soft); border-radius: 50%; }
.empty-state > span .eco-icon { width: 26px; height: 26px; }
.mobile-nav span { display: grid; width: 22px; height: 22px; place-items: center; font-size: 0; }
.mobile-nav span .eco-icon { width: 20px; height: 20px; }
.cart-float-icon .eco-icon { width: 22px; height: 22px; stroke-width: 2.1; }
.cart-empty > span { display: grid; width: 52px; height: 52px; place-items: center; color: var(--green); background: #edfff6; border-radius: 50%; }
.cart-empty > span .eco-icon { width: 28px; height: 28px; }
.card-order .eco-icon, .detail-direct-order .eco-icon { width: 16px; height: 16px; }
.detail-cart-icon .eco-icon { width: 23px; height: 23px; }

/* === Redesign pop-up keranjang: marketplace checkout sheet === */
.cart-panel {
  width: min(420px, calc(100vw - 24px));
  overflow: hidden;
  background: linear-gradient(180deg, #fff 0%, #fff 62%, #fff8fa 100%);
  border: 0;
  border-radius: 26px;
  box-shadow: 0 28px 90px rgba(20, 28, 45, .28);
  animation: cartPanelIn .18s ease-out;
}
@keyframes cartPanelIn {
  from { opacity: 0; transform: translateY(10px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.cart-panel-head {
  padding: 18px 18px 16px;
  color: #fff;
  background: linear-gradient(135deg, var(--red), #ff4d72 72%, #ff865b);
  border-bottom: 0;
}
.cart-panel-head strong { color: #fff; font-size: 17px; letter-spacing: -.25px; }
.cart-panel-head small { color: rgba(255,255,255,.82); font-weight: 700; }
.cart-panel-head button {
  color: #fff;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.22);
}
.cart-panel-head button:hover { background: rgba(255,255,255,.28); }
.cart-items {
  gap: 11px;
  padding: 14px;
  background: #f8f9fd;
}
.cart-items::-webkit-scrollbar { width: 7px; }
.cart-items::-webkit-scrollbar-thumb { background: #d7dce7; border-radius: 999px; }
.cart-item {
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 11px;
  align-items: start;
  padding: 11px;
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 18px;
  box-shadow: 0 8px 22px rgba(25, 32, 46, .045);
}
.cart-item-media {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.5);
}
.cart-item-body strong { font-size: 13px; line-height: 1.35; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.cart-item-body small { margin-top: 4px; font-size: 12px; }
.cart-qty {
  margin-top: 10px;
  overflow: hidden;
  border: 1px solid #ffd4df;
  background: var(--red-soft);
}
.cart-qty button { color: var(--red); background: #fff; }
.cart-qty button:hover { background: #ffe4eb; }
.cart-qty span { color: var(--red); }
.cart-item-side {
  grid-column: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding-top: 8px;
  border-top: 1px dashed #edf0f5;
}
.cart-item-side strong { font-size: 13px; color: #1f2530; }
.cart-item-side button {
  height: 27px;
  padding: 0 10px;
  color: #e31b4b;
  background: #fff2f6;
  border: 1px solid #ffd6df;
  border-radius: 999px;
}
.cart-empty { background: #f8f9fd; }
.cart-footer {
  padding: 14px;
  background: #fff;
  border-top: 1px solid #eef1f6;
  box-shadow: 0 -10px 24px rgba(25,32,46,.04);
}
.cart-total-row {
  margin-bottom: 12px;
  padding: 12px 13px;
  background: linear-gradient(135deg, #fff5f8, #fff);
  border: 1px solid #ffe0e8;
  border-radius: 16px;
}
.cart-total-row span { color: #8b5364; font-size: 12px; }
.cart-total-row strong { color: var(--red); font-size: 19px; }
.cart-footer-actions { grid-template-columns: .78fr 1.22fr; }
.cart-clear, .cart-checkout {
  height: 43px;
  border-radius: 14px;
  font-size: 12.5px;
}
.cart-clear { background: #fff; border: 1px solid #dfe5ee; }
.cart-checkout {
  background: linear-gradient(135deg, #12a362, #0f8d57);
  box-shadow: 0 12px 24px rgba(19,165,103,.22);
}
.cart-checkout:hover:not(:disabled) { background: linear-gradient(135deg, #0f965b, #0d7e50); transform: translateY(-1px); }

@media (max-width: 720px) {
  .cart-widget { bottom: calc(72px + env(safe-area-inset-bottom)); }
  .cart-panel {
    width: 100%;
    max-height: min(78vh, 680px);
    border-radius: 24px 24px 18px 18px;
  }
  .cart-panel-head::before {
    content: "";
    position: absolute;
  }
  .cart-items { max-height: calc(78vh - 230px); }
}
@media (max-width: 430px) {
  .cart-panel {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    max-height: 82vh;
    border-radius: 24px 24px 0 0;
  }
  .cart-panel-head { padding-top: 22px; }
  .cart-panel-head::before {
    content: "";
    position: absolute;
    top: 8px;
    left: 50%;
    width: 46px;
    height: 4px;
    background: rgba(255,255,255,.55);
    border-radius: 999px;
    transform: translateX(-50%);
  }
  .cart-items { max-height: calc(82vh - 250px); }
  .cart-item { grid-template-columns: 58px minmax(0, 1fr); }
  .cart-item-media { width: 58px; height: 58px; }
  .cart-footer { padding-bottom: calc(14px + env(safe-area-inset-bottom)); }
}
.cart-panel-head { position: relative; }


/* Tombol silang: ikon lebih premium dan touch-friendly */
.close-icon {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.15;
  stroke-linecap: round;
}
#cartClose,
.modal-close {
  display: grid;
  place-items: center;
  transition: transform .16s ease, background .16s ease, color .16s ease, box-shadow .16s ease;
}
#cartClose {
  width: 34px;
  height: 34px;
  color: #fff;
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.28);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.16);
}
#cartClose:hover {
  color: #fff;
  background: rgba(255,255,255,.28);
  transform: rotate(90deg) scale(1.04);
}
.modal-close {
  width: 38px;
  height: 38px;
  color: #4b5566;
  background: rgba(255,255,255,.94);
  border: 1px solid rgba(214,222,233,.95);
  box-shadow: 0 10px 28px rgba(21,31,48,.16);
  font-size: 0;
}
.modal-close:hover {
  color: var(--red);
  background: #fff3f6;
  border-color: #ffd2dc;
  transform: rotate(90deg) scale(1.04);
}
@media (max-width: 520px) {
  .modal-close { width: 36px; height: 36px; }
  #cartClose { width: 33px; height: 33px; }
}

/* Infinite scroll produk */
.load-more-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  margin: 18px 0 4px;
  padding: 13px;
  color: #7b5363;
  background: #fff7fa;
  border: 1px solid #ffe0e8;
  border-radius: 16px;
  font-size: 13px;
  font-weight: 850;
}
.load-more-state span {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(227, 27, 75, .18);
  border-top-color: var(--red);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

/* ============================================================
   ESTHETIC & ELEGANT DARK THEME — TOKO NOTNOT STOREFRONT
   ============================================================ */

/* Theme Toggle Button */
.theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 50%;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}
.theme-toggle-btn:hover {
  transform: rotate(15deg) scale(1.08);
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

[data-theme="dark"] {
  --bg: #090d16;
  --card: #111728;
  --card-elevated: #162035;
  --ink: #f1f5f9;
  --muted: #94a3b8;
  --line: #1e293b;
  --line-dark: #29384e;
  --red: #ff2d55;
  --red-dark: #e01e45;
  --red-soft: rgba(255, 45, 85, 0.16);
  --green: #10b981;
  --green-soft: rgba(16, 185, 129, 0.16);
  --shadow: 0 20px 48px rgba(0, 0, 0, 0.6);
}

[data-theme="dark"] body {
  background-color: var(--bg);
  color: var(--ink);
}

/* Header */
[data-theme="dark"] .market-header {
  background: rgba(12, 17, 29, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .brand-bag {
  background: #182238;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ff3366;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .search-bar {
  background: #141c2e;
  border: 1px solid #25334d;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .search-bar input {
  color: #f8fafc;
}

[data-theme="dark"] .search-bar input::placeholder {
  color: #64748b;
}

[data-theme="dark"] .search-bar svg {
  color: #64748b;
}

[data-theme="dark"] .header-action {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
}

[data-theme="dark"] .header-action:hover {
  background: rgba(255, 255, 255, 0.14);
}

/* Hero Section */
[data-theme="dark"] .hero-card {
  background:
    radial-gradient(circle at 80% 20%, rgba(255, 45, 85, 0.24), transparent 40%),
    radial-gradient(circle at 20% 80%, rgba(99, 102, 241, 0.16), transparent 42%),
    linear-gradient(135deg, #131124 0%, #1e1124 50%, #0e1526 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
}

[data-theme="dark"] .hero-card::after {
  background: rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .hero-kicker {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: #f8fafc;
}

[data-theme="dark"] #heroShopButton {
  background: linear-gradient(135deg, #ff2d55, #ff5e7e);
  color: #fff;
  box-shadow: 0 8px 24px rgba(255, 45, 85, 0.4);
}

[data-theme="dark"] #heroCategoryButton {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  color: #f8fafc;
}

[data-theme="dark"] #heroCategoryButton:hover {
  background: rgba(255, 255, 255, 0.15);
}

[data-theme="dark"] .promo-card {
  background: #141c2e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #f1f5f9;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.55);
}

[data-theme="dark"] .promo-main span {
  background: rgba(255, 45, 85, 0.2);
  color: #ff476e;
}

/* Stats */
[data-theme="dark"] .stats-row article {
  background: #111728;
  border-color: #1e293b;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .stats-row strong {
  color: #ff3366;
}

[data-theme="dark"] .stats-row span {
  color: #94a3b8;
}

/* Categories & Sections */
[data-theme="dark"] .section-card,
[data-theme="dark"] .filter-panel,
[data-theme="dark"] .products-section {
  background: #111728;
  border-color: #1e293b;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] h2 {
  color: #f1f5f9;
}

[data-theme="dark"] .section-head button {
  background: rgba(255, 45, 85, 0.14);
  border-color: rgba(255, 45, 85, 0.26);
  color: #ff476e;
}

[data-theme="dark"] .category-chip {
  background: #151d30;
  border-color: #222f46;
  color: #cbd5e1;
}

[data-theme="dark"] .category-chip:hover {
  background: #1b263e;
  border-color: #334360;
  color: #fff;
}

[data-theme="dark"] .category-chip.active {
  background: linear-gradient(135deg, #ff2d55, #e01e45);
  border-color: #ff2d55;
  color: #fff;
  box-shadow: 0 8px 22px rgba(255, 45, 85, 0.38);
}

/* Filter controls Dark */
[data-theme="dark"] .filter-panel {
  background: #111728;
  border-color: #1e293b;
}

[data-theme="dark"] .filter-panel label {
  color: #94a3b8;
}

[data-theme="dark"] .filter-panel select {
  background-color: #162035;
  border-color: #273752;
  color: #f8fafc;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
}

[data-theme="dark"] .filter-panel select:focus {
  border-color: #ff2d55;
  box-shadow: 0 0 0 3px rgba(255, 45, 85, 0.22);
}

[data-theme="dark"] .filter-panel select option {
  background-color: #111728;
  color: #f8fafc;
}

[data-theme="dark"] .check-line {
  color: #cbd5e1;
}

/* Products Dark */
[data-theme="dark"] .product-card {
  background: #111728;
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .product-card:hover {
  background: #151d32;
  border-color: rgba(255, 45, 85, 0.4);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55), 0 0 24px rgba(255, 45, 85, 0.1);
}

[data-theme="dark"] .product-media {
  background: #162035;
}

[data-theme="dark"] .product-title,
[data-theme="dark"] .product-name {
  color: #f1f5f9;
}

[data-theme="dark"] .product-desc {
  color: #94a3b8;
}

[data-theme="dark"] .product-price {
  color: #ff476e;
}

[data-theme="dark"] .detail-button {
  color: #e2e8f0;
  background: #182238;
  border: 1px solid #283954;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

[data-theme="dark"] .detail-button:hover {
  color: #fff;
  background: #22304c;
  border-color: #3e557c;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  transform: translateY(-1px);
}

[data-theme="dark"] .card-order {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #fff;
  border: 0;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3);
}

[data-theme="dark"] .card-order:hover:not(.disabled) {
  background: linear-gradient(135deg, #059669, #047857);
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.45);
  transform: translateY(-1px);
}

[data-theme="dark"] .card-order.auto-qris-btn {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #fff;
  border: 0;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35);
}

[data-theme="dark"] .card-order.auto-qris-btn:hover {
  background: linear-gradient(135deg, #0369a1, #075985);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.5);
  transform: translateY(-1px);
}

[data-theme="dark"] .card-order.disabled,
[data-theme="dark"] .card-order.out-btn {
  background: rgba(239, 68, 68, 0.12) !important;
  color: #fca5a5 !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
  box-shadow: none !important;
  opacity: 0.95 !important;
  cursor: not-allowed;
}

[data-theme="dark"] .secondary-detail {
  color: #e2e8f0;
  background: #182238;
  border: 1px solid #283954;
}

[data-theme="dark"] .secondary-detail:hover {
  color: #fff;
  background: #22304c;
  border-color: #3e557c;
}

/* Empty & Load More */
[data-theme="dark"] .empty-card,
[data-theme="dark"] .load-more-state {
  background: #111728;
  border-color: #1e293b;
  color: #94a3b8;
}

[data-theme="dark"] .empty-icon {
  background: #162035;
  color: #ff3366;
}

[data-theme="dark"] .skeleton-card,
[data-theme="dark"] .skeleton-grid span {
  background: linear-gradient(90deg, #131b2c 25%, #1a253c 50%, #131b2c 75%);
  background-size: 200% 100%;
}

/* Modals & Detail Sheet */
[data-theme="dark"] .detail-overlay,
[data-theme="dark"] .cart-overlay {
  background: rgba(4, 7, 13, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

[data-theme="dark"] .detail-sheet {
  background: #0f1628;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.85);
}

[data-theme="dark"] .detail-image-wrap {
  background: #080d18;
  border-right-color: #1e293b;
}

[data-theme="dark"] .detail-body {
  background: #0f1628;
}

[data-theme="dark"] .detail-body h2 {
  color: #f8fafc;
}

[data-theme="dark"] .detail-price {
  color: #ff3366;
}

[data-theme="dark"] .detail-desc-box {
  background: #141c2e;
  border-color: #1e293b;
}

[data-theme="dark"] .detail-desc-title {
  color: #94a3b8;
}

[data-theme="dark"] .detail-description {
  color: #cbd5e1;
}

[data-theme="dark"] .detail-actions {
  background: #0f1628;
  border-top-color: #1e293b;
}

[data-theme="dark"] .detail-cart-icon {
  background: rgba(2, 132, 199, 0.15);
  border-color: rgba(2, 132, 199, 0.35);
  color: #38bdf8;
}

[data-theme="dark"] .detail-cart-icon:hover {
  background: rgba(2, 132, 199, 0.25);
  border-color: #38bdf8;
}

[data-theme="dark"] .secondary-detail {
  background: #182238;
  border-color: #26354f;
  color: #94a3b8;
}

[data-theme="dark"] .secondary-detail:hover {
  background: #22304c;
  color: #f1f5f9;
}

[data-theme="dark"] .cart-panel {
  background: #0f1628;
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: #f1f5f9;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.75);
}

[data-theme="dark"] .modal-close {
  background: #182238;
  border-color: #26354f;
  color: #cbd5e1;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .modal-close:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #ffffff;
}

/* Cart */
[data-theme="dark"] .cart-panel-head {
  border-bottom-color: #1e293b;
}

[data-theme="dark"] .cart-panel-head button {
  background: #182238;
  color: #94a3b8;
}

[data-theme="dark"] .cart-panel-head button:hover {
  color: #f1f5f9;
}

[data-theme="dark"] .cart-item {
  background: #141c2e;
  border-color: #1e293b;
}

[data-theme="dark"] .cart-item-media {
  background: #1a243c;
  color: #ff3366;
}

[data-theme="dark"] .cart-item-body strong {
  color: #f1f5f9;
}

[data-theme="dark"] .cart-item-body span {
  color: #ff476e;
}

[data-theme="dark"] .cart-qty button {
  background: #1a253c;
  border-color: #273752;
  color: #cbd5e1;
}

[data-theme="dark"] .cart-qty button:hover {
  background: #253452;
  color: #fff;
}

[data-theme="dark"] .cart-remove-btn {
  background: rgba(239, 68, 68, 0.14);
  border-color: rgba(239, 68, 68, 0.26);
  color: #f87171;
}

[data-theme="dark"] .cart-panel-foot {
  background: #111728;
  border-top-color: #1e293b;
}

/* Mobile Nav */
[data-theme="dark"] .mobile-nav {
  background: rgba(12, 17, 29, 0.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .mobile-nav-btn {
  color: #94a3b8;
}

[data-theme="dark"] .mobile-nav-btn.active {
  color: #ff2d55;
}

[data-theme="dark"] .product-stock-tag.in-stock { color: #38bdf8; background: rgba(56, 189, 248, 0.15); }
[data-theme="dark"] .product-stock-tag.ready { color: #34d399; background: rgba(52, 211, 153, 0.15); }
[data-theme="dark"] .product-stock-tag.out { color: #f87171; background: rgba(248, 113, 113, 0.15); }
[data-theme="dark"] .product-sold-tag { color: #94a3b8; background: rgba(148, 163, 184, 0.12); border-color: rgba(148, 163, 184, 0.22); }
[data-theme="dark"] .detail-badge.badge-stock { color: #38bdf8; background: rgba(56, 189, 248, 0.15); }
[data-theme="dark"] .detail-badge.badge-out { color: #f87171; background: rgba(248, 113, 113, 0.15); }
[data-theme="dark"] .detail-badge.badge-sold { color: #cbd5e1; background: rgba(148, 163, 184, 0.14); border-color: rgba(148, 163, 184, 0.25); }

/* ============================================================
   CLEAN QRIS POPUP CHECKOUT STYLES (PERSIS SEPERTI KERANJANG/MANUAL)
   ============================================================ */

.modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 15, 29, 0.68);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 14px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  cursor: pointer;
}

.qris-sheet-container {
  position: relative;
  width: 100%;
  max-width: 440px;
  max-height: min(92vh, 690px);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 26px 80px rgba(15, 23, 42, 0.32);
  z-index: 2;
  animation: qrisModalPop .24s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes qrisModalPop {
  0% { transform: scale(0.92) translateY(12px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.qris-sheet-head {
  background: linear-gradient(135deg, #ff2d55 0%, #ff5238 60%, #ff7a29 100%);
  color: #fff;
  padding: 18px 20px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 24px 24px 0 0;
}

.qris-sheet-head strong {
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.3px;
  display: block;
}

.qris-sheet-head small {
  font-size: 11.5px;
  opacity: 0.92;
  margin-top: 3px;
  display: block;
  font-weight: 600;
}

.qris-sheet-close {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  border: 0;
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background .15s;
}

.qris-sheet-close:hover {
  background: rgba(255, 255, 255, 0.38);
}

.qris-sheet-body {
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--bg);
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.35) transparent;
  overscroll-behavior: contain;
}

.qris-sheet-body::-webkit-scrollbar {
  width: 5px;
}

.qris-sheet-body::-webkit-scrollbar-track {
  background: transparent;
}

.qris-sheet-body::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.3);
  border-radius: 999px;
}

.qris-sheet-body::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.55);
}

.qris-product-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.03);
}

.qris-prod-main {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  align-items: center;
}

.qris-prod-media {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
}

.qris-prod-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.qris-prod-fallback {
  font-size: 26px;
}

.qris-prod-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.qris-prod-name {
  font-size: 14.5px;
  font-weight: 850;
  color: var(--ink);
}

.qris-prod-price {
  font-size: 13.5px;
  font-weight: 900;
  color: #e31b4b;
  margin-top: 1px;
}

.qris-qty-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  background: var(--card);
  border: 1px solid #ffccd5;
  border-radius: 999px;
  padding: 2px 6px;
  width: fit-content;
}

.qris-qty-pill.locked-qty {
  padding: 3px 12px;
  background: rgba(255, 45, 85, 0.05);
  border-color: rgba(255, 45, 85, 0.25);
  font-size: 11.5px;
  color: var(--ink);
  cursor: default;
}

.qris-qty-lock-text strong {
  color: #ff2d55;
  font-weight: 850;
}

.qris-qty-lock-text small {
  color: var(--muted);
  font-weight: 600;
  margin-left: 2px;
}

.qris-qty-btn {
  width: 24px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #ff2d55;
  font-size: 16px;
  font-weight: 950;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.qris-qty-val {
  width: 26px;
  text-align: center;
  border: 0;
  background: transparent;
  font-size: 13px;
  font-weight: 900;
  color: var(--ink);
}

.qris-prod-subtotal-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
}

.qris-prod-subtotal {
  font-size: 14.5px;
  font-weight: 950;
  color: var(--ink);
}

.qris-prod-stock-badge {
  font-size: 11px;
  font-weight: 750;
  color: #ff2d55;
  background: rgba(255, 45, 85, 0.08);
  padding: 3px 10px;
  border-radius: 999px;
}

.qris-form-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 2px;
}

.qris-form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.qris-form-group label {
  font-size: 11.5px;
  font-weight: 750;
  color: var(--ink);
}

.qris-req {
  color: #dc2626;
}

.qris-opt {
  font-size: 10.5px;
  color: var(--muted);
  font-weight: 500;
}

.qris-input-field {
  width: 100%;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  padding: 0 12px;
  font-size: 13px;
  background: var(--card);
  color: var(--ink);
  outline: none;
  transition: border-color .15s;
}

.qris-input-field:focus {
  border-color: #0284c7;
  box-shadow: 0 0 0 2.5px rgba(2, 132, 199, 0.15);
}

.qris-email-alert {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  background: rgba(2, 132, 199, 0.08);
  border-left: 3.5px solid #0284c7;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 11px;
  color: var(--ink);
  line-height: 1.45;
  margin-top: 6px;
}

.qris-alert-icon {
  color: #0284c7;
  min-width: 16px;
  margin-top: 1px;
}

.qris-payment-selector {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border: 1.5px solid #0284c7;
  border-radius: 12px;
  background: rgba(2, 132, 199, 0.04);
  margin-top: 4px;
}

.qris-payment-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.qris-badge-box {
  padding: 4px 6px;
  background: transparent;
  border-radius: 6px;
  display: flex;
  align-items: center;
}

.qris-logo-img {
  height: 22px;
  max-width: 80px;
  width: auto;
  object-fit: contain;
  display: block;
}

.qris-payment-text strong {
  font-size: 12.5px;
  font-weight: 800;
  color: var(--ink);
  display: block;
}

.qris-payment-text small {
  font-size: 10.5px;
  color: var(--muted);
  display: block;
}

.qris-check-circle {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #0284c7;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  display: grid;
  place-items: center;
}

.qris-error-banner {
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(220, 38, 38, 0.1);
  border: 1px solid rgba(220, 38, 38, 0.25);
  color: #dc2626;
  font-size: 11.5px;
  font-weight: 600;
}

.qris-sheet-footer {
  padding: 14px 16px;
  border-top: 1px solid var(--line);
  background: var(--card);
}

.qris-total-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: rgba(255, 45, 85, 0.04);
  border: 1.5px solid rgba(255, 45, 85, 0.2);
  border-radius: 14px;
  margin-bottom: 12px;
}

.qris-total-label {
  font-size: 13px;
  font-weight: 750;
  color: var(--ink);
}

.qris-total-amount {
  font-size: 19px;
  font-weight: 950;
  color: #ff2d55;
}

.qris-footer-actions {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  gap: 10px;
}

.qris-btn-cancel {
  height: 42px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 850;
  background: #f3f5f8;
  color: #64748b;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: all .15s;
}

.qris-btn-cancel:hover {
  background: #e2e8f0;
  color: var(--ink);
}

.qris-btn-submit {
  height: 42px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 900;
  background: #13a567;
  color: #fff;
  border: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 4px 14px rgba(19, 165, 103, 0.35);
  transition: all .15s;
}

.qris-btn-submit:hover:not(:disabled) {
  background: #0f8a55;
  box-shadow: 0 6px 18px rgba(19, 165, 103, 0.45);
}

.qris-btn-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Dark Mode Overrides */
[data-theme="dark"] .qris-sheet-container {
  background: #0f172a;
  border-color: #1e293b;
}

[data-theme="dark"] .qris-sheet-body {
  background: #080d1a;
  scrollbar-color: rgba(148, 163, 184, 0.25) transparent;
}

[data-theme="dark"] .qris-product-card,
[data-theme="dark"] .qris-sheet-footer {
  background: #0f172a;
  border-color: #1e293b;
}

[data-theme="dark"] .qris-prod-media,
[data-theme="dark"] .qris-input-field {
  background: #141f36;
  border-color: #273752;
  color: #f8fafc;
}

[data-theme="dark"] .qris-qty-pill {
  background: #141f36;
  border-color: #3b2a3a;
}

[data-theme="dark"] .qris-qty-val {
  color: #f8fafc;
}

[data-theme="dark"] .qris-btn-cancel {
  background: #1e293b;
  border-color: #334155;
  color: #94a3b8;
}

[data-theme="dark"] .qris-btn-cancel:hover {
  background: #334155;
  color: #fff;
}

[data-theme="dark"] .qris-total-box {
  background: rgba(255, 45, 85, 0.08);
  border-color: rgba(255, 45, 85, 0.3);
}

[data-theme="dark"] .qris-payment-selector {
  background: rgba(2, 132, 199, 0.08);
  border-color: #0284c7;
}

[data-theme="dark"] .qris-logo-img {
  filter: brightness(0) invert(1);
}



