/* ==================================================
   FOTOALBUM
   ================================================== */

* {
    box-sizing: border-box;
}


html {
    scroll-behavior: smooth;
}


body {
    margin: 0;

    background: #f4f4f4;

    color: #222;

    font-family: Arial, sans-serif;
}


/* ==================================================
   HOOFDGEDEELTE
   ================================================== */

.fotoalbum {

    width: 100%;

    max-width: 1200px;

    margin: 0 auto;

    padding: 20px;

}


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

.album-header {

    text-align: center;

    margin-bottom: 25px;

}


.album-header h1 {

    margin: 5px 0 8px;

    font-size: 32px;

}


.album-header p {

    margin: 0;

    color: #777;

    font-size: 15px;

}


/* ==================================================
   TERUGKNOP
   ================================================== */

.terug-knop {

    display: none;

    border: 0;

    padding: 8px 0;

    background: transparent;

    color: #2675c9;

    font-size: 16px;

    cursor: pointer;

}


.terug-knop:hover {

    text-decoration: underline;

}


/* ==================================================
   ALBUMOVERZICHT
   ================================================== */

.albums {

    display: grid;

    grid-template-columns:
        repeat(auto-fill, minmax(220px, 1fr));

    gap: 20px;

}


/* ==================================================
   ALBUMKAART
   ================================================== */

.album-kaart {

    position: relative;

    overflow: hidden;

    background: #fff;

    border-radius: 10px;

    cursor: pointer;

    box-shadow:
        0 2px 8px rgba(0, 0, 0, .12);

    transition:
        transform .2s,
        box-shadow .2s;

}


.album-kaart:hover {

    transform: translateY(-3px);

    box-shadow:
        0 5px 16px rgba(0, 0, 0, .18);

}


.album-kaart img {

    display: block;

    width: 100%;

    aspect-ratio: 4 / 3;

    object-fit: cover;

}


.album-naam {

    padding: 14px;

    font-size: 18px;

    font-weight: bold;

}


.album-aantal {

    padding: 0 14px 14px;

    color: #777;

    font-size: 14px;

}


/* ==================================================
   FOTOOVERZICHT
   ================================================== */

.foto-overzicht {

    display: grid;

    grid-template-columns:
        repeat(auto-fill, minmax(180px, 1fr));

    gap: 12px;

}


/*
   Dit zijn thumbnails.

   De originele foto's worden hier NIET geladen.
*/

.foto-overzicht figure {

    position: relative;

    margin: 0;

    overflow: hidden;

    background: #ddd;

    border-radius: 8px;

    cursor: pointer;

}


.foto-overzicht img {

    display: block;

    width: 100%;

    aspect-ratio: 4 / 3;

    object-fit: cover;

    transition:
        transform .25s;

}


.foto-overzicht figure:hover img {

    transform: scale(1.04);

}


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

.lightbox {

    position: fixed;

    inset: 0;

    z-index: 9999;

    display: none;

    align-items: center;

    justify-content: center;

    background: rgba(0, 0, 0, .94);

}


.lightbox.actief {

    display: flex;

}


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

.lightbox-inhoud {

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    max-width: calc(100vw - 150px);

    max-height: 95vh;

}


.lightbox-inhoud img {

    display: block;

    max-width: 100%;

    max-height: 85vh;

    width: auto;

    height: auto;

    object-fit: contain;

}


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

.foto-ondertitel {

    padding-top: 10px;

    color: #fff;

    font-size: 15px;

}


/* ==================================================
   SLIDER KNOPPEN
   ================================================== */

.slider-knop,
.sluit-knop {

    position: fixed;

    border: 0;

    background:
        rgba(255, 255, 255, .15);

    color: #fff;

    cursor: pointer;

    display: flex;

    align-items: center;

    justify-content: center;

    transition:
        background .2s;

}


.slider-knop:hover,
.sluit-knop:hover {

    background:
        rgba(255, 255, 255, .3);

}


/* ==================================================
   VORIGE / VOLGENDE
   ================================================== */

.slider-knop {

    top: 50%;

    width: 55px;

    height: 70px;

    margin-top: -35px;

    font-size: 55px;

    line-height: 1;

}


.vorige {

    left: 20px;

}


.volgende {

    right: 20px;

}


/* ==================================================
   SLUITKNOP
   ================================================== */

.sluit-knop {

    top: 15px;

    right: 20px;

    width: 45px;

    height: 45px;

    font-size: 35px;

    line-height: 1;

}


/* ==================================================
   MELDING
   ================================================== */

.melding {

    grid-column: 1 / -1;

    text-align: center;

    padding: 40px 20px;

    color: #777;

}


/* ==================================================
   LADEN
   ================================================== */

.laden {

    grid-column: 1 / -1;

    text-align: center;

    padding: 40px 20px;

    color: #777;

}


/* ==================================================
   SMARTPHONE
   ================================================== */

@media (max-width: 600px) {


    .fotoalbum {

        padding: 12px;

    }


    .album-header h1 {

        font-size: 25px;

    }


    .albums {

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

        gap: 10px;

    }


    .album-naam {

        padding: 10px;

        font-size: 16px;

    }


    .album-aantal {

        padding:
            0 10px 10px;

    }


    .foto-overzicht {

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

        gap: 7px;

    }


    .lightbox-inhoud {

        max-width:
            calc(100vw - 20px);

    }


    .lightbox-inhoud img {

        max-height: 80vh;

    }


    .slider-knop {

        width: 42px;

        height: 55px;

        font-size: 42px;

    }


    .vorige {

        left: 5px;

    }


    .volgende {

        right: 5px;

    }


    .sluit-knop {

        top: 5px;

        right: 5px;

    }

}