/* RESET BÁSICO */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  color: #111827;
  background-color: #f5f7fb;
  line-height: 1.5;
}

/* UTILIDADES */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 16px;
}

.section {
  padding: 64px 0;
}

.section-light {
  background-color: #ffffff;
}

.section-gray {
  background: linear-gradient(180deg, #f3f4f8 0%, #e5e7f1 100%);
}

.section-soft {
  background: radial-gradient(circle at top, #e3f0ff 0%, #f5f7fb 55%, #ffffff 100%);
}

.section-title {
  text-align: center;
  font-size: 24px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #111827;
  margin-bottom: 32px;
}

/* BOTONES */
.btn-primary,
.btn-secondary,
.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.18s ease-in-out;
}

.btn-primary {
  background-color: #c53030;
  color: #ffffff;
  box-shadow: 0 14px 30px rgba(197, 48, 48, 0.35);
}

.btn-primary:hover {
  background-color: #9b1c1c;
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(197, 48, 48, 0.45);
}

.btn-secondary {
  background-color: #ffffff;
  color: #111827;
  border-color: #d1d5db;
}

.btn-secondary:hover {
  background-color: #111827;
  color: #ffffff;
  border-color: #111827;
}

.btn-outline {
  background: white;
  color: #111827;
  border-color: #d1d5db;
}

.btn-outline:hover {
  background-color: #111827;
  color: #ffffff;
}

/* HEADER */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 40;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

/* LOGO */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
}

.logo-img {
  height: 44px;
  width: auto;
  display: block;
}

/* HERO */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  color: #ffffff;
  padding-top: 72px; /* altura header */
  overflow: hidden;
}

/* Imagen de fondo del hero */
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url("img/hero.jpg");
  background-size: cover;
  background-position: center;
  filter: brightness(0.65);
  z-index: -2;
}

/* Degradado oscuro para mejorar legibilidad del texto */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(0, 0, 0, 0.2), transparent 55%),
              linear-gradient(to bottom, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.4), rgba(15, 23, 42, 0.9));
  z-index: -1;
}

.hero-inner {
  display: flex;
  align-items: center;
  min-height: calc(80vh - 72px);
}

.hero-text {
  max-width: 520px;
}

.hero h1 {
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.hero-subtitle {
  font-size: 16px;
  max-width: 420px;
  margin-bottom: 24px;
  color: #e5e7eb;
}

/* CARDS BASE */
.card {
  background-color: #ffffff;
  border-radius: 14px;
  padding: 24px 20px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease, background-color 0.22s ease;
}

/* PRODUCTOS DESTACADOS */
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.product-card {
  text-align: center;
}

.card-icon {
  width: 60px;
  height: 60px;
  border-radius: 999px;
  background-color: #e5efff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.card-icon img {
  max-width: 32px;
  max-height: 32px;
}

.product-card h3 {
  font-size: 16px;
  margin-bottom: 8px;
}

.product-card p {
  font-size: 14px;
  color: #4b5563;
}

/* BENEFICIOS */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.benefit-card {
  text-align: center;
}

.benefit-card .card-icon {
  background-color: #ffffff;
}

.benefit-card h3 {
  font-size: 15px;
  margin-bottom: 8px;
}

.benefit-card p {
  font-size: 13px;
  color: #4b5563;
}

/* GALERÍA */
.gallery-section .section-title {
  margin-bottom: 8px;
}

.gallery-intro {
  text-align: center;
  font-size: 14px;
  color: #4b5563;
  max-width: 640px;
  margin: 0 auto 32px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.gallery-card {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  background-color: #111827;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background-color 0.22s ease;
}

.gallery-image {
  position: relative;
  padding-top: 64%;
  overflow: hidden;
}

.gallery-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  cursor: zoom-in;
}

/* SECCIÓN DIAGZONE PRO V2 */
.section-diagzone {
  background: radial-gradient(circle at top left, #111827 0%, #020617 55%, #020617 100%);
  color: #e5e7eb;
}

.diagzone-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  align-items: stretch;
}

.diagzone-copy {
  flex: 3 1 260px;
  min-width: 0;
}

.diagzone-kicker {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 11px;
  color: #9ca3af;
  margin-bottom: 8px;
}

.diagzone-title {
  font-size: 24px;
  margin-bottom: 12px;
  color: #f9fafb;
}

.diagzone-lead {
  font-size: 14px;
  color: #e5e7eb;
  max-width: 640px;
  margin-bottom: 16px;
}

.diagzone-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.diagzone-list li {
  position: relative;
  padding-left: 18px;
  font-size: 14px;
  color: #d1d5db;
  margin-bottom: 8px;
}

.diagzone-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background-color: #ef4444;
}

/* Card lateral */
.diagzone-card {
  flex: 2 1 260px;
  background: linear-gradient(145deg, #020617, #111827);
  border-radius: 18px;
  padding: 22px 20px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.diagzone-badge {
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  background: rgba(34, 197, 94, 0.1);
  color: #bbf7d0;
  border: 1px solid rgba(34,197,94,0.45);
}

.diagzone-card-title {
  font-size: 18px;
  color: #f9fafb;
}

.diagzone-card-text {
  font-size: 13px;
  color: #e5e7eb;
}

.diagzone-card-list {
  list-style: none;
  padding-left: 0;
  margin: 4px 0 0;
  font-size: 13px;
  color: #d1d5db;
}

.diagzone-card-list li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 6px;
}

.diagzone-card-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  top: 0;
  color: #22c55e;
}

/* Animaciones suaves en la sección DiagZone */
.section-diagzone .diagzone-copy,
.section-diagzone .diagzone-card {
  opacity: 0;
  animation: fadeUp 0.6s ease forwards;
}

.section-diagzone .diagzone-copy {
  animation-delay: 0.05s;
}

.section-diagzone .diagzone-card {
  animation-delay: 0.18s;
}


/* Detalles extra animados DiagZone */
.diagzone-card {
  position: relative;
  overflow: hidden;
}

.diagzone-card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at top, rgba(239, 68, 68, 0.18), transparent 55%);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.4s ease, transform 0.4s ease;
  pointer-events: none;
}

.diagzone-card:hover::before {
  opacity: 1;
  transform: scale(1);
}

.diagzone-badge {
  animation: diagzonePulse 2.4s ease-in-out infinite;
}

@keyframes diagzonePulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.0);
  }
  50% {
    transform: scale(1.03);
    box-shadow: 0 0 0 8px rgba(34, 197, 94, 0.18);
  }
}

/* LIGHTBOX GALERÍA */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 80;
}

.lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-inner {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
}

.lightbox-image {
  display: block;
  max-width: 100%;
  max-height: 100%;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.lightbox-close {
  position: absolute;
  top: -32px;
  right: 0;
  border: none;
  background: transparent;
  color: #f9fafb;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

@media (max-width: 640px) {
  .lightbox-inner {
    max-width: 94vw;
    max-height: 80vh;
  }
  .lightbox-close {
    top: -28px;
    right: -4px;
  }
}
/* FOOTER */
.site-footer {
  background-color: #ffffff;
  border-top: 1px solid #e5e7eb;
  padding: 20px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-copy {
  font-size: 13px;
  color: #6b7280;
}

.footer-social {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-icon {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #f3f4f6;
  text-decoration: none;
  transition: background-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.footer-icon svg {
  width: 18px;
  height: 18px;
}

.footer-icon:hover {
  background-color: #e5e7eb;
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.15);
}

/* BOTÓN FLOTANTE WHATSAPP */
.floating-whatsapp {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background-color: #25d366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
  z-index: 60;
  text-decoration: none;
  border: 2px solid #ffffff;
  transition: background-color 0.18s ease, transform 0.18s ease,
    box-shadow 0.18s ease;
}

.floating-whatsapp svg {
  width: 28px;
  height: 28px;
}

.floating-whatsapp:hover {
  background-color: #1ebe5b;
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

/* HOVERS / ANIMACIONES EN CARDS */
.card:hover,
.gallery-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.16);
}

/* Fade-in suave al aparecer */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.products-grid .card,
.benefits-grid .card,
.gallery-grid .gallery-card {
  opacity: 0;
  animation: fadeUp 0.6s ease forwards;
}

.products-grid .card:nth-child(1) { animation-delay: 0.05s; }
.products-grid .card:nth-child(2) { animation-delay: 0.15s; }
.products-grid .card:nth-child(3) { animation-delay: 0.25s; }

.benefits-grid .card:nth-child(1) { animation-delay: 0.05s; }
.benefits-grid .card:nth-child(2) { animation-delay: 0.15s; }
.benefits-grid .card:nth-child(3) { animation-delay: 0.25s; }
.benefits-grid .card:nth-child(4) { animation-delay: 0.35s; }

.gallery-grid .gallery-card:nth-child(1) { animation-delay: 0.05s; }
.gallery-grid .gallery-card:nth-child(2) { animation-delay: 0.12s; }
.gallery-grid .gallery-card:nth-child(3) { animation-delay: 0.19s; }
.gallery-grid .gallery-card:nth-child(4) { animation-delay: 0.26s; }
.gallery-grid .gallery-card:nth-child(5) { animation-delay: 0.33s; }
.gallery-grid .gallery-card:nth-child(6) { animation-delay: 0.40s; }

/* Respeto a usuarios con reducción de movimiento */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* RESPONSIVE */
@media (max-width: 960px) {
  .products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .benefits-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .header-inner {
    height: 64px;
  }

  .hero {
    padding-top: 64px;
  }

  .hero-inner {
    min-height: calc(80vh - 64px);
  }

  .hero-text {
    max-width: none;
  }

  .products-grid,
  .benefits-grid,
  .gallery-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .card {
    padding: 20px 18px;
  }

  .header-cta {
    display: none;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .floating-whatsapp {
    right: 16px;
    bottom: 16px;
  }
}
