/* ===============================
   🧼 RESET Y CONFIGURACIÓN BASE
================================= */
body {
  margin: 0;
  padding-top: 40px; /* espacio para la barra superior */
  font-family: 'Segoe UI', sans-serif;
}

/* ===============================
   📞 BARRA SUPERIOR DE CONTACTO
================================= */
.top-contact {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: #ffa500;
  font-size: 1.1rem;
  font-weight: 500;
  padding: 5px 20px;
  text-align: right;
  z-index: 10000;
  transition: all 0.3s ease;
}

.top-contact a {
  text-decoration: none;
  color: #c0392b;
  margin-right: 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.top-contact i {
  font-size: 1.2rem;
  color: #c0392b;
}

/* 🔽 Versión reducida al hacer scroll */
/* 🔽 Versión reducida al hacer scroll */
.top-contact.shrink {
  font-size: 0.9rem;
  padding: 1px 10px; /* mitad de la altura original */
}


/* ===============================
   🧭 NAVEGACIÓN AJUSTADA SIN LOGO
================================= */
.navbar {
  position: fixed;
  top: 30px;
  width: 100%;
  background-color: #fff;
  border-bottom: 2px solid #ffa500;
  z-index: 9999;
  transition: all 0.3s ease;
  padding: 15px 0;
}

.navbar-nav .nav-link {
  color: orange !important;
  font-weight: 600;
  margin-right: 15px;
  transition: color 0.3s ease;
}

.nav-link.active {
  color: #c0392b !important;
  font-weight: bold;
}

.navbar.shrink {
  top: 30px;
  padding: 3px 0;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.navbar.shrink .nav-link {
  font-size: 0.85rem;
  margin-right: 10px;
}
/* ===============================
   🎠 CARRUSEL Y ANIMACIONES
================================= */
.carousel-vertical .carousel-item img {
  width: 400x !important;
  height: 450px !important;
  object-fit: cover;
  margin: auto;
  display: block;
}
.carousel-item img {
  width: 100%;
  height: auto;
  max-height: 100vh;
  object-fit: contain;
}


.carousel-caption.top-caption {
  bottom: 90px;
  top: auto;
  left: 50%;
  transform: translateX(-50%);
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 2;
  padding: 0 20px;
  position: absolute;
}



/* Estilo del texto con sombra negra transparente */
.carrusel-text {
  color: #ffffff;
  font-size: 2rem;
  font-weight: bold;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 1);
  background-color: rgba(0, 0, 0, 0.9); /* fondo negro semitransparente */
  padding: 10px 20px;
  border-radius: 8px;
  animation: fadeInUp 1s ease-in-out;
}

.carousel-caption {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0;
}
.carousel-caption h3 {
  animation: fadeInUp 1s ease-in-out;
}
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 5px;
  background-color: #d91d1a;
  width: 0%;
  animation: progressAnim 5s linear forwards;
}
@keyframes progressAnim {
  from { width: 0%; }
  to { width: 100%; }
}


/* ===============================
   🟢 BOTÓN WHATSAPP FLOTANTE
================================= */
.whatsapp-expand {
  position: fixed;
  bottom: 50px;
  right: 50px;
  z-index: 999;
  background-color: #25d366;
  color: white;
  font-weight: bold;
  font-family: sans-serif;
  padding: 15px;
  border-radius: 30px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 50px;
  overflow: hidden;
  white-space: nowrap;
  transition: width 0.3s ease, background-color 0.3s ease;
}
.whatsapp-expand:hover {
  width: 200px;
  background-color: #1ebe5d;
}
.whatsapp-expand img {
  width: 70px;
  height: 30px;
}
.whatsapp-expand .text {
  opacity: 0;
  transition: opacity 0.3s ease;
}
.whatsapp-expand:hover .text {
  opacity: 1;
}

/* ===============================
   🧊 TARJETAS Y EFECTOS HOVER
================================= */
.col-md-3.mb-4:hover,
.box.highlight:hover {
  background-color: rgba(192, 57, 43, 0.05);
  box-shadow: 0 0 15px rgba(192, 57, 43, 0.3);
  transform: translateY(-5px);
  transition: all 0.3s ease;
  border-radius: 10px;
}
.box.highlight {
  background-color: #fff;
  padding: 10px;
  border-radius: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 0 0 transparent;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===============================
   🧩 GRID DE LOGOS Y CLIENTES
================================= */
.logo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  padding: 20px 0;
}
.mainx {
  flex: 0 0 calc(20% - 20px);
  max-width: calc(20% - 20px);
}
@media (max-width: 992px) {
  .mainx {
    flex: 0 0 calc(33.33% - 20px);
    max-width: calc(33.33% - 20px);
  }
}
@media (max-width: 576px) {
  .mainx {
    flex: 0 0 calc(50% - 20px);
    max-width: calc(50% - 20px);
  }
}
.titulo-clientes {
  text-align: center;
  font-weight: bold;
  font-size: 1.8rem;
  color: #c0392b;
  margin-bottom: 30px;
  text-transform: uppercase;
}

/* ===============================
   🖼️ IMÁGENES Y EFECTOS
================================= */
.image.left img,
img:hover,
.logo-card:hover img {
  transform: scale(1.05);
  transition: transform 0.3s ease;
}
.image.left img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: contain;
  cursor: zoom-in;
}
.fa:hover {
  transform: scale(1.1);
  transition: transform 0.3s ease;
}

/* ===============================
   🧾 TARJETAS DE LOGO
================================= */
.logo-card {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
  background-color: #fff;
  padding: 10px;
  width: 120px;
  height: 120px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.logo-card img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.logo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: rgba(192, 57, 43, 0.85);
  color: white;
  text-align: center;
  padding: 8px;
  font-weight: bold;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.logo-card:hover .logo-overlay {
  opacity: 1;
}
/* ===============================
  🧰 CARRUSEL DE SERVICIOS (Ajustado para diseño unificado)
================================= */
#carouselServicios {
  background-color: #fff;
  padding: 40px 0;
}
#carouselServicios .carousel-inner {
  padding: 20px;
}
#carouselServicios .carousel-item {
  /* Establece una altura mínima para evitar que el carrusel se colapse */
  min-height: 400px; /* Aumentado para las nuevas imágenes de 200px */
}

/*
 * NOTA: Los estilos específicos para la caja (background-color, border, etc.)
 * ya los provee la clase .box.highlight, haciendo innecesarios los estilos
 * previos de #carouselServicios .d-flex.
 * * Además, NO establecemos un tamaño fijo para la imagen aquí (#carouselServicios img),
 * ya que el tamaño de 200x200 está definido directamente en el HTML con el atributo style.
 */

#carouselServicios h6,
#carouselServicios .fw-bold.text-danger {
  color: #c0392b !important; /* Asegurar que el color sea el deseado, usando !important si es necesario */
}
/* ===============================
   🔴 ICONOS DE NAVEGACIÓN CARRUSEL
================================= */
.carousel-control-prev-icon,
.carousel-control-next-icon {
  background-color: #c0392b;
  border-radius: 50%;
  padding: 10px;
  background-size: 60% 60%;
  background-repeat: no-repeat;
  background-position: center;
}

/* Flecha izquierda (Anterior) */
.carousel-control-prev-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3e%3c/svg%3e");
}

/* Flecha derecha (Siguiente) */
.carousel-control-next-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}
@media (max-width: 768px) {
  body {
    padding-top: 150px; /* espacio para top-contact + logo-bar + navbar */
  }

  .logo-bar img {
    height: 60px;
  }

  .navbar {
    top: 90px;
  }

  .carousel-item img {
    height: 300px;
    object-fit: cover;
  }

  .carousel-caption.top-caption {
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0 10px;
    max-width: 90%;
  }

  .carrusel-text {
    font-size: 1.2rem;
    padding: 6px 10px;
    background-color: rgba(0, 0, 0, 0.7);
  }
  
}

.gallery-img {
  width: 100%;
  height: 400px !important;
  object-fit: cover !important;
  display: block;
  border-radius: 0.5rem;
  box-shadow: 0 0 8px rgba(0,0,0,0.1);
}
.galeria-rh img {
  width: 100%;
  height: 250px;   /* todas iguales en altura */
  object-fit: cover; /* recorta sin deformar */
}
.img-icono {
  width: 100px;
  height: auto;
  margin: 0 15px; /* separación lateral mínima */
  object-fit: contain;
  transition: transform 0.3s ease;
}

.img-icono:hover {
  transform: scale(1.1);
}.img-icono1 {
  width: 150px;
  height: auto;
  margin: 0 15px; /* separación lateral mínima */
  object-fit: contain;
  transition: transform 0.3s ease;
}

.img-icono1:hover {
  transform: scale(1.1);
}