/* =====================================================
   Sicily Terrace & Wine - Gallery Page Styles
   ===================================================== */

.gallery-page {
    padding: 60px 0 80px;
}

/* ===== Filters ===== */
.gallery-page__filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 40px;
}

.gallery-page__filter {
    padding: 10px 20px;
    background-color: var(--color-gray-100);
    border-radius: var(--radius-full);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-gray-700);
    transition: all var(--transition);
}

    .gallery-page__filter:hover {
        background-color: var(--color-gray-200);
    }

.gallery-page__filter--active {
    background-color: var(--color-primary);
    color: var(--color-white);
}

/* ===== Grid ===== */
.gallery-page__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

@media (min-width: 640px) {
    .gallery-page__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

@media (min-width: 1024px) {
    .gallery-page__grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.gallery-page__item {
    position: relative;
    aspect-ratio: 1;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
}

.gallery-page__media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.gallery-page__item:hover .gallery-page__media {
    transform: scale(1.1);
}

.gallery-page__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(30, 90, 142, 0.9) 0%, transparent 50%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px;
    opacity: 0;
    transition: opacity var(--transition);
}

.gallery-page__item:hover .gallery-page__overlay {
    opacity: 1;
}

.gallery-page__title {
    font-family: var(--font-heading);
    font-size: 16px;
    color: var(--color-white);
    margin-bottom: 4px;
}

.gallery-page__category {
    font-size: 12px;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.gallery-page__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    color: var(--color-primary);
    font-size: 20px;
    transition: all var(--transition);
}

.gallery-page__item:hover .gallery-page__play {
    background-color: var(--color-secondary);
    transform: translate(-50%, -50%) scale(1.1);
}

/* ===== Empty State ===== */
.gallery-page__empty {
    text-align: center;
    padding: 80px 24px;
}

    .gallery-page__empty i {
        font-size: 60px;
        color: var(--color-gray-300);
        margin-bottom: 24px;
    }

    .gallery-page__empty h3 {
        font-size: 24px;
        margin-bottom: 8px;
    }

    .gallery-page__empty p {
        color: var(--color-gray-600);
    }

/* =====================================================
   Lightbox Styles
   ===================================================== */

.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

    .lightbox.active {
        opacity: 1;
        visibility: visible;
    }

.lightbox__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.9);
}

.lightbox__container {
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox__content {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox__image {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox__video {
    max-width: 90vw;
    max-height: 80vh;
    border-radius: 8px;
    outline: none;
    display: none;
}

.lightbox__caption {
    margin-top: 16px;
    color: var(--color-white);
    font-family: var(--font-heading);
    font-size: 18px;
    text-align: center;
}

.lightbox__close {
    position: absolute;
    top: -50px;
    right: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: var(--color-white);
    font-size: 20px;
    cursor: pointer;
    transition: all var(--transition);
}

    .lightbox__close:hover {
        background-color: rgba(255, 255, 255, 0.2);
        transform: rotate(90deg);
    }

.lightbox__prev,
.lightbox__next {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: var(--color-white);
    font-size: 20px;
    cursor: pointer;
    transition: all var(--transition);
    z-index: 10;
}

.lightbox__prev {
    left: 20px;
}

.lightbox__next {
    right: 20px;
}

    .lightbox__prev:hover,
    .lightbox__next:hover {
        background-color: var(--color-secondary);
    }

/* Mobile adjustments */
@media (max-width: 768px) {
    .lightbox__prev,
    .lightbox__next {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .lightbox__prev {
        left: 10px;
    }

    .lightbox__next {
        right: 10px;
    }

    .lightbox__close {
        top: -40px;
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .lightbox__caption {
        font-size: 14px;
        padding: 0 20px;
    }
}

/* No scroll when lightbox is open */
body.no-scroll {
    overflow: hidden;
}
