/* 갤러리 페이지 스타일 */
.gallery-page {
    padding-top: 80px;
    min-height: calc(100vh - 80px);
    background-color: #f8f9fa;
}

.gallery-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.gallery-title {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.gallery-description {
    text-align: center;
    margin-bottom: 3rem;
    color: #666;
    font-size: 1.1rem;
}

/* 필터 버튼 */
.gallery-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.filter-btn {
    padding: 0.8rem 1.5rem;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 25px;
    color: #666;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background-color: #f0f0f0;
}

.filter-btn.active {
    background-color: #4a6b57;
    color: white;
    border-color: #4a6b57;
}

/* 갤러리 그리드 */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* 이미지 뷰어 */
.image-viewer {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.image-viewer.active {
    display: flex !important;
}

.image-viewer img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    display: block;
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 1001;
}

.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
    width: 40px;
    height: 40px;
    line-height: 35px;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    transition: background-color 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
}

.nav-btn:hover {
    background-color: rgba(0, 0, 0, 0.5);
}

.prev-btn {
    left: 20px;
}

.next-btn {
    right: 20px;
}

/* 로딩 스타일 */
.loading {
    display: none;
    text-align: center;
    padding: 2rem;
}

.loading.active {
    display: block;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #4a6b57;
    border-radius: 50%;
    margin: 0 auto 1rem;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 모달 스타일 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
}

.modal-content-wrapper {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90%;
    max-height: 90vh;
}

.modal-content {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

.modal-caption {
    color: white;
    text-align: center;
    padding: 1rem 0;
    font-size: 1.1rem;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
}

.modal-nav {
    position: absolute;
    width: 100%;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 2rem;
    pointer-events: none;
}

.modal-prev,
.modal-next {
    background-color: rgba(255, 255, 255, 0.3);
    color: white;
    padding: 1rem;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
    pointer-events: auto;
}

.modal-prev:hover,
.modal-next:hover {
    background-color: rgba(255, 255, 255, 0.5);
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .gallery-container {
        padding: 1rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 0.5rem;
    }
    
    .gallery-item img {
        height: 150px;
    }
    
    .nav-btn {
        font-size: 1.5rem;
        width: 32px;
        height: 32px;
        line-height: 28px;
        padding: 0;
    }
} 