.video {
    padding: 3rem;
}

.contact-logo {
    text-decoration: none;
    color: white;
    height: 1.5rem;
    width: auto;
    opacity: 0.5;
    transition: opacity 0.3s;
    filter: grayscale(100%);
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    -webkit-filter: grayscale(100%);
    text-decoration: none;
}

.contact-logo:hover {
    filter: blur(1px) grayscale(100%);
    opacity: 0.8;
}

/* ========================================= About page ========================================= */
.bio-container {
    background-repeat: no-repeat;
    background-size: 10rem auto;
    max-width: 100%;
    margin: 0 auto;
    padding-top: 3rem;
    display: flex;
    /* Enables flexbox */
    align-items: center;
    /* Vertically centers content */
    justify-content: space-between;
    /* Pushes children to edges */
    gap: 2rem;
    /* Adds space between the image and text */
    padding: 2rem;
    position: relative;
    text-align: center;
}

.bio-text {
    margin-bottom: 2rem;
    z-index: 2;
    /* Ensure text stays above the images */
    position: relative;
    max-width: 25rem;
    /* Limit image width */
    text-align: justify;
    text-decoration: none;
    /* Adds space between the text and the image */

}

.bio-text a {
    text-decoration: none;
    color: #888;
    transition: color 0.3s ease;
}

.bio-text a:hover {
    background: linear-gradient(45deg, #1ca591, #fff, #1ca591);
    background-size: 200%;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientHover 2s infinite linear;
}

.bio-text h2,
.bio-text p {
    font-family: 'Crimson Text', serif;
    line-height: 1.8;
    color: #777;
}

.bio-text h2 {
    font-size: 1rem;
    color: #ccc;
}

.bio-text p {
    font-size: 0.75rem;
    color: #888;
}

@keyframes gradientHover {
    0% {
        background-position: 0%;
    }

    100% {
        background-position: 100%;
    }
}

/* Image container for random positions */
.image-container {
    position: relative;
    width: 100%;
    height: 70vh;
    /* Set height for random positioning */
    overflow: hidden;
    z-index: 1;
}

/* Individual images */
.image {
    position: absolute;
    /* Allow placement anywhere within the container */
    width: 150px;
    height: 150px;
    background-size: cover;
    background-position: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease, top 0.3s ease, left 0.3s ease;
    cursor: pointer;
    z-index: 1;
    filter: grayscale(100%);
    /* top: random(0vw, 50vw, 5vw); left: random(0vw, 50vw, 5vw);  */
}

/* Dim other images */
.image:hover~.image {
    opacity: 0.25;
    /* Dim non-hovered images */
}

.gif-image {
    position: relative;
    width: 25vw;
    height: auto;
    background-size: cover;
    background-position: center;
    cursor: pointer;
    z-index: 1;
}

/* Full-size pop-up styling */
.popup-image {
    position: fixed;
    background-size: contain;
    /* Maintain aspect ratio */
    background-repeat: no-repeat;
    background-position: center;
    z-index: 999;
    pointer-events: none;
    /* Disable pointer interactions */
}

.bio-image {
    flex: 0 0 auto;
    margin-left: 1vw;
    /* Ensures the image stays its natural size */
    max-width: 300px;
    /* Limit image width */
    /* Rounded corners */
    filter: grayscale(100%);
    opacity: 0.8;
    transition: filter 0.3s ease, box-shadow 0.3s ease;
}

.bio-image:hover {
    animation: grayscaleTransition 1s infinite alternate;
    box-shadow: -0.25rem 0.25rem 0.5rem 0.05rem #1ca591;
}

@keyframes grayscaleTransition {
    from {
        filter: grayscale(100%);
    }

    to {
        filter: grayscale(25%);
    }
}

/* Footer section design */

/* ========================================= Thumbnail Styling ========================================= */
.thumbnail-container {
    font-family: "Crimson Text", serif;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding: 3rem;
    max-width: 800px;
    margin: 0 auto;
}

.thumbnail {
    display: flex;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.thumbnail:hover {
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.15);
}

.thumbnail img {
    width: 300px;
    height: 150px;
    object-fit: cover;
}

.thumbnail-content {
    padding-left: 3rem;
    flex: 1;
}

.thumbnail-header {
    font-style: italic;
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: #ddd;
    text-decoration: none;
}

.thumbnail-description {
    font-size: 0.75rem;
    color: #666;
}

/* ========================================= Masonry Grid Styling ========================================= */
.masonry {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    /* 3 equal-width columns */
    padding: 1rem;
}

/* Individual Item Styling */
.item img {
    display: block;
    width: 100%;
    height: 20rem;
    object-fit: cover;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.item img:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Lightbox Overlay Styling */
.lightbox-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.lightbox-overlay img {
    max-width: 90%;
    max-height: 90%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

/* ========================================= Other small items ========================================= */
/* Button Styling */
.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2rem;
    color: white;
    cursor: pointer;
    z-index: 1001;
    transition: opacity 0.3s;
}

.close-btn:hover {
    opacity: 0.7;
}

/* Loader Styling */
.loader-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.loader-container.hidden {
    opacity: 0;
    visibility: hidden;
}

/* Adjust size of the GIF */
.loader-container img {
    width: 10rem;
    height: auto;
}

#sketch-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    left: 0;
}

@media screen and (min-width: 666px) and (max-width:880px) {
    .masonry {
        grid-template-columns: repeat(2, 1fr);
    }

    .bio-container {
        flex-direction: column;
        padding: 2rem;
    }

    .bio-text {
        max-width: 100%;
        padding: 0;
    }

    .image {
        width: 120px;
        height: 120px;
    }

    .thumbnail {
        padding-bottom: 3rem;
    }

    .thumbnail img {
        width: 200px;
        height: 100px;
    }

    .thumbnail-content {
        padding-left: 1.5rem;
    }


}

@media screen and (max-width: 666px) {
    .masonry {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .bio-container {
        flex-direction: column;
        padding: 1rem;
    }

    .bio-text {
        font-size: 0.8rem;
    }


    .image {
        width: 100px;
        height: 100px;
    }

    .thumbnail {
        flex-direction: column;
        align-items: center;
        padding-bottom: 2rem;
    }

    .thumbnail img {
        width: 100%;
        height: auto;
    }

    .thumbnail-content {
        padding-left: 0;
        text-align: center;
    }

}

.fb-video {
    float: right;
    height: auto;
}

.recit-image {
    height: 35vh;
    width: auto;
}

@media screen and (max-width: 600px) {
    .fb-video {
        float: none;
        width: 100vw;
        margin-left: 0;
    }

    .recit-image {
        height: auto;
        width: 100vw;
    }
}