@import url('https://fonts.googleapis.com/css2? family= Montserrat:wght@300 & family= Open+Sans:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400; 1,500;1,600;1,700;1,800 & familia= Poppins:wght@400;500;600;700 & display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    list-style: none;
}

body {
    font-family: 'Open Sans', sans-serif;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px; /* Añadido para que no quede pegado a los bordes en móvil */
}

/* ----- HEADER ----- */
.header {
    width: 100%;
    min-height: 100vh; /* Cambiado de altura fija a mínima para adaptarse */
    background: #0e4cea;
    background: -webkit-linear-gradient(to right, hsla(217, 95%, 50%, 0.458), hsla(263, 76%, 55%, 0.693)), url(Imagenes/portada.jpg);
    background: linear-gradient(to right, hsla(232, 59%, 52%, 0.458), hsla(261, 84%, 52%, 0.693)), url(Imagenes/portada.jpg);
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 80px 0 0; /* Espacio para el menú fijo */
}

/* Menú */
.menu2 {
    position: fixed; /* Fijo para que siempre esté visible */
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 5%;
    background: rgba(0, 0, 0, 0.8); /* Fondo semitransparente para mejorar legibilidad */
    z-index: 1000;
    flex-wrap: wrap;
}

.logo3 {
    width: 150px; /* Tamaño fijo pero razonable */
    height: auto;
}

.menu2 .navbar ul {
    display: flex;
    gap: 10px;
}

.menu2 .navbar ul li a {
    font-size: 16px;
    padding: 10px 15px;
    color: aliceblue;
    font-weight: 600;
    white-space: nowrap;
}

/* Checkbox hamburguesa */
#menu2 {
    display: none;
}

.menu2 label {
    cursor: pointer;
    display: none; /* Oculto en escritorio */
}

.menu2-icono {
    width: 40px; /* Tamaño adecuado para el icono */
    height: auto;
}

/* Contenido del header */
.header-txt h1 {
    font-size: clamp(40px, 10vw, 85px); /* Responsivo: mínimo 40px, máximo 85px */
    color: aliceblue;
    text-transform: uppercase;
    margin-top: 20px;
}

.header-txt p {
    color: #fff;
    font-size: clamp(14px, 4vw, 16px);
    padding: 0 5%;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.btn-1 {
    display: inline-block;
    padding: 12px 30px;
    border: 1px solid #fff;
    color: #fff;
    font-size: 16px;
    text-transform: uppercase;
    font-weight: 600;
    transition: 0.3s;
}

.btn-1:hover {
    color: #1b293A;
    background-color: #fff;
}

.wave2 {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    line-height: 0;
}

/* ----- SECCIÓN SERVICIOS ----- */
.info-2 {
    padding: 40px 0;
}

.titulo {
    color: #642a73;
    font-size: clamp(24px, 6vw, 30px);
    text-align: center;
    margin-bottom: 40px;
}

/* Estilos generales para cada servicio */
.testi-txt, .testo-txt {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-bottom: 60px;
    flex-wrap: wrap; /* Para que en móvil se apilen */
}

/* Invertir el orden en el segundo servicio (imagen a la derecha) */
.testo-txt {
    flex-direction: row-reverse;
}

.imagen-about-us, .imagen-about-us2 {
    width: 40%; /* Reducido para dar más espacio al texto */
    max-width: 400px;
    height: auto;
    flex-shrink: 0;
}

.testi-txt div, .testo-txt div {
    flex: 1;
    min-width: 250px; /* Evita que el texto se comprima demasiado */
}

.testi-txt h3, .testo-txt h3 {
    margin-bottom: 20px;
    font-size: clamp(18px, 5vw, 24px);
}

.testi-txt h3 span, .testo-txt h3 span {
    background: #4d0686;
    color: #fff;
    border-radius: 50%;
    display: inline-block;
    text-align: center;
    width: 30px;
    height: 30px;
    line-height: 30px;
    box-shadow: 0 0 6px 0 rgba(0, 0, 0, .5);
    margin-right: 8px;
}

.testi-txt p, .testo-txt p {
    font-weight: 300;
    text-align: justify;
    margin-bottom: 15px;
}

/* Botones de servicios */
.btn-3, .btn-4 {
    display: inline-block;
    padding: 10px 20px;
    border: 2px solid #4d0686;
    color: #4d0686;
    font-size: 15px;
    text-transform: uppercase;
    font-weight: 600;
    transition: 0.3s;
    margin-top: 15px;
    /* Eliminado margin-left fijo */
}

.btn-3:hover, .btn-4:hover {
    color: #fff;
    background-color: #4d0686;
}

/* ----- CONTACTO ----- */
.contacto {
    width: 100%;
    background-color: #f9f9f9;
    padding: 50px 20px;
    text-align: center;
    margin-bottom: 0;
}

.contacto h2 {
    font-size: clamp(22px, 6vw, 28px);
    margin-bottom: 20px;
}

.contacto form p {
    font-size: 16px;
    margin: 10px 0;
}

/* ----- FOOTER ----- */
.footer {
    position: relative;
    width: 100%;
    background: #3586ff;
    padding: 40px 20px 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.social-icon,
.menu {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin: 10px 0;
    gap: 15px;
}

.social-icon__link {
    font-size: 2rem;
    color: #fff;
    transition: 0.3s;
}

.social-icon__link:hover {
    transform: translateY(-5px);
}

.menu__link {
    font-size: 1rem;
    color: #fff;
    opacity: 0.8;
    font-weight: 300;
}

.menu__link:hover {
    opacity: 1;
}

.footer p {
    color: #fff;
    margin: 15px 0 5px;
    font-size: 0.9rem;
    text-align: center;
}

/* Ondas del footer */
.waves {
    position: absolute;
    top: -50px;
    left: 0;
    width: 100%;
    height: 50px;
    overflow: hidden;
}

.wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: url("https://i.ibb.co/wQZVxxk/wave.png");
    background-size: 1000px 100px;
}

.wave#wave1 {
    z-index: 1000;
    opacity: 1;
    animation: animateWaves 4s linear infinite;
}

.wave#wave2 {
    z-index: 999;
    opacity: 0.5;
    animation: animate 4s linear infinite !important;
}

.wave#wave3 {
    z-index: 1000;
    opacity: 0.2;
    animation: animateWaves 3s linear infinite;
}

.wave#wave4 {
    z-index: 999;
    opacity: 0.7;
    animation: animate 3s linear infinite;
}

@keyframes animateWaves {
    0% { background-position-x: 1000px; }
    100% { background-position-x: 0px; }
}

@keyframes animate {
    0% { background-position-x: -1000px; }
    100% { background-position-x: 0px; }
}

/* ----- MEDIA QUERIES (Móviles) ----- */
@media screen and (max-width: 768px) {
    /* Menú hamburguesa */
    .menu2 label {
        display: block;
    }

    .menu2 .navbar {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #4d0686;
        display: none;
        padding: 20px;
        width: 100%;
    }

    .menu2 .navbar ul {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .menu2 .navbar ul li a {
        font-size: 18px;
        padding: 10px;
        white-space: normal;
    }

    #menu2:checked ~ .navbar {
        display: block;
    }

    /* Ajustes de secciones de servicios */
    .testi-txt, .testo-txt {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .testo-txt {
        flex-direction: column; /* Anulamos row-reverse */
    }

    .imagen-about-us, .imagen-about-us2 {
        width: 70%;
        max-width: 300px;
        margin: 0 auto;
    }

    .testi-txt div, .testo-txt div {
        width: 100%;
    }

    .btn-3, .btn-4 {
        margin-left: 0; /* Aseguramos que no haya margen izquierdo */
    }
}

@media screen and (max-width: 480px) {
    /* Ajustes para móviles pequeños */
    .logo3 {
        width: 120px;
    }

    .menu2 {
        padding: 10px 5%;
    }

    .header-txt h1 {
        font-size: 36px;
    }

    .header-txt p {
        font-size: 14px;
    }

    .btn-1 {
        padding: 10px 20px;
        font-size: 14px;
    }

    .imagen-about-us, .imagen-about-us2 {
        width: 90%;
    }

    .footer {
        padding: 30px 15px 15px;
    }

    .social-icon__link {
        font-size: 1.5rem;
    }
}

/* Botón flotante de WhatsApp (si lo tienes en un CSS aparte, pero lo incluyo aquí) */
.float {
    position: fixed;
    width: 55px;
    height: 55px;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 3px #999;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.float:hover {
    transform: scale(1.1);
}

.my-float {
    margin-top: 0; /* Ajuste fino */
}
