/* Estilos de la Galería */
.gallery-container {
    padding: 2rem 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

.gallery-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transition: all 0.4s ease;
    aspect-ratio: 4/3;
    cursor: pointer;
    background: var(--color-blanco);
    padding: 10px;
}

.gallery-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 2rem 1.5rem 1.5rem;
    color: var(--color-blanco);
    transform: translateY(100%);
    transition: transform 0.4s ease;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--color-blanco);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    font-weight: 600;
}

.gallery-overlay p {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
    line-height: 1.4;
}

/* Efecto de marco decorativo */
.gallery-item::before {
    content: '';
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 10px;
    pointer-events: none;
    transition: all 0.4s ease;
    z-index: 1;
}

.gallery-item:hover::before {
    border-color: rgba(255,255,255,0.6);
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

/* Efecto de brillo al pasar el mouse */
.gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.3),
        transparent
    );
    transition: 0.5s;
    z-index: 2;
}

.gallery-item:hover::after {
    left: 100%;
}

/* Modal de la Galería */
.gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    backdrop-filter: blur(5px);
}

.gallery-modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    background: var(--color-blanco);
    border-radius: 15px;
    overflow: hidden;
    transform: scale(0.9);
    transition: transform 0.4s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.gallery-modal.active .modal-content {
    transform: scale(1);
}

.modal-content img {
    width: 100%;
    height: auto;
    max-height: 70vh;
    object-fit: contain;
    display: block;
}

.modal-info {
    padding: 1.5rem;
    background: var(--color-blanco);
}

.modal-info h3 {
    color: var(--color-texto);
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.modal-info p {
    color: var(--color-gris-oscuro);
    margin: 0;
    line-height: 1.6;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    background: rgba(0,0,0,0.5);
    color: var(--color-blanco);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    transition: all 0.3s ease;
    z-index: 1;
    border: 2px solid rgba(255,255,255,0.3);
}

.modal-close:hover {
    background: rgba(0,0,0,0.8);
    transform: rotate(90deg);
}

/* Filtros de la galería */
.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    padding: 0 1rem;
}

.filter-btn {
    padding: 0.8rem 1.5rem;
    border: 2px solid var(--color-mar);
    background: transparent;
    color: var(--color-mar);
    border-radius: 25px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-btn:hover {
    background: var(--color-mar);
    color: var(--color-blanco);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(30,144,255,0.2);
}

.filter-btn.active {
    background: var(--color-mar);
    color: var(--color-blanco);
    box-shadow: 0 4px 10px rgba(30,144,255,0.2);
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1rem;
    }

    .gallery-overlay {
        padding: 1.5rem 1rem 1rem;
    }

    .gallery-overlay h3 {
        font-size: 1.2rem;
    }

    .gallery-overlay p {
        font-size: 0.9rem;
    }

    .modal-content {
        max-width: 95%;
    }

    .modal-info {
        padding: 1rem;
    }

    .modal-info h3 {
        font-size: 1.2rem;
    }

    .modal-close {
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }

    .gallery-filters {
        gap: 0.5rem;
    }

    .filter-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
} 