/* =========================================================
   GALLERY SECTION
   ========================================================= */
.gallery-section {
    padding: 80px 0;
    background: #fff;
    text-align: center;
}

.gallery-section h2 {
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: #333;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 40px;
}

.gallery-item {
    aspect-ratio: 3/2;
    background: linear-gradient(45deg, #dbeafe, #bfdbf7);
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    cursor: pointer;
}

.gallery-item:hover {
    transform: scale(1.05);
}

.gallery-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.3s;
}

.gallery-thumbnail:hover {
    opacity: 0.8;
}

/* Modal styling */
.gallery-modal {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    padding-top: 100px; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgb(0,0,0); 
    background-color: rgba(0,0,0,0.9); 
}

.gallery-modal-content {
    margin: auto;
    display: block;
    max-width: 80%;
    max-height: 80vh;
    object-fit: contain;
    animation-name: zoom;
    animation-duration: 0.6s;
}

@keyframes zoom {
    from {transform:scale(0)} 
    to {transform:scale(1)}
}

#gallery-modal-caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
}

.gallery-modal-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
}

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

/* Media Queries - Gallery */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .gallery-section h2 {
        font-size: 1.5rem;
    }
    
    .gallery-modal-content {
        max-width: 95%;
    }
}
