/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* BODY GENERAL */
html, body {
    height: 100%;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background: linear-gradient(to bottom, #f5f7fa, #dbe6f6);
    display: flex;
    flex-direction: column;
}

/* CONTENEDOR GLOBAL (MEJORA PARA PANTALLAS GRANDES) */
main {
    width: 100%;
    max-width: 1200px;
    margin: auto;
    width: 100%;
}

/* IMÁGENES RESPONSIVAS */
img {
    max-width: 100%;
    height: auto;
}

/* HEADER */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #0b3d91;
    color: white;
    padding: 15px 20px;
    flex-wrap: wrap;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    width: clamp(40px, 6vw, 50px);
    margin-right: 10px;
}

.logo h1 {
    font-size: clamp(16px, 3vw, 20px);
}

/* NAV */
nav ul {
    list-style: none;
    display: flex;
    gap: clamp(10px, 2vw, 20px);
    flex-wrap: wrap;
    justify-content: center;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

nav a:hover {
    color: #00d4ff;
}

/* SLIDER */
.slider {
    width: 100%;
    height: clamp(200px, 50vh, 600px);
    overflow: hidden;
}

.slides {
    width: 100%;
    height: 100%;
}

.slides img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.slides img.active {
    display: block;
}

/* CONTENIDO */
.contenido {
    padding: clamp(40px, 6vw, 60px) 20px;
    text-align: center;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)),
                url('../img/fondo-quienes.jpg');
    background-size: cover;
    background-position: center;
    color: white;
}

.contenido h2 {
    font-size: clamp(22px, 5vw, 40px);
    margin-bottom: 20px;
}

.contenido p {
    max-width: 800px;
    margin: auto;
    font-size: clamp(14px, 2.5vw, 18px);
}

/* SERVICIOS */
.servicios {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.servicio {
    width: clamp(250px, 90%, 300px);
    background: rgb(66, 159, 225);
    border-radius: 15px;
    padding: 20px;
    transition: 0.3s;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.servicio:hover {
    transform: translateY(-10px);
}

.servicio img {
    width: 60px;
    margin-bottom: 10px;
}

.servicio h3 {
    color: #0b3d91;
}

/* FORMULARIO */
form {
    width: 90%;
    max-width: 500px;
    margin: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

form input,
form textarea {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 16px;
}

form input:focus,
form textarea:focus {
    border-color: #0b3d91;
    outline: none;
}

form button {
    background: #0b3d91;
    color: white;
    padding: 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}

form button:hover {
    background: #062a66;
}

/* CARRUSEL */
.carrusel {
    overflow: hidden;
    padding: 20px 0;
}

.carrusel-track {
    display: flex;
    gap: 20px;
    width: max-content;
    animation: scroll 20s linear infinite;
}

.card-mini {
    min-width: 200px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
}

.card-mini img {
    height: 120px;
    object-fit: cover;
}

.card-mini h4 {
    padding: 10px;
    color: #0b3d91;
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* FOOTER */
footer {
    background: #0b3d91;
    color: white;
    text-align: center;
    padding: 10px;
    font-size: 14px;
}

/* WHATSAPP */
.whatsapp {
    position: fixed;
    bottom: 15px;
    left: 15px;
    width: clamp(40px, 8vw, 60px);
    height: clamp(40px, 8vw, 60px);
    background: #25D366;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.whatsapp img {
    width: 60%;
}

/* RESPONSIVE TABLET */
@media (max-width: 768px) {

    header {
        flex-direction: column;
        text-align: center;
    }

    nav ul {
        flex-direction: column;
    }

    .slider {
        height: 40vh;
    }

    .contenido {
        padding: 40px 15px;
    }

    .servicios {
        flex-direction: column;
        align-items: center;
    }

    .whatsapp {
        bottom: 10px;
        left: 10px;
    }
}

/* RESPONSIVE MÓVIL PEQUEÑO */
@media (max-width: 480px) {

    .contenido h2 {
        font-size: 22px;
    }

    .contenido p {
        font-size: 14px;
    }

    .servicio {
        width: 95%;
    }

    form input,
    form textarea {
        font-size: 14px;
    }
}