/* ============================================
   CHIAPAS INCENTIVE — STYLES.CSS (DEPURADO)
   ============================================ */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap");

/* ---------- RESET BÁSICO ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.65;
  color: #1b1b1b;
  background-color: #ffffff;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  width: 100%;
  position: relative;

  /* Espacio compensatorio para que el header fijo no tape el contenido */
  padding-top: 80px;
}

/* Reducción del margen en celulares (pantallas hasta 480px) */
@media (max-width: 480px) {
  body {
    padding-top: 65px;
  }
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

h1, h2, h3 {
  font-weight: 800;
  line-height: 1.25;
  color: var(--verde-oscuro);
}

address {
  font-style: normal;
}

/* ---------- VARIABLES ---------- */
:root {
  --verde-oscuro: #1b4332;
  --verde-medio: #2d6a4f;
  --turquesa: #2a9d8f;
  --acento: #d97706;
  --acento-hover: #b45309;
  --whatsapp: #25d366;
  --whatsapp-hover: #1da851;
  --fondo-claro: #f8f9fa;
  --blanco: #ffffff;
  --texto-gris: #5b6660;
  --texto-claro: #f8f9fa;
  --radio: 14px;
  --transicion: all 0.3s ease;
  --max-ancho: 1200px;
}

/* ---------- UTILIDADES Y ACCESIBILIDAD ---------- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background-color: var(--verde-oscuro);
  color: var(--texto-claro);
  padding: 0.9rem 1.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  z-index: 2000;
  border-radius: 0 0 8px 0;
  transition: top 0.25s ease;
}

.skip-link:focus {
  top: 0;
  outline: 3px solid var(--acento);
  outline-offset: -3px;
}

/* ============================================
   HEADER / NAVBAR
   ============================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #ffffff;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.05);
  border-bottom: 1px solid rgba(15, 42, 30, 0.06);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--max-ancho);
  margin: 0 auto;
  padding: 0.6rem 1.5rem;
}

/* ---------- LOGO CON IMAGEN ---------- */
/* Control estricto de contenedor del logo */
.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  height: 64px;            /* Altura fija para el contenedor del logo */
  flex-shrink: 0;          /* Evita que los enlaces del menú lo aplasten */
  padding: 0;
  margin: 0;
}

/* Control estricto para la imagen del logo */
.logo img,
.logo-img {
  max-height: 64px !important;  /* Límite de altura para que quepa en el header */
  width: auto !important;        /* Respeta la proporción exacta sin deformar */
  object-fit: contain;
  display: block;
}

/* En pantallas móviles se ajusta ligeramente para no apretar el botón hamburguesa */
@media (max-width: 480px) {
  .logo-img {
    height: 40px;
    max-width: 165px;
  }
}

/* Botón hamburguesa */
.nav-toggle {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  z-index: 1100;
  order: 3;
}

.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  background-color: var(--verde-oscuro);
  border-radius: 2px;
  transition: var(--transicion);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Overlay oscuro detrás del panel móvil */
.nav-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(15, 42, 30, 0.55);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
  z-index: 1040;
}

.nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Menú móvil (panel lateral) - CERRADO */
.nav-links {
  position: fixed;
  top: 0;
  right: 0;
  transform: translateX(100%);
  visibility: hidden;
  pointer-events: none;
  width: 78%;
  max-width: 320px;
  height: 100vh;
  height: 100dvh;
  background-color: var(--verde-oscuro);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 1.25rem;
  padding: 6rem 2rem 2rem;
  transition: transform 0.4s ease, visibility 0s linear 0.4s;
  z-index: 1050;
  order: 4;
}

/* Menú móvil - ACTIVO */
.nav-links.active {
  transform: translateX(0);
  visibility: visible;
  pointer-events: auto;
  transition: transform 0.4s ease, visibility 0s linear 0s;
}

.nav-links li {
  width: 100%;
}

.nav-links a {
  white-space: nowrap;
  position: relative;
  display: inline-block;
  color: var(--texto-claro);
  font-size: 1.05rem;
  font-weight: 600;
  padding: 0.3rem 0;
  transition: var(--transicion);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background-color: var(--turquesa);
  transition: width 0.3s ease;
}

.nav-links a:hover {
  color: var(--turquesa);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-actions {
  order: 2;
}

/* ---------- BOTONES BASE ---------- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.6rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.9rem;
  white-space: nowrap;
  transition: var(--transicion);
  text-align: center;
}

.btn-whatsapp {
  background-color: var(--whatsapp);
  color: var(--blanco);
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
  font-size: 0.82rem;
  padding: 0.65rem 1.3rem;
}

.btn-whatsapp:hover {
  background-color: var(--whatsapp-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(29, 168, 81, 0.4);
}

.btn-primary {
  background-color: var(--acento);
  color: var(--blanco);
  box-shadow: 0 8px 24px rgba(217, 119, 6, 0.45);
}

.btn-primary:hover {
  background-color: var(--acento-hover);
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(180, 83, 9, 0.55);
}

/* ============================================
   HERO SECTION CON VIDEO RESPONSIVO DE FONDO
   ============================================ */
.hero {
  position: relative;
  width: 100%;
  min-height: 88vh; /* Ocupa casi toda la pantalla */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden; /* Corta cualquier sobrante del video */
  padding: 4rem 1.5rem;
  background-color: #0f2a1e; /* Fondo de respaldo si el video tarda en cargar */
}

/* 1. Video en el fondo absoluto */
.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover; /* Se expande cubriendo todo el ancho y alto sin deformarse */
  z-index: 1;
  pointer-events: none; /* No interfiere con clics o toques */
}

/* 2. Capa de oscurecimiento (filtro) */
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    180deg,
    rgba(15, 42, 30, 0.78) 0%,
    rgba(10, 25, 18, 0.7) 50%,
    rgba(10, 25, 18, 0.92) 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* 3. Textos flotando sobre el video */
.hero-content {
  position: relative;
  z-index: 3;
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
}

.hero-content h1 {
  color: #ffffff;
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.5px;
  margin-bottom: 0.8rem;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.6);
}

.hero-subtitle {
  color: var(--turquesa, #2a9d8f);
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  font-weight: 600;
  margin-bottom: 1.25rem;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
}

.hero-description {
  color: #f1f5f9;
  font-size: clamp(0.95rem, 1.8vw, 1.1rem);
  line-height: 1.7;
  max-width: 760px;
  margin: 0 auto 2.25rem;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}

.hero-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

/* Adaptación a dispositivos móviles */
@media (max-width: 768px) {
  .hero {
    min-height: 80vh;
    padding: 3.5rem 1rem;
  }

  .hero-content h1 {
    font-size: 1.9rem;
  }

  .hero-description {
    font-size: 0.9rem;
    line-height: 1.55;
    margin-bottom: 1.8rem;
  }

  .hero-cta {
    width: 100%;
  }

  .hero-cta .btn {
    width: 100%;
    max-width: 320px;
  }
}

/* ============================================
   ESTILOS DE LA SECCIÓN SERVICIOS DMC
   ============================================ */

.services-section {
  padding: 5rem 1.5rem;
  background-color: var(--fondo-claro, #f8fafc);
  border-top: 1px solid rgba(15, 42, 30, 0.05);
}

.services-container {
  max-width: var(--max-ancho, 1200px);
  margin: 0 auto;
}

/* Cabecera B2B (Estilo Groups2Go) */
.services-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 3.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(15, 42, 30, 0.08);
}

.services-header-text {
  max-width: 820px;
}

.services-eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--turquesa, #2a9d8f);
  margin-bottom: 0.5rem;
}

.services-header h2 {
  font-size: clamp(2rem, 3.5vw, 2.6rem);
  color: var(--verde-oscuro, #0f2a1e);
  margin-bottom: 0.8rem;
  letter-spacing: -0.5px;
}

.services-header p {
  color: var(--texto-gris, #475569);
  font-size: 1.05rem;
  line-height: 1.65;
  margin: 0;
}

.services-header-action {
  flex-shrink: 0;
}

/* Cuadrícula balanceada de 4 pilares (2 columnas en escritorio, 1 en móvil) */
.services-grid-4 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

/* Tarjeta individual */
.service-card {
  background-color: #ffffff;
  border: 1px solid rgba(15, 42, 30, 0.08);
  border-radius: var(--radio, 12px);
  padding: 2.2rem 1.8rem;
  box-shadow: var(--sombra, 0 4px 20px rgba(15, 42, 30, 0.04));
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--sombra-hover, 0 12px 30px rgba(15, 42, 30, 0.12));
  border-color: var(--turquesa, #2a9d8f);
}

/* Contenedor del Icono SVG */
.service-icon {
  width: 54px;
  height: 54px;
  border-radius: 10px;
  background-color: rgba(42, 157, 143, 0.1);
  color: var(--turquesa, #2a9d8f);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.service-card:hover .service-icon {
  background-color: var(--acento, #d97706);
  color: #ffffff;
}

/* Tipografía de la tarjeta */
.service-card h3 {
  font-size: 1.25rem;
  color: var(--verde-oscuro, #0f2a1e);
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.service-card p {
  color: var(--texto-gris, #475569);
  font-size: 0.95rem;
  line-height: 1.65;
  margin: 0;
}

/* Media Queries para adaptabilidad móvil y tablet */
@media (max-width: 900px) {
  .services-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }

  .services-header-action {
    width: 100%;
  }

  .services-header-action .btn {
    display: block;
    width: 100%;
    max-width: 300px;
    text-align: center;
  }
}

@media (max-width: 820px) {
  .services-grid-4 {
    grid-template-columns: 1fr;
  }

  .service-card {
    padding: 1.8rem 1.4rem;
  }
}



/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background-color: #0f2a1e;
  color: #d8e2dc;
  padding: 4rem 1.5rem 1.75rem;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  max-width: var(--max-ancho);
  margin: 0 auto 2.5rem;
}

.footer-column h3 {
  color: var(--texto-claro);
  font-size: 1.05rem;
  margin-bottom: 1.1rem;
  font-weight: 700;
}

.footer-column p {
  font-size: 0.9rem;
  color: #b8c4bd;
  margin-bottom: 0.6rem;
  line-height: 1.7;
}

.footer-column ul li {
  margin-bottom: 0.7rem;
}

.footer-column ul li a,
.footer-column address a {
  font-size: 0.9rem;
  color: #b8c4bd;
  transition: var(--transicion);
}

.footer-column ul li a:hover,
.footer-column address a:hover {
  color: var(--turquesa);
  padding-left: 3px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.social-links li {
  margin-bottom: 0 !important;
}

.social-links a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 50px;
  font-size: 0.85rem !important;
  transition: var(--transicion);
}

.social-links a:hover {
  background-color: var(--acento);
  color: var(--texto-claro) !important;
  padding-left: 1rem !important;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.75rem;
  text-align: center;
  font-size: 0.85rem;
  color: #8fa298;
  max-width: var(--max-ancho);
  margin: 0 auto;
}

/* ---------- WIDGET DE CHAT ---------- */
#chat-widget-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 1500;
}

/* ============================================
   MEDIA QUERIES
   ============================================ */

/* Escritorio - 768px+ */
@media (min-width: 768px) {
  .hero {
    background-attachment: fixed;
  }

  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Escritorio grande - 992px+ */
@media (min-width: 992px) {
  .nav-toggle {
    display: none;
  }

  .nav-overlay {
    display: none;
  }

  .nav-links {
    position: static;
    transform: none;
    visibility: visible;
    pointer-events: auto;
    flex-direction: row;
    align-items: center;
    height: auto;
    width: auto;
    max-width: none;
    background-color: transparent;
    padding: 0;
    gap: 2rem;
    order: 2;
    transition: none;
  }

  .nav-links li {
    width: auto;
  }

  .nav-links a {
    color: var(--verde-oscuro);
  }

  .nav-links a:hover {
    color: var(--turquesa);
  }

  .nav-actions {
    order: 3;
  }

  .footer-content {
    grid-template-columns: 1.5fr 1.2fr 1fr 1fr;
  }
}

/* Dispositivos móviles - hasta 480px */
@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 2.4rem;
  }

  .hero-cta {
    flex-direction: column;
    width: 100%;
  }

  .hero-cta .btn {
    width: 100%;
  }

  .navbar {
    padding: 0.85rem 1.25rem;
  }

  .btn-whatsapp {
    font-size: 0.72rem;
    padding: 0.55rem 1rem;
  }
}