/* Default colors */
:root {
    --principal_color: #3870c3;
    --principal_color_less_opacity: #2058adbd;
    --white_background: #f6fbff;
    --lively-principal-color: #3e9fcc;
    --clear-principal-color: #71b9da;
}

/* Page default config */
* {
    box-sizing: border-box;
    font-family: 'Helvetica', sans-serif;
    padding: 0;
    margin: 0;
}

/* Page background color */
body {
    background: var(--white_background);
}

/* Header styles */
header {
    width: 100%;
    height: 7vh;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-left: 10%;
    background-color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* Boto menú */

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.7rem;
    font-weight: bold;
    cursor: pointer;
    color: var(--clear-principal-color);
}

.menu-toggle:hover {
    color: var(--white_background);
    background-color: var(--clear-principal-color);
    scale: 1.1;
}

/*----------------------------------------------------------*/

header img {
    width: auto;
    height: 80%;
}

header nav {
    display: flex;
    height: 100%;
}

header nav ul {
    display: flex;
    height: 100%;
    list-style: none;
}

header nav ul li {
    display: flex;
    align-items: center;
}

header nav ul li a {
    display: flex;
    padding-left: 4rem;
    padding-right: 4rem;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-decoration: none;
    color: var(--clear-principal-color);
    font-weight: bold;
    transition: all 0.5s;
}

header nav ul li a:hover {
    background-color: var(--clear-principal-color);
    color: var(--white_background);
}

.activo {
    color: var(--principal_color);
}

header nav ul li a.activo:hover {
    background-color: var(--clear-principal-color);
    color: var(--white_background);
}

/*----------------------------------------------------------*/

/* Main */

main {
    width: 100%;
    height: 93vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 10%;
}

.main-container {
    display: flex;
    width: 100%;
    height: 80%;
    align-items: center;
    gap: 4rem;
}

/* Imagen izquierda */
.main-image {
    flex: 1;
    height: 100%;
    overflow: hidden;
    border-radius: 15px;
}

.main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.85;
    border-radius: 15px;
    transition: transform 0.4s ease;
}

.main-image:hover img {
    transform: scale(1.05);
}

/* Cuadrado azul derecha */
.main-text {
    flex: 1;
    background-color: var(--principal_color);
    color: var(--white_background);
    padding: 4rem;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.main-text h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.main-text p {
    font-size: 1.2rem;
}

/*----------------------------------------------------------*/

/* Sección ¿Qué Ofrecemos? */

#que-ofrecemos {
    background-color: white;
    color: var(--principal_color);
    padding: 6rem 10%;
    text-align: center;
}

#que-ofrecemos h2 {
    font-size: 3rem;
    margin-bottom: 4rem;
}

.cards {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.card {
    background-color: var(--white_background);
    padding: 2rem;
    width: 300px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: 0.3s;
}

.card:hover {
    transform: translateY(-5px);
    cursor: grab;
}

/*----------------------------------------------------------*/

/* Sección Ubicaciones */

#nuestras-ubicaciones {
    background-color: var(--principal_color);
    color: white;
    padding: 6rem 10%;
    text-align: center;
}

#nuestras-ubicaciones h2 {
    font-size: 3rem;
    margin-bottom: 4rem;
}

#nuestras-ubicaciones .card {
    background-color: white;
    color: var(--principal_color);
}

/*----------------------------------------------------------*/

/* Footer */

footer {
    background-color: #1f1f1f;
    color: white;
    padding: 4rem 10%;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 3rem;
}

footer h3 {
    margin-bottom: 1.5rem;
}

.footer-links ul, .footer-info ul, .footer-redes ul {
    list-style: none;
}

.footer-links ul li, .footer-info ul li, .footer-redes ul li {
    margin-bottom: 0.8rem;
}

.footer-links ul li a {
    text-decoration: none;
    color: white;
    transition: 0.3s;
}

.footer-links ul li a:hover {
    color: var(--clear-principal-color);
}

/* Responsive */

@media (max-width: 900px) {
    .menu-toggle {
        height: 100%;
        padding-left: 2rem;
        padding-right: 2rem;
        display: block;
    }

    header nav {
        position: absolute;
        top: 7vh;
        left: 0;
        width: 100%;
        height: auto;
        background-color: var(--principal_color);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
    }

    header nav.open {
        max-height: 100vh;
    }

    header nav ul {
        flex-direction: column;
        width: 100%;
        height: 100%;
    }

    header nav ul li {
        flex: 1;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    header nav ul li a {
        padding: 0;
        width: 100%;
        height: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        color: white;
        text-decoration: none;
        font-weight: bold;
        transition: all 0.5s;
        padding-top: 1rem;
        padding-bottom: 1rem;
    }

    header nav ul li a:hover {
        background-color: var(--clear-principal-color);
        color: var(--white_background);
    }

    .main-container {
        flex-direction: column;
        height: auto;
    }

    .main-image,
    .main-text {
        width: 100%;
        padding: 2rem;
    }

    .main-text h1 {
        font-size: 1.6rem;
    }

    .main-text p {
        font-size: 1.2rem;
    }

    main {
        height: auto;
        padding: 4rem 10%;
    }

    .cards {
        flex-direction: column;
        align-items: center;
    }

    .footer-container {
        flex-direction: column;
        text-align: center;
    }

    .activo {
        color: var(--white_background);
    }
}

/*--------------------------------------------*/

/* Pagina servicios */

/* MAIN SERVICIOS */
.servicios-main {
    padding: 4rem 10%;
    background: var(--white_background);
    flex-direction: column;
}

/* TÍTULO ARRIBA CENTRADO */
.servicios-titulo {
    text-align: center;
    margin-bottom: 1rem;
}

.servicios-titulo h1 {
    font-size: 3rem;
    color: var(--principal_color);
    margin-bottom: 1rem;
}

.servicios-titulo p {
    color: #555;
    font-size: 1.2rem;
}

/* BLOQUES DE CATEGORÍA */
.categoria-servicios {
    margin-bottom: 5rem;
}

.categoria-servicios h2 {
    color: var(--principal_color);
    font-size: 2rem;
    margin-bottom: 2rem;
    border-left: 6px solid var(--principal_color);
    padding-left: 1rem;
}

/* GRID DE 3 */
.categoria-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
}

/* CARD */
.servicio-card {
    display: flex;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    min-height: 200px;
    transition: 0.3s;
}

.servicio-card:hover {
    transform: translateY(-6px);
}

.servicio-card img {
    width: 40%;
    object-fit: cover;
}

.servicio-card div {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.servicio-card h3 {
    margin-bottom: 0.8rem;
    color: var(--principal_color);
}

.servicio-card p {
    color: #555;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .categoria-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .categoria-grid {
        grid-template-columns: 1fr;
    }

    .servicio-card {
        flex-direction: column;
    }

    .servicio-card img {
        width: 100%;
        height: 200px;
    }
}
