:root {
    --led-blue: #00f2ff;
    --led-purple: #7000ff;
    --bg-dark: #030005;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
}

.gallery-header {
    padding-top: 160px;
    text-align: center;
    margin-bottom: 60px;
}

.gallery-header h1 {
    font-weight: 900;
    letter-spacing: 12px;
    font-size: clamp(2rem, 8vw, 5rem);
    text-transform: uppercase;
    margin: 0;
}

.gallery-header h1 span {
    color: var(--led-blue);
    text-shadow: 0 0 25px rgba(0, 242, 255, 0.4);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    padding: 0 8% 100px;
    max-width: 1600px;
    margin: 0 auto;
}

.gallery-item {
    position: relative;
    height: 380px;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid var(--glass-border);
    background: var(--glass);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-item img,
.gallery-item video {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.item-bg-blur {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(20px) brightness(0.4);
    transform: scale(1.1);
    opacity: 0.6;
    z-index: 1;
}

.item-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0, 242, 255, 0.1), transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    opacity: 0;
    transition: 0.4s;
    backdrop-filter: blur(4px);
    z-index: 4;
}

.gallery-item:hover {
    transform: translateY(-10px);
    border-color: var(--led-blue);
    box-shadow: 0 20px 40px rgba(0, 242, 255, 0.15);
}

.gallery-item:hover .item-overlay {
    opacity: 1;
}

.gallery-item:hover img,
.gallery-item:hover video {
    transform: scale(1.15);
    filter: brightness(0.6);
}

/* --- LIGHTBOX --- */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(3, 0, 5, 0.98);
    z-index: 3000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 50px;
    backdrop-filter: blur(15px);
}

.lightbox-content {
    max-width: 95%;
    max-height: 85vh;
    border: 1px solid var(--led-blue);
    box-shadow: 0 0 60px rgba(0, 242, 255, 0.2);
    border-radius: 15px;
    overflow: hidden;
    background: black;
    transform: scale(0.9);
    animation: lightboxZoom 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes lightboxZoom {
    to {
        transform: scale(1);
    }
}

.lightbox-content img,
.lightbox-content video {
    display: block;
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

.close-lightbox {
    position: absolute;
    top: 30px;
    right: 40px;
    font-size: 3.5rem;
    color: white;
    cursor: pointer;
    opacity: 0.5;
    transition: 0.3s;
}

.close-lightbox:hover {
    opacity: 1;
    color: var(--led-blue);
    transform: rotate(90deg);
}

/* --- FILTROS --- */
.filter-section {
    padding: 20px 8%;
    max-width: 1400px;
    margin: 0 auto 50px;
}

.filter-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: #888;
    padding: 12px 28px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.4s;
    text-transform: uppercase;
}

.filter-btn:hover {
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.filter-btn.active {
    background: var(--led-blue);
    color: black;
    border-color: var(--led-blue);
    box-shadow: 0 0 25px rgba(0, 242, 255, 0.4);
}

/* --- INFO DE CADA ITEM --- */
.item-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.4) 60%, transparent 100%);
    z-index: 5;
    pointer-events: none;
    transform: translateY(0);
    opacity: 1;
    transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.item-info span {
    font-size: 0.65rem;
    color: var(--led-blue);
    font-weight: 900;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.item-info h3 {
    margin: 8px 0 0;
    font-size: 1.2rem;
    font-weight: 900;
    letter-spacing: 1px;
}

.gallery-item:hover .item-info {
    opacity: 0.8;
}

@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        padding: 0 5% 80px;
        gap: 20px;
    }

    .gallery-item {
        height: 320px;
    }

    .gallery-header h1 {
        letter-spacing: 6px;
    }

    .filter-buttons {
        gap: 10px;
    }

    .filter-btn {
        padding: 10px 18px;
        font-size: 0.7rem;
    }

    .lightbox {
        padding: 20px;
    }
}