/* ==========================================================================
   KITALURO - Premium Luxury CSS
   Dark Mode First Design System
   ========================================================================== */

/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   BASE STYLES & TYPOGRAPHY
   ========================================================================== */

/* Font Family Defaults */
body {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 400;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Remove default margins */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ==========================================================================
   HIDE SCROLLBAR UTILITY - Para galería deslizante
   ========================================================================== */

.hide-scrollbar {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;     /* Firefox */
}

.hide-scrollbar::-webkit-scrollbar {
  display: none;             /* Chrome, Safari, Opera */
}

/* ===========================================================================
   PREMIUM BRANDS SHOWCASE
   Desktop: Static elegant grid | Mobile: Smooth infinite marquee
   =========================================================================== */

.brands-showcase {
  padding: 4rem 1.5rem;
  background: linear-gradient(180deg, 
    rgba(249, 250, 251, 0.5) 0%, 
    rgba(255, 255, 255, 1) 50%, 
    rgba(249, 250, 251, 0.5) 100%);
  border-top: 1px solid rgba(229, 231, 235, 0.8);
  border-bottom: 1px solid rgba(229, 231, 235, 0.8);
}

.dark .brands-showcase {
  background: linear-gradient(180deg, 
    rgba(10, 10, 10, 0.5) 0%, 
    rgba(23, 23, 23, 1) 50%, 
    rgba(10, 10, 10, 0.5) 100%);
  border-top-color: rgba(64, 64, 64, 0.3);
  border-bottom-color: rgba(64, 64, 64, 0.3);
}

.brands-showcase__container {
  max-width: 1280px;
  margin: 0 auto;
}

/* Header */
.brands-showcase__header {
  text-align: center;
  margin-bottom: 3rem;
}

.brands-showcase__title {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.dark .brands-showcase__title {
  color: #f9fafb;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.15);
}

.brands-showcase__subtitle {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.dark .brands-showcase__subtitle {
  color: #9ca3af;
}

/* Desktop Grid (hidden on mobile) */
.brands-showcase__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  align-items: center;
  justify-items: center;
}

.brands-showcase__card {
  width: 100%;
  max-width: 200px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: transparent;
  border-radius: 12px;
  border: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dark .brands-showcase__card {
  background: transparent;
  border: none;
}

.brands-showcase__card:hover {
  transform: translateY(-4px);
}

.dark .brands-showcase__card:hover {
  background: transparent;
}

.brands-showcase__logo {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.brands-showcase__card:hover .brands-showcase__logo {
  transform: scale(1.05);
}

/* Mobile Marquee (hidden on desktop) */
.brands-showcase__marquee {
  display: none;
  position: relative;
  overflow: hidden;
  padding: 1rem 0;
}

.brands-showcase__marquee::before,
.brands-showcase__marquee::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 60px;
  z-index: 2;
  pointer-events: none;
}

.brands-showcase__marquee::before {
  left: 0;
  background: linear-gradient(90deg, 
    rgba(255, 255, 255, 1) 0%, 
    rgba(255, 255, 255, 0) 100%);
}

.brands-showcase__marquee::after {
  right: 0;
  background: linear-gradient(270deg, 
    rgba(255, 255, 255, 1) 0%, 
    rgba(255, 255, 255, 0) 100%);
}

.dark .brands-showcase__marquee::before {
  background: linear-gradient(90deg, 
    rgba(23, 23, 23, 1) 0%, 
    rgba(23, 23, 23, 0) 100%);
}

.dark .brands-showcase__marquee::after {
  background: linear-gradient(270deg, 
    rgba(23, 23, 23, 1) 0%, 
    rgba(23, 23, 23, 0) 100%);
}

.brands-showcase__marquee-track {
  display: flex;
  width: max-content;
  animation: brands-marquee-scroll 25s linear infinite;
}

.brands-showcase__marquee-group {
  display: flex;
  align-items: center;
  gap: 32px;
  padding-right: 32px;
  flex-shrink: 0;
}

.brands-showcase__marquee-item {
  width: 140px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  background: white;
  border-radius: 8px;
  border: 1px solid rgba(229, 231, 235, 0.5);
  padding: 0.75rem;
}

.dark .brands-showcase__marquee-item {
  background: rgba(38, 38, 38, 0.5);
  border-color: rgba(64, 64, 64, 0.3);
}

.brands-showcase__marquee-logo {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}

@keyframes brands-marquee-scroll {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-50%, 0, 0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .brands-showcase {
    padding: 3rem 1rem;
  }

  .brands-showcase__header {
    margin-bottom: 2rem;
  }

  .brands-showcase__title {
    font-size: 1.75rem;
  }

  .brands-showcase__subtitle {
    font-size: 0.75rem;
  }

  /* Mobile: 2-row grid instead of marquee */
  .brands-showcase__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .brands-showcase__card {
    max-width: 100%;
    height: 80px;
    padding: 1rem;
  }

  .brands-showcase__marquee {
    display: none;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .brands-showcase__marquee-track {
    animation: none;
  }

  .brands-showcase__marquee {
    overflow-x: auto;
  }

  .brands-showcase__marquee::before,
  .brands-showcase__marquee::after {
    display: none;
  }
}

/* ==========================================================================
   CUSTOM ANIMATIONS - Horizontal Bounce
   ========================================================================== */

@keyframes bounce-horizontal {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(-10px);
  }
}

@keyframes bounce-horizontal-reverse {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(10px);
  }
}

.animate-bounce-horizontal {
  animation: bounce-horizontal 2s ease-in-out infinite;
}

.animate-bounce-horizontal-reverse {
  animation: bounce-horizontal-reverse 2s ease-in-out infinite;
}

/* ==========================================================================
   CUSTOM SCROLLBAR - PREMIUM STYLE
   ========================================================================== */

/* Hide default scrollbar on Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
}

/* Webkit Browsers (Chrome, Safari, Edge) */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f3f4f6;
}

.dark ::-webkit-scrollbar-track {
  background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 10px;
}

.dark ::-webkit-scrollbar-thumb {
  background: #404040;
}

::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

.dark ::-webkit-scrollbar-thumb:hover {
  background: #666;
}

/* ==========================================================================
   CUSTOM UTILITY CLASSES
   ========================================================================== */

/* Scroll Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.4s ease-out; /* Reducido de 0.6s a 0.4s */
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Reveal variants con tiempos reducidos */
.reveal-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.5s ease-out; /* Reducido de 0.8s a 0.5s */
}

.reveal-left.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(50px);
  transition: all 0.5s ease-out; /* Reducido de 0.8s a 0.5s */
}

.reveal-right.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: all 0.5s ease-out; /* Reducido de 0.6s a 0.5s */
}

.reveal-scale.active {
  opacity: 1;
  transform: scale(1);
}

/* Product Cards - Sin reveal en desktop, con reveal en móvil */
@media (min-width: 1024px) {
  .product-card {
    opacity: 1 !important;
    transform: none !important;
  }
}

@media (max-width: 1023px) {
  .product-card {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s ease-out;
  }
  
  .product-card.reveal.active {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Text Glow Effect - Para títulos premium sobre fondos oscuros */
.text-glow {
  /* Modo claro: sombra sutil oscura */
  text-shadow: 
    0 2px 10px rgba(0, 0, 0, 0.1),
    0 4px 20px rgba(0, 0, 0, 0.05);
}

.dark .text-glow {
  /* Modo oscuro: glow blanco */
  text-shadow: 
    0 0 20px rgba(255, 255, 255, 0.2),
    0 0 40px rgba(255, 255, 255, 0.1),
    0 0 60px rgba(255, 255, 255, 0.05);
}

/* Gold Text Glow - Variante dorada para highlights */
.text-glow-gold {
  text-shadow: 
    0 0 20px rgba(250, 204, 21, 0.3),
    0 0 40px rgba(250, 204, 21, 0.2),
    0 0 60px rgba(250, 204, 21, 0.1);
}

/* Glass Panel Effect - Glassmorphism premium */
.glass-panel {
  background: rgba(10, 10, 10, 0.6);
  backdrop-filter: blur(12px) saturate(150%);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Light Glass Panel - Para modo claro */
.glass-panel-light {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(12px) saturate(150%);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

/* Premium Gradient Overlay */
.gradient-overlay {
  background: linear-gradient(
    135deg,
    rgba(10, 10, 10, 0.9) 0%,
    rgba(20, 20, 20, 0.8) 50%,
    rgba(10, 10, 10, 0.9) 100%
  );
}

/* Gold Gradient Text */
.text-gradient-gold {
  background: linear-gradient(135deg, #fde047 0%, #facc15 50%, #eab308 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Luxury Border Gradient */
.border-gradient-gold {
  border-image: linear-gradient(135deg, #fde047, #facc15, #eab308) 1;
}

/* ==========================================================================
   LUXURY TECH PALETTE - BLUE SAPPHIRE & RED CRIMSON
   ========================================================================== */

/* Blue Sapphire Glow - Tech Elements */
.tech-glow {
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
  transition: box-shadow 0.3s ease;
}

.tech-glow-subtle {
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

.tech-border {
  border-color: rgba(59, 130, 246, 0.3);
}

.tech-border-hover:hover {
  border-color: rgba(59, 130, 246, 0.8);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

/* Text Tech Accent */
.text-tech {
  color: #60a5fa;
  text-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

/* Navigation Active State - Botón cuadrado minimalista */
.nav-link-active {
  position: relative;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  border: 2px solid #3b82f6;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  color: #3b82f6 !important;
  font-weight: 700;
}

.dark .nav-link-active {
  background: rgba(10, 10, 10, 0.9);
  backdrop-filter: blur(8px);
  color: #60a5fa !important;
  border-color: #60a5fa;
}

.nav-link-active:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: #2563eb;
  color: #2563eb !important;
  transform: translateY(-1px);
}

.dark .nav-link-active:hover {
  background: rgba(10, 10, 10, 0.95) !important;
  border-color: #3b82f6;
  color: #3b82f6 !important;
}

/* Remover línea inferior para enlaces activos */
.nav-link-active .nav-underline {
  display: none;
}

/* Red Crimson CTAs - Conversion Focus */
.btn-crimson {
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
  color: white;
  padding: 0.875rem 2.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  letter-spacing: 0.025em;
  box-shadow: 0 10px 20px rgba(220, 38, 38, 0.4);
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
}

.btn-crimson:hover {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  box-shadow: 0 15px 30px rgba(220, 38, 38, 0.6);
  transform: translateY(-2px);
}

.dark .btn-crimson {
  box-shadow: 0 10px 15px -3px rgba(153, 27, 27, 0.5);
}

.dark .btn-crimson:hover {
  box-shadow: 0 15px 25px -5px rgba(153, 27, 27, 0.7), 
              0 0 20px rgba(220, 38, 38, 0.4);
}

/* Badge Offer - Red */
.badge-offer {
  background: #dc2626;
  color: white;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 10px rgba(220, 38, 38, 0.5);
}

/* Progress Bar Tech */
.progress-tech {
  background: #3b82f6;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
}

/* ==========================================================================
   HERO VIDEO BACKGROUND - LUXURY STYLES
   ========================================================================== */

/* Video Container - Optimización de performance */
.hero-video-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: -10;
}

/* Video Element - Optimizado para autoplay y performance */
.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  object-fit: cover;
  object-position: center;
  /* Optimización de renderizado */
  will-change: auto;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

/* Video Overlay - Dual Layer para legibilidad premium */
.video-overlay-dark {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 0;
  transition: background 0.3s ease;
}

.dark .video-overlay-dark {
  background: rgba(0, 0, 0, 0.7);
}

.video-overlay-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60%;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.8) 0%,
    rgba(0, 0, 0, 0.4) 50%,
    transparent 100%
  );
  z-index: 1;
  pointer-events: none;
}

/* Text Shadows para legibilidad sobre video */
.hero-text-shadow {
  text-shadow: 
    0 2px 10px rgba(0, 0, 0, 0.8),
    0 4px 20px rgba(0, 0, 0, 0.6),
    0 8px 40px rgba(0, 0, 0, 0.4);
}

/* Glassmorphism Button Premium - Para CTAs sobre video */
.btn-glass-premium {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px) saturate(150%);
  -webkit-backdrop-filter: blur(10px) saturate(150%);
  border: 2px solid rgba(255, 255, 255, 0.7);
  color: white;
  padding: 0.875rem 2.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  letter-spacing: 0.025em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateY(0);
  box-shadow: 
    0 4px 15px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-glass-premium:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 1);
  transform: translateY(-3px);
  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(255, 255, 255, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-glass-premium:active {
  transform: translateY(-1px);
}

/* Vignette Effect - Añade profundidad cinematográfica */
.video-vignette {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    ellipse at center,
    transparent 0%,
    transparent 50%,
    rgba(0, 0, 0, 0.3) 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* Video Loading State - Skeleton mientras carga */
.video-skeleton {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    #0a0a0a 0%,
    #171717 50%,
    #0a0a0a 100%
  );
  background-size: 200% 200%;
  animation: shimmer 3s ease-in-out infinite;
}

/* Responsive Video - Ajustes para móviles */
@media (max-width: 768px) {
  .hero-video {
    /* En móvil, priorizar ancho para videos verticales */
    width: 100%;
    height: auto;
    min-height: 100%;
  }
  
  .video-overlay-dark {
    background: rgba(0, 0, 0, 0.7);
  }
  
  .dark .video-overlay-dark {
    background: rgba(0, 0, 0, 0.8);
  }
}

/* Performance: Deshabilitar video en dispositivos de bajo rendimiento */
@media (prefers-reduced-motion: reduce) {
  .hero-video {
    display: none;
  }
  
  .video-skeleton {
    animation: none;
  }
}

/* ==========================================================================
   COMPONENT STYLES
   ========================================================================== */

/* Premium Button Base */
.btn-premium {
  padding: 0.75rem 2rem;
  font-weight: 500;
  letter-spacing: 0.025em;
  transition: all 0.3s ease;
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  transform: translateY(0);
}

.btn-premium:hover {
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.btn-premium:active {
  transform: translateY(0);
}

/* Gold CTA Button */
.btn-gold {
  padding: 0.75rem 2rem;
  font-weight: 500;
  letter-spacing: 0.025em;
  background: linear-gradient(to right, #facc15, #eab308);
  color: #000;
  border: none;
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(250, 204, 21, 0.5);
  transition: all 0.3s ease;
  transform: translateY(0);
}

.btn-gold:hover {
  background: linear-gradient(to right, #fde047, #facc15);
  box-shadow: 0 20px 25px -5px rgba(250, 204, 21, 0.6);
  transform: translateY(-2px);
}

.btn-gold:active {
  transform: translateY(0);
}

/* Dark Outline Button */
.btn-outline-dark {
  padding: 0.75rem 2rem;
  font-weight: 500;
  letter-spacing: 0.025em;
  border: 2px solid #404040;
  background: transparent;
  color: #e5e5e5;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  transform: translateY(0);
}

.btn-outline-dark:hover {
  background: #262626;
  border-color: #525252;
  transform: translateY(-2px);
}

/* Premium Card */
.card-premium {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-radius: 1rem;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 
              0 4px 6px -2px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.dark .card-premium {
  background: rgba(23, 23, 23, 0.5);
  border: 1px solid #262626;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3);
}

.card-premium:hover {
  border-color: #d1d5db;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
}

.dark .card-premium:hover {
  border-color: #404040;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Product Card - Luxury Tech Style */
.product-card {
  background: #ffffff;
  border-radius: 1rem;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.dark .product-card {
  background: rgba(10, 10, 10, 0.8);
  border: 2px solid #1f1f1f;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.product-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.12);
  transform: translateY(-8px) scale(1.02);
}

.dark .product-card:hover {
  border-color: rgba(59, 130, 246, 0.8);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 
              0 0 20px rgba(59, 130, 246, 0.3);
}

/* Input Premium Style */
.input-premium {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  background: #171717;
  border: 2px solid #262626;
  color: #e5e5e5;
  transition: border-color 0.3s ease;
}

.input-premium::placeholder {
  color: #737373;
}

.input-premium:focus {
  outline: none;
  border-color: #eab308;
}

/* Section Divider */
.section-divider {
  height: 1px;
  width: 100%;
  background: linear-gradient(to right, transparent, #404040, transparent);
}

/* ==========================================================================
   ANIMATIONS & TRANSITIONS
   ========================================================================== */

/* Fade In Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

/* Shimmer Effect */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.animate-shimmer {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 100%
  );
  background-size: 1000px 100%;
  animation: shimmer 2s infinite;
}

/* Pulse Glow */
@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(250, 204, 21, 0.3);
  }
  50% {
    box-shadow: 0 0 40px rgba(250, 204, 21, 0.5);
  }
}

.animate-pulse-glow {
  animation: pulseGlow 3s ease-in-out infinite;
}

/* ==========================================================================
   PRODUCT IMAGE OPTIMIZATION - PREMIUM QUALITY
   ========================================================================== */

/* Product Image Container - Fixed Aspect Ratio */
.product-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  background: linear-gradient(135deg, #f8f9fa 0%, #f1f3f5 100%);
  overflow: hidden;
  border-radius: 0.75rem;
  border: 1px solid rgba(229, 231, 235, 0.8);
  box-shadow: 
    inset 0 1px 3px rgba(0, 0, 0, 0.05),
    0 1px 2px rgba(0, 0, 0, 0.05);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.dark .product-image-wrapper {
  background: linear-gradient(135deg, #1a1a1a 0%, #141414 100%);
  border-color: rgba(42, 42, 42, 0.8);
  box-shadow: 
    inset 0 1px 3px rgba(0, 0, 0, 0.4),
    0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Product Image - Optimized for full visibility */
.product-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transform: scale(0.92);
  transition: 
    transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 0.5s ease,
    filter 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  filter: contrast(1.05) saturate(1.1) brightness(1.02);
  padding: 0.75rem;
  max-width: 100%;
  max-height: 100%;
}

.dark .product-image {
  filter: contrast(1.08) saturate(1.15) brightness(1);
  padding: 0.5rem;
}

/* Fade-in effect when loaded */
.product-image.loaded {
  opacity: 1;
  transform: scale(0.92);
}

/* Hover Zoom Effect - Premium Magnifier */
.product-image-wrapper:hover {
  border-color: rgba(209, 213, 219, 1);
  box-shadow: 
    0 8px 24px rgba(0, 0, 0, 0.12),
    0 0 0 1px rgba(59, 130, 246, 0.1),
    inset 0 1px 3px rgba(0, 0, 0, 0.05);
  transform: translateY(-2px);
}

.dark .product-image-wrapper:hover {
  border-color: rgba(64, 64, 64, 1);
  box-shadow: 
    0 12px 32px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(59, 130, 246, 0.2),
    inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

.product-image-wrapper:hover .product-image {
  transform: scale(1);
  filter: contrast(1.08) saturate(1.18) brightness(1.05);
}

.dark .product-image-wrapper:hover .product-image {
  filter: contrast(1.12) saturate(1.22) brightness(1.03);
}

/* Shimmer Loading Placeholder */
.product-image-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.5) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer-loading 2s ease-in-out infinite;
  opacity: 1;
  transition: opacity 0.5s ease;
  pointer-events: none;
  z-index: 2;
  border-radius: inherit;
}

.dark .product-image-wrapper::before {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
}

/* Hide shimmer when image is loaded */
.product-image-wrapper.image-loaded::before {
  opacity: 0;
}

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

/* Skeleton gradient background while loading */
.product-image-wrapper.loading {
  background: linear-gradient(
    110deg,
    #ececec 8%,
    #f5f5f5 18%,
    #ececec 33%
  );
  background-size: 200% 100%;
  animation: skeleton-pulse 1.8s ease-in-out infinite;
}

.dark .product-image-wrapper.loading {
  background: linear-gradient(
    110deg,
    #1a1a1a 8%,
    #262626 18%,
    #1a1a1a 33%
  );
}

@keyframes skeleton-pulse {
  0%, 100% {
    background-position: 0% 0%;
  }
  50% {
    background-position: 100% 0%;
  }
}

/* Quality Badge */
.product-image-quality-badge {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  background: rgba(255, 255, 255, 0.95);
  color: #2563eb;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  opacity: 0;
  transform: translateY(0.5rem);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  z-index: 3;
}

.dark .product-image-quality-badge {
  background: rgba(10, 10, 10, 0.95);
  color: #60a5fa;
  border-color: rgba(59, 130, 246, 0.3);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.product-image-wrapper:hover .product-image-quality-badge {
  opacity: 1;
  transform: translateY(0);
}

/* Prevent image dragging for better UX */
.product-image {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  user-select: none;
  pointer-events: none;
}

/* Progressive enhancement for sharp rendering */
@supports (image-rendering: -webkit-optimize-contrast) {
  .product-image {
    image-rendering: -webkit-optimize-contrast;
  }
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .product-image-wrapper {
    aspect-ratio: 1 / 1;
    border-radius: 0.625rem;
  }
  
  .product-image {
    padding: 0.5rem;
    transform: scale(0.90);
  }
  
  .product-image.loaded {
    transform: scale(0.90);
  }
  
  .product-image-wrapper:hover .product-image {
    transform: scale(0.95);
  }
  
  .product-image-quality-badge {
    font-size: 0.5rem;
    padding: 0.25rem 0.5rem;
  }
}

/* Tablet optimization */
@media (min-width: 641px) and (max-width: 1024px) {
  .product-image-wrapper {
    aspect-ratio: 3 / 4;
  }
  
  .product-image {
    padding: 0.625rem;
  }
}

/* High DPI displays optimization */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .product-image {
    image-rendering: -webkit-optimize-contrast;
  }
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .product-image,
  .product-image-wrapper,
  .product-image-wrapper::before {
    animation: none !important;
    transition: opacity 0.2s ease !important;
  }
  
  .product-image.wrapper:hover .product-image {
    transform: scale(0.92) !important;
  }
  
  .product-image.loaded {
    transform: scale(0.92);
  }
}

/* Loading state text indicator */
.product-image-wrapper.loading::after {
  content: 'Cargando...';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.75rem;
  font-weight: 500;
  color: #9ca3af;
  letter-spacing: 0.05em;
  z-index: 1;
  opacity: 0.6;
}

.dark .product-image-wrapper.loading::after {
  color: #525252;
}

/* ==========================================================================
   ACCESSIBILITY & PERFORMANCE
   ========================================================================== */

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Focus visible for keyboard navigation */
*:focus-visible {
  outline: 2px solid #facc15;
  outline-offset: 2px;
}

/* ==========================================================================
   PRINT STYLES
   ========================================================================== */

@media print {
  .no-print {
    display: none !important;
  }
  
  body {
    background: white !important;
    color: black !important;
  }
}

/* ✅ Variables CSS para temas */
:root {
  /* Modo Claro */
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --border-color: #e5e7eb;
  --shadow-color: rgba(0, 0, 0, 0.1);
}

.dark {
  /* Modo Oscuro */
  --bg-primary: #0a0a0a;
  --bg-secondary: #171717;
  --text-primary: #f5f5f5;
  --text-secondary: #a3a3a3;
  --border-color: #262626;
  --shadow-color: rgba(0, 0, 0, 0.5);
}

/* ========================================================================== */
/* LUX HERO BANNER - VIDEO COMPLETO SIN RECORTE                             */
/* ========================================================================== */

.lux-hero-banner {
  width: 100%;
  background: radial-gradient(circle at top, #f3f4f6 0%, #e5e7eb 55%, #d1d5db 100%);
  color: #111827;
  display: flex;
  justify-content: center;
  align-items: center;
  padding-inline: 1.5rem;
  padding-top: 1.5rem;
}

.dark .lux-hero-banner {
  background: radial-gradient(circle at top, #111827 0%, #020617 55%, #020617 100%);
  color: #f9fafb;
}

.lux-hero-media {
  position: relative;
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  height: clamp(320px, 60vh, 620px);
  background: #f9fafb;
  overflow: hidden;
  border-radius: 1.5rem;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.2),
    0 0 0 1px rgba(148, 163, 184, 0.25);
}

.dark .lux-hero-media {
  background: #000;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(148, 163, 184, 0.15);
}

.lux-hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  background: #f9fafb;
}

.dark .lux-hero-video {
  background: #000;
}

/* Texto separado para móviles, oculto por defecto */
.lux-hero-mobile-copy {
  display: none;
}

.lux-hero-overlay {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 1.75rem 1.5rem;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.75) 0%,
    rgba(255, 255, 255, 0.45) 40%,
    transparent 75%
  );
  border-radius: inherit;
}

.dark .lux-hero-overlay {
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.70) 0%,
    rgba(0, 0, 0, 0.40) 40%,
    transparent 75%
  );
}

.lux-hero-content {
  max-width: 560px;
}

.lux-hero-kicker {
  font-family: 'Outfit', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: #6b7280;
  margin-bottom: 0.75rem;
}

.dark .lux-hero-kicker {
  color: #9ca3af;
}

.lux-hero-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(2.5rem, 3.4vw, 3.8rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.9rem;
  color: #854d0e;
  text-shadow:
    0 0 25px rgba(217, 119, 6, 0.25),
    0 18px 35px rgba(0, 0, 0, 0.15);
}

.dark .lux-hero-title {
  color: #fefce8;
  text-shadow:
    0 0 25px rgba(250, 204, 21, 0.35),
    0 18px 35px rgba(0, 0, 0, 0.85);
}

.lux-hero-subtitle {
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #374151;
  max-width: 30rem;
  margin-bottom: 1.5rem;
}

.dark .lux-hero-subtitle {
  color: #f9fafb;
}

.lux-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
}

.lux-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 2.4rem;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #facc15 0%, #eab308 100%);
  color: #111827;
  font-family: 'Outfit', system-ui, sans-serif;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.8rem;
  text-decoration: none;
  box-shadow:
    0 12px 30px rgba(250, 204, 21, 0.45),
    0 0 0 1px rgba(0, 0, 0, 0.6);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.lux-btn-primary:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #fde047 0%, #facc15 100%);
  box-shadow:
    0 18px 40px rgba(250, 204, 21, 0.65),
    0 0 0 1px rgba(0, 0, 0, 0.7);
}

.lux-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 2.2rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.55);
  background: rgba(15, 23, 42, 0.60);
  backdrop-filter: blur(14px) saturate(160%);
  color: #f9fafb;
  font-family: 'Outfit', system-ui, sans-serif;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.75rem;
  text-decoration: none;
  box-shadow:
    0 14px 35px rgba(15, 23, 42, 0.85);
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.lux-btn-ghost:hover {
  border-color: rgba(249, 250, 251, 0.9);
  background: rgba(15, 23, 42, 0.85);
  transform: translateY(-1px);
}

/* Ajuste para botón ghost en móvil (fondo claro) */
@media (max-width: 640px) {
  .lux-hero-mobile-actions .lux-btn-ghost {
    background: transparent;
    border-color: var(--text-secondary);
    color: var(--text-primary);
    box-shadow: none;
  }
  
  .lux-hero-mobile-actions .lux-btn-ghost:hover {
    background: var(--bg-secondary);
    border-color: var(--text-primary);
  }
}

@media (max-width: 1024px) {
  .lux-hero-media {
    height: clamp(260px, 55vh, 480px);
    border-radius: 1.25rem;
  }

  .lux-hero-overlay {
    padding: 1.5rem 1.25rem;
    background: linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.78) 0%,
      rgba(255, 255, 255, 0.45) 40%,
      transparent 85%
    );
    align-items: flex-end;
  }

  .dark .lux-hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.72) 0%,
      rgba(0, 0, 0, 0.40) 40%,
      transparent 85%
    );
  }

  .lux-hero-title {
    font-size: clamp(2rem, 6vw, 2.6rem);
  }

  .lux-hero-subtitle {
    font-size: 0.9rem;
  }

  .lux-hero-actions {
    gap: 0.7rem;
  }
}

/* Ajuste extra para móviles pequeños: dejar ver más video */
@media (max-width: 640px) {
  /* En móvil, el video va limpio y el texto pasa abajo */
  .lux-hero-banner {
    flex-direction: column;
    padding-inline: 0;
    padding-top: 0;
  }

  .lux-hero-media {
    max-width: 100%;
    border-radius: 0;
  }

  /* Ocultamos cualquier overlay sobre el video en móvil */
  .lux-hero-overlay {
    display: none;
  }

  /* Bloque de texto que aparece debajo del video en móvil */
  .lux-hero-mobile-copy {
    display: block;
    padding: 1.5rem 1.25rem 2rem;
    text-align: center;
    /* Usamos variables CSS para que coincida con el body */
    background: var(--bg-primary);
    color: var(--text-primary);
  }

  .lux-hero-mobile-kicker {
    font-family: 'Outfit', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 0.7rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 0.6rem;
  }

  .lux-hero-mobile-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.9rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
  }

  .lux-hero-mobile-subtitle {
    font-family: 'Outfit', system-ui, sans-serif;
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-secondary);
    max-width: 22rem;
    margin: 0 auto 1.25rem;
  }

  .lux-hero-mobile-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lux-btn-primary,
  .lux-btn-ghost,
  .lux-hero-media {
    transition: none !important;
  }
}

/* ========================================================================== */
/* SCROLL TO TOP BUTTON                                                     */
/* ========================================================================== */

.scroll-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 99;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%); /* Crimson Red */
  color: white;
  border: none;
  box-shadow: 0 10px 25px rgba(220, 38, 38, 0.4);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.scroll-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-to-top:hover {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(220, 38, 38, 0.6);
}

.scroll-to-top:active {
  transform: translateY(-2px);
}

@media (max-width: 640px) {
  .scroll-to-top {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 3rem;
    height: 3rem;
  }
}

/* ========================================================================== */
/* PREMIUM GALLERY CONTROLS - LUXURY CAROUSEL INTERFACE                      */
/* ========================================================================== */

/* --- Control Bar Container --- */
.gallery-controls {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.15),
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.dark .gallery-controls {
  background: rgba(10, 10, 10, 0.65);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.5),
    0 0 30px rgba(59, 130, 246, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.gallery-controls:hover {
  background: rgba(255, 255, 255, 1);
  border-color: rgba(0, 0, 0, 0.15);
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.2),
    0 4px 12px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.dark .gallery-controls:hover {
  background: rgba(10, 10, 10, 0.75);
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.6),
    0 0 30px rgba(59, 130, 246, 0.15);
}

/* --- Base Control Button Style --- */
.gallery-control-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: transparent;
  color: rgba(31, 41, 55, 0.85);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.dark .gallery-control-btn {
  color: rgba(255, 255, 255, 0.85);
}

.gallery-control-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.08);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.dark .gallery-control-btn::before {
  background: rgba(255, 255, 255, 0.08);
}

.gallery-control-btn:hover {
  color: #1f2937;
  transform: scale(1.1);
}

.dark .gallery-control-btn:hover {
  color: #ffffff;
}

.gallery-control-btn:hover::before {
  opacity: 1;
}

.gallery-control-btn:active {
  transform: scale(0.95);
}

/* Focus state for accessibility */
.gallery-control-btn:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

.dark .gallery-control-btn:focus-visible {
  outline-color: #facc15;
}

/* --- Icon Styling --- */
.gallery-control-btn svg {
  width: 1.25rem;
  height: 1.25rem;
  position: relative;
  z-index: 1;
  transition: transform 0.3s ease;
}

.gallery-control-btn:hover svg {
  transform: scale(1.15);
}

/* --- Navigation Arrows (Prev/Next) --- */
.gallery-nav-btn {
  color: rgba(31, 41, 55, 0.7);
}

.dark .gallery-nav-btn {
  color: rgba(255, 255, 255, 0.7);
}

.gallery-nav-btn:hover {
  color: #2563eb;
}

.dark .gallery-nav-btn:hover {
  color: #93c5fd;
  text-shadow: 0 0 12px rgba(59, 130, 246, 0.5);
}

/* Arrow bounce animation on hover */
.gallery-nav-btn.prev:hover svg {
  animation: arrowBounceLeft 0.6s ease-in-out;
}

.gallery-nav-btn.next:hover svg {
  animation: arrowBounceRight 0.6s ease-in-out;
}

@keyframes arrowBounceLeft {
  0%, 100% { transform: translateX(0) scale(1.15); }
  50% { transform: translateX(-4px) scale(1.15); }
}

@keyframes arrowBounceRight {
  0%, 100% { transform: translateX(0) scale(1.15); }
  50% { transform: translateX(4px) scale(1.15); }
}

/* --- Play/Pause Toggle Button --- */
.gallery-playpause-btn {
  width: 3rem;
  height: 3rem;
  margin: 0 0.25rem;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(59, 130, 246, 0.08) 100%);
  border: 1px solid rgba(59, 130, 246, 0.25);
  box-shadow: 
    0 0 15px rgba(59, 130, 246, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.gallery-playpause-btn:hover {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.25) 0%, rgba(59, 130, 246, 0.15) 100%);
  border-color: rgba(59, 130, 246, 0.4);
  box-shadow: 
    0 0 25px rgba(59, 130, 246, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.dark .gallery-playpause-btn {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(59, 130, 246, 0.05) 100%);
  border-color: rgba(59, 130, 246, 0.25);
  box-shadow: 
    0 0 15px rgba(59, 130, 246, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.dark .gallery-playpause-btn:hover {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.35) 0%, rgba(59, 130, 246, 0.15) 100%);
  border-color: rgba(59, 130, 246, 0.5);
  box-shadow: 
    0 0 30px rgba(59, 130, 246, 0.5),
    0 0 60px rgba(59, 130, 246, 0.2);
}

/* Play/Pause Icon States */
.gallery-playpause-btn svg {
  width: 1.125rem;
  height: 1.125rem;
}

.gallery-playpause-btn .icon-play,
.gallery-playpause-btn .icon-pause {
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.gallery-playpause-btn .icon-play {
  opacity: 0;
  transform: scale(0.8);
  position: absolute;
}

.gallery-playpause-btn .icon-pause {
  opacity: 1;
  transform: scale(1);
}

/* State: Paused (show play icon) */
.gallery-playpause-btn.is-paused .icon-play {
  opacity: 1;
  transform: scale(1);
}

.gallery-playpause-btn.is-paused .icon-pause {
  opacity: 0;
  transform: scale(0.8);
}

/* Active pulse animation when playing */
.gallery-playpause-btn:not(.is-paused)::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 2px solid rgba(59, 130, 246, 0.4);
  animation: playPulse 2s ease-in-out infinite;
}

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

/* --- Divider between controls --- */
.gallery-control-divider {
  width: 1px;
  height: 1.5rem;
  background: rgba(0, 0, 0, 0.1);
  margin: 0 0.25rem;
}

.dark .gallery-control-divider {
  background: rgba(255, 255, 255, 0.1);
}

/* --- Progress Indicator (Optional enhancement) --- */
.gallery-progress {
  position: absolute;
  bottom: 0;
  left: 0.75rem;
  right: 0.75rem;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 1px;
  overflow: hidden;
}

.gallery-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #60a5fa);
  border-radius: 1px;
  width: 0%;
  transition: width 0.1s linear;
}

.dark .gallery-progress-bar {
  background: linear-gradient(90deg, #2563eb, #3b82f6);
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

/* --- Responsive Adjustments --- */
@media (max-width: 640px) {
  .gallery-controls {
    padding: 0.375rem 0.5rem;
    gap: 0.25rem;
    bottom: 1rem;
  }

  .gallery-control-btn {
    width: 2.5rem;
    height: 2.5rem;
  }

  .gallery-control-btn svg {
    width: 1.125rem;
    height: 1.125rem;
  }

  .gallery-playpause-btn {
    width: 2.75rem;
    height: 2.75rem;
  }

  .gallery-control-divider {
    height: 1.25rem;
  }
}

@media (min-width: 1024px) {
  .gallery-controls {
    padding: 0.625rem 1rem;
    gap: 0.625rem;
    bottom: 0rem;
  }

  .gallery-control-btn {
    width: 2rem;
    height: 2rem;
  }

  .gallery-control-btn svg {
    width: 1.375rem;
    height: 1.375rem;
  }

  .gallery-playpause-btn {
    width: 3.25rem;
    height: 3.25rem;
    margin: 0 0.375rem;
  }
}

/* --- Hide controls on reduced motion preference --- */
@media (prefers-reduced-motion: reduce) {
  .gallery-control-btn,
  .gallery-playpause-btn,
  .gallery-controls {
    transition: none !important;
    animation: none !important;
  }

  .gallery-playpause-btn::after {
    animation: none !important;
  }
}

/* ==========================================================================
   PREVENT HORIZONTAL SCROLL - GLOBAL FIX
   ========================================================================== */

html, body {
  overflow-x: hidden;
  max-width: 100vw;
  position: relative;
}

/* Prevenir desbordamiento en todos los contenedores principales */
main, section, div {
  max-width: 100%;
}

/* Fix para imágenes y videos que pueden causar overflow */
img, video, iframe, embed, object {
  max-width: 100%;
  height: auto;
}

/* ==========================================================================
   RESPONSIVE CONTAINER FIXES
   ========================================================================== */

/* Asegurar que los contenedores no se desborden */
.max-w-7xl,
.max-w-6xl,
.max-w-5xl,
.max-w-4xl,
.max-w-3xl,
.max-w-2xl,
.max-w-xl {
  width: 100%;
  padding-left: 1rem;
  padding-right: 1rem;
}

@media (min-width: 640px) {
  .max-w-7xl,
  .max-w-6xl,
  .max-w-5xl,
  .max-w-4xl,
  .max-w-3xl,
  .max-w-2xl,
  .max-w-xl {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .max-w-7xl,
  .max-w-6xl,
  .max-w-5xl,
  .max-w-4xl {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

/* ==========================================================================
   GRID RESPONSIVE FIXES
   ========================================================================== */

/* Asegurar que los grids no causen overflow */
.grid {
  width: 100%;
  max-width: 100%;
}

/* Gap responsivo para prevenir overflow */
@media (max-width: 640px) {
  .gap-8 { gap: 1rem; }
  .gap-6 { gap: 0.75rem; }
  .gap-4 { gap: 0.5rem; }
  
  .space-x-8 > * + * { margin-left: 1rem; }
  .space-x-6 > * + * { margin-left: 0.75rem; }
  .space-x-4 > * + * { margin-left: 0.5rem; }
}

/* ==========================================================================
   TABLE & ADMIN RESPONSIVE FIXES
   ========================================================================== */

/* Wrapper para tablas con scroll horizontal controlado */
.table-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 0.75rem;
}

.table-wrapper::-webkit-scrollbar {
  height: 6px;
}

.table-wrapper::-webkit-scrollbar-track {
  background: #f3f4f6;
  border-radius: 3px;
}

.dark .table-wrapper::-webkit-scrollbar-track {
  background: #1a1a1a;
}

.table-wrapper::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.dark .table-wrapper::-webkit-scrollbar-thumb {
  background: #404040;
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* Indicador visual de scroll disponible */
.table-wrapper::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2rem;
  background: linear-gradient(90deg, transparent, rgba(0,0,0,0.05));
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.dark .table-wrapper::after {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.05));
}

.table-wrapper.scrolled-end::after {
  opacity: 0;
}

/* ==========================================================================
   CAROUSEL & SLIDER FIXES
   ========================================================================== */

/* Carousel responsivo sin overflow */
.carousel-container {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  position: relative;
}

.carousel-inner {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.carousel-inner::-webkit-scrollbar {
  display: none;
}

/* ==========================================================================
   MODAL & OVERLAY RESPONSIVE FIXES
   ========================================================================== */

/* Modales que respetan viewport */
.modal-content {
  max-width: calc(100vw - 2rem);
  max-height: calc(100vh - 2rem);
  overflow: auto;
}

@media (max-width: 640px) {
  .modal-content {
    max-width: calc(100vw - 1rem);
    max-height: calc(100vh - 1rem);
    border-radius: 1rem;
  }
}

/* ==========================================================================
   TEXT OVERFLOW FIXES
   ========================================================================== */

/* Prevenir que textos largos causen overflow */
.prevent-overflow {
  overflow-wrap: break-word;
  word-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
}

/* Títulos responsivos */
h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* ==========================================================================
   BREADCRUMB RESPONSIVE FIX
   ========================================================================== */

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.breadcrumb::-webkit-scrollbar {
  display: none;
}

@media (max-width: 640px) {
  .breadcrumb {
    font-size: 0.75rem;
  }
}

/* ==========================================================================
   BUTTON GROUP RESPONSIVE
   ========================================================================== */

.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

@media (max-width: 640px) {
  .button-group {
    flex-direction: column;
  }
  
  .button-group > * {
    width: 100%;
  }
}

/* ==========================================================================
   FILTER BUTTONS
   ========================================================================== */

.filter-btn {
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.filter-btn.active {
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3), 0 2px 4px -1px rgba(59, 130, 246, 0.2);
}

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

@media (max-width: 640px) {
  .filter-btn {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
  }
}

/* ==========================================================================
   SAFE PADDING FOR NOTCHES (iPhone X+)
   ========================================================================== */

@supports (padding: max(0px)) {
  .safe-area-inset {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }
}

