/* The Parts - Design System */
:root {
  --blue-primary: #1e87d6;
  --blue-light: #42a5f5;
  --blue-dark: #1565a0;
  --silver: #b8c4d0;
  --silver-light: #e2e8f0;
  --silver-dark: #64748b;
  --orange: #f97316;
  --orange-light: #fb923c;
  --orange-dark: #ea580c;
  --header-bg: #1a1d23;
  --header-border: #3a4150;
  --header-input-bg: #242830;
  --header-text: #f1f5f9;
  --header-text-muted: #94a3b8;
  --filter-bar-bg: #eef2f7;
  --filter-bar-border: #dce3ed;
  --filter-label: #64748b;
  --filter-input-bg: #ffffff;
  --filter-input-border: #cbd5e1;
  --bg-page: #e5edf3;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --bg-input: #f1f5f9;
  --bg-muted: #f8fafc;
  --border: #e2e8f0;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --success: #22c55e;
  --warning: #eab308;
  --danger: #ef4444;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  --shadow-blue: 0 4px 20px rgba(30, 135, 214, 0.18);
  --font: 'Inter', system-ui, -apple-system, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font);
  background: var(--bg-page);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.5;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

a {
  color: var(--blue-primary);
  text-decoration: none;
}

a:hover {
  color: var(--orange);
}

img {
  max-width: 100%;
  display: block;
}

/* Header — dark top + light filter bar */
.header {
  position: relative;
  z-index: 100;
  width: 100%;
  max-width: 100%;
}

.header a {
  color: inherit;
}

.header-top {
  position: sticky;
  top: 0;
  z-index: 102;
  background: linear-gradient(180deg, #1e2229 0%, var(--header-bg) 100%);
  border-bottom: 1px solid var(--header-border);
}

.header-top-inner {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: nowrap;
  min-width: 0;
}

.header-filters {
  position: sticky;
  top: var(--header-top-height, 64px);
  z-index: 101;
  background: var(--filter-bar-bg);
  border-bottom: 1px solid var(--filter-bar-border);
}

body.store-filter-mode .banner-carousel-wrap {
  display: none;
}

/* Banner carousel — full bleed images */
.banner-carousel-wrap {
  background: #0a0a0a;
  border-bottom: none;
  width: 100%;
  overflow: hidden;
}

.banner-carousel {
  position: relative;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

.banner-track {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  border-radius: 0;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.banner-track::-webkit-scrollbar {
  display: none;
}

.banner-slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  display: block;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  line-height: 0;
}

.banner-slide--image img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 2.4 / 1;
  object-fit: cover;
  object-position: center;
}

.banner-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-primary);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
  z-index: 2;
  transition: background 0.2s, transform 0.2s;
}

.banner-nav:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.05);
}

.banner-nav--prev {
  left: 12px;
}

.banner-nav--next {
  right: 12px;
}

.banner-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 10px 0 12px;
  width: 100%;
  max-width: none;
  margin: 0;
  background: #0a0a0a;
}

.banner-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}

.banner-dot.active {
  background: #fff;
  transform: scale(1.15);
}

.banner-dot:hover {
  background: rgba(255, 255, 255, 0.7);
}

.header-filters-inner {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
  min-width: 0;
}

.location-row,
.search-row {
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.logo-img {
  height: 64px;
  max-width: 280px;
  width: auto;
  object-fit: contain;
}

.header-title h1 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--header-text);
  line-height: 1.2;
}

.header-title p {
  font-size: 0.8rem;
  color: var(--header-text-muted);
  margin-top: 2px;
}

/* Location Filter */
.location-filter {
  flex: 0 0 280px;
  min-width: 200px;
}

.header-filters .location-filter {
  flex: 0 0 280px;
}

.location-filter label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  font-weight: 600;
}

.header-filters .location-filter label {
  color: var(--filter-label);
}

.location-filter select {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.header-filters .location-filter select {
  background-color: var(--filter-input-bg);
  border: 1px solid var(--filter-input-border);
  color: var(--text-primary);
}

.header-filters .location-filter select:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.15);
}

/* Search */
.search-bar {
  width: 100%;
  position: relative;
}

.search-bar input {
  width: 100%;
  padding: 11px 14px 11px 40px;
  border-radius: var(--radius);
  font-size: 0.9rem;
}

.header-filters .search-bar input {
  background: var(--filter-input-bg);
  border: 1px solid var(--filter-input-border);
  color: var(--text-primary);
}

.header-filters .search-bar input::placeholder {
  color: var(--text-secondary);
}

.header-filters .search-bar input:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.15);
}

.search-bar .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  pointer-events: none;
}

.header-filters .search-bar .search-icon {
  color: var(--text-secondary);
}

/* Location bar */
.location-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  background: var(--filter-input-bg);
  border: 1px solid var(--filter-input-border);
  border-radius: var(--radius);
  padding: 0 14px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.geo-btn {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: var(--blue-primary);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background 0.2s, opacity 0.2s;
}

.geo-btn:hover {
  background: var(--blue-light);
}

.geo-btn.loading {
  opacity: 0.6;
  animation: pulse 1s infinite;
}

@keyframes pulse {
  50% { opacity: 0.4; }
}

.location-info {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.location-label {
  flex-shrink: 0;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--filter-label);
  font-weight: 600;
}

.location-value {
  font-size: 0.92rem;
  color: var(--text-primary);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.location-radius {
  font-size: 0.78rem;
  color: var(--text-secondary);
  white-space: nowrap;
}

.location-radius::before {
  content: '·';
  margin-right: 8px;
  color: var(--silver-dark);
}

/* Primary filters */
.primary-filters {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}

.filter-field--search {
  grid-column: 1 / -1;
}

.filter-field--search .search-bar {
  width: 100%;
}

.more-filters-wrap {
  width: 100%;
}

.more-filters-toggle {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius);
  border: 1px dashed var(--filter-input-border);
  background: var(--filter-input-bg);
  color: var(--blue-primary);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.more-filters-toggle:hover,
.more-filters-toggle.open {
  background: rgba(30, 135, 214, 0.08);
  border-color: var(--blue-primary);
  border-style: solid;
}

.more-filters-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--filter-bar-border);
}

.more-filters-panel[hidden] {
  display: none;
}

.filter-field {
  min-width: 0;
}

.filter-field label {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--filter-label);
  font-weight: 600;
  margin-bottom: 6px;
}

.filter-field select {
  width: 100%;
  padding: 11px 12px;
  border-radius: var(--radius);
  border: 1px solid var(--filter-input-border);
  background: var(--filter-input-bg);
  font-size: 0.88rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.filter-field select:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.12);
}

/* Cart button */
.cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  background: var(--header-input-bg);
  border: 1px solid var(--header-border);
  border-radius: var(--radius);
  padding: 8px 12px;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  text-decoration: none;
  color: inherit;
}

.cart-badge,
.mobile-nav-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 10px;
  background: var(--orange);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-nav-item {
  position: relative;
}

.mobile-nav-icon svg {
  width: 22px;
  height: 22px;
  display: block;
}

/* Store logos */
.store-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: white;
  font-weight: 800;
  flex-shrink: 0;
}

.store-logo--sm {
  width: 28px;
  height: 28px;
  font-size: 0.6rem;
}

.store-logo--lg {
  width: 48px;
  height: 48px;
  font-size: 0.85rem;
}

.store-logo--xl {
  width: 72px;
  height: 72px;
  font-size: 1.2rem;
  margin: 0 auto 12px;
}

/* Listing cards (individual ads) */
.listing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.25s;
  position: relative;
  box-shadow: var(--shadow);
  cursor: pointer;
}

.listing-card:hover {
  transform: translateY(-3px);
  border-color: var(--blue-primary);
  box-shadow: var(--shadow-blue);
}

.listing-card-image {
  height: 160px;
  background: var(--bg-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
}

.listing-card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
}

.listing-card-body {
  padding: 14px;
}

.listing-store-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.listing-store-row--lg {
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.listing-store-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}

.listing-store-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.listing-store-name-row--lg h2 {
  margin: 0;
  flex: 1;
  min-width: 0;
}

.listing-store-name-row--card h2 {
  margin: 0;
  flex: 1;
  min-width: 0;
}

.store-rating {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.store-rating--compact {
  gap: 3px;
}

.store-rating-stars {
  display: inline-flex;
  line-height: 1;
  letter-spacing: -0.05em;
}

.store-rating-stars .star {
  font-size: 0.82rem;
  line-height: 1;
}

.store-rating--compact .store-rating-stars .star {
  font-size: 0.68rem;
}

.store-rating--compact .store-rating-score {
  font-size: 0.68rem;
}

.store-rating-stars .star--full {
  color: #f59e0b;
}

.store-rating-stars .star--half {
  background: linear-gradient(90deg, #f59e0b 50%, #d1d5db 50%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.store-rating-stars .star--empty {
  color: #d1d5db;
}

.store-rating-score {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
  line-height: 1;
}

.table-store-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 2px 0 4px;
  flex-wrap: wrap;
}

.table-store-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  flex: 1;
  min-width: 0;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.listing-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.listing-pricing {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}

.listing-pricing--single .listing-price-value {
  font-size: 1.2rem;
}

.listing-price-block {
  flex: 1;
}

.listing-price-label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.listing-price-value {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--orange);
}

.listing-price-block--total .listing-price-value {
  font-size: 1.15rem;
}

.listing-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.listing-card .listing-actions--single {
  margin-top: 14px;
}

.listing-card .btn-buy-now--full {
  width: 100%;
  padding: 11px 14px;
  font-size: 0.88rem;
}

.btn-add-cart,
.btn-buy-now {
  flex: 1;
  padding: 8px 10px;
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  font-family: var(--font);
}

.btn-add-cart {
  background: var(--bg-muted);
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.btn-buy-now {
  background: var(--blue-primary);
  color: white;
}

.btn-add-cart--lg,
.btn-buy-now--lg {
  padding: 12px 16px;
  font-size: 0.9rem;
}

.listing-detail-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.listing-detail-actions--single {
  flex-direction: column;
}

.btn-buy-now--full {
  width: 100%;
  padding: 14px 16px;
  font-size: 0.95rem;
}

.listing-detail-pricing {
  background: var(--bg-muted);
  border-radius: var(--radius);
  padding: 16px;
  margin-top: 16px;
}

.pricing-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 0.9rem;
}

.pricing-row--total {
  border-top: 1px solid var(--border);
  margin-top: 8px;
  padding-top: 12px;
  font-size: 1rem;
  font-weight: 800;
}

.pricing-row--total strong {
  color: var(--orange);
}

.favorite-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.favorite-btn--inline {
  position: static;
  width: auto;
  height: auto;
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 0.8rem;
  margin-left: auto;
}

/* Cart */
.cart-items {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cart-store-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--border);
}

.cart-store-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.cart-store-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--blue-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.cart-store-shipping {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: -4px;
}

.cart-store-shipping-note {
  font-size: 0.75rem;
}

.checkout-store-shipping-row {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed var(--border);
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.cart-item {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  align-items: center;
}

.cart-item-img {
  width: 56px;
  height: 56px;
  object-fit: contain;
  background: var(--bg-muted);
  border-radius: 8px;
  padding: 4px;
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.cart-item-info strong {
  font-size: 0.85rem;
}

.cart-item-store,
.cart-item-price {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.cart-item-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.qty-control {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-muted);
  border-radius: 8px;
  padding: 4px;
}

.qty-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: white;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 700;
}

.cart-remove {
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
  font-size: 0.85rem;
}

.cart-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.cart-summary-rows {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 10px;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.checkout-summary-rows {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}

.checkout-section-label {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.checkout-delivery-options,
.checkout-payment-section {
  margin-bottom: 16px;
}

.delivery-option-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.delivery-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  cursor: pointer;
  font-size: 0.9rem;
}

.delivery-option input {
  accent-color: var(--blue-primary);
}

.delivery-option--disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.checkout-payment-group {
  margin-bottom: 10px;
}

.checkout-payment-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.checkout-payment-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.9rem;
  background: var(--bg-card);
}

.checkout-change-group {
  margin-top: 10px;
  padding: 12px;
  border-radius: var(--radius);
  background: rgba(249, 115, 22, 0.08);
  border: 1px solid rgba(249, 115, 22, 0.2);
}

.checkout-change-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.checkout-change-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.9rem;
  background: var(--bg-card);
}

.checkout-change-input:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

.checkout-change-hint {
  margin-top: 6px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.35;
}

.checkout-pickup-address {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-top: 10px;
  line-height: 1.4;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 14px;
}

.cart-total-row strong {
  color: var(--orange);
}

.cart-footer-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-continue-shopping {
  width: 100%;
  padding: 13px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.btn-continue-shopping:hover {
  background: var(--bg-muted);
  border-color: var(--blue-primary);
}

.checkout-store-group {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border);
}

.checkout-store-name {
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--blue-primary);
}

.order-item-line {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

/* Stores page */
.stores-page-header {
  margin-bottom: 28px;
}

.stores-page-header h1 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.stores-page-header p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 560px;
}

.stores-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  max-width: 720px;
}

.store-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, border-color 0.2s;
}

.store-card:hover {
  transform: translateY(-2px);
  border-color: var(--blue-primary);
}

.store-card-layout {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.store-card-logo-link {
  flex-shrink: 0;
  text-decoration: none;
}

.store-card-logo-link .store-logo--xl {
  margin: 0;
}

.store-card-body {
  flex: 1;
  min-width: 0;
  text-align: left;
}

.store-card h2 {
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.store-card-name-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.store-card-name-link:hover h2 {
  color: var(--blue-primary);
}

.store-card-tagline {
  font-size: 0.82rem;
  color: var(--blue-primary);
  font-weight: 600;
  margin-bottom: 8px;
}

.store-card-meta {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.35;
}

.store-card-count {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--orange);
  margin: 8px 0 6px;
}

.store-card-link {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--blue-primary);
}

.store-card-fav {
  top: 12px;
  right: 12px;
}

/* Nav links */
.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
  flex-wrap: nowrap;
  min-width: 0;
  flex-shrink: 1;
}

.user-greeting {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.user-greeting-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  padding: 4px 0;
  border-radius: var(--radius);
  transition: opacity 0.2s;
}

.user-greeting-btn:hover {
  opacity: 0.85;
}

.user-menu-wrap {
  position: relative;
}

.user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 200px;
  background: var(--header-input-bg);
  border: 1px solid var(--header-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  z-index: 120;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.user-dropdown[hidden] {
  display: none;
}

.user-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 14px;
  background: none;
  border: none;
  border-radius: 6px;
  color: var(--header-text);
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  transition: background 0.2s;
}

.user-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.user-dropdown-divider {
  border: none;
  border-top: 1px solid var(--header-border);
  margin: 4px 0;
}

.user-avatar-img,
.user-avatar-fallback {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, 0.15);
}

.user-avatar-img {
  object-fit: cover;
  display: block;
}

.user-avatar-fallback {
  background: var(--blue-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
}

.user-text {
  font-size: 0.9rem;
  color: var(--header-text-muted);
  white-space: nowrap;
}

.user-text strong {
  color: var(--header-text);
  font-weight: 600;
}

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-btn {
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid var(--header-border);
  background: var(--header-input-bg);
  color: var(--header-text);
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-btn:hover {
  background: #2c3139;
  border-color: var(--blue-primary);
  color: var(--header-text);
}

.nav-btn.primary {
  background: var(--blue-primary);
  border-color: var(--blue-primary);
  color: white;
}

.nav-btn.primary:hover {
  background: var(--blue-light);
}

/* Main layout */
.main {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 24px 20px 60px;
  min-width: 0;
  overflow-x: hidden;
}

.section-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.listings-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 16px;
  margin-bottom: 16px;
}

.listings-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
}

.toolbar-field label {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 5px;
}

.toolbar-field select {
  min-width: 200px;
  padding: 9px 32px 9px 12px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 0.85rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.toolbar-field select:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.12);
}

.view-toggle {
  display: flex;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-card);
}

.view-toggle-btn {
  padding: 9px 14px;
  border: none;
  background: transparent;
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  white-space: nowrap;
}

.view-toggle-btn + .view-toggle-btn {
  border-left: 1px solid var(--border);
}

.view-toggle-btn.active {
  background: var(--blue-primary);
  color: white;
}

.view-toggle-btn:hover:not(.active) {
  background: var(--bg-muted);
}

.section-title .badge {
  background: var(--orange);
  color: white;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 600;
}

/* Categories carousel */
.categories-carousel {
  position: relative;
  margin-bottom: 24px;
  margin-left: -20px;
  margin-right: -20px;
  padding: 0 20px;
}

.categories-carousel::before,
.categories-carousel::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 4px;
  width: 28px;
  z-index: 1;
  pointer-events: none;
}

.categories-carousel::before {
  left: 0;
  background: linear-gradient(to right, var(--bg-page), transparent);
}

.categories-carousel::after {
  right: 0;
  background: linear-gradient(to left, var(--bg-page), transparent);
}

.categories {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 4px 4px 8px;
}

.categories::-webkit-scrollbar {
  display: none;
}

.category-chip {
  flex-shrink: 0;
  scroll-snap-align: start;
  padding: 10px 18px;
  border-radius: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.category-chip:hover,
.category-chip.active {
  background: var(--blue-primary);
  border-color: var(--blue-primary);
  color: white;
}

.listings-container--table {
  display: block;
}

.store-context-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  background: rgba(30, 135, 214, 0.08);
  border: 1px solid rgba(30, 135, 214, 0.22);
  border-radius: var(--radius-lg);
}

.store-context-banner[hidden] {
  display: none !important;
}

.store-context-banner-body {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.store-context-banner-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 2px;
}

.store-context-banner-name {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
}

.store-context-banner-clear {
  flex-shrink: 0;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--blue-primary);
  background: var(--bg-card);
  color: var(--blue-primary);
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.store-context-banner-clear:hover {
  background: rgba(30, 135, 214, 0.08);
}

.listings-table-wrap {
  width: 100%;
  overflow-x: visible;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  box-shadow: var(--shadow);
}

.listings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  table-layout: fixed;
}

.listings-table thead {
  background: var(--bg-muted);
  border-bottom: 1px solid var(--border);
}

.listings-table th {
  padding: 12px 14px;
  text-align: left;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  font-weight: 700;
  white-space: nowrap;
}

.listings-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.listings-table tbody tr:last-child td {
  border-bottom: none;
}

.listings-table-row {
  transition: background 0.15s;
}

.listings-table-row:hover {
  background: var(--bg-muted);
}

.table-product-cell {
  min-width: 0;
  width: 55%;
}

.table-product-name {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1.35;
  color: var(--text-primary);
}

.table-product-meta {
  display: block;
  margin-top: 4px;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.col-total,
.table-total-cell {
  text-align: right;
  white-space: nowrap;
  width: 1%;
}

.col-action,
.table-action-cell {
  text-align: right;
  white-space: nowrap;
  width: 1%;
}

.table-total {
  color: var(--orange);
  font-weight: 800;
  font-size: 0.95rem;
}

.btn-view-listing {
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid var(--blue-primary);
  background: var(--bg-card);
  color: var(--blue-primary);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  white-space: nowrap;
}

.btn-view-listing:hover {
  background: var(--blue-primary);
  color: #fff;
}

.listing-qty-section {
  margin-top: 20px;
  padding: 16px;
  background: var(--bg-muted);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.listing-qty-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  font-weight: 600;
}

.qty-control--detail {
  padding: 6px;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.qty-control--detail .qty-btn {
  width: 44px;
  height: 44px;
  font-size: 1.25rem;
  border-radius: 10px;
}

.qty-control--detail .qty-value {
  min-width: 48px;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-primary);
}

.listing-qty-subtotal {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.listing-qty-subtotal strong {
  color: var(--orange);
  font-weight: 800;
}

/* Product Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s;
  position: relative;
  box-shadow: var(--shadow);
}

.product-card:hover {
  transform: translateY(-3px);
  border-color: var(--blue-primary);
  box-shadow: var(--shadow-blue);
}

.product-card-image {
  height: 180px;
  background: var(--bg-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 16px;
}

.product-card-body {
  padding: 16px;
}

.product-card-category {
  font-size: 0.7rem;
  color: var(--blue-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  margin-bottom: 4px;
}

.product-card-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  line-height: 1.3;
}

.product-card-stores {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.product-card-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.product-card-price .from {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.product-card-price .value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--orange);
}

.product-card-price .best-tag {
  font-size: 0.65rem;
  background: rgba(249, 115, 22, 0.15);
  color: var(--orange);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 600;
}

/* Product Detail Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}

.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 820px;
  margin: 40px auto;
  box-shadow: var(--shadow);
  transform: translateY(20px);
  transition: transform 0.3s;
}

.modal-overlay.open .modal {
  transform: translateY(0);
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  border-radius: 6px;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 24px;
}

.product-detail-hero {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 24px;
  margin-bottom: 28px;
  align-items: start;
}

.product-detail-image {
  width: 180px;
  height: 180px;
  background: var(--bg-muted);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--border);
  overflow: hidden;
}

.product-detail-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
}

.product-detail-info h2 {
  font-size: 1.3rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.product-detail-info .category {
  color: var(--blue-primary);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  margin-bottom: 8px;
}

.product-detail-info .description {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* Store comparison table */
.stores-comparison {
  margin-top: 8px;
}

.stores-comparison h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.store-row {
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: start;
  transition: border-color 0.2s;
}

.store-row:hover {
  border-color: var(--blue-primary);
}

.store-row.best-price {
  border-color: var(--orange);
  background: rgba(249, 115, 22, 0.04);
}

.store-info {
  min-width: 0;
}

.store-info-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.store-info h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--blue-primary);
  margin: 0;
  line-height: 1.3;
}

.store-info .address {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.store-info .delivery {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.store-info .delivery strong {
  color: var(--text-primary);
}

.store-pricing {
  text-align: right;
  min-width: 150px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.store-pricing .price {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--orange);
}

.store-pricing .shipping {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin: 2px 0 2px;
}

.store-pricing .shipping-band {
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.store-pricing .total {
  font-size: 0.85rem;
  color: var(--text-primary);
  font-weight: 600;
  margin-bottom: 10px;
}

.btn-order {
  padding: 8px 18px;
  background: var(--blue-primary);
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-order:hover {
  background: var(--blue-light);
  box-shadow: var(--shadow-blue);
}

.best-badge {
  display: inline-block;
  background: var(--orange);
  color: white;
  font-size: 0.65rem;
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

/* Order Form Modal */
.order-form {
  margin-top: 16px;
}

.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--blue-primary);
}

.form-group textarea {
  resize: vertical;
  min-height: 60px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.order-summary {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  margin-bottom: 16px;
}

.order-summary h4 {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.order-summary .item {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.order-summary .total-row {
  display: flex;
  justify-content: space-between;
  font-weight: 800;
  font-size: 1rem;
  color: var(--orange);
  border-top: 1px solid var(--border);
  padding-top: 8px;
  margin-top: 8px;
}

.payment-notice {
  background: rgba(30, 135, 214, 0.08);
  border: 1px solid rgba(30, 135, 214, 0.2);
  border-radius: var(--radius);
  padding: 12px;
  font-size: 0.85rem;
  color: var(--blue-dark);
  margin-bottom: 16px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.btn-submit {
  width: 100%;
  padding: 14px;
  background: var(--orange);
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn-submit:hover {
  background: var(--orange-light);
  box-shadow: 0 4px 20px rgba(249, 115, 22, 0.3);
}

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

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--bg-card);
  border: 1px solid var(--success);
  border-radius: var(--radius);
  padding: 14px 20px;
  color: var(--text-primary);
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: var(--shadow);
  z-index: 300;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 10px;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Empty state */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
}

.empty-state .icon {
  font-size: 3rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.empty-state h3 {
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 6px;
}

/* ===== STORE DASHBOARD ===== */
.header-dashboard-bar {
  background: var(--header-bg);
  border-bottom: 1px solid var(--header-border);
}

.header-dashboard-inner {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0 20px 16px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  min-width: 0;
}

.header--dashboard .header-title {
  flex: 1;
  min-width: 200px;
}

.header--dashboard .header-title h1 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--header-text);
  line-height: 1.2;
}

.header--dashboard .header-title p {
  font-size: 0.8rem;
  color: var(--header-text-muted);
  margin-top: 4px;
}

.dashboard-stats {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.stat-card {
  background: var(--header-input-bg);
  border: 1px solid var(--header-border);
  border-radius: var(--radius);
  padding: 10px 16px;
  text-align: center;
  min-width: 88px;
}

.stat-card .number {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--orange);
}

.stat-card .label {
  font-size: 0.7rem;
  color: var(--header-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.dashboard-main {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 24px 20px 60px;
  min-width: 0;
}

/* Dashboard section tabs */
.dashboard-section-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
}

.section-tab {
  padding: 12px 20px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s;
}

.section-tab:hover {
  color: var(--text-primary);
}

.section-tab.active {
  color: var(--blue-primary);
  border-bottom-color: var(--blue-primary);
}

/* Product catalog manager */
.products-toolbar {
  margin-bottom: 16px;
}

.products-search {
  position: relative;
  margin-bottom: 12px;
}

.products-search input {
  width: 100%;
  padding: 11px 14px 11px 40px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font);
}

.products-search input:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.15);
}

.products-search .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
}

.products-filter-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.products-hint {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.5;
}

.catalog-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.catalog-item {
  display: grid;
  grid-template-columns: auto 72px 1fr auto;
  gap: 14px;
  align-items: start;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow);
  transition: border-color 0.2s;
}

.catalog-item--active {
  border-color: var(--blue-primary);
  background: rgba(30, 135, 214, 0.03);
}

.catalog-item-check {
  display: flex;
  align-items: center;
  padding-top: 28px;
  cursor: pointer;
}

.catalog-item-check input {
  width: 20px;
  height: 20px;
  accent-color: var(--blue-primary);
  cursor: pointer;
}

.catalog-item-image {
  width: 72px;
  height: 72px;
  background: var(--bg-muted);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  flex-shrink: 0;
}

.catalog-item-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.catalog-item-info {
  min-width: 0;
}

.catalog-item-category {
  font-size: 0.68rem;
  color: var(--blue-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.catalog-item-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 4px 0 6px;
  line-height: 1.3;
}

.catalog-item-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.catalog-item-fields {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 140px;
}

.catalog-item-fields--hidden {
  opacity: 0.4;
  pointer-events: none;
}

.catalog-field label {
  display: block;
  font-size: 0.68rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 3px;
  font-weight: 600;
}

.catalog-field input {
  width: 100%;
  padding: 8px 10px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: var(--font);
  color: var(--text-primary);
}

.catalog-field input:focus {
  outline: none;
  border-color: var(--blue-primary);
}

.catalog-field input:disabled {
  background: var(--bg-muted);
  cursor: not-allowed;
}

.btn-save-product {
  padding: 10px 16px;
  background: var(--blue-primary);
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: background 0.2s;
  margin-top: 4px;
}

.btn-save-product:hover:not(:disabled) {
  background: var(--blue-light);
}

.btn-save-product:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.shipping-rates-panel {
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 20px;
}

.shipping-rates-panel h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.rate-base {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.rate-categories {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rate-category strong {
  display: block;
  font-size: 0.82rem;
  margin-bottom: 6px;
  color: var(--blue-primary);
}

.rate-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.rate-chip {
  font-size: 0.72rem;
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 10px;
  color: var(--text-secondary);
}

.catalog-field--frete {
  grid-column: 1 / -1;
}

.catalog-frete-bands {
  list-style: none;
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.catalog-frete-bands li::before {
  content: '📍 ';
  font-size: 0.65rem;
}

.tabs-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.tabs-scroll::-webkit-scrollbar {
  display: none;
}

.tabs-scroll .tabs {
  display: inline-flex;
  flex-wrap: nowrap;
  margin-bottom: 0;
  border-bottom: none;
  min-width: min-content;
}

.store-selector {
  flex: 1;
  min-width: 200px;
}

.store-selector label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  font-weight: 600;
}

.header-filters .store-selector label {
  color: var(--filter-label);
}

.store-selector select {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 0.9rem;
}

.header-filters .store-selector select {
  background: var(--filter-input-bg);
  border: 1px solid var(--filter-input-border);
  color: var(--text-primary);
  min-width: 0;
}

.header-filters .store-selector select:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(30, 135, 214, 0.15);
}

/* Orders table */
.orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.order-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color 0.2s;
  box-shadow: var(--shadow);
}

.order-card.new {
  border-color: var(--orange);
  box-shadow: 0 0 20px rgba(249, 115, 22, 0.1);
}

.order-card-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  background: var(--bg-muted);
  flex-wrap: wrap;
  gap: 8px;
}

.order-id {
  font-weight: 800;
  color: var(--blue-primary);
  font-size: 0.95rem;
}

.order-status {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.order-status.pending {
  background: rgba(249, 115, 22, 0.15);
  color: var(--orange);
}

.order-status.confirmed {
  background: rgba(30, 135, 214, 0.15);
  color: var(--blue-primary);
}

.order-status.delivering {
  background: rgba(234, 179, 8, 0.15);
  color: var(--warning);
}

.order-status.delivered {
  background: rgba(34, 197, 94, 0.15);
  color: var(--success);
}

.order-status.cancelled {
  background: rgba(239, 68, 68, 0.12);
  color: var(--danger);
}

.order-card-body {
  padding: 16px 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.order-detail label {
  display: block;
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 2px;
}

.order-detail p {
  font-size: 0.9rem;
  color: var(--text-primary);
}

.order-product-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.order-product-thumb {
  width: 48px;
  height: 48px;
  object-fit: contain;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px;
  flex-shrink: 0;
}

.order-detail .price-highlight {
  color: var(--orange);
  font-weight: 800;
  font-size: 1.1rem;
}

.order-card-actions {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-action {
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 700;
  border: 1px solid var(--border);
  background: var(--bg-input);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-action:hover {
  border-color: var(--blue-primary);
}

.btn-action.confirm {
  background: var(--blue-primary);
  border-color: var(--blue-primary);
  color: white;
}

.btn-action.deliver {
  background: var(--orange);
  border-color: var(--orange);
  color: white;
}

.btn-action.complete {
  background: var(--success);
  border-color: var(--success);
  color: white;
}

/* Tabs */
.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  padding: 10px 20px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
  font-family: var(--font);
  touch-action: manipulation;
}

.tab .count {
  background: var(--orange);
  color: white;
  font-size: 0.65rem;
  padding: 1px 6px;
  border-radius: 10px;
  margin-left: 6px;
  pointer-events: none;
}

.tab:hover {
  color: var(--text-primary);
}

.tab.active {
  color: var(--blue-primary);
  border-bottom-color: var(--blue-primary);
}

/* Mobile footer navigation */
.mobile-footer-nav {
  display: none;
}

.mobile-menu-overlay {
  display: none;
}

/* Responsive */
@media (max-width: 640px) {
  .main {
    padding-bottom: 96px;
  }

  .mobile-footer-nav {
    display: flex;
    align-items: flex-end;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 90;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.08);
    padding: 0 4px calc(8px + env(safe-area-inset-bottom, 0px));
    min-height: 62px;
  }

  .mobile-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px 2px 8px;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
    color: var(--text-secondary);
    font-family: var(--font);
    color: var(--text-secondary);
    font-family: var(--font);
    border-radius: var(--radius);
    transition: color 0.2s;
    min-width: 0;
  }

  .mobile-nav-item.active {
    color: var(--blue-primary);
  }

  .mobile-nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
  }

  .mobile-nav-label {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.02em;
  }

  .mobile-nav-cart-wrap {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    position: relative;
    min-width: 72px;
  }

  .mobile-nav-cart-fab {
    position: relative;
    top: -20px;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--blue-primary);
    color: #fff;
    border: 4px solid var(--bg-page);
    box-shadow: 0 6px 20px rgba(30, 135, 214, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
    flex-shrink: 0;
  }

  .mobile-nav-cart-fab svg {
    width: 26px;
    height: 26px;
  }

  .mobile-nav-cart-fab:active {
    transform: scale(0.96);
  }

  .mobile-nav-cart-fab.active {
    background: var(--blue-dark);
    box-shadow: 0 6px 24px rgba(21, 101, 160, 0.5);
  }

  .mobile-nav-cart-fab .mobile-nav-badge {
    top: 0;
    right: 0;
    border: 2px solid var(--bg-page);
  }

  .mobile-menu-overlay {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 150;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
  }

  .mobile-menu-overlay.open {
    opacity: 1;
    visibility: visible;
  }

  .mobile-menu-drawer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-page);
    border-radius: 20px 20px 0 0;
    padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    max-height: 85vh;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.15);
  }

  .mobile-menu-overlay.open .mobile-menu-drawer {
    transform: translateY(0);
  }

  .mobile-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px 12px;
    border-bottom: 1px solid var(--border);
  }

  .mobile-menu-user {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
  }

  .mobile-menu-user img,
  .mobile-menu-user .user-avatar-fallback {
    width: 48px;
    height: 48px;
  }

  .mobile-menu-user-info h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
  }

  .mobile-menu-user-info p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 2px;
  }

  .mobile-menu-close {
    background: var(--bg-muted);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.4rem;
    line-height: 1;
    color: var(--text-secondary);
    cursor: pointer;
    flex-shrink: 0;
  }

  .mobile-menu-list {
    padding: 8px 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .mobile-menu-section-label {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    padding: 12px 16px 6px;
    margin: 0;
  }

  .mobile-menu-section-label:first-child {
    padding-top: 4px;
  }

  .mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px 16px;
    background: none;
    border: none;
    border-radius: var(--radius);
    font-family: var(--font);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    text-align: left;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
  }

  .mobile-menu-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    color: var(--text-secondary);
  }

  .mobile-menu-icon svg {
    width: 22px;
    height: 22px;
    display: block;
  }

  .mobile-menu-link.active {
    background: rgba(30, 135, 214, 0.1);
    color: var(--blue-primary);
  }

  .mobile-menu-link.active .mobile-menu-icon {
    color: var(--blue-primary);
  }

  .mobile-menu-link--anchor {
    color: var(--text-primary);
  }

  .mobile-menu-link:hover,
  .mobile-menu-link:active {
    background: var(--bg-muted);
  }

  .mobile-menu-user {
    cursor: pointer;
  }

  .mobile-panel-modal {
    max-width: 100%;
    margin: 0;
    min-height: 100%;
    border-radius: 0;
  }

  .mobile-panel-modal .modal-body {
    padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px));
  }

  .toast {
    bottom: calc(80px + env(safe-area-inset-bottom, 0px));
  }

  .customer-order-card {
    background: var(--bg-muted);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px;
    margin-bottom: 10px;
  }

  .customer-order-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    gap: 8px;
  }

  .customer-order-card .order-id {
    font-weight: 800;
    color: var(--blue-primary);
    font-size: 0.9rem;
  }

  .profile-card {
    text-align: center;
    padding: 8px 0 20px;
  }

  .profile-card-photo {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 12px;
    border: 3px solid var(--blue-primary);
  }

  .profile-card .user-avatar-fallback {
    width: 88px;
    height: 88px;
    font-size: 2rem;
    margin: 0 auto 12px;
  }

  .plan-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 18px;
    margin-bottom: 12px;
    background: var(--bg-muted);
  }

  .plan-card.featured {
    border-color: var(--blue-primary);
    background: rgba(30, 135, 214, 0.06);
  }

  .plan-card h4 {
    font-size: 1rem;
    font-weight: 800;
    color: var(--blue-primary);
    margin-bottom: 4px;
  }

  .plan-card .plan-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--orange);
    margin: 8px 0;
  }

  .plan-card ul {
    list-style: none;
    font-size: 0.85rem;
    color: var(--text-secondary);
  }

  .plan-card li {
    padding: 4px 0;
  }

  .plan-card li::before {
    content: '✓ ';
    color: var(--success);
    font-weight: 700;
  }

  .info-block {
    background: var(--bg-muted);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
  }

  .info-block h4 {
    color: var(--text-primary);
    font-weight: 700;
    margin-bottom: 8px;
  }

  .header-top-inner {
    flex-wrap: nowrap;
    gap: 12px;
    padding: 10px 16px;
  }

  .header-filters-inner {
    padding: 12px 16px;
    gap: 10px;
  }

  .banner-slide--image img {
    aspect-ratio: 1.6 / 1;
  }

  .banner-nav {
    display: none;
  }

  .banner-dots {
    padding: 8px 0 10px;
  }

  .header-filters .location-filter {
    flex: 1 1 auto;
  }

  .logo-img {
    height: 48px;
    max-width: 140px;
  }

  .header-actions {
    margin-left: auto;
    width: auto;
    flex-shrink: 0;
    gap: 8px;
  }

  .location-bar {
    gap: 10px;
    padding: 0 12px;
    min-height: 44px;
  }

  .location-label {
    display: none;
  }

  .location-info {
    flex-wrap: nowrap;
    overflow: hidden;
  }

  .location-radius {
    display: none;
  }

  .categories-carousel {
    margin-left: -16px;
    margin-right: -16px;
    padding: 0 16px;
  }

  .primary-filters,
  .more-filters-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .filter-field select {
    padding: 10px 28px 10px 10px;
    font-size: 0.82rem;
  }

  .listings-header {
    flex-direction: column;
    align-items: stretch;
  }

  .listings-toolbar {
    width: 100%;
    justify-content: space-between;
  }

  .toolbar-field {
    flex: 1;
    min-width: 0;
  }

  .toolbar-field select {
    width: 100%;
    min-width: 0;
  }

  .btn-view-listing {
    padding: 7px 12px;
    font-size: 0.75rem;
  }

  .listings-table-wrap {
    overflow: visible;
    border: none;
    box-shadow: none;
    background: transparent;
  }

  .listings-table {
    display: block;
    table-layout: auto;
  }

  .listings-table thead {
    display: none;
  }

  .listings-table tbody {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .listings-table-row {
    display: block;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    box-shadow: var(--shadow);
    padding: 14px;
  }

  .listings-table-row:hover {
    background: var(--bg-card);
  }

  .listings-table-row td {
    display: block;
    padding: 0;
    border: none;
    width: auto;
  }

  .table-product-cell {
    width: auto;
    margin-bottom: 10px;
  }

  .table-total-cell {
    text-align: left;
    margin-bottom: 10px;
  }

  .table-total-cell::before {
    content: 'Preço: ';
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.82rem;
  }

  .table-action-cell {
    text-align: left;
  }

  .table-action-cell .btn-view-listing {
    display: block;
    width: 100%;
    text-align: center;
  }

  .store-context-banner {
    flex-direction: column;
    align-items: stretch;
  }

  .store-context-banner-clear {
    width: 100%;
  }

  .nav-links .nav-btn:not(.primary) {
    display: none;
  }

  .logo {
    flex-shrink: 1;
    min-width: 0;
  }

  .user-greeting .user-text {
    display: none;
  }

  .user-dropdown {
    display: none !important;
  }

  .nav-links {
    width: auto;
  }

  .nav-btn {
    padding: 8px 12px;
    font-size: 0.78rem;
    white-space: nowrap;
  }

  /* Dashboard mobile */
  .header--dashboard .header-top-inner {
    flex-wrap: nowrap;
    overflow: hidden;
  }

  .header--dashboard .logo {
    flex: 0 1 auto;
    max-width: 45%;
  }

  .header--dashboard .logo-img {
    height: 44px;
    max-width: 100%;
    width: auto;
  }

  .header--dashboard .header-actions {
    flex: 0 1 auto;
    max-width: 55%;
    justify-content: flex-end;
  }

  .header--dashboard .user-greeting .user-text {
    display: block;
    font-size: 0.75rem;
    max-width: 90px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .user-dropdown {
    display: none !important;
  }

  .header--dashboard .user-greeting {
    gap: 6px;
    min-width: 0;
  }

  .header--dashboard .user-avatar-img,
  .header--dashboard .user-avatar-fallback {
    width: 34px;
    height: 34px;
  }

  .header--dashboard .nav-links {
    display: none;
  }

  .header-dashboard-inner {
    flex-direction: column;
    align-items: stretch;
    padding: 0 16px 14px;
    gap: 14px;
  }

  .header--dashboard .header-title {
    min-width: 0;
  }

  .header--dashboard .header-title h1 {
    font-size: 1.05rem;
  }

  .header--dashboard .header-title p {
    font-size: 0.72rem;
  }

  .header--dashboard .dashboard-stats {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .header--dashboard .stat-card {
    min-width: 0;
    padding: 10px 6px;
  }

  .header--dashboard .stat-card .number {
    font-size: 1.15rem;
  }

  .header--dashboard .stat-card .label {
    font-size: 0.58rem;
    line-height: 1.2;
  }

  .dashboard-main {
    padding: 16px 16px 40px;
    overflow-x: hidden;
  }

  .page-dashboard .tabs-scroll {
    margin-bottom: 16px;
    width: 100%;
    max-width: 100%;
  }

  .page-dashboard .tab {
    padding: 10px 12px;
    font-size: 0.8rem;
  }

  .page-dashboard .empty-state {
    padding-left: 0;
    padding-right: 0;
  }

  .dashboard-section-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .dashboard-section-tabs::-webkit-scrollbar {
    display: none;
  }

  .section-tab {
    white-space: nowrap;
    flex-shrink: 0;
    padding: 10px 16px;
    font-size: 0.88rem;
  }

  .catalog-item {
    grid-template-columns: auto 64px 1fr;
    gap: 10px;
    padding: 14px;
  }

  .catalog-item-check {
    padding-top: 20px;
  }

  .catalog-item-image {
    width: 64px;
    height: 64px;
  }

  .catalog-item-fields {
    grid-column: 1 / -1;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-end;
    min-width: 0;
    width: 100%;
    border-top: 1px solid var(--border);
    padding-top: 12px;
    margin-top: 4px;
  }

  .catalog-field {
    flex: 1;
    min-width: 90px;
  }

  .btn-save-product {
    flex: 1 1 100%;
  }

  .products-filter-chips {
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
    padding-bottom: 4px;
  }

  .products-filter-chips::-webkit-scrollbar {
    display: none;
  }

  .products-filter-chips .category-chip {
    flex-shrink: 0;
  }

  .product-detail-hero {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .product-detail-image {
    width: 160px;
    height: 160px;
  }

  .store-row {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .store-pricing {
    text-align: left;
    align-items: flex-start;
    min-width: 0;
    border-top: 1px solid var(--border);
    padding-top: 14px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .order-card-body {
    grid-template-columns: 1fr;
  }

  .listing-actions {
    flex-direction: column;
  }

  .listing-detail-actions {
    flex-direction: column;
  }

  .cart-item {
    grid-template-columns: 48px 1fr;
  }

  .cart-item-controls {
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* Standalone pages */
.auth-switch-link {
  margin-top: 16px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.auth-switch-link a {
  font-weight: 700;
}

.page-content {
  max-width: 720px;
}

.page-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin-bottom: 20px;
}

.page-back {
  margin-bottom: 12px;
}

.page-back a {
  font-size: 0.88rem;
  font-weight: 600;
}

.cart-footer--page {
  margin-top: 24px;
}

.checkout-page {
  max-width: 560px;
}

.product-page-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
}

.product-page-title {
  font-size: 1.35rem;
  font-weight: 800;
  margin: 8px 0 12px;
}

.product-page-category {
  font-size: 0.8rem;
  color: var(--blue-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.product-page-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.product-page-cart-link {
  text-align: center;
}

.menu-page-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.menu-page-link {
  display: block;
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
}

.menu-page-link:hover {
  border-color: var(--blue-primary);
  color: var(--blue-primary);
}

.alert-success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #15803d;
  padding: 12px 14px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 0.9rem;
  font-weight: 600;
}

.orders-tabs {
  margin-bottom: 16px;
}

.empty-state--compact {
  padding: 32px 16px;
}

.empty-state--compact .icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

.empty-state--compact h3 {
  font-size: 1rem;
}

.customer-order-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}

.customer-order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  gap: 8px;
}

.customer-order-card .order-id {
  font-weight: 800;
  color: var(--blue-primary);
  font-size: 0.9rem;
}

.btn-cancel-order {
  margin-top: 12px;
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius);
  border: 1px solid rgba(239, 68, 68, 0.35);
  background: rgba(239, 68, 68, 0.08);
  color: var(--danger);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  touch-action: manipulation;
}

.btn-cancel-order:hover {
  background: rgba(239, 68, 68, 0.14);
  border-color: var(--danger);
}

.customer-order-items {
  font-size: 0.85rem;
  margin: 6px 0 6px 18px;
  color: var(--text-primary);
}

.customer-order-store {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.customer-order-total {
  font-weight: 800;
  color: var(--orange);
}

.customer-order-meta,
.customer-order-date {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

a.btn-view-listing,
a.btn-buy-now {
  text-decoration: none;
  text-align: center;
}
