/* ==========================================================================
   PYB ELECTRONICS & LUXURY STORE - DESIGN SYSTEM
   Modern, Ultra-Premium Dark Theme with Glassmorphism and Micro-Animations
   ========================================================================== */

:root {
  /* Color Palette */
  --bg-primary: #0a0c10;
  --bg-secondary: #12161f;
  --bg-tertiary: #191e2b;
  --bg-card: rgba(22, 27, 38, 0.75);
  --bg-card-hover: rgba(28, 35, 49, 0.95);
  --bg-glass: rgba(18, 22, 31, 0.7);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(229, 169, 124, 0.3);
  --border-focus: #e5a97c;

  /* Brand Accents */
  --gold-primary: #e5a97c;
  --gold-hover: #f0bc94;
  --gold-dark: #b87c50;
  --gold-glow: rgba(229, 169, 124, 0.25);
  
  --cyan-primary: #38bdf8;
  --cyan-hover: #7dd3fc;
  --cyan-glow: rgba(56, 189, 248, 0.25);

  --emerald-primary: #10b981;
  --emerald-glow: rgba(16, 185, 129, 0.25);

  --rose-primary: #f43f5e;
  --amber-primary: #f59e0b;

  /* Typography Colors */
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --text-inverse: #0a0c10;

  /* UI Tokens */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 25px var(--gold-glow);
  --shadow-cyan-glow: 0 0 25px var(--cyan-glow);

  /* Fonts */
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-display: 'Outfit', sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;

  --transition-fast: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 15% 15%, rgba(56, 189, 248, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 85% 35%, rgba(229, 169, 124, 0.05) 0%, transparent 45%),
    radial-gradient(circle at 50% 80%, rgba(16, 185, 129, 0.03) 0%, transparent 40%);
  background-attachment: fixed;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-primary);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-dark);
}

/* Utility Containers */
.container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Top Announcement Bar (Promotions) */
.promo-bar {
  background: linear-gradient(90deg, #111827 0%, #1c1917 50%, #111827 100%);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.55rem 1rem;
  font-size: 0.82rem;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.25rem;
  position: relative;
  z-index: 60;
}

.promo-bar-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}

.promo-tag {
  background: var(--gold-primary);
  color: #000;
  font-weight: 800;
  font-size: 0.7rem;
  padding: 0.15rem 0.6rem;
  border-radius: var(--radius-full);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  animation: pulse-gold 2s infinite;
}

.countdown-box {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  font-family: monospace;
  font-weight: 700;
  color: var(--gold-primary);
  background: rgba(0, 0, 0, 0.4);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(229, 169, 124, 0.2);
}

@keyframes pulse-gold {
  0%, 100% { box-shadow: 0 0 0 0 rgba(229, 169, 124, 0.4); }
  50% { box-shadow: 0 0 0 6px rgba(229, 169, 124, 0); }
}

/* Navigation Header */
.main-header {
  position: sticky;
  top: 0;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 50;
  transition: all var(--transition-smooth);
}

.main-header.scrolled {
  background: rgba(10, 12, 16, 0.95);
  box-shadow: var(--shadow-sm);
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4.75rem;
  gap: 1.5rem;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--text-main);
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-badge {
  background: linear-gradient(135deg, var(--gold-primary), var(--cyan-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.brand-icon-box {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #1e2533, #151a24);
  border: 1px solid var(--border-highlight);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-primary);
  box-shadow: 0 4px 15px rgba(229, 169, 124, 0.15);
}

/* Nav Links & Controls */
.nav-links {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  list-style: none;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.92rem;
  transition: color var(--transition-fast);
  position: relative;
  padding: 0.25rem 0;
}

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gold-primary);
  border-radius: var(--radius-full);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

/* Search Bar in Header */
.search-wrapper {
  position: relative;
  width: 280px;
  display: flex;
  align-items: center;
}

.search-input {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.55rem 1rem 0.55rem 2.6rem;
  color: var(--text-main);
  font-size: 0.88rem;
  outline: none;
  transition: all var(--transition-fast);
}

.search-input:focus {
  border-color: var(--gold-primary);
  background: var(--bg-tertiary);
  box-shadow: 0 0 15px rgba(229, 169, 124, 0.2);
}

.search-icon {
  position: absolute;
  left: 0.9rem;
  color: var(--text-dim);
  pointer-events: none;
  font-size: 0.95rem;
}

/* Icon Buttons */
.icon-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: all var(--transition-fast);
}

.icon-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--border-highlight);
  color: var(--gold-primary);
  transform: translateY(-2px);
}

.badge-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--gold-primary);
  color: #000;
  font-weight: 800;
  font-size: 0.72rem;
  min-width: 20px;
  height: 20px;
  padding: 0 4px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

/* Hero Section */
.hero-section {
  position: relative;
  padding: 4.5rem 0 3rem;
  overflow: hidden;
}

.hero-glow-1 {
  position: absolute;
  top: -100px;
  left: 10%;
  width: 450px;
  height: 450px;
  background: radial-gradient(circle, rgba(229, 169, 124, 0.12), transparent 70%);
  filter: blur(80px);
  pointer-events: none;
}

.hero-glow-2 {
  position: absolute;
  top: 50px;
  right: 5%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.1), transparent 70%);
  filter: blur(80px);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 3.5rem;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(229, 169, 124, 0.1);
  border: 1px solid rgba(229, 169, 124, 0.25);
  color: var(--gold-primary);
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
}

.hero-title-highlight {
  background: linear-gradient(135deg, #ffffff 30%, var(--gold-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 540px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
  color: #000;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: all var(--transition-smooth);
  box-shadow: 0 4px 20px rgba(229, 169, 124, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(229, 169, 124, 0.45);
  filter: brightness(1.05);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--border-highlight);
  color: var(--gold-primary);
}

.hero-stats {
  display: flex;
  gap: 2rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
}

.stat-item h4 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
}
.stat-item p {
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Featured Hero Showcase Card */
.hero-card-preview {
  background: linear-gradient(145deg, rgba(25, 30, 43, 0.8), rgba(15, 18, 25, 0.95));
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem;
  position: relative;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(12px);
  overflow: hidden;
}

.hero-card-preview::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold-primary), var(--cyan-primary), transparent);
}

/* Category Filter Tabs */
.filter-section {
  padding: 1rem 0 2rem;
  position: sticky;
  top: 4.75rem;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 40;
  border-bottom: 1px solid var(--border-subtle);
}

.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.category-tabs {
  display: flex;
  gap: 0.5rem;
  background: var(--bg-secondary);
  padding: 0.35rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  overflow-x: auto;
  scrollbar-width: none;
}
.category-tabs::-webkit-scrollbar { display: none; }

.cat-tab {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 0.55rem 1.25rem;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.cat-tab:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.cat-tab.active {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
  color: #000;
  box-shadow: 0 2px 10px rgba(229, 169, 124, 0.3);
}

.filter-controls {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.select-custom {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  padding: 0.55rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  outline: none;
  cursor: pointer;
  transition: border-color var(--transition-fast);
}

.select-custom:focus {
  border-color: var(--gold-primary);
}

/* Catalog Product Grid */
.catalog-section {
  padding: 2.5rem 0 4rem;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 2rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 0.25rem;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
}

/* Product Card */
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-smooth);
  position: relative;
  backdrop-filter: blur(8px);
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-highlight);
  background: var(--bg-card-hover);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5), 0 0 20px rgba(229, 169, 124, 0.12);
}

.product-image-box {
  position: relative;
  height: 240px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(0, 0, 0, 0.2));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  overflow: hidden;
  border-bottom: 1px solid var(--border-subtle);
}

.product-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform var(--transition-bounce);
}

.product-card:hover .product-img {
  transform: scale(1.08);
}

/* Badges on Card */
.badge-category {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(18, 22, 31, 0.85);
  border: 1px solid var(--border-subtle);
  color: var(--gold-primary);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  backdrop-filter: blur(4px);
}

.badge-stock {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-in-stock {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-low-stock {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-out-of-stock {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.badge-promo-tag {
  position: absolute;
  bottom: 0.75rem;
  left: 1rem;
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
}

/* Card Body */
.product-content {
  padding: 1.25rem 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-code {
  color: var(--text-dim);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  margin-bottom: 0.35rem;
  font-weight: 600;
}

.product-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.7rem;
}

.product-meta {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-bottom: 1rem;
}

.price-container {
  margin-top: auto;
  margin-bottom: 1.25rem;
}

.price-usd {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--gold-primary);
  font-family: var(--font-display);
}

.price-gs {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Card Buttons */
.card-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
}

.btn-add-cart {
  background: rgba(229, 169, 124, 0.15);
  border: 1px solid var(--gold-primary);
  color: var(--gold-primary);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.65rem 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.btn-add-cart:hover:not(:disabled) {
  background: var(--gold-primary);
  color: #000;
  box-shadow: 0 4px 15px rgba(229, 169, 124, 0.3);
}

.btn-add-cart:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  border-color: var(--border-subtle);
  color: var(--text-dim);
}

.btn-quick-view {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-quick-view:hover {
  background: var(--bg-tertiary);
  color: var(--text-main);
  border-color: var(--border-highlight);
}

/* Empty State / Loading State */
.empty-state {
  text-align: center;
  padding: 4rem 1rem;
  grid-column: 1 / -1;
  color: var(--text-dim);
}

.empty-state svg {
  margin-bottom: 1rem;
  color: var(--text-dim);
}

/* Loading Skeleton */
.skeleton-card {
  height: 380px;
  border-radius: var(--radius-lg);
  background: linear-gradient(90deg, #121620 25%, #1c2230 50%, #121620 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border: 1px solid var(--border-subtle);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Sliding Cart Drawer */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-smooth);
}

.drawer-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  max-width: 440px;
  height: 100vh;
  background: #0f131a;
  border-left: 1px solid var(--border-subtle);
  z-index: 101;
  display: flex;
  flex-direction: column;
  transition: right var(--transition-smooth);
  box-shadow: var(--shadow-lg);
}

.drawer-backdrop.active .cart-drawer {
  right: 0;
}

.drawer-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drawer-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.drawer-close-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}

.drawer-close-btn:hover {
  color: var(--text-main);
  background: var(--bg-tertiary);
}

.drawer-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Cart Items */
.cart-item {
  display: grid;
  grid-template-columns: 65px 1fr auto;
  gap: 1rem;
  align-items: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.75rem;
  position: relative;
  transition: border-color var(--transition-fast);
}

.cart-item:hover {
  border-color: var(--border-highlight);
}

.cart-item-img {
  width: 65px;
  height: 65px;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-sm);
  padding: 0.25rem;
}

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

.cart-item-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item-price {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold-primary);
}

.qty-control {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.15rem;
  margin-top: 0.35rem;
  width: fit-content;
}

.qty-btn {
  background: none;
  border: none;
  color: var(--text-main);
  width: 22px;
  height: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
}

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

.qty-count {
  font-size: 0.8rem;
  font-weight: 700;
  min-width: 18px;
  text-align: center;
}

.btn-remove-item {
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  padding: 0.4rem;
  transition: color var(--transition-fast);
}

.btn-remove-item:hover {
  color: var(--rose-primary);
}

/* Coupon & Totals in Cart Footer */
.drawer-footer {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.coupon-box {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.coupon-input {
  flex-grow: 1;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.5rem 0.85rem;
  font-size: 0.85rem;
  color: var(--text-main);
  text-transform: uppercase;
  outline: none;
}

.coupon-input:focus {
  border-color: var(--gold-primary);
}

.btn-apply-coupon {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-subtle);
  color: var(--gold-primary);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 0 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-apply-coupon:hover {
  background: var(--gold-primary);
  color: #000;
}

.active-coupon-tag {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
  font-size: 0.8rem;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 0.6rem;
  margin-top: 0.6rem;
  border-top: 1px dashed var(--border-subtle);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
}

.cart-total-usd {
  color: var(--gold-primary);
  font-family: var(--font-display);
}

.btn-checkout-wa {
  width: 100%;
  margin-top: 1.25rem;
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #fff;
  border: none;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.9rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  box-shadow: 0 4px 18px rgba(37, 211, 102, 0.3);
  transition: all var(--transition-smooth);
}

.btn-checkout-wa:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.45);
  filter: brightness(1.05);
}

/* Customer Checkout Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 150;
  opacity: 0;
  visibility: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  transition: all var(--transition-smooth);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-box {
  background: #11151e;
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  padding: 2rem;
  position: relative;
  transform: scale(0.95);
  transition: transform var(--transition-bounce);
}

.modal-backdrop.active .modal-box {
  transform: scale(1);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1rem;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
}

.form-group {
  margin-bottom: 1.15rem;
}

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.7rem 1rem;
  color: var(--text-main);
  font-size: 0.9rem;
  outline: none;
  transition: border-color var(--transition-fast);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--gold-primary);
}

/* Floating Customer Support Chat Widget */
.chat-widget-wrapper {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 90;
}

.chat-trigger-btn {
  width: 58px;
  height: 58px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
  color: #000;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 25px rgba(229, 169, 124, 0.4);
  transition: all var(--transition-bounce);
  position: relative;
}

.chat-trigger-btn:hover {
  transform: scale(1.08) rotate(-4deg);
  box-shadow: 0 12px 30px rgba(229, 169, 124, 0.55);
}

.chat-pulse-ring {
  position: absolute;
  inset: -4px;
  border-radius: var(--radius-full);
  border: 2px solid var(--gold-primary);
  animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.95); opacity: 1; }
  100% { transform: scale(1.35); opacity: 0; }
}

.chat-window {
  position: absolute;
  bottom: 70px;
  right: 0;
  width: 360px;
  max-width: 90vw;
  height: 500px;
  max-height: 75vh;
  background: #11151f;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.95);
  transition: all var(--transition-smooth);
}

.chat-widget-wrapper.open .chat-window {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.chat-header {
  background: linear-gradient(135deg, #181d29, #121620);
  border-bottom: 1px solid var(--border-subtle);
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chat-agent-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.agent-avatar {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--gold-primary), var(--cyan-primary));
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  position: relative;
}

.online-dot {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 10px;
  height: 10px;
  background: var(--emerald-primary);
  border: 2px solid #11151f;
  border-radius: var(--radius-full);
}

.agent-details h4 {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
}
.agent-details p {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.chat-messages {
  flex-grow: 1;
  padding: 1rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: rgba(10, 12, 16, 0.4);
}

.chat-bubble {
  max-width: 82%;
  padding: 0.65rem 0.95rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  line-height: 1.45;
}

.chat-bubble.bot {
  background: var(--bg-tertiary);
  color: var(--text-main);
  border-top-left-radius: 4px;
  align-self: flex-start;
  border: 1px solid var(--border-subtle);
}

.chat-bubble.user {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
  color: #000;
  font-weight: 500;
  border-top-right-radius: 4px;
  align-self: flex-end;
}

.quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.chip-btn {
  background: rgba(229, 169, 124, 0.1);
  border: 1px solid rgba(229, 169, 124, 0.3);
  color: var(--gold-primary);
  font-size: 0.75rem;
  padding: 0.3rem 0.65rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.chip-btn:hover {
  background: var(--gold-primary);
  color: #000;
}

.chat-footer {
  padding: 0.75rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
  display: flex;
  gap: 0.5rem;
}

.chat-input {
  flex-grow: 1;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.55rem 1rem;
  font-size: 0.85rem;
  color: var(--text-main);
  outline: none;
}

.chat-input:focus {
  border-color: var(--gold-primary);
}

.chat-send-btn {
  background: var(--gold-primary);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  color: #000;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast);
}

.chat-send-btn:hover {
  transform: scale(1.08);
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 2rem;
  left: 2rem;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  pointer-events: none;
}

.toast {
  background: #151a24;
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  padding: 0.8rem 1.25rem;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  box-shadow: var(--shadow-md);
  pointer-events: auto;
  animation: toast-in 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  max-width: 360px;
}

.toast.success {
  border-color: rgba(16, 185, 129, 0.4);
}
.toast.success .toast-icon { color: var(--emerald-primary); }

.toast.error {
  border-color: rgba(244, 63, 94, 0.4);
}
.toast.error .toast-icon { color: var(--rose-primary); }

@keyframes toast-in {
  from { opacity: 0; transform: translateY(12px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Footer */
.main-footer {
  border-top: 1px solid var(--border-subtle);
  background: #090b0e;
  padding: 4rem 0 2rem;
  margin-top: 5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 1rem;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: var(--text-main);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--gold-primary);
}

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-dim);
  font-size: 0.82rem;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .search-wrapper {
    width: 180px;
  }
  .filter-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .hero-stats {
    flex-direction: column;
    gap: 1rem;
  }
}

/* ==========================================================================
   PROMOTIONAL PRICING, MARGINS & USER MANAGEMENT EXTENSIONS
   ========================================================================== */

/* Promotional Price Display */
.price-box-promo {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.price-promo-usd {
  font-size: 1.4rem;
  font-weight: 800;
  color: #ef4444;
  font-family: var(--font-display);
}

.price-original-usd {
  text-decoration: line-through;
  color: var(--text-dim);
  font-size: 0.92rem;
  font-weight: 500;
}

.badge-discount-percent {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-sm);
}

/* Category Margin Rule Card in Admin */
.margins-rule-card {
  background: linear-gradient(145deg, rgba(22, 27, 38, 0.9), rgba(16, 20, 29, 0.95));
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.margins-rule-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.margins-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.margin-box {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.margin-input-group {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.margin-input {
  width: 70px;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  padding: 0.4rem 0.5rem;
  text-align: center;
}
.margin-input:focus {
  border-color: var(--gold-primary);
}

/* User Management Styles */
.user-badge-role {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.user-badge-superadmin {
  background: rgba(229, 169, 124, 0.15);
  color: var(--gold-primary);
  border: 1px solid rgba(229, 169, 124, 0.3);
}

.user-badge-operator {
  background: rgba(56, 189, 248, 0.15);
  color: var(--cyan-primary);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
}
.status-indicator.active { color: #34d399; }
.status-indicator.inactive { color: #fb7185; }

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.status-indicator.active .status-dot { background: #34d399; }
.status-indicator.inactive .status-dot { background: #fb7185; }
