.intern-entry {
  	position: relative;
    margin-bottom: 20px;
    overflow: hidden;
  	width: 25%;
}

.intern-wrap {
    padding-right: 20px;
}

.intern-entry:nth-child(4n) .intern-wrap {
    padding-right: 0;
}

.intern-thumbnail {
    position: relative;
    cursor: pointer;
}

.intern-image {
    position: relative;
    height: 400px;
    width: 100%;
}

.intern-image img {
    object-fit: cover;
    object-position: center;
    height: 100%;
    width: 100%;
}

.intern-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, .7);
    opacity: 0;
    transition: opacity 0.3s, visibility 0s linear 0.3s;
    display: flex;
/*    align-items: center;
    justify-content: center;
    text-align: center;*/
    overflow-y: auto;
}

.intern-bio {
    color: #fff;
    display: none;
    font-size: 14px;
    line-height: 1.75;
    opacity: 0;
    padding: 20px; /* Add padding to create space around the text */
    transition: opacity 0.3s;
    max-height: 100%; /* Allow the content to expand but not exceed the overlay */
    overflow-y: auto; /* Enable scrolling when content exceeds the overlay height */
}

.intern-thumbnail:hover .intern-bio {
    opacity: 1;
    display: block;
}

.intern-thumbnail:hover .intern-overlay {
    opacity: 1;
    visibility: visible;
    transition-delay: 0s;
}

.intern-thumbnail:hover .intern-bio {
    display: block;
}
.intern-flex {
    display: flex;
    flex-flow: row wrap;
}
.intern-name {
    position: absolute;
    bottom: 0;
    background: rgba(0, 0, 0, .7);
    width: 100%;
    color: white;
    text-align: center;
    text-transform: uppercase;
    transition: opacity 0.3s, visibility 0s linear 0.3s;
}
.intern-entry:hover .intern-name {
    display: none;
    opacity: 0;
}
.intern-title {
    padding: 20px;
    font-size: 20px;
    font-weight: 500;
    text-transform: uppercase;
    line-height: 1.25em;
}

/* Responsive Styling */
@media (max-width: 1199px) {

    .intern-entry {
        width: 33.333333%;
    }
    .intern-entry:nth-child(3n) .intern-wrap {
        padding-right: 0;
    }
    .intern-entry:nth-child(4n) .intern-wrap {
        padding-right: 20px;
    }
}

@media (max-width: 991px) {

    .intern-entry {
        width: 50%;
    }
    .intern-wrap {
        padding-right: 20px !important;
    }
    .intern-entry:nth-child(2n) .intern-wrap {
        padding-right: 0 !important;
    }
    .intern-title {
        font-size: 15px;
    }

}

@media (max-width: 640px) {

    .intern-entry {
        width: 100%;
    }
    .intern-wrap {
        padding-right: 0 !important;
    }
    .intern-image {
        height: 600px;
    }

}

@media (max-width: 480px) {

    .intern-image {
        height: 450px;
    }

}

@media (max-width: 340px) {

    .intern-image {
        height: 350px;
    }

}





