/* ============================================
   헤더 스타일
   ============================================ */

/* 상단 유틸리티 바 */
.top-util-bar {
    background-color: #5DADE2;
    padding: 25px 0;
    /* border-bottom: 2px solid #a0a0a0; */
    border-bottom: 1px solid #000;
}

.top-util-inner {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
}

/* 상단 유틸리티 링크  home, 로그인, 회원가입 */
.top-util-inner a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 400;
    font-family: 'KoPub Dotum', Arial, sans-serif;
    font-size: 25px;
    line-height: 25px;
}

.top-util-inner a:hover {
    text-decoration: underline;
}

/* 메인 헤더 */
.main-header {
    background-color: #ffffff;
    border-bottom: 2px solid #e0e0e0;
    position: relative;
    z-index: 1000;
    padding: 25px 0;
}

.header-inner {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

/* 로고(text) */
.logo {
    margin: 0 20px;
    font-family: "PretendardV";
}

.logo a {
    display: flex;
    /* flex-direction: column; */
    
    align-items: center;
    /* gap: 10px; */
    text-decoration: none;
}

.logo-main {
    line-height: 42px;
    font-size: 42px;
    font-weight: 900;
    font-stretch: condensed;
    /* letter-spacing: -5px; */
    /* color: #5DADE2; */
    color: #000;
    letter-spacing: -3px;
}

.logo-subi {
    font-size: 38px;
    font-weight: 900;
    color: #5DADE2;
}
.logo-sub {
    line-height: 42px;
    font-size: 42px;
    font-stretch: condensed;
    letter-spacing: -3px;
    color: #5DADE2;
    font-weight: 900;
}

.logo-highlight {
    color: #5DADE2;
}
/* 이미지 로고 */
/* .logo {
   margin: 0;
}
.logo a {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 4px;
    text-decoration: none;
}
.logo-main {
    height: 56px;
}
.logo-sub {
    height: 50px;
} */

/* 메인 네비게이션 */
.main-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.main-nav ul {
    display: flex;
    gap: 40px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav li {
    position: relative;
}

.main-nav a {
    color: #333;
    text-decoration: none;
    font-family: "KoPub Dotum", Arial, sans-serif;
    font-size: 30px;
    font-weight: 600;
    line-height: 30px;
    padding: 10px 0;
    display: block;
    transition: color 0.3s;
}

.main-nav a:hover {
    color: #5DADE2;
}

.main-nav li.on a,
.main-nav li.active a {
    color: #5DADE2;
    font-weight: 700;
}

/* 헤더 유틸리티 */
.header-util {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-search,
.btn-mobile-menu {
    background: none;
    border: none;
    cursor: pointer;
    /* padding: 8px; */
    color: #333;
    transition: color 0.3s;
    width:32px;
    height:32px;
    padding: 0;
}
.btn-search svg {
    width: 100%;
    height: 100%;
}

.btn-search:hover,
.btn-mobile-menu:hover {
    color: #5DADE2;
}

.btn-mobile-menu {
    display: none;
    flex-direction: column;
    gap: 4px;
    width: 24px;
    height: 24px;
}

.btn-mobile-menu span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: currentColor;
    transition: all 0.3s;
}

/* 검색 레이어 */
.search-layer {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
}

.search-layer-inner {
    background: #ffffff;
    padding: 40px;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    position: relative;
}

.search-layer form {
    display: flex;
    gap: 10px;
}

.search-input {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid #5DADE2;
    border-radius: 4px;
    font-size: 16px;
    outline: none;
}

.search-input:focus {
    border-color: #3498db;
}

.btn-search-submit {
    padding: 12px 30px;
    background-color: #5DADE2;
    color: #ffffff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-search-submit:hover {
    background-color: #3498db;
}

.btn-search-close {
    position: absolute;
    top: 7px;
    right: 7px;
    background: none;
    border: none;
    font-size: 32px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    width: 40px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-search-close:hover {
    color: #333;
}

/* 모바일 메뉴 */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
}

.mobile-menu-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
}

.mobile-menu-inner {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 80%;
    max-width: 320px;
    background-color: #ffffff;
    overflow-y: auto;
    z-index: 1;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.mobile-menu-header h2 {
    margin: 0;
    font-size: 20px;
    color: #333;
}

.btn-mobile-close {
    background: none;
    border: none;
    font-size: 32px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-mobile-close:hover {
    color: #333;
}

.mobile-nav {
    padding: 20px 0;
}

.mobile-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-nav li {
    border-bottom: 1px solid #f0f0f0;
}

.mobile-nav a {
    display: block;
    padding: 15px 20px;
    color: #333;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: background-color 0.3s;
}

.mobile-nav a:hover {
    background-color: #f5f5f5;
    color: #5DADE2;
}



/* 반응형 - 태블릿 */
@media screen and (max-width: 1280px) {
    .logo .logo-sub { display: none; }
}
@media screen and (max-width: 1024px) {
    .header-inner {
        padding: 0 15px;
        height: 70px;
    }

    .main-nav ul {
        gap: 25px;
    }

    .main-nav a {
        font-size: 20px;
    }

    .logo-main {
        height:40px;
    }
    .logo-sub {
        display: none;
    }
    .btn-search {
        width:25px;
        height:25px;
    }
}

/* 반응형 - 모바일 */
@media screen and (max-width: 768px) {
    .top-util-bar {
        padding: 6px 0;
        font-size: 12px;
    }

    .top-util-inner {
        padding: 0 15px;
        gap: 15px;
    }

    .header-inner {
        height: 40px;
    }

    .logo-main {
        font-size: 24px;
    }

    .logo-sub {
        font-size: 9px;
    }

    .main-nav {
        display: none;
    }

    .header-util {
        max-width:100px;
        gap: 40px;
    }
    .btn-mobile-menu {
        display: flex;
    }

    /* .btn-search {
        width: 20px;
        height: 20px;
    } */

    .search-layer-inner {
        padding: 30px 20px;
        width: 95%;
    }

    .search-input {
        padding: 10px 15px;
        font-size: 14px;
    }

    .btn-search-submit {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* 반응형 - 작은 모바일 */
@media screen and (max-width: 480px) {
    .logo a {
        gap: 8px;
    }

    .logo-main {
        font-size: 20px;
    }

    .logo-sub {
        font-size: 8px;
    }

    .mobile-menu-inner {
        width: 85%;
    }
}
