/* gallery.css */
.gallery-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    max-width: 70%; /* Narrower than full viewport */
    margin: 0 auto;
    padding-bottom: 40px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border-radius: 10px;
}

.gallery-item img {
    width: 100%;
    height: auto;
    transition: opacity 0.3s ease;
    border-radius: 10px;
}

.gallery-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5); /* Semi-transparent black */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item .overlay .description {
    color: white;
    font-size: 20px;
}
.gallery-item:hover .overlay {
    opacity: 1;
}

.gallery-item:hover img {
    opacity: 0.5;
}

.description {
    padding: 0 20px;
}


/* gallery.css */
.gallery-title-container {
    text-align: center;
    margin-bottom: 20px; /* Adds space between title and gallery */
}

.gallery-title {
    font-size: 2rem; /* Adjust size as needed */
    font-weight: bold;
    color: #333; /* Dark gray color for the title */
}


/* Modal Styles */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 2;
    left: 0;
    top: 50;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7); /* Semi-transparent black background */
    justify-content: center;
    align-items: center;
    z-index: 1000; /* Make sure the modal is on top */
}

.modal-content {
    max-width: 65%;
    position: relative;
    margin: auto;
    display: flex;
}

.modal-description {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    background: rgba(0, 0, 0, 0.5);
    padding: 10px;
    max-width: 50%;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    display: block;
}


.modal.active .modal-description {
    opacity: 1;
}

.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #ff66b2;
    text-decoration: none;
    cursor: pointer;
}


/* Style the navigation buttons */
button.prev, button.next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px;
    font-size: 30px;
    cursor: pointer;
    z-index: 10;
    border-radius: 50%;
}

/* Position the 'Previous' button on the left side */
button.prev {
    left: 20px;
}

/* Position the 'Next' button on the right side */
button.next {
    right: 20px;
}

/* Hover effect for the buttons */
button.prev:hover, button.next:hover {
    background-color: rgba(0, 0, 0, 0.7);
}
