@charset "utf-8";

/* --- 공통 --- */
#header {
    --hd-top-h: 100px;
    --hd-bottom-h: 60px;
    --hd-top-h-scrolled: 78px;
    --hd-bottom-h-scrolled: 54px;

    --hd-logo-main-h: 40px;
    --hd-logo-sub-h: 40px;
    --hd-logo-main-h-scrolled: 34px;
    --hd-logo-sub-h-scrolled: 34px;

    --hd-menu-fs: var(--fs_20);
    --hd-menu-fs-scrolled: var(--fs_18);
    --hd-call-fs: var(--fs_20);
    --hd-call-fs-scrolled: var(--fs_18);

    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 20000;
    background: var(--gray_f);
    border-bottom: 1px solid transparent;
    box-shadow: none;
    transition:
        border-color 0.24s ease-out,
        box-shadow 0.32s ease-out,
        background-color 0.24s ease-out;
}

#header.is-scrolled {
    border-bottom-color: rgba(var(--point_rgb), 0.14);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

#header .logo a,
#header .logo img {
    display: block;
}

#header .pc_nav {
    display: flex !important;
}

#header .m_nav {
    display: none !important;
}

#m_nav_layer,
.m_dim,
#m_gnb_panel {
    display: none;
}

body.no-scroll {
    position: fixed;
    left: 0;
    right: 0;
    width: 100%;
    overflow: hidden;
}

/* --- PC 전용 (1101px 이상) --- */
@media screen and (min-width: 1101px) {
    #header {
        background: var(--gray_f);
    }

    #header .wrap {
        max-width: calc(1720px + 4rem);
        display: flex;
        align-items: stretch;
    }

    #header .pc_header {
        display: flex !important;
        flex-direction: column;
        width: 100%;
        min-height: calc(var(--hd-top-h) + var(--hd-bottom-h));
        transition: min-height 0.38s ease;
    }

    #header .m_nav {
        display: none !important;
    }

    #header .pc_header_top {
        min-height: var(--hd-top-h);
        padding: 20px 0;
        transition: min-height 0.38s ease, padding 0.38s ease;
    }

    #header .pc_header_top .logo a {
        display: flex;
        align-items: center;
        gap: 20px;
    }

    #header .pc_header_top .logo a img:first-child {
        height: var(--hd-logo-main-h);
        width: auto;
        transition: height 0.38s ease;
    }

    #header .pc_header_top .logo a img:last-child {
        height: var(--hd-logo-sub-h);
        width: auto;
        transition: height 0.38s ease;
    }

    #header .top_tel {
        min-height: 40px;
        padding: 0 18px;
        border-radius: 999px;
        gap: 8px !important;
        background: var(--point) !important;
        color: var(--gray_f) !important;
        font-size: var(--hd-call-fs);
        line-height: 1;
        box-shadow: 0 6px 16px rgba(var(--point_rgb), 0.20);
        transition:
            transform 0.25s ease,
            box-shadow 0.25s ease,
            font-size 0.38s ease,
            min-height 0.38s ease,
            padding 0.38s ease;
    }

    #header .top_tel img {
        display: block;
        height: 20px;
        width: auto;
        transition: height 0.38s ease;
    }

    #header .top_tel:hover {
        filter: none;
        transform: translateY(-1px);
    }

    #header .pc_header_bottom {
        position: relative;
        width: 100%;
    }

    #header .pc_header_bottom::before {
        content: "";
        position: absolute;
        top: 0;
        bottom: 0;
        left: 50%;
        width: 100vw;
        transform: translateX(-50%);
        background: var(--point_lighter);
        border-top: 1px solid #f1f5f8;
        z-index: 0;
    }

    #header .pc_gnb_list {
        position: relative;
        z-index: 1;
        min-height: var(--hd-bottom-h);
        gap: clamp(8px, 0.8vw, 22px) !important;
        transition: min-height 0.38s ease, gap 0.38s ease;
    }

    #header .pc_gnb_list li {
        list-style: none;
    }

    #header .pc_gnb_list .d1 {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: var(--hd-bottom-h);
        padding: 0 6px;
        font-size: var(--hd-menu-fs);
        font-weight: 500;
        color: #444444;
        white-space: nowrap;
        transition:
            color 0.2s ease,
            font-weight 0.2s ease,
            font-size 0.38s ease,
            min-height 0.38s ease;
    }

    #header .pc_gnb_list li:hover .d1,
    #header .pc_gnb_list li.is-active .d1,
    #header .pc_gnb_list .d1.is-active,
    #header .pc_gnb_list .d1[aria-current="page"] {
        color: var(--point) !important;
        font-weight: 700;
    }

    #header.is-scrolled .pc_header {
        min-height: calc(var(--hd-top-h-scrolled) + var(--hd-bottom-h-scrolled));
    }

    #header.is-scrolled .pc_header_top {
        min-height: var(--hd-top-h-scrolled);
        padding: 14px 0;
    }

    #header.is-scrolled .pc_header_top .logo a img:first-child {
        height: var(--hd-logo-main-h-scrolled);
    }

    #header.is-scrolled .pc_header_top .logo a img:last-child {
        height: var(--hd-logo-sub-h-scrolled);
    }

    #header.is-scrolled .top_tel {
        min-height: 38px;
        padding: 0 16px;
        font-size: var(--hd-call-fs-scrolled);
    }

    #header.is-scrolled .top_tel img {
        height: 18px;
    }

    #header.is-scrolled .pc_gnb_list {
        min-height: var(--hd-bottom-h-scrolled);
    }

    #header.is-scrolled .pc_gnb_list .d1 {
        min-height: var(--hd-bottom-h-scrolled);
        font-size: var(--hd-menu-fs-scrolled);
    }
}

/* PC에서 화면 줄어들 때 자연스럽게 축소 */
@media screen and (min-width: 1101px) and (max-width: 1499px) {
    #header {
        --hd-top-h: 92px;
        --hd-bottom-h: 58px;
        --hd-top-h-scrolled: 74px;
        --hd-bottom-h-scrolled: 52px;

        --hd-logo-main-h: 36px;
        --hd-logo-sub-h: 36px;
        --hd-logo-main-h-scrolled: 32px;
        --hd-logo-sub-h-scrolled: 32px;

        --hd-menu-fs: var(--fs_18);
        --hd-menu-fs-scrolled: var(--fs_16);
        --hd-call-fs: var(--fs_18);
        --hd-call-fs-scrolled: var(--fs_16);
    }

    #header .pc_header_top .logo a {
        gap: 16px;
    }

    #header .pc_gnb_list {
        gap: 14px !important;
    }
}

@media screen and (min-width: 1101px) and (max-width: 1260px) {
    #header {
        --hd-top-h: 86px;
        --hd-bottom-h: 56px;
        --hd-top-h-scrolled: 70px;
        --hd-bottom-h-scrolled: 50px;

        --hd-logo-main-h: 33px;
        --hd-logo-sub-h: 33px;
        --hd-logo-main-h-scrolled: 29px;
        --hd-logo-sub-h-scrolled: 29px;

        --hd-menu-fs: var(--fs_16);
        --hd-menu-fs-scrolled: var(--fs_15);
        --hd-call-fs: var(--fs_16);
        --hd-call-fs-scrolled: var(--fs_15);
    }

    #header .pc_header_top .logo a {
        gap: 12px;
    }

    #header .top_tel {
        padding: 0 14px;
    }

    #header .pc_gnb_list {
        gap: 10px !important;
    }

    #header .pc_gnb_list .d1 {
        padding: 0 4px;
    }
}

/* --- 모바일 전용 (1100px 이하) --- */
/* --- 모바일 전용 (1100px 이하) --- */
@media screen and (max-width: 1100px) {
    #header {
        height: 72px;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border-bottom-color: transparent;
        transition:
            height 0.3s ease,
            border-color 0.24s ease-out,
            box-shadow 0.32s ease-out,
            background-color 0.24s ease-out;
    }

    #header.is-scrolled {
        height: 64px;
        border-bottom-color: rgba(var(--point_rgb), 0.16);
        box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
    }

    #header .wrap {
        width: 100%;
        max-width: 100%;
        display: flex;
        align-items: center;
    }

    #header .pc_nav {
        display: none !important;
    }

    #header .m_nav {
        display: flex !important;
        width: 100%;
        min-height: 72px;
        transition: min-height 0.3s ease;
    }

    #header.is-scrolled .m_nav {
        min-height: 64px;
    }

    #header .m_nav .logo {
        flex-shrink: 0;
    }

    #header .m_nav .logo a {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    #header .m_nav .logo a img {
        height: 22px;
        width: auto;
        transition: height 0.3s ease;
    }

    #header.is-scrolled .m_nav .logo a img {
        height: 20px;
    }

    #header .m_action_group {
        position: relative;
        z-index: 20001;
        flex-shrink: 0;
        gap: 10px !important;
    }

    /* 헤더 안 전화 버튼 : 아이콘 전용 40x40 */
    #header .m_tel_btn {
        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;
        padding: 0;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0;
        background: var(--point);
        color: var(--gray_f);
        border: 1px solid rgba(var(--point_rgb), 0.15);
        box-shadow: 0 6px 16px rgba(var(--point_rgb), 0.18);
        transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    }

    #header .m_tel_btn:active {
        transform: scale(0.97);
    }

    #header .m_tel_btn img {
        height: 18px;
        width: auto;
        display: block;
        filter: brightness(0) invert(1);
    }

    #header .m_tel_btn span {
        display: none !important;
    }

    /* 헤더 안 햄버거 버튼 : 40x40 */
    #header .m_menu_btn {
        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;
        position: relative;
        border: 1px solid rgba(var(--point_rgb), 0.14);
        border-radius: 50%;
        background: var(--point_lighter);
        padding: 0;
        cursor: pointer;
        z-index: 20001;
        appearance: none;
        -webkit-appearance: none;
        transition: background 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
    }

    #header .m_menu_btn:active {
        transform: scale(0.97);
    }

    #header .m_menu_btn span {
        position: absolute;
        left: 50%;
        width: 20px;
        height: 2px;
        border-radius: 999px;
        background: var(--point2);
        transform: translateX(-50%);
        transition: top 0.28s ease, transform 0.28s ease, opacity 0.2s ease, background 0.2s ease;
    }

    #header .m_menu_btn span:nth-child(1) {
        top: 11px;
    }

    #header .m_menu_btn span:nth-child(2) {
        top: 18px;
    }

    #header .m_menu_btn span:nth-child(3) {
        top: 25px;
    }

    #header .m_menu_btn.active {
        background: var(--point);
        border-color: var(--point);
    }

    #header .m_menu_btn.active span {
        background: var(--gray_f);
    }

    #header .m_menu_btn.active span:nth-child(1) {
        top: 19px;
        transform: translateX(-50%) rotate(45deg);
    }

    #header .m_menu_btn.active span:nth-child(2) {
        opacity: 0;
    }

    #header .m_menu_btn.active span:nth-child(3) {
        top: 19px;
        transform: translateX(-50%) rotate(-45deg);
    }

    #m_nav_layer {
        display: block;
    }

    .m_dim {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(var(--point2_darker_rgb), 0.3);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index: 20010;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }

    .m_dim.show {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    #m_gnb_panel {
        display: flex;
        position: fixed;
        top: 0;
        right: 0;
        width: min(88vw, 360px);
        height: 100dvh;
        background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
        z-index: 20020;
        transform: translateX(100%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: transform 0.35s ease, opacity 0.25s ease, visibility 0.25s ease;
        box-shadow: -1rem 0 3rem rgba(var(--point2_dark_rgb), 0.5);
        border-top-left-radius: var(--br_15);
        border-bottom-left-radius: var(--br_15);
        overflow: hidden;
        flex-direction: column;
    }

    #m_gnb_panel.open {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    #m_gnb_panel .m_gnb_top {
        min-height: 76px;
        padding-top: 0;
        padding-bottom: 0;
        background: var(--point_lighter);
        border-bottom: 1px solid rgba(var(--point_rgb), 0.08);
        flex-shrink: 0;
    }

    #m_gnb_panel .m_gnb_top strong {
        font-size: var(--fs_18);
        letter-spacing: 0.04em;
        color: var(--point2);
    }

    #m_gnb_panel .m_gnb_action_group {
        gap: 10px !important;
    }

    /* 패널 안 전화 버튼 : 텍스트 버전, 높이 40 */
    #m_gnb_panel .m_tel_btn {
        min-height: 40px;
        height: 40px;
        padding: 0 14px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        background: var(--point);
        color: var(--gray_f);
        border: 1px solid rgba(var(--point_rgb), 0.15);
        box-shadow: 0 6px 16px rgba(var(--point_rgb), 0.18);
        transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    }

    #m_gnb_panel .m_tel_btn:active {
        transform: scale(0.97);
    }

    #m_gnb_panel .m_tel_btn img {
        height: 18px;
        width: auto;
        display: block;
        filter: brightness(0) invert(1);
    }

    #m_gnb_panel .m_tel_btn span {
        display: inline-block;
        font-size: var(--fs_16);
        font-weight: 700;
        line-height: 1;
        color: var(--gray_f);
        white-space: nowrap;
    }

    /* 패널 닫기 버튼도 40x40 */
    #m_gnb_panel .m_menu_close {
        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;
        position: relative;
        border: 1px solid rgba(var(--point_rgb), 0.14);
        border-radius: 50%;
        background: var(--gray_f);
        padding: 0;
        cursor: pointer;
        appearance: none;
        -webkit-appearance: none;
    }

    #m_gnb_panel .m_menu_close span {
        position: absolute;
        top: 50%;
        left: 50%;
        width: 20px;
        height: 2px;
        border-radius: 999px;
        background: var(--point2);
    }

    #m_gnb_panel .m_menu_close span:nth-child(1) {
        transform: translate(-50%, -50%) rotate(45deg);
    }

    #m_gnb_panel .m_menu_close span:nth-child(2) {
        transform: translate(-50%, -50%) rotate(-45deg);
    }

    #m_gnb_panel .m_menu_list {
        flex: 1;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        padding: 10px 0 max(20px, env(safe-area-inset-bottom));
        margin: 0;
    }

    #m_gnb_panel .m_menu_list li {
        list-style: none;
    }

    #m_gnb_panel .m_menu_list .m_d1 {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
        padding: 18px 20px;
        color: var(--gray_2);
        font-weight: 600;
        font-size: 16px;
        border-bottom: 1px solid rgba(var(--point_rgb), 0.06);
        transition: background 0.2s ease, color 0.2s ease, padding 0.2s ease;
    }

    #m_gnb_panel .m_menu_list .m_d1 i {
        font-size: 13px;
        color: var(--gray_9);
        transition: transform 0.2s ease, color 0.2s ease;
    }

    #m_gnb_panel .m_menu_list .m_d1:hover,
    #m_gnb_panel .m_menu_list .m_d1:active,
    #m_gnb_panel .m_menu_list li.is-active .m_d1,
    #m_gnb_panel .m_menu_list .m_d1.is-active,
    #m_gnb_panel .m_menu_list .m_d1[aria-current="page"] {
        background: var(--point_lighter);
        color: var(--point);
        padding-left: 24px;
    }

    #m_gnb_panel .m_menu_list .m_d1:hover i,
    #m_gnb_panel .m_menu_list .m_d1:active i,
    #m_gnb_panel .m_menu_list li.is-active .m_d1 i,
    #m_gnb_panel .m_menu_list .m_d1.is-active i,
    #m_gnb_panel .m_menu_list .m_d1[aria-current="page"] i {
        color: var(--point);
        transform: translateX(3px);
    }
}

@media screen and (max-width: 540px) {
    #header .m_nav .logo a img {
        height: 20px;
    }

    #m_gnb_panel .m_tel_btn {
        padding: 0 12px;
    }

    #m_gnb_panel .m_tel_btn span {
        font-size: var(--fs_15);
    }
}

@media screen and (max-width: 430px) {
    #header .m_nav .logo a img {
        height: 18px;
    }

    #m_gnb_panel .m_tel_btn {
        padding: 0 10px;
    }

    #m_gnb_panel .m_tel_btn span {
        font-size: 14px;
    }
}

/* --- 모션 최소화 --- */
@media (prefers-reduced-motion: reduce) {
    #header,
    #header .pc_header,
    #header .pc_header_top,
    #header .pc_header_top .logo a img,
    #header .pc_gnb_list,
    #header .pc_gnb_list .d1,
    #header .top_tel,
    #header .top_tel img,
    #header .m_nav,
    #header .m_nav .logo img,
    #header .m_tel_btn,
    #m_gnb_panel .m_tel_btn,
    #header .m_menu_btn,
    #header .m_menu_btn span,
    #m_gnb_panel,
    #m_gnb_panel .m_menu_list .m_d1,
    #m_gnb_panel .m_menu_list .m_d1 i,
    #m_gnb_panel .m_menu_close,
    .m_dim {
        transition: none !important;
    }
}