.auth-form .privacy-check {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 18px 0 4px;
  line-height: 1.5;
  cursor: pointer;
}

.auth-form .privacy-check input[type="checkbox"] {
  display: block;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--blue);
}

.auth-form .privacy-check span {
  display: block;
}

.auth-form .privacy-check a {
  color: var(--blue);
  font-weight: 700;
}

.verify-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: var(--navy);
}

.verification-help {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #dbe5dd;
  text-align: center;
}

.verification-help p {
  margin: 0 0 10px;
  color: #637069;
  font-size: 13px;
}

.auth-form .secondary-action {
  width: 100%;
  border: 1px solid #2f8654;
  background: #fff;
  color: #226c43;
}

.registration-complete {
  padding: 36px 0 14px;
  text-align: center;
}

.registration-complete .completion-mark {
  display: inline-grid;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  place-items: center;
  border-radius: 50%;
  background: #e4f3e9;
  color: #25814c;
  font-size: 28px;
  font-weight: 800;
}

.registration-complete h2 {
  margin: 0 0 18px;
}

.registration-complete p {
  margin: 0 0 16px;
  line-height: 1.7;
}

.registration-complete strong {
  display: block;
  max-width: 100%;
  margin-bottom: 4px;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.registration-complete strong + span {
  display: block;
}

.registration-complete .completion-guide {
  color: #66736b;
  font-size: 14px;
}

.registration-complete > button {
  display: block;
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--blue);
  background: var(--blue);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.registration-complete > .secondary-action {
  background: #fff;
  color: var(--blue);
}

.registration-complete button + button {
  margin-top: 10px;
}

.verify-card {
  width: min(100%, 520px);
  padding: 42px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .26);
  text-align: center;
}

.verify-card h1 {
  margin: 0 0 14px;
  color: var(--navy);
  font-size: clamp(1.7rem, 5vw, 2.25rem);
}

.verify-card p {
  margin: 0 0 24px;
  color: #526071;
  line-height: 1.7;
}

.verify-card button {
  width: 100%;
}

.verify-card .home-link {
  display: inline-block;
  margin-top: 20px;
}

.verify-card #verificationMessage {
  min-height: 1.6em;
  margin-top: 18px;
  color: #b42318;
  font-weight: 700;
}

@media (max-width: 560px) {
  .verify-card { padding: 30px 22px; }
  .auth-brand.official-brand .official-brand-text { color: var(--navy); }
  .login-help { align-items: flex-start; flex-direction: column; }
  .reset-brand { position: absolute; top: 18px; left: 20px; }
  .reset-page { padding-top: 100px; }
}
.auth-brand.official-brand {
  color: inherit;
  text-decoration: none;
}

.auth-brand.official-brand .official-brand-text { color: #fff; }
.auth-brand.official-brand .official-logo { width: 54px; height: 54px; flex-basis: 54px; }

.login-help { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; }
.login-help > a { color: var(--blue); font-size: 12px; font-weight: 700; text-decoration: none; }
.login-help > .action { width: auto; margin: 0; padding: 8px 10px; font-size: 11px; }

.social-login {
  margin-top: 20px;
  text-align: center;
}

.social-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 13px;
  color: #87938b;
  font-size: 11px;
}

.social-divider::before,
.social-divider::after {
  flex: 1;
  height: 1px;
  background: #dbe5dd;
  content: "";
}

.naver-login-button {
  display: inline-grid;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #03c75a;
  color: #fff;
  text-decoration: none;
}

.naver-login-button:focus-visible { outline: 3px solid rgba(3,199,90,.28); outline-offset: 2px; }
.naver-login-button span { font: 900 22px Arial,sans-serif; line-height: 1; }

.naver-processing-page {
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  display: grid;
  place-items: center;
  padding: 28px;
  background: #fff;
  color: #050505;
  font-family: Pretendard, "Noto Sans KR", Arial, sans-serif;
}

.naver-processing-card {
  width: min(100%, 480px);
  margin-top: -5vh;
  text-align: center;
}

.naver-processing-spinner {
  display: block;
  width: 34px;
  height: 34px;
  margin: 0 auto 24px;
  border: 4px solid #e0e4e7;
  border-bottom-color: #03c75a;
  border-radius: 50%;
  animation: naver-processing-spin .8s linear infinite;
}

.naver-processing-spinner.is-stopped {
  border-color: #e0e4e7;
  border-bottom-color: #03c75a;
  animation: none;
}

.naver-processing-card h1 {
  margin: 0 0 14px;
  color: #050505;
  font-size: clamp(1.5rem, 5vw, 2rem);
  font-weight: 900;
  letter-spacing: -.04em;
  line-height: 1.35;
  word-break: keep-all;
}

.naver-processing-card p {
  margin: 0;
  color: #5f6368;
  font-size: 16px;
  line-height: 1.6;
  word-break: keep-all;
}

.naver-processing-return {
  display: inline-block;
  margin-top: 24px;
  color: #03a64d;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.naver-processing-return[hidden] { display: none; }

@keyframes naver-processing-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .naver-processing-spinner { animation-duration: 1.8s; }
}

.reset-brand { position: fixed; top: 28px; left: max(24px,5vw); text-decoration: none; }
.reset-card { width: min(520px,calc(100vw - 40px)); }
.reset-eyebrow { color: var(--blue) !important; font: 800 10px Manrope,sans-serif; letter-spacing: 2px; }
.reset-form { text-align: left; }
.reset-form label { display: block; margin: 14px 0; color: var(--ink); font-size: 12px; font-weight: 700; }
.reset-form input { display: block; width: 100%; margin-top: 7px; padding: 12px; border: 1px solid var(--line); background: #fbfcfd; outline: none; }
.reset-form input:focus { border-color: var(--blue); }
.reset-form button { width: 100%; margin-top: 8px; padding: 14px; border: 0; background: var(--blue); color: #fff; font-weight: 700; cursor: pointer; }
.reset-form button:disabled { opacity: .6; }
.reset-card #resetMessage { min-height: 1.6em; margin-top: 18px; color: #1d5fae; font-weight: 700; }

/* Desktop authentication layout: align the brand with the card instead of
   absolutely overlaying it near the upper-left edge. */
@media (min-width: 851px) {
  body.auth-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    min-height: 100vh;
    padding: 28px;
  }

  .auth-brand.official-brand {
    position: static;
    top: auto;
    left: auto;
    width: min(970px, 92vw);
    min-width: 0;
    max-width: 100%;
    margin: 0 auto;
    padding-left: 2px;
  }

  .auth-card {
    flex: 0 0 auto;
    margin: 0 auto;
  }
}

/* Mobile authentication layout: keep the brand, tabs and form in normal flow. */
@media (max-width: 850px) {
  html,
  body.auth-page {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  body.auth-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100dvh;
    padding: max(22px, env(safe-area-inset-top)) 16px max(36px, env(safe-area-inset-bottom));
  }

  .auth-brand.official-brand {
    position: static;
    top: auto;
    left: auto;
    width: min(100%, 560px);
    min-width: 0;
    max-width: 100%;
    margin: 0 auto 18px;
    padding: 0 4px;
    color: var(--navy);
  }

  .auth-brand.official-brand .official-logo {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
  }

  .auth-brand.official-brand .official-brand-wordmark-korean {
    flex: 0 1 180px;
    width: min(180px, calc(100% - 60px));
    min-width: 0;
    max-width: 180px;
    height: 44px;
  }

  .auth-card {
    display: block;
    width: min(100%, 560px);
    min-width: 0;
    min-height: 0;
    margin: 0 auto;
    overflow: hidden;
  }

  .auth-form,
  .auth-form form,
  .auth-form label,
  .auth-form .tabs,
  .auth-form .two,
  .registration-complete {
    min-width: 0;
    max-width: 100%;
  }

  .auth-form .tabs {
    width: 100%;
  }

  .auth-form .tabs button,
  .auth-form input,
  .auth-form button {
    min-width: 0;
    max-width: 100%;
  }

  .auth-form .two {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .auth-form .privacy-check span,
  .verification-help,
  .login-help,
  #authMessage,
  .home-link {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: keep-all;
  }
}

@media (max-width: 560px) {
  body.auth-page {
    padding-right: 12px;
    padding-left: 12px;
  }

  .auth-brand.official-brand {
    margin-bottom: 14px;
    padding-inline: 6px;
  }

  .auth-brand.official-brand .official-logo {
    flex-basis: 44px;
    width: 44px;
    height: 44px;
  }

  .auth-brand.official-brand .official-brand-wordmark-korean {
    flex-basis: 166px;
    width: min(166px, calc(100% - 54px));
    max-width: 166px;
    height: 41px;
  }

  .auth-form {
    padding: 26px 18px 30px;
  }

  .auth-form .tabs {
    margin-bottom: 28px;
  }

  .auth-form .two {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .auth-form .privacy-check {
    align-items: flex-start;
  }

  .auth-form .privacy-check input[type="checkbox"] {
    margin-top: 2px;
  }

  .registration-complete {
    padding-top: 18px;
  }

  .verify-page,
  .reset-page {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    padding-right: 16px;
    padding-left: 16px;
  }

  .verify-card,
  .reset-card {
    width: 100%;
    min-width: 0;
    max-width: 520px;
  }
}
