.galerie {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.3em;
    justify-content: flex-start;
    align-content: flex-start;

    & h1,h2,h3,h4,h5 {
        flex-basis: 100%;
    }
    & a {
        text-decoration: none;
        display: block;
        max-width: 30%;
        &:focus {
            outline: 2px solid black;
        }
        & img {
            height: min(25vw,10em);
            display: block;
            max-width: 100%;
        }
    }
}

.row{
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.thumbnail_images{
    width: 90%;
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    gap: 0.5rem;
    margin: auto;
    overflow: scroll;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}
.thumbnail{
    max-height: 5em;
    max-width: 5em;
}
.column{
    position: relative;
}

#modalView{
    margin: auto;
    padding: 0.2em;
    width:100%;
    height:100%;
    background-color: var(--color-bg-body);
    border: 0;
}

#modalContent{
    height: 75%;
    width: 100%;
    position: relative;
}

#modalContent > button{
    --button-height: 3rem;
    position: absolute;
    top: calc(50% - var(--button-height)/2);
    height: var(--button-height);
    border: 0;
    background: transparent;
    font-weight: bold;
    cursor: pointer;
    font-size: 3rem;
    color: var(--color-body);
}
#closeButton{
    position: absolute;
    top: 0.5rem;
    right:0.5rem;
    background: red;
    opacity: 0.9;
    border: 0;
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: 0.3rem;
}
#closeButton:hover{
    color: white;
    box-shadow: 2px 2px #00000060;
}
#modalContent > button:hover{
    color: gray;
    background: transparent;
    border-radius: 0.5rem;
}
#modalContent .leftButton{
    left:0;
}
#modalContent .rightButton{
    right:0;
}

#modalContent .imageWrapper{
    display: flex;
    text-align: center;
    height: 100%;
    justify-content: center;
    align-content: center;
}

#modalContent img{
    max-width: 100%;
    max-height: 100%;
    align-self: center;
}

@media all and (min-width: 50em) {
    #modalContent img{
        width: auto;
    }
}

#imageList {
    margin: 0;
    padding-top: 1em;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 1rem;
    overflow-x: scroll;
    height: 20%;
    width: 100%;
}

#imageList .active{
    opacity: 0.5;
}

#modalView::backdrop {
    background: var(--color-bg-body);
}

.visually-hidden {
    position: absolute !important;
    clip: rect(1px, 1px, 1px, 1px) !important;
    padding: 0 !important;
    border: 0 !important;
    height: 1px !important;
    width: 1px !important;
    overflow: hidden !important;
    white-space: nowrap !important;
}
