#images-section {
    display: flex;
    flex-wrap: wrap;
}
#images-section::after {
    content: '';
    flex-grow: 999999999;
}

div.img-wrapper {
    background-color: rgb(169, 205, 208);
    position: relative;
    margin: 2px;
}
i.gallery-item-i {
    display: block;
}
img.gallery-item {
    position: absolute;
    top: 0;
    width: 100%;
    vertical-align: bottom;
}

#modal-container {
    position: fixed;
    display: table;
    height: 100%;
    width: 100%;
    top: 0;
    left: 0;
    transform: scale(0);
    z-index: 10000;
}

#modal-container.blowup {
    z-index: 10001;
    transform: scale(1);
}

#modal-container.blowup .modal-background {
    background: rgba(0, 0, 0, 0.7);
}

#modal-container.blowup .modal-background .modal {
    animation: blowUpModal 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

#modal-container .modal-background {
    display: table-cell;
    background: rgba(0, 0, 0, 0.8);
    text-align: center;
    vertical-align: middle;
}

#modal-container .modal-background .modal {
    background-position: center;
    background-repeat: no-repeat;
    background-size: 50px;
    padding: 5px;
    margin: 5px;
    display: flex;
    display: -webkit-flex;
    vertical-align: middle;
    align-items: center;
    font-weight: 300;
    max-height: 70%;
    max-width: 80%;
    position: absolute;
    top: 15%;
    left: 10%;
    bottom: 15%;
    right: 10%;
    margin: auto;
}

#modal-container .modal-background .modal .modal-img-wrapper {
    display: contents;
}

#modal-container .modal-background .modal .modal-svg {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    border-radius: 3px;
}

@keyframes blowUpModal {
    0% {
        transform: scale(0);
    }
    100% {
        transform: scale(1);
    }
}

.modal-close-button {
    color: #fff;
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 5px 11px;
    background: rgba(207, 47, 47, 0.7);
    cursor: pointer;
    z-index: 10005;
    border-radius: 25px;
    font-weight: bold;
    transition: 0.2s ease;
}

.modal-close-button:hover {
    background: rgb(207, 47, 47);
}

.modal-close-button span {
    display: block;
    transform: rotate(45deg) !important;
    font-size: 1.5rem;
    font-weight: bold;
}

img.modal-img {
    max-width: 100%;
    max-height: 100%;
    border: 5px solid #fff;
    margin: auto;
    background-color: #fff;
}

.hover-pointer {
    cursor: pointer;
}

.modal-prev-button, .modal-next-button {
    cursor: pointer;
    position: absolute;
    width: auto;
    padding: 11px 20px;
    color: #fff;
    font-weight: bold;
    font-size: 50px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
    background-color: rgba(0, 0, 0, 0.2);
    top: 50%;
    transform: translateY(-50%);
    z-index: 10004;
}

.modal-next-button {
    right: 15px;
    border-radius: 3px 0 0 3px;
}

.modal-prev-button {
    left: 15px;
    border-radius: 3px 0 0 3px;
}

.modal-prev-button:hover, .modal-next-button:hover {
    background-color: rgba(0, 0, 0, 0.8);
}
