* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #000000 0%, #0a0a0a 25%, #1a0033 50%, #330066 75%, #000000 100%);
    color: #ffffff;
    overflow-x: hidden;
    line-height: 1.6;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(249, 122, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(255, 255, 0, 0.05) 0%, transparent 50%);
    z-index: -2;
    pointer-events: none;
}

/* 파티클 배경 */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(249, 122, 0, 0.3);
    border-radius: 50%;
    animation: float 6s infinite ease-in-out;
}

@keyframes float {
    0%, 100% { 
        transform: translateY(0) translateX(0); 
        opacity: 0; 
    }
    50% { 
        opacity: 1; 
    }
    100% { 
        transform: translateY(-100vh) translateX(50px); 
        opacity: 0; 
    }
}

/* 네비게이션 */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 2px solid rgba(249, 122, 0, 0.3);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-img {
    height: 50px;
    width: auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #f97a00;
    text-shadow: 0 0 10px rgba(249, 122, 0, 0.5);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 1rem;
}

.nav-links a:hover {
    color: #f97a00;
}

/* 히어로 섹션 */
.gallery-hero {
    position: relative;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8rem 2rem 4rem 2rem;
    margin-top: 80px;
}

.gallery-hero h1 {
    font-size: 4rem;
    color: #f97a00;
    margin-bottom: 1rem;
    text-shadow: 0 0 30px rgba(249, 122, 0, 0.6);
    letter-spacing: 0.2rem;
}

.gallery-hero p {
    font-size: 1.3rem;
    color: #ccc;
}

/* 갤러리 컨테이너 */
.gallery-container {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

/* 메인 필터 버튼 */
.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-bottom: 3rem;
    flex-wrap: wrap;
    background: rgba(20, 20, 20, 0.8);
    padding: 0.5rem 0;
    border-radius: 0;
    backdrop-filter: blur(10px);
    border-top: 2px solid rgba(249, 122, 0, 0.2);
    border-bottom: 2px solid rgba(249, 122, 0, 0.2);
    width: 100%;
    margin-left: 0;
    margin-right: 0;
    position: relative;
    z-index: 100;
}

/* 드롭다운 컨테이너 */
.filter-dropdown {
    position: relative;
    display: inline-block;
    z-index: 101;
}

.filter-btn {
    padding: 1rem 2.5rem;
    background: transparent;
    border: none;
    color: #ccc;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    font-weight: 600;
    position: relative;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.filter-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #f97a00, #ff9933);
    transition: width 0.3s ease;
    border-radius: 3px 3px 0 0;
}

.filter-btn:hover {
    color: #f97a00;
    background: rgba(249, 122, 0, 0.1);
}

.filter-btn:hover::after {
    width: 80%;
}

.filter-btn.active {
    background: linear-gradient(135deg, rgba(249, 122, 0, 0.3), rgba(249, 122, 0, 0.15));
    color: #fff;
    text-shadow: 0 0 10px rgba(249, 122, 0, 0.5);
}

.filter-btn.active::after {
    width: 90%;
    height: 4px;
    box-shadow: 0 0 15px rgba(249, 122, 0, 0.8);
}

/* 서브 필터 - 드롭다운 스타일 */
.sub-filters {
    position: absolute;
    top: 100%;
    left: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: rgba(20, 20, 20, 0.95);
    border: 2px solid rgba(249, 122, 0, 0.3);
    border-top: none;
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 102;
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.filter-dropdown:hover .sub-filters,
.sub-filters.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sub-filter-btn {
    padding: 1rem 2rem;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(249, 122, 0, 0.1);
    color: #aaa;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    font-weight: 500;
    text-align: left;
    width: 100%;
}

.sub-filter-btn:last-child {
    border-bottom: none;
}

.sub-filter-btn:hover {
    background: rgba(249, 122, 0, 0.2);
    color: #f97a00;
    padding-left: 2.5rem;
}

.sub-filter-btn.active {
    background: rgba(249, 122, 0, 0.3);
    color: #fff;
    font-weight: 600;
    border-left: 3px solid #f97a00;
}

/* 갤러리 그리드 */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    background: rgba(20, 20, 20, 0.8);
    border: 2px solid rgba(249, 122, 0, 0.2);
    transition: all 0.4s ease;
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-10px);
    border-color: #f97a00;
    box-shadow: 0 15px 40px rgba(249, 122, 0, 0.4);
}

.gallery-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

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

.gallery-item-info {
    padding: 1.5rem;
}

.gallery-item-info h3 {
    color: #f97a00;
    margin-bottom: 0.8rem;
    font-size: 1.3rem;
}

.gallery-item-info p {
    color: #ccc;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.8rem;
}

.gallery-item-tag {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: rgba(249, 122, 0, 0.3);
    color: #f97a00;
    font-size: 0.85rem;
    border-radius: 20px;
    margin-top: 0.5rem;
    border: 1px solid rgba(249, 122, 0, 0.5);
}

/* 라이트박스 */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.lightbox-caption {
    background: rgba(20, 20, 20, 0.95);
    padding: 1.5rem 2rem;
    border-radius: 10px;
    max-width: 600px;
    text-align: center;
}

.lightbox-caption h3 {
    color: #f97a00;
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    text-shadow: 0 0 10px rgba(249, 122, 0, 0.5);
}

.lightbox-caption p {
    color: #ccc;
    font-size: 1rem;
    line-height: 1.6;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2.5rem;
    color: white;
    cursor: pointer;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
    border: none;
}

.lightbox-close:hover {
    transform: rotate(90deg);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(249, 122, 0, 0.8);
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: #f97a00;
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev:active,
.lightbox-next:active {
    transform: translateY(-50%) scale(0.95);
}

/* 업로드 섹션 */
.upload-section {
    text-align: center;
    padding: 3rem 2rem;
    background: rgba(249, 122, 0, 0.08);
    border-radius: 15px;
    margin-top: 3rem;
    border: 2px dashed rgba(249, 122, 0, 0.3);
}

.upload-section h3 {
    color: #f97a00;
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.upload-section p {
    color: #ccc;
    font-size: 1.1rem;
}

/* Footer */
footer {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 2rem;
    background: rgba(10, 10, 10, 0.9);
    color: #666;
    border-top: 2px solid rgba(249, 122, 0, 0.3);
}

/* 페이드인 애니메이션 */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 커서 페이드 애니메이션 */
@keyframes cursor-fade {
    0% { 
        opacity: 1; 
        transform: scale(1); 
    }
    100% { 
        opacity: 0; 
        transform: scale(2.5); 
    }
}

/* 반응형 */
@media (max-width: 768px) {
    .gallery-hero h1 {
        font-size: 2.5rem;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .nav-links {
        gap: 1rem;
        font-size: 0.9rem;
    }

    .logo {
        font-size: 1.2rem;
    }

    .logo-img {
        height: 40px;
    }

    .gallery-filters {
        padding: 0.3rem;
        max-width: 100%;
    }

    .filter-btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .filter-dropdown {
        width: 100%;
    }

    .sub-filters {
        position: relative;
        width: 100%;
        min-width: auto;
    }

    .sub-filter-btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.85rem;
    }

    .lightbox-close {
        top: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 2rem;
    }

    .lightbox-prev,
    .lightbox-next {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }

    .lightbox-caption {
        padding: 1rem 1.5rem;
        max-width: 90%;
    }

    .lightbox-caption h3 {
        font-size: 1.2rem;
    }

    .lightbox-caption p {
        font-size: 0.9rem;
    }

    .lightbox-content img {
        max-height: 50vh;
    }
}