body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
  left: 0;
  right: 0;
}

.marquee-section {
  margin: 16px 0 24px 0;
  padding: 12px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  position: relative;
}

.marquee-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding: 0 4px;
}

.marquee-section-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.marquee-section-title i {
  font-size: 16px;
}

.marquee-outer-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.marquee-inner-wrapper {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
  padding: 4px 4px 12px 4px;
  width: 100%;
}

.marquee-inner-wrapper::-webkit-scrollbar {
  display: none;
}

.marquee-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s ease;
  color: var(--text);
}

.marquee-nav-btn:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-50%) scale(1.1);
}

.marquee-nav-btn.prev {
  left: -12px;
}

.marquee-nav-btn.next {
  right: -12px;
}

.marquee-card {
  flex: 0 0 auto;
  width: 150px;
  scroll-snap-align: start;
}

.compact-card {
  background: #ffffff;
  border-radius: var(--radius-sm);
  border: none;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  padding: 6px;
  cursor: pointer;
}

/* Subtle lift on hover, desktop/pointer devices only so it never gets
   "stuck" active on mobile taps. No border is reintroduced on hover. */
@media (hover: hover) and (pointer: fine) {
  .compact-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  }
}

.compact-img-wrap {
  position: relative;
  aspect-ratio: 1;
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #ffffff;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.compact-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.compact-badge-discount {
  position: absolute;
  top: 6px;
  left: 6px;
  background: #ff3b5c;
  color: white;
  font-size: 9px;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 20px;
  box-shadow: 0 2px 6px rgba(255, 59, 92, 0.25);
  z-index: 2;
}

.compact-badge-tag {
  position: absolute;
  bottom: 6px;
  left: 6px;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(2px);
  color: white;
  font-size: 8px;
  font-weight: 700;
  padding: 3px 7px;
  border-radius: 20px;
  z-index: 2;
  text-transform: uppercase;
  letter-spacing: 0.2px;
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-btn-fav {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  z-index: 3;
  color: #64748b;
  transition: transform 0.15s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.compact-btn-fav i {
  font-size: 15px;
  line-height: 1;
}

.compact-btn-fav:hover {
  box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

.compact-btn-fav.active {
  color: #ff3b5c;
}

.compact-btn-fav.active i {
  animation: favPop 0.3s ease;
}

@keyframes favPop {
  0% { transform: scale(1); }
  40% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.compact-btn-fav:active {
  transform: scale(0.9);
}

.compact-info {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.compact-vendor {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.compact-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 31px;
}

.compact-rating {
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  font-weight: 700;
  color: #fbbf24;
  margin-bottom: 4px;
}

.compact-rating span {
  color: var(--text-muted);
  font-weight: 500;
}

.compact-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-top: auto;
}

.compact-price-wrap {
  display: flex;
  flex-direction: column;
}

.compact-price {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
}

.compact-old-price {
  font-size: 10px;
  color: var(--text-muted);
  text-decoration: line-through;
  line-height: 1;
  margin-top: 1px;
}

.compact-stock-status {
  font-size: 9px;
  font-weight: 700;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 3px;
}

.compact-stock-status.in-stock {
  color: #10b981;
}

.compact-stock-status.out-of-stock {
  color: #ef4444;
}

.compact-btn-cart {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  transition: transform 0.15s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.compact-btn-cart i {
  font-size: 14px;
  line-height: 1;
}

.compact-btn-cart:hover {
  background: #1e293b;
  box-shadow: 0 3px 10px rgba(0,0,0,0.25);
}

.compact-btn-cart:active {
  transform: scale(0.9);
}

.compact-btn-cart:disabled {
  background: #cbd5e1;
  color: #64748b;
  cursor: not-allowed;
  box-shadow: none;
}

.shop-layout-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 4px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

.shop-sorting-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.shop-sort-select {
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  outline: none;
  cursor: pointer;
}

.shop-sort-select:focus {
  border-color: var(--primary);
}



.skeleton-marquee-card {
  width: 150px;
  height: 210px;
  border-radius: var(--radius-sm);
  background: #f1f5f9;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.skeleton-shimmer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.6) 50%, rgba(255,255,255,0) 100%);
  animation: skeletonLoad 1.5s infinite;
}

@keyframes skeletonLoad {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@media (max-width: 768px) {
  .marquee-card {
    width: 130px;
  }
  .compact-name {
    font-size: 11px;
    height: 29px;
  }
  .compact-price {
    font-size: 12px;
  }
}

.detail-header-bar {
  display: flex;
  align-items: center;
  padding: 0 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  height: 64px;
}

.detail-header-back-btn {
  background: var(--surface2);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: #0f172a;
  transition: background 0.2s;
  margin-right: 16px;
  flex-shrink: 0;
}

.detail-header-back-btn i {
  font-size: 20px;
  line-height: 1;
}

.detail-header-back-btn:hover {
  background: #e2e8f0;
}

.detail-header-title {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  flex-grow: 1;
}

.detail-fab-cart {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: transform 0.2s, background-color 0.2s;
  z-index: 10;
}

.detail-fab-cart i {
  font-size: 20px;
  line-height: 1;
}

.detail-fab-cart:active {
  transform: scale(0.95);
}

.detail-fab-cart:disabled {
  background: #cbd5e1;
  color: #64748b;
  cursor: not-allowed;
  box-shadow: none;
}