/* General Styles */
/* Estilos del popup */
.popup-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(0,0,0,0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.popup-overlay.active {
    visibility: visible;
    opacity: 1;
}
.popup-box {
    width: 40%;
    background: #1e2d4a;
    margin: 20px;
    padding: 0 0 30px 0;
    border-radius: 10px;
    text-align: center;
    font-family: 'Montserrat', sans-serif;
}
.popup-box h2 {
    margin-bottom: 10px;
    color: #ccd6f6;
}
.popup-box p {
    font-size: 16px;
    margin-bottom: 20px;
    color: white;
}
.popup-box button {
    background: #0a192f;
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-weight: bold;
    border-radius: 5px;
}



body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #0a192f; /* Dark background */
    color: #ccd6f6; /* Light text */
    line-height: 1.6;
    overflow-x: hidden; /* Prevent horizontal scrollbar */
}

.whatsapp-float {
    position: fixed;
    bottom: 20px; /* distancia desde abajo */
    left: 0px;   /* distancia desde la izquierda */
    z-index: 9999; /* siempre encima */
    background-color: #25d366;
    border-top-right-radius: 50px;
    border-bottom-right-radius: 50px;
    padding: 15px 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    text-decoration: none;
    transition: transform 0.2s ease;
}

.whatsapp-float img {
    width: 50px;  /* más grande */
    height: 50px;
}

.whatsapp-float span {
    color: white;
    font-size: 20px;
    font-weight: bold;
    font-family: Arial, sans-serif;
}

.whatsapp-float:hover {
    transform: scale(1.05);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.section {
    padding: 80px 20px;
    text-align: center;
}

.section h2 {
    font-size: 4vmax;
    margin-bottom: 30px;
    color: #f9f9f9;
    position: relative;
    display: inline-block;
}

.section h2::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -10px;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: #64ffda; /* Accent color */
}

.bg-light {
    background-color: #112240; /* Slightly lighter background */
}

.button {
    display: inline-block;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.primary-button {
    background-color: #64ffda;
    color: #0a192f;
}

.primary-button:hover {
    background-color: #49ccb7;
}

/* Header and Navigation */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
}

nav {
    padding: 20px;
    display: flex;
    align-items: center;
    margin: 0;
    transition: background-color 0.5s ease-in-out;
}

.menu {
    width: 93%;
}

nav ul {
    display: flex;
    flex-wrap: wrap; /* Permite que los elementos pasen a la siguiente línea */
    list-style: none;
    padding: 0;
    margin: 0 3%;
    justify-content: flex-end;
  }
  
nav ul li {
margin-right: 10px; /* Espacio entre los elementos */
text-align: right;
}

.logo {
    display: flex;
    align-items: center;
    width: 17%;
}

.logo img {
    height: 40px;
    margin-right: 10px;
}

.logo h1 {
    margin: 0;
    font-size: 1.8em;
    color: white;
}

nav ul li a {
    text-decoration: none;
    color: #ccd6f6;
    font-weight: bold;
    transition: color 0.3s ease;
}

nav ul li a:hover,
nav ul li a.active {
    color: #ffb516;
}

/* Hero Section */
.hero {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 150px 20px 100px;
    text-align: left;
    background-image: linear-gradient(rgba(10, 25, 47, 0.4), rgba(10, 25, 47, 0.4)), url('/static/media/img/index_back.webp');
    background-size: cover;
    background-position: center;
}

.hero-content {
    max-width: 600px;
    margin-right: 40px;
}

.hero h1 {
    font-size: 2em;
    margin-bottom: 20px;
    color: #f9f9f9;
    line-height: 1.2;
}

.hero p {
    font-size: 1.2em;
    color: white;
    margin-bottom: 30px;
}

.hero-image {
    max-width: 400px;
}

.hero-image img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.3);
}

/* Contenedor flexible para los divs */
.about-container {
    display: flex;
    flex-wrap: wrap; /* Esto permite que los elementos se ajusten a la siguiente línea cuando sea necesario */
    justify-content: space-between;
}

/* Estilos para los divs dentro del contenedor */
.about-content {
    width: 48%; /* Ajustamos el ancho para dar espacio */
    margin: 1%; /* Añadimos un pequeño margen entre los elementos */
    text-align: left; /* Alineamos el texto a la izquierda por defecto */
}

/* Estilo de la imagen dentro del div */
.about-content img {
    width: 100%; /* Aseguramos que la imagen ocupe el 100% de su contenedor */
    max-width: 100%;
    height: auto;
}

.features-cards{
    display: flex; /* Usar flexbox para un mejor control del diseño */
    flex-wrap: wrap;
    justify-content: space-between; /* Espacio entre las tarjetas */
    margin-bottom: 20px; /* Añadir margen inferior entre las tarjetas */
}
.card-item{
    margin: 0 1%; /* Añadir margen horizontal para igualar el margen de las tarjetas */
    flex: 0 0 23%;
    background-color: #1e2d4a;
    border-radius: 8px; /* Añadir bordes redondeados para un mejor aspecto */
    overflow: hidden; /* Asegurar que la imagen no se desborde del contenedor */
}

.card-img {
    height: auto;
    width: 100%;
}
.card-img img{
   width: 100%; /* La imagen ocupa todo el ancho del contenedor */
   height: auto;  /* Mantiene la proporción de la imagen */
   display: block; /* Elimina el espacio extra debajo de la imagen */
}

.card-section {
    text-align: left;
    padding: 15px; /* Añadir padding para separar el texto del borde de la tarjeta */
    color: white; /* Asegurar que el texto sea visible sobre el fondo azul */
}

.card-section h3 {
    margin-bottom: 10px; /* Espacio debajo del título */
}

.card-section p {
    font-size: 14px; /* Tamaño de fuente legible */
    line-height: 1.5; /* Espaciado entre líneas para mejor legibilidad */
}

.asociacion{
    background-image: url('../media/img/sostenible.webp') !important;
    background-position: center;
    background-size: cover;
}


.nav-arrows {
    display: flex;
    justify-content: center; /* Centra las flechas horizontalmente */
    margin-top: 10px; /* Espacio entre las tarjetas y las flechas */
}

.nav-arrows .text{
    display: flex; 
    align-items: center;
}

.nav-arrow {
    cursor: pointer;
    padding: 5px 10px;
    color: #1e2d4a;
    margin: 0 5px;
    border-radius: 5px;
    background-color: #f0f0f0;
    user-select: none; /* Evita que el texto de la flecha se seleccione */
}

.nav-arrow:hover {
    color: #112240;
}

.nav-arrow.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    display: none;
}


/* Features Section */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-item {
    background-color: #1e2d4a;
    padding: 30px;
    border-radius: 5px;
    text-align: center;
    transition: transform 0.3s ease-in-out;
}

.feature-item:hover {
    transform: translateY(-5px);
}

.feature-item i {
    font-size: 2em;
    color: #64ffda;
    margin-bottom: 15px;
}

.feature-item h3 {
    color: #f9f9f9;
    margin-bottom: 10px;
}

.feature-item p {
    color: #a8b2d1;
}

.galeria {
  display: flex;
  flex-wrap: wrap;
}

.galeria .imagen {
  flex: 1 1 calc(33.333% - 10px); /* Tres columnas */
  box-sizing: border-box;
  margin: 0 5px;
}

.galeria .imagen img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Technology Section */
.technology-list {
    list-style: none;
    padding: 0;
    margin-top: 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.technology-list li {
    background-color: #1e2d4a;
    color: #ccd6f6;
    padding: 10px 20px;
    margin: 10px;
    border-radius: 5px;
    font-size: 1em;
}


/*Experience*/
.experience-section {
    padding: 60px 20px;
}

.experience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 10px;
}

.experience-card {
    position: relative;
    height: 300px;
    background-size: cover;
    background-position: center;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.4s ease;
}

.experience-card:hover {
    transform: translateY(-10px);
    background: #1e2d4a;
}

.experience-card .overlay {
    position: absolute;
    inset: 0;
    transition: background 0.4s ease;
}

.experience-card:hover .overlay {
    background: rgba(0, 0, 0, 0.6);
}

.experience-content {
    position: absolute;
    bottom: 5px;
    left: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 15px; /* coincide con el contenedor */
    color: #fff;
    transition: bottom 0.4s ease;
}

.experience-card:hover .experience-content {
    bottom: 40px;
}

.experience-content h3 {
    margin: 0 0 10px;
    font-size: 1.3rem;
}

.experience-content p {
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.experience-btn {
    display: inline-block;
    margin-bottom: 5px;
    background: #0a192f;
    color: #fff;
    text-decoration: none;
    padding: 10px 15px;
    border-radius: 5px;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.experience-card:hover .experience-btn {
    opacity: 1;
}

.enterprises {
    background-color: white;
    padding: 20px 50px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px; /* algo más amplio para separación */
    justify-content: space-between;
}

.enterprises > * {
    flex: 1 1 calc(20% - 10px); /* por defecto: 5 columnas (se ajusta a 2 filas si hay más de 5 elementos) */
    max-width: calc(20% - 10px);
}

.enterprises > img{
    width: 100px;
    height: auto;
    object-fit: contain; /* Ajusta la imagen dentro sin deformarla */
}