/* ==========================================================================
   VARIABLES Y CONFIGURACIÓN GLOBAL
   ========================================================================== */
:root {
  /* CAMBIO A TIPOGRAFÍA OUTFIT */
  --font-title: 'Outfit', sans-serif;
  --font-body: 'Outfit', sans-serif;
  
  --primary: #0f2c59;
  --primary-hover: #1e40af;
  --accent: #d97706;
  --accent-wa: #25d366;
  --bg-light: #f8fafc;
  --card-bg: #ffffff;
  --text-dark: #1e293b;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  
  --radius: 12px;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Ocultar el cursor por defecto solo en PC */
@media (hover: hover) and (pointer: fine) {
  body, a, button, input { cursor: none; }
}

body {
  font-family: var(--font-body);
  color: var(--text-dark);
  background-color: var(--bg-light);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-title);
  color: var(--primary);
  line-height: 1.2;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ==========================================================================
   CUSTOM CURSOR (GSAP Milantec Style)
   ========================================================================== */
.cursor-dot, .cursor-outline {
  position: fixed; 
  top: 0; 
  left: 0; 
  transform: translate(-50%, -50%);
  border-radius: 50%; 
  z-index: 99999; 
  pointer-events: none;
}

.cursor-dot { 
  width: 6px; 
  height: 6px; 
  background-color: var(--accent); 
}

.cursor-outline { 
  width: 40px; 
  height: 40px; 
  border: 1px solid rgba(217, 119, 6, 0.5); /* Color --accent con transparencia */
}

@media (max-width: 768px) {
  .cursor-dot, .cursor-outline { display: none !important; }
  body, a, button, input { cursor: auto; }
}

/* ==========================================================================
   HEADER, LOGO Y TOP BAR
   ========================================================================== */
.top-bar {
  background-color: var(--primary);
  color: #e2e8f0;
  font-size: 0.85rem;
  padding: 8px 0;
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.icon-text {
  display: flex;
  align-items: center;
  gap: 6px;
}

.main-header {
  background-color: #ffffff;
  padding: 12px 0;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-img {
  height: 50px;
  width: auto;
}

.logo-text .brand-name {
  font-family: var(--font-title);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  display: block;
  line-height: 1;
}

.logo-text .tagline {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Nav Desktop */
.desktop-only {
  display: flex;
  align-items: center;
  gap: 25px;
}

.main-nav {
  display: flex;
  gap: 25px;
}

.nav-link {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  font-size: 1rem;
  transition: color 0.2s;
  padding: 5px 0;
  border-bottom: 2px solid transparent;
}

.nav-link.active, .nav-link:hover {
  color: var(--primary);
  border-bottom-color: var(--accent);
}

.btn-head-wa {
  background-color: var(--accent-wa);
  color: #fff;
  text-decoration: none;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
}

/* ==========================================================================
   MENÚ MÓVIL FULLSCREEN Y HAMBURGUESA
   ========================================================================== */
.hamburger {
  display: none; 
  flex-direction: column; 
  gap: 6px; 
  cursor: pointer; 
  z-index: 1001;
}

.hamburger span {
  display: block; 
  width: 30px; 
  height: 3px; 
  background-color: var(--primary);
  transition: all 0.3s ease; 
  border-radius: 2px;
}

.mobile-menu {
  position: fixed; 
  top: 0; 
  left: 0; 
  width: 100%; 
  height: 100vh;
  background: rgba(255, 255, 255, 0.98); 
  backdrop-filter: blur(10px);
  display: flex; 
  flex-direction: column; 
  justify-content: center; 
  align-items: center;
  gap: 30px; 
  z-index: 1000;
  opacity: 0; 
  visibility: hidden; 
  transition: all 0.4s ease;
}

.mobile-menu.active { 
  opacity: 1; 
  visibility: visible; 
}

.mobile-link { 
  font-size: 2.2rem; 
  color: var(--primary); 
  text-decoration: none; 
  font-weight: 600; 
  transition: color 0.3s;
}

.mobile-link:hover, .mobile-link.active {
  color: var(--accent);
}

.mobile-socials { 
  display: flex; 
  gap: 20px; 
  margin-top: 40px; 
}

.mobile-socials a {
  color: var(--primary);
  transition: color 0.3s, transform 0.3s;
}

.mobile-socials a:hover { 
  color: var(--accent); 
  transform: scale(1.1);
}

.mobile-close {
  position: absolute;
  top: 25px;
  right: 25px;
  background: none;
  border: none;
  color: var(--primary);
  z-index: 1002;
  transition: transform 0.2s, color 0.2s;
  padding: 5px;
}

.mobile-close:hover {
  color: var(--accent);
  transform: scale(1.1);
}

/* Animación de la hamburguesa a "X" */
.hamburger.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero {
  background-size: cover;
  background-position: center;
  color: #ffffff;
  padding: 90px 20px;
  text-align: center;
  min-height: 75vh; /* Hacemos la cabecera más alta */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero h1 {
  color: #ffffff;
  font-size: clamp(2.5rem, 5vw, 4rem); /* Se adapta según el tamaño de pantalla */
  margin: 15px 0;
  font-weight: 700;
}

.hero p {
  font-size: 1.2rem;
  color: #e2e8f0;
  max-width: 700px;
  margin: 0 auto 30px auto;
  font-weight: 300;
}

.badge {
  background-color: rgba(255,255,255,0.2);
  color: #fef08a;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.btn {
  padding: 12px 26px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
  transition: transform 0.2s, background-color 0.2s;
  border: none;
  cursor: inherit; /* Hereda el cursor personalizado */
}

.btn-large {
  padding: 16px 32px;
  font-size: 1.1rem;
}

.btn:hover { transform: translateY(-2px); }
.btn-primary { background-color: var(--accent); color: #fff; }
.btn-outline { border: 2px solid #ffffff; color: #ffffff; }
.btn-outline:hover { background-color: #ffffff; color: var(--primary); }

/* ==========================================================================
   SECCIÓN NOSOTROS / HISTORIA
   ========================================================================== */
.about-section {
  margin-top: -40px; /* Hace que la tarjeta "suba" un poquito sobre el Hero */
  position: relative;
  z-index: 10;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  background-color: var(--card-bg);
  padding: 40px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-hover); /* Una sombra un poco más fuerte para destacar */
  border: 1px solid var(--border-color);
}

.about-title-col h2 {
  font-size: 2.2rem;
  margin-top: 15px;
  line-height: 1.2;
}

.about-text-col p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 20px;
  line-height: 1.7;
}

.about-text-col p:last-child {
  margin-bottom: 0;
}

/* En Tablets y PC, lo dividimos en 2 columnas */
@media (min-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr 1.5fr; /* La columna de texto es un poco más ancha */
    gap: 50px;
    padding: 60px;
  }
}

/* ==========================================================================
   PRODUCTOS Y GRILLA (3 COLUMNAS)
   ========================================================================== */
.main-content { padding: 80px 20px; }
.section-title { text-align: center; margin-bottom: 45px; }
.section-title h2 { font-size: 2.5rem; margin-bottom: 8px; }
.section-title p { color: var(--text-muted); font-size: 1.1rem; font-weight: 300;}

.shop-search-wrapper {
  max-width: 500px;
  margin: 0 auto 25px auto;
}

.shop-search-wrapper input {
  width: 100%;
  padding: 12px 20px;
  border: 1px solid var(--border-color);
  border-radius: 30px;
  font-size: 0.95rem;
  outline: none;
  font-family: var(--font-body);
}

.shop-search-wrapper input:focus {
  border-color: var(--accent);
}

.categories-nav {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.cat-btn {
  background-color: #fff;
  border: 1px solid var(--border-color);
  padding: 8px 18px;
  border-radius: 30px;
  font-weight: 500;
  color: var(--text-dark);
  transition: all 0.2s;
  font-family: var(--font-body);
}

.cat-btn.active, .cat-btn:hover {
  background-color: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* Grilla Responsiva: 1, 2 y 3 Columnas */
.products-grid {
  display: grid;
  grid-template-columns: 1fr; /* Móviles: 1 columna */
  gap: 30px;
}

@media (min-width: 650px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr); /* Tablets: 2 columnas */
  }
}

@media (min-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(3, 1fr); /* PC: 3 columnas */
  }
}

.product-card {
  background-color: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.product-img {
  width: 100%;
  height: auto; /* Quitamos la altura fija */
  aspect-ratio: 1 / 1; /* Forzamos un cuadrado perfecto */
  object-fit: contain; /* Asegura que se vea completa sin cortar nada */
  background-color: #f1f5f9;
}

.product-info {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 5px;
  letter-spacing: 1px;
}

.product-title {
  font-size: 1.25rem;
  margin-bottom: 15px; /* Más margen ya que quitamos la descripción */
  flex-grow: 1; /* Empuja los botones hacia abajo */
}

.product-title:hover { color: var(--primary-hover); }

.card-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-detail {
  background-color: #f1f5f9;
  color: var(--primary);
  border: none;
  padding: 10px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  text-align: center;
  font-family: var(--font-body);
  transition: background-color 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-detail:hover { background-color: #e2e8f0; }

.btn-wa-card {
  background-color: var(--accent-wa);
  color: #ffffff;
  text-align: center;
  padding: 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color 0.2s;
}

.btn-wa-card:hover { background-color: #20b858; }

.center-btn-wrapper {
  text-align: center;
  margin-top: 55px;
}

/* ==========================================================================
   MODAL DE PRODUCTO (GALERÍA)
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-container {
  background-color: #fff;
  width: 90%;
  max-width: 900px;
  border-radius: var(--radius);
  position: relative;
  overflow: hidden;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  color: var(--text-muted);
  z-index: 10;
  transition: color 0.2s;
}

.modal-close:hover { color: var(--primary); }

.modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 35px;
  padding: 40px;
}

.modal-gallery {
  min-width: 0; /* Evita que las miniaturas rompan el ancho del modal en móviles */
}

.modal-main-img {
  width: 100%;
  height: auto; /* Quitamos los 350px fijos */
  aspect-ratio: 1 / 1; /* Forzamos un cuadrado perfecto */
  object-fit: contain;
  border-radius: 8px;
  background-color: #f1f5f9;
}

.modal-thumb {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 6px;
  border: 2px solid transparent;
  opacity: 0.6;
  transition: all 0.2s;
  flex-shrink: 0; /* <--- AGREGA ESTA LÍNEA */
}

.modal-thumb {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 6px;
  border: 2px solid transparent;
  opacity: 0.6;
  transition: all 0.2s;
}

.modal-thumb:hover { opacity: 1; }
.modal-thumb.active { 
  border-color: var(--primary); 
  opacity: 1; 
}

.modal-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.modal-info h2 { font-size: 2rem; margin: 10px 0 20px 0; }
.modal-desc { color: var(--text-muted); margin-bottom: 30px; line-height: 1.6; font-size: 1.05rem;}

/* ==========================================================================
   PÁGINA DE CONTACTO Y TIKTOK
   ========================================================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.contact-card {
  background: #fff;
  padding: 25px;
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.contact-card .card-icon { margin-bottom: 12px; }

.social-buttons {
  display: flex;
  gap: 12px;
}

.social-btn {
  width: 45px;
  height: 45px;
  border-radius: 8px;
  transition: transform 0.2s;
}

.social-btn:hover { transform: translateY(-3px); }

.tiktok-section { background-color: #fff; padding: 60px 0; }
.tiktok-wrapper { display: flex; justify-content: center; }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.main-footer {
  background-color: var(--primary);
  color: #94a3b8;
  padding: 30px 0;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
  font-size: 0.95rem;
}

.footer-right a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 500;
}

.footer-right a:hover { text-decoration: underline; color: var(--accent); }

/* ==========================================================================
   BOTONES FLOTANTES ALINEADOS
   ========================================================================== */
.float-btn {
  position: fixed;
  bottom: 25px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(0,0,0,0.25);
  text-decoration: none;
  z-index: 1000;
  transition: transform 0.3s ease, opacity 0.4s ease, visibility 0.4s ease;
}

.float-btn:hover { transform: scale(1.1); }

.float-wa {
  left: 25px; 
  background-color: var(--accent-wa);
}

.float-scrollup {
  right: 25px; 
  background-color: var(--primary);
  opacity: 0;
  visibility: hidden;
}

.float-scrollup.visible {
  opacity: 1;
  visibility: visible;
}

/* ==========================================================================
   RESPONSIVE MÓVILES EXTRAS
   ========================================================================== */
@media (max-width: 768px) {
  /* Ocultar barra superior azul en móviles */
  .top-bar { display: none; }

  /* Ocultamos navegación de escritorio y mostramos hamburguesa */
  .desktop-only { display: none; }
  .hamburger { display: flex; }
  
  .header-container { flex-direction: row; } /* Mantener logo a la izq y botón a la der */

  .modal-body { grid-template-columns: 1fr; padding: 25px; gap: 20px;}
    
  .contact-grid { grid-template-columns: 1fr; }
  .footer-content { flex-direction: column; text-align: center; }
}