/* ==================================================
   ACE Component : Floating Label Field
   login / find / signup / verify 공통 사용
   ================================================== */
/* ===============================
   Autofill Fix (Common)
   =============================== */
input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: #000;
}

input:not(:placeholder-shown) + label {
  /* floating */
}
/* ===============================
   Floating Label - Core
   =============================== */
.m-field {
  position: relative;
  margin: 24px 0;
}

.service-page .m-field {
  position: relative;
  margin: 24px 16px;
}

.m-field input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 70px 12px 0; /* 우측 유틸 버튼 기본 공간 */
  height: 48px;
  font-size: 16px;
  border: none;
  border-bottom: 1px solid #ddd;
  outline: none;
  background: transparent;
  color: #111;
}

/* label */
.m-field label {
  position: absolute;
  left: 0;
  top: 14px;
  font-size: 15px;
  color: #aaa;
  pointer-events: none;
  transition: all 0.2s ease;
}

/* floating 상태 */
.m-field.active label,
.m-field.filled label {
  top: -6px;
  font-size: 12px;
  color: #333;
}

/* focus bar */
.m-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: #1e73be;
  transition: width 0.25s;
}

.m-field input:focus ~ .m-bar {
  width: 100%;
}

/* ===============================
   Input Utility Button (clear etc)
   =============================== */
.input-btn {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: #1e73be;
  color: #fff;
  font-size: 12px;
  cursor: pointer;

  display: none;              /* 기본 숨김 */
  align-items: center;
  justify-content: center;
  line-height: 1;
  text-align: center;

  -webkit-tap-highlight-color: transparent;
}

/* 값이 있을 때 노출 */
.m-field.filled .input-btn {
  display: inline-flex;
  pointer-events: auto;
}


/* ===============================
   Password Toggle (optional)
   =============================== */
.pw-toggle {
  position: absolute;
  right: 44px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  border: none;
  background: none;
  cursor: pointer;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

/* 기본 : 비밀번호 숨김 */
.pw-toggle::before {
  content: '👁';
  font-size: 18px;
  line-height: 1;
  display: block;
}

/* 보이는 상태 */
.pw-toggle.show::before {
  content: '🙈';
}

/* ===============================
   Phone Field (verify type)
   =============================== */
.phone-field {
  position: relative;
}

/* 인증 버튼이 있을 때 clear 버튼 위치 조정 */
.phone-field .input-btn {
  right: 100px;
}

/* ===============================
   Verify Button
   =============================== */
.verify-btn {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 26px;
  padding: 0 14px;
  border-radius: 18px;
  border: 2px solid #aaa;   /* 기본 비활성 */
  background: #fff;
  color: #aaa;
  font-size: 12px;
  white-space: nowrap;
  line-height: 22px;
  cursor: not-allowed;
  transition: all 0.25s ease;
}

/* 활성 상태 */
.verify-btn.active {
  border-color: #1e73be;
  color: #1e73be;
  cursor: pointer;
  background: #fff;
}

.limit-text { font-size:14px; color:#ccc; } 

/* ===============================
   Mobile Adjustment
   =============================== */
@media (max-width: 480px) {
  .verify-btn {
    min-width: 85px;
    text-align: center;
    white-space: nowrap;
  }
}

/* ================= 이미지 체크박스 ================= */
.checkbox-label.v-only .checkbox-custom {
  width: 16px;
  height: 12px;
  margin-left: 10px;
  display: inline-block;
  vertical-align: middle;
  background-image: url('../ace-img/icon/ico_chk_s_off.png'); /* 체크 안 됨 이미지 */
  background-size: cover;
  background-position: center;
  border: none;
}

.id-check-page .checkbox-label.v-only .checkbox-custom {
  margin-left: 20px;
}

.checkbox-label.v-only input[type="checkbox"]:checked + .checkbox-custom {
  background-image: url('../ace-img/icon/ico_chk_s_on.png');
}


.checkbox-label.v-only input[type="checkbox"] {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
}


/* =========================================================
   메시지 팝업 (공통)
========================================================= */

/* 전체 영역 */
.message-popup { position:fixed; inset:0; z-index:9999; display:none; }
.message-popup.active { display:block; }

/* dim */
.message-popup .term-dim { position:absolute; inset:0; background:rgba(0,0,0,.45); }

/* 박스 */
.message-popup .term-box {
  position:absolute; left:50%; top:50%; transform:translate(-50%,-50%);
  width:90%; max-width:360px; min-height:120px;
  background:#fff; border-radius:12px;
  display:flex; flex-direction:column; overflow:hidden;
  box-shadow:0 4px 16px rgba(0,0,0,.15);
}

/* header (가로 정렬) */
.message-popup .term-header {
  flex:0 0 auto; padding:16px; border-bottom:1px solid #eee;
  display:flex; align-items:center; justify-content:space-between;
  font-size:16px; font-weight:500;
}
.message-popup .term-close { background:none; border:0; font-size:18px; cursor:pointer; }

/* content */
.message-popup .term-content {
  flex:1 1 auto; padding:16px;
  font-size:14px; line-height:1.6; color:#333; text-align:center;
  overflow-y:auto; -webkit-overflow-scrolling:touch;
}

/* footer */
.message-popup .term-footer {
  flex:0 0 auto; padding:16px; border-top:1px solid #eee;
  background:#fff; border-bottom-left-radius:12px; border-bottom-right-radius:12px;
}

/* 확인 버튼 */
.message-popup .term-confirm {
  width:100%; height:48px; border:0; border-radius:8px;
  background:var(--main-blue); color:#fff; font-size:15px; font-weight:600;
  cursor:pointer; transition:background .2s ease;
}
.message-popup .term-confirm:active { background:var(--main-blue); }

/* 모바일 */
@media (max-width:480px) {
  .message-popup .term-box { max-width:320px; }
  .message-popup .term-header,
  .message-popup .term-content,
  .message-popup .term-footer { padding:12px; }
}

/* button */
.btn-primary { 
  width: 100%;
  padding: 14px;
  background:var(--main-blue);
  color: #fff;
  font-size: 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-primary:hover,
.btn-primary:active {
  opacity: 0.85;
}

/* spacing utilities */
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }

/*
.signup-btn { width:100%; padding:14px; margin:20px 0; font-size:16px; border:none; border-radius:var(--button-radius);
  cursor:pointer; transition:background 0.2s ease; color:#fff; background:var(--main-blue); }

.signup-btn-wrap {
  position: fixed;       
  bottom: 60px;         
  left: 0;
  width: 100%;           
  display: flex;
  justify-content: center; 
  padding: 0 20px;       
  box-sizing: border-box;
  z-index: 1000;         
}
*/

.signup-btn-wrap {
  position: fixed;
  left: 0;
  bottom: 0;          /* 하단 여백 */
  width: 100%;           /* 화면 전체 폭 */
  height: 64px;
  display: flex;
  align-items: center; /* 수직 중앙 */
  justify-content: center;
  padding: 0 16px;       /* 좌우 여백 */
  box-sizing: border-box;
  z-index: 99;         
}

.signup-btn { flex:1; box-sizing: border-box; width:100%;
	height:45px;  line-height: 45px; padding: 0;        
  text-align: center; font-size:16px; border:none; border-radius:var(--button-radius);
  cursor:pointer; transition:background 0.2s ease; color:#fff; background:var(--main-blue); }


.signup-btn.inactive{ background:#aaa; cursor:default; pointer-events:none; }
.signup-btn:hover:not(.inactive){ background:var(--main-blue); }


/* ===============================
   Bottom Fixed Form Buttons
================================ */
.form-buttons {
    position: fixed;       
    left: 0;
	bottom: 0;          /* 하단 여백 */
    width: 100%;           /* 화면 전체 폭 */
    height: 64px;
	display: flex;
	align-items: center; /* 수직 중앙 */
	justify-content: center;
    gap: 12px;
    padding: 0 16px;       /* 좌우 여백 */
    box-sizing: border-box;
    z-index: 99;         /* 다른 요소 위 */
}

.btn-confirm,
.btn-save {
    flex: 1;
	box-sizing: border-box;
	height:45px;
    padding: 10px 0;
    border: none;
    border-radius:var(--button-radius);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
}

.btn-confirm {
    background-color: #ddd;
    color: #111;
}

.btn-save {
    background-color: var(--main-blue);
    color: #fff;
}

