/**
 * 관리자 갤러리 스타일
 * 제품 상세 보기 모달의 이미지 갤러리 UI
 */

/* 갤러리 컨테이너 */
.admin-image-gallery {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
}

.gallery-main-container {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    background-color: #fff;
    border: 1px solid #dee2e6;
}

.main-image-wrapper {
    width: 100%;
    aspect-ratio: 16/10;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
}

.main-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    cursor: pointer;
}

/* 갤러리 네비게이션 버튼 */
.gallery-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    z-index: 10;
}

.gallery-nav-prev {
    left: 12px;
}

.gallery-nav-next {
    right: 12px;
}

.gallery-nav-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.1);
}

.gallery-nav-btn:active {
    transform: translateY(-50%) scale(0.95);
}

/* 이미지 카운터 */
.image-counter-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* 썸네일 갤러리 */
.gallery-thumbnails-wrapper {
    border-top: 1px solid #dee2e6;
    padding-top: 12px;
}

.gallery-thumbnails-scroll {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 5px 0;
}

.gallery-thumbnails-scroll::-webkit-scrollbar {
    height: 6px;
}

.gallery-thumbnails-scroll::-webkit-scrollbar-track {
    background: #e9ecef;
    border-radius: 10px;
}

.gallery-thumbnails-scroll::-webkit-scrollbar-thumb {
    background: #adb5bd;
    border-radius: 10px;
}

.gallery-thumbnails-scroll::-webkit-scrollbar-thumb:hover {
    background: #6c757d;
}

.gallery-thumbnail-item {
    position: relative;
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 4px;
    overflow: hidden;
    border: 2px solid #dee2e6;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: #fff;
}

.gallery-thumbnail-item:hover {
    border-color: #0d6efd;
    transform: scale(1.08);
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.2);
}

.gallery-thumbnail-item.active {
    border-color: #0d6efd;
    box-shadow: 0 0 8px rgba(13, 110, 253, 0.4);
}

.thumbnail-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-indicator {
    position: absolute;
    top: 3px;
    right: 3px;
    background-color: #ffc107;
    color: white;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* 반응형 */
@media (max-width: 768px) {
    .gallery-main-container {
        border-radius: 4px;
    }

    .main-image-wrapper {
        aspect-ratio: 4/3;
    }

    .gallery-nav-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .gallery-nav-prev {
        left: 8px;
    }

    .gallery-nav-next {
        right: 8px;
    }

    .image-counter-badge {
        font-size: 11px;
        padding: 5px 10px;
        bottom: 8px;
        right: 8px;
    }

    .gallery-thumbnail-item {
        width: 55px;
        height: 55px;
    }
}

@media (max-width: 576px) {
    .admin-image-gallery {
        padding: 12px;
    }

    .main-image-wrapper {
        aspect-ratio: 3/2;
    }

    .gallery-nav-btn {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .gallery-nav-prev {
        left: 6px;
    }

    .gallery-nav-next {
        right: 6px;
    }

    .image-counter-badge {
        font-size: 10px;
        padding: 4px 8px;
        bottom: 6px;
        right: 6px;
    }

    .gallery-thumbnail-item {
        width: 50px;
        height: 50px;
    }

    .featured-indicator {
        width: 16px;
        height: 16px;
        font-size: 8px;
    }
}
