.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
    padding: 0;
    width: 100%;
    max-width: 100%;
    margin: 0;
}

/* Responsive para tablets */
@media (max-width: 1024px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 15px;
    }
}

/* Responsive para móviles */
@media (max-width: 768px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 10px;
        padding: 15px;
    }
}

/* Móviles pequeños - ocupar todo el ancho */
@media (max-width: 480px) {
    .gallery-container {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 10px;
        width: 100%;
    }
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    aspect-ratio: 200 / 135;
    transition: transform 0.3s ease;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05) rotate(1.5deg);
    filter: brightness(0.85);
}

/* Lightbox styles */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    transform: scale(0.5);
    transition: transform 0.3s ease;
}

.lightbox.active img {
    transform: scale(1);
}

.close-lightbox {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 30px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 10px;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
    transition: background-color 0.3s ease;
}

.lightbox-nav:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.lightbox-nav.prev {
    left: 10px;
}

.lightbox-nav.next {
    right: 10px;
}