/* ============================================
   LAB13 — Design System | v1.1.0
   Apple-inspired, mobile-first, dark theme
   ============================================ */

/* ---------- Hide all scrollbars ---------- */
* { scrollbar-width: none !important; -ms-overflow-style: none !important; }
*::-webkit-scrollbar { display: none !important; }

/* ---------- CSS Variables ---------- */
:root {
  --crimson: #B52249;
  --crimson-dark: #3D0A1A;
  --crimson-light: #D4305E;
  --sand: #C9945A;
  --sand-light: #DAAD7A;
  --charcoal: #1A1A1A;
  --charcoal-light: #252525;
  --charcoal-lighter: #333333;
  --white: #F8F8F8;
  --gray-100: #F8F8F8;
  --gray-200: #D8D8D8;
  --gray-300: #D8D8D8;
  --gray-400: #888888;
  --gray-500: #888888;
  --gray-600: #555555;
  --gray-700: #222222;

  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;
  --spacing-4xl: 6rem;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.5);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.6);

  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;

  --container-max: 1200px;
  --nav-height: calc(160px + env(safe-area-inset-top, 0px));

  --surface:    #1A1A1A;
  --surface-2:  #252525;
  --surface-3:  #333333;
  --border:     #2A2A2A;
  --text:       #F8F8F8;
  --text-muted: #888888;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

html:not([data-page="stadium"]) {
  background-color: #1A1A1A; /* iOS overscroll area matches dark body */
}

body {
  font-family: var(--font-primary);
  background-color: var(--charcoal);
  color: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

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

ul, ol {
  list-style: none;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
  background: none;
  color: inherit;
}

button {
  cursor: pointer;
}

/* ---------- Typography ---------- */
h1 {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
}

h4 {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
}

p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--gray-300);
}

.text-sm {
  font-size: 0.875rem;
}

.text-xs {
  font-size: 0.75rem;
}

.text-lg {
  font-size: 1.125rem;
}

.text-crimson {
  color: var(--crimson);
}

.text-sand {
  color: var(--sand);
}

.text-muted {
  color: var(--gray-400);
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

.section {
  padding: var(--spacing-xl) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

.section-header h2 {
  margin-bottom: var(--spacing-sm);
}

.section-header p {
  max-width: 500px;
  margin: 0 auto;
}

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: auto;
  overflow: hidden;
  background: rgba(18, 18, 18, 0.3);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 1000;
  /* iOS safe area: extend nav behind the status bar */
  padding-top: env(safe-area-inset-top, 0px);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  height: auto;
  padding: 8px var(--spacing-lg);
  max-width: var(--container-max);
  margin: 0 auto;
  background: transparent;
}

.nav-logo {
  display: flex;
  align-items: center;
}

.nav-logo-img {
  height: 64px;
  width: auto;
}

.footer-logo-img {
  height: 56px;
  width: auto;
  margin-bottom: var(--spacing-sm);
}

.nav-links {
  display: none;
  gap: var(--spacing-xl);
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-300);
  transition: color var(--transition-fast);
  position: relative;
}

.nav-links a:hover {
  color: var(--white);
}

.nav-links a.active {
  color: var(--crimson);
}

.nav-links a.active::after {
  display: none;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  position: absolute;
  right: var(--spacing-lg);
}

.nav-cart {
  position: relative;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  transition: background var(--transition-fast);
}

.nav-cart:hover {
  background: var(--charcoal-lighter);
}

.nav-cart svg {
  width: 22px;
  height: 22px;
  stroke: var(--white);
}

.cart-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  background: var(--crimson);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  align-items: center;
  justify-content: center;
  display: none;
}

.cart-badge.show {
  display: flex;
}

/* Cart inside nav-inner (mobile only) */
.nav-cart-inner {
  display: none;
}

/* Mobile menu toggle */
.nav-toggle {
  width: 40px;
  height: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: var(--radius-full);
  transition: background var(--transition-fast);
}

.nav-toggle:hover {
  background: var(--charcoal-lighter);
}

.nav-toggle span {
  width: 18px;
  height: 1px;
  background: var(--white);
  border-radius: 1px;
  transition: var(--transition-base);
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(4.5px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  transform: translateY(-4.5px) rotate(-45deg);
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26, 26, 26, 0.98);
  z-index: 999;
  display: flex;
  flex-direction: column;
  padding: var(--spacing-md) var(--spacing-lg);
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu.open {
  transform: translateY(0);
  opacity: 1;
}

.mobile-menu a {
  font-size: 1.5rem;
  font-weight: 600;
  padding: 10px 0;
  transition: color var(--transition-fast);
}

.mobile-menu a:hover,
.mobile-menu a.active {
  color: var(--crimson);
}

.mobile-theme-btn {
  display: none;
  margin-top: auto;
  padding: 10px 0;
  width: 24px;
  height: 24px;
  color: var(--gray-400);
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
}
.mobile-theme-btn svg {
  width: 22px;
  height: 22px;
  stroke: var(--gray-400);
  display: block;
}

@media (max-width: 639px) {
  .mobile-theme-btn { display: block; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: 14px 28px;
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: 0.9375rem;
  transition: all var(--transition-base);
  white-space: nowrap;
  min-height: 48px;
}

.btn-primary {
  background: var(--crimson);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--crimson-light);
  transform: scale(1.02);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: transparent;
  color: var(--white);
  border: 1.5px solid rgba(255,255,255,0.2);
}

.btn-secondary:hover {
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.05);
}

.btn-sand {
  background: var(--sand);
  color: var(--charcoal);
}

.btn-sand:hover {
  background: var(--sand-light);
  transform: scale(1.02);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 0.8125rem;
  min-height: 40px;
}

.btn-lg {
  padding: 16px 36px;
  font-size: 1rem;
}

.btn-block {
  width: 100%;
}

.btn-icon {
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: var(--radius-full);
}

/* ---------- Cards ---------- */
.card {
  background: var(--charcoal-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.card-img {
  width: calc(100% - 20px);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: transparent;
  margin: 10px 10px 0;
  border-radius: var(--radius-md);
}

.card-body {
  padding: 12px 14px 14px;
  flex: 1;
}

.card-title {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.card-price {
  font-size: 1rem;
  font-weight: 700;
  color: var(--crimson);
}

.card-price span {
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--gray-400);
  margin-left: 2px;
}

/* Product Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-md);
}

#featured-grid,
#stadium-featured-grid,
#bylab13-featured-grid {
  grid-template-columns: repeat(auto-fit, minmax(160px, 260px));
  justify-content: center;
}

/* ---------- Category Tabs ---------- */
.category-tabs {
  display: flex;
  gap: var(--spacing-sm);
  overflow-x: auto;
  padding-bottom: var(--spacing-sm);
  scrollbar-width: none;
  -ms-overflow-style: none;
  margin-bottom: var(--spacing-xl);
}

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

.category-tab {
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
  background: var(--charcoal-light);
  color: var(--gray-300);
  transition: all var(--transition-fast);
  min-height: 44px;
}

.category-tab:hover {
  background: var(--charcoal-lighter);
  color: var(--white);
}

.category-tab.active {
  background: var(--crimson);
  color: var(--white);
}

/* ---------- Hero Section ---------- */
.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-height);
  position: relative;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: 8px 16px;
  background: rgba(220, 20, 60, 0.15);
  border: 1px solid rgba(220, 20, 60, 0.3);
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--crimson-light);
  margin-bottom: var(--spacing-lg);
}

.hero-tagline {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--gray-300);
  margin-bottom: var(--spacing-sm);
  line-height: 1.5;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: var(--spacing-md);
}

.hero h1 .highlight {
  color: var(--crimson);
}

.hero p {
  font-size: 1.0625rem;
  margin-bottom: var(--spacing-xl);
  max-width: 480px;
}

.hero-actions {
  display: flex;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

.hero-bg {
  position: absolute;
  top: 0;
  right: -20%;
  width: 70%;
  height: 100%;
  background: radial-gradient(circle at center, rgba(220, 20, 60, 0.08) 0%, transparent 70%);
  z-index: 1;
}

/* ---------- Category Cards ---------- */
.category-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-md);
}

.category-card {
  background: var(--charcoal-light);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  text-align: center;
  transition: all var(--transition-base);
  border: 1px solid transparent;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.category-card:hover {
  border-color: rgba(220, 20, 60, 0.3);
  transform: translateY(-2px);
}

.category-card .icon {
  font-size: 2rem;
  margin-bottom: var(--spacing-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--crimson);
  opacity: 0.85;
}
.category-card .icon svg {
  width: 36px;
  height: 36px;
}

.category-card h3 {
  font-size: 0.9375rem;
}

.category-card p {
  font-size: 0.8125rem;
}

/* ---------- CTA Section ---------- */
.cta-section {
  background: linear-gradient(135deg, rgba(220, 20, 60, 0.12) 0%, rgba(210, 180, 140, 0.08) 100%);
  border-radius: var(--radius-xl);
  padding: var(--spacing-3xl) var(--spacing-xl);
  text-align: center;
  border: 1px solid rgba(220, 20, 60, 0.15);
}

.cta-section h2 {
  margin-bottom: var(--spacing-md);
}

.cta-section p {
  margin-bottom: var(--spacing-xl);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Forms ---------- */
.form-group {
  margin-bottom: var(--spacing-lg);
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: var(--spacing-sm);
  color: var(--gray-300);
}

.form-input {
  width: 100%;
  padding: 14px 16px;
  background: var(--charcoal-light);
  border: 1.5px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  color: var(--white);
  font-size: 1rem;
  transition: border-color var(--transition-fast);
  min-height: 48px;
}

.form-input:focus {
  border-color: var(--crimson);
}

.form-input::placeholder {
  color: var(--gray-500);
}

textarea.form-input {
  resize: vertical;
  min-height: 120px;
}

select.form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%239E9E9E' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

/* iOS Toggle */
.site-toggle { position:relative; width:36px; height:20px; display:inline-block; flex-shrink:0; }
.site-toggle input { opacity:0; width:0; height:0; }
.site-toggle-slider { position:absolute; inset:0; background:var(--border); border-radius:20px; cursor:pointer; transition:background 0.2s; }
.site-toggle-slider::before { content:''; position:absolute; width:16px; height:16px; border-radius:50%; background:#fff; box-shadow:0 1px 4px rgba(0,0,0,0.35); top:2px; left:2px; transition:all 0.2s; }
.site-toggle input:checked + .site-toggle-slider { background:var(--crimson); }
.site-toggle input:checked + .site-toggle-slider::before { left:18px; }

/* File Upload */
.file-upload {
  border: 2px dashed rgba(255,255,255,0.15);
  border-radius: var(--radius-lg);
  padding: var(--spacing-2xl);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-base);
}

.file-upload:hover {
  border-color: var(--crimson);
  background: rgba(220, 20, 60, 0.05);
}

.file-upload svg {
  width: 40px;
  height: 40px;
  stroke: var(--gray-400);
  margin-bottom: var(--spacing-md);
}

.file-upload p {
  font-size: 0.875rem;
}

.file-upload .text-crimson {
  font-weight: 600;
}

/* ---------- Cart Items ---------- */
.cart-item {
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-lg);
  background: var(--charcoal-light);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-md);
}

.cart-item-img {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  background: var(--charcoal-lighter);
  flex-shrink: 0;
}

.cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.cart-item-name {
  font-weight: 600;
  font-size: 0.9375rem;
}

.cart-item-price {
  color: var(--crimson);
  font-weight: 700;
}

.cart-item-actions {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.qty-control {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  background: var(--charcoal-lighter);
  border-radius: var(--radius-full);
  padding: 4px;
}

.qty-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  font-size: 1.125rem;
  transition: background var(--transition-fast);
}

.qty-btn:hover {
  background: rgba(255,255,255,0.1);
}

.qty-value {
  width: 24px;
  text-align: center;
  font-weight: 600;
  font-size: 0.875rem;
}

.cart-remove {
  color: var(--gray-500);
  transition: color var(--transition-fast);
}

.cart-remove:hover {
  color: var(--crimson);
}

/* Cart Summary */
.cart-summary {
  background: var(--charcoal-light);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  margin-top: var(--spacing-xl);
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  font-size: 0.9375rem;
}

.cart-summary-row.total {
  border-top: 1px solid rgba(255,255,255,0.1);
  margin-top: var(--spacing-sm);
  padding-top: var(--spacing-md);
  font-size: 1.125rem;
  font-weight: 700;
}

.cart-summary-row.total .price {
  color: var(--crimson);
}

/* ---------- Order Summary ---------- */
.order-summary {
  background: var(--charcoal-light);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
}

.order-item {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  font-size: 0.875rem;
  color: var(--gray-300);
}

/* ---------- Empty State ---------- */
.empty-state {
  text-align: center;
  padding: var(--spacing-4xl) var(--spacing-xl);
}

.empty-state svg {
  width: 64px;
  height: 64px;
  stroke: var(--gray-500);
  margin-bottom: var(--spacing-lg);
}

.empty-state h3 {
  margin-bottom: var(--spacing-sm);
}

.empty-state p {
  margin-bottom: var(--spacing-xl);
}

/* ---------- Footer ---------- */
.footer {
  padding: var(--spacing-xl) 0 calc(var(--spacing-md) + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(255,255,255,0.06);
}

.footer-grid {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 60px;
  margin-bottom: var(--spacing-lg);
}

.footer-brand h3 {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-sm);
}

.footer-brand h3 span {
  color: var(--crimson);
}

.footer-brand p {
  font-size: 0.75rem;
  line-height: 2;
}

.footer-col h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-400);
  margin-bottom: var(--spacing-md);
  white-space: nowrap;
}

.footer-col a {
  display: inline-block;
  font-size: 0.75rem;
  color: var(--gray-300);
  padding: var(--spacing-xs) 0;
  transition: color var(--transition-fast);
}

.footer-col a:hover {
  color: var(--white);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--spacing-md);
  border-top: 1px solid rgba(255,255,255,0.06);
  font-size: 0.8125rem;
  color: var(--gray-500);
}

/* ---------- Page Header ---------- */
.page-header {
  padding-top: calc(var(--nav-height) + var(--spacing-xl));
  padding-bottom: var(--spacing-2xl);
}

.page-header h1 {
  margin-bottom: var(--spacing-sm);
}

/* ---------- Stadium Page Background ---------- */
body.page-stadium {
  background: #000;
}

/* Desktop/tablet: pseudo-element background (works fine) */
body.page-stadium::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url('../images/stadium-bg-2.jpg');
  background-size: cover;
  background-position: center bottom;
  filter: brightness(0.55);
  z-index: -1;
}

/* Mobile Stadium: position:sticky freeze — the only approach with zero lag on iOS Safari.
   sticky is handled entirely by the browser compositor (no JS, no animation, no repaint).
   The element starts at page y=0; top:120px holds it at viewport y=120 for all scroll positions.
   margin-bottom:-100lvh collapses layout space so content starts at page y=0.
   isolation:isolate on body keeps z-index:-1 behind all content. */
.stadium-bg-layer { display: none; }
@media (max-width: 639px) {
  html[data-page="stadium"] {
    background-color: #111;
  }

  .stadium-bg-layer {
    display: block !important;
    position: sticky;
    top: 60px;
    width: 100%;
    height: 100lvh;
    margin-bottom: -100lvh;
    background-image: url('../images/stadium-bg-mobile-v5.jpg');
    background-size: 160%;
    background-position: center 100%;
    background-repeat: no-repeat;
    filter: brightness(0.4);
    z-index: -1;
    pointer-events: none;
  }

  /* Body: isolated stacking context so bg-layer z-index:-1 stays behind content */
  body.page-stadium {
    position: relative !important;
    isolation: isolate !important;
  }

  /* Hide desktop pseudo-element */
  body.page-stadium::before { display: none !important; }

  /* Body transparent */
  body.page-stadium,
  [data-theme="dark"] body.page-stadium,
  [data-theme="light"] body.page-stadium {
    background: transparent !important;
  }

  /* Sections/hero/footer transparent so html background shows through */
  body.page-stadium .hero,
  body.page-stadium .section,
  body.page-stadium footer,
  body.page-stadium .footer,
  body.page-stadium .footer-grid,
  body.page-stadium .footer-bottom {
    background: transparent !important;
  }

  /* Match body bg to nav color so safe area blends seamlessly */
  body.page-stadium { background: #333333 !important; }

  /* Nav: always dark regardless of theme */
  body.page-stadium .nav {
    background: rgba(26, 26, 26, 0.5) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    backdrop-filter: blur(20px) !important;
  }
  body.page-stadium .nav-toggle span { background: #fff !important; }
  body.page-stadium .nav-cart svg { stroke: #fff !important; }

  /* Cards — match desktop stadium style */
  body.page-stadium .card {
    background: rgba(35, 22, 22, 0.55) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    -webkit-backdrop-filter: blur(6px) !important;
    backdrop-filter: blur(6px) !important;
  }
  body.page-stadium .card-title,
  body.page-stadium .card-price,
  body.page-stadium .card-body p {
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.95), 0 0 16px rgba(0, 0, 0, 0.7) !important;
    color: #fff !important;
  }
  body.page-stadium .card-price {
    color: var(--crimson) !important;
  }

  /* Footer text readable */
  body.page-stadium footer .footer-col a,
  body.page-stadium footer .footer-col h4,
  body.page-stadium footer .footer-bottom,
  body.page-stadium footer .footer-bottom div {
    color: rgba(255, 255, 255, 0.6) !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
  }
  body.page-stadium footer {
    border-top-color: rgba(255, 255, 255, 0.08) !important;
    padding-bottom: env(safe-area-inset-bottom, 8px) !important;
  }
  body.page-stadium footer a[href*="instagram"],
  body.page-stadium footer a[href*="contact"] {
    color: var(--crimson) !important;
  }
}

/* Mobile light mode: match desktop light mode exactly */
@media (max-width: 639px) {
  /* html/body: white background (same as desktop [data-theme="light"] body.page-stadium { background:#fff }) */
  [data-theme="light"] html[data-page="stadium"] {
    background-color: #fff !important;
  }

  /* bg-layer: faded stadium watermark — matches desktop ::before (brightness:1.5, opacity:0.25) */
  [data-theme="light"] .stadium-bg-layer {
    background-image: linear-gradient(rgba(242,232,230,0.75), rgba(242,232,230,0.75)), url('../images/stadium-bg-mobile-v5.jpg') !important;
    background-size: 160% !important;
    background-position: center 40% !important;
    filter: none !important;
    opacity: 1 !important;
  }

  /* Nav: light (remove dark override — let global light mode nav apply) */
  [data-theme="light"] body.page-stadium .nav {
    background: rgba(242, 232, 230, 1) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    backdrop-filter: blur(20px) !important;
  }
  [data-theme="light"] body.page-stadium .nav-links a {
    color: var(--gray-300) !important;
  }
  [data-theme="light"] body.page-stadium .nav-toggle span {
    background: #111 !important;
  }
  [data-theme="light"] body.page-stadium .nav-cart svg {
    stroke: #111 !important;
  }

  /* Mobile menu: light */
  [data-theme="light"] body.page-stadium .mobile-menu {
    background: rgba(240, 240, 240, 0.99) !important;
  }
  [data-theme="light"] body.page-stadium .mobile-menu a {
    color: #111 !important;
  }

  /* Cards: light gray (matches desktop light mode) */
  [data-theme="light"] body.page-stadium .card {
    background: rgba(242, 232, 230, 0.75) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
  [data-theme="light"] body.page-stadium .card-title,
  [data-theme="light"] body.page-stadium .card-body p {
    color: #111 !important;
    text-shadow: none !important;
  }
  [data-theme="light"] body.page-stadium .card-price {
    color: var(--crimson) !important;
    text-shadow: none !important;
  }

  /* Footer: dark text on light background */
  [data-theme="light"] body.page-stadium footer .footer-col a,
  [data-theme="light"] body.page-stadium footer .footer-col h4,
  [data-theme="light"] body.page-stadium footer .footer-bottom,
  [data-theme="light"] body.page-stadium footer .footer-bottom div {
    color: rgba(0, 0, 0, 0.6) !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
  }
  [data-theme="light"] body.page-stadium footer {
    border-top-color: rgba(0, 0, 0, 0.1) !important;
  }
  [data-theme="light"] body.page-stadium footer a[href*="instagram"],
  [data-theme="light"] body.page-stadium footer a[href*="contact"] {
    color: var(--crimson) !important;
  }
}

/* Desktop/tablet-only stadium overrides (>= 640px) */
@media (min-width: 640px) {
  body.page-stadium .section {
    background: transparent;
  }
  body.page-stadium .page-header {
    background: transparent;
  }
  body.page-stadium .card {
    background: rgba(30, 5, 10, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  body.page-stadium .card-img {
    background: transparent;
  }
  [data-theme="light"] body.page-stadium .card {
    background: rgba(232, 232, 232, 0.75);
    border: 1px solid rgba(0, 0, 0, 0.08);
  }
  [data-theme="light"] body.page-stadium {
    background: #fff;
  }
  [data-theme="light"] body.page-stadium::before {
    filter: brightness(1.5);
    opacity: 0.25;
  }
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  display: flex;
  gap: var(--spacing-sm);
  font-size: 0.8125rem;
  color: var(--gray-400);
  margin-bottom: var(--spacing-lg);
}

.breadcrumb a:hover {
  color: var(--white);
}

.breadcrumb .sep {
  color: var(--gray-600);
}

/* ---------- Success Message ---------- */
.success-message {
  background: rgba(46, 125, 50, 0.15);
  border: 1px solid rgba(46, 125, 50, 0.3);
  border-radius: var(--radius-lg);
  padding: var(--spacing-2xl);
  text-align: center;
}

.success-message svg {
  width: 48px;
  height: 48px;
  stroke: #4CAF50;
  margin-bottom: var(--spacing-md);
}

.success-message h2 {
  margin-bottom: var(--spacing-sm);
}

/* ---------- WhatsApp Button ---------- */
.btn-whatsapp {
  background: #25D366;
  color: var(--white);
}

.btn-whatsapp:hover {
  background: #20BD5A;
  transform: scale(1.02);
}

/* ---------- Toast Notification ---------- */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--charcoal-lighter);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--white);
  padding: 14px 24px;
  border-radius: var(--radius-lg);
  font-size: 0.875rem;
  font-weight: 500;
  z-index: 2000;
  transition: transform var(--transition-base);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

.toast svg {
  width: 18px;
  height: 18px;
  stroke: #4CAF50;
}

/* ---------- Responsive ---------- */
@media (max-width: 639px) {
  :root { --nav-height: calc(110px + env(safe-area-inset-top, 0px)); }

  .brand-tabs { gap: 10px !important; }
  .brand-logo-active  { height: 66px !important; }
  .brand-logo-inactive { height: 40px !important; }

  /* 60% transparent nav on mobile */
  .nav { background: rgba(26, 26, 26, 0.5); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
  [data-theme="light"] .nav { background: rgba(242, 232, 230, 0.5) !important; backdrop-filter: blur(20px) !important; -webkit-backdrop-filter: blur(20px) !important; }

  /* Hide brand-row cart+theme on mobile — cart moves to nav-inner row */
  .nav-brand-cart { display: none !important; }

  /* Nav-inner on mobile: hamburger LEFT, cart RIGHT */
  .nav-inner {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    padding: 6px 12px;
  }

  /* Full-width strip: hamburger LEFT, cart RIGHT */
  .nav-actions {
    position: static;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .nav-cart-inner { display: flex !important; }

  /* Hide theme btn from nav on mobile — it lives in burger menu */
  .nav-theme-btn { display: none !important; }

}

@media (min-width: 640px) and (max-width: 1023px) {
  :root { --nav-height: calc(160px + env(safe-area-inset-top, 0px)); }

  .brand-tabs { gap: 65px !important; }

  .nav-links { display: flex; }
  .nav-toggle { display: none; }
  .nav-cart-inner { display: none !important; }
}

@media (min-width: 640px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .category-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 768px) {
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }

  .hero h1 { font-size: 3.5rem; }

  .footer-grid {
    gap: var(--spacing-xl);
  }

  .cart-item-img {
    width: 100px;
    height: 100px;
  }
}

@media (min-width: 1024px) {
  :root {
    --nav-height: calc(160px + env(safe-area-inset-top, 0px));
  }

  .nav-logo-img {
    height: 90px;
  }

  .footer-logo-img {
    height: 72px;
  }

  .nav-links {
    display: flex;
  }

  .nav-toggle {
    display: none;
  }

  .nav-cart-inner {
    display: none !important;
  }

  h1 { font-size: 3rem; }

  .hero h1 { font-size: 4rem; }

  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .checkout-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: var(--spacing-2xl);
    align-items: start;
  }

  .product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-2xl);
    align-items: start;
  }

  .footer-grid {
    grid-template-columns: 2fr 1fr;
  }
}

/* ============================================================
   Light Mode
   ============================================================ */

[data-theme="light"] {
  --charcoal: #f2e8e6;
  --charcoal-light: #eadbd8;
  --charcoal-lighter: #deccca;
  --white: #111111;
  --gray-100: #111111;
  --gray-200: #222222;
  --gray-300: #444444;
  --gray-400: #666666;
  --gray-500: #888888;
  --gray-600: #aaaaaa;
  --gray-700: #dddddd;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.15);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.2);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.25);
}

[data-theme="light"] html {
  background-color: #f2e8e6; /* iOS overscroll area matches light body */
}

[data-theme="light"] body {
  background-color: var(--charcoal);
  color: var(--white);
}

[data-theme="light"] .nav {
  background: rgba(240, 240, 240, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

[data-theme="light"] .nav-brand-row {
  background: transparent;
}

[data-theme="light"] .nav-inner {
  background: transparent;
}

[data-theme="light"] .nav-links a { color: var(--gray-300); }
[data-theme="light"] .nav-links a:hover,
[data-theme="light"] .nav-links a.active { color: var(--crimson); }

[data-theme="light"] .nav-toggle span { background: var(--white); }

[data-theme="light"] .nav-cart svg { stroke: var(--white); }

[data-theme="light"] .mobile-menu {
  background: rgba(240,240,240,0.99);
}


[data-theme="light"] .form-input {
  background: var(--charcoal-light);
  border-color: rgba(0,0,0,0.15);
  color: var(--white);
}

[data-theme="light"] .footer {
  border-top-color: rgba(0,0,0,0.1);
}

[data-theme="light"] .footer-bottom {
  border-top-color: rgba(0,0,0,0.1);
}

[data-theme="light"] .cart-summary-row.total {
  border-top-color: rgba(0,0,0,0.1);
}

[data-theme="light"] .qty-btn:hover {
  background: rgba(0,0,0,0.06);
}

[data-theme="light"] .toast {
  border-color: rgba(0,0,0,0.1);
}

[data-theme="light"] p { color: var(--gray-300); }

[data-theme="light"] .btn-secondary {
  border-color: rgba(0,0,0,0.25);
  color: var(--white);
}
[data-theme="light"] .btn-secondary:hover {
  border-color: rgba(0,0,0,0.45);
  background: rgba(0,0,0,0.05);
}
[data-theme="light"] .card .btn-primary:hover,
[data-theme="light"] .card .btn-secondary:hover {
  border-color: var(--crimson);
  color: var(--crimson);
}
[data-theme="light"] .card .btn-primary:hover {
  background: var(--crimson);
  color: #fff;
}

/* ── Keep white text on red/crimson backgrounds in light mode ── */
[data-theme="light"] .btn-primary,
[data-theme="light"] .category-tab.active,
[data-theme="light"] .cart-badge { color: #F8F8F8 !important; }

/* iOS-style toggle switch (used in customize modals) */
.ios-sm { position:relative; display:inline-block; width:38px; height:22px; flex-shrink:0; }
.ios-sm input { opacity:0; width:0; height:0; position:absolute; }
.ios-sm-track { position:absolute; inset:0; background:rgba(255,255,255,0.15); border-radius:999px; transition:background 0.25s; cursor:pointer; }
.ios-sm-track::after { content:''; position:absolute; top:3px; left:3px; width:16px; height:16px; border-radius:50%; background:#fff; transition:transform 0.25s; box-shadow:0 1px 3px rgba(0,0,0,0.4); }
.ios-sm input:checked + .ios-sm-track { background:var(--crimson,#8b0000); }
.ios-sm input:checked + .ios-sm-track::after { transform:translateX(16px); }
/* ios-sm OFF track is rgba(white,0.15) = invisible in light mode */
[data-theme="light"] .ios-sm-track { background: rgba(0,0,0,0.2); }

/* Theme toggle button in customer nav */
.nav-theme-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  transition: background var(--transition-fast);
  color: var(--white);
}

.nav-theme-btn:hover {
  background: var(--charcoal-lighter);
}

.nav-theme-btn svg {
  width: 20px;
  height: 20px;
  stroke: var(--white);
}

/* ── Brand Tab Switcher ─────────────────────────── */
.nav-brand-row {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  position: relative;
  padding: 0 var(--spacing-lg);
  background: transparent;
}

.brand-tabs {
  display: flex;
  flex-wrap: nowrap;
  align-items: flex-end;
  gap: 65px;
}

.brand-tab {
  display: flex;
  align-items: center;
  padding: 8px 0 12px;
  cursor: pointer;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  margin-bottom: 0;
  transition: opacity 0.2s;
}

.brand-tab.active {
  border-bottom: 1px solid var(--crimson);
}

.brand-tab.inactive {
  opacity: 0.25;
}

.brand-tab.inactive:hover {
  opacity: 0.6;
}

.brand-logo-active  { height: 100px; width: auto; display: block; max-width: 300px; }
.brand-logo-inactive { height: 75px; width: auto; display: block; max-width: 300px; }

.nav-brand-cart {
  position: absolute;
  right: var(--spacing-lg);
  bottom: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

/* ── Shared Form Styles ─────────────────────────── */
.brand-form { max-width: 480px; }

.form-group { margin-bottom: var(--spacing-lg); }

.form-input {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  color: var(--text);
  font-size: 0.95rem;
  font-family: var(--font-primary);
  box-sizing: border-box;
}

.form-input:focus {
  outline: none;
  border-color: var(--crimson);
}

.form-select-btn {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  color: var(--text);
  font-size: 0.95rem;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.size-options { display: flex; gap: var(--spacing-sm); flex-wrap: wrap; }

.size-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm) var(--spacing-md);
  color: var(--text);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: border-color 0.15s;
}

.size-btn.active {
  border-color: var(--crimson);
  color: var(--crimson);
}

.size-price { font-size: 0.75rem; color: var(--text-muted); }

/* ── Upload Area ─────────────────────────────────── */
.upload-area {
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.upload-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-xl);
  cursor: pointer;
  color: var(--text-muted);
  text-align: center;
  transition: background 0.15s;
}

.upload-placeholder:hover { background: var(--surface-2); }

.upload-preview { position: relative; }

.upload-preview img {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  display: block;
}

.remove-photo {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  background: rgba(0,0,0,0.6);
  border: none;
  color: #fff;
  border-radius: var(--radius-sm);
  padding: 4px 8px;
  font-size: 0.75rem;
  cursor: pointer;
}

/* ── Popup Sheet ─────────────────────────────────── */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 200;
}

.popup-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--surface);
  border-radius: 16px 16px 0 0;
  padding: var(--spacing-lg);
  z-index: 201;
  max-height: 60vh;
  overflow-y: auto;
}

.popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-md);
}

.popup-title { font-weight: 600; font-size: 1rem; }

.popup-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  padding: 4px 8px;
}

.popup-options {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.popup-option {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  color: var(--text);
  font-size: 0.95rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s;
}

.popup-option:hover { background: var(--surface-3); }

/* ── Modal Overlay (used by By.LAB13 customize modal) ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.active {
  display: flex;
}
.modal-overlay .modal {
  background: var(--charcoal-light);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

/* Product Video Player */
.product-video {
  width: 100%;
  border-radius: var(--radius-lg);
  background: var(--charcoal-light);
  display: block;
  margin-bottom: 12px;
  aspect-ratio: 9/16;
  object-fit: cover;
}
[data-theme="light"] .product-video {
  background: #e8e8e8;
}
