/* ========================================
   FASHION E-COMMERCE - MEXICAN MARKET
   Design System & Global Styles
   ======================================== */

/* Import Modern Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

/* ========================================
   CSS CUSTOM PROPERTIES (Design Tokens)
   ======================================== */
:root {
  /* Mexican-Inspired Color Palette */
  --color-primary: #D4735E;
  /* Terracota suave */
  --color-primary-dark: #B85A47;
  --color-primary-light: #E89580;

  --color-secondary: #1A7B82;
  /* Turquesa profundo */
  --color-secondary-dark: #145B61;
  --color-secondary-light: #2A9BA3;

  --color-accent: #D4AF37;
  /* Dorado */
  --color-accent-dark: #B8941F;

  /* Neutrals */
  --color-dark: #1A1A1A;
  --color-gray-900: #2A2A2A;
  --color-gray-800: #3F3F3F;
  --color-gray-700: #595959;
  --color-gray-600: #737373;
  --color-gray-500: #8C8C8C;
  --color-gray-400: #A6A6A6;
  --color-gray-300: #C0C0C0;
  --color-gray-200: #E0E0E0;
  --color-gray-100: #F0F0F0;
  --color-white: #FFFFFF;

  /* Background */
  --bg-primary: #FFFFFF;
  --bg-secondary: #FAFAFA;
  --bg-dark: #1A1A1A;
  --bg-overlay: rgba(26, 26, 26, 0.85);

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  --gradient-secondary: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
  --gradient-accent: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
  --gradient-overlay: linear-gradient(180deg, rgba(26, 26, 26, 0.2) 0%, rgba(26, 26, 26, 0.7) 100%);

  /* Typography */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;

  --font-size-xs: 0.75rem;
  /* 12px */
  --font-size-sm: 0.875rem;
  /* 14px */
  --font-size-base: 1rem;
  /* 16px */
  --font-size-lg: 1.125rem;
  /* 18px */
  --font-size-xl: 1.25rem;
  /* 20px */
  --font-size-2xl: 1.5rem;
  /* 24px */
  --font-size-3xl: 1.875rem;
  /* 30px */
  --font-size-4xl: 2.25rem;
  /* 36px */
  --font-size-5xl: 3rem;
  /* 48px */
  --font-size-6xl: 3.75rem;
  /* 60px */

  --font-weight-light: 300;
  --font-weight-regular: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;

  /* Spacing */
  --spacing-xs: 0.25rem;
  /* 4px */
  --spacing-sm: 0.5rem;
  /* 8px */
  --spacing-md: 1rem;
  /* 16px */
  --spacing-lg: 1.5rem;
  /* 24px */
  --spacing-xl: 2rem;
  /* 32px */
  --spacing-2xl: 3rem;
  /* 48px */
  --spacing-3xl: 4rem;
  /* 64px */
  --spacing-4xl: 6rem;
  /* 96px */

  /* Border Radius */
  --radius-sm: 0.25rem;
  /* 4px */
  --radius-md: 0.5rem;
  /* 8px */
  --radius-lg: 0.75rem;
  /* 12px */
  --radius-xl: 1rem;
  /* 16px */
  --radius-2xl: 1.5rem;
  /* 24px */
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-base: 250ms ease-in-out;
  --transition-slow: 400ms ease-in-out;

  /* Z-index */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ========================================
   RESET & BASE STYLES
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-regular);
  line-height: 1.6;
  color: var(--color-dark);
  background-color: var(--bg-primary);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-weight-bold);
  line-height: 1.2;
  margin-bottom: var(--spacing-md);
  color: var(--color-dark);
}

h1 {
  font-size: var(--font-size-5xl);
}

h2 {
  font-size: var(--font-size-4xl);
}

h3 {
  font-size: var(--font-size-3xl);
}

h4 {
  font-size: var(--font-size-2xl);
}

h5 {
  font-size: var(--font-size-xl);
}

h6 {
  font-size: var(--font-size-lg);
}

p {
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-primary-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: var(--font-body);
  cursor: pointer;
  border: none;
  background: none;
  transition: all var(--transition-base);
}

input,
textarea,
select {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
}

ul,
ol {
  list-style: none;
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.container-sm {
  max-width: 720px;
}

.container-lg {
  max-width: 1440px;
}

.section {
  padding: var(--spacing-4xl) 0;
}

.section-sm {
  padding: var(--spacing-2xl) 0;
}

.section-lg {
  padding: 6rem 0;
}

.text-center {
  text-align: center;
}

.text-primary {
  color: var(--color-primary);
}

.text-secondary {
  color: var(--color-secondary);
}

.text-accent {
  color: var(--color-accent);
}

.text-muted {
  color: var(--color-gray-600);
}

.fw-light {
  font-weight: var(--font-weight-light);
}

.fw-regular {
  font-weight: var(--font-weight-regular);
}

.fw-medium {
  font-weight: var(--font-weight-medium);
}

.fw-semibold {
  font-weight: var(--font-weight-semibold);
}

.fw-bold {
  font-weight: var(--font-weight-bold);
}

.fw-extrabold {
  font-weight: var(--font-weight-extrabold);
}

.mb-0 {
  margin-bottom: 0;
}

.mb-sm {
  margin-bottom: var(--spacing-sm);
}

.mb-md {
  margin-bottom: var(--spacing-md);
}

.mb-lg {
  margin-bottom: var(--spacing-lg);
}

.mb-xl {
  margin-bottom: var(--spacing-xl);
}

.mb-2xl {
  margin-bottom: var(--spacing-2xl);
}

.mt-0 {
  margin-top: 0;
}

.mt-sm {
  margin-top: var(--spacing-sm);
}

.mt-md {
  margin-top: var(--spacing-md);
}

.mt-lg {
  margin-top: var(--spacing-lg);
}

.mt-xl {
  margin-top: var(--spacing-xl);
}

.mt-2xl {
  margin-top: var(--spacing-2xl);
}

/* ========================================
   HEADER & NAVIGATION
   ======================================== */
.header {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  transition: all var(--transition-base);
}

.header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md) var(--spacing-md);
  gap: var(--spacing-xl);
}

.logo {
  font-family: var(--font-heading);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-extrabold);
  color: var(--color-dark);
  letter-spacing: -0.02em;
}

.logo-accent {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-xl);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
}

.nav-link {
  font-family: var(--font-heading);
  font-weight: var(--font-weight-medium);
  font-size: var(--font-size-base);
  color: var(--color-dark);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  position: relative;
}

.nav-link:hover {
  color: var(--color-primary);
  background: rgba(212, 115, 94, 0.05);
}

.nav-link.active {
  color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 3px;
  background: var(--gradient-primary);
  border-radius: var(--radius-full);
}

.cart-button {
  position: relative;
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--gradient-primary);
  color: var(--color-white);
  border-radius: var(--radius-lg);
  font-weight: var(--font-weight-semibold);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
}

.cart-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.cart-button:active {
  transform: translateY(0);
}

.cart-count {
  background: var(--color-accent);
  color: var(--color-dark);
  border-radius: var(--radius-full);
  min-width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* Mobile Menu */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--spacing-sm);
  cursor: pointer;
}

.menu-toggle span {
  width: 24px;
  height: 3px;
  background: var(--color-dark);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(212, 115, 94, 0.15) 0%, transparent 70%);
  border-radius: 50%;
  animation: float 20s ease-in-out infinite;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -5%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(26, 123, 130, 0.12) 0%, transparent 70%);
  border-radius: 50%;
  animation: float 15s ease-in-out infinite reverse;
}

@keyframes float {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(-30px, 30px) scale(1.1);
  }
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 600px;
}

.hero-badge {
  display: inline-block;
  padding: var(--spacing-sm) var(--spacing-lg);
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212, 115, 94, 0.2);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--color-primary);
  margin-bottom: var(--spacing-lg);
  box-shadow: var(--shadow-sm);
}

.hero-title {
  font-size: var(--font-size-6xl);
  font-weight: var(--font-weight-extrabold);
  line-height: 1.1;
  margin-bottom: var(--spacing-lg);
  letter-spacing: -0.02em;
}

.hero-title .gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: var(--font-size-lg);
  color: var(--color-gray-700);
  margin-bottom: var(--spacing-2xl);
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

.hero-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;               /* responsive: en móvil se apila */
}

.hero-content {
  flex: 1;
  min-width: 300px;
  max-width: 600px;
}

.hero-image {
  flex: 1;
  min-width: 300px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative; /* keep hero background positioning */
  background-image: url('hero-bg.png');
  background-size: cover;
  background-position: center;
  border-radius: 16px;
  overflow: hidden;
}

.hero-bg-img {
  display: none; /* now used as fallback; actual slides will overlay */
}

/* Hero carousel overlayed on the background image */
.hero-carousel {
  width: 100%;
  max-width: 560px;
  height: 420px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
}

.carousel-track {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-slide {
  position: absolute;
  width: 88%;
  height: 86%;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.12);
  transition: opacity 400ms ease, transform 400ms ease;
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-slide.active {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  z-index: 2;
}

.carousel-slide.prev, .carousel-slide.next {
  opacity: 0.6;
  transform: translate(-50%, -50%) scale(0.98);
  z-index: 1;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.48);
  color: white;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0,0,0,0.28);
}

.carousel-prev { left: 8px; }
.carousel-next { right: 8px; }

.carousel-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: transform 200ms ease, background 200ms ease;
}

.carousel-dot.active { background: white; transform: scale(1.15); }

@media (max-width: 992px) {
  .hero-carousel { max-width: 420px; height: 320px; }
  .carousel-slide { width: 92%; height: 86%; }
}

@media (max-width: 480px) {
  .hero-carousel { max-width: 320px; height: 240px; }
  .carousel-btn { width: 36px; height: 36px; font-size: 1.25rem; }
}

/* Responsive: en pantallas pequeñas la imagen va arriba o abajo */
@media (max-width: 992px) {
  .hero-wrapper {
    flex-direction: column;
    text-align: center;
  }
  
  .hero-image {
    order: -1;   /* pone la imagen arriba en móvil si lo prefieres */
  }
}

/* ========================================
   BUTTONS
   ======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md) var(--spacing-xl);
  font-family: var(--font-heading);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
  cursor: pointer;
  border: none;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--color-white);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
  color: var(--color-white);
}

.btn-secondary {
  background: var(--gradient-secondary);
  color: var(--color-white);
  box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
  color: var(--color-white);
}

.btn-outline {
  background: transparent;
  color: var(--color-dark);
  border: 2px solid var(--color-dark);
}

.btn-outline:hover {
  background: var(--color-dark);
  color: var(--color-white);
}

.btn-ghost {
  background: transparent;
  color: var(--color-dark);
  border: 1px solid var(--color-gray-300);
}

.btn-ghost:hover {
  background: var(--color-gray-100);
  border-color: var(--color-gray-400);
}

.btn-sm {
  padding: var(--spacing-sm) var(--spacing-md);
  font-size: var(--font-size-sm);
}

.btn-lg {
  padding: var(--spacing-lg) var(--spacing-2xl);
  font-size: var(--font-size-lg);
}

.btn:active {
  transform: translateY(0);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ========================================
   PRODUCT CARDS
   ======================================== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--spacing-xl);
  margin-top: var(--spacing-2xl);
}

.product-card {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
  cursor: pointer;
  position: relative;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-2xl);
}

.product-image {
  position: relative;
  width: 100%;
  height: 320px;
  overflow: hidden;
  background: var(--color-gray-100);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.product-card:hover .product-image img {
  transform: scale(1.08);
}

.product-badge {
  position: absolute;
  top: var(--spacing-md);
  left: var(--spacing-md);
  padding: var(--spacing-xs) var(--spacing-md);
  background: var(--color-accent);
  color: var(--color-dark);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-md);
  letter-spacing: 0.5px;
}

.product-badge.new {
  background: var(--color-secondary);
  color: var(--color-white);
}

.product-info {
  padding: var(--spacing-lg);
}

.product-brand {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--color-gray-600);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: var(--spacing-xs);
}

.product-name {
  font-family: var(--font-heading);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
  margin-bottom: var(--spacing-sm);
  line-height: 1.3;
}

.product-price {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

.price-current {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
}

.price-original {
  font-size: var(--font-size-base);
  color: var(--color-gray-500);
  text-decoration: line-through;
}

.product-actions {
  display: flex;
  gap: var(--spacing-sm);
}

.add-to-cart-btn {
  flex: 1;
  padding: var(--spacing-md);
  background: var(--gradient-primary);
  color: var(--color-white);
  font-weight: var(--font-weight-semibold);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.add-to-cart-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* ========================================
   FILTERS & SEARCH (SHOP PAGE)
   ======================================== */
.shop-header {
  background: var(--bg-secondary);
  padding: var(--spacing-2xl) 0;
  border-bottom: 1px solid var(--color-gray-200);
}

.shop-title {
  text-align: center;
  margin-bottom: var(--spacing-lg);
}

.filters-container {
  display: flex;
  gap: var(--spacing-md);
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

.filter-group {
  display: flex;
  gap: var(--spacing-sm);
  flex-wrap: wrap;
}

.filter-btn {
  padding: var(--spacing-sm) var(--spacing-lg);
  background: var(--color-white);
  color: var(--color-dark);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.filter-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.filter-btn.active {
  background: var(--gradient-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
}

.search-box {
  position: relative;
  width: 100%;
  max-width: 400px;
}

.search-input {
  width: 100%;
  padding: var(--spacing-md) var(--spacing-md) var(--spacing-md) var(--spacing-2xl);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-base);
  transition: all var(--transition-fast);
}

.search-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(212, 115, 94, 0.1);
}

.search-icon {
  position: absolute;
  left: var(--spacing-md);
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-gray-500);
  pointer-events: none;
}

/* ========================================
   CART PAGE
   ======================================== */
.cart-container {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: var(--spacing-2xl);
  margin-top: var(--spacing-2xl);
}

.cart-items {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.cart-item {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: var(--spacing-lg);
  padding: var(--spacing-lg);
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.cart-item:hover {
  box-shadow: var(--shadow-md);
}

.cart-item-image {
  width: 120px;
  height: 120px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-gray-100);
}

.cart-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.cart-item-brand {
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--color-gray-600);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cart-item-name {
  font-family: var(--font-heading);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
  margin: var(--spacing-xs) 0;
}

.cart-item-price {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
}

.cart-item-controls {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-end;
}

.quantity-control {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.quantity-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-gray-100);
  color: var(--color-dark);
  font-weight: var(--font-weight-bold);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.quantity-btn:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

.quantity-value {
  min-width: 40px;
  text-align: center;
  font-weight: var(--font-weight-semibold);
}

.remove-btn {
  color: var(--color-gray-500);
  font-size: var(--font-size-sm);
  transition: color var(--transition-fast);
}

.remove-btn:hover {
  color: #DC2626;
}

.cart-summary {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-lg);
  position: sticky;
  top: calc(80px + var(--spacing-md));
  height: fit-content;
}

.cart-summary h3 {
  font-size: var(--font-size-2xl);
  margin-bottom: var(--spacing-lg);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid var(--color-gray-200);
}

.summary-row:last-of-type {
  border-bottom: none;
  padding-top: var(--spacing-lg);
  margin-top: var(--spacing-md);
  border-top: 2px solid var(--color-dark);
}

.summary-label {
  color: var(--color-gray-700);
  font-weight: var(--font-weight-medium);
}

.summary-value {
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
}

.summary-total {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
}

.customer-form {
  margin-top: var(--spacing-xl);
  padding-top: var(--spacing-xl);
  border-top: 2px solid var(--color-gray-200);
}

.form-group {
  margin-bottom: var(--spacing-md);
}

.form-label {
  display: block;
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--spacing-sm);
  color: var(--color-dark);
}

.form-input {
  width: 100%;
  padding: var(--spacing-md);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  font-size: var(--font-size-base);
  transition: all var(--transition-fast);
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(212, 115, 94, 0.1);
}

.checkout-btn {
  width: 100%;
  margin-top: var(--spacing-lg);
  padding: var(--spacing-lg);
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: var(--color-white);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-base);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.checkout-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

/* ========================================
   CATEGORIES SECTION
   ======================================== */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-xl);
  margin-top: var(--spacing-2xl);
}

.category-card {
  position: relative;
  height: 400px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-base);
}

.category-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-2xl);
}

.category-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.category-card:hover .category-image {
  transform: scale(1.1);
}

.category-overlay {
  position: absolute;
  inset: 0;
  background: var(--gradient-overlay);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-xl);
  transition: background var(--transition-base);
}

.category-card:hover .category-overlay {
  background: linear-gradient(180deg, rgba(26, 26, 26, 0.3) 0%, rgba(26, 26, 26, 0.8) 100%);
}

.category-name {
  font-size: var(--font-size-3xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-white);
  margin-bottom: var(--spacing-sm);
  text-align: center;
}

.category-count {
  font-size: var(--font-size-base);
  color: rgba(255, 255, 255, 0.9);
  font-weight: var(--font-weight-medium);
}

/* ========================================
   FEATURES SECTION
   ======================================== */
.features {
  background: var(--bg-secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-xl);
  margin-top: var(--spacing-2xl);
}

.feature-card {
  text-align: center;
  padding: var(--spacing-xl);
  background: var(--color-white);
  border-radius: var(--radius-xl);
  transition: all var(--transition-base);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--spacing-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  color: var(--color-white);
  font-size: var(--font-size-3xl);
}

.feature-title {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--spacing-sm);
}

.feature-description {
  color: var(--color-gray-600);
  font-size: var(--font-size-base);
  margin-bottom: 0;
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
  background: var(--color-dark);
  color: var(--color-gray-300);
  padding: var(--spacing-3xl) 0 var(--spacing-xl);
  margin-top: var(--spacing-4xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--spacing-2xl);
  margin-bottom: var(--spacing-2xl);
}

.footer-brand h3 {
  color: var(--color-white);
  margin-bottom: var(--spacing-md);
}

.footer-description {
  color: var(--color-gray-400);
  margin-bottom: var(--spacing-lg);
}

.social-links {
  display: flex;
  gap: var(--spacing-md);
}

.social-link {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--color-white);
  transition: all var(--transition-base);
}

.social-link:hover {
  background: var(--color-primary);
  transform: translateY(-2px);
}

.footer-section h4 {
  color: var(--color-white);
  font-size: var(--font-size-lg);
  margin-bottom: var(--spacing-md);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.footer-link {
  color: var(--color-gray-400);
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--color-primary);
}

.footer-bottom {
  padding-top: var(--spacing-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: var(--color-gray-500);
  font-size: var(--font-size-sm);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 1024px) {
  :root {
    --font-size-6xl: 3rem;
    --font-size-5xl: 2.5rem;
    --font-size-4xl: 2rem;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }

  .cart-container {
    grid-template-columns: 1fr;
  }

  .cart-summary {
    position: static;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --font-size-6xl: 2.5rem;
    --font-size-5xl: 2rem;
    --font-size-4xl: 1.75rem;
    --spacing-4xl: 3rem;
  }

  .nav-links {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .nav-links.active {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-xl);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  }

  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--spacing-lg);
  }

  .hero {
    min-height: 500px;
  }

  .hero-title {
    font-size: var(--font-size-4xl);
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    width: 100%;
  }

  .categories-grid {
    grid-template-columns: 1fr;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .cart-item {
    grid-template-columns: 100px 1fr;
    gap: var(--spacing-md);
  }

  .cart-item-controls {
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

@media (max-width: 480px) {
  :root {
    --font-size-6xl: 2rem;
    --font-size-5xl: 1.75rem;
    --font-size-4xl: 1.5rem;
    --spacing-2xl: 2rem;
    --spacing-3xl: 2.5rem;
  }

  .container {
    padding: 0 var(--spacing-sm);
  }

  .section {
    padding: var(--spacing-2xl) 0;
  }

  .products-grid {
    grid-template-columns: 1fr;
  }

  .product-image {
    height: 280px;
  }

  .filters-container {
    flex-direction: column;
    align-items: stretch;
  }

  .search-box {
    max-width: 100%;
  }
}

/* ========================================
   ANIMATIONS
   ======================================== */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-slide-in {
  animation: slideIn 0.5s ease-out forwards;
}

/* Loading State */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: var(--color-white);
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: var(--spacing-4xl) var(--spacing-xl);
}

.empty-state-icon {
  font-size: var(--font-size-6xl);
  color: var(--color-gray-400);
  margin-bottom: var(--spacing-lg);
}

.empty-state-title {
  font-size: var(--font-size-2xl);
  color: var(--color-gray-700);
  margin-bottom: var(--spacing-md);
}

.empty-state-description {
  color: var(--color-gray-500);
  margin-bottom: var(--spacing-xl);
}

/* ========================================
   PRODUCT DETAIL PAGE
   ======================================== */

/* Breadcrumbs */
.breadcrumbs-section {
  background: var(--bg-secondary);
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid var(--color-gray-200);
}

.breadcrumbs {
  display: flex;
  gap: var(--spacing-sm);
  align-items: center;
  flex-wrap: wrap;
  font-size: var(--font-size-sm);
  color: var(--color-gray-600);
}

.breadcrumbs a {
  color: var(--color-gray-600);
  transition: color var(--transition-fast);
}

.breadcrumbs a:hover {
  color: var(--color-primary);
}

.breadcrumbs-separator {
  color: var(--color-gray-400);
  margin: 0 var(--spacing-xs);
}

.breadcrumbs-current {
  color: var(--color-dark);
  font-weight: var(--font-weight-medium);
}

/* Product Detail Layout */
.product-detail-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-4xl);
  margin-top: var(--spacing-2xl);
}

/* Product Gallery */
.product-gallery {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.gallery-main {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--radius-2xl);
  overflow: hidden;
  background: var(--color-gray-100);
  box-shadow: var(--shadow-lg);
}

.main-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.main-image:hover {
  transform: scale(1.05);
}

.image-badge {
  position: absolute;
  top: var(--spacing-lg);
  left: var(--spacing-lg);
  padding: var(--spacing-sm) var(--spacing-lg);
  background: var(--color-accent);
  color: var(--color-dark);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-md);
  letter-spacing: 0.5px;
}

.image-badge.new {
  background: var(--color-secondary);
  color: var(--color-white);
}

.gallery-thumbnails {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: var(--spacing-md);
}

.thumbnail {
  aspect-ratio: 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  border: 3px solid transparent;
  transition: all var(--transition-fast);
  background: var(--color-gray-100);
}

.thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumbnail:hover {
  border-color: var(--color-gray-300);
}

.thumbnail.active {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(212, 115, 94, 0.1);
}

/* Product Detail Info */
.product-detail-info {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.product-detail-title {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-bold);
  line-height: 1.2;
  margin-bottom: 0;
}

.product-detail-price {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.product-meta {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
  padding: var(--spacing-lg);
  background: var(--bg-secondary);
  border-radius: var(--radius-xl);
}

.meta-item {
  display: flex;
  gap: var(--spacing-sm);
  font-size: var(--font-size-base);
}

.meta-label {
  font-weight: var(--font-weight-semibold);
  color: var(--color-gray-700);
  min-width: 90px;
}

.meta-value {
  color: var(--color-dark);
}

.product-description {
  font-size: var(--font-size-base);
  line-height: 1.7;
  color: var(--color-gray-700);
}

/* Quantity Selector and Add to Cart */
.product-actions-detail {
  display: flex;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

.quantity-selector {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  background: var(--color-white);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xs);
}

.quantity-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-gray-100);
  border: none;
  border-radius: var(--radius-md);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-dark);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.quantity-btn:hover {
  background: var(--color-gray-200);
}

.quantity-btn:active {
  transform: scale(0.95);
}

.quantity-input {
  width: 60px;
  text-align: center;
  border: none;
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
  background: transparent;
}

.quantity-input:focus {
  outline: none;
}

/* Remove number input spinners */
.quantity-input::-webkit-inner-spin-button,
.quantity-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.quantity-input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Product Features */
.product-features {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-md);
  padding: calc(var(--spacing-md) + 4px);
  background: linear-gradient(135deg, rgba(212,115,94,0.06) 0%, rgba(42,155,163,0.02) 100%);
  border-radius: calc(var(--radius-2xl));
  margin-top: var(--spacing-lg);
  box-shadow: 0 8px 30px rgba(26,26,26,0.06);
  border: 1px solid rgba(255,255,255,0.5);
  backdrop-filter: blur(6px) saturate(120%);
  transform: translateZ(0);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

/* On larger screens arrange features horizontally for an attention-grabbing row */
@media (min-width: 900px) {
  .product-features {
    grid-template-columns: repeat(3, 1fr);
    align-items: stretch;
  }
}

.feature-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255,255,255,0.65), rgba(255,255,255,0.45));
  border: 1px solid rgba(26,26,26,0.03);
  box-shadow: 0 6px 20px rgba(26,26,26,0.06);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
}

.feature-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 40px rgba(26,26,26,0.12);
  background: linear-gradient(180deg, rgba(255,255,255,0.9), rgba(255,255,255,0.7));
}

.feature-icon {
  width: 56px;
  height: 56px;
  min-width: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 1.375rem; /* slightly larger icon */
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  box-shadow: 0 6px 18px rgba(0,0,0,0.12);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.feature-text {
  display: flex;
  flex-direction: column;
}

.feature-text .feature-title {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
}

.feature-text .feature-sub {
  font-size: var(--font-size-sm);
  color: var(--color-gray-600);
}

.product-features .feature-item + .feature-item {
  margin-top: 0; /* grid gap handles space */
}

/* Related Products Section */
.related-products-section {
  padding-top: var(--spacing-4xl);
  margin-top: var(--spacing-4xl);
  border-top: 1px solid var(--color-gray-200);
}

/* Responsive Design for Product Detail */
@media (max-width: 1024px) {
  .product-detail-container {
    gap: var(--spacing-2xl);
  }
}

@media (max-width: 768px) {
  .product-detail-container {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
  }

  .product-detail-title {
    font-size: var(--font-size-3xl);
  }

  .product-actions-detail {
    flex-direction: column;
  }

  .gallery-thumbnails {
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
  }

  .related-products-section {
    margin-top: var(--spacing-2xl);
  }
}

/* ========================================
   ADMIN PANEL - UNIFIED INTERFACE
   ======================================== */

/* Admin Layout */
.admin-layout {
  display: flex;
  min-height: 100vh;
  background: var(--bg-secondary);
}

/* ========================================
   SIDEBAR NAVIGATION
   ======================================== */
.admin-sidebar {
  width: 280px;
  background: linear-gradient(180deg, #1A1A1A 0%, #2A2A2A 100%);
  color: var(--color-white);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  z-index: var(--z-sticky);
  box-shadow: var(--shadow-xl);
  transition: transform var(--transition-base);
}

.sidebar-header {
  padding: var(--spacing-2xl) var(--spacing-lg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
  font-family: var(--font-heading);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-extrabold);
  color: var(--color-white);
  margin-bottom: var(--spacing-xs);
}

.sidebar-subtitle {
  font-size: var(--font-size-sm);
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

.sidebar-nav {
  flex: 1;
  padding: var(--spacing-lg) 0;
  overflow-y: auto;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md) var(--spacing-lg);
  color: rgba(255, 255, 255, 0.7);
  font-weight: var(--font-weight-medium);
  transition: all var(--transition-fast);
  border-left: 3px solid transparent;
  margin-bottom: var(--spacing-xs);
}

.sidebar-nav-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-white);
  border-left-color: var(--color-primary);
}

.sidebar-nav-item.active {
  background: rgba(212, 115, 94, 0.15);
  color: var(--color-white);
  border-left-color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
}

.nav-icon {
  font-size: var(--font-size-xl);
  min-width: 24px;
}

.nav-label {
  flex: 1;
}

.sidebar-footer {
  padding: var(--spacing-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-config-btn,
.sidebar-back-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-white);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  transition: all var(--transition-base);
  margin-bottom: var(--spacing-sm);
  cursor: pointer;
}

.sidebar-config-btn:hover,
.sidebar-back-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateX(4px);
}

/* ========================================
   MAIN CONTENT AREA
   ======================================== */
.admin-main {
  flex: 1;
  margin-left: 280px;
  padding: var(--spacing-2xl);
  min-height: 100vh;
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-2xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 2px solid var(--color-gray-200);
}

.admin-title {
  font-size: var(--font-size-3xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-dark);
  margin: 0;
}

.admin-header-actions {
  display: flex;
  gap: var(--spacing-md);
}

/* ========================================
   CONTENT SECTIONS
   ======================================== */
.content-section {
  display: none;
  animation: fadeIn var(--transition-base);
}

.content-section.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-card {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  box-shadow: var(--shadow-lg);
  margin-bottom: var(--spacing-xl);
}

.section-card h2 {
  font-size: var(--font-size-2xl);
  margin-bottom: var(--spacing-md);
}

/* ========================================
   STATS SECTION
   ======================================== */
.stats-section {
  margin-bottom: var(--spacing-2xl);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--spacing-lg);
}

.stat-card {
  background: var(--color-white);
  padding: var(--spacing-xl);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  text-align: center;
  transition: all var(--transition-base);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.stat-icon {
  font-size: var(--font-size-4xl);
  margin-bottom: var(--spacing-md);
}

.stat-value {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  margin-bottom: var(--spacing-sm);
}

.stat-label {
  color: var(--color-gray-600);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
}

/* ========================================
   UPLOAD ZONE (CSV Import)
   ======================================== */
.upload-zone {
  border: 3px dashed var(--color-gray-300);
  border-radius: var(--radius-xl);
  padding: var(--spacing-4xl);
  text-align: center;
  background: var(--color-gray-50);
  transition: all var(--transition-base);
  cursor: pointer;
  margin: var(--spacing-xl) 0;
}

.upload-zone:hover,
.upload-zone.drag-over {
  border-color: var(--color-primary);
  background: rgba(212, 115, 94, 0.05);
}

.upload-icon {
  font-size: var(--font-size-6xl);
  margin-bottom: var(--spacing-lg);
}

.upload-zone h3 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--spacing-sm);
}

.upload-zone p {
  color: var(--color-gray-600);
  margin-bottom: var(--spacing-lg);
}

.upload-actions {
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

/* ========================================
   TABLES
   ======================================== */
.table-container,
.table-responsive {
  overflow-x: auto;
  margin-top: var(--spacing-xl);
}

.preview-table,
.products-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

.preview-table th,
.products-table th {
  background: var(--color-gray-100);
  padding: var(--spacing-md);
  text-align: left;
  font-weight: var(--font-weight-semibold);
  border-bottom: 2px solid var(--color-gray-300);
  white-space: nowrap;
}

.preview-table td,
.products-table td {
  padding: var(--spacing-md);
  border-bottom: 1px solid var(--color-gray-200);
}

.preview-table tr:hover,
.products-table tr:hover {
  background: var(--color-gray-50);
}

.preview-table img,
.products-table img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.preview-actions {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  margin-top: var(--spacing-xl);
}

/* ========================================
   CONTROLS BAR (Search & Filters)
   ======================================== */
.controls-bar {
  display: flex;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  flex-wrap: wrap;
}

.search-box {
  flex: 1;
  min-width: 280px;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: var(--spacing-md) var(--spacing-md) var(--spacing-md) 3rem;
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-base);
  transition: all var(--transition-base);
}

.search-box input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(212, 115, 94, 0.1);
}

.search-icon {
  position: absolute;
  left: var(--spacing-md);
  top: 50%;
  transform: translateY(-50%);
  font-size: var(--font-size-xl);
  color: var(--color-gray-400);
}

.filters {
  display: flex;
  gap: var(--spacing-sm);
  flex-wrap: wrap;
}

.filter-btn {
  padding: var(--spacing-sm) var(--spacing-md);
  border: 2px solid var(--color-gray-300);
  background: var(--color-white);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  cursor: pointer;
  transition: all var(--transition-base);
}

.filter-btn:hover {
  border-color: var(--color-primary);
  background: rgba(212, 115, 94, 0.05);
}

.filter-btn.active {
  background: var(--gradient-primary);
  color: var(--color-white);
  border-color: transparent;
}

/* ========================================
   LOADING & EMPTY STATES
   ======================================== */
.loading-state,
.empty-state {
  text-align: center;
  padding: var(--spacing-4xl);
  color: var(--color-gray-500);
}

.spinner {
  width: 48px;
  height: 48px;
  border: 4px solid var(--color-gray-200);
  border-top-color: var(--color-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto var(--spacing-lg);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.empty-icon {
  font-size: var(--font-size-6xl);
  margin-bottom: var(--spacing-lg);
}

/* ========================================
   PRODUCT FORM (Editor)
   ======================================== */
.editor-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-2xl);
}

.editor-mode-badge {
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--gradient-secondary);
  color: var(--color-white);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
}

.product-form {
  max-width: 100%;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: var(--spacing-2xl);
  margin-bottom: var(--spacing-2xl);
}

.form-section {
  background: var(--bg-secondary);
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
}

.form-section.full-width {
  grid-column: 1/ -1;
}

.form-section h3 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--spacing-lg);
  color: var(--color-dark);
}

.form-group {
  margin-bottom: var(--spacing-lg);
}

.form-group label {
  display: block;
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--spacing-sm);
  color: var(--color-gray-700);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: var(--spacing-md);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  font-size: var(--font-size-base);
  transition: all var(--transition-base);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(212, 115, 94, 0.1);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-md);
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  cursor: pointer;
  font-weight: var(--font-weight-medium);
}

.checkbox-label input[type="checkbox"] {
  width: auto;
  cursor: pointer;
}

.form-actions {
  display: flex;
  gap: var(--spacing-md);
  justify-content: flex-end;
  padding-top: var(--spacing-xl);
  border-top: 2px solid var(--color-gray-200);
}

/* Image Manager */
.image-manager {
  padding: var(--spacing-xl);
  background: var(--color-white);
  border-radius: var(--radius-lg);
}

.images-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
}

.image-item {
  position: relative;
  aspect-ratio: 1;
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.image-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.remove-image-btn {
  position: absolute;
  top: var(--spacing-xs);
  right: var(--spacing-xs);
  background: rgba(255, 0, 0, 0.8);
  color: white;
  border: none;
  border-radius: var(--radius-full);
  padding: var(--spacing-xs) var(--spacing-sm);
  cursor: pointer;
  font-size: var(--font-size-xs);
}

/* ========================================
   PROGRESS BAR
   ======================================== */
.progress-bar {
  width: 100%;
  height: 24px;
  background: var(--color-gray-200);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin: var(--spacing-lg) 0;
}

.progress-fill {
  height: 100%;
  background: var(--gradient-primary);
  transition: width var(--transition-base);
  border-radius: var(--radius-full);
}

/* ========================================
   LOG CONTAINER
   ======================================== */
.log-container {
  background: var(--color-dark);
  color: var(--color-white);
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  max-height: 400px;
  overflow-y: auto;
  font-family: monospace;
  font-size: var(--font-size-sm);
}

.log-entry {
  padding: var(--spacing-xs) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.log-entry.success {
  color: #10B981;
}

.log-entry.error {
  color: #EF4444;
}

.log-entry.info {
  color: #3B82F6;
}

/* ========================================
   MODAL
   ======================================== */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal);
  backdrop-filter: blur(4px);
}

.modal-content {
  background: var(--color-white);
  border-radius: var(--radius-xl);
  max-width: 600px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-2xl);
  animation: modalSlideIn var(--transition-base);
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-40px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-xl);
  border-bottom: 2px solid var(--color-gray-200);
}

.modal-header h2 {
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: var(--font-size-2xl);
  cursor: pointer;
  color: var(--color-gray-600);
  transition: color var(--transition-fast);
}

.modal-close:hover {
  color: var(--color-dark);
}

.modal-body {
  padding: var(--spacing-xl);
}

/* ========================================
   ALERTS
   ======================================== */
#alertContainer {
  margin-bottom: var(--spacing-lg);
}

.alert {
  padding: var(--spacing-md) var(--spacing-lg);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-md);
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  animation: slideInDown 0.3s ease-out;
  box-shadow: var(--shadow-md);
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.alert-success {
  background: #D1FAE5;
  color: #065F46;
  border-left: 4px solid #10B981;
}

.alert-error {
  background: #FEE2E2;
  color: #991B1B;
  border-left: 4px solid #EF4444;
}

.alert-info {
  background: #DBEAFE;
  color: #1E40AF;
  border-left: 4px solid #3B82F6;
}

.alert-warning {
  background: #FEF3C7;
  color: #92400E;
  border-left: 4px solid #F59E0B;
}

/* ========================================
   BADGES & LABELS
   ======================================== */
.category-badge {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
}

.featured-badge {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: var(--color-white);
  border-radius: var(--radius-md);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  margin-left: var(--spacing-sm);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 1024px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .admin-sidebar {
    transform: translateX(-100%);
  }

  .admin-sidebar.open {
    transform: translateX(0);
  }

  .admin-main {
    margin-left: 0;
    padding: var(--spacing-md);
  }

  .admin-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-md);
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .controls-bar {
    flex-direction: column;
  }

  .search-box {
    min-width: 100%;
  }
}

.feature-item:hover .feature-icon {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 14px 30px rgba(0,0,0,0.18);
}

/* SVG sizing inside icon badge */
.feature-icon svg {
  width: 28px;
  height: 28px;
}

/* Highlight a feature (e.g., free shipping) */
.feature-item.highlight {
  border: 1px solid rgba(32, 160, 125, 0.12);
  background: linear-gradient(180deg, rgba(245, 255, 250, 0.95), rgba(245, 255, 250, 0.7));
  box-shadow: 0 18px 48px rgba(32,160,125,0.08);
}

/* Small 'badge' element inside a feature */
.feature-badge {
  margin-left: auto;
  padding: 4px 8px;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: white;
  font-size: 0.8rem;
  border-radius: 999px;
  font-weight: var(--font-weight-semibold);
  box-shadow: 0 4px 14px rgba(18, 140, 126, 0.15);
}