/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Estilos generales */
body, html {
    font-family: 'Poppins', sans-serif;
    background-color: #F7EDE2;
    color: #6D597A;
    scroll-behavior: smooth;
}

/* NAVBAR */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.8); /* Transparencia */
    backdrop-filter: blur(10px); /* Efecto de desenfoque */
    padding: 20px 0;
    z-index: 1000;
    transition: all 0.3s ease-in-out;
}

/* Contenedor del Navbar */
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 90%;
    margin: 0 auto;
}

/* Logo */
.logo a {
    text-decoration: none;
    display: flex;
    align-items: center;
}

/* Estilo para la imagen del logo (nuevo) */
.logo img {
    height: 60px; /* Altura aumentada para el logo */
    width: auto;  /* Ancho automático para mantener proporción */
}

/* Grupo de elementos derechos (añadido) */
.nav-right {
    display: flex;
    align-items: center;
    gap: 25px; /* Espaciado uniforme entre links, botón e icono */
}

/* Enlaces */
.nav-links {
    list-style: none;
    display: flex;
    gap: 30px; /* Reintroducir gap para separar los li */
    align-items: center; /* Asegurar alineación vertical de los links */
}

.nav-links li {
    display: inline;
}

.nav-links li a {
    color: #6D597A;
    text-decoration: none;
    font-size: 1.5em; /* Aumentado */
    font-weight: bold;
    transition: color 0.3s ease, transform 0.3s ease;
}

.nav-links li a:hover {
    color: #E5989B;
    transform: translateY(-3px);
}

/* Estilos para el selector de idiomas */
.language-selector {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    margin-left: 15px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.language-selector:hover {
    background-color: rgba(229, 152, 155, 0.2);
}

.language-selector i#lang-icon {
    color: #6D597A; /* Cambiado para coincidir con los enlaces de navegación */
    font-size: 1.5em;
    transition: transform 0.3s ease;
}

.language-selector:hover i#lang-icon {
    transform: scale(1.1);
}

.language-options-container {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    padding: 10px 0;
    z-index: 1001;
    min-width: 120px;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.language-options-container::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 15px;
    width: 12px;
    height: 12px;
    background-color: white;
    transform: rotate(45deg);
    box-shadow: -2px -2px 5px rgba(0,0,0,0.04);
}

.language-selector.show-options .language-options-container {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.lang-option {
    padding: 8px 15px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-size: 14px;
    color: #333;
}

.lang-option:hover {
    background-color: #f5f5f5;
    color: #E5989B;
}

/* Estilo para quitar la flecha por defecto en algunos navegadores */
.language-selector select::-ms-expand {
    display: none;
}

.language-selector select:focus {
    outline: none; /* Quitar borde al enfocar */
}

/* Estilo para las opciones del dropdown */
.language-selector select option {
    background: white;
    color: #333; /* Color oscuro para el texto de las opciones */
}

/* Botón de contacto en el menú */
.nav-btn {
    background: #E5989B;
    color: white;
    padding: 12px 22px;
    border-radius: 10px;
    font-size: 1.3em; /* Aumentado */
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    /* No necesita márgenes específicos aquí, usa gap */
}

.nav-btn:hover {
    background: #FFB5A7;
    transform: scale(1.1);
}

/* Botón del menú en móviles */
.menu-toggle {
    display: none;
    font-size: 2em; /* Aumentado */
    background: none;
    border: none;
    color: #6D597A;
    cursor: pointer;
}

/* RESPONSIVIDAD */
@media (max-width: 768px) {
    body {
        overflow-x: hidden; /* Evitar scroll horizontal en móviles */
    }
    
    /* NAVBAR MEJORADO PARA MÓVIL */
    nav {
        padding: 15px 0;
    }
    
    .nav-container { 
        width: 95%;
        position: relative;
        justify-content: space-between;
    }

    .logo {
        margin-right: auto;
        z-index: 1001; /* Asegurar que el logo esté por encima del menú desplegable */
    }

    .logo img {
        height: 40px; /* Logo más pequeño en móvil */
    }
    
    /* Creamos un contenedor para language-selector y menu-toggle */
    .nav-container::after {
        content: '';
        display: flex;
        align-items: center;
        gap: 15px;
    }
    
    /* Mostramos y posicionamos language-selector en móvil */
    .language-selector {
        display: inline-flex;
        position: absolute;
        right: 50px; /* Espacio para el botón de menú */
        top: 50%;
        transform: translateY(-50%);
        margin: 0;
        z-index: 1001; /* Asegurar que esté por encima del menú desplegable */
    }
    
    /* Posicionamos el menú toggle */
    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        background: transparent;
        padding: 5px;
        z-index: 1001;
        width: 40px;
        height: 40px;
    }
    
    /* Ocultamos el nav-right original */
    .nav-right { 
        display: none;
    }

    /* Ajustamos el menú desplegable */
    .nav-links {
        display: none;
        position: fixed; /* Fixed para cubrir toda la pantalla */
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 50px 0;
        z-index: 1000;
    }

    /* Estilos cuando el menú está activo */
    .nav-links.show {
        display: flex;
    }

    /* Ajustamos los enlaces del menú */
    .nav-links li {
        margin: 15px 0;
        width: 80%;
        text-align: center;
    }

    .nav-links li a {
        font-size: 1.8em;
        display: block;
        padding: 12px 0;
        color: #6D597A;
    }

    /* Estilos al pasar el mouse */
    .nav-links li a:hover {
        color: #E5989B;
        background-color: rgba(229, 152, 155, 0.1);
        border-radius: 8px;
        transform: none;
    }
    
    /* Añadimos el botón de contacto dentro del menú móvil */
    .nav-links.show:after {
        content: '';
        display: block;
        margin: 20px 0;
        width: 80%;
    }
    
    /* Estilos para el dropdown de idiomas en móvil */
    .language-options-container {
        top: 45px;
        right: 0;
        width: 120px;
    }
    
    .language-options-container::before {
        right: 15px;
    }

    /* HEADER AJUSTES PARA MÓVIL */
    header {
        height: 100vh;
        background-position: center;
        background-size: cover; /* Aseguramos que sea cover para que no se corte */
        padding-top: 60px;
    }
    
    .header-content {
        max-width: 90%;
        padding-top: 60px;
    }
    
    .header-logo {
        max-height: 80px; /* Reducido de 100px a 80px para mejor centrado */
        margin-bottom: 20px;
        width: auto;
    }
    
    .header-content h1 {
        font-size: 2.3em;
        margin-bottom: 15px;
    }
    
    .header-content p {
        font-size: 1.2em;
        margin-bottom: 25px;
    }
    
    .btn {
        font-size: 1.1em;
        padding: 10px 20px;
    }
    
    /* SECCIÓN SOLUCIONES */
    #soluciones {
        padding: 60px 5%;
    }
    
    #soluciones h2 {
        font-size: 2.2em;
        margin-bottom: 10px;
    }
    
    #soluciones p {
        font-size: 1.1em;
        margin-bottom: 30px;
    }
    
    .soluciones-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .solucion {
        padding: 25px 20px;
    }
    
    .solucion img {
        border-radius: 10px;
    }
    
    .solucion h3 {
        font-size: 1.6em;
    }
    
    .solucion p {
        font-size: 1.1em;
    }
    
    /* SECCIÓN SERVICIOS */
    #servicios {
        padding: 60px 5%;
    }
    
    .servicio-container {
        gap: 50px;
    }
    
    .servicio-item {
        gap: 30px;
    }
    
    .servicio-texto h2 {
        font-size: 1.8em;
    }
    
    .servicio-texto p {
        font-size: 1.2em;
    }
    
    .servicio-texto ul li {
        font-size: 1.1em;
    }
    
    /* CONTACTO AJUSTES */
    #contacto {
        padding: 60px 5%;
    }
    
    .contact-container {
        padding: 30px 20px;
        gap: 40px;
    }
    
    /* FOOTER AJUSTES */
    #footer {
        padding: 50px 5% 30px;
    }
    
    .footer-container {
        gap: 40px;
    }
}

/* Media query adicional para pantallas muy pequeñas */
@media (max-width: 480px) {
    .header-logo {
        max-height: 60px; /* Reducido de 80px a 60px para pantallas pequeñas */
        margin-bottom: 15px;
    }
    
    .header-content h1 {
        font-size: 2em;
    }
    
    .soluciones-container {
        grid-template-columns: 1fr;
    }
    
    input, textarea {
        padding: 12px;
        font-size: 1em;
    }
    
    button {
        padding: 12px;
        font-size: 1.1em;
    }
    
    header {
        background-position: center 30%; /* Ajuste de posición de fondo para mejor encuadre */
    }
}

/* HEADER */
header {
    position: relative;
    width: 100%;
    height: 100vh;
    background: url('images/fondo3.jpg') no-repeat center;
    background-size: cover; /* Ya configurado para todos los tamaños */
    background-color: #F8F9FA;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
}

/* Eliminamos la regla que cambia a contain */
/* Si `contain` no funciona en algunos casos, prueba con esta opción */
@media (min-width: 1200px) {
    header {
        background-size: cover; /* Mantener cover en todas las pantallas */
    }
}

/* Capa de opacidad sobre la imagen */
.header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3); /* Opacidad para mejor visibilidad del texto */
    z-index: 1;
}

/* Contenido dentro del header */
.header-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 80%;
    padding: 20px;
}

/* Estilo para el logo en el header */
.header-logo {
    display: block; /* Para que ocupe su propia línea */
    max-height: 250px; /* Reducido de 300px a 250px para mejor proporción */
    width: auto; /* Ancho automático */
    margin: 0 auto 35px auto; /* Margen inferior para equilibrar */
}

.header-content h1 {
    font-size: 3.2em;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.header-content p {
    font-size: 1.4em;
    margin-bottom: 20px;
}

/* BOTÓN CTA */
.btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: #E5989B;
    color: white;
    text-decoration: none;
    font-size: 1.2em;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: #FFB5A7;
    transform: scale(1.08);
}


/* Sección Soluciones */
#soluciones {
    text-align: center;
    padding: 80px 5%;
    background-color: #F8F9FA; /* Fondo claro */
}

#soluciones h2 {
    font-size: 2.8em;
    margin-bottom: 10px;
    font-weight: bold;
    color: #B83B5E;
}

#soluciones p {
    font-size: 1.3em;
    margin-bottom: 40px;
    color: #6D597A;
}

/* Contenedor de soluciones con grid */
.soluciones-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); /* Ajusta el tamaño */
    gap: 50px; /* Espacio entre tarjetas */
    max-width: 1300px;
    margin: auto;
}

/* Tarjetas de Soluciones */
.solucion {
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 6px 20px rgba(240, 167, 57, 0.26);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.solucion:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.solucion img {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 20px;
}

/* Estilos de texto */
.solucion h3 {
    font-size: 1.8em;
    color: #B83B5E;
    font-weight: bold;
    margin-bottom: 10px;
}

.solucion p {
    font-size: 1.2em;
    color: #5a1588;
    font-weight: 500;
    line-height: 1.6;
}

/* SECCIÓN DE SERVICIOS */
#servicios {
    padding: 80px 5%;
    background: url('images/fondo2.jpg') center/cover no-repeat; /* Imagen de fondo */
}

/* Contenedor general de los servicios */
.servicio-container {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

/* Estructura de cada servicio */
.servicio-item {
    display: flex;
    align-items: center;
    gap: 50px;
    justify-content: space-between;
    max-width: 1200px;
    margin: auto;
}

/* Alternar contenido en móviles */
.servicio-invertido {
    flex-direction: row-reverse;
}

/* Estilos de los textos */
.servicio-texto {
    flex: 1;
    text-align: left;
}

.servicio-texto h2 {
    font-size: 2.6em;
    margin-bottom: 10px;
    color: #B83B5E;
}

.servicio-texto p {
    font-size: 1.8em;
    margin-bottom: 15px;
    color: #000000; /* Texto blanco para mejor contraste con el fondo */
}

/* Lista de puntos */
.servicio-texto ul {
    list-style: none;
    padding-left: 0;
}

.servicio-texto ul li {
    font-size: 1.5em;
    color: #000000;
    margin-bottom: 8px;
    padding-left: 25px;
    position: relative;
}

.servicio-texto ul li::before {
    content: "✔";
    position: absolute;
    left: 0;
    color: #E5989B;
    font-weight: bold;
}

/* Contenedor de imagen con tamaño fijo */
.servicio-imagen {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 300px; /* Tamaño fijo para todas las imágenes */
    max-width: 450px; /* Ajustar ancho máximo */
}

/* Imagen con mismo tamaño para todas */
.servicio-imagen img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ajusta sin deformar */
    border-radius: 16px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* RESPONSIVIDAD */
@media (max-width: 900px) {
    .servicio-item {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }

    .servicio-invertido {
        flex-direction: column;
    }

    .servicio-texto {
        text-align: center;
    }

    .servicio-imagen {
        max-width: 100%;
        height: auto;
    }
}


/* SECCIÓN DE CONTACTO */
#contacto {
    padding: 80px 5%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: white; /* Fondo completamente blanco */
}

/* Contenedor principal */
.contact-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 50px;
    background: white;
    padding: 50px;
    border-radius: 16px;
    box-shadow: 0 6px 15px rgba(241, 141, 47, 0.322);
    max-width: 1200px;
    width: 100%;
}

/* Texto de contacto */
.contact-text {
    flex: 1;
    text-align: left;
    max-width: 450px; /* Ajuste del ancho del texto */
}

.contact-text h2 {
    font-size: 2.5em;
    color: #6D597A; /* Color Seoquenze */
    margin-bottom: 10px;
}

.contact-text p {
    font-size: 1.2em;
    color: #6D597A;
}

/* Ícono de contacto */
.icono-contacto {
    font-size: 1.2em;
    color: white;
    background: #E5989B;
    padding: 8px 16px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: bold;
    margin-bottom: 15px;
}

.icono-contacto i {
    font-size: 1.5em;
}

/* FORMULARIO */
.contact-form {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 450px; /* Ajuste del tamaño del formulario */
}

form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

input, textarea {
    width: 100%;
    padding: 14px;
    font-size: 1.1em;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #F0F0F0;
    transition: border 0.3s ease;
}

input:focus, textarea:focus {
    border-color: #E5989B;
    outline: none;
}

/* Botón */
button {
    background: #B83B5E;
    color: white;
    padding: 14px;
    border: none;
    cursor: pointer;
    font-size: 1.2em;
    border-radius: 8px;
    font-weight: bold;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

button:hover {
    background: #FFB5A7;
    transform: scale(1.05);
}

/* RESPONSIVIDAD */
@media (max-width: 900px) {
    .contact-container {
        flex-direction: column;
        text-align: center;
    }

    .contact-text {
        text-align: center;
        max-width: 100%;
    }

    .contact-form {
        max-width: 100%;
    }

    .icono-contacto {
        justify-content: center;
    }
}



/* FOOTER */
#footer {
    background-color: #B5838D;
    color: white;
    padding: 60px 5%;
}

/* Contenedor principal */
.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: auto;
    gap: 50px;
}

/* Sección de suscripción */
.footer-subscribe {
    flex: 1;
    text-align: left;
}

.footer-subscribe h3 {
    font-size: 1.8em;
    margin-bottom: 10px;
}

.footer-subscribe p {
    font-size: 1.2em;
    margin-bottom: 15px;
}

/* Input de suscripción */
#subscribe-form {
    display: flex;
    align-items: center;
    gap: 10px;
}

#email-subscribe {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 1.1em;
}

#subscribe-form button {
    background: #B83B5E;
    color: white;
    border: none;
    padding: 12px 18px;
    font-size: 1.1em;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

#subscribe-form button:hover {
    background: #E5989B;
}

/* Información de contacto */
.footer-contact {
    flex: 1;
    text-align: left;
}

.footer-contact h3 {
    font-size: 1.8em;
    margin-bottom: 10px;
}

.footer-contact p {
    font-size: 1.2em;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-contact i {
    color: #FFB5A7;
    font-size: 1.3em;
}

/* Footer inferior */
.footer-bottom {
    text-align: center;
    margin-top: 40px;
    font-size: 1em;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    padding-top: 20px;
}

/* RESPONSIVIDAD */
@media (max-width: 900px) {
    .footer-container {
        flex-direction: column;
        text-align: center;
    }

    .footer-subscribe, .footer-contact {
        text-align: center;
    }

    #subscribe-form {
        flex-direction: column;
    }

    #email-subscribe {
        width: 100%;
    }
}

/* Estilo para la opción de idioma seleccionada */
.lang-option.selected {
    background-color: rgba(229, 152, 155, 0.1);
    color: #E5989B;
    font-weight: 500;
}

/* Estilos para elementos de menú móvil */
.mobile-lang {
    display: none; /* Oculto por defecto */
    margin: 0;
    width: 35px;
    height: 35px;
}

.mobile-nav-links {
    display: none; /* Oculto por defecto */
}

.mobile-nav-btn {
    margin-top: 20px;
    text-align: center;
}

.mobile-nav-btn .nav-btn {
    display: inline-block;
    margin: 0 auto;
}

/* Reglas específicas para móvil */
@media (max-width: 768px) {
    /* Mostrar el selector de idioma móvil */
    .mobile-lang {
        display: flex;
        position: absolute;
        right: 50px;
        top: 50%;
        transform: translateY(-50%);
        z-index: 1001;
    }
    
    /* Ocultar el selector de idioma original */
    .language-selector:not(.mobile-lang) {
        display: none;
    }
    
    /* Estilos para menú móvil desplegable */
    .mobile-nav-links {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 50px 0;
        z-index: 1000;
    }
    
    .mobile-nav-links.show {
        display: flex;
    }
    
    /* Estilos para botón del menú móvil */
    .mobile-nav-btn .nav-btn {
        background: #E5989B;
        padding: 10px 30px;
        font-size: 1.3em;
    }
    
    /* Ajustes para el botón de toggle del menú móvil */
    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        background: transparent;
        border: none;
        padding: 5px;
        z-index: 1001;
        width: 40px;
        height: 40px;
        color: #6D597A;
        font-size: 1.7em;
        cursor: pointer;
    }
    
    /* Eliminar margen inferior del último elemento de lista en el menú móvil */
    .mobile-nav-links li:last-child {
        margin-bottom: 0;
    }
}

