/* css/style.css - Leksas Light Theme & Interactive UI */

:root {
  /* Leksas Brand Colors */
  --color-black: #25343a;
  /* Usado para textos fuertes y headers */
  --color-orange: #FF8800;
  /* Botones principales y Calls to Action */
  --color-blue: #154F8C;
  /* Acentos, iconos y hover states */

  /* Light Theme Palette */
  --color-bg-primary: #f0f2f5;
  /* Gris extra claro moderno */
  --color-bg-secondary: #ffffff;
  /* Blanco puro para tarjetas */
  --color-text-main: #333333;
  --color-text-muted: #666666;
  --color-whatsapp: #25D366;

  /* Neumorphic / Soft Shadows */
  --shadow-soft: 8px 8px 16px rgba(0, 0, 0, 0.05), -8px -8px 16px rgba(255, 255, 255, 0.8);
  --shadow-hover: 12px 12px 24px rgba(0, 0, 0, 0.1), -12px -12px 24px rgba(255, 255, 255, 1);
  --shadow-inset: inset 4px 4px 8px rgba(0, 0, 0, 0.05), inset -4px -4px 8px rgba(255, 255, 255, 0.8);

  /* Typography */
  --font-primary: 'Inter', system-ui, -apple-system, sans-serif;
  --font-headings: 'Montserrat', system-ui, -apple-system, sans-serif;

  /* Layout */
  --container-width: 1200px;
  --transition-normal: 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  color: var(--color-text-main);
  background-color: var(--color-bg-primary);
  line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6,
.section-title,
.btn,
.nav-links li a {
  font-family: var(--font-headings);
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Reusable UI Components */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 5%;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  text-align: center;
  transition: var(--transition-normal);
  cursor: pointer;
  border: none;
  font-size: 1rem;
}

.btn-primary {
  background-color: var(--color-orange);
  color: #fff;
  box-shadow: 0 4px 15px rgba(255, 136, 0, 0.3);
}

.btn-primary:hover {
  background-color: #e67a00;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 136, 0, 0.4);
}

.btn-secondary {
  background-color: var(--color-blue);
  color: #fff;
}

.btn-secondary:hover {
  background-color: #103c6b;
  transform: translateY(-3px);
}

.btn-portal {
  background-color: var(--color-bg-secondary);
  color: var(--color-blue);
  border: 2px solid var(--color-blue);
}

.btn-portal:hover {
  background-color: var(--color-blue);
  color: #fff;
}

.section-title {
  text-align: center;
  margin-bottom: 3.5rem;
  color: var(--color-black);
  font-size: 2.5rem;
  font-weight: 800;
}

.section-title span {
  color: var(--color-orange);
}

/* Animation Classes */
.fade-in-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Header & Navbar */
header {
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  transition: var(--transition-normal);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 85px;
}

.logo-container img {
  height: 55px;
  /* Logo original de fondo blanco lucirá perfecto aquí */
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links li a {
  color: var(--color-text-main);
  font-weight: 600;
  font-size: 1rem;
  transition: color 0.3s;
  position: relative;
}

.nav-links li a:not(.btn):hover {
  color: var(--color-orange);
}

.menu-toggle {
  display: none;
  color: var(--color-black);
  font-size: 1.8rem;
  cursor: pointer;
}

/* Hero Slider Section */
.hero-slider-wrapper {
  position: relative;
  width: 100%;
  height: 100vh;
  /* Ocupa toda la pantalla */
  min-height: 600px;
  overflow: hidden;
  background-color: var(--color-bg-secondary);
  margin-top: 0;
  /* Por el header fixed */
}

.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.hero-slide.active {
  opacity: 1;
  z-index: 2;
}

/* Diseñamos el fondo limpio con sutiles degradados, sin que compitan con las ilustraciones */
.slide-1 {
  background: radial-gradient(circle at right, #fbfcfd 0%, #e2e8f0 100%);
}

.slide-2 {
  background: linear-gradient(120deg, #fdfbfb 0%, #eef2f5 100%);
}

.slide-3 {
  background: linear-gradient(to top, #eef2f5 0%, #ffffff 100%);
}

.hero-content-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 3rem;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 1s ease 0.5s, opacity 1s ease 0.5s;
}

.hero-slide.active .hero-content-split {
  transform: translateY(0);
  opacity: 1;
}

.hero-text {
  text-align: left;
}

.hero-text h1 {
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--color-black);
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.hero-text h1 span {
  color: var(--color-blue);
}

.hero-text p {
  font-size: 1.2rem;
  color: var(--color-text-muted);
  margin-bottom: 2.5rem;
  font-weight: 500;
}

.hero-buttons {
  display: flex;
  justify-content: flex-start;
  gap: 1.5rem;
}

.hero-image-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Vector Composite Animations (Interactive Slides) */
.vector-composite {
  position: relative;
  width: 320px;
  height: 320px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.vc-icon {
  position: absolute;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  background: var(--color-bg-secondary);
  box-shadow: var(--shadow-hover);
  color: var(--color-blue);
  transition: 0.3s;
}

.vc-center {
  width: 150px;
  height: 150px;
  font-size: 4.5rem;
  z-index: 2;
  border: 4px solid var(--color-orange);
  color: var(--color-black);
  animation: float 6s ease-in-out infinite;
}

.vc-float-1 {
  width: 90px;
  height: 90px;
  font-size: 2.5rem;
  top: 5%;
  left: -5%;
  animation: float 4s ease-in-out infinite;
}

.vc-float-2 {
  width: 80px;
  height: 80px;
  font-size: 2.2rem;
  bottom: 0%;
  right: 5%;
  animation: float 5s ease-in-out infinite reverse;
}

.vc-pulse {
  width: 70px;
  height: 70px;
  font-size: 1.8rem;
  top: 25%;
  right: -10%;
  animation: pulse 2s ease-in-out infinite;
  color: var(--color-orange);
}

.vc-spin {
  width: 100px;
  height: 100px;
  font-size: 3rem;
  top: 0%;
  right: -5%;
  animation: spin 8s linear infinite;
  color: var(--color-orange);
}

.vc-spin-reverse {
  width: 75px;
  height: 75px;
  font-size: 2rem;
  bottom: 10%;
  left: 0%;
  animation: spin-reverse 6s linear infinite;
}

@keyframes spin {
  100% {
    transform: rotate(360deg);
  }
}

@keyframes spin-reverse {
  100% {
    transform: rotate(-360deg);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.15);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-15px);
  }

  100% {
    transform: translateY(0px);
  }
}

/* Slider Controls */
.slider-controls {
  position: absolute;
  bottom: 50px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  gap: 10px;
}

.slider-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: 0.3s;
}

.slider-dot.active {
  background-color: var(--color-orange);
  transform: scale(1.3);
}

/* Services Section (Soft Shadows) */
.services {
  padding: 8rem 0;
  background-color: var(--color-bg-primary);
  /* Fondo gris super claro */
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 3rem;
}

.service-card {
  background-color: var(--color-bg-secondary);
  border-radius: 20px;
  padding: 4.5rem 3rem;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
  transition: var(--transition-normal);
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-top: 6px solid var(--color-blue);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.service-card:hover {
  transform: translateY(-15px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
  border-top-color: var(--color-orange);
}

.service-icon {
  width: 90px;
  height: 90px;
  margin: 0 auto 2.5rem;
  border-radius: 50%;
  background-color: rgba(21, 79, 140, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--color-blue);
  transition: var(--transition-normal);
}

.service-card:hover .service-icon {
  background-color: var(--color-orange);
  color: #fff;
  transform: scale(1.15) rotate(5deg);
  box-shadow: 0 10px 25px rgba(255, 136, 0, 0.3);
}

.service-card h3 {
  font-size: 1.8rem;
  color: var(--color-black);
  margin-bottom: 1.5rem;
  font-weight: 800;
}

.service-card p {
  color: var(--color-text-muted);
  font-size: 1.15rem;
  line-height: 1.7;
}

/* Partners Marquee (Socios Comerciales) */
.partners {
  padding: 4rem 0;
  background-color: var(--color-bg-secondary);
  overflow: hidden;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.partners h3 {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 2rem;
}

.trust-container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  /* Permite bajar de línea en pantallas pequeñas */
  gap: 1rem;
  padding: 1rem 0;
}

.trust-badge {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 15px;
  color: var(--color-text-muted);
  /* Texto gris tenue */
  font-weight: 500;
  font-size: 1.1rem;
  background: transparent;
  /* Sin cuadro rodeándolo */
  padding: 10px 15px;
  /* Padding reducido para acercarlos */
  transition: var(--transition-normal);
  white-space: nowrap;
  flex: 1;
  /* Para que se distribuyan equitativamente */
  min-width: 150px;
  /* Reducción de ancho mínimo */
}

.trust-badge i {
  font-size: 3.5rem;
  /* Ajustado para mejor balance visual */
  color: #c9d1d9;
  /* Gris sutil por defecto */
  transition: var(--transition-normal);
}

.trust-badge:hover i {
  color: var(--color-orange);
  /* Cambia a naranja al hacer hover */
  transform: scale(1.1) translateY(-5px);
  /* Efecto combinado en hover */
}

/* Dynamic Client Logos Section */
.clients-section {
  padding: 4.5rem 0;
  background: #ffffff;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  text-align: center;
  overflow: hidden;
}

.clients-section h3 {
  color: var(--color-text-muted);
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 3rem;
  font-weight: 700;
}

.clients-marquee-container {
  width: 100%;
  position: relative;
}

.clients-marquee-container::before,
.clients-marquee-container::after {
  content: '';
  position: absolute;
  top: 0;
  width: 15%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.clients-marquee-container::before {
  left: 0;
  background: linear-gradient(to right, #ffffff, transparent);
}

.clients-marquee-container::after {
  right: 0;
  background: linear-gradient(to left, #ffffff, transparent);
}

.clients-marquee-track {
  display: flex;
  width: max-content;
  animation: scroll-clients 55s linear infinite;
  align-items: center;
  gap: 5rem;
  padding: 1rem 0;
}

.clients-marquee-track:hover {
  animation-play-state: paused;
}

.client-logo-box {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 160px;
  height: 80px;
}

.client-logo-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0.85;
  /* Ajustado de 0.75 a 0.85 para mayor claridad */
  transition: var(--transition-normal);
  cursor: pointer;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.05));
}

.client-logo-box img:hover {
  opacity: 1;
  transform: scale(1.15);
  filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.08));
}

@keyframes scroll-clients {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(calc(-50% - 2.5rem));
  }
}

/* Catalog Section */
.catalog {
  padding: 8rem 0;
  background-color: var(--color-bg-primary);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
}

.product-card {
  background-color: var(--color-bg-secondary);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
}

.product-img {
  height: 220px;
  background-color: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: #a0aec0;
  position: relative;
}

/* Capa oscura semitransparente al hacer hover a la imagen */
.product-img::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(21, 79, 140, 0.1);
  opacity: 0;
  transition: 0.3s;
}

.product-card:hover .product-img::after {
  opacity: 1;
}

.product-info {
  padding: 2rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.product-title {
  font-size: 1.4rem;
  color: var(--color-black);
  margin-bottom: 0.8rem;
}

.product-desc {
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

/* Contact CTA */
.cta-section {
  padding: 6rem 0;
  background: linear-gradient(135deg, var(--color-blue), #1e293b);
  color: #fff;
  text-align: center;
}

.cta-section h2 {
  font-size: 2.8rem;
  margin-bottom: 1.5rem;
}

.cta-section p {
  font-size: 1.2rem;
  margin-bottom: 2.5rem;
  opacity: 0.9;
}

/* Footer */
footer {
  background-color: var(--color-white);
  color: var(--color-text-main);
  padding: 5rem 0 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-col h4 {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: var(--color-black);
  font-weight: 700;
}

.footer-col p {
  color: var(--color-text-muted);
  margin-bottom: 0.8rem;
}

.footer-links li {
  margin-bottom: 0.8rem;
}

.footer-links a {
  font-weight: 500;
  color: var(--color-blue);
  transition: 0.3s;
}

.footer-links a:hover {
  color: var(--color-orange);
  padding-left: 5px;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  color: var(--color-text-muted);
}

/* WhatsApp Float */
.whatsapp-float {
  position: fixed;
  width: 65px;
  height: 65px;
  bottom: 30px;
  right: 30px;
  background-color: var(--color-whatsapp);
  color: #FFF;
  border-radius: 50%;
  text-align: center;
  font-size: 35px;
  box-shadow: 0px 8px 20px rgba(37, 211, 102, 0.4);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-normal);
}

.whatsapp-float:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0px 12px 25px rgba(37, 211, 102, 0.6);
}

/* Mobile */
@media (max-width: 900px) {
  .hero-content-split {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1rem;
    margin-top: 4rem;
  }

  .hero-text {
    text-align: center;
  }

  .hero-buttons {
    justify-content: center;
  }

  .hero-image-wrapper img {
    max-height: 280px;
  }

  .hero-text h1 {
    font-size: 2.8rem;
  }

  .menu-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 85px;
    left: -100%;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    flex-direction: column;
    padding: 2rem 0;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.05);
    transition: 0.4s;
  }

  .nav-links.active {
    left: 0;
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links li a {
    display: block;
    padding: 10px 0;
    font-size: 1.2rem;
  }
}

@media (max-width: 600px) {
  .hero-content h1 {
    font-size: 2.2rem;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .partners i {
    font-size: 3rem;
  }
}

/* --- Sombra y Destello Magnético del Header --- */
.header-glow-tracker {
  position: absolute;
  bottom: -2px;
  /* Apenas se asoma del header */
  left: -150px;
  /* Offset para centrar la luz debajo del puntero */
  width: 300px;
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--color-orange) 40%, var(--color-blue) 60%, transparent);
  border-radius: 50%;
  filter: drop-shadow(0 5px 15px rgba(255, 136, 0, 0.4)) drop-shadow(0 5px 15px rgba(21, 79, 140, 0.4));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
  /* Solo hace fade, el transform es fluido nativo por JS */
  z-index: 10;
  will-change: transform;
}

/* --- Utilidades Responsivas de Efectos --- */
.mobile-only {
  display: none;
}

@media (max-width: 900px) {
  .mobile-only {
    display: block !important;
  }

  .desktop-only {
    display: none !important;
  }
}

/* Animación de Cometas rescatada para Móviles y Escritorio */
  .comets-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 9999;
    overflow: hidden;
  }

  .comet {
    position: absolute;
    width: 150px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--color-orange));
    border-radius: 50%;
    filter: drop-shadow(0 0 6px var(--color-orange));
    opacity: 0;
  }

  .comet::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    width: 3px;
    height: 3px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 0 10px #ffffff, 0 0 20px var(--color-orange);
  }

  @keyframes comet-dr {
    0% {
      transform: translate(-10vw, -10vh) rotate(45deg);
      opacity: 0;
    }

    1% {
      opacity: 0.8;
    }

    30% {
      transform: translate(120vw, 80vh) rotate(45deg);
      opacity: 0;
    }

    100% {
      transform: translate(120vw, 80vh) rotate(45deg);
      opacity: 0;
    }
  }

  @keyframes comet-dl {
    0% {
      transform: translate(110vw, -10vh) rotate(135deg);
      opacity: 0;
    }

    1% {
      opacity: 0.8;
    }

    30% {
      transform: translate(-20vw, 90vh) rotate(135deg);
      opacity: 0;
    }

    100% {
      transform: translate(-20vw, 90vh) rotate(135deg);
      opacity: 0;
    }
  }

  @keyframes comet-ur {
    0% {
      transform: translate(-10vw, 110vh) rotate(-45deg);
      opacity: 0;
    }

    1% {
      opacity: 0.8;
    }

    30% {
      transform: translate(120vw, -20vh) rotate(-45deg);
      opacity: 0;
    }

    100% {
      transform: translate(120vw, -20vh) rotate(-45deg);
      opacity: 0;
    }
  }

  @keyframes comet-ul {
    0% {
      transform: translate(110vw, 110vh) rotate(-135deg);
      opacity: 0;
    }

    1% {
      opacity: 0.8;
    }

    30% {
      transform: translate(-20vw, -20vh) rotate(-135deg);
      opacity: 0;
    }

    100% {
      transform: translate(-20vw, -20vh) rotate(-135deg);
      opacity: 0;
    }
  }

  @keyframes comet-hr {
    0% {
      transform: translate(-10vw, 50vh) rotate(0deg);
      opacity: 0;
    }

    1% {
      opacity: 0.8;
    }

    30% {
      transform: translate(120vw, 50vh) rotate(0deg);
      opacity: 0;
    }

    100% {
      transform: translate(120vw, 50vh) rotate(0deg);
      opacity: 0;
    }
  }

  .c1 {
    animation: comet-dr 35s linear infinite 2s;
    top: 10%;
  }

  .c2 {
    animation: comet-dl 42s linear infinite 14s;
    top: 20%;
  }

  .c3 {
    animation: comet-ur 48s linear infinite 8s;
    top: 80%;
  }

  .c4 {
    animation: comet-ul 38s linear infinite 22s;
    top: 90%;
  }

  .c5 {
    animation: comet-hr 45s linear infinite 33s;
    top: 30%;
  }

  .c6 {
    animation: comet-dr 39s linear infinite 40s;
    top: -5%;
  }

  .c7 {
    animation: comet-dl 40s linear infinite 19s;
    top: -10%;
  }

  .c8 {
    animation: comet-ur 50s linear infinite 5s;
    top: 105%;
  }