/* =========================================
   KSAP Premium Registration Page Styles
   ========================================= */

/* 1. 회원가입 폼 컨테이너 (카드 UI) */
.cosmosfarm-members-form.signup-form {
  max-width: 680px !important; /* 로그인보다 조금 더 넓게 */
  margin: 60px auto !important;
  padding: 3rem !important;
  background-color: #ffffff !important;
  border-radius: 16px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.1) !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  box-sizing: border-box !important;
}

/* 2. 타이틀 (Legend) */
.cosmosfarm-members-form.signup-form fieldset {
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

.cosmosfarm-members-form.signup-form legend {
  display: block !important;
  width: 100% !important;
  text-align: center !important;
  font-size: 2rem !important;
  font-weight: 800 !important;
  color: #1e3a8a !important; /* KSAP Navy */
  margin-bottom: 2.5rem !important;
  border-bottom: 2px solid #f1f5f9 !important;
  padding-bottom: 1.5rem !important;
}

/* 3. 입력 필드 레이블 */
.cosmosfarm-members-form.signup-form label.text {
  display: block !important;
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  margin-bottom: 0.5rem !important;
  margin-top: 1.5rem !important;
}

/* 필수 항목 별표 (*) 색상 */
.cosmosfarm-members-form.signup-form .req {
  color: #ef4444 !important;
  margin-left: 4px !important;
}

/* 4. 입력 필드 (Input) */
.cosmosfarm-members-form.signup-form input[type="text"],
.cosmosfarm-members-form.signup-form input[type="email"],
.cosmosfarm-members-form.signup-form input[type="password"] {
  width: 100% !important;
  height: 50px !important;
  padding: 0 15px !important;
  background-color: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  font-size: 1rem !important;
  color: #1e293b !important;
  box-sizing: border-box !important;
  transition: all 0.3s ease !important;
  box-shadow: none !important;
}

/* 포커스 효과 */
.cosmosfarm-members-form.signup-form input:focus {
  background-color: #ffffff !important;
  border-color: #2563eb !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1) !important;
}

/* div_text 여백 제거 */
.cosmosfarm-members-form.signup-form .div_text {
  margin: 0 !important;
  padding: 0 !important;
}

/* 4-0. 본인인증(인증 버튼) 정렬/사이즈 보정 */
.cosmosfarm-members-form.signup-form .add-buttons {
  display: flex !important;
  align-items: stretch !important;
  gap: 8px;
  width: 100%;
}

.cosmosfarm-members-form.signup-form .add-buttons > input[type="text"] {
  flex: 1 1 auto;
  min-width: 0;
  width: auto !important;
}

.cosmosfarm-members-form.signup-form .add-buttons-wrap {
  display: flex !important;
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: 72px !important;
  max-width: none !important;
  overflow: visible !important;
}

.cosmosfarm-members-form.signup-form .add-buttons-wrap button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 50px !important;
  width: auto !important;
  min-width: 72px !important;
  max-width: none !important;
  padding: 0 16px !important;
  border-radius: 8px !important;
  border: 1px solid #1d4ed8 !important;
  background-color: #2563eb !important;
  color: #ffffff !important;
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  white-space: nowrap;
  overflow: visible !important;
  cursor: pointer;
}

.cosmosfarm-members-form.signup-form .add-buttons-wrap button:hover {
  background-color: #1d4ed8 !important;
}

/* 4-1. 자동 인증 입력 항목 숨김 (생년월일, 휴대폰 번호) */
.cosmosfarm-members-form.signup-form label[for="birth_date"],
.cosmosfarm-members-form.signup-form label[for="billing_phone"],
.cosmosfarm-members-form.signup-form label[for="birth_date"] + .div_text,
.cosmosfarm-members-form.signup-form label[for="billing_phone"] + .div_text {
  display: none !important;
}

/* 5. 약관 동의 박스 (스크롤 가능하게) */
.cosmosfarm-members-form.signup-form .div_checkbox.agree {
  margin-top: 0.5rem !important;
  margin-bottom: 1rem !important;
}

.cosmosfarm-members-form.signup-form .policy_content {
  height: 150px !important;
  overflow-y: auto !important;
  background-color: #f9fafb !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 8px !important;
  padding: 1rem !important;
  font-size: 0.85rem !important;
  color: #64748b !important;
  line-height: 1.6 !important;
  margin-bottom: 0.5rem !important;
}

/* 약관 체크박스 라벨 */
.cosmosfarm-members-form.signup-form label.checkbox {
  display: block !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  margin-top: 2rem !important;
  margin-bottom: 0.5rem !important;
}

/* 동의 체크박스 및 텍스트 */
.cosmosfarm-members-form.signup-form .div_checkbox label {
  font-size: 0.95rem !important;
  color: #334155 !important;
  display: flex !important;
  align-items: center !important;
  cursor: pointer !important;
}

.cosmosfarm-members-form.signup-form input[type="checkbox"] {
  width: 18px !important;
  height: 18px !important;
  margin-right: 8px !important;
  accent-color: #2563eb !important;
}

/* 6. 회원가입 버튼 */
.cosmosfarm-members-form.signup-form .button_div {
  margin-top: 3rem !important;
  text-align: center !important;
}

.cosmosfarm-members-form.signup-form input[type="submit"] {
  width: 100% !important;
  height: 56px !important;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%) !important;
  color: #ffffff !important;
  font-size: 1.1rem !important;
  font-weight: 800 !important;
  border: none !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

.cosmosfarm-members-form.signup-form input[type="submit"]:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 10px 20px -5px rgba(37, 99, 235, 0.4) !important;
  background: linear-gradient(135deg, #172554 0%, #1d4ed8 100%) !important;
}

/* 필수 입력 안내 텍스트 숨김 (이미 *로 표시됨) */
.cosmosfarm-members-form.signup-form .req-text {
  display: none !important;
}

/* 비밀번호 강도 메시지 */
.password-strength-meter-display {
  font-size: 0.8rem !important;
  margin-top: 5px !important;
  display: block !important;
}

.password-strength-meter-display.bad {
  color: #ef4444 !important;
}

.password-strength-meter-display.good {
  color: #10b981 !important;
}

/* 모바일 반응형 */
@media (max-width: 768px) {
  .page-id-4532 #content,
  .page-id-4532 #post-4532,
  .page-id-4532 #post-4532 .post-content {
    overflow-x: hidden !important;
  }

  .cosmosfarm-members-form.signup-form {
    padding: 2rem 1.5rem !important;
    width: calc(100vw - 2rem) !important;
    max-width: 680px !important;
    margin: 40px auto !important;
    box-shadow: none !important;
    border: 1px solid #e2e8f0 !important;
  }
}
