/* ==================================================
   MEMBER COMMON VARIABLES
================================================== */
:root {
  --primary: #14347b;
  --primary-hover: #01154d;
  --bg: #f8fafc;
  --surface: #ffffff;

  --text: #0b1220;
  --muted: #64748b;

  --error-bg: #ffe9e9;
  --error-text: #a00;
}

/* ==================================================
   RESET (회원 영역 한정)
================================================== */
.member-page *,
.login-page * {
  box-sizing: border-box;
}

.member-page,
.login-page {
  font-family: "Noto Sans KR", "Apple SD Gothic Neo", system-ui, sans-serif;
  color: var(--text);
}

/* ==================================================
   LOGIN PAGE LAYOUT
================================================== */
.login-page {
  padding: 140px 0;
  background:
    radial-gradient(
      1200px 500px at 40% 20%,
      rgba(37, 99, 235, 0.18),
      transparent 60%
    ),
    linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

/* ==================================================
   LOGIN CARD
================================================== */
.login-container {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  padding: 32px 28px;

  background: var(--surface);
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
}

.login-container h1 {
  margin-bottom: 24px;
  text-align: center;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary);
}

/* ==================================================
   ERROR MESSAGE
================================================== */
.login-err {
  margin-bottom: 20px;
  padding: 12px 14px;

  background: var(--error-bg);
  color: var(--error-text);
  border-radius: 8px;

  font-size: 0.95rem;
  text-align: center;
}

/* ==================================================
   FORM
================================================== */
.login-container form label {
  display: block;
  margin: 16px 0 6px;
  font-size: 0.95rem;
  font-weight: 500;
}

.login-container form input {
  width: 100%;
  padding: 12px 14px;

  border: 1px solid #ddd;
  border-radius: 8px;

  font-size: 1rem;
  background: #fff;
}

.login-container form input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(20, 52, 123, 0.15);
}

/* ==================================================
   SUBMIT BUTTON
================================================== */
.login-container form button {
  width: 100%;
  margin-top: 24px;
  padding: 14px;

  background: var(--primary);
  color: #fff;

  font-size: 1.05rem;
  font-weight: 600;

  border: none;
  border-radius: 8px;
  cursor: pointer;

  transition: background 0.2s ease;
}

.login-container form button:hover {
  background: var(--primary-hover);
}

/* ==================================================
   EXTRA LINKS
================================================== */
.login-extra {
  margin-top: 20px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
}

.login-extra a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.login-extra a:hover {
  text-decoration: underline;
}

.login-links {
  margin-top: 12px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

.login-links a {
  margin: 0 6px;
  color: var(--primary);
  text-decoration: none;
}

.login-links a:hover {
  text-decoration: underline;
}

/* ==================================================
   MOBILE
================================================== */
@media (max-width: 480px) {
  .login-page {
    padding: 40px 10px;
  }

  .login-container {
    padding: 24px 20px;
    border-radius: 12px;
  }

  .login-container h1 {
    font-size: 1.5rem;
  }

  .login-container form button {
    font-size: 1rem;
  }
}

/* ==================================================
   MEMBER PAGE (My Page)
================================================== */
.member-container {
  max-width: 960px;
  margin: 32px auto 80px;
  padding: 0 16px;
}

.member-container h1 {
  margin-bottom: 20px;
  font-size: 1.8rem;
  font-weight: 700;
}

.member-container h2 {
  margin: 36px 0 14px;
  font-size: 1.25rem;
  font-weight: 600;
  border-left: 4px solid var(--primary);
  padding-left: 10px;
}

/* ==================================================
   CARD
================================================== */
.card {
  background: #fff;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.06);
}

/* ==================================================
   PROFILE TOP
================================================== */
.profile-top {
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.profile-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #e5e7eb;
}

.profile-info {
  line-height: 1.5;
}

.profile-name {
  font-size: 1.2rem;
  font-weight: 700;
}

.profile-email {
  color: #475569;
  font-size: 0.95rem;
}

.profile-status {
  margin-top: 4px;
  font-size: 0.9rem;
  color: #64748b;
}

/* ==================================================
   PROFILE ACTIONS
================================================== */
.profile-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-actions .btn {
  padding: 8px 14px;
  font-size: 0.9rem;
  text-decoration:none;
  color:#000;
}

/* ==================================================
   TABLE
================================================== */
.profile-table-wrap {
  overflow-x: auto;
}

.profile-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0,0,0,.05);
}

.profile-table th {
  width: 180px;
  background: #f1f5f9;
  padding: 12px 14px;
  text-align: left;
  font-weight: 600;
  font-size: 0.9rem;
}

.profile-table td {
  padding: 12px 14px;
  font-size: 0.95rem;
  border-left: 1px solid #e5e7eb;
}

.profile-table tr + tr th,
.profile-table tr + tr td {
  border-top: 1px solid #e5e7eb;
}

/* ==================================================
   AVATAR GRID
================================================== */
.avatar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.avatar-item {
  margin: 0;
  background: #fff;
  border-radius: 14px;
  padding: 10px;
  box-shadow: 0 4px 14px rgba(0,0,0,.06);
}

.avatar-img-wrap {
  position: relative;
}

.avatar-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 10px;
}

.avatar-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  padding: 3px 8px;
  border-radius: 999px;
}

.avatar-date {
  margin-top: 8px;
  font-size: 0.85rem;
  color: #6b7280;
  text-align: center;
}

/* ==================================================
   AVATAR ACTIONS
================================================== */
.avatar-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.avatar-actions form {
  flex: 1;
}

/* ==================================================
   TEXT
================================================== */
.text-muted {
  color: #64748b;
  font-size: 0.95rem;
}

/* ==================================================
   MOBILE
================================================== */
@media (max-width: 768px) {
  .profile-top {
    align-items: flex-start;
  }

  .profile-actions {
    width: 100%;
    margin-left: 0;
  }

  .profile-actions .btn {
    flex: 1;
    text-align: center;
  }

  .profile-table th {
    width: 140px;
  }
}

/* ==================================================
   Mypage 상태뱃지
================================================== */
.status-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 3px 10px;
  font-size: 0.8rem;
  border-radius: 999px;
  font-weight: 500;
}

.status-active {
  background: #e0f2fe;
  color: #0369a1;
}

.status-pending {
  background: #fef3c7;
  color: #92400e;
}

.status-blocked {
  background: #fee2e2;
  color: #991b1b;
}

.status-withdraw {
  background: #e5e7eb;
  color: #374151;
}
/* =========================
   마이페이지 아바타 이미지 
   UPLOAD PAGE
========================= */
.upload-page {
  max-width: 720px;
}

.page-title {
  margin-bottom: 20px;
  font-size: 1.6rem;
  font-weight: 700;
}

.upload-card {
  background: #fff;
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 6px 24px rgba(0,0,0,.06);
}

/* 미리보기 */
.preview-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

.preview-img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px dashed #cbd5e1;
  background: #f8fafc;
}

/* 파일 선택 */
.file-label {
  display: block;
  text-align: center;
  margin-bottom: 20px;
}

.file-label input {
  display: none;
}

.file-label span {
  display: inline-block;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid #cbd5e1;
  cursor: pointer;
  background: #fff;
}

.file-label span:hover {
  background: #f1f5f9;
}

/* 버튼 영역 */
.upload-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}


/* 알림 */
.alert {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.95rem;
}

.alert-success {
  background: #dcfce7;
  color: #166534;
}

.alert-error {
  background: #fee2e2;
  color: #991b1b;
}
/* 회원가입 체크박스 정렬 */
.chk-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0;
}

.chk-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.chk-row label {
  margin: 0 !important;
  font-size: 14px;
  line-height: 1.4;
  cursor: pointer;
}

/* 체크박스만 예외 처리 */
.login-container input[type="checkbox"] {
  width: auto !important;
  height: 18px;
  margin: 0;
  flex-shrink: 0;
}

/* =================================================
   Member Common (Find / Password)
================================================= */

.member-wrap {
  max-width: 420px;
  margin: 80px auto;
  padding: 32px 28px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
}

.member-title {
  font-size: 1.6rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
}

.member-desc {
  text-align: center;
  font-size: .95rem;
  color: #666;
  line-height: 1.5;
  margin-bottom: 28px;
}

/* =================================================
   Form
================================================= */

.member-form .form-group {
  margin-bottom: 18px;
}

.member-form label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: #333;
}

.member-form input[type="text"],
.member-form input[type="email"],
.member-form input[type="password"],
.member-form input[type="tel"] {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: .95rem;
  transition: border-color .15s, box-shadow .15s;
}

.member-form input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}

/* =================================================
   Button
================================================= */

.w-100 {
  width: 100%;
}

/* =================================================
   Alert
================================================= */

.alert {
  padding: 14px 16px;
  border-radius: 10px;
  font-size: .9rem;
  margin-bottom: 20px;
  line-height: 1.4;
}

.alert.error {
  background: #fee2e2;
  color: #991b1b;
}

.alert.success {
  background: #dcfce7;
  color: #166534;
}

.alert.info {
  background: #eff6ff;
  color: #1e40af;
}

/* =================================================
   Member Links
================================================= */

.member-links {
  margin-top: 26px;
  text-align: center;
  font-size: .85rem;
}

.member-links a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 500;
}

.member-links a:hover {
  text-decoration: underline;
}

.member-links .divider {
  margin: 0 8px;
  color: #ccc;
}

/* =================================================
   Password Sent Page
================================================= */

.member-password-sent {
  text-align: center;
}

.member-password-sent .icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.member-password-sent .hint {
  font-size: .85rem;
  color: #777;
  margin-top: 14px;
}

/* =================================================
   Mobile
================================================= */

@media (max-width: 480px) {
  .member-wrap {
    margin: 40px 16px;
    padding: 26px 20px;
  }

  .member-title {
    font-size: 1.4rem;
  }
}
/* =================================================
   Password Sent (메일 발송 완료 안내)
================================================= */

.member-password-sent {
  text-align: center;
}

.member-password-sent .icon {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: 18px;
}

.member-password-sent .member-desc {
  margin-bottom: 24px;
}

/* 링크 버튼 느낌 강화 (선택) */
.member-password-sent .member-links a {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--primary-soft, rgba(37,99,235,.12));
  transition: background .15s ease;
}

.member-password-sent .member-links a:hover {
  background: rgba(37,99,235,.2);
}
/* =================================================
   Password Reset Complete
================================================= */

.member-password-complete {
  text-align: center;
}

.member-password-complete .icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.member-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
  flex-wrap: wrap;
}

.member-actions .btn {
  min-width: 120px;
}

/* 버튼 보조 스타일 (없다면) */
.btn-outline {
  padding: 12px 20px;
  border: 1px solid var(--primary);
  color: var(--primary);
  border-radius: 999px;
  text-decoration: none;
  font-weight: 500;
}

.btn-outline:hover {
  background: rgba(37,99,235,.08);
}
