@charset "utf-8";

/* ============================================= */
/*  1. 기본 초기화                                */
/* ============================================= */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { 
    font-family: 'Pretendard', sans-serif; 
    line-height: 1.6; 
    color: #333; 
    background: #fff; 
    overflow-x: hidden; 
}
a { text-decoration: none; color: inherit; }
ul, li { list-style: none; }

/* ============================================= */
/*  2. 공통 헤더                                  */
/* ============================================= */
#header {
    width: 100%; 
    height: 110px; 
    background: #fff; 
    border-bottom: 1px solid #e5e5e5;
    position: fixed; 
    top: 0; left: 0; 
    z-index: 1000;
    transition: height 0.3s ease;
}
.header-inner { 
    width: 1400px; 
    max-width: 95%; 
    margin: 0 auto; 
    height: 100%; 
    display: flex !important; 
    justify-content: space-between; 
    align-items: center; 
}

/* 로고 영역 */
.logo-area .logo-link { 
    display: flex !important; 
    align-items: center; 
}
.logo-main { 
    width: 294px; 
    height: 54px; 
    display: block; 
    object-fit: contain; 
    transition: all 0.3s ease;
}

/* 메뉴(GNB) - 데스크톱 가로 정렬 */
.gnb {
    display: block;
}
.gnb ul { 
    display: flex !important; 
    align-items: center; 
}
.gnb ul li { margin-left: 40px; }
.gnb ul li a { 
    font-size: 22px; 
    font-weight: 600; 
    color: #333; 
    transition: 0.3s; 
    white-space: nowrap; 
}
.gnb ul li a.active, 
.gnb ul li a:hover { color: #004ea2; }

/* 인제의대 홈 - 강조 버튼 */
.gnb ul li.menu-btn {
    margin-left: 30px;
}
.gnb ul li.menu-btn a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #004ea2;
    color: #fff !important;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 78, 162, 0.25);
}
.gnb ul li.menu-btn a .ico-home {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}
.gnb ul li.menu-btn a:hover {
    background: #003a7a;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 78, 162, 0.35);
}
.gnb ul li.menu-btn a:hover .ico-home {
    transform: scale(1.1);
}

/* ============================================= */
/*  3. 햄버거 메뉴 버튼 (모바일 전용)              */
/* ============================================= */
.menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 1001;
    padding: 0;
}
.menu-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    background: #004ea2;
    margin: 6px auto;
    border-radius: 3px;
    transition: all 0.3s ease;
}
.menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}
.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* ============================================= */
/*  4. 서브페이지 공통 타이틀                     */
/*  (index의 메인 비주얼과 동일한 폰트 크기 사용) */
/* ============================================= */
.sub-title-area {
    margin-top: 110px; 
    height: 200px; 
    background-color: #004ea2; 
    background-image: radial-gradient(rgba(255, 255, 255, 0.15) 1.5px, transparent 1.5px);
    background-size: 25px 25px;
    display: flex; 
    justify-content: center; 
    align-items: center; 
    position: relative; 
    overflow: hidden;
    transition: all 0.3s ease;
}
.visual-text-container { 
    width: 100%; 
    height: 80px; 
    position: relative; 
    z-index: 10; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    padding: 0 20px;
}
.visual-item { 
    position: absolute; 
    width: 100%; 
    opacity: 0; 
    transform: translateY(15px); 
    transition: all 0.8s ease; 
    text-align: center; 
}
.visual-item.active { 
    opacity: 1; 
    transform: translateY(0); 
}
/* index의 .visual-item h2/p와 동일한 톤 */
.visual-item h1 { 
    font-size: 48px; 
    font-weight: 700; 
    color: #fff; 
    margin-bottom: 15px; 
    word-break: keep-all;
    letter-spacing: -1px;
    text-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.visual-item p { 
    font-size: 24px; 
    color: rgba(255, 255, 255, 0.9); 
    font-weight: 400;
    word-break: keep-all;
}

/* ============================================= */
/*  5. 공통 푸터                                  */
/* ============================================= */
#footer { 
    background: #333; 
    color: #fff; 
    padding: 40px 0; 
    margin-top: 60px; 
}
.footer-inner { 
    width: 1200px; 
    max-width: 95%; 
    margin: 0 auto; 
    font-size: 14px; 
    opacity: 0.8; 
    text-align: center;
}
.footer-inner p { margin-bottom: 5px; }
.footer-inner p:last-child { margin-bottom: 0; }

/* ============================================= */
/*  6. 반응형 - 태블릿 (1024px 이하)              */
/* ============================================= */
@media (max-width: 1024px) {
    /* 헤더 - 메뉴 폰트 살짝 축소 */
    .gnb ul li { margin-left: 25px; }
    .gnb ul li a { font-size: 18px; }
    
    /* 로고 약간 축소 */
    .logo-main { width: 272px; height: 50px; }
    
    /* 인제의대바로가기 버튼 축소 */
    .gnb ul li.menu-btn { margin-left: 20px; }
    .gnb ul li.menu-btn a { 
        padding: 8px 16px; 
        font-size: 14px; 
        gap: 6px;
    }
    .gnb ul li.menu-btn a .ico-home {
        width: 16px;
        height: 16px;
    }
    
    /* 서브 타이틀 - index의 태블릿과 동일 */
    .sub-title-area { height: 180px; }
    .visual-item h1 { font-size: 38px; margin-bottom: 12px; }
    .visual-item p  { font-size: 20px; }
}

/* ============================================= */
/*  7. 반응형 - 모바일 (768px 이하) - 햄버거 활성화 */
/* ============================================= */
@media (max-width: 768px) {
    /* 헤더 높이 축소 + 살짝 그림자 추가 */
    #header { 
        height: 80px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    }
    
    /* 로고 모바일 사이즈 */
    .logo-main { width: 240px; height: 44px; }
    
    /* 햄버거 버튼 표시 */
    .menu-toggle { display: block; }
    
    /* GNB 모바일 슬라이드 메뉴 */
    .gnb {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid #e5e5e5;
        box-shadow: 0 8px 20px rgba(0,0,0,0.08);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    }
    .gnb.open {
        max-height: 500px;
    }
    .gnb ul { 
        display: block !important; 
        padding: 10px 0;
    }
    .gnb ul li { 
        margin: 0; 
        border-bottom: 1px solid #f0f0f0;
    }
    .gnb ul li:last-child { border-bottom: none; }
    .gnb ul li a { 
        display: block;
        padding: 16px 25px;
        font-size: 17px;
        font-weight: 600;
        transition: background 0.3s ease, color 0.3s ease, border-left-color 0.3s ease;
        border-left: 3px solid transparent;
    }
    .gnb ul li a:hover,
    .gnb ul li a.active { 
        background: #f0f7ff;
        color: #004ea2;
        border-left-color: #004ea2;
    }
    
    /* 모바일 - 인제의대 홈 (다른 메뉴와 동일한 가로폭 / 글자색만 강조) */
    .gnb ul li.menu-btn {
        margin: 0;
        border-bottom: none;
    }
    .gnb ul li.menu-btn a {
        display: flex;
        align-items: center;
        gap: 8px;
        background: transparent;
        color: #004ea2 !important;
        padding: 16px 25px;
        border-radius: 0;
        font-size: 17px;
        font-weight: 700;
        border-left: 3px solid transparent;
        box-shadow: none;
        text-align: left;
    }
    .gnb ul li.menu-btn a .ico-home {
        width: 18px;
        height: 18px;
        flex-shrink: 0;
    }
    .gnb ul li.menu-btn a:hover {
        background: #f0f7ff;
        color: #004ea2 !important;
        border-left-color: #004ea2;
        transform: none;
        box-shadow: none;
    }
    .gnb ul li.menu-btn a:hover .ico-home {
        transform: none;
    }
    
    /* 서브 타이틀 영역 모바일 - index와 동일 */
    .sub-title-area { 
        margin-top: 80px;
        height: 160px; 
    }
    .visual-text-container { height: 120px; }
    .visual-item h1 { 
        font-size: 26px; 
        margin-bottom: 8px;
    }
    .visual-item p { font-size: 14px; }
    
    /* 푸터 모바일 */
    #footer { 
        padding: 30px 15px; 
        margin-top: 40px;
    }
    .footer-inner { font-size: 13px; }
}

/* ============================================= */
/*  8. 반응형 - 작은 모바일 (600px 이하)          */
/*  index 페이지와 동일하게 통일                  */
/* ============================================= */
@media (max-width: 600px) {
    .sub-title-area { height: 140px; }
    .visual-item h1 { 
        font-size: 22px; 
        margin-bottom: 6px;
    }
    .visual-item p { font-size: 13px; }
}

/* ============================================= */
/*  9. 반응형 - 아주 작은 모바일 (480px 이하)     */
/* ============================================= */
@media (max-width: 480px) {
    #header { height: 70px; }
    
    .logo-main { width: 196px; height: 36px; }
    
    .gnb { top: 70px; }
    
    .sub-title-area { 
        margin-top: 70px;
        height: 130px; 
    }
    .visual-text-container { height: 100px; padding: 0 15px; }
    .visual-item h1 { 
        font-size: 20px; 
        margin-bottom: 5px;
    }
    .visual-item p { font-size: 12px; }
    
    /* 햄버거 버튼 살짝 축소 */
    .menu-toggle { width: 36px; height: 36px; }
    .menu-toggle span { width: 22px; height: 2px; margin: 5px auto; }
    .menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
    
    /* 모바일 메뉴 항목 높이 살짝 축소 */
    .gnb ul li a { 
        padding: 14px 20px; 
        font-size: 15px;
    }
    
    #footer { 
        padding: 25px 12px; 
        margin-top: 30px;
    }
    .footer-inner { font-size: 12px; }
    .footer-inner p { margin-bottom: 3px; }
}

/* ============================================= */
/*  10. 모바일 메뉴 열렸을 때 body 스크롤 방지    */
/* ============================================= */
body.menu-open {
    overflow: hidden;
}

/* ============================================= */
/*  11. 접근성 - 포커스 스타일                    */
/* ============================================= */
.menu-toggle:focus-visible {
    outline: 2px solid #004ea2;
    outline-offset: 2px;
    border-radius: 4px;
}
.gnb a:focus-visible {
    outline: 2px solid #004ea2;
    outline-offset: -2px;
}
