/* Hero */

.hero {

    .hero-background {
        background: url('/assets/images/hero-background.png') center/cover;
        filter: brightness(75%);
    }

    .hero-main {
        padding: calc(10vh + 0.2487 * min(75vmin, 450px)) 5vw 10vh;
    }

    .hero-slogan {
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        text-align: center;
        font-size: 9vmin;
        font-weight: 700;
        line-height: 1em;

        p {
            width: 100%;
            margin: 0;
            padding: 10vmin;
            background-color: rgba(var(--aqu-rgb-dark-blue), 0.85);
        }
    }

    .hero-slogan-2 {
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        text-align: center;
        font-size: 4vmin;
        font-weight: 700;
        line-height: 1.25;

        p {
            width: 100%;
            margin: 0;
            padding: 1rem 3rem;
            background-color: rgb(var(--aqu-rgb-red));
        }
    }

    .hero-text {
        padding-top: 4rem;
        text-align: center;
    }

    @media (min-width: 576px) and (orientation: landscape) {
        .hero-text {
            padding: 0;
        }
    }

    @media (min-width: 768px) {
        .hero-main {
            align-items: normal;
            justify-content: normal;
            padding: 10vh 5vw;
        }

        .hero-slogan {
            font-size: 7vh;
            flex-grow: 100;

            p {
                width: 75vw;
                max-width: 1200px;
                padding: 10vh 9vh;
            }
        }

        .hero-slogan-2 {
            position: absolute;
            top: 60vh;
            right: 5vw;

            p {
                max-width: 50vw;
            }
        }

        .hero-text {
            position: absolute;
            right: calc(55vw + 1rem);
            top: calc(67vh + 1rem);
            width: 35vw;
            padding: 0;
            text-align: right;
        }
    }

    @media (min-width: 1200px) {

        .hero-text {
            position: absolute;
            right: calc(55vw + 1rem);
            top: calc(63.5vh + 1rem);
            width: 35vw;
            padding: 0;
            text-align: right;
        }
    }
}

/* Nosotros section */

.site-section.nosotros {
    .section-container {
        gap: 5rem;
    }

    .grid-group.intro {
        grid-area: 1 / 1 / span 1 / -1;
    }

    .section-img {
        grid-area: 2 / 1 / span 1 / -1;
    }

    .grid.grid-mision-vision {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 5rem;

        @media (min-width: 992px) {
            grid-template-columns: repeat(2, 1fr);
        }
    }

    @media (min-width: 768px) {
        .grid-group.intro {
            grid-area: 2 / 1 / span 1 / span 2;
        }

        .section-img {
            grid-area: 1 / 3 / span 3 / span 2;
        }
    }

    @media (min-width: 992px) {
        .grid-group.intro {
            grid-area: 2 / 1 / span 1 / span 4;
        }

        .section-img {
            grid-area: 1 / 5 / span 3 / span 2;
        }
    }
}

/* Mercado section */

.site-section.mercado {
    .section-banner {
        background: url('/assets/images/banner-1.png') center/cover;
    }

    .section-container {
        gap: 5rem;
    }

    .grid {
        grid-template-columns: 1fr;
        align-items: stretch;
        row-gap: 5rem;
        column-gap: 3rem;
    }

    .section-title {

        .framed-left,
        .framed-right {
            background-color: rgb(var(--aqu-rgb-red));
        }
    }

    @media (min-width: 576px) {
        .card-img {
            aspect-ratio: 16 / 9;
        }
    }

    @media (min-width: 768px) {
        .grid {
            grid-template-columns: repeat(2, 1fr);
        }

        .card-img {
            aspect-ratio: 1 / 1;
        }
    }

    @media (min-width: 992px) {
        .grid {
            grid-template-columns: repeat(3, 1fr);
        }
    }
}

/* Proceso section */

.site-section.proceso {
    .section-container {
        padding-top: 50px;
    }

    .title-constructivo {
        width: max-content;
        max-width: 100%;
        align-self: center;
    }

    .grid.constructivo {
        figure {
            display: flex;
            flex-direction: column;
            justify-content: center;
            margin: 0;

            img {
                max-height: 12rem;
                object-fit: contain;
            }

            figcaption {
                display: flex;
                align-items: center;
                justify-content: center;
                flex: 1;
                padding: 2rem;
                text-align: center;
                font-size: 1rem;
            }
        }

        .big-figure, .medium-figure {
            grid-row-end: span 1;
            grid-column-end: span 4;
        }

        .quote-figure {
            grid-area: 5 / 1 / span 1 / span 4;
            background-color: rgb(var(--aqu-rgb-red));
            color: rgb(var(--aqu-rgb-white));
            text-align: center;

            >span {
                padding: 3rem 2rem 1rem;
                margin: 0;
            }

            figcaption {
                font-size: 1rem;
            }
        }

        @media (min-width: 768px) {
            .big-figure {
                grid-area: 1 / 1 / span 2 / span 4;
    
                img {
                    max-height: 30rem;
                }
            }
    
            .medium-figure {
                grid-column-end: span 2;
            }
        }

        @media (min-width: 992px) {
            .quote-figure {
                grid-area: 3 / 1 / span 1 / span 4;
            }
        }
    }

    .grid.materiales {
        grid-template-columns: 1fr;
        gap: 1.5rem;

        .section-img {
            aspect-ratio: 3 / 2;
        }

        img {
            object-fit: contain;
        }

        @media (min-width: 576px) {
            grid-template-columns: repeat(2, 1fr);
        }

        @media (min-width: 992px) {
            grid-template-columns: repeat(4, 1fr);
        }
    }

    .title-comparativo {
        width: max-content;
        max-width: 100%;
        align-self: center;
    }

    .grid.comparativo {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        align-items: stretch;

        figure {
            display: flex;
            position: relative;
            flex-direction: column;
            justify-content: center;
            margin: 0;
            grid-column-end: span 2;

            &.proceso-campo-step {
                grid-column-start: 1;

                figcaption {
                    border: 2px solid rgb(var(--aqu-rgb-dark-blue));
                }

                .step-number {
                    background-color: rgb(var(--aqu-rgb-dark-blue));
                }

            }

            &.proceso-modular-step {
                grid-column-start: 1;

                figcaption {
                    border: 2px solid rgb(var(--aqu-rgb-red));
                }

                .step-number {
                    background-color: rgb(var(--aqu-rgb-red));
                }
            }

            img {
                max-height: 12rem;
                object-fit: contain;
            }

            figcaption {
                display: flex;
                min-height: 6.75rem;
                align-items: center;
                justify-content: center;
                flex: 1;
                padding: 1rem;
                text-align: center;
                font-size: 1rem;
            }

            .step-number {
                position: absolute;
                top: 0;
                left: 0;
                width: 2.5rem;
                height: 2.5rem;
                align-content: center;
                text-align: center;
                color: rgb(var(--aqu-rgb-white));
            }
        }
    }

    .title-campo,
    .title-modular {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 3rem 0;
        grid-column-start: 1;
        grid-column-end: -1;
    }

    .title-campo h4 {
        color: rgb(var(--aqu-rgb-dark-blue));
    }

    .title-modular h4 {
        color: rgb(var(--aqu-rgb-red));
    }

    @media (min-width: 576px) {
        .grid.comparativo {
            grid-template-columns: repeat(4, 1fr);

            figure {
                &.proceso-campo-step {
                    &:nth-of-type(2n) {
                        grid-column-start: 3;
                    }
                }

                &.proceso-modular-step {
                    grid-column-start: 2;
                }
            }
        }
    }

    @media (min-width: 992px) {
        .grid.comparativo {
            grid-template-columns: repeat(4, 1fr) 3rem repeat(4, 1fr);

            figure {
                &.proceso-modular-step {
                    grid-column-start: 7;
                }

                &:nth-child(1 of .proceso-modular-step) {
                    grid-row-start: 2;
                }

                &:nth-child(2 of .proceso-modular-step) {
                    grid-row-start: 3;
                }

                &:nth-child(3 of .proceso-modular-step) {
                    grid-row-start: 4;
                }

                &:nth-child(4 of .proceso-modular-step) {
                    grid-row-start: 5;
                }
            }
        }

        .title-campo {
            grid-area: 1 / 1 / span 1 / span 4;
        }

        .title-modular {
            grid-area: 1 / 6 / span 1 / span 4;
        }
    }
}

/* Contacto section */

.site-section.contacto {
    padding: 100px 0;
    background-color: rgb(var(--aqu-rgb-dark-blue));
    font-size: 1rem;
    color: rgb(var(--aqu-rgb-white));

    .grid {
        gap: 1.5rem;
    }

    .section-pill {
        display: grid;
        align-items: center;
        grid-template-columns: 3.5rem 1fr;
        grid-column: 1 / -1;
    }

    .pill-icon {
        font-size: 1.5rem;
    }

    .pill-title {
        grid-area: 1 / 2 / span 1 / span 1;

        h5 {
            margin: 0;
            font-variant-caps: small-caps;
        }
    }

    .pill-text {
        grid-area: 2 / 2 / span 1 / span 1;
    }

    .section-map {
        grid-column: 1 / -1;
    }

    @media (min-width: 576px) {
        .section-map {
            aspect-ratio: 16 / 9;
        }
    }

    @media (min-width: 768px) {
        .section-pill {
            grid-column-end: span 3;
        }

        .section-map {
            aspect-ratio: 1 / 1;
            grid-area: 1 / 4 / span 5 / span 3;
        }
    }

    @media (min-width: 992px) {
        .pill-direccion {
            grid-area: 1 / 1 / span 1 / span 4;
        }

        .pill-email {
            grid-area: 2 / 1 / span 1 / span 2;
        }

        .pill-telefono {
            grid-area: 2 / 3 / span 1 / span 2;
        }

        .pill-contacto-1 {
            grid-area: 3 / 1 / span 1 / span 2;
        }

        .pill-contacto-2 {
            grid-area: 3 / 3 / span 1 / span 2;
        }

        .section-map {
            aspect-ratio: 1 / 1;
            grid-area: 1 / 5 / span 3 / span 2;
        }

    }
}