/* =========================
   VARIABLES DE COLOR Y FUENTES
========================= */
:root {
  --primary: #007bff;
  --secondary: #f5f7fa;
  --text-dark: #222;
  --text-light: #666;
  --background: #ffffff;
  --accent: #007bff;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  color: var(--text-dark);
  background-color: var(--background);
  scroll-behavior: smooth;
}

/* =========================
   HEADER
========================= */
header {
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
}

.logo img {
  height: 60px;
  width: auto;
  object-fit: contain;
}

nav a {
  margin-left: 20px;
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 600;
  transition: color 0.3s ease;
}

nav a:hover {
  color: var(--primary);
}

/* =========================
   HERO 
========================= */
.hero {
  height: 70vh;
  background: 
    linear-gradient(rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.8)),
    url('images/hero-bg.jpg') center/cover no-repeat; 
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 20px;
  margin-top: 80px;
}

.hero-content {
  max-width: 700px;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-dark);
}

.hero .highlight {
  color: var(--primary);
}

.hero p {
  color: var(--text-light);
  font-size: 1.1rem;
  margin: 20px 0 40px;
}

.btn {
  background: var(--primary);
  color: #fff;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s ease;
}

.btn:hover {
  background: #0056c4;
}

/* =========================
   SECCIONES GENERALES
========================= */
section {
  padding: 100px 20px;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 10px;
  text-align: center;
  color: var(--text-dark);
}

.section-subtitle {
  color: var(--text-light);
  margin-bottom: 50px;
  font-size: 1.1rem;
  text-align: center;
}

/* =========================
   SERVICIOS
========================= */
.services {
  background: var(--secondary);
  text-align: center;
}

.service-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  max-width: 1100px;
  margin: auto;
}

.service-cards .card {
  background: #fff;
  border-radius: 12px;
  padding: 40px 25px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-cards .card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.service-cards i {
  color: var(--primary);
  margin-bottom: 20px;
  font-size: 3rem;
}

.service-cards h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 10px;
}

.service-cards p {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* =========================
   PROYECTOS
========================= */
.projects {
  background: #fff;
  text-align: center;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  max-width: 1100px;
  margin: auto;
}

.project-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  padding: 40px 25px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.project-card img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 15px;
  border-radius: 10px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  background-color: #fff;
  padding: 10px;
}

.project-card h3 {
  font-size: 1.1rem;
  color: #111;
  font-weight: 700;
  margin-bottom: 10px;
}

.project-card p {
  color: #555;
  font-size: 0.95rem;
  line-height: 1.5;
}

/* =========================
   INFORMACIÓN DE LA EMPRESA
========================= */
.info {
  background: #fff;
  text-align: center;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.info-item {
  background: var(--secondary);
  border-radius: 12px;
  padding: 30px 20px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.info-item:hover {
  transform: translateY(-5px);
}

.info-item i {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 15px;
}

.info-item h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 8px;
}

.info-item p {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.5;
}

.info-item a {
  color: var(--text-dark);
  text-decoration: none;
}

.info-item a:hover {
  color: var(--primary);
}

.map-container {
  margin-top: 50px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

/* =========================
   CATÁLOGO DE SOLUCIONES
========================= */
.catalogo {
  background: var(--secondary);
  text-align: center;
  padding: 100px 20px;
}

.catalogo-content {
  max-width: 600px;
  margin: 40px auto 0;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  padding: 40px 25px;
}

.catalogo-icon {
  width: 100px; /* 🔹 Ajusta el tamaño del icono a tu gusto */
  height: auto;
  margin-bottom: 20px;
}

.catalogo-content p {
  color: var(--text-light);
  font-size: 1rem;
  margin-bottom: 30px;
}

.btn-catalogo {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  padding: 14px 35px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s ease, transform 0.2s ease;
}

.btn-catalogo:hover {
  background: #0056c4;
  transform: translateY(-3px);
}

/* =========================
   CONTACTO
========================= */
.contact {
  background: var(--secondary);
  text-align: center;
}

form {
  max-width: 600px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

form input,
form textarea,
form button {
  width: 100%;
  box-sizing: border-box; /* 🔹 Corrige desalineación de ancho */
}

form input,
form textarea {
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
}

form button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
  font-size: 1rem;
}

form button:hover {
  background: #0056c4;
}

#formFeedback {
  margin-top: 10px;
  font-size: 0.95rem;
}

#formFeedback.success {
  color: green;
}

#formFeedback.error {
  color: red;
}

/* =========================
   FOOTER
========================= */
footer {
  background: #f1f3f6;
  text-align: center;
  padding: 30px 20px;
  margin-top: 50px;
}

footer .socials {
  margin-bottom: 15px;
}

footer .socials a {
  margin: 0 10px;
  display: inline-block;
  color: var(--text-dark);
  text-decoration: none;
  font-size: 1.8rem;
  transition: color 0.3s ease;
}

footer .socials a:hover {
  color: var(--primary);
}

footer p {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* =========================
   BOTÓN FLOTANTE WHATSAPP (solo ícono)
   ========================= */
#whatsapp-float {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 2000;
  display: inline-block;
  text-decoration: none;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

#whatsapp-float img.whatsapp-icon {
  width: 64px;
  height: 64px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

#whatsapp-float:hover img.whatsapp-icon {
  transform: scale(1.1);
}

#whatsapp-float:hover,
#whatsapp-float:focus {
  transform: translateY(-4px);
}

/* Tooltip */
.whatsapp-tooltip {
  position: absolute;
  right: 80px;
  bottom: 50%;
  transform: translateY(50%) translateX(8px);
  background: rgba(34, 34, 34, 0.9);
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.whatsapp-tooltip::after {
  content: "";
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  width: 12px;
  height: 12px;
  background: rgba(34, 34, 34, 0.9);
}

#whatsapp-float:hover .whatsapp-tooltip,
#whatsapp-float:focus .whatsapp-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateY(50%) translateX(0);
}

/* Responsive */
@media (max-width: 480px) {
  #whatsapp-float {
    right: 14px;
    bottom: 14px;
  }
  #whatsapp-float img.whatsapp-icon {
    width: 54px;
    height: 54px;
  }
  .whatsapp-tooltip {
    display: none;
  }
}

/* =========================
   SECCIÓN DE IMÁGENES PROMOCIONALES 
   ========================= */
.promociones {
  width: 100%;
  display: flex;
  justify-content: center;
  background: #fafafa;
  padding: 40px 0;
}

.promo-container {
  position: relative;
  width: 80%;
  max-width: 700px;
  aspect-ratio: 1.19 / 1;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  background: #fafafa;
}

.promo-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.promo-slide.active {
  opacity: 1;
  z-index: 1;
}

/* 🔹 Imágenes con contorno mínimo */
.promo-slide img {
  width: 90%;
  height: 90%;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(0, 0, 0, 0.08); /* contorno sutil */
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.promo-slide img:hover {
  transform: scale(1.04);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  border-color: rgba(0, 0, 0, 0.15);
}

/* Flechas de navegación */
.promo-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.85);
  color: #333;
  border: none;
  font-size: 26px;
  padding: 6px 12px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.promo-btn:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateY(-50%) scale(1.1);
}

.promo-btn.prev { left: 10px; }
.promo-btn.next { right: 10px; }

/* Modal (imagen ampliada) */
.promo-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(250, 250, 250, 0.95);
  z-index: 3000;
  align-items: center;
  justify-content: center;
}

.promo-modal img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
}

.promo-modal .close-modal {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 36px;
  color: #333;
  cursor: pointer;
  transition: color 0.3s ease;
}

.promo-modal .close-modal:hover {
  color: #25D366;
}

/* Responsive */
@media (max-width: 768px) {
  .promo-container {
    width: 90%;
    max-width: 500px;
  }
  .promo-slide img {
    width: 88%;
    height: 88%;
  }
  .promo-btn {
    font-size: 22px;
    padding: 4px 10px;
  }
}

@media (max-width: 480px) {
  .promociones {
    padding: 24px 0;
  }
  .promo-container {
    width: 95%;
  }
  .promo-slide img {
    width: 90%;
    height: 90%;
  }
}

/* =========================
   ESTILO BLOG HP (COLORES DEL INDEX)
========================= */
.hp-article {
  padding: 80px 20px;
  font-family: 'Inter', sans-serif;
  color: var(--fg);
  line-height: 1.8;
  background: var(--bg);
  max-width: 900px;
  margin: auto;
}

.article-title {
  font-size: 2.4rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 10px;
  color: var(--accent);
}

.article-meta {
  text-align: center;
  color: var(--muted);
  margin-bottom: 40px;
}

.article-image {
  text-align: center;
  margin: 30px 0;
}

.article-image img {
  width: 100%;
  max-width: 700px;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}

.hp-article h2 {
  color: var(--accent);
  margin-top: 40px;
  font-size: 1.6rem;
  font-weight: 600;
}

.hp-article p {
  margin-bottom: 20px;
}

.hp-quote {
  background: #f8fafc;
  border-left: 5px solid var(--accent);
  padding: 20px;
  margin: 40px 0;
  font-style: italic;
  color: var(--fg);
}

.contact-banner {
  text-align: center;
  background: #f2f9f9;
  color: var(--fg);
  padding: 35px 20px;
  border-radius: 16px;
  margin-top: 60px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.contact-banner p {
  font-size: 1.1rem;
  margin-bottom: 15px;
}

.contact-banner .btn {
  background: var(--accent);
  color: #fff;
  padding: 12px 30px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  display: inline-block;
}

.contact-banner .btn:hover {
  background: #00414a;
  color: #fff;
}

/* En pantallas pequeñas */
@media (max-width: 768px) {
  .hp-article {
    padding: 60px 15px;
  }

  .article-title {
    font-size: 2rem;
  }

  .article-image img {
    border-radius: 8px;
  }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  .hero p {
    font-size: 1rem;
  }
  nav a {
    margin-left: 10px;
    font-size: 0.95rem;
  }
}
