:root {
    --yellow: #FBBE00;
    --blue: #005D99;
}

*,
img {
    -webkit-user-drag: none;
    /* Chrome, Safari, Opera */
    -moz-user-drag: none;
    /* Firefox */
    -ms-user-drag: none;
    /* IE/Edge */
    /* estándar */
    user-select: none;
    /* evitar selección de texto */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.floating-image {
    position: fixed;
    bottom: 3rem;
    right: 2rem;
    width: 100px;
    height: auto;
    z-index: 900;
    cursor: pointer;
    filter: drop-shadow(0 0 1px #004979);
}

.title {
    display: flex;
    justify-content: center;
    padding: 3rem 5rem;
}

.title h1 {
    font-size: 40px;
    color: var(--yellow);
    margin-right: 10px;
    font-weight: 600;
    font-style: italic;
    overflow: hidden;
}

.title h2 {
    font-size: 40px;
    font-weight: 600;
    font-style: italic;
    color: var(--blue);
    overflow: hidden;
}

.grid-container {
    padding: 0 5rem;
    display: flex;
    gap: 10px;
    width: 100%;
}

.grid-container.grid-3-cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 0 5rem;
}

.grid-container.grid-2-cols {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 0 5rem;
}

.grid-container.grid-4-cols {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.col {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 10px;
}

.box {
    background-color: #d4d4d4;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    cursor: zoom-in;
}

.tall {
    height: 45vh;
}

.short {
    height: 30vh;
}

.full {
    height: 60vh;
}

.square {
    width: 100%;
    padding-bottom: 100%;
    position: relative;
}

.square>* {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

/* Lightbox CSS */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(8, 41, 90, 0.2);
    z-index: 10000;
}

.lightbox-toggle:checked+label+.lightbox {
    display: flex;
}

.lightbox-close {
    position: absolute;
    width: 100%;
    height: 100%;
    cursor: zoom-out;
}

/* Responsive */
@media (max-width: 768px) {
    .floating-image {
        bottom: 1.5rem;
        right: 1rem;
    }

    .title {
        padding: 0 2rem;
    }

    .title h1,
    .title h2 {
        font-size: 34px;
    }

    .grid-container {
        margin-top: 0;
        padding: 1rem 2rem 0 2rem;
        flex-direction: column;
    }

    .grid-container.grid-3-cols {
        grid-template-columns: repeat(2, 1fr);
        /* De 3 a 2 columnas */
        padding: 0rem 2rem 0 2rem;
    }

    .grid-container.grid-2-cols {
        grid-template-columns: repeat(2, 1fr);
        /* Dos columnas también en móviles */
        padding: 0rem 2rem 0 2rem;
    }

    .grid-container.grid-4-cols {
        grid-template-columns: repeat(2, 1fr);
        /* Dos columnas en móviles */
        padding: 0em 2rem 0 2rem;
    }

    .square {
        padding-bottom: 0;
        /* Cancelar proporción cuadrada */
        height: 200px;
        /* Altura fija para móviles */
        position: static;
    }

    .square>* {
        position: static;
        /* Ya no es necesario posicionamiento absoluto */
        width: 100%;
        height: 100%;
    }

    .col {
        flex-direction: row;
    }

    .tall,
    .short,
    .full {
        height: 200px;
        flex: 1;
    }
}