/* 

gallery.css
Custom styles for the gallery page

Author: Luke Wulf
Date: August 16, 2024

*/

body {
    overflow-x: hidden;
}

.images-wrapper {
    line-height: 0;
    -webkit-column-count: 5;
    -webkit-column-gap: 0px;
    -moz-column-count: 5;
    -moz-column-gap: 0px;
    column-count: 5;
    column-gap: 0px;
    /* column-gap: 5px; */
}

@media (max-width: 1000px){
    .images-wrapper {
        -webkit-column-count: 4;
        -moz-column-count: 4;
        column-count: 4;
    }
}

@media (max-width: 800px){
    .images-wrapper {
        -webkit-column-count: 3;
        -moz-column-count: 3;
        column-count: 3;
    }
}

@media (max-width: 600px){
    .images-wrapper {
        -webkit-column-count: 2;
        -moz-column-count: 2;
        column-count: 2;
    }
}



.images-wrapper {
    display: inline-block;
    margin-left: auto;
    margin-right: auto;
}

.image-container {
    display: inline-block;
    position: relative;
    overflow: hidden;
}

.image-container img {
    width: 100%;
    height: auto;
    transition: transform 0.4s ease, filter 0.4s ease;
}

.image-container p {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); 
    width: 90%; 
    height: auto; 
    color: rgba(243, 243, 243, 0);
    font-size: 1.3rem;
    font-weight: 600;
    z-index: 2;
    text-align: center;
    padding: 10px;
    transition: color 0.4s;
    white-space: normal; 
    word-wrap: break-word;
    line-height: 1.5;
}

.image-container:hover {
    z-index: 2;
}

.image-container:hover img {
    transform: scale(1.1);
    filter: brightness(0.5);
}

.image-container:hover p {
    cursor: pointer;
    color: rgba(243, 243, 243, 1); 
}

header h1 {
    text-align: center;
    font-weight: 900;
    font-size: 3rem;
    color: var(--color-primary);
    margin: 100px 20px 20px 20px;
}

header hr {
    border: 2px solid var(--color-secondary-light);
    width: 50%;
    max-width: 400px;
    margin: 20px auto 40px auto;
}

/* back to top button */
#back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: none;
    background-color: var(--color-primary);
    color: var(--color-text);
    border: none;
    border-radius: 5px;
    padding: 10px 15px;
    font-size: 25px;
    cursor: pointer;
    z-index: 1000; 
    transition: background-color 0.4s;
}

#back-to-top:hover {
    background-color: var(--color-primary-dark);
}

/* Spinner styling */
#loading-spinner {
    position: fixed;
    width: 100%;
    height: 100%;
    background-color: rgb(26, 26, 26, 0.8);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spinner {
    border: 8px solid rgba(0, 0, 0, 0.1);
    border-top: 8px solid var(--color-primary); /* Color of the spinner */
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

