@charset "utf-8";
@import url('https://cdn.rawgit.com/moonspam/NanumSquare/master/nanumsquare.css');

/* ==========================================
   1. 배경 및 전역 설정
   ========================================== */
html, body {
    background-image: url('https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FbtrECA%2FdJMcajnrTIa%2FAAAAAAAAAAAAAAAAAAAAACCHhqo1KbLobhMGANhah11VAZlXdr3te99078U_u4mr%2Fimg.jpg%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1769871599%26allow_ip%3D%26allow_referer%3D%26signature%3DrW6pYpH9pZxBBeKallxqWdKWv6w%253D') !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-color: #222 !important;
    margin: 0;
    padding: 0;
    font-family: 'NanumSquare', sans-serif !important;
}

/* 스크롤바 숨김 */
::-webkit-scrollbar { display: none; }

/* 레이어 투명화 */
#wrapper, #container, #content, .gallery-board, .gallery-grid, main, section {
    background: transparent !important;
}

/* ==========================================
   2. 갤러리 리스트 및 카드 아이템
   ========================================== */
.gallery-board {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.gallery-grid {
    display: flex;
    flex-direction: column;
}

.gallery-item {
    position: relative !important;
    cursor: pointer;
    overflow: hidden !important;
    border: 1px solid #eee;
    border-radius: 10px;
    background: #eeeeee17;
    backdrop-filter: blur(2px);
    filter: drop-shadow(2px 2px 3px rgba(0, 0, 0, 0.5));
}

.gallery-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
}

/* 카드 제목 레이어 */
.item-title {
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    padding: 30px 10px 15px 10px !important;
    color: #ffffff !important;
    font-size: 12px !important;
    font-weight: bold !important;
    text-align: center !important;
    display: flex !important;
    justify-content: center !important;
    align-items: flex-end !important;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.5) 60%, transparent 100%) !important;
    z-index: 10 !important;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s ease-in-out;
    pointer-events: none;
    box-sizing: border-box !important;
}

.gallery-item:hover .item-title {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ==========================================
   3. 모달창 (클릭 시 이미지 팝업)
   ========================================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: none;
    z-index: 1000;
    backdrop-filter: blur(3px);
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 900px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background-color: rgba(255, 255, 255, 0.05) !important;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37) !important;
    padding: 20px;
    z-index: 1001;
}

.modal-img {
    max-width: 100%;
    max-height: 700px;
    display: block;
}

.modal-close {
    position: relative;
    top: 5px;
    left: 5px;
    font-size: 35px;
    cursor: pointer;
    color: #ffffff;
    text-shadow: 0px 0px 3px black;
}

.modal-description {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 15px;
    border-radius: 20px;
    color: #eee !important;
    text-align: center;
}

.modal-description * { color: #ffffff !important; }

.modal-title {
    font-size: 18px;
    font-weight: bold;
    color: #eee;
    text-shadow: 1px 3px 3px black;
    text-align: center;
}

/* 내비게이션 화살표 */
.modal-navigation {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.modal-nav-btn {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #eee;
    text-shadow: 3px 3px 3px black;
    transition: all 0.3s ease;
    padding: 0 20px;
    z-index: 10;
}

/* ==========================================
   4. UI 요소 (버튼, 검색창, 페이지 숨김)
   ========================================== */
/* 상단 헤더 및 버튼 */
.pic-header { display: flex; gap: 5px; align-items: center; justify-content: space-between; }
.list-option { display: flex; flex: 1; gap: 5px; margin-bottom: 3px; opacity: 20%; transition: 0.3s; }
.list-option:hover { opacity: 100%; }
.list-option.btn { justify-content: flex-end; font-size: 10px; }

.simple-ui-btn { display: flex; gap: 5px; }
.simple-btn { background: #eee; color: #333; padding: 5px; font-size: 18px; border-radius: 10px; border: 1px inset #eee; }
.simple-btn.admin { background: #333 !important; }

/* 카테고리 */
.simple-category { display: flex; gap: 5px; margin-bottom: 20px; justify-content: center; list-style: none; }
.simple-category li { background: #333; color: #eee; font-size: 10px; border-radius: 10px; padding: 2px 5px; border: 1px inset #333; }

/* 불필요한 요소 숨김 (검색, 페이지네이션 등) */
.ui-search-box, .pagination, [class*="paging"], [class*="page"], 
.modal-meta, .btn-search, .search-btn, .gallery-board + div, center, #bo_btn_top {
    display: none !important;
}

/* ==========================================
   5. 모바일 반응형
   ========================================== */
@media (max-width: 768px) {
    .gallery-board { gap: 10px !important; }
    .pic-header { display: none !important; }
    .gallery-item {
        width: 150px !important;
        height: 150px !important;
    }
}