/*-----------------공통-----------------*/
input::placeholder {color: var(--text-light); }
.member-login-wrap {max-width: 400px;margin: 50px auto;}
.member-join-wrap {max-width: 600px;margin: 50px auto;}
/* layout legacy: div.id_center { display:inline-block } → margin:auto 좌우 무효, 가운데 정렬 깨짐 */
div.id_center.member-join-wrap {display: block;}
@media (max-width: 800px) {
    .member-join-wrap {margin : 20px auto;}
}

/*-----------------로그인-----------------*/

/* 헤더 영역 */
.member-login-wrap .login-header {text-align: center;margin-bottom: 30px;}
.member-login-wrap .login-header h2 {font-size: 28px;font-weight: 600;margin-bottom: 15px;}
.member-login-wrap .login-header p {font-size: 14px;color: var(--text-sub);}
/* 폼 영역 - 입력칸 */
.member-login-wrap .input-box {margin-bottom: 10px;position: relative;}
.member-login-wrap .input-box input {
    width: 100%;
    height: 50px;
    padding: 0 15px 0 50px;
    border: 1px solid var(--border-light);
    box-sizing: border-box;
    font-size: 14px;
    border-radius: 8px;
    background-color: #fafafa;
}
.member-login-wrap .input-box input:focus {border-color: var(--theme-primary);outline: none;}
/* 텍스트 아이콘 스타일  */
.member-login-wrap .input-box .input-icon-label {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    color: var(--text-light);
}
/* 로그인 버튼 */
.member-login-wrap .btn-submit-login {
    width: 100%;
    height: 50px;
    background-color: var(--theme-primary);
    color: var(--text-white);
    font-size: 16px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}
/* 유틸리티 행 (아이디 저장, 회원가입, ID/PW찾기) */
.member-login-wrap .login-util-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0 30px;
    font-size: 13px;
}
.member-login-wrap .save-id-label {display: flex;align-items: center;}
.member-login-wrap .save-id-label input[type="checkbox"] {margin-right: 5px;}
.member-login-wrap .save-id-label span {color: var(--text-sub);}
.member-login-wrap .login-links-row {display: flex;gap: 15px;}
.member-login-wrap .login-links-row a {color: var(--text-sub);text-decoration: none;}
/* SNS 로그인 영역 */
.member-sns-divider {display: flex;align-items: center;gap: 12px;margin: 20px 0 15px;  font-size: 12px;}
.member-sns-divider::before,.member-sns-divider::after {content: '';flex: 1;height: 1px;background: var(--border-light);}
.member-login-wrap .sns-login-title {font-size: 14px;color: var(--text-sub);margin-bottom: 20px;position: relative;}

.sns-login-box {display: flex;gap: 10px;margin-bottom: 30px;}
/* SNS 로그인 버튼 */
.member-login-wrap .btn-sns, .sns-link-box .btn-sns {
    flex: 1;
    height: 50px;
    margin-bottom: 0;
    font-size: 14px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 0 10px;
}
.member-login-wrap .btn-sns.naver, .sns-link-box .btn-sns.naver{background-color: #03A94D;color: var(--bg-white);}
.member-login-wrap .btn-sns.kakao, .sns-link-box .btn-sns.kakao{background-color: #FEE500;color: #000000;}
.member-login-wrap .btn-sns .btn-text, .sns-link-box .btn-sns .btn-text {padding: 8px;}

.member-login-wrap .btn-sns .recent-login-text {
    position: absolute;
    bottom: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    color: #d9534f;
    font-size: 12px;
    white-space: nowrap;
    pointer-events: none;
}
.member-login-wrap .btn-sns.recent .recent-login-text::before{content: "↑ 최근 로그인했어요"; }


/*----------------회원가입 1단계-------------- */

/* 상단 단계 표시 (Step) */
.join-step-area {display: flex;justify-content: center;align-items: center;margin-bottom: 40px;}
.join-step-area .step {font-size: 14px;color: var(--text-light);display: flex;align-items: center;font-weight: bold;}
.join-step-area .step span {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 36px;
    text-align: center;
    border-radius: 50%;
    border: 1px solid var(--border-medium);
    margin-right: 6px;
    font-size: 20px;
    box-sizing: border-box;
}
.join-step-area .step.active {color: var(--theme-primary));}
.join-step-area .step.active span {background-color: var(--theme-primary);color: var(--text-white);}
.join-step-area .step-arrow {color: var(--border-medium);}
@media (min-width:800px) {
    .join-step-area .step-arrow {margin: 0 15px;}
}

/* 헤더 공통 적용 */
.member-join-wrap .login-header {text-align: center;margin-bottom: 30px;}
.member-join-wrap .login-header h2 {font-size: 28px;font-weight: 600;margin-bottom: 15px;}
.member-join-wrap .login-header p {font-size: 14px;color: var(--text-sub);}

/* 약관 리스트 래퍼 */
.terms-list-wrap {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    background: var(--bg-white);
    margin-bottom: 25px;
}
.all-agree-item {
    padding-bottom: 15px;
    border-bottom: 1px solid var(--bg-gray-300);
    margin-bottom: 15px;
}
.terms-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.terms-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

/* SMS, Email 하위 요소 컨테이너 */
.terms-list li.sub-terms-li {
    justify-content: flex-start;
    padding-left: 30px;
    gap: 20px;
    margin-top: -5px;
    margin-bottom: 15px;
}
/* 팝업 열기 버튼(화살표) */
.btn-terms-pop {
    background: none;
    border: none;
    font-size: 16px;
    color: #999;
    cursor: pointer;
    padding: 0 5px;
}

/* 커스텀 체크박스 */
.custom-chk {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}
.custom-chk input[type="checkbox"] {
    display: none;
}
.custom-chk .chk-mark {
    width: 22px;
    height: 22px;
    border: 1px solid var(--border-medium);
    border-radius: 50%;
    margin-right: 10px;
    position: relative;
    background-color: var(--bg-white);
    transition: all 0.2s;
}
.custom-chk input[type="checkbox"]:checked + .chk-mark {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
}
.custom-chk input[type="checkbox"]:checked + .chk-mark::after {
    content: '';
    position: absolute;
    left: 7px;
    top: 4px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
/* 비활성화 상태 스타일 */
.custom-chk input[type="checkbox"]:disabled + .chk-mark {background-color: #f0f0f0;border-color: #ddd;}
.custom-chk input[type="checkbox"]:disabled ~ span {color: #aaa;}
.custom-chk strong {font-size: 16px;font-weight: 700;}
.custom-chk span {font-size: 15px;color: #333;}

/* 다음 버튼 */
.btn-submit-join {
    width: 100%;
    height: 55px;
    background-color: var(--theme-primary);
    color: var(--bg-white);
    font-size: 18px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}
/* 비활성화된 다음 버튼 스타일 */
.btn-submit-join:disabled {
    background-color: #cccccc !important;
    cursor: not-allowed;
    color: #888888;
}

/* ---------------- 팝업 스타일 ---------------- */
.layer-popup-bg {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}
.layer-popup-box {
    background: var(--bg-white);
    width: 90%;
    max-width: 800px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}
.pop-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid var(--bg-gray-300);
}
.pop-header h3 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}
.btn-pop-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--text-sub);
}
.pop-body {
    padding: 20px;
    max-height: 600px;
    overflow-y: auto;
    font-size: 13px;
    color: var(--text-sub);
    line-height: 1.6;
}
.terms-info-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    text-align: center;
}
.terms-info-table th, .terms-info-table td {
    border: 1px solid #ddd;
    padding: 8px 5px;
}
.terms-info-table th { background-color: #f7f7f7; }

/* ---------------- 개인정보처리방침 ---------------- */
.privacy-wrap {line-height: 1.6;color: #333;max-width: 1200px;margin: 0 auto;padding: 20px 20px 6%;box-sizing: border-box;}
.privacy-wrap h1 {font-size: 24px;border-bottom: 2px solid #333;padding-bottom: 10px;margin-top: 30px;color: #333; margin-bottom: 16px;}
.privacy-wrap h2 {font-size: 18px;background-color: #f9f9f9; padding: 10px;border-left: 5px solid #7f1a21;margin-top: 25px; margin-bottom: 15px;}
.privacy-wrap table {width: 100%;border-collapse: collapse;margin: 10px 0;font-size: 14px;}
.privacy-wrap th, .privacy-wrap td {border: 1px solid #ddd;padding: 8px;text-align: left;white-space: inherit;word-break: break-word;}
.privacy-wrap th {background-color: #f9f9f9;font-weight: bold;text-align: center;}
.privacy-wrap ul {list-style-type: disc; padding-left: 20px;margin: 0 0 15px 10px;}
.privacy-wrap ol {list-style-type: decimal;padding-left: 20px;margin: 0 0 15px 10px;}
.privacy-wrap li {display: list-item; list-style: inherit;margin-bottom: 5px;}
.privacy-wrap p {margin: 0 0 15px 10px;}
.privacy-wrap .toc {background-color: var(--bg-white)afa; padding: 15px;border: 1px solid #ebd0d2;border-radius: 5px;}
.privacy-wrap .toc a {text-decoration: none;color: #333;display: block;margin: 3px 0;}
.privacy-wrap .toc a:hover {text-decoration: underline;color: #7f1a21; font-weight: bold;}
.privacy-wrap .emphasis {font-weight: bold;color: #d9534f;}
.privacy-wrap .history-link {color: var(--text-sub);font-size: 0.9em;text-decoration: none;display: inline-block;margin-top: 5px;}
.privacy-wrap .history-link:hover {text-decoration: underline;color: #7f1a21;}

/* ---------------- 회원가입 2단계 - 본인인증 전용 스타일 ---------------- */
.auth-section-wrap {margin-bottom: 25px;}
.input-btn-box {display: flex;gap: 10px;margin-bottom: 15px;}
.input-btn-box input {
    flex: 1;
    height: 50px;
    padding: 0 15px;
    border: 1px solid var(--border-medium);
    border-radius: 8px;
    background-color: #fafafa;
    font-size: 14px;
    box-sizing: border-box;
}
.input-btn-box input:focus {
    border-color: var(--theme-primary);
    outline: none;
}
/* 인증 / 확인 버튼 */
.input-btn-box .btn-verify,
.input-btn-box .btn-confirm {
    width: 100px;
    height: 50px;
    background-color: #666;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s;
}
.input-btn-box .btn-verify:hover,
.input-btn-box .btn-confirm:hover {
    background-color: #333;
}
/* 인증번호 입력 타이머 포함 컨테이너 */
.input-with-timer {position: relative;flex: 1;}
.input-with-timer input {width: 100%;}
.input-with-timer .auth-timer {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #d9534f;
    font-size: 14px;
    font-weight: bold;
}
/* 인증 메시지 텍스트 */
.auth-msg {
    font-size: 13px;
    color: var(--theme-primary);
    margin-bottom: 10px;
    line-height: 1.5;
    font-weight: bold;
}
/* 인증 방법 전환 링크 */
.auth-toggle-link {text-align: center;margin-top: 25px;}
.auth-toggle-link a {color: var(--text-sub);text-decoration: underline;}


/* ---------------- 회원가입 3단계 - 회원정보 입력 폼 스타일 ---------------- */
.info-form-wrap {padding: 0 10px;}
.ul-field { position: relative; margin-bottom: 35px; } /* 에러 메시지 공간을 위해 하단 마진 증가 */
.ul-field input {
    width: 100%; padding: 10px 0; background: transparent; border: none;
    border-bottom: 1.5px solid var(--border-medium, #ccc); font-size: 15px; color: #333;
    outline: none; transition: border-color 0.2s; border-radius: 0; box-shadow: none;
}
.ul-field input::placeholder { color: transparent; }
.ul-field input:focus { border-color: transparent; }

.ul-field label {
    position: absolute; left: 0; top: 10px; font-size: 14px; color: var(--text-sub, #666);
    pointer-events: none; transition: all 0.25s cubic-bezier(0.2, 0, 0, 1);
}
.ul-field label .req { color: #d9534f; margin-left: 2px; }
/* 입력 시 라벨 위로 이동 */
.ul-field input:focus + label,
.ul-field input:not(:placeholder-shown) + label,
.ul-field.has-val label {
    top: -16px; font-size: 11px; color: var(--theme-primary, #0056b3); font-weight: 600;
}
.ul-line { position: absolute; bottom: 0; left: 0; width: 100%; height: 1.5px; background: transparent; z-index: 1;}
.ul-line::after {
    content: ''; position: absolute; bottom: 0; left: 50%; width: 0; height: 2px;
    background: var(--theme-primary, #0056b3); transition: width 0.3s ease, left 0.3s ease;
}
.ul-field:focus-within .ul-line::after { left: 0; width: 100%; }
.ul-clear {
    position: absolute; right: 0; top: 6px; width: 26px; height: 26px;
    background: #e9ecef; border: none; border-radius: 50%; font-size: 12px;
    color: #666; cursor: pointer; display: none; align-items: center; justify-content: center; z-index: 2;
}
.ul-field.has-val .ul-clear { display: flex; }
/* ---------------- Masked Input Hint ---------------- */
.ul-mask-hint {
    position: absolute; right: 0; top: 12px; font-size: 12px; color: #adb5bd;
    font-family: 'Malgun Gothic', monospace; pointer-events: none; opacity: 0; transition: opacity 0.2s;
}
.ul-field:focus-within .ul-mask-hint { opacity: 1; }
.ul-field.has-val .ul-mask-hint { display: none; }
.btn-verify-inline {
    position: absolute; right: 0; top: 0; height: 34px; padding: 0 12px;
    background: #555; color: #fff; border: none; border-radius: 4px; font-size: 12px; cursor: pointer; z-index: 2;
}
/* 비밀번호 보기/숨김 + 클리어 버튼 (memberRegistInfo02 등 ul-field.has-pw-toggle) */
.ul-field.has-pw-toggle input {
    padding-right: 88px;
}
.ul-field.has-pw-toggle .ul-clear {
    right: 0;
}
.ul-toggle-pw {
    position: absolute;
    right: 34px;
    top: 6px;
    min-width: 36px;
    padding: 4px 2px;
    background: transparent;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    z-index: 2;
    line-height: 1.2;
    text-decoration: underline;
}
.ul-toggle-pw:hover {
    color: var(--theme-primary, #0056b3);
}
.ul-toggle-pw.is-open {
    font-weight: 600;
}
.ul-field .info-field-hint {
    font-size: 12px;
    color: #888;
    margin: 8px 0 0;
    line-height: 1.4;
}
.ul-field.has-pw-toggle#ulf-pw {
    margin-bottom: 48px;
}
/* ---------------- Inline Validation 상태 ---------------- */
/* 언더라인 바로 밑에 위치하도록 absolute 설정 */
.ul-err-msg {
    position: absolute; left: 0; top: 100%;
    font-size: 11.5px; color: #d9534f; display: none;
}
.ul-field.error .ul-err-msg { display: block; }
.ul-field.error input, .ul-field.error .bs-trigger { border-bottom-color: #d9534f; }
.ul-field.error .ul-line::after { background: #d9534f; width: 100%; left: 0;}
.ul-field.error label { color: #d9534f !important; }

.ul-field.valid input { border-bottom-color: #0ca678; }
.ul-field.valid .ul-line::after { background: #0ca678; width: 100%; left: 0;}
.ul-field.valid label { color: #0ca678 !important; }
/* 패스워드 강도 체크 UI (언더라인 바로 밑) */
.pw-strength { position: absolute; left: 0; top: 100%; display: none; width: 100%; }
.pw-strength.visible { display: block; }
.pw-rules { display: flex; gap: 15px; }
.pw-rule { font-size: 11px; color: #adb5bd; display: flex; align-items: center; gap: 4px; transition: color 0.2s; }
.pw-rule::before { content: '○'; font-size: 10px; }
.pw-rule.pass { color: #0ca678; }
.pw-rule.pass::before { content: '✓'; font-weight: bold;}
.pw-rule.fail { color: #d9534f; }
.pw-rule.fail::before { content: '✕'; font-weight: bold;}

/* ---------------- Bottom Sheet Select 및 Floating 연동 ---------------- */
.bs-field label { opacity: 0; } /* 초기엔 라벨 숨김 (버튼의 텍스트가 라벨역할) */
.bs-field.has-val label { opacity: 1; top: -16px; font-size: 11px; color: var(--theme-primary, #0056b3); font-weight: 600; }

.bs-trigger {
    display: flex; align-items: center; justify-content: space-between;
    width: 100%; padding: 10px 0; height: 42px;
    background: transparent; border: none; border-bottom: 1.5px solid var(--border-medium, #ccc);
    font-size: 15px; color: #999; cursor: pointer; text-align: left; transition: border-color 0.2s;
}
.ul-field.has-val .bs-trigger { color: #333; } /* 선택 후 텍스트 색상 진하게 */
.bs-trigger-arrow { font-size: 12px; color: #999; transition: transform 0.2s; }
.bs-trigger.open .bs-trigger-arrow { transform: rotate(180deg); }
.bs-trigger:focus { outline: none; }

.bs-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 1000;
    opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.bs-overlay.open { opacity: 1; pointer-events: auto; }

.bs-sheet {
    position: fixed; bottom: 0; left: 0; right: 0; background: #fff;
    border-radius: 20px 20px 0 0; box-shadow: 0 -4px 16px rgba(0,0,0,0.1); z-index: 1001;
    transform: translateY(100%); transition: transform 0.3s cubic-bezier(0.32,0.72,0,1);
    max-height: 75vh; display: flex; flex-direction: column;
}
.bs-sheet.open { transform: translateY(0); }
@media (min-width: 768px) {
    .bs-sheet {
        top: 50%; bottom: auto; left: 50%; right: auto;
        width: 100%; max-width: 420px;
        height: 600px; max-height: 80vh;
        border-radius: 12px;
        box-shadow: 0 10px 40px rgba(0,0,0,0.2);
        transform: translate(-50%, -40%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.3s cubic-bezier(0.32,0.72,0,1), opacity 0.3s ease;
    }
    .bs-sheet.open {
        transform: translate(-50%, -50%);
        opacity: 1;
        pointer-events: auto;
    }
    .bs-handle {
        /* PC 팝업에서는 드래그 핸들(상단 회색바)이 필요 없으므로 숨김 */
        display: none;
    }
    .bs-sheet-head {
        /* 핸들이 빠진 만큼 상단 여백을 살짝 보정 */
        padding-top: 20px;
    }
}

.bs-handle { width: 36px; height: 4px; background: #ddd; border-radius: 2px; margin: 12px auto 0; flex-shrink: 0;}
.bs-sheet-head { padding: 16px 20px 12px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #eee; flex-shrink: 0;}
.bs-sheet-title { font-size: 16px; font-weight: bold; color:#333; }
.bs-sheet-close { background: none; border: none; font-size: 18px; color: #999; cursor: pointer; }

/* 바텀시트 검색창 */
.bs-search-wrap { padding: 10px 20px; position: relative; flex-shrink: 0; border-bottom: 1px solid #f5f5f5;}
.bs-search {
    width: 100%; height: 40px; padding: 0 12px 0 36px; background: #f8f9fa;
    border: 1px solid #e0e0e0; border-radius: 8px; font-size: 14px; outline: none; transition: border-color 0.2s; box-sizing: border-box;
}
.bs-search:focus { border-color: var(--theme-primary, #0056b3); }
.bs-search-icon { position: absolute; left: 30px; top: 50%; transform: translateY(-50%); color: #999; pointer-events: none;}

.bs-list { overflow-y: auto; padding: 0 20px 30px; }
.bs-item {
    display: flex; justify-content: space-between; align-items: center;
    padding: 10px 5px; border-bottom: 1px solid #f5f5f5; font-size: 15px; cursor: pointer; transition: background 0.2s;
}
.bs-item:last-child { border-bottom: none; }
.bs-item:hover { background: #fafafa; }
.bs-item.active { color: var(--theme-primary, #0056b3); font-weight: bold; background: rgba(0,86,179,0.05); border-radius: 8px; border-bottom: none;}





/* ---------------- 가입 완료 화면 스타일 ---------------- */
.complete-header {
    text-align: center;
    margin-bottom: 40px;
}

.complete-icon {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: var(--theme-primary, #0056b3);
    color: #fff;
    margin-bottom: 20px;
}

.complete-header .sub-title {
    font-size: 14px;
    color: var(--theme-primary, #0056b3);
    margin-bottom: 10px;
}

.complete-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
}

.complete-header .desc {
    font-size: 15px;
    color: #666;
    line-height: 1.5;
}

/* SNS 연동 권유 박스 */
.sns-link-box {
    background-color: #f8f9fa;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 30px 20px;
    margin-bottom: 30px;
    text-align: center;
}

.sns-link-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
}