/* ==========================================
   KSEI 심포지움 - Layout 스타일
   헤더, 푸터, 컨텐츠 영역
   ========================================== */

/* ==========================================
   상단 유틸리티 바 (헤더 위, PC 전용)
   ========================================== */
.util-bar {
    background: rgba(0, 0, 0, 0.8);
    padding: 8px 0;
    font-size: 13px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.util-bar .container {
    max-width: 1200px;
    margin: 0 auto;
}

.util-bar-inner {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
}

.util-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 13px;
}

.util-link:hover {
    color: var(--accent-orange);
}

.util-divider {
    color: rgba(255, 255, 255, 0.3);
}

/* ==========================================
   메인 헤더
   ========================================== */

/* HEADER BASE */
#header { 
    background: rgba(0, 0, 0, 0.6);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 20px 0;
}

#header .container {
    max-width: 1200px;
    margin: 0 auto;
}

/* 헤더 내부: 로고 좌측, GNB 우측 배치 */
.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    gap: 24px;
}

/* 로고 */
.logo { 
    flex-shrink: 0;
}

.logo a { 
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--accent-orange);
    transition: all 0.3s ease;
}

.logo a span {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.5px;
    white-space: nowrap;
    line-height: 1.2;
    color: inherit;
}

.logo img {
    height: 40px;
    width: auto;
}

/* 햄버거 메뉴 버튼 (모바일 전용) */
.nav-toggle-label {
    display: none;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--white);
    font-size: 24px;
    z-index: 1001;
    transition: color 0.3s ease;
}

.nav-toggle-label:hover {
    color: var(--accent-orange);
}

.nav-toggle-label:focus {
    outline: 2px solid var(--accent-orange);
    outline-offset: 2px;
}

/* GNB - 데스크톱: 우측 배치 */
#gnb { 
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: flex-end;
}

#gnb ul { 
    list-style: none; 
    display: flex; 
    gap: 48px;
}

#gnb a { 
    display: block;
    text-decoration: none; 
    color: var(--white); 
    font-weight: 500;
    font-size: 15px;
    transition: color 0.3s;
}

#gnb a:hover { 
    color: var(--accent-orange);
}

/* ==========================================
   컨텐츠
   ========================================== */
#content { 
    flex: 1; 
    min-height: calc(100vh - 200px);
}

#content > .container {
    padding-top: 60px;
    padding-bottom: 80px;
}

/* ==========================================
   푸터
   ========================================== */
#footer { 
    color: rgba(255, 255, 255, 0.7); 
    padding: 60px 0; 
    margin-top: auto; 
}

#footer .container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 32px;
}

.footer-info p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.footer-copyright {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

/* 그누보드 호환성용 클래스 (사용되지 않지만 레거시 지원) */
#ft_wr, #ft_copy { 
    width: 100% !important; 
    max-width: 1200px !important; 
    margin: 0 auto !important; 
}

#aside { 
    float: none !important; 
    width: 100% !important; 
    margin: 0 !important; 
}

#footer a { 
    color: var(--accent-orange); 
    text-decoration: none; 
}

#footer a:hover { 
    text-decoration: underline; 
}

/* ==========================================
   모바일 메뉴 (JavaScript 기반)
   ========================================== */

/* 모바일 메뉴 오버레이 */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

/* 모바일 메뉴 패널 */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 300px;
    max-width: 85vw;
    background: #111;
    z-index: 1200;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    flex-direction: column;
}

.mobile-menu.is-open {
    transform: translateX(0);
}

/* 모바일 메뉴 헤더 */
.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-logo {
    color: var(--white);
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
}

.mobile-close-btn {
    background: none;
    border: none;
    color: var(--white);
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    transition: color 0.3s ease;
}

.mobile-close-btn:hover {
    color: var(--accent-orange);
}

/* 모바일 네비게이션 */
.mobile-nav ul {
    list-style: none;
    padding: 12px 0;
}

.mobile-nav li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.mobile-nav a {
    display: block;
    padding: 16px 24px;
    color: var(--white);
    text-decoration: none;
    font-size: 16px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.mobile-nav a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent-orange);
}

/* 모바일 유틸리티 */
.mobile-util {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mobile-util-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
    border-radius: 6px;
}

.mobile-util-link:hover {
    color: var(--accent-orange);
    background: rgba(255, 255, 255, 0.05);
}

/* body 스크롤 방지 */
body.menu-open {
    overflow: hidden;
    height: 100%;
}

/* ==========================================
   반응형 디자인 - Layout
   ========================================== */

/* 모바일 (1024px 미만) */
@media (max-width: 1023px) {
    /* 상단 유틸리티 바 숨김 */
    .util-bar {
        display: none;
    }
    
    /* 헤더 */
    #header {
        padding: 16px 0;
    }
    
    .logo a span {
        font-size: 17px;
        letter-spacing: -0.4px;
    }
    
    .logo img {
        height: 36px;
    }
    
    /* 햄버거 메뉴 표시 */
    .nav-toggle-label {
        display: flex;
    }
    
    /* GNB 숨김 */
    #gnb {
        display: none;
    }
    
    /* 모바일 메뉴 표시 */
    .mobile-menu-overlay,
    .mobile-menu {
        display: flex;
    }
    
    /* 서브페이지 반응형 */
    #content > .container {
        padding-top: 40px;
        padding-bottom: 60px;
    }
}

/* 모바일 (480px 이하) */
@media (max-width: 480px) {
    .logo a span {
        font-size: 15px;
    }
    
    .logo img {
        height: 32px;
    }
    
    .mobile-menu {
        width: 280px;
        max-width: 90vw;
    }
}

/* 푸터 반응형 */
@media (max-width: 768px) {
    #footer {
        padding: 40px 0;
    }
    
    #footer .container {
        gap: 20px;
    }
    
    .footer-info {
        margin-top: 24px;
        gap: 6px;
    }
    
    .footer-info p {
        font-size: 13px;
    }
    
    .footer-copyright {
        font-size: 12px;
    }
}
