 body, html {
    height: 100%;
    margin: 0;
    overflow: hidden; /* Evita el scroll */
   }
   a{
      color: #f3f3f3;
      text-decoration: none;
      margin: 0 10px;
   }
   .header {
    background-color: #00A9FF;
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
    height: 60px;
   }

    .header-left {
    display: flex;
    align-items: center;
   }
   .header-logo {
    width: 40px;
    height: 40px;
    object-fit: cover;
   /* background-color: #ffc107;*/
    margin-right: 15px;
    padding: 5px;
   }
   .header h1 {
    margin: 0;
    font-size: 1.5em;
   }
   .header-right {
    display: flex;
    align-items: center;
   }
   .header-center {
    flex: 1;
    text-align: center;
    font-size: 2.5rem;
    color: #ffffff;
    font-weight: bold;
   }
   .header-icon-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    /*background-color: #ffc107;*/
    color: #141E30;
    font-size: 24px;
    margin-left: 20px;
   }
   /* Círculo blanco solo para el botón de WhatsApp del header */
   .header-right a.header-icon-circle {
     background-color: #ffffff;
     display: flex;
     justify-content: center;
     align-items: center;
     box-shadow: 0 0 8px rgba(0,0,0,0.2);
     width: 52px;
     height: 52px;
     border-radius: 50%;
     position: relative;
     overflow: visible;
     transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
   }
   .header-right a.header-icon-circle::before {
     content: "";
     position: absolute;
     inset: 0;
     border-radius: 50%;
     border: 2px solid rgba(37, 211, 102, 0.6);
     opacity: 0.6;
     transform: scale(1);
     pointer-events: none;
     animation: whatsapp-ripple 1.8s ease-out infinite;
   }
   .header-right a.header-icon-circle:hover {
     background-color: #25D366;
     transform: translateY(-2px) scale(1.05);
     box-shadow: 0 0 14px rgba(37, 211, 102, 0.9);
   }
   .header-right a.header-icon-circle:hover i.fa-whatsapp {
     color: #ffffff;
   }
   /* Estilo y animación solo para el icono de WhatsApp del header */
   .header-right a.header-icon-circle i.fa-whatsapp {
     color: #25D366;
     font-size: 28px;
     animation: whatsapp-pulse 1.2s ease-in-out infinite;
   }
   /* Ocultamos el icono de la ranita por defecto en la vista de escritorio */
   #frog-icon {
    display: none;
   }

   .container {
    display: flex;
    height: calc(100% - 60px); /* Ajusta la altura restando la altura del header */
   }
   .panel-left {
    width: 20%;
    background-color:#141E30;
    padding: 20px 10px;
    box-sizing: border-box;
    position: relative;
   }
   .panel-left .marketing{
      color:#f3f3f3;
      text-align: center;
   }
   .panel-left .social-icons{
      position: absolute;
      bottom: 20px;
      left: 50%;
      transform: translate(-50%, 0);
      color: #e0e0e0;

      font-size: 28px;
   }
   
   .panel-right {
    width: 80%;
    background-color: #141E30; /* Asegura que el panel derecho no tenga un color de fondo que oculte las imágenes */
    position: relative; /* Necesario para posicionar absolutamente el slider de fondo */
    padding: 10px;
   }

   .nav-button {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    background-color:#E6A000 ;
    border-color: #FFFFE6;;
    border-width: 2px;
    color: white;
    /*border: none;*/
    border-radius: 5px;
    text-align: left;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
    box-sizing: border-box;
   }
   .nav-button:hover {
    background-color:#FADB91;
    color:#141E30;
   }
   .nav-button .icon {
    margin-right: 15px;
    font-weight: bold;
   }
.nav-button .circle{
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #fff;
    color: #141E30;
    display: flex;
    justify-content: center;
    align-items: center;
}

   .nav-button:hover .circle {
    background-color: #141E30;
    color: #fff; /* Color del círculo (amarillo) */
   }

   .nav-button .text {
    display: inline;
   }

   @keyframes whatsapp-pulse {
     0% {
       transform: scale(1);
       text-shadow: 0 0 0 rgba(37, 211, 102, 0.7);
     }
     50% {
       transform: scale(1.2);
       text-shadow: 0 0 10px rgba(37, 211, 102, 0.9);
     }
     100% {
       transform: scale(1);
       text-shadow: 0 0 0 rgba(37, 211, 102, 0.7);
     }
   }

   @keyframes whatsapp-ripple {
     0% {
       transform: scale(1);
       opacity: 0.6;
     }
     70% {
       transform: scale(1.7);
       opacity: 0;
     }
     100% {
       transform: scale(1.7);
       opacity: 0;
     }
   }

   .content-section {
    display: none; /* Oculta todas las secciones por defecto */
   }

   .content-section.active {
    display: block; /* Muestra solo la sección activa */
   }

   .overlay-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* Centra el contenedor */
    z-index: 2; /* Asegura que el texto esté sobre las imágenes */
    background-color: rgba(0, 0, 0, 0.6); /* Fondo semitransparente para legibilidad */
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
    height: 200px; /* Altura fija para contener las frases */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 0;
   }
   .phrase {
    position: absolute;
    /*background-color: #007bff;*/
    color: white;
    opacity: 0;
    width: 100%;
    height: 100%;
    /* Ajustes para el nuevo layout con Flexbox */
    display: flex;
    box-sizing: border-box;
    gap: 25px;
   }
   .phrase.active {
    opacity: 1; /* Hacemos visible el contenedor de la frase activa */
   }
   .phrase-image {
    width: 30%;
    height: 100%;
    margin: 0;
    padding: 0;
    border-radius: 8px;
   }
   .phrase-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-items: center;
    justify-content: center;
    text-align: center;

    
   }
   .phrase.active h1 {
    animation: h1-enter 0.8s forwards cubic-bezier(0.25, 0.46, 0.45, 0.94);
   }
   .phrase.active p {
    animation: p-enter 0.8s forwards cubic-bezier(0.25, 0.46, 0.45, 0.94);
   }
   .phrase.exiting {
    opacity: 1; /* Mantenemos visible el contenedor mientras los hijos se animan */
   }
   .phrase.exiting h1 {
    animation: h1-exit 0.8s forwards cubic-bezier(0.55, 0.085, 0.68, 0.53);
   }
   .phrase.exiting p {
    animation: p-exit 0.8s forwards cubic-bezier(0.55, 0.085, 0.68, 0.53);
   }

   .phrase h1, .phrase p {
    opacity: 0;
    margin: 0; /* Reseteamos márgenes */
   }

   .phrase h1 {
    margin-bottom: 5px;
    font-size: 2.5em;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para el texto */
   }
   .phrase p {
    font-size: 1.2em;
   }
   .background-slider {
    /* Para que el slider ocupe todo el espacio del panel derecho, incluyendo el padding */
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    /*background-color: #333;*/
    z-index: 1; /* Asegura que el slider esté por encima de cualquier otro contenido en panel-right */
   }

   .background-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    animation: none; /* La animación se aplicará solo cuando la imagen esté activa */
   }

   .background-image.active {
    opacity: 1 !important;
    animation: kenburns 10s linear forwards; /* Aplica el zoom suave y se mantiene al final */
   }
   
   .background-image.bg1 { background-image: url('../img/bg1.jpeg'); }
   .background-image.bg3 { background-image: url('../img/bg3.jpeg'); }

   @keyframes kenburns {
    0% { transform: scale(0.9); transform-origin: center center; } /* Inicia ligeramente alejado, mostrando más de la imagen */
    100% { transform: scale(1.1); transform-origin: center center; } /* Se acerca suavemente */
   }

   @keyframes h1-enter {
    0% { opacity: 0; transform: translateX(-100px); }
    100% { opacity: 1; transform: translateY(0); }
   }
   @keyframes p-enter {
    0% { opacity: 0; transform: translateX(100px); }
    100% { opacity: 1; transform: translateY(0); }
   }

   @keyframes h1-exit {
    0% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateX(100px); }
   }
   @keyframes p-exit {
    0% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateX(-100px); }
   }

   .promo-image {
    position: absolute;
    left: 50%;
    top:5%;
    transform: translateX(-50%);
     width: 250px; /* Ancho de la imagen promocional */
    height: auto;
    z-index: 3; /* Se coloca entre el fondo (auto) y el texto (z-index: 2) */
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5)); /* Sombra para darle profundidad */
   }

   /* Media query para responsividad en pantallas pequeñas */
   @media (max-width: 768px) {
    .header-center {
      display: none;
    }
    .container {
     flex-direction: column; /* Apila los paneles verticalmente */
    }

    .panel-left {
     width: 100%; /* Ocupa todo el ancho */
     /* Se convierte en una barra horizontal para los botones */
     display: flex;
     justify-content: space-around;
     align-items: flex-start;
     height: auto; /* La altura se ajusta al contenido */
     padding: 5px 0;
     background-color: #E6A000;
    }
    .panel-left .marketing{
      display: none;
    }
    .panel-left .social-icons{
      display: none;
    }
    .nav-button {
     /* Se transforma en icono con texto debajo */
     flex-direction: column;
     width: auto;
     padding: 10px;
     background-color: transparent;
     color: #333;
     border: none;
    }
    .nav-button .icon {
     margin-right: 0;
     margin-bottom: 5px;
     /* El círculo ya tiene su tamaño definido, no necesita ajustes aquí */
    }
     .nav-button:hover{
      background-color: transparent;;
     }

    .panel-right {
     width: 100%; /* Ocupan todo el ancho */
     flex: 1; /* Permite que el panel crezca para ocupar el espacio restante */
     min-height: 0; /* Necesario para que flexbox funcione correctamente con overflow en algunos navegadores */
    }
    .promo-image {
     width: 160px; /* Reducimos más el tamaño para la vista móvil */
     top: 5%; /* Ajustamos la posición vertical */
    }
    /* Mostramos el icono de la ranita solo en la vista móvil */
    #frog-icon {
      display: block;
    }
    
    /* Ajustes para las frases en móvil */
    .phrase {
      gap: 5px 10px;
      padding: 0 10px;
      align-items: center;
    }
    .phrase-image {
      width: 30%; /* Ancho fijo para la imagen en móvil */
      height: 100%;
    }
    .phrase-text {
      text-align: center;
      font-size: 1.0em;
    }
    .phrase h1 {
      font-size: 1.6em;
      text-align: center;
      margin-bottom: 10px;
    }

   }

   /* --- Estilos de la Sección de Productos --- */
   .loader {
    display: none; /* Oculto por defecto */
    border: 8px solid #f3f3f3; /* Gris claro */
    border-top: 8px solid #007bff; /* Azul */
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1.5s linear infinite;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
   }
   @keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
   }
   #productos {
    padding: 20px 40px;
    color: #333;
    background-color: #f4f4f4;
    height: 100%;
    overflow-y: auto; /* Permite scroll solo en esta sección */
    box-sizing: border-box;
    position: relative; /* Para posicionar el loader */
   }
   #productos h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2.5em;
   }
   .product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 280px)); /* Ajusta el ancho máximo para evitar que la última tarjeta se alargue horizontalmente */
    gap: 30px;
    visibility: hidden; /* Oculto hasta que se carguen los datos */
   }
   /* Estado de carga */
   #productos.loading .loader { display: block; }
   #productos.loading .product-grid, #productos.loading h2 { visibility: hidden; }
   /* Estado cargado */
   #productos.loaded .product-grid, #productos.loaded h2 { visibility: visible; }
   

   .product-card {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    /* align-self: start; */ /* Lo comentamos para permitir que las tarjetas se estiren y tengan la misma altura */
    display: flex;
    flex-direction: column;
   }
   .product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
   }
   .product-image {
    width: 100%;
    height: 200px;
    object-fit: fill;
   }
   .product-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
   }
   .product-image-placeholder {
    width: 100%;
    height: 200px; /* Misma altura que las imágenes */
    background-color: #e0e0e0; /* Gris claro */
    display: flex; /* Para centrar el texto si se añade */
    justify-content: center;
    align-items: center;
   }
   /* --- Fin de Estilos de Productos --- */

   /* --- Estilos del Modal --- */
   .modal {
    display: none; /* Oculto por defecto */
    position: fixed; /* Se queda fijo en la pantalla */
    z-index: 1000; /* Se asegura que esté por encima de todo */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto; /* Permite scroll si el contenido es muy grande */
    background-color: rgba(0,0,0,0.6); /* Fondo negro semitransparente */
   }

   .modal-content {
    background-color: #fefefe;
    color: #141E30;
    margin: 15% auto; /* 15% desde arriba y centrado horizontalmente */
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px; /* Ancho máximo del modal */
    height: fit-content;
    border-radius: 10px;
    position: relative;
    text-align: center;
   }

   .modal-content-image{
    height: 80%;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: auto;
   }

   .close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
   }

   .close-button:hover,
   .close-button:focus {
    color: black;
    text-decoration: none;
   }

   /* --- Estilos de la Sección de Contacto --- */
   #contacto {
    display: none; /* Asegurarse que está oculto por defecto */
    flex-direction: column;
    height: 100%;
    padding: 20px 40px;
    box-sizing: border-box;
    background-color: #f4f4f4;
    color: #333;
   }
   #contacto.active {
    display: flex; /* Cambiar a flex cuando esté activo */
   }
   .contact-info {
    text-align: center;
    margin-bottom: 20px;
   }
   .google-map {
    width: 50%;
    height: 100%;
    border: 0;
    border-radius: 8px;
   }
   .contact-body {
    display: flex;
    flex-grow: 1; /* Ocupa el espacio restante */
    gap: 20px; /* Espacio entre el mapa y el formulario */
    min-height: 0; /* Solución para flexbox en algunos navegadores */
   }
   .contact-form {
    width: 50%;
    display: flex;
    flex-direction: column;
    gap: 10px;
   }
   .contact-form input,
   .contact-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    font-family: inherit;
    font-size: 16px;
   }
   .contact-form .form-group {
    display: flex;
    gap: 10px;
   }
   .contact-form .form-group input {
    width: 50%;
   }
   .contact-form textarea {
    resize: vertical;
    flex-grow: 1;
   }
   .submit-button {
    background-color: #E6A000;
    color: white;
    padding: 15px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s;
   }
   .submit-button:hover {
    background-color: #FADB91;
    color: #141E30;
   }

/* Estilos para el contenedor de la imagen y la paginación */
.product-image-container {
  position: relative;
  width: 100%;
}

/* Estilos para la paginación de "pills" */
.pagination-pills {
  /* Eliminamos el posicionamiento absoluto para que fluya naturalmente */
  /* position: absolute; */
  /* bottom: 10px; */
  /* left: 50%; */
  /* transform: translateX(-50%); */
  display: flex;
  justify-content: center; /* Centra los pills horizontalmente */
  gap: 5px;
  z-index: 5; /* Asegura que estén sobre la imagen */
  margin-top: 10px; /* Espacio entre el título y los pills */
  margin-bottom: 10px; /* Espacio entre los pills y la imagen */
}

.pill {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #141E30;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.pill.active {
  background-color: #00A9FF
}

/* --- Estilos de la Sección de Servicios --- */
#servicios {
  padding: 10px 20px;
  color: #333;
  background-color: #f4f4f4;
  height: 100%;
  overflow-y: auto;
  box-sizing: border-box;
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

#servicios h2,
#servicios h3 {
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 18px;
  color: #00A9FF;
  text-align: center;
}

#servicios p {
  font-size: 0.98rem;
  line-height: 1.6;
  color: #444444;
}

.service-row-icon {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background-image: url('../img/iconos.png');
  background-repeat: no-repeat;
  /* Imagen completa 800x600: 4 columnas x 3 filas de 200x200 */
  background-size: 800px 600px;
  margin: 0 auto 15px auto;
}

/* Mapeo de cada servicio al spritesheet (4 columnas x 3 filas) */
.icon-serv-actualizaciones {
  background-position: 0 0; /* fila 1, columna 1 */
}

.icon-serv-servicio-tecnico {
  background-position: -200px 0; /* fila 1, columna 2 */
}

.icon-serv-sonidos {
  background-position: -400px 0; /* fila 1, columna 3 */
}

.icon-serv-restauracion-maquinas {
  background-position: 0 -200px; /* fila 2, columna 1 */
}

.icon-serv-restauracion-muebles {
  background-position: -600px -200px; /* fila 2, columna 4 */
}

.icon-serv-ventas {
  background-position: 0 -400px; /* fila 3, columna 1 */
}

.icon-serv-envios {
  background-position: -400px -400px; /* fila 3, columna 3 (camión) */
}

.icon-serv-pagos {
  background-position: -600px -400px; /* fila 3, columna 4 */
}

.service-container {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr; /* Por defecto, una columna (móvil / pantallas pequeñas) */
  gap: 30px;
}

.service-row {
  background-color: #fff; /* Fondo blanco para que resalte */
  padding: 25px;
  border-radius: 10px; /* Bordes redondeados */
  box-shadow: 0 4px 12px rgba(0,0,0,0.08); /* Sombra suave para dar profundidad */
  margin-bottom: 30px; /* Espacio entre las filas */
  box-sizing: border-box;
}

.service-row h2, .service-row h3 {
  margin-bottom: 20px;
}

.logo-container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 40px; /* Espacio entre logos */
}

.logo-container img {
  max-height: 60px; /* Altura máxima para los logos */
  max-width: 150px; /* Ancho máximo para los logos */
  object-fit: contain; /* Asegura que el logo se vea completo sin distorsión */
}

/* Ajuste para el logo de Interrapidisimo que es más vertical */
.logo-container img[alt="Logo Inter Rapidísimo"] {
  max-height: 80px;
}


/* --- Estilos de Viñetas para Servicios --- */
@media (min-width: 769px) {
  .service-container {
    grid-template-columns: repeat(2, minmax(0, 1fr)); /* Siempre 2 cards por fila en escritorio */
  }

  .service-row {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    grid-template-areas:
      "icon title"
      "desc desc";
    column-gap: 20px;
    row-gap: 10px;
    align-items: center;
    text-align: left; /* Alineamos el texto a la izquierda en escritorio */
  }

  .service-row-icon {
    grid-area: icon;
    flex-shrink: 0; /* Evita que el icono se encoja */
    margin: 0; /* El espaciado lo controla el grid */
    justify-self: center;
  }

  .service-row-content {
    display: contents; /* Sus hijos participan directamente en el grid */
  }

  .service-row-content h2,
  .service-row-content h3 {
    grid-area: title;
    margin-bottom: 8px;
  }

  .service-row-content p {
    grid-area: desc;
  }

  /* Los logos de las últimas tarjetas deben ir debajo de la descripción ocupando todo el ancho */
  .service-row .logo-container {
    grid-column: 1 / -1;
    margin-top: 10px;
  }

  .logo-container {
    justify-content: flex-start; /* Alinea los logos a la izquierda */
  }
}


  