* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #f5f5f5;
    color: #111111;
    font-family: "Cormorant Garamond", serif;
    overflow-x: hidden;
}

body.lightbox-open {
    overflow: hidden;
}

img {
    display: block;
    width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    margin: 0;
    padding: 0;

    color: inherit;
    font: inherit;

    background: none;
    border: none;

    cursor: pointer;
}


/* =========================================
   PÁGINA DEL PROYECTO
========================================= */

.project-page {
    position: relative;

    width: 100%;
    min-height: 100vh;

    padding:
        55px
        clamp(45px, 7vw, 140px)
        150px;
}


/* =========================================
   PUNTOS DECORATIVOS
========================================= */

.decorative-dot {
    position: absolute;

    width: 11px;
    height: 11px;

    background-color: #c8c2b9;
    border-radius: 50%;

    pointer-events: none;
}

.dot-top-left {
    top: 46px;
    left: 4.6%;
}

.dot-top-center {
    top: 46px;
    left: 50%;

    transform: translateX(-50%);
}

.dot-top-right {
    top: 46px;
    right: 3.4%;
}

.dot-left-one {
    top: 565px;
    left: 4.6%;
}

.dot-right-one {
    top: 570px;
    right: 3.4%;
}

.dot-left-two {
    top: 1410px;
    left: 5.8%;
}

.dot-right-two {
    top: 1415px;
    right: 2%;
}

.dot-left-three {
    top: 2010px;
    left: 5.4%;
}

.dot-right-three {
    top: 2015px;
    right: 2.5%;
}


/* =========================================
   FLECHA PARA REGRESAR
========================================= */

.back-button {
    position: absolute;

    top: 55px;
    left: clamp(45px, 7vw, 140px);

    z-index: 10;

    font-family: Arial, Helvetica, sans-serif;
    font-size: 38px;
    font-weight: 300;
    line-height: 1;

    transition:
        transform 0.5s ease,
        opacity 0.5s ease;
}

.back-button:hover {
    opacity: 0.55;
    transform: translateX(-7px);
}


/* =========================================
   MENÚ SUPERIOR
========================================= */

.main-menu {
    position: absolute;

    top: 68px;
    right: clamp(45px, 5vw, 105px);

    z-index: 10;

    display: flex;
    flex-direction: column;
    align-items: flex-end;

    gap: 0;
}

.main-menu a {
    font-size: 17px;
    font-weight: 500;
    line-height: 0.9;

    transition:
        opacity 0.5s ease,
        transform 0.5s ease;
}

.main-menu a:hover {
    opacity: 0.45;
    transform: translateX(-3px);
}

.main-menu .active {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}


/* =========================================
   INTRODUCCIÓN DEL PROYECTO
========================================= */

.project-introduction {
    width: min(1250px, 88%);

    margin:
        165px
        auto
        90px;

    display: grid;

    grid-template-columns:
        minmax(520px, 0.9fr)
        minmax(0, 1.1fr);

    align-items: start;

    gap: clamp(70px, 7vw, 120px);
}


/* TÍTULO */

.project-title {
    width: 100%;

    margin: 0;

    font-family: "Cormorant Garamond", serif;
    font-size: clamp(60px, 5.2vw, 82px);
    font-weight: 600;
    line-height: 0.95;
    letter-spacing: -2px;

    white-space: nowrap;
}


/* DESCRIPCIÓN */

.project-description {
    max-width: 650px;
    padding-top: 20px;
}

.project-description p {
    margin-bottom: 22px;

    font-size: clamp(16px, 1.15vw, 20px);
    font-weight: 500;
    line-height: 1.12;
}

.project-description p:last-child {
    margin-bottom: 0;
}


/* =========================================
   GALERÍA NORMAL
========================================= */

.photo-gallery {
    width: min(970px, 78%);

    margin: 0 auto;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 413px));

    justify-content: space-between;

    column-gap: clamp(60px, 9vw, 145px);
    row-gap: 66px;
}

.photo-item {
    position: relative;

    width: 100%;
    aspect-ratio: 413 / 580;

    overflow: hidden;

    background-color: #c6c6c6;
}

.photo-button {
    position: relative;

    width: 100%;
    height: 100%;

    display: block;

    overflow: hidden;

    cursor: zoom-in;
}

.photo-button img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition:
        transform 0.8s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.8s ease;
}

.photo-button:hover img {
    transform: scale(1.025);
}

.photo-button:focus-visible {
    outline: 2px solid #111111;
    outline-offset: 5px;
}


/* =========================================
   LIGHTBOX
========================================= */

.lightbox {
    position: fixed;
    inset: 0;

    z-index: 1000;

    width: 100%;
    height: 100dvh;

    overflow: hidden;

    background-color: #f5f5f5;

    visibility: hidden;
    opacity: 0;

    pointer-events: none;

    transition:
        opacity 0.6s ease,
        visibility 0.6s ease;
}

.lightbox.is-open {
    visibility: visible;
    opacity: 1;

    pointer-events: auto;
}


/* =========================================
   PUNTOS DEL LIGHTBOX
========================================= */

.lightbox-dot {
    position: absolute;

    z-index: 1004;

    width: 10px;
    height: 10px;

    background-color: #c8c2b9;
    border-radius: 50%;

    pointer-events: none;
}

.lightbox-dot-top-left {
    top: 28px;
    left: 28px;
}

.lightbox-dot-top-center {
    top: 28px;
    left: 50%;

    transform: translateX(-50%);
}

.lightbox-dot-top-right {
    top: 28px;
    right: 28px;
}

.lightbox-dot-left-center {
    top: 50%;
    left: 28px;

    transform: translateY(-50%);
}

.lightbox-dot-right-center {
    top: 50%;
    right: 28px;

    transform: translateY(-50%);
}

.lightbox-dot-bottom-left {
    bottom: 28px;
    left: 28px;
}

.lightbox-dot-bottom-right {
    right: 28px;
    bottom: 28px;
}


/* =========================================
   NAVEGACIÓN DEL LIGHTBOX
========================================= */

.lightbox-back {
    position: absolute;

    top: 53px;
    left: clamp(45px, 5vw, 90px);

    z-index: 1005;

    font-family: Arial, Helvetica, sans-serif;
    font-size: 38px;
    font-weight: 300;
    line-height: 1;

    transition:
        opacity 0.4s ease,
        transform 0.4s ease;
}

.lightbox-back:hover {
    opacity: 0.5;
    transform: translateX(-6px);
}

.lightbox-menu {
    position: absolute;

    top: 57px;
    right: clamp(45px, 5vw, 90px);

    z-index: 1005;

    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.lightbox-menu a {
    font-size: 16px;
    font-weight: 500;
    line-height: 0.95;

    transition:
        opacity 0.4s ease,
        transform 0.4s ease;
}

.lightbox-menu a:hover {
    opacity: 0.45;
    transform: translateX(-3px);
}

.lightbox-menu .active {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.lightbox-close {
    position: absolute;

    right: clamp(45px, 5vw, 90px);
    bottom: 40px;

    z-index: 1005;

    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    font-family: Arial, Helvetica, sans-serif;
    font-size: 35px;
    font-weight: 200;
    line-height: 1;

    transition:
        opacity 0.4s ease,
        transform 0.4s ease;
}

.lightbox-close:hover {
    opacity: 0.45;
    transform: rotate(90deg);
}


/* =========================================
   IMÁGENES DEL LIGHTBOX
========================================= */

.lightbox-content {
    position: relative;

    width: 100%;
    height: 100%;

    padding:
        100px
        clamp(45px, 6vw, 110px)
        70px;

    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(180px, 1fr);

    align-items: center;

    gap: clamp(45px, 6vw, 110px);
}

.lightbox-main-wrapper {
    width: 100%;
    height: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}

.lightbox-main-button {
    max-width: 100%;
    max-height: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    cursor: w-resize;
}

.lightbox-main-image {
    width: auto;
    max-width: 100%;

    height: auto;
    max-height: 78vh;

    object-fit: contain;

    opacity: 1;
    transform: scale(1);

    transition:
        opacity 0.35s ease,
        transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.lightbox-main-image.is-changing {
    opacity: 0;
    transform: scale(0.985);
}

.lightbox-next-wrapper {
    width: 100%;

    display: flex;
    flex-direction: column;

    align-items: flex-start;
    justify-content: center;

    gap: 14px;
}

.next-label {
    font-size: 14px;
    font-weight: 500;

    opacity: 0.6;
}

.lightbox-next-button {
    width: min(100%, 310px);

    overflow: hidden;

    cursor: e-resize;
}

.lightbox-next-image {
    width: 100%;
    height: auto;

    max-height: 52vh;

    object-fit: contain;

    transition:
        opacity 0.5s ease,
        transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.lightbox-next-button:hover .lightbox-next-image {
    opacity: 0.72;
    transform: scale(1.025);
}


/* =========================================
   CONTADOR
========================================= */

.lightbox-counter {
    position: absolute;

    left: 50%;
    bottom: 30px;

    z-index: 1005;

    font-size: 15px;
    font-weight: 500;
    letter-spacing: 1px;

    transform: translateX(-50%);
}


/* =========================================
   FOOTER
========================================= */

.site-footer {
    width: 100%;

    min-height: 215px;

    padding:
        55px
        clamp(45px, 6vw, 100px)
        45px;

    display: grid;
    grid-template-columns: 1fr 1fr 1fr;

    align-items: start;

    background-color: #ffffff;
}

.footer-brand {
    display: flex;
    flex-direction: column;

    align-items: flex-start;

    gap: 65px;
}

.footer-brand > a:first-child {
    font-size: 22px;
    font-weight: 500;
}

.instagram-link {
    font-size: 18px;

    transition: opacity 0.4s ease;
}

.instagram-link:hover {
    opacity: 0.45;
}

.footer-menu {
    display: flex;
    flex-direction: column;

    align-items: flex-start;

    gap: 20px;
}

.footer-menu a,
.footer-contact a {
    font-size: 15px;
    font-weight: 500;

    transition:
        opacity 0.4s ease,
        transform 0.4s ease;
}

.footer-menu a:hover,
.footer-contact a:hover {
    opacity: 0.45;
    transform: translateX(3px);
}

.footer-contact {
    display: flex;
    justify-content: flex-start;
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 1000px) {

    .project-introduction {
        width: 88%;

        grid-template-columns:
            minmax(400px, 1fr)
            minmax(0, 1fr);

        gap: 60px;
    }

    .project-title {
        font-size: clamp(54px, 6vw, 72px);
    }

    .photo-gallery {
        width: 80%;

        column-gap: 55px;
        row-gap: 55px;
    }

    .lightbox-content {
        grid-template-columns:
            minmax(0, 2.5fr)
            minmax(170px, 1fr);

        gap: 45px;
    }

}


/* =========================================
   CELULAR
========================================= */

@media (max-width: 720px) {

    .project-page {
        padding:
            35px
            24px
            90px;
    }

    .dot-left-one,
    .dot-right-one,
    .dot-left-two,
    .dot-right-two,
    .dot-left-three,
    .dot-right-three {
        display: none;
    }

    .dot-top-left {
        top: 25px;
        left: 24px;
    }

    .dot-top-center {
        top: 25px;
    }

    .dot-top-right {
        top: 25px;
        right: 24px;
    }

    .back-button {
        top: 50px;
        left: 24px;

        font-size: 32px;
    }

    .main-menu {
        top: 54px;
        right: 24px;
    }

    .main-menu a {
        font-size: 15px;
    }

    .project-introduction {
        width: 100%;

        margin:
            165px
            auto
            65px;

        grid-template-columns: 1fr;

        gap: 45px;
    }

    .project-title {
        width: 100%;

        font-size: clamp(52px, 15vw, 72px);
        line-height: 0.93;

        white-space: normal;
    }

    .project-description {
        max-width: 100%;
        padding-top: 0;
    }

    .project-description p {
        font-size: 17px;
        line-height: 1.18;
    }

    .photo-gallery {
        width: 100%;

        grid-template-columns: 1fr;

        gap: 35px;
    }

    .photo-item {
        width: min(100%, 413px);

        margin: 0 auto;
    }


    /* Lightbox móvil */

    .lightbox-dot-left-center,
    .lightbox-dot-right-center {
        display: none;
    }

    .lightbox-dot-top-left,
    .lightbox-dot-top-center,
    .lightbox-dot-top-right {
        top: 18px;
    }

    .lightbox-dot-top-left {
        left: 18px;
    }

    .lightbox-dot-top-right {
        right: 18px;
    }

    .lightbox-dot-bottom-left {
        bottom: 18px;
        left: 18px;
    }

    .lightbox-dot-bottom-right {
        right: 18px;
        bottom: 18px;
    }

    .lightbox-back {
        top: 48px;
        left: 24px;

        font-size: 31px;
    }

    .lightbox-menu {
        top: 49px;
        right: 24px;
    }

    .lightbox-menu a {
        font-size: 14px;
    }

    .lightbox-close {
        right: 18px;
        bottom: 19px;

        font-size: 30px;
    }

    .lightbox-content {
        padding:
            125px
            24px
            75px;

        grid-template-columns: 1fr;
        grid-template-rows: minmax(0, 1fr) auto;

        gap: 18px;
    }

    .lightbox-main-image {
        max-height: 58vh;
    }

    .lightbox-next-wrapper {
        flex-direction: row;

        align-items: center;
        justify-content: flex-end;

        gap: 12px;
    }

    .next-label {
        font-size: 13px;
    }

    .lightbox-next-button {
        width: 70px;
    }

    .lightbox-next-image {
        max-height: 95px;
    }

    .lightbox-counter {
        bottom: 30px;

        font-size: 13px;
    }

    .site-footer {
        min-height: auto;

        padding:
            45px
            24px;

        grid-template-columns: 1fr;

        gap: 45px;
    }

    .footer-brand {
        gap: 30px;
    }

    .footer-menu {
        gap: 14px;
    }

}


/* =========================================
   PANTALLAS MUY PEQUEÑAS
========================================= */

@media (max-width: 420px) {

    .main-menu a {
        font-size: 14px;
    }

    .project-title {
        font-size: 50px;
    }

    .project-description p {
        font-size: 16px;
    }

}