/* ============================================================
   공통 헤더 (2026-08-03 XRPFLOW 시안)
   화이트 바 + 중앙 블랙 필(pill) 메뉴 + 우측 로그인/회원가입.
   마크업(head.php)은 기존 구조(clone-*)를 유지하고 스타일만 교체.
   ============================================================ */
.clone-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 9999;
    height: 72px;
    background: #fff;
    color: #161616;
    border-bottom: 1px solid #e6e6e6;
    font-family: "Pretendard Variable", Pretendard, Inter, "Noto Sans KR", Arial, sans-serif;
}

.clone-nav {
    max-width: 1560px;
    height: 100%;
    margin: auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    gap: 30px;
}

.clone-logo {
    display: flex;
    align-items: center;
    flex: none;
}

.clone-logo img {
    width: 132px;
    height: auto;
}

/* 중앙 블랙 필 메뉴 */
.clone-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    height: 50px;
    margin: 0 auto;
    padding: 0 14px;
    background: #111;
    border-radius: 999px;
}

.clone-links>a,
.clone-drop>button {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 17px;
    border: 0;
    background: none;
    color: #fff;
    font-family: inherit;
    font-weight: 600;
    font-size: 14.5px;
    white-space: nowrap;
    text-decoration: none;
    cursor: pointer;
    transition: opacity .15s;
}

.clone-links>a:hover,
.clone-drop>button:hover,
.clone-drop:hover>button,
.clone-links>a.active,
.clone-drop.active>button {
    color: #eb2323;
}

.clone-drop {
    position: relative;
    height: 100%;
}

.clone-drop>button {
    gap: 5px;
}

/* 드롭다운: 다크 패널 + 상단 레드 영문 라벨 (시안) */
.clone-menu {
    position: absolute;
    top: 58px;
    left: 50%;
    transform: translate(-50%, 7px);
    width: 244px;
    padding: 14px;
    background: #1b1b1d;
    color: #fff;
    border: 0;
    border-radius: 18px;
    box-shadow: 0 22px 50px #00000038;
    opacity: 0;
    visibility: hidden;
    transition: opacity .16s, transform .16s, visibility .16s;
}

.clone-menu-label {
    display: block;
    padding: 4px 12px 14px;
    margin-bottom: 10px;
    border-bottom: 1px solid #ffffff22;
    color: #eb2323;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.clone-menu a {
    display: block;
    padding: 13px 14px;
    border-radius: 10px;
    color: #fff !important;
    font-family: inherit;
    font-weight: 600;
    font-size: 14.5px;
    text-decoration: none;
}

.clone-menu a:hover,
.clone-menu a:focus,
.clone-menu a.active {
    background: #2f2f32;
    color: #fff !important;
}

.clone-drop:hover .clone-menu {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0);
}

/* 우측 계정 영역 */
.clone-account {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 10px;
    flex: none;
}

.clone-account>a {
    display: flex;
    align-items: center;
    color: #161616;
    font-family: inherit;
    font-weight: 700;
    font-size: 14.5px;
    white-space: nowrap;
    text-decoration: none;
}

.clone-account .clone-name {
    padding-right: 2px;
}

/* 로그인: 흰 필 + 보더 */
.clone-account .clone-login-link {
    height: 46px;
    padding: 0 26px;
    border: 1px solid #dcdcdc;
    border-radius: 999px;
    transition: border-color .15s;
}

.clone-account .clone-login-link:hover {
    border-color: #161616;
}

.clone-account .clone-pill {
    height: 46px;
    border-radius: 999px;
    padding: 0 24px;
    border: 1px solid #dcdcdc;
}

/* 회원가입: 블랙 필 */
.clone-account .clone-pill--primary {
    background: #111;
    border-color: #111;
    color: #fff;
    font-weight: 700;
    transition: opacity .15s;
}

.clone-account .clone-pill--primary:hover {
    opacity: .85;
    color: #fff;
}

.desktop-logout {
    color: #8a8a8a !important;
}

.clone-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    background: none;
    color: #161616;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
}

.mobile-only,
.clone-mobile-panel {
    display: none;
}

@media(max-width:1180px) {
    .clone-links>a,
    .clone-drop>button {
        padding: 0 12px;
        font-size: 13.5px;
    }
    .clone-logo img {
        width: 112px;
    }
}

@media(max-width:980px) {
    .clone-header {
        height: 56px;
    }

    .clone-nav {
        padding: 0 16px;
        gap: 8px;
    }

    .clone-logo img {
        width: 108px;
    }

    .clone-links {
        display: none;
    }

    .clone-account {
        margin-left: auto;
        gap: 8px;
    }

    .clone-account>a {
        display: none;
    }

    .clone-account .mobile-only {
        display: flex;
    }

    /* 비로그인: 모바일에서도 로그인 텍스트 노출 (시안) */
    .clone-account .clone-login-link {
        display: flex;
        height: auto;
        padding: 0 6px;
        border: 0;
        font-size: 14px;
        color: #161616;
    }

    .clone-account .clone-pill {
        height: 40px;
        min-width: 51px;
        justify-content: center;
        padding: 0 18px;
        font-size: 13.5px;
    }

    .clone-toggle {
        display: block;
    }

    .clone-toggle .close-mark {
        display: none;
    }

    .clone-header.menu-open .clone-toggle .menu-mark {
        display: none;
    }

    .clone-header.menu-open .clone-toggle .close-mark {
        display: inline;
    }

    /* 메뉴 열림: 헤더에는 로고 + X 만 남김 (시안) */
    .clone-header.menu-open .clone-account>a {
        display: none !important;
    }

    /* 모바일 전체 메뉴: 화이트 패널 (2026-08-03 시안) */
    .clone-mobile-panel {
        display: none;
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        bottom: 0;
        background: #fff;
        color: #161616;
        padding: 0 20px 40px;
        overflow-y: auto;
        border-top: 1px solid #ececec;
    }

    .clone-header.menu-open .clone-mobile-panel {
        display: block;
    }

    /* 번호 목록 (01~) — 하위 없는 상위 메뉴 */
    .clone-mobile-panel .m-item {
        display: flex;
        align-items: center;
        gap: 16px;
        padding: 20px 2px;
        color: #161616;
        text-decoration: none;
        border-bottom: 1px solid #ececec;
    }

    .clone-mobile-panel .m-item small {
        color: #9a9a9a;
        font-size: 12px;
        font-weight: 600;
    }

    .clone-mobile-panel .m-item b {
        font-size: 17px;
        font-weight: 800;
        letter-spacing: -.02em;
    }

    .clone-mobile-panel .m-item i {
        margin-left: auto;
        font-style: normal;
        font-size: 16px;
        line-height: 1;
    }

    .clone-mobile-panel .m-item.active b {
        color: #eb2323;
    }

    /* 그룹 아코디언 (GUIDE / INFO) */
    .clone-mobile-panel .m-group {
        border-bottom: 1px solid #ececec;
    }

    .clone-mobile-panel .m-group:first-of-type {
        margin-top: 12px;
        border-top: 1px solid #d9d9d9;
    }

    .clone-mobile-panel .m-group-toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 18px 2px;
        border: 0;
        background: none;
        color: #eb2323;
        font-family: inherit;
        font-size: 12.5px;
        font-weight: 800;
        letter-spacing: .08em;
        text-transform: uppercase;
        cursor: pointer;
    }

    .clone-mobile-panel .m-group-toggle i {
        color: #9a9a9a;
        font-style: normal;
        font-size: 12px;
        transition: transform .18s;
    }

    .clone-mobile-panel .m-group.open .m-group-toggle i {
        transform: rotate(180deg);
    }

    .clone-mobile-panel .m-group-body {
        display: none;
        grid-template-columns: 1fr 1fr;
        gap: 6px 16px;
        padding: 0 2px 20px;
    }

    .clone-mobile-panel .m-group.open .m-group-body {
        display: grid;
    }

    .clone-mobile-panel .m-group-body a {
        padding: 10px 0;
        color: #161616;
        font-size: 14.5px;
        font-weight: 500;
        text-decoration: none;
    }

    .clone-mobile-panel .m-group-body a.active {
        color: #eb2323;
    }

    /* 하단 버튼: 회원가입(블랙) / 로그인(테두리) */
    .clone-mobile-panel .mobile-bottom {
        margin-top: 34px;
        display: grid;
        gap: 12px;
    }

    .clone-mobile-panel .m-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 52px;
        font-size: 15px;
        font-weight: 700;
        text-decoration: none;
    }

    .clone-mobile-panel .m-btn--black {
        background: #111;
        color: #fff;
    }

    .clone-mobile-panel .m-btn--line {
        border: 1px solid #d9d9d9;
        color: #161616;
    }
}
