/* ========================================
   BIMMERS GT - Estilos Personalizados
   ======================================== */

:root {
  --primary-blue: #0066CC;
  --primary-dark: #004C99;
  --primary-light: #3399FF;
  --secondary-black: #1a1a1a;
  --gray-light: #f8f9fa;
  --gray-medium: #6c757d;
  --gray-dark: #343a40;
  --white: #ffffff;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.15);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.2);
  --transition: all 0.3s ease;
}

/* ========================================
   Estilos Generales
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--gray-light);
  color: var(--secondary-black);
  line-height: 1.6;
  overflow-x: hidden;
}

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

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

/* ========================================
   Header / Navbar
   ======================================== */
.navbar {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-blue) 100%);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 0.5rem 0;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--white) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  padding: 0;
  line-height: 1;
}

.navbar-brand img {
  border-radius: 4px;
  object-fit: contain;
  height: 120px;
  width: auto;
  margin-top: -25px;
  margin-bottom: -25px;
}

@media (max-width: 767px) {
  .navbar-brand img {
    height: 70px !important; /* Aumentado de 55px a 70px */
    margin-top: 0;
    margin-bottom: 0;
    filter: brightness(1.3) contrast(1.1) drop-shadow(0 0 10px rgba(0,0,0,0.8)) drop-shadow(0 0 20px rgba(0,0,0,0.6)); /* Más brillo, contraste y sombra negra con glow */
  }
}

/* Iconos siempre visibles en la barra (móvil y desktop) */
@media (max-width: 991px) {
  .navbar .d-flex.align-items-center.gap-3 {
    display: flex !important;
    order: 3;
    margin-left: auto;
  }
  
  .navbar-brand {
    flex-grow: 1;
  }
}

.nav-link {
  color: rgba(255,255,255,0.9) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  transition: var(--transition);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--white) !important;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--white);
  transition: var(--transition);
}

.nav-link:hover::after {
  width: 80%;
}

/* Buscador en Navbar (Desktop) */
.navbar-search {
  position: relative;
  max-width: 500px;
}

.navbar-search.d-none.d-xl-flex {
  position: relative;
}

.navbar-search.d-none.d-xl-flex input {
  border-radius: 50px;
  border: none;
  padding: 0.6rem 1.2rem 0.6rem 2.8rem;
  width: 250px;
  font-size: 0.9rem;
  background: rgba(255,255,255,0.95);
  transition: var(--transition);
}

.navbar-search.d-none.d-xl-flex input:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
  background: var(--white);
  width: 300px;
}

.navbar-search.d-none.d-xl-flex i {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-medium);
}

/* Buscador en Navbar (Móvil/Tablet) */
.navbar-search.d-xl-none .input-group {
  max-width: 100%;
}

.navbar-search.d-xl-none .form-control {
  border-radius: 50px 0 0 50px !important;
  border: none;
  padding: 0.6rem 1rem;
  font-size: 0.9rem;
  background: rgba(255,255,255,0.95);
}

.navbar-search.d-xl-none .form-control:focus {
  box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
  background: var(--white);
}

.navbar-search.d-xl-none .btn-primary {
  border-radius: 0 50px 50px 0 !important;
  background: var(--white);
  color: var(--primary-blue);
  border: none;
  padding: 0.6rem 1rem;
}

.navbar-search.d-xl-none .btn-primary:hover {
  background: var(--primary-blue);
  color: var(--white);
}

/* Icono del carrito y Favoritos */
.cart-icon-wrapper,
.nav-icon-wrapper {
  position: relative;
  color: var(--white);
  font-size: 1.3rem;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
}

.cart-icon-wrapper:hover,
.nav-icon-wrapper:hover {
  transform: scale(1.15);
  background: rgba(255,255,255,0.2);
}

.nav-icon-wrapper i.fa-heart {
  transition: all 0.3s ease;
}

.nav-icon-wrapper:hover i.fa-heart {
  color: #ff4757;
  transform: scale(1.2);
}

/* Botón de favoritos en cards */
.product-action-btn.wishlist {
  background: var(--white);
  color: #ff4757;
  border: 2px solid #ff4757;
}

.product-action-btn.wishlist:hover,
.product-action-btn.wishlist.active {
  background: #ff4757;
  color: var(--white);
}

.product-action-btn.wishlist.active i {
  animation: heartBeat 0.5s ease;
}

@keyframes heartBeat {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.3); }
}

.cart-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ff4757;
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* Redes sociales en header */
.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-links a {
  color: var(--white);
  font-size: 1.2rem;
  transition: var(--transition);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
}

.social-links a:hover {
  background: var(--white);
  transform: translateY(-3px);
}

.social-links a.facebook:hover { color: #1877F2; }
.social-links a.instagram:hover { color: #E4405F; }
.social-links a.tiktok:hover { color: #000000; }

/* Hamburger menu */
.navbar-toggler {
  border: none;
  padding: 0.5rem;
}

.navbar-toggler:focus {
  box-shadow: none;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ========================================
   Hero Banner
   ======================================== */
.hero-banner {
  background: linear-gradient(135deg, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.5) 50%, rgba(0,0,0,0.6) 100%),
              url('../img/banners/Banner.jpg');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: scroll;
  min-height: 550px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
  filter: brightness(0.7);
}

@media (max-width: 767px) {
  .hero-banner {
    background-attachment: scroll;
    min-height: 450px;
    background-position: center 30%;
  }
}

@media (min-width: 768px) and (max-width: 1024px) {
  .hero-banner {
    min-height: 500px;
  }
}

.hero-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 50% 50%, transparent 0%, rgba(0,0,0,0.3) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 2rem;
  max-width: 900px;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  margin-bottom: 1rem;
  text-shadow: 
    3px 3px 0px rgba(0,0,0,0.8),
    4px 4px 0px rgba(0,0,0,0.6),
    5px 5px 15px rgba(0,0,0,0.9),
    0 0 30px rgba(255,255,255,0.3);
  letter-spacing: 1px;
  text-transform: uppercase;
  animation: fadeInUp 0.8s ease;
  line-height: 1.3;
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  margin-bottom: 2rem;
  opacity: 1;
  font-weight: 700;
  text-shadow: 
    2px 2px 0px rgba(0,0,0,1),
    3px 3px 0px rgba(0,0,0,0.9),
    4px 4px 8px rgba(0,0,0,1),
    5px 5px 15px rgba(0,0,0,0.8),
    0 0 35px rgba(255,255,255,0.5),
    0 0 70px rgba(255,255,255,0.3);
  animation: fadeInUp 0.8s ease 0.2s backwards;
  line-height: 1.5;
  letter-spacing: 0.5px;
}

/* Estadísticas del Banner */
.stat-item {
  text-align: center;
  padding: 1.5rem 1rem;
  transition: transform 0.3s ease;
}

.stat-item:hover {
  transform: translateY(-5px);
}

.stat-number {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  color: #ffffff;
  text-shadow: 
    2px 2px 0px rgba(0,0,0,1),
    3px 3px 0px rgba(0,0,0,0.9),
    4px 4px 10px rgba(0,0,0,1),
    0 0 40px rgba(255,255,255,0.4),
    0 0 80px rgba(255,255,255,0.2),
    0 0 120px rgba(255,255,255,0.1);
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
  line-height: 1;
}

.stat-label {
  font-size: clamp(0.9rem, 2vw, 1.1rem);
  font-weight: 600;
  color: #ffffff;
  text-shadow: 
    1px 1px 2px rgba(0,0,0,1),
    2px 2px 4px rgba(0,0,0,0.9),
    0 0 20px rgba(255,255,255,0.3);
  letter-spacing: 1px;
  text-transform: uppercase;
  opacity: 0.95;
}

/* Buscador tipo eBay */
.ebay-search-container {
  animation: fadeInUp 0.8s ease 0.4s backwards;
  max-width: 650px;
  margin: 0 auto;
}

.ebay-search {
  display: flex;
  background: rgba(255, 255, 255, 0.98);
  border-radius: 50px;
  padding: 0.35rem;
  box-shadow: 
    0 10px 40px rgba(0,0,0,0.3),
    0 0 0 1px rgba(255,255,255,0.1);
  max-width: 100%;
  margin: 0 auto;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.ebay-search:focus-within {
  box-shadow: 
    0 15px 50px rgba(0,0,0,0.4),
    0 0 0 2px rgba(255,255,255,0.3),
    0 0 30px rgba(255,255,255,0.2);
  transform: translateY(-2px);
}

.ebay-search input {
  flex: 1;
  border: none;
  padding: 0.85rem 1.5rem;
  font-size: 0.95rem;
  border-radius: 50px;
  outline: none;
  background: transparent;
  color: #333;
}

.ebay-search input::placeholder {
  color: #999;
}

.ebay-search button {
  background: linear-gradient(135deg, #0066CC 0%, #004C99 100%);
  color: var(--white);
  border: none;
  padding: 0.85rem 1.8rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 4px 15px rgba(0,102,204,0.4),
    0 0 0 1px rgba(255,255,255,0.2);
}

.ebay-search button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.ebay-search button:hover::before {
  left: 100%;
}

.ebay-search button:hover {
  transform: scale(1.08) translateY(-2px);
  box-shadow: 
    0 8px 25px rgba(0,102,204,0.5),
    0 0 40px rgba(255,255,255,0.3),
    0 0 0 1px rgba(255,255,255,0.3);
  background: linear-gradient(135deg, #0073E6 0%, #0059B3 100%);
}

.ebay-search button:active {
  transform: scale(0.98);
}

.ebay-search button i {
  font-size: 1.1rem;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ========================================
   Secciones
   ======================================== */
.section {
  padding: 4rem 0;
}

.section-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--secondary-black);
  margin-bottom: 0.5rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-blue), var(--primary-light));
  border-radius: 2px;
}

.section-subtitle {
  color: var(--gray-medium);
  margin-bottom: 2.5rem;
}

/* ========================================
   Categorías - Carrusel
   ======================================== */
.categories-section {
  position: relative;
  overflow: hidden;
}

.categories-carousel-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 0;
}

.categories-carousel {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
  padding: 0.5rem;
  flex: 1;
}

.categories-carousel::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.categories-carousel .category-card {
  flex: 0 0 auto;
  width: 140px;
}

/* Flechas del Carrusel */
.carousel-arrow {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-dark) 100%);
  color: var(--white);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  transition: all 0.3s ease;
  box-shadow: 
    0 4px 15px rgba(0,102,204,0.4),
    0 0 0 1px rgba(255,255,255,0.2);
  flex-shrink: 0;
  z-index: 10;
}

.carousel-arrow:hover {
  transform: scale(1.15);
  box-shadow: 
    0 6px 20px rgba(0,102,204,0.6),
    0 0 30px rgba(255,255,255,0.3);
  background: linear-gradient(135deg, #0073E6 0%, #0059B3 100%);
}

.carousel-arrow:active {
  transform: scale(0.95);
}

.carousel-arrow i {
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* Indicadores */
.carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(0,102,204,0.3);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.carousel-indicator.active {
  background: var(--primary-blue);
  transform: scale(1.3);
  border-color: var(--primary-dark);
  box-shadow: 0 0 10px rgba(0,102,204,0.5);
}

.carousel-indicator:hover {
  background: var(--primary-blue);
  transform: scale(1.2);
}

/* Category Card - Carrusel */
.categories-carousel .category-card {
  background: var(--white);
  border-radius: 16px;
  padding: 1.5rem 1rem;
  text-align: center;
  box-shadow: 
    0 4px 15px rgba(0,0,0,0.1),
    0 0 0 1px rgba(0,0,0,0.05);
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  cursor: pointer;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.categories-carousel .category-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0,102,204,0.1) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.categories-carousel .category-card:hover::before {
  opacity: 1;
}

.categories-carousel .category-card:hover {
  transform: translateY(-10px) scale(1.05);
  box-shadow: 
    0 15px 35px rgba(0,102,204,0.2),
    0 0 0 2px var(--primary-blue);
  border-color: var(--primary-blue);
}

.category-icon {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-light) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  color: var(--white);
  font-size: 1.8rem;
  transition: all 0.3s ease;
  box-shadow: 
    0 4px 15px rgba(0,102,204,0.3),
    inset 0 2px 10px rgba(255,255,255,0.2);
}

.categories-carousel .category-card:hover .category-icon {
  transform: rotate(360deg) scale(1.1);
  box-shadow: 
    0 6px 20px rgba(0,102,204,0.5),
    0 0 30px rgba(0,102,204,0.3);
}

.category-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--secondary-black);
  line-height: 1.3;
}

/* ========================================
   Cards de Productos
   ======================================== */
.products-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 576px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.product-card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
}

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

.product-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
  color: var(--white);
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  z-index: 10; /* Badge SIEMPRE al frente */
  box-shadow: 0 4px 15px rgba(255,107,107,0.4);
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.product-image-wrapper {
  position: relative;
  overflow: hidden;
  padding-top: 85%; /* Proporción más cuadrada para mejor visualización */
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 0; /* El badge (z-index 10) siempre estará encima */
}

.product-image-wrapper::before {
  content: '\f03e'; /* Icono de imagen de Font Awesome */
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 3rem;
  color: #dee2e6;
  z-index: 0;
}

.product-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain; /* Mantiene proporción original sin recortar */
  transition: var(--transition);
  opacity: 1;
  z-index: 1;
  background: transparent;
}

.product-card:hover .product-image {
  transform: scale(1.08);
  z-index: 1; /* La imagen se mantiene atrás */
}

.product-actions {
  position: absolute;
  bottom: 10px; /* Siempre visible en la parte inferior */
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(10px);
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  opacity: 0;
  z-index: 5; /* Botones debajo del badge (z-index 10) */
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  border-radius: 50px;
}

.product-card:hover .product-actions {
  bottom: 10px;
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  z-index: 5;
}

.product-action-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: var(--primary-blue);
  color: var(--white);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 3; /* Botones siempre en primer plano */
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.product-action-btn:hover {
  background: var(--primary-dark);
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.product-action-btn.wishlist {
  background: var(--white);
  color: #ff6b6b;
  border: 2px solid #ff6b6b;
}

.product-action-btn.wishlist:hover {
  background: #ff6b6b;
  color: var(--white);
}

.product-info {
  padding: 1.25rem;
}

.product-category {
  font-size: 0.75rem;
  color: var(--primary-blue);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.5rem;
}

.product-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--secondary-black);
  margin-bottom: 0.75rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-price-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.product-price {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary-blue);
}

.product-original-price {
  font-size: 0.9rem;
  color: var(--gray-medium);
  text-decoration: line-through;
}

.product-stock {
  font-size: 0.75rem;
  color: #28a745;
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

/* ========================================
   Modal de Detalles del Producto
   ======================================== */
.product-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  overflow-y: auto;
}

.product-modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(5px);
}

.product-modal-content {
  position: relative;
  background: var(--white);
  border-radius: 20px;
  max-width: 900px;
  width: 90%;
  margin: 2rem auto;
  overflow: hidden;
  box-shadow: 0 25px 100px rgba(0,0,0,0.3);
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-50px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.product-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--white);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--secondary-black);
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  z-index: 10;
  transition: all 0.3s ease;
}

.product-modal-close:hover {
  background: #ff4757;
  color: var(--white);
  transform: rotate(90deg);
}

.product-modal-body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

@media (min-width: 768px) {
  .product-modal-body {
    grid-template-columns: 1fr 1fr;
  }
}

.product-modal-image {
  position: relative;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  min-height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

@media (min-width: 768px) {
  .product-modal-image {
    min-height: 550px; /* Más alto para mejor visualización */
  }
}

.product-modal-image::before {
  content: '\f03e';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 5rem;
  color: #dee2e6;
  z-index: 0;
}

.product-modal-image img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Mantiene proporción original sin recortar */
  position: absolute;
  top: 0;
  left: 0;
  transition: transform 0.3s ease;
  z-index: 1;
}

.product-modal-image:hover img {
  transform: scale(1.05);
  cursor: zoom-in;
}

/* Skeleton loading para modal */
.product-modal-image.loading {
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.product-modal-info {
  padding: 2rem;
  display: flex;
  flex-direction: column;
}

.product-modal-category {
  font-size: 0.85rem;
  color: var(--primary-blue);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.product-modal-category i {
  font-size: 1.2rem;
}

.product-modal-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--secondary-black);
  margin-bottom: 1rem;
  line-height: 1.3;
}

.product-modal-price {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.product-modal-price-current {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 900;
  color: var(--primary-blue);
}

.product-modal-price-original {
  font-size: 1.25rem;
  color: var(--gray-medium);
  text-decoration: line-through;
}

.product-modal-description {
  color: var(--gray-dark);
  line-height: 1.7;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.product-modal-stock {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: #d4edda;
  border-radius: 10px;
  margin-bottom: 1.5rem;
}

.product-modal-stock.low {
  background: #fff3cd;
}

.product-modal-stock.out {
  background: #f8d7da;
}

.product-modal-stock i {
  font-size: 1.2rem;
  color: #28a745;
}

.product-modal-stock.low i {
  color: #ffc107;
}

.product-modal-stock.out i {
  color: #dc3545;
}

.product-modal-actions {
  display: flex;
  gap: 1rem;
  margin-top: auto;
}

.product-modal-add-cart {
  flex: 1;
  background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-dark) 100%);
  color: var(--white);
  border: none;
  padding: 1rem 2rem;
  border-radius: 12px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: 0 4px 15px rgba(0,102,204,0.3);
}

.product-modal-add-cart:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,102,204,0.4);
}

.product-modal-add-cart:active {
  transform: translateY(0);
}

.product-modal-sku {
  font-size: 0.8rem;
  color: var(--gray-medium);
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

/* ========================================
   Filtros
   ======================================== */
.filters-sidebar {
  background: var(--white);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 100px;
}

.filter-group {
  margin-bottom: 1.5rem;
}

.filter-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--secondary-black);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.filter-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 8px;
  transition: var(--transition);
}

.filter-option:hover {
  background: var(--gray-light);
}

.filter-option input[type="radio"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--primary-blue);
}

.filter-option input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary-blue);
}

.price-range {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.price-range input {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  font-size: 0.9rem;
}

/* ========================================
   Carrito
   ======================================== */
.cart-table {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.cart-table thead {
  background: linear-gradient(135deg, var(--primary-blue), var(--primary-dark));
  color: var(--white);
}

.cart-table th {
  padding: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}

.cart-table td {
  padding: 1rem;
  vertical-align: middle;
  border-bottom: 1px solid #eee;
}

.cart-product {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.cart-product img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
}

.cart-product-info h5 {
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

.cart-quantity {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.cart-quantity button {
  width: 32px;
  height: 32px;
  border: 1px solid #dee2e6;
  background: var(--white);
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
}

.cart-quantity button:hover {
  background: var(--primary-blue);
  color: var(--white);
  border-color: var(--primary-blue);
}

.cart-quantity input {
  width: 50px;
  text-align: center;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  padding: 0.25rem;
}

.cart-summary {
  background: var(--white);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 100px;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid #eee;
}

.cart-summary-row:last-child {
  border-bottom: none;
  padding-top: 1rem;
  font-size: 1.25rem;
  font-weight: 800;
}

/* ========================================
   Checkout
   ======================================== */
.checkout-form {
  background: var(--white);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.form-section-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--secondary-black);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-control,
.form-select {
  border: 2px solid #eee;
  border-radius: 10px;
  padding: 0.75rem 1rem;
  transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(0,102,204,0.1);
}

.payment-methods {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 576px) {
  .payment-methods {
    grid-template-columns: repeat(2, 1fr);
  }
}

.payment-option {
  position: relative;
}

.payment-option input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.payment-option label {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  border: 2px solid #eee;
  border-radius: 12px;
  cursor: pointer;
  transition: var(--transition);
}

.payment-option input:checked + label {
  border-color: var(--primary-blue);
  background: rgba(0,102,204,0.05);
  box-shadow: 0 0 0 3px rgba(0,102,204,0.1);
}

.payment-option label:hover {
  border-color: var(--primary-blue);
  background: rgba(0,102,204,0.02);
}

.payment-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--primary-blue), var(--primary-light));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.3rem;
  flex-shrink: 0;
}

/* Detalles de Pago */
.payment-details {
  margin-top: 1rem;
  animation: slideDown 0.3s ease;
}

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

.payment-details .card {
  border: 1px solid #dee2e6;
  border-radius: 12px;
  background: #f8f9fa;
}

.payment-details .alert {
  border-radius: 8px;
  border: 1px solid #b8daff;
  background: #d1ecf1;
  color: #0c5460;
  padding: 1rem;
  margin-bottom: 1rem;
}

.payment-details .form-control:focus {
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 0.2rem rgba(0,102,204,0.25);
}

#card_type {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--primary-blue);
}

#card_type i {
  font-size: 1.5rem;
}

/* ========================================
   Botón de WhatsApp
   ======================================== */
.whatsapp-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  background: #25D366;
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  transition: var(--transition);
  animation: whatsappPulse 2s infinite;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  background: #20BA5A;
}

@keyframes whatsappPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  50% {
    box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
  }
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: linear-gradient(135deg, var(--secondary-black) 0%, #2d2d2d 100%);
  color: var(--white);
  padding: 4rem 0 2rem;
}

.footer-brand {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center; /* Centrado en todos los dispositivos */
}

.footer-brand img {
  border-radius: 4px;
  object-fit: contain;
  height: 80px;
  width: auto;
}

.footer-description {
  color: rgba(255,255,255,0.7);
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.footer-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.75rem;
}

.footer-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--primary-blue);
}

.footer-links {
  list-style: none;
  padding: 0;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-links a:hover {
  color: var(--primary-blue);
  padding-left: 5px;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
  color: rgba(255,255,255,0.7);
}

.footer-contact-item i {
  color: var(--primary-blue);
  font-size: 1.2rem;
  margin-top: 0.25rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 2rem;
  margin-top: 3rem;
  text-align: center;
  color: rgba(255,255,255,0.5);
}

/* ========================================
   Enlace E-PYME (Footer)
   ======================================== */
.epyme-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #ffffff;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  position: relative;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
}

.epyme-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
}

.epyme-link:hover::before {
  left: 100%;
}

.epyme-link:hover {
  background: rgba(255,255,255,0.1);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 10px 30px rgba(255,255,255,0.2);
}

.epyme-link .epyme-name {
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: all 0.3s ease;
}

.epyme-link:hover .epyme-name {
  transform: scale(1.1);
  letter-spacing: 1px;
}

.epyme-link img {
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  filter: brightness(0) invert(1) drop-shadow(0 0 10px rgba(255,255,255,0.3));
}

.epyme-link:hover img {
  transform: scale(1.15) rotate(5deg);
  filter: brightness(0) invert(1) drop-shadow(0 0 20px rgba(255,255,255,0.5));
}

.epyme-link:active {
  transform: translateY(-1px) scale(0.98);
}

/* ========================================
   Utilidades
   ======================================== */
.btn-primary-custom {
  background: linear-gradient(135deg, var(--primary-blue), var(--primary-dark));
  border: none;
  color: var(--white);
  padding: 0.75rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  transition: var(--transition);
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
}

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
}

.empty-state i {
  font-size: 5rem;
  color: var(--gray-medium);
  margin-bottom: 1.5rem;
  opacity: 0.5;
}

.empty-state h3 {
  color: var(--secondary-black);
  margin-bottom: 0.5rem;
}

.empty-state p {
  color: var(--gray-medium);
  margin-bottom: 1.5rem;
}

/* Toast notification */
.toast-notification {
  position: fixed;
  bottom: 100px;
  right: 20px;
  background: var(--white);
  padding: 1rem 1.5rem;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 1rem;
  z-index: 998;
  transform: translateX(150%);
  transition: transform 0.3s ease;
}

.toast-notification.show {
  transform: translateX(0);
}

.toast-notification.success {
  border-left: 4px solid #28a745;
}

.toast-notification.error {
  border-left: 4px solid #dc3545;
}

/* ========================================
   Media Queries - Mobile
   ======================================== */
@media (max-width: 767px) {
  /* Navbar */
  .navbar-brand span {
    display: none;
  }

  .social-links {
    display: none;
  }

  .hero-banner {
    min-height: 400px;
  }

  .section {
    padding: 3rem 0;
  }

  /* Carrusel de Categorías */
  .categories-carousel-wrapper {
    gap: 0.5rem;
  }

  .carousel-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }

  .categories-carousel .category-card {
    width: 120px;
  }

  .category-icon {
    width: 55px;
    height: 55px;
    font-size: 1.5rem;
  }

  .category-name {
    font-size: 0.8rem;
  }

  /* Tabla del carrito */
  .cart-table {
    font-size: 0.85rem;
  }

  .cart-table img {
    width: 60px;
    height: 60px;
  }

  /* Footer */
  .footer {
    padding: 3rem 0 1.5rem;
  }
  
  .footer-brand img {
    height: 60px;
  }
  
  .footer-description {
    font-size: 0.9rem;
    text-align: center;
    margin-bottom: 1rem;
  }
  
  .footer-title {
    font-size: 1rem;
    text-align: center;
    margin-bottom: 1rem;
  }
  
  .footer-title::after {
    left: 50%;
    transform: translateX(-50%);
  }
  
  .footer-links {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  .footer-links li {
    margin-bottom: 0.5rem;
  }
  
  .footer-links a {
    justify-content: center;
    font-size: 0.9rem;
  }
  
  .footer-contact-item {
    justify-content: center;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
  }
  
  .social-links {
    justify-content: center;
    margin-top: 1rem;
  }
  
  .footer .col-lg-4,
  .footer .col-lg-2,
  .footer .col-lg-3,
  .footer .col-md-6 {
    text-align: center;
    margin-bottom: 2rem;
  }
  
  .footer .col-md-6:last-child {
    margin-bottom: 0;
  }
  
  .footer-bottom {
    padding-top: 1.5rem;
    margin-top: 2rem;
  }
  
  .footer-bottom p {
    font-size: 0.85rem;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .epyme-link {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .epyme-link img {
    height: 35px !important;
  }
  
  .whatsapp-float {
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    bottom: 15px;
    right: 15px;
  }
}

@media (max-width: 575px) {
  .ebay-search-container {
    max-width: 100%;
    padding: 0 1rem;
  }

  .ebay-search {
    flex-direction: column;
    border-radius: 16px;
    padding: 0.5rem;
  }

  .ebay-search input {
    border-radius: 12px;
    margin-bottom: 0.5rem;
    padding: 0.75rem 1rem;
  }

  .ebay-search button {
    width: 100%;
    justify-content: center;
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
  }

  .product-actions {
    position: static;
    opacity: 1;
    background: transparent;
    padding: 0 1.25rem 1.25rem;
  }

  .product-action-btn {
    width: 45px;
    height: 45px;
  }
}
