/* Gallery Widget Styles */
.gallery-widget {
    max-width: 100%; /* Full width of the device */
    margin: 0 auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.gallery-widget h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Responsive grid */
    gap: 10px;
}

.gallery-grid img {
    width: 100%; /* Full width of the grid cell */
    height: auto; /* Maintain aspect ratio */
    object-fit: cover; /* Ensure images cover the area without distortion */
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-grid img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Lightbox Modal */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.lightbox img {
    max-width: 90%; /* Limit lightbox image size */
    max-height: 90%; /* Limit lightbox image size */
    border-radius: 10px;
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
}