/* ========================================
   La Boutique - Static Catalog Styles
   Enhanced with new features
   ======================================== */

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

:root {
  --color-stone-50: #fafaf9;
  --color-stone-100: #f5f5f4;
  --color-stone-200: #e7e5e4;
  --color-stone-300: #d6d3d1;
  --color-stone-400: #a8a29e;
  --color-stone-500: #78716c;
  --color-stone-600: #57534e;
  --color-stone-700: #44403c;
  --color-stone-800: #292524;
  --color-stone-900: #1c1917;
  --color-rose-100: #ffe4e6;
  --color-rose-200: #fecdd3;
  --color-rose-400: #fb7185;
  --color-rose-500: #f43f5e;
  --color-rose-700: #be123c;
  --color-green-100: #dcfce7;
  --color-green-500: #22c55e;
  --color-green-600: #16a34a;
  --color-green-700: #15803d;
  --color-amber-100: #fef3c7;
  --color-amber-400: #fbbf24;
  --color-amber-500: #f59e0b;
  --color-amber-700: #b45309;
  --color-emerald-100: #d1fae5;
  --color-emerald-500: #10b981;
  --color-emerald-700: #047857;
  --color-sky-100: #e0f2fe;
  --color-sky-500: #0ea5e9;
  --color-sky-700: #0369a1;
  --color-violet-100: #ede9fe;
  --color-violet-500: #8b5cf6;
  --color-violet-700: #6d28d9;
  --color-pink-100: #fce7f3;
  --color-pink-500: #ec4899;
  --color-pink-700: #be185d;
  --color-orange-100: #ffedd5;
  --color-orange-500: #f97316;
  --color-orange-700: #c2410c;
  --color-teal-100: #ccfbf1;
  --color-teal-500: #14b8a6;
  --color-teal-700: #0f766e;
  --color-fuchsia-100: #fae8ff;
  --color-fuchsia-500: #d946ef;
  --color-fuchsia-700: #a21caf;
  --color-lime-100: #ecfccb;
  --color-lime-500: #84cc16;
  --color-lime-700: #4d7c0f;
  --color-gray-100: #f3f4f6;
  --color-gray-500: #6b7280;
  --color-gray-700: #374151;
  --color-red-100: #fee2e2;
  --color-red-500: #ef4444;

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);

  /* Theme variables (light mode defaults) */
  --bg-primary: #ffffff;
  --bg-secondary: #fafaf9;
  --bg-tertiary: #f5f5f4;
  --text-primary: #1c1917;
  --text-secondary: #44403c;
  --text-muted: #78716c;
  --text-faint: #a8a29e;
  --border-color: #e7e5e4;
  --border-subtle: #f5f5f4;
  --card-bg: #ffffff;
  --card-border: #f5f5f4;
  --header-bg: rgba(255, 255, 255, 0.8);
  --input-bg: rgba(245, 245, 244, 0.6);
  --input-focus-bg: #ffffff;
}

/* Dark Mode */
[data-theme="dark"] {
  --bg-primary: #0c0a09;
  --bg-secondary: #1c1917;
  --bg-tertiary: #292524;
  --text-primary: #fafaf9;
  --text-secondary: #d6d3d1;
  --text-muted: #a8a29e;
  --text-faint: #78716c;
  --border-color: #44403c;
  --border-subtle: #292524;
  --card-bg: #1c1917;
  --card-border: #292524;
  --header-bg: rgba(12, 10, 9, 0.85);
  --input-bg: rgba(41, 37, 36, 0.6);
  --input-focus-bg: #1c1917;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-secondary);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s, color 0.3s;
}

.hidden {
  display: none !important;
}

/* App Wrapper */
.app-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ============ Scroll Progress Bar ============ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: var(--color-rose-500);
  z-index: 9999;
  transition: width 0.1s linear;
}

/* ============ Announcement Banner ============ */
.announcement-banner {
  background: var(--color-rose-500);
  color: white;
  position: relative;
  z-index: 45;
}

.announcement-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 2.5rem 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  text-align: center;
}

.announcement-close {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 4px;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.announcement-close:hover {
  opacity: 1;
}

/* ============ Header ============ */
.header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: background-color 0.3s, border-color 0.3s;
}

.header-inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--text-primary);
  color: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s, color 0.3s;
}

.brand-text {
  display: none;
}

@media (min-width: 640px) {
  .brand-text {
    display: block;
  }
}

.brand-name {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1;
  color: var(--text-primary);
}

.brand-sub {
  font-size: 0.625rem;
  color: var(--text-faint);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Search */
.search-container {
  flex: 1;
  position: relative;
  max-width: 28rem;
}

.search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-faint);
  pointer-events: none;
}

.search-container input {
  width: 100%;
  height: 40px;
  padding: 0 2.25rem 0 2.25rem;
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 9999px;
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--text-primary);
  outline: none;
  transition: all 0.2s;
}

.search-container input:focus {
  background: var(--input-focus-bg);
  border-color: var(--text-faint);
  box-shadow: 0 0 0 3px rgba(68, 64, 60, 0.1);
}

.search-container input::placeholder {
  color: var(--text-faint);
}

.clear-search-btn {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  padding: 2px;
  border-radius: 4px;
  transition: color 0.2s;
}

.clear-search-btn:hover {
  color: var(--text-muted);
}

/* Header Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-shrink: 0;
}

.icon-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}

.icon-btn:hover {
  background: var(--bg-tertiary);
}

/* Favorites Badge */
.fav-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--color-rose-500);
  color: white;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: badgePop 0.2s ease-out;
}

@keyframes badgePop {
  0% { transform: scale(0); }
  100% { transform: scale(1); }
}

/* ============ Hero ============ */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--color-stone-900);
  color: white;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../img/boutique-banner.png');
  background-size: cover;
  background-position: center;
  opacity: 0.3;
  will-change: transform;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(28,25,23,0.6), rgba(28,25,23,0.8), var(--color-stone-900));
}

.hero-content {
  position: relative;
  max-width: 72rem;
  margin: 0 auto;
  padding: 2.5rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1rem;
}

@media (min-width: 640px) {
  .hero-content {
    padding: 4rem 1rem;
  }
}

.hero-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-rose-400);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.hero-title {
  font-size: 1.875rem;
  font-weight: 700;
  letter-spacing: -0.025em;
}

@media (min-width: 640px) {
  .hero-title {
    font-size: 3rem;
  }
}

.hero-desc {
  color: var(--color-stone-300);
  font-size: 0.875rem;
  max-width: 32rem;
  line-height: 1.625;
}

@media (min-width: 640px) {
  .hero-desc {
    font-size: 1rem;
  }
}

.hero-cta {
  margin-top: 0.5rem;
  padding: 0.625rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 9999px;
  background: transparent;
  color: white;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
}

.hero-cta:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* ============ Main Content ============ */
.main-content {
  flex: 1;
  max-width: 72rem;
  margin: 0 auto;
  width: 100%;
  padding: 1.5rem 1rem;
}

/* Category Filters */
.category-filters {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

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

.category-btn {
  flex-shrink: 0;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.375rem;
  background: var(--bg-tertiary);
  color: var(--text-muted);
}

.category-btn:hover {
  background: var(--border-color);
}

.category-btn.active {
  background: var(--text-primary);
  color: var(--bg-primary);
  box-shadow: var(--shadow-md);
}

.category-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

/* Controls Bar */
.controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.controls-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.controls-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Sort */
.sort-container {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--text-muted);
}

.sort-select {
  height: 36px;
  padding: 0 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--card-bg);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 0.8125rem;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
  appearance: auto;
}

.sort-select:focus {
  border-color: var(--text-faint);
}

/* Control Button (Price filter toggle, etc.) */
.control-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  height: 36px;
  padding: 0 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--card-bg);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.8125rem;
  cursor: pointer;
  transition: all 0.2s;
}

.control-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.control-btn.active {
  background: var(--text-primary);
  color: var(--bg-primary);
  border-color: var(--text-primary);
}

/* View Toggle */
.view-toggle {
  display: flex;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  overflow: hidden;
}

.view-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card-bg);
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  transition: all 0.2s;
}

.view-btn:first-child {
  border-right: 1px solid var(--border-color);
}

.view-btn:hover {
  color: var(--text-muted);
}

.view-btn.active {
  background: var(--text-primary);
  color: var(--bg-primary);
}

/* Price Filter Panel */
.price-filter-panel {
  margin-bottom: 1rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  overflow: hidden;
  animation: slideDown 0.2s ease-out;
  transition: background-color 0.3s, border-color 0.3s;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.price-filter-content {
  padding: 1rem;
  display: flex;
  align-items: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.price-inputs {
  display: flex;
  align-items: flex-end;
  gap: 0.5rem;
}

.price-input-group {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.price-input-group label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

.price-input-group input {
  width: 100px;
  height: 36px;
  padding: 0 0.5rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.875rem;
  outline: none;
  transition: border-color 0.2s;
}

.price-input-group input:focus {
  border-color: var(--text-faint);
}

.price-separator {
  color: var(--text-faint);
  padding-bottom: 0.5rem;
  font-size: 0.875rem;
}

.price-apply-btn {
  height: 36px;
  padding: 0 1rem;
  border: none;
  border-radius: 0.5rem;
  background: var(--text-primary);
  color: var(--bg-primary);
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s;
}

.price-apply-btn:hover {
  opacity: 0.85;
}

.price-clear-btn {
  height: 36px;
  padding: 0 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--color-rose-500);
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.price-clear-btn:hover {
  background: var(--color-rose-100);
}

/* Results Info */
.results-info {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.results-info p {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.results-info .highlight {
  font-weight: 500;
  color: var(--text-secondary);
}

.clear-search-link {
  font-size: 0.75rem;
  color: var(--color-rose-500);
  font-weight: 500;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.2s;
}

.clear-search-link:hover {
  color: var(--color-rose-700);
}

/* State Containers */
.state-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5rem 1rem;
  gap: 0.75rem;
  text-align: center;
}

.state-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.error-icon {
  background: var(--color-rose-100);
  color: var(--color-rose-500);
}

.empty-icon {
  background: var(--bg-tertiary);
  color: var(--text-faint);
}

.state-title {
  font-weight: 500;
  color: var(--text-secondary);
  font-size: 1rem;
}

.state-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 24rem;
}

.retry-btn {
  margin-top: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--card-bg);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s;
}

.retry-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--text-faint);
}

/* ============ Shimmer Loading ============ */
.shimmer-card-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  width: 100%;
  max-width: 72rem;
}

@media (min-width: 640px) {
  .shimmer-card-container {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
  }
}

@media (min-width: 1024px) {
  .shimmer-card-container {
    grid-template-columns: repeat(4, 1fr);
  }
}

.shimmer-card {
  background: var(--card-bg);
  border-radius: 1rem;
  border: 1px solid var(--card-border);
  overflow: hidden;
  position: relative;
}

.shimmer-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(168, 162, 158, 0.08) 40%,
    rgba(168, 162, 158, 0.15) 50%,
    rgba(168, 162, 158, 0.08) 60%,
    transparent 100%
  );
  animation: shimmer 1.8s ease-in-out infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.shimmer-card::after {
  content: '';
  display: block;
  padding-top: 130%;
}

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

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

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

/* List View */
.product-grid.list-view {
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

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

@media (min-width: 1024px) {
  .product-grid.list-view {
    grid-template-columns: repeat(2, 1fr);
  }
}

.product-grid.list-view .product-card {
  display: flex;
  flex-direction: row;
}

.product-grid.list-view .product-image-container {
  width: 140px;
  min-width: 140px;
  aspect-ratio: auto;
  height: 180px;
}

@media (min-width: 640px) {
  .product-grid.list-view .product-image-container {
    width: 180px;
    min-width: 180px;
    height: 220px;
  }
}

.product-grid.list-view .product-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Product Card */
.product-card {
  background: var(--card-bg);
  border-radius: 1rem;
  border: 1px solid var(--card-border);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  position: relative;
}

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

/* Scroll Reveal Animation */
.product-card.reveal {
  opacity: 0;
  transform: translateY(20px);
}

.product-card.revealed {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out, box-shadow 0.3s;
}

/* Product Image */
.product-image-container {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--bg-tertiary);
  cursor: pointer;
}

.product-image-skeleton {
  position: absolute;
  inset: 0;
  background: var(--bg-tertiary);
  overflow: hidden;
}

.product-image-skeleton::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(168, 162, 158, 0.08) 40%,
    rgba(168, 162, 158, 0.15) 50%,
    rgba(168, 162, 158, 0.08) 60%,
    transparent 100%
  );
  animation: shimmer 1.8s ease-in-out infinite;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.5s;
}

.product-card:hover .product-image {
  transform: scale(1.05);
}

.product-image-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  pointer-events: none;
}

.product-card:hover .product-image-overlay {
  background: rgba(0, 0, 0, 0.1);
}

.zoom-icon {
  width: 32px;
  height: 32px;
  color: white;
  opacity: 0;
  transition: opacity 0.3s;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.product-card:hover .zoom-icon {
  opacity: 0.8;
}

/* Category Badge on Card */
.product-category-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid;
  backdrop-filter: blur(4px);
}

.product-category-badge .badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

/* "Nuevo" Badge */
.product-nuevo-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 600;
  background: white;
  color: var(--color-amber-700);
  border: 1px solid var(--color-amber-400);
  z-index: 2;
}

/* Availability Badge */
.product-availability-badge {
  position: absolute;
  bottom: 50px;
  left: 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 9999px;
  font-size: 10px;
  font-weight: 600;
  backdrop-filter: blur(4px);
  z-index: 2;
}

.product-availability-badge.available {
  background: rgba(34, 197, 94, 0.15);
  color: var(--color-green-700);
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.product-availability-badge.limited {
  background: rgba(245, 158, 11, 0.15);
  color: var(--color-amber-700);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.product-availability-badge.sold-out {
  background: rgba(239, 68, 68, 0.15);
  color: var(--color-red-500);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Sold out card dimming */
.product-card.sold-out {
  opacity: 0.6;
}

.product-card.sold-out:hover {
  opacity: 0.75;
}

/* Favorite Heart Button */
.fav-heart-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: var(--shadow-lg);
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  color: var(--text-faint);
  opacity: 0;
  transform: translateY(8px);
}

.product-card:hover .fav-heart-btn {
  opacity: 1;
  transform: translateY(0);
}

.fav-heart-btn:hover {
  color: var(--color-rose-500);
}

.fav-heart-btn.is-fav {
  background: var(--color-rose-500);
  color: white;
  opacity: 1;
  transform: translateY(0) scale(1.1);
}

.fav-heart-btn.is-fav svg {
  fill: white;
}

/* Share Button on Card */
.share-card-btn {
  position: absolute;
  bottom: 10px;
  right: 58px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: var(--shadow-md);
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  color: var(--text-faint);
  opacity: 0;
  transform: translateY(8px);
}

.product-card:hover .share-card-btn {
  opacity: 1;
  transform: translateY(0);
}

.share-card-btn:hover {
  color: var(--text-secondary);
}

/* WhatsApp consult button on card */
.consult-card-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  z-index: 2;
  background: var(--color-green-500);
  color: white;
  opacity: 0;
  transform: translateY(-8px);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.product-card:hover .consult-card-btn {
  opacity: 1;
  transform: translateY(0);
}

.consult-card-btn:hover {
  background: var(--color-green-600);
}

/* Product Info */
.product-info {
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  flex: 1;
}

@media (min-width: 640px) {
  .product-info {
    padding: 1rem;
  }
}

.product-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.375;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 640px) {
  .product-name {
    font-size: 1rem;
  }
}

.product-desc {
  font-size: 0.75rem;
  color: var(--text-faint);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.5;
}

.product-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 0.25rem;
}

.product-price {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
}

@media (min-width: 640px) {
  .product-price {
    font-size: 1.25rem;
  }
}

/* ============ Favorites Sidebar ============ */
.fav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 50;
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fav-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 28rem;
  background: var(--bg-primary);
  z-index: 51;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease-out;
}

.fav-sidebar.open {
  transform: translateX(0);
}

/* Mobile: bottom sheet style */
@media (max-width: 639px) {
  .fav-sidebar {
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    max-width: none;
    max-height: 85vh;
    border-radius: 1.25rem 1.25rem 0 0;
    transform: translateY(100%);
    transition: transform 0.3s ease-out;
  }

  .fav-sidebar.open {
    transform: translateY(0);
  }
}

.fav-header {
  padding: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.fav-header-content {
  flex: 1;
}

.fav-title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
}

.fav-header-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: var(--bg-tertiary);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.fav-description {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.close-fav-btn {
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

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

/* Favorites Empty */
.fav-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.5rem;
}

.fav-empty-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-faint);
}

.fav-empty-title {
  font-weight: 500;
  color: var(--text-secondary);
}

.fav-empty-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Favorites Items */
.fav-items-container {
  flex: 1;
  overflow-y: auto;
}

.fav-items {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.fav-item {
  display: flex;
  gap: 0.75rem;
  padding: 0.75rem;
  background: var(--bg-secondary);
  border-radius: 0.75rem;
  transition: background-color 0.3s;
}

.fav-item-image {
  width: 64px;
  height: 80px;
  border-radius: 0.5rem;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-tertiary);
}

.fav-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fav-item-details {
  flex: 1;
  min-width: 0;
}

.fav-item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.fav-item-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

.fav-item-remove {
  flex-shrink: 0;
  padding: 4px;
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  border-radius: 4px;
  transition: color 0.2s;
}

.fav-item-remove:hover {
  color: var(--color-rose-500);
}

.fav-item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
}

.fav-item-price {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-primary);
}

.fav-item-consult {
  padding: 0.25rem 0.5rem;
  border: none;
  border-radius: 0.375rem;
  background: var(--color-green-600);
  color: white;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: background 0.2s;
}

.fav-item-consult:hover {
  background: var(--color-green-700);
}

/* Favorites Footer */
.fav-footer {
  border-top: 1px solid var(--border-color);
  padding: 1.25rem;
}

.fav-footer .whatsapp-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 0.75rem;
  background: var(--color-green-600);
  color: white;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: background 0.2s;
  margin-bottom: 0.5rem;
}

.fav-footer .whatsapp-btn:hover {
  background: var(--color-green-700);
}

.clear-fav-btn {
  width: 100%;
  padding: 0.5rem;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.875rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  transition: color 0.2s;
}

.clear-fav-btn:hover {
  color: var(--color-rose-500);
}

/* ============ Product Detail Modal ============ */
.detail-modal {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease-out;
}

.detail-modal.hidden {
  display: none !important;
}

.detail-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.detail-modal-content {
  position: relative;
  width: 95vw;
  max-width: 56rem;
  max-height: 90vh;
  background: var(--bg-primary);
  border-radius: 1.25rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.3s ease-out;
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.detail-close-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  transition: all 0.2s;
}

.detail-close-btn:hover {
  background: var(--border-color);
}

.detail-swipe-hint {
  display: none;
  position: absolute;
  top: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.375rem 0.75rem;
  background: var(--bg-tertiary);
  border-radius: 9999px;
  font-size: 0.75rem;
  color: var(--text-muted);
  z-index: 5;
  gap: 0.25rem;
  align-items: center;
}

@media (max-width: 639px) {
  .detail-swipe-hint {
    display: flex;
  }
}

.detail-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  box-shadow: var(--shadow-md);
  transition: all 0.2s;
}

.detail-nav:hover {
  background: var(--text-primary);
  color: var(--bg-primary);
  border-color: var(--text-primary);
}

.detail-nav-prev {
  left: 0.5rem;
}

.detail-nav-next {
  right: 0.5rem;
}

@media (max-width: 639px) {
  .detail-nav {
    display: none;
  }
}

.detail-body {
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  touch-action: pan-y;
}

@media (min-width: 640px) {
  .detail-body {
    flex-direction: row;
  }
}

/* Detail Gallery */
.detail-gallery {
  flex-shrink: 0;
  width: 100%;
  background: var(--bg-tertiary);
}

@media (min-width: 640px) {
  .detail-gallery {
    width: 50%;
    max-width: 28rem;
  }
}

.detail-main-image {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
}

.detail-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-zoom-btn {
  position: absolute;
  bottom: 0.75rem;
  right: 0.75rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.detail-zoom-btn:hover {
  background: rgba(0, 0, 0, 0.7);
}

.detail-thumbnails {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  overflow-x: auto;
}

.detail-thumbnail {
  width: 56px;
  height: 56px;
  border-radius: 0.5rem;
  overflow: hidden;
  flex-shrink: 0;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color 0.2s;
  opacity: 0.6;
}

.detail-thumbnail.active {
  border-color: var(--color-rose-500);
  opacity: 1;
}

.detail-thumbnail:hover {
  opacity: 0.9;
}

.detail-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Detail Info */
.detail-info {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
}

@media (min-width: 640px) {
  .detail-info {
    padding: 2rem;
    overflow-y: auto;
  }
}

.detail-category-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid;
  width: fit-content;
}

.detail-nuevo-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--color-amber-100);
  color: var(--color-amber-700);
  border: 1px solid var(--color-amber-400);
  width: fit-content;
}

.detail-availability-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  width: fit-content;
}

.detail-availability-badge.available {
  background: var(--color-green-100);
  color: var(--color-green-700);
}

.detail-availability-badge.limited {
  background: var(--color-amber-100);
  color: var(--color-amber-700);
}

.detail-availability-badge.sold-out {
  background: var(--color-red-100);
  color: var(--color-red-500);
}

.detail-availability-badge.hidden-badge {
  display: none;
}

.detail-name {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.025em;
  line-height: 1.3;
}

.detail-desc {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.detail-price {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
}

.detail-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.detail-fav-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.detail-fav-btn:hover {
  border-color: var(--color-rose-500);
  color: var(--color-rose-500);
}

.detail-fav-btn.is-fav {
  background: var(--color-rose-500);
  border-color: var(--color-rose-500);
  color: white;
}

.detail-fav-btn.is-fav svg {
  fill: white;
}

.detail-share-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.detail-share-btn:hover {
  border-color: var(--text-secondary);
  color: var(--text-secondary);
}

.detail-whatsapp-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 0.75rem;
  background: var(--color-green-600);
  color: white;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.detail-whatsapp-btn:hover {
  background: var(--color-green-700);
}

/* Related Products */
.detail-related {
  margin-top: 1rem;
}

.detail-related-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.detail-related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.detail-related-card {
  background: var(--bg-secondary);
  border-radius: 0.5rem;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid var(--border-color);
}

.detail-related-card:hover {
  border-color: var(--text-faint);
}

.detail-related-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.detail-related-name {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 0.375rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ============ Image Zoom Modal ============ */
.zoom-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease-out;
}

.zoom-modal-content {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50vh;
  max-height: 85vh;
  width: 95vw;
  max-width: 48rem;
}

.zoom-image {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 0.5rem;
}

.zoom-close-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.zoom-close-btn:hover {
  background: rgba(255, 255, 255, 0.4);
}

/* ============ FAQ Section ============ */
.faq-section {
  background: var(--bg-primary);
  border-top: 1px solid var(--border-color);
  transition: background-color 0.3s, border-color 0.3s;
}

.faq-inner {
  max-width: 48rem;
  margin: 0 auto;
  padding: 3rem 1rem;
}

.faq-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  text-align: center;
  letter-spacing: -0.025em;
}

.faq-subtitle {
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 0.5rem;
  margin-bottom: 2rem;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.faq-item {
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  overflow: hidden;
  transition: border-color 0.2s;
}

.faq-item.open {
  border-color: var(--text-faint);
}

.faq-question {
  width: 100%;
  padding: 1rem 1.25rem;
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: color 0.2s;
}

.faq-question:hover {
  color: var(--text-secondary);
}

.faq-chevron {
  flex-shrink: 0;
  transition: transform 0.3s;
  color: var(--text-faint);
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

.faq-item.open .faq-answer {
  max-height: 200px;
}

.faq-answer p {
  padding: 0 1.25rem 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ============ Floating Buttons ============ */
.floating-whatsapp {
  position: fixed;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 30;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.floating-whatsapp-btn {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--color-green-500);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 25px -5px rgba(34, 197, 94, 0.4);
  transition: all 0.3s;
}

.floating-whatsapp-btn:hover {
  background: var(--color-green-600);
  transform: scale(1.1);
}

.floating-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--color-rose-500);
  color: white;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.floating-label {
  display: none;
}

@media (min-width: 640px) {
  .floating-label {
    display: block;
    font-size: 10px;
    font-weight: 600;
    color: var(--color-green-700);
    background: #f0fdf4;
    padding: 2px 8px;
    border-radius: 9999px;
    border: 1px solid #bbf7d0;
    white-space: nowrap;
  }
}

.floating-fav-bar {
  position: fixed;
  bottom: 1.5rem;
  right: 1rem;
  z-index: 30;
}

.floating-fav-btn {
  height: 48px;
  padding: 0 1rem;
  border: none;
  border-radius: 0.75rem;
  background: var(--text-primary);
  color: var(--bg-primary);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 20px 40px -10px rgba(28, 25, 23, 0.3);
  transition: all 0.2s;
}

.floating-fav-btn:hover {
  opacity: 0.9;
}

.floating-fav-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: var(--color-rose-500);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
}

/* ============ Toast ============ */
.toast-container {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

.toast {
  background: var(--text-primary);
  color: var(--bg-primary);
  padding: 0.75rem 1.25rem;
  border-radius: 0.75rem;
  box-shadow: var(--shadow-xl);
  font-size: 0.875rem;
  animation: toastIn 0.3s ease-out, toastOut 0.3s ease-in 1.7s forwards;
  pointer-events: auto;
  max-width: 20rem;
  text-align: center;
}

.toast-title {
  font-weight: 600;
}

.toast-desc {
  font-size: 0.75rem;
  opacity: 0.7;
  margin-top: 2px;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(1rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes toastOut {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-1rem); }
}

/* ============ Footer ============ */
.footer {
  background: var(--color-stone-900);
  color: var(--color-stone-400);
  margin-top: auto;
}

.footer-inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: 2rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 640px) {
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    padding: 2.5rem 1rem;
  }
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.footer-brand-name {
  color: white;
  font-weight: 600;
  font-size: 0.875rem;
}

.footer-brand-sub {
  font-size: 0.75rem;
}

.footer-info {
  font-size: 0.75rem;
  text-align: center;
}

@media (min-width: 640px) {
  .footer-info {
    text-align: right;
  }
}

.footer-highlight {
  color: var(--color-stone-500);
}

/* ============ Placeholder Image ============ */
.placeholder-img {
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-img::after {
  content: 'Imagen no disponible';
  color: var(--text-faint);
  font-size: 0.75rem;
  position: absolute;
}

/* ============ Smooth Transitions ============ */
.product-grid.fade-transition .product-card {
  transition: opacity 0.25s ease-out, transform 0.3s ease-out, box-shadow 0.3s;
}

/* ============ Dark Mode Special Cases ============ */
[data-theme="dark"] .announcement-banner {
  background: var(--color-rose-700);
}

[data-theme="dark"] .product-nuevo-badge {
  background: var(--color-stone-800);
  color: var(--color-amber-400);
  border-color: var(--color-amber-700);
}

[data-theme="dark"] .detail-nuevo-badge {
  background: var(--color-stone-800);
  color: var(--color-amber-400);
  border-color: var(--color-amber-700);
}

[data-theme="dark"] .fav-heart-btn {
  background: rgba(41, 37, 36, 0.9);
}

[data-theme="dark"] .fav-heart-btn.is-fav {
  background: var(--color-rose-500);
}

[data-theme="dark"] .share-card-btn {
  background: rgba(41, 37, 36, 0.9);
}

[data-theme="dark"] .consult-card-btn {
  background: var(--color-green-700);
}

[data-theme="dark"] .detail-thumbnail {
  opacity: 0.5;
}

[data-theme="dark"] .detail-thumbnail.active {
  opacity: 1;
}

[data-theme="dark"] .shimmer-card::before {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.04) 40%,
    rgba(255, 255, 255, 0.08) 50%,
    rgba(255, 255, 255, 0.04) 60%,
    transparent 100%
  );
}

[data-theme="dark"] .product-availability-badge.available {
  background: rgba(34, 197, 94, 0.2);
}

[data-theme="dark"] .product-availability-badge.limited {
  background: rgba(245, 158, 11, 0.2);
}

[data-theme="dark"] .product-availability-badge.sold-out {
  background: rgba(239, 68, 68, 0.2);
}

[data-theme="dark"] .price-clear-btn:hover {
  background: rgba(244, 63, 94, 0.15);
}

[data-theme="dark"] .floating-label {
  background: var(--color-stone-800);
  color: var(--color-green-500);
  border-color: var(--color-stone-700);
}

/* ============ Cart Button (Header) ============ */
.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--color-sky-500);
  color: white;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: badgePop 0.2s ease-out;
}

/* ============ Cart Card Button (on product card) ============ */
.cart-card-btn {
  position: absolute;
  bottom: 10px;
  right: 58px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: var(--shadow-md);
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  color: var(--text-faint);
  opacity: 0;
  transform: translateY(8px);
}

.product-card:hover .cart-card-btn {
  opacity: 1;
  transform: translateY(0);
}

.cart-card-btn:hover {
  color: var(--color-sky-500);
}

.cart-card-btn.is-in-cart {
  background: var(--color-sky-500);
  color: white;
  opacity: 1;
  transform: translateY(0) scale(1.1);
}

[data-theme="dark"] .cart-card-btn {
  background: rgba(41, 37, 36, 0.9);
}

[data-theme="dark"] .cart-card-btn.is-in-cart {
  background: var(--color-sky-500);
}

/* ============ Cart Sidebar ============ */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 50;
  animation: fadeIn 0.2s ease-out;
}

.cart-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 28rem;
  background: var(--bg-primary);
  z-index: 51;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease-out;
}

.cart-sidebar.open {
  transform: translateX(0);
}

@media (max-width: 639px) {
  .cart-sidebar {
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    max-width: none;
    max-height: 85vh;
    border-radius: 1.25rem 1.25rem 0 0;
    transform: translateY(100%);
    transition: transform 0.3s ease-out;
  }

  .cart-sidebar.open {
    transform: translateY(0);
  }
}

.cart-header {
  padding: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.cart-header-content {
  flex: 1;
}

.cart-title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
}

.cart-header-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: var(--bg-tertiary);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.cart-description {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.close-cart-btn {
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

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

/* Cart Empty */
.cart-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.5rem;
}

.cart-empty-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-faint);
}

.cart-empty-title {
  font-weight: 500;
  color: var(--text-secondary);
}

.cart-empty-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Cart Items */
.cart-items-container {
  flex: 1;
  overflow-y: auto;
}

.cart-items {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.cart-item {
  display: flex;
  gap: 0.75rem;
  padding: 0.75rem;
  background: var(--bg-secondary);
  border-radius: 0.75rem;
  transition: background-color 0.3s;
}

.cart-item-image {
  width: 64px;
  height: 80px;
  border-radius: 0.5rem;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-tertiary);
}

.cart-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-details {
  flex: 1;
  min-width: 0;
}

.cart-item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

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

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

.cart-item-remove {
  flex-shrink: 0;
  padding: 4px;
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  border-radius: 4px;
  transition: color 0.2s;
}

.cart-item-remove:hover {
  color: var(--color-sky-500);
}

.cart-item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
}

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

/* Cart Footer */
.cart-footer {
  border-top: 1px solid var(--border-color);
  padding: 1.25rem;
}

.cart-footer .whatsapp-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 0.75rem;
  background: var(--color-green-600);
  color: white;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: background 0.2s;
  margin-bottom: 0.5rem;
}

.cart-footer .whatsapp-btn:hover {
  background: var(--color-green-700);
}

.clear-cart-btn {
  width: 100%;
  padding: 0.5rem;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.875rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  transition: color 0.2s;
}

.clear-cart-btn:hover {
  color: var(--color-sky-500);
}

/* Floating Cart Bar */
.floating-cart-bar {
  position: fixed;
  bottom: 4.5rem;
  right: 1rem;
  z-index: 30;
}

.floating-cart-btn {
  height: 48px;
  padding: 0 1rem;
  border: none;
  border-radius: 0.75rem;
  background: var(--color-sky-500);
  color: white;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 20px 40px -10px rgba(14, 165, 233, 0.3);
  transition: all 0.2s;
}

.floating-cart-btn:hover {
  opacity: 0.9;
}

.floating-cart-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.3);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
}

/* ============ Detail Cart Button ============ */
.detail-cart-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.detail-cart-btn:hover {
  border-color: var(--color-sky-500);
  color: var(--color-sky-500);
}

.detail-cart-btn.is-in-cart {
  background: var(--color-sky-500);
  border-color: var(--color-sky-500);
  color: white;
}

/* ============ Image Carousel ============ */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  transition: background 0.2s;
}

.carousel-arrow:hover {
  background: rgba(0, 0, 0, 0.7);
}

.carousel-arrow-prev {
  left: 0.75rem;
}

.carousel-arrow-next {
  right: 0.75rem;
}

.carousel-dots {
  position: absolute;
  bottom: 3.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 3;
}

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

.carousel-dot.active {
  background: white;
  transform: scale(1.3);
}

.carousel-dot:hover {
  background: rgba(255, 255, 255, 0.8);
}
