:root {
    --fuenteHeading: 'Montserrat', sans-serif;
    --fuenteParrafos: 'Inter' sans-serif;

    --blanco: #ffffff;
    --negro: #000000;
    --texto: #153146;
    --gris: #CBD5E1;
    --oscuro: #334155;
    --verde: #10B981;
    --fondo: #F1F5F9;
    --hover: #6366F1;
}

html {
    box-sizing: border-box;
    font-size: 62.5%;
}

*,
*:before,
*:after {
    box-sizing: inherit;
}

body {
    background-color: var(--fondo);
    font-family: var(--fuenteParrafos);
    font-size: 1.6rem;
    line-height: 2;
}

.hidden-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    visibility: hidden;
    transition: opacity 600ms ease-out, transform 600ms ease-out, visibility 0s linear 600ms;
    will-change: opacity, transform;
}

.hidden-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    transition-delay: 0s;
}

/* Globales */

.contenedor {
    width: min(90%, 120rem);
    margin: 0 auto;
}

main.contenedor {
    /* * Duración: 0.7 segundos
     * Efecto: 'ease-out' (rápido al inicio, suave al final)
     * Relleno: 'forwards' (mantiene el estado final de la animación)
     */
    animation: fadeInOnLoad 0.7s ease-out forwards;
}

@keyframes fadeInOnLoad {
    /* Estado inicial: 0% */
    from {
        opacity: 0;
        /* Hacemos que también se deslice sutilmente desde abajo */
        transform: translateY(30px); 
    }
    
    /* Estado final: 100% */
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.contenedor-barra {
    width: min(100%, 200rem);
    margin: 0 auto;
}

a {
    text-decoration: none;
    color: var(--texto);
    line-height: 2;
    font-size: 3rem;
}

h1,
h2,
h3 {
    text-align: center;
    font-family: var(--fuenteHeading);
    line-height: 1.2;
    text-transform: uppercase;
}

h4 {
    text-align: left;
    font-family: var(--fuenteHeading);
    line-height: 1.2;
    text-align: center;
    font-size: 2rem;
}

p {
    line-height: 2rem;
    text-align: justify;
    font-size: 2rem;
}

img {
    max-width: 100%;
    width: 100%;
    align-items: center;
}

h1 {
    font-size: 4rem;
}

@media (min-width: 768px) {
    h1 {
        font-size: 5rem;
    }
}

h2 {
    font-size: 3rem;
}

@media (min-width: 768px) {
    h2 {
        font-size: 4rem;
    }
}

h3 {
    font-size: 2rem;
}

@media (min-width: 768px) {
    h3 {
        font-size: 3rem;
    }
}

/* Utilidades */

.no-margin {
    margin: 1rem;
}
.no-padding {
    padding: 1;
}
.centrar-texto {
    text-align: center;
}
.izq-texto{
    text-align: left;
    padding-left: 2rem;
}
.color-t{
    color: var(--texto);
}

/* HEADER */
.header {
    width: 100%;
    display: flex;
    justify-content: center;
    border-bottom: 0.3rem solid var(--oscuro);
}
.barra {
    width: 100%;
    max-width: 240rem;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.header_img {
    width: 20rem;
    height: auto;
}
.navegacion {
    display: flex;
    gap: 3rem;
}
.navegacion__enlace {
    color: var(--texto);
    text-decoration: none;
    transition: color 0.3s ease;
}
.navegacion__enlace:hover {
    color: var(--hover);
}
@media (max-width: 480px) {
    .header_img {
        width: 12rem;
    }
    .barra {
        align-items: center;
    }
    .navegacion {
        flex-direction: column;
        align-items: flex-end;
        gap: 0.5rem;
    }
    .navegacion__enlace {
        font-size: 2rem;
    }
}

/* Main */

/* Barra img */
.barra-s {
    background-image: linear-gradient(
        rgba(0, 0, 0, 0.5),
        rgba(0, 0, 0, 0.5)
    ),
    url(../img/MainBG.jpg);
    height: 60rem;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    display: flex;
    justify-content: center;
    align-items: center;     
    text-align: center;
    
    padding: 1rem;
}
.img_texto{
    color: var(--fondo);
    margin: 0;
}
.boton-s a {
    display: inline-block;
    border: solid 2px var(--fondo);
    border-radius: 2rem;
    color: var(--fondo);
    padding: 0.8rem 2.2rem;
    text-decoration: none;
    transition: all 0.3s ease;
}
.boton-s a:hover {
    background-color: var(--fondo);
    color: var(--hover);
}
 /* Valores */

 .valores {
    margin: 3rem;
    border: solid 4px var(--texto);
    border-radius: 2rem;
    background-color: var(--gris);
 }
.grid-v {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4rem;
    justify-content: center;
    padding: 3rem;
}
.valor {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 2rem;
    border-radius: 2rem;
    border: 3px solid transparent;
    color: var(--texto);
    background:
        linear-gradient(var(--gris), var(--gris)) padding-box,
        linear-gradient(to top, var(--verde), transparent) border-box;
}
.valor:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.12);
}
@media (max-width: 480px) {
    .grid-v {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 3rem;
        justify-content: center;
        padding: 3rem;
    }
}

/* Ofrecemos */

.ofrecemos {
    padding: 4rem 2rem;
}
.ofrecemos h2 {
    text-align: center;
    margin-bottom: 5rem;
}
.grid-o {
    display: grid;
    gap: 6rem;
    max-width: 180rem;
    margin: 0 auto;
}
.servicio {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.imagen img {
    max-width: 220px;
    height: auto;
}
@media (min-width: 768px) {
    .servicio {
        display: grid;
        grid-template-columns: 1fr 1fr;
        align-items: center;
        gap: 6rem;
        max-width: 150rem;
        margin: 0 auto;
    }
    .servicio:nth-child(even) .imagen {
        order: 2;
    }
    .servicio:nth-child(even) .contenido {
        order: 1;
    }
    .imagen {
        display: flex;
        justify-content: center;
    }
    .contenido {
        max-width: 50rem;
        color: var(--texto);
    }
}

/* Mision y Visión */

.mvsion {
    margin: 3rem;
    border-radius: 2rem;
    background-color: var(--gris);
}
.grid-mvsion {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4rem;
    justify-content: center;
    padding: 3rem;
}
@media (max-width: 480px) {
    .grid-mvsion {
        display: grid;
        grid-template-columns: repeat(1, minmax(0, 1fr));
        gap: 3rem;
        justify-content: center;
        padding: 3rem;
    }
}
.mision {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.mision img {
    width: 240px;
    max-width: 100%;
    height: auto;
    margin-bottom: 2rem;
}
.propuesta {
    width: 100%;
    background-color: var(--texto);
    color: var(--fondo);
    padding: 1rem;
    text-align: center;
}

.propuesta-v {
    position: relative;
    display: inline-block;
    padding: 1rem 0;
    color: var(--fondo);
}
.propuesta-v::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(
        to right,
        transparent,
        var(--verde),
        transparent
    );
    filter: blur(4px);
}
.modelo {
    display: flex;
    justify-content: center;
}

.modelo img {
    width: 120rem;
    max-width: 100%;
    height: auto;
    margin: 2rem;
    padding: 1rem
}

/* Contacto */

.ayuda {
    width: 100%;
    background-color: var(--texto);
    color: var(--fondo);
    padding: 1rem;
    text-align: center;
    margin: 0;
    margin-bottom: -2rem;
}
.contacto {
    padding: 6rem 2rem;
    text-align: center;
}
.descripcion {
    margin-bottom: 4rem; 
    line-height: 1.8;
}
.formulario {
    max-width: 800px;
    margin: auto;
}
.campo {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}
.campo label {
    color: var(--texto);
    font-weight: 500;
    white-space: nowrap; 
}
.campo input,
.campo select,
.campo textarea {
    flex: 1;
}
.fila {
    display: flex;
    gap: 2rem;
}
.fila .campo {
    flex: 1;
}
input,
select,
textarea {
    padding: 1.1rem;
    border-radius: 8px;
    border: 1px solid var(--texto);
    font-size: 1rem;
    outline: none;
    width: 100%;
    box-sizing: border-box;
}
.btn-enviar {
    background: var(--verde);
    color: var(--fondo);
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: 0.3s ease;
}
.btn-enviar:hover {
    background-color: var(--hover);
}
.acciones {
    display: flex;
    justify-content: flex-end;
    margin-top: 2rem;
}
@media (max-width: 480px) {
    .campo {
        flex-direction: column;
        align-items: flex-start;
    }
    .campo label {
        text-align: left;
        width: 100%;
    }
    .campo input,
    .campo select,
    .campo textarea {
        width: 100%;
    }
    .fila {
        flex-direction: column;
        gap: 0;
    }
}
.mensaje-exito {
    color: var(--texto);
    padding: 1rem;
    margin-bottom: 2rem;
    border-radius: 8px;
    text-align: center;
}
/* FOOTER */

.footer {
    width: 100%;
    display: flex;
    justify-content: center;
    border-top: 0.3rem solid var(--oscuro);
}
.barra_f {
    width: 100%;
    max-width: 240rem;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    color: var(--texto);
}
.footer_links {
    display: flex;
    gap: 3rem;
}
.links{
    color: var(--texto);
}
.links:hover{
    color: var(--hover);
}
@media (max-width: 480px) {
    .barra_f {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1rem;
    }
    .barra_f img {
        width: 20rem;
    }
    .footer_links {
        flex-direction: column;
        gap: 1rem;
    }
}