/* VARIABLES DE COLOR */
:root {
  --color-detail: #baab96; /* Para detalles */
  --color-button: #507355; /* Para botones */
  --color-bg: #f8f7f3;     /* Para fondos */
  --color-text: #1c2536;   /* Para texto */
}

/* FUENTE CORPORATIVA EN LOCAL */
@font-face {
  font-family: 'Montserrat Alt1';
  src: url('/fonts/webfonts/Montserrat-Alt1.css') format('woff2'),
       url('/fonts/webfonts/MontserratAlt1-Light.woff') format('woff'),
       url('/fonts/ttf/MontserratAlt1-Light.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

/* RESETEO BÁSICO */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
}

/* SCROLL */
html {
  scroll-behavior: smooth;
}

/* NAVEGACIÓN */
.main-header {
  background-color: var(--color-bg);
  padding: 1rem 2rem;
  position: fixed; /* Fija el header en la parte superior */
  top: 0; /* Mantiene el header en la parte superior */
  left: 0;
  width: 100%; /* Asegura que el header abarque toda la anchura */
  z-index: 1000; /* Asegura que quede por encima de otros elementos */
}

.navbar {
  display: flex;
  align-items: center;
  font-family: 'Montserrat Alt1', sans-serif;
  padding: 0, 20px;
  position: relative;
  z-index: 2;
}

.logo {
  margin-right: auto;
  font-size: 2rem;
  color: var(--color-text);
  font-weight: bold;
}

.logo-img {
  max-width: 200px; 
  margin-right: 800px; /* Ajusta según tus necesidades */
}

@media (max-width: 768px) {
  .logo-img {
    max-width: 150px;
    margin: auto; /* Ajusta si quieres centrar la imagen */
  }
}

.nav-links {
  display: flex; 
  gap: 60px;          /* Espacio entre enlaces */
  margin-left: auto;  /* Empuja los enlaces al extremo derecho */
  list-style: none;   /* Quitar viñetas si tu lista <ul> las tiene */
}

.nav-links li a {
  text-decoration: none;
  color: black;
  font-weight: 600;
  font-weight: bold;
}

/* Botón que se verá en móvil */
.nav-toggle {
  display: none; /* Oculto por defecto en escritorio */
  background: var(--color-button);
  color: #fff;
  border: none;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  cursor: pointer;
}

/* HERO */
.hero {
  position: relative;
  height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  font-family: 'Montserrat Alt1', sans-serif;
}

#particles-js {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 1;
  pointer-events: auto;
  background: #1a1a1a;
}

#particles-js-main {
  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 1;
  pointer-events: auto;
  background: transparent;
}

#particles-js-nav {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 1;
  pointer-events: auto;
  background: transparent;
}

.hero-content {
  position: relative;
  z-index: 2;
  color: #ffffff;
  text-align: center;
  padding: 0 20px;
}

.hero-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--color-bg);
}

.hero-text {
  font-size: 1rem;
  margin-bottom: 1.5rem;
  margin-left: 1rem;
  color: var(--color-bg);
}

/* Transicion del HERO */
.hero {
  opacity: 0; /* Comienza con opacidad 0 (invisible) */
  transition: opacity 1.5s ease-out; /* Transición de opacidad suave */
}
.hero.visible {
  opacity: 1; /* Opacidad completa al ser visible */
}

/* BOTONES */
.btn {
  display: inline-block;
  background-color: var(--color-button);
  color: #fff;
  padding: 0.85rem 1.5rem;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  font-family: 'Montserrat Alt1', sans-serif;
  border: 2px solid var(--color-button);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  position: relative;
  overflow: hidden;
}
.btn:hover {
  background-color: transparent;
  color: var(--color-button);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-hero {
  background-color: var(--color-button);
  color: var(--color-bg);
  font-weight: 700;
  border: 2px solid var(--color-bg);
}
.btn-hero:hover {
  background-color: var(--color-bg);
  color: var(--color-button);
  border-color: var(--color-bg);
}

.btn-serv {
  margin-left: 520px; /* Regla para pantallas grandes */
}

@media (max-width: 768px) {
  .btn-serv {
    margin: 0 auto;       
    display: block;       
    text-align: center;   
  }
  .btn {
    margin: 0 auto;       
    display: block;       
    text-align: center;   
  }
}

/* SECCIÓN PROC (PRESENTACION) */
.section-proc {
  padding: 3rem 0;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.proc-content, .proc-image {
  flex: 1;
}

.section-proc .container {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .proc-image {
    display: none;
  }
}

/* Animacion PRESENTACION */
.hidden-proc {
  opacity: 0;
  transform: translateX(-50px); /* Para los elementos que se moverán desde la izquierda */
  transition: all 3s ease-out; /* Duración de 3 segundos */
  transition-delay: 0.75s;     /* Retraso de 0.75s */
}
.show {
  opacity: 1;
  transform: translateX(0);
}

.proc-content h2 {
  margin-bottom: 1.5rem;
  margin-top: 6.5rem;
  text-align: center;
  font-family: 'Montserrat Alt1', sans-serif;
}

.proc-content p {
  margin-bottom: 1.5rem;
  margin-right: 3.5rem;
  margin-left: 3.5rem;
  text-align: center;
  font-family: 'Montserrat Alt1', sans-serif;
  font-size: 0.95rem;
  line-height: 1.5rem;
}

.img-presentacion {
  margin-top: 6rem;
}

/* SECCIÓN NUESTROS SERVICIOS */
.section-featured h2 {
  text-align: center;
  margin-bottom: 2rem;
  font-family: 'Montserrat Alt1', sans-serif;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
  font-family: 'Montserrat Alt1', sans-serif;
  text-align: center;
  max-width: 1200px; /* Limitamos el ancho máximo del grid */
  margin-left: auto;
  margin-right: auto;
}
.featured-grid p {
  font-size: 0.9rem;
  line-height: 1.2rem;
}

.featured-card {
  position: relative;
  background-color: transparent;
  width: 100%;
  height: 450px;
  perspective: 1500px;
  cursor: pointer;
  max-width: 340px; /* Aumentamos de 330px a 340px */
  margin: 0 auto;
  border-radius: 8px;
  overflow: hidden;
}

.featured-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 1.2s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.3s ease,
              translateY 0.3s ease;
  transform-style: preserve-3d;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.featured-card:hover .featured-card-inner {
  transform: translateY(-10px) rotateY(180deg) scale(1.02);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.2);
  transition-delay: 0.1s;
}

.featured-card-front,
.featured-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 0;
  overflow: hidden;
  transition: all 0.8s ease;
}

.featured-card-front {
  background-color: #fff;
  transform: rotateY(0deg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
}

.featured-card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  padding: 0;
  margin: 0;
  display: block;
}

.featured-card-back {
  background-color: var(--color-button);
  color: white;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem;
  background-image: linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0)
  );
}

/* Ajustamos para móvil */
@media (max-width: 768px) {
  .featured-card {
    height: 350px;
    max-width: 260px; /* Aumentamos de 250px a 260px */
  }

  .featured-card-front img {
    padding: 0;
  }

  .featured-card-back {
    padding: 1rem;
  }

  .featured-card-back h3 {
    font-size: 1.1rem;
  }

  .featured-card-back p {
    font-size: 0.9rem;
  }
}

/* Animacion SERVICIOS */
.hidden-serv {
  opacity: 0;
  transform: translateY(50px);
  transition: all 1.5s ease-out;
}
.show {
  opacity: 1;
  transform: translateY(0);
}

/* SECCIÓN UBICACIÓN Y LOGOS EMPRESAS */
.carousel-container {
  width: 200%;
  max-width: none;
  overflow: hidden;
  position: relative;
  white-space: nowrap;
  margin-left: -20%;
  margin-right: -20%;
}
.carousel {
  display: flex;
  align-items: center;
  width: 200%;
}
.carousel-slide {
  display: flex;
  animation: slideAnimation 40s linear infinite;
}
.carousel-slide img {
  width: auto;
  height: 100px;
  margin-right: 20px;
  object-fit: contain;
}
/* Animación continua */
@keyframes slideAnimation {
  from {
    transform: translateX(0%);
  }
  to {
    transform: translateX(-50%);
  }
}

.logo-empresas {
  max-width: 500px;
  display: flex;
  margin: auto;
}

h2 {
  font-family: 'Montserrat Alt1', sans-serif;
}
.section-location {
  background-color: transparent;
  color: var(--color-text);
  padding: 3rem 0;
  font-family: 'Montserrat', sans-serif;
  line-height: 1.2rem;
  position: relative;
  z-index: 2;
}

.section-location .container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  background-color: rgba(248, 247, 243, 0.7);
  padding: 2rem;
  border-radius: 8px;
}

.location-content, .location-image {
  flex: 1;
  position: relative;
  z-index: 2;
}

.location-content h2 {
  margin-bottom: 1rem;
  margin-top: 4rem;
}

.location-content p {
  margin-bottom: 1.5rem;
}

.location-image img {
  width: 100%;
  border-radius: 8px;
}

/* SECCIÓN REDES SOCIALES */
.section-subscribe {
  padding: 3rem 0;
  text-align: center;
  font-family: 'Montserrat Alt1', sans-serif;
  font-size: 0.8rem;
  line-height: 1.2rem;
}

.subscribe-container {
  width: 90%;
  max-width: 600px;
  margin: 0 auto;
}

.subscribe-container p {
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}
.subscribe-form {
  margin-top: 1.5rem;
}

.subscribe-form input[type="email"] {
  padding: 0.75rem;
  width: 70%;
  margin-right: 1rem;
  border: 2px solid var(--color-button);
  border-radius: 4px;
}
.subscribe-form button {
  padding: 0.75rem 1rem;
}

/* SECCIÓN CTA FINAL */
.section-call-to-action {
  background: var(--color-detail);
  padding: 3rem 0;
  text-align: center;
}
.section-call-to-action .container {
  width: 90%;
  max-width: 800px;
  margin: 0 auto;
}
.icono {
  max-height: 50px;
  margin-top: 20px;
}

/* FOOTER */
.main-footer {
  background-color: var(--color-text);
  color: #fff;
  padding: 2rem 0;
}
.footer-container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}
.logo-footer {
  max-height: 150px;
}
.footer-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.footer-links li a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
}

/* Asegurar que todo el contenido esté por encima de las partículas */
.main-header,
.hero-content,
.section-proc,
.section-featured,
.section-location,
.section-subscribe,
.main-footer {
  position: relative;
  z-index: 2;
  pointer-events: none;
}
/* Permitir eventos en elementos interactivos específicos */
.navbar,
.nav-links,
.btn,
.featured-card,
.footer-links,
a,
button,
input,
textarea,
.form-group,
.proc-content form {
  position: relative;
  pointer-events: auto;
}
/* Ajustar contenedores para mantener la interactividad */
.container,
.hero-content,
.footer-container,
.subscribe-container {
  position: relative;
  z-index: 2;
}

/* Asegurar que el contenedor del formulario permita interacciones */
.proc-content {
  pointer-events: auto;
}

/* Asegurar que el formulario y sus elementos sean interactivos */
.form-group input,
.form-group textarea {
  position: relative;
  z-index: 3;
  pointer-events: auto;
}

/* MEDIA QUERY para menú móvil */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: black;
    cursor: pointer;
    margin-right: 1rem;
  }

  .nav-links {
    position: absolute;
    top: 80px;
    left: 10px;
    right: 10px;
    background-color: #507355;
    flex-direction: column;
    text-align: center;
    display: none;
    z-index: 1000;
    padding: 40px;
    border-radius: 10px;
  }

  .nav-links.show {
    display: flex; 
  }

  /* Ajustamos la imagen de logos empresas */
  .logo-empresas {
    max-width: 90%; /* Reducimos el ancho máximo */
    margin: 0 auto; /* Centramos la imagen */
    display: none; /* Opcional: si prefieres que desaparezca en móvil */
  }

  /* Ocultar estos elementos cuando el menú esté abierto */
  body.menu-open .hero-content,
  body.menu-open .hero-title,
  body.menu-open .hero-text {
    display: none;
  }

  /* Ajustamos las tarjetas para móvil */
  .featured-card {
    height: 180px; /* Reducimos altura en móvil */
    max-width: 250px; /* Reducimos ancho en móvil */
  }

  .featured-card-front img {
    padding: 0;
    height: 100%; /* Reducimos un poco la altura en móvil para asegurar que se vea completa */
  }

  .featured-card-back {
    padding: 1rem;
  }

  .featured-card-back h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }

  .featured-card-back p {
    font-size: 0.8rem;
    line-height: 1.2;
  }
}

/* Estilos para formularios */
.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    color: #000;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
    font-family: Arial, sans-serif;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--color-button);
    outline: none;
    box-shadow: 0 0 10px rgba(80, 115, 85, 0.3);
}

.error-message {
    color: #ff4444;
    font-size: 14px;
    margin-top: 8px;
    text-align: left;
}

/* Ajustes responsivos para formularios */
@media (max-width: 768px) {
    .form-group input,
    .form-group textarea {
        font-size: 14px;
    }
}


/*Asegurar que el iframe del mapa es interactivo */

.section-location iframe {
  pointer-events: auto;
  z-index: 10;
  position: relative;
  width: 100%;
  max-width: 800px;
  height: 400px;
  display: block;
  margin: 2rem auto;
}


