/* =====================================================
   Flavor Studio Portfolio - Lightbox Styles
   ===================================================== */

/* Lightbox Overlay */
.fsp-lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(10, 10, 20, 0.95);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}

.fsp-lightbox-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Lightbox Content */
.fsp-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fsp-lightbox-image-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fsp-lightbox-image {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.fsp-lightbox-image.loading {
    opacity: 0.3;
    transform: scale(0.95);
}

/* Loading spinner */
.fsp-lightbox-loader {
    position: absolute;
    width: 40px;
    height: 40px;
    border: 3px solid rgba(201, 169, 110, 0.2);
    border-top-color: #c9a96e;
    border-radius: 50%;
    animation: fsp-lb-spin 0.7s linear infinite;
    display: none;
}

.fsp-lightbox-loader.active {
    display: block;
}

@keyframes fsp-lb-spin {
    to { transform: rotate(360deg); }
}

/* Close Button */
.fsp-lightbox-close {
    position: fixed;
    top: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    border: none;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px);
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s ease;
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.fsp-lightbox-close:hover {
    background: rgba(201, 169, 110, 0.9);
    color: #1a1a2e;
    transform: rotate(90deg);
}

/* Navigation Arrows */
.fsp-lightbox-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    border: none;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(8px);
    border-radius: 50%;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s ease;
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.fsp-lightbox-nav:hover {
    background: rgba(201, 169, 110, 0.15);
    border-color: rgba(201, 169, 110, 0.3);
}

.fsp-lightbox-prev {
    left: 24px;
}

.fsp-lightbox-next {
    right: 24px;
}

.fsp-lightbox-nav:disabled {
    opacity: 0.2;
    cursor: default;
}

/* Counter */
.fsp-lightbox-counter {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(8px);
    border-radius: 24px;
    color: rgba(255, 255, 255, 0.7);
    font-family: 'DM Sans', 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.fsp-lightbox-counter-current {
    color: #c9a96e;
    font-weight: 700;
}

/* Title */
.fsp-lightbox-title {
    position: fixed;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    text-align: center;
    max-width: 60vw;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Thumbnail strip */
.fsp-lightbox-thumbnails {
    position: fixed;
    bottom: 70px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(8px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    max-width: 80vw;
    overflow-x: auto;
    scrollbar-width: none;
}

.fsp-lightbox-thumbnails::-webkit-scrollbar {
    display: none;
}

.fsp-lightbox-thumb {
    width: 56px;
    height: 42px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.4;
    transition: 0.25s ease;
    flex-shrink: 0;
    border: 2px solid transparent;
}

.fsp-lightbox-thumb.active {
    opacity: 1;
    border-color: #c9a96e;
}

.fsp-lightbox-thumb:hover {
    opacity: 0.8;
}

.fsp-lightbox-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Mobile */
@media (max-width: 768px) {
    .fsp-lightbox-nav {
        width: 40px;
        height: 40px;
    }

    .fsp-lightbox-prev { left: 12px; }
    .fsp-lightbox-next { right: 12px; }
    .fsp-lightbox-close { top: 12px; right: 12px; }

    .fsp-lightbox-title {
        font-size: 14px;
        top: 16px;
    }

    .fsp-lightbox-thumbnails {
        display: none;
    }

    .fsp-lightbox-image {
        max-width: 95vw;
        max-height: 80vh;
    }
}
