/* Featured Style Gallery - Frontend Styles */

.fsg-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    padding: 40px 0;
}

.fsg-gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    background: #fff;
}

.fsg-gallery-item:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.fsg-gallery-item-inner {
    position: relative;
    overflow: hidden;
}

.fsg-gallery-item-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fsg-gallery-item:hover img {
    transform: scale(1.2) rotate(2deg);
}

.fsg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgb(237 232 226), rgb(176 176 176 / 90%));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.fsg-gallery-item:hover .fsg-overlay {
    opacity: 1;
}

.fsg-overlay-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.fsg-zoom-icon {
    color: #fff;
    transform: scale(0.5);
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.fsg-gallery-item:hover .fsg-zoom-icon {
    transform: scale(1);
}

.fsg-view-text {
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s ease 0.1s;
}

.fsg-gallery-item:hover .fsg-view-text {
    opacity: 1;
    transform: translateY(0);
}

.fsg-item-title {
    padding: 20px;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    color: #1d2327;
    line-height: 1.5;
    background: #fff;
    min-height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fsg-item-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    position: relative;
}

.fsg-item-title a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.fsg-item-title a:hover {
    color: #667eea;
}

.fsg-item-title a:hover::after {
    width: 100%;
}

.fsg-external-icon {
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.fsg-item-title a:hover .fsg-external-icon {
    opacity: 1;
}

.fsg-empty-message {
    text-align: center;
    padding: 80px 20px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 16px;
    color: #646970;
}

/* Lightbox Styles */
.fsg-lightbox-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    animation: fsgFadeIn 0.3s ease;
    backdrop-filter: blur(10px);
}

.fsg-lightbox-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.fsg-lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    animation: fsgZoomIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.fsg-lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

#fsg-lightbox-caption {
    text-align: center;
    color: #fff;
    padding: 20px;
    font-size: 20px;
    font-weight: 600;
    margin-top: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.fsg-lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000000;
    backdrop-filter: blur(10px);
}

.fsg-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.fsg-lightbox-prev,
.fsg-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: none;
    width: 60px;
    height: 60px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.fsg-lightbox-prev:hover,
.fsg-lightbox-next:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.1);
}

.fsg-lightbox-prev {
    left: 30px;
}

.fsg-lightbox-next {
    right: 30px;
}

.fsg-lightbox-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    backdrop-filter: blur(10px);
}

@keyframes fsgFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fsgZoomIn {
    from { 
        transform: scale(0.5);
        opacity: 0;
    }
    to { 
        transform: scale(1);
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 1024px) {
    .fsg-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .fsg-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
        padding: 20px 0;
    }
    
    .fsg-item-title {
        font-size: 16px;
        padding: 15px;
        min-height: 60px;
    }
    
    .fsg-lightbox-prev,
    .fsg-lightbox-next {
        width: 45px;
        height: 45px;
    }
    
    .fsg-lightbox-prev {
        left: 15px;
    }
    
    .fsg-lightbox-next {
        right: 15px;
    }
    
    .fsg-lightbox-close {
        top: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
    }
    
    #fsg-lightbox-caption {
        font-size: 16px;
        padding: 15px;
    }
    
    .fsg-lightbox-counter {
        bottom: 15px;
        font-size: 12px;
        padding: 8px 16px;
    }
}

@media (max-width: 480px) {
    .fsg-gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .fsg-lightbox-content {
        max-width: 95%;
    }
}