:root {
    --gold: var(--color-principal);
    --gold-dark: #b8911e;
    --bg: #ffffff;
    --text: #1a1a1a;
}

/* =========================================================
   GENERAL
========================================================= */

html,
body {
    overflow-x: hidden;
}

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

body {
    font-family: "Segoe UI", Arial, sans-serif;
}

/* =========================================================
   SECCIÓN MOMENTOS
========================================================= */

.momentos-section {
    position: relative;
    width: 100%;
    min-height: 800px;
    padding: 5rem 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-image: url("../img/fondo_momentos.png");
    background-size: 110% auto;
    background-position: center;
    background-repeat: no-repeat;
    isolation: isolate;
}
/* =========================================================
   HEADER
========================================================= */

/* =========================================================
   HEADER
========================================================= */

.momentos-header {
    position: relative;

    width: fit-content;
    max-width: 90%;

    text-align: center;

    margin: 0 auto 2.5rem;

    padding: 12px 25px;

    background: #ffffff;

    z-index: 5;
}

/* =========================================================
   TÍTULO
========================================================= */

.momentos-header h2 {
    font-size: 3.0rem;

    font-weight: 800;

    text-align: center;

    margin: 0;

    text-transform: uppercase;

    letter-spacing: 0.5px;

    line-height: 1.2;
}


/* AROMMA */

.momentos-header h2 span {
    color: #000000;
}


/* MOMENTS */

.momentos-header h2 strong {
    color: var(--color-principal);

    font-weight: 800;
}


/* =========================================================
   SUBTÍTULO
========================================================= */

@font-face {
    font-family: 'MV Boli';
    src: url('../fonts/MVBoli.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

.momentos-header p {
    margin: 0.8rem 0 0;

    font-family: 'MV Boli', cursive;
    font-size: 1.1rem;
    line-height: 1.5;
    font-weight: 400;
    color: #000000;
    text-align: center;
    text-transform: uppercase;
}

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

.momentos-gallery {
    position: relative;

    width: 100%;

    max-width: 1600px;

    min-height: 500px;

    display: flex;

    align-items: center;

    justify-content: center;

    z-index: 5;
}


/* =========================================================
   GRID
========================================================= */

.momentos-grid {
    width: 100%;

    max-width: none;

    display: grid;

    grid-template-columns:
        repeat(5, minmax(0, 1fr));

    grid-auto-rows: 215px;

    column-gap: 22px;

    row-gap: 24px;

    padding: 0 85px;
}


/* =========================================================
   POLAROID
========================================================= */

.momento-item {
    position: relative;

    width: 100%;

    height: 215px;

    /*
        MARCO BLANCO
    */
    background: #ffffff;

    /*
        BORDES LATERALES Y SUPERIOR
        + PARTE INFERIOR MÁS GRANDE
    */
    padding:
        10px
        10px
        32px
        10px;

    /*
        ESQUINAS CASI RECTAS
    */
    border-radius: 3px;

    /*
        SOMBRA DE FOTO REAL
    */
    box-shadow:
        5px 7px 14px rgba(0, 0, 0, 0.18),
        10px 14px 28px rgba(0, 0, 0, 0.10);

    /*
        PEQUEÑA PROFUNDIDAD
    */
    border: 1px solid rgba(0, 0, 0, 0.08);

    overflow: visible;

    transition:
        transform 0.35s ease,
        box-shadow 0.35s ease;

    z-index: 2;
}


/* =========================================================
   FOTO
========================================================= */

.momento-item img {
    display: block;

    width: 100%;

    height: 100%;

    /*
        ÁREA DE LA FOTO
    */
    object-fit: cover;

    object-position: center;

    /*
        FONDO POR SI LA IMAGEN TARDA
        EN CARGAR
    */
    background: #CFCFCF;

    /*
        ESQUINAS MUY LIGERAS
    */
    border-radius: 2px;

    transition:
        transform 0.35s ease;
}


/* =========================================================
   COLLAGE
   ROTACIONES DIFERENTES
========================================================= */

/*
    FOTO 1
*/
.momento-item:nth-child(5n + 1) {
    transform:
        translateY(-18px)
        rotate(-5deg);
}


/*
    FOTO 2
*/
.momento-item:nth-child(5n + 2) {
    transform:
        translateY(18px)
        rotate(4deg);
}


/*
    FOTO 3
*/
.momento-item:nth-child(5n + 3) {
    transform:
        translateY(-8px)
        rotate(-2deg);
}


/*
    FOTO 4
*/
.momento-item:nth-child(5n + 4) {
    transform:
        translateY(18px)
        rotate(6deg);
}


/*
    FOTO 5
*/
.momento-item:nth-child(5n + 5) {
    transform:
        translateY(-18px)
        rotate(-4deg);
}


/* =========================================================
   HOVER POLAROID
========================================================= */

.momento-item:hover {
    z-index: 50;

    transform:
        translateY(-12px)
        rotate(0deg)
        scale(1.035);

    box-shadow:
        7px 12px 20px rgba(0, 0, 0, 0.22),
        12px 20px 38px rgba(0, 0, 0, 0.15);
}


.momento-item:hover img {
    transform:
        scale(1.02);
}


/* =========================================================
   FLECHAS
========================================================= */

.momentos-arrow {
    position: absolute;

    top: 50%;

    transform:
        translateY(-50%);

    width: 50px;

    height: 50px;

    display: flex;

    align-items: center;

    justify-content: center;

    background:
        var(--color-principal);

    color: #ffffff;

    border:
        2px solid
        rgba(255, 255, 255, 0.9);

    border-radius: 50%;

    outline: none;

    font-size: 1.8rem;

    font-weight: 700;

    line-height: 1;

    cursor: pointer;

    z-index: 100;

    box-shadow:
        0 4px 10px
        rgba(0, 0, 0, 0.25),

        0 8px 20px
        rgba(0, 0, 0, 0.18);

    transition:
        transform 0.25s ease,
        background 0.25s ease,
        box-shadow 0.25s ease;
}


/* =========================================================
   FLECHA IZQUIERDA
========================================================= */

.momentos-prev {
    left: 0;
}


.momentos-prev:hover {
    transform:
        translateY(-50%)
        translateX(-5px)
        scale(1.08);
}


/* =========================================================
   FLECHA DERECHA
========================================================= */

.momentos-next {
    right: 0;
}


.momentos-next:hover {
    transform:
        translateY(-50%)
        translateX(5px)
        scale(1.08);
}


/* =========================================================
   HOVER FLECHAS
========================================================= */

.momentos-arrow:hover {
    background:
        var(--color-principal);

    color: #ffffff;

    box-shadow:
        0 6px 15px
        rgba(0, 0, 0, 0.30),

        0 10px 25px
        rgba(0, 0, 0, 0.20);
}


/* =========================================================
   ACTIVE
========================================================= */

.momentos-arrow:active {
    transform:
        translateY(-50%)
        scale(0.92);
}


/* =========================================================
   FOCUS
========================================================= */

.momentos-arrow:focus-visible {
    outline:
        2px solid #ffffff;

    outline-offset: 4px;
}


/* =========================================================
   TABLETS GRANDES
========================================================= */

@media (max-width: 1200px) {

    .momentos-section {
        min-height: 720px;

        padding:
            4rem 15px;
    }


    .momentos-gallery {
        max-width: 1100px;

        min-height: 460px;
    }


    .momentos-grid {
        grid-template-columns:
            repeat(5, minmax(0, 1fr));

        grid-auto-rows: 195px;

        column-gap: 16px;

        row-gap: 20px;

        padding:
            0 45px;
    }


    .momento-item {
        height: 195px;

        padding:
            8px
            8px
            28px
            8px;
    }


    /* COLLAGE */

    .momento-item:nth-child(5n + 1) {
        transform:
            translateY(-14px)
            rotate(-5deg);
    }

    .momento-item:nth-child(5n + 2) {
        transform:
            translateY(14px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 3) {
        transform:
            translateY(-6px)
            rotate(-2deg);
    }

    .momento-item:nth-child(5n + 4) {
        transform:
            translateY(14px)
            rotate(5deg);
    }

    .momento-item:nth-child(5n + 5) {
        transform:
            translateY(-14px)
            rotate(-4deg);
    }


    .momentos-header h2 {
        font-size: 2.3rem;
    }
}


/* =========================================================
   TABLETS
========================================================= */

@media (max-width: 1000px) {

    .momentos-section {
        min-height: 680px;

        padding:
            3.5rem 15px;
    }


    .momentos-gallery {
        max-width: 900px;

        min-height: 430px;
    }


    .momentos-grid {
        grid-template-columns:
            repeat(4, minmax(0, 1fr));

        grid-auto-rows: 175px;

        gap: 16px;

        padding:
            0 40px;
    }


    .momento-item {
        height: 175px;

        padding:
            7px
            7px
            25px
            7px;
    }


    /* COLLAGE */

    .momento-item:nth-child(5n + 1) {
        transform:
            translateY(-12px)
            rotate(-5deg);
    }

    .momento-item:nth-child(5n + 2) {
        transform:
            translateY(12px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 3) {
        transform:
            translateY(-5px)
            rotate(-2deg);
    }

    .momento-item:nth-child(5n + 4) {
        transform:
            translateY(12px)
            rotate(5deg);
    }

    .momento-item:nth-child(5n + 5) {
        transform:
            translateY(-12px)
            rotate(-4deg);
    }


    .momentos-arrow {
        width: 44px;

        height: 44px;

        font-size: 1.55rem;
    }


    .momentos-header h2 {
        font-size: 2.1rem;
    }


    .momentos-header p {
        font-size: 1rem;
    }
}


/* =========================================================
   TABLETS PEQUEÑAS
========================================================= */

@media (max-width: 800px) {

    .momentos-section {
        min-height: 620px;

        padding:
            3rem 12px;
    }


    .momentos-header {
        margin-bottom: 2rem;
    }


    .momentos-header h2 {
        font-size: 2rem;
    }


    .momentos-gallery {
        min-height: 400px;

        max-width: 700px;
    }


    .momentos-grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));

        grid-auto-rows: 165px;

        gap: 14px;

        padding:
            0 38px;
    }


    .momento-item {
        height: 165px;

        padding:
            7px
            7px
            24px
            7px;
    }


    /* COLLAGE */

    .momento-item:nth-child(5n + 1) {
        transform:
            translateY(-10px)
            rotate(-4deg);
    }

    .momento-item:nth-child(5n + 2) {
        transform:
            translateY(10px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 3) {
        transform:
            translateY(-5px)
            rotate(-2deg);
    }

    .momento-item:nth-child(5n + 4) {
        transform:
            translateY(10px)
            rotate(5deg);
    }

    .momento-item:nth-child(5n + 5) {
        transform:
            translateY(-10px)
            rotate(-4deg);
    }


    .momentos-arrow {
        width: 42px;

        height: 42px;

        font-size: 1.45rem;
    }


    .momentos-prev {
        left: 1px;
    }


    .momentos-next {
        right: 1px;
    }
}


/* =========================================================
   CELULARES
========================================================= */

@media (max-width: 600px) {

    .momentos-section {
        min-height: auto;

        padding:
            3rem 10px;
    }


    .momentos-header {
        margin-bottom: 1.8rem;
    }


    .momentos-header h2 {
        font-size: 1.6rem;

        line-height: 1.2;
    }


    .momentos-header p {
        font-size: 0.9rem;

        line-height: 1.4;
    }


    .momentos-gallery {
        width: 100%;

        min-height: 380px;
    }


    .momentos-grid {
        width: 100%;

        max-width: 100%;

        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        grid-auto-rows: 145px;

        gap: 12px;

        padding:
            0 34px;
    }


    .momento-item {
        height: 145px;

        padding:
            6px
            6px
            22px
            6px;

        border-radius: 3px;

        box-shadow:
            4px 6px 12px
            rgba(0, 0, 0, 0.18);
    }


    /* COLLAGE */

    .momento-item:nth-child(5n + 1) {
        transform:
            translateY(-8px)
            rotate(-4deg);
    }

    .momento-item:nth-child(5n + 2) {
        transform:
            translateY(8px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 3) {
        transform:
            translateY(-4px)
            rotate(-2deg);
    }

    .momento-item:nth-child(5n + 4) {
        transform:
            translateY(8px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 5) {
        transform:
            translateY(-8px)
            rotate(-4deg);
    }


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

    .momentos-arrow {
        width: 38px;

        height: 38px;

        background:
            var(--color-principal);

        color: #ffffff;

        border:
            2px solid
            rgba(255, 255, 255, 0.95);

        border-radius: 50%;

        font-size: 1.35rem;

        font-weight: 900;

        box-shadow:
            0 3px 8px
            rgba(0, 0, 0, 0.35),

            0 0 0 2px
            rgba(0, 0, 0, 0.10);
    }


    .momentos-prev {
        left: 0;
    }


    .momentos-next {
        right: 0;
    }


    .momentos-arrow:hover {
        background:
            var(--color-principal);

        color: #ffffff;

        transform:
            translateY(-50%)
            scale(1.05);
    }


    .momentos-arrow:active {
        transform:
            translateY(-50%)
            scale(0.90);
    }
}


/* =========================================================
   CELULAR PEQUEÑO
========================================================= */

@media (max-width: 380px) {

    .momentos-section {
        padding:
            2.5rem 8px;
    }


    .momentos-header {
        margin-bottom: 1.5rem;
    }


    .momentos-header h2 {
        font-size: 1.45rem;
    }


    .momentos-header p {
        font-size: 0.82rem;
    }


    .momentos-gallery {
        min-height: 330px;
    }


    .momentos-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        grid-auto-rows: 120px;

        gap: 10px;

        padding:
            0 30px;
    }


    .momento-item {
        height: 120px;

        padding:
            5px
            5px
            18px
            5px;

        border-radius: 3px;
    }


    /* COLLAGE */

    .momento-item:nth-child(5n + 1) {
        transform:
            translateY(-6px)
            rotate(-4deg);
    }

    .momento-item:nth-child(5n + 2) {
        transform:
            translateY(6px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 3) {
        transform:
            translateY(-3px)
            rotate(-2deg);
    }

    .momento-item:nth-child(5n + 4) {
        transform:
            translateY(6px)
            rotate(4deg);
    }

    .momento-item:nth-child(5n + 5) {
        transform:
            translateY(-6px)
            rotate(-4deg);
    }


    .momentos-arrow {
        width: 34px;

        height: 34px;

        font-size: 1.1rem;
    }


    .momentos-prev {
        left: 1px;
    }


    .momentos-next {
        right: 1px;
    }
}

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

.momento-lightbox {
    position: fixed;

    inset: 0;

    width: 100%;
    height: 100%;

    display: flex;

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

    padding: 40px;

    background: rgba(0, 0, 0, 0.88);

    opacity: 0;
    visibility: hidden;

    z-index: 99999;

    overflow: hidden;

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


.momento-lightbox.active {
    opacity: 1;

    visibility: visible;
}


/* =========================================================
   CONTENEDOR DE LA IMAGEN
========================================================= */

.momento-lightbox img {
    display: block;

    max-width: 90vw;
    max-height: 88vh;

    width: auto;
    height: auto;

    object-fit: contain;

    border-radius: 3px;

    box-shadow:
        0 15px 50px
        rgba(0, 0, 0, 0.45);

    transform:
        translate(0px, 0px)
        scale(0.75);

    transform-origin: center center;

    cursor: grab;

    user-select: none;

    -webkit-user-select: none;

    -webkit-user-drag: none;

    touch-action: none;

    transition:
        transform 0.35s cubic-bezier(
            0.2,
            0.8,
            0.2,
            1
        );
}


/* =========================================================
   IMAGEN ABIERTA
========================================================= */

.momento-lightbox.active img {
    transform:
        translate(
            var(--zoom-x, 0px),
            var(--zoom-y, 0px)
        )
        scale(var(--zoom, 1));
}


/* =========================================================
   CUANDO ESTÁ ARRASTRANDO
========================================================= */

.momento-lightbox img.arrastrando {
    cursor: grabbing;

    transition: none;
}


/* =========================================================
   CONTROLES DE ZOOM
========================================================= */

.momento-zoom-controles {
    position: absolute;

    bottom: 25px;
    left: 50%;

    transform:
        translateX(-50%);

    display: flex;

    align-items: center;

    gap: 8px;

    padding: 8px;

    background:
        rgba(0, 0, 0, 0.65);

    border:
        1px solid
        rgba(255, 255, 255, 0.15);

    border-radius: 12px;

    backdrop-filter:
        blur(8px);

    -webkit-backdrop-filter:
        blur(8px);

    z-index: 20;
}


/* =========================================================
   BOTONES ZOOM
========================================================= */

.momento-zoom-btn {
    width: 42px;

    height: 42px;

    display: flex;

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

    border: none;

    border-radius: 8px;

    background:
        rgba(255, 255, 255, 0.12);

    color: #ffffff;

    font-size: 1.2rem;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}


.momento-zoom-btn:hover {
    background:
        var(--color-principal);

    transform:
        scale(1.05);
}


/* =========================================================
   INDICADOR DE ZOOM
========================================================= */

.momento-zoom-valor {
    min-width: 55px;

    color: #ffffff;

    font-size: 0.85rem;

    font-weight: 700;

    text-align: center;
}


/* =========================================================
   BOTÓN CERRAR
========================================================= */

.momento-lightbox-close {
    position: absolute;

    top: 25px;
    right: 30px;

    width: 48px;
    height: 48px;

    display: flex;

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

    border: none;

    border-radius: 50%;

    background:
        var(--color-principal);

    color: #ffffff;

    font-size: 1.5rem;

    cursor: pointer;

    z-index: 30;

    box-shadow:
        0 5px 15px
        rgba(0, 0, 0, 0.30);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}


.momento-lightbox-close:hover {
    transform:
        scale(1.08);

    box-shadow:
        0 8px 22px
        rgba(0, 0, 0, 0.40);
}


/* =========================================================
   CURSOR DE LAS POLAROIDS
========================================================= */

.momento-item {
    cursor: zoom-in;
}


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

@media (max-width: 600px) {

    .momento-lightbox {
        padding: 20px;
    }


    .momento-lightbox img {
        max-width: 94vw;

        max-height: 82vh;
    }


    .momento-lightbox-close {
        top: 15px;

        right: 15px;

        width: 42px;

        height: 42px;

        font-size: 1.25rem;
    }


    .momento-zoom-controles {
        bottom: 15px;

        gap: 5px;

        padding: 6px;
    }


    .momento-zoom-btn {
        width: 40px;

        height: 40px;
    }
}