/* ═══════════════════════════════════════════════════
   옷결 OTT_GYEOL — Auth Page Styles
   로그인 / 회원가입 / 비밀번호 재설정
   ═══════════════════════════════════════════════════ */

/* ─── AUTH MAIN LAYOUT ─── */
.auth-main {
  min-height: calc(100vh - var(--header-height) - 40px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  background:
    linear-gradient(135deg, var(--cream) 0%, var(--cream-dark) 50%, var(--cream) 100%);
  position: relative;
}

/* Subtle decorative background pattern */
.auth-main::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.02;
  background-image:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 60px,
      rgba(184, 150, 90, 0.5) 60px,
      rgba(184, 150, 90, 0.5) 61px
    );
  pointer-events: none;
}

/* ─── AUTH CARD ─── */
.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--white);
  border-radius: 12px;
  box-shadow:
    0 4px 24px rgba(26, 23, 20, 0.06),
    0 1px 4px rgba(26, 23, 20, 0.04);
  overflow: hidden;
  position: relative;
  animation: fadeUp 0.6s ease-out both;
}

.auth-accent {
  height: 3px;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold), var(--gold-light));
}

/* ─── AUTH LOGO ─── */
.auth-logo {
  text-align: center;
  padding: 32px 40px 0;
}

.auth-logo-img {
  height: 44px;
  width: auto;
  display: inline-block;
  mix-blend-mode: multiply;
}

/* ─── TAB SWITCHER ─── */
.auth-tabs {
  display: flex;
  margin: 24px 40px 0;
  border-bottom: 1px solid var(--beige);
}

.auth-tab {
  flex: 1;
  padding: 12px 0;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--taupe);
  background: none;
  border: none;
  cursor: pointer;
  position: relative;
  transition: color 0.3s ease;
}

.auth-tab::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 20%;
  width: 60%;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.auth-tab.active {
  color: var(--charcoal);
  font-weight: 500;
}

.auth-tab.active::after {
  transform: scaleX(1);
}

.auth-tab:hover {
  color: var(--charcoal);
}

/* ─── FORMS ─── */
.auth-form {
  padding: 28px 40px 36px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: var(--brown);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.required {
  color: var(--rose);
  font-weight: 500;
}

.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="text"] {
  width: 100%;
  padding: 12px 0;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--charcoal);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--beige);
  outline: none;
  transition: border-color 0.3s ease;
  letter-spacing: 0.02em;
}

.form-group input::placeholder {
  color: var(--sand);
  font-weight: 300;
}

.form-group input:focus {
  border-bottom-color: var(--gold);
}

.form-group input.error {
  border-bottom-color: var(--rose);
}

.form-group input.success {
  border-bottom-color: var(--sage);
}

/* Form hint */
.form-hint {
  display: block;
  font-size: 0.68rem;
  margin-top: 6px;
  min-height: 16px;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
}

.form-hint.error {
  color: var(--rose);
}

.form-hint.success {
  color: #7a9e6e;
}

/* ─── PASSWORD STRENGTH ─── */
.password-strength {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.strength-bar {
  flex: 1;
  height: 3px;
  background: var(--beige);
  border-radius: 2px;
  overflow: hidden;
}

.strength-fill {
  height: 100%;
  width: 0;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.strength-fill.weak { width: 33%; background: var(--rose); }
.strength-fill.medium { width: 66%; background: var(--gold); }
.strength-fill.strong { width: 100%; background: #7a9e6e; }

.strength-label {
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--taupe);
  min-width: 40px;
}

/* ─── CHECKBOX ─── */
.form-group-checkbox {
  margin-top: 24px;
  margin-bottom: 24px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--brown);
}

.checkbox-native {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  cursor: pointer;
  accent-color: var(--gold);
  vertical-align: middle;
  margin-top: 0;
}

.checkbox-text {
  font-weight: 300;
}

.terms-link {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.terms-link:hover {
  color: var(--gold-dark);
}

/* ─── FORM MESSAGE (error/success) ─── */
.form-message {
  min-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
}

.form-message.show {
  padding: 10px 14px;
  margin-bottom: 16px;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.5;
}

.form-message.error {
  background: rgba(196, 146, 138, 0.1);
  color: #a0534b;
  border: 1px solid rgba(196, 146, 138, 0.2);
}

.form-message.success {
  background: rgba(122, 158, 110, 0.1);
  color: #5a7e4e;
  border: 1px solid rgba(122, 158, 110, 0.2);
}

/* ─── SUBMIT BUTTON ─── */
.auth-submit {
  width: 100%;
  padding: 14px;
  text-align: center;
  font-size: 0.82rem;
  margin-top: 4px;
}

.auth-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

.btn-loading {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

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

/* ─── AUTH LINKS ─── */
.auth-link {
  display: block;
  text-align: center;
  margin-top: 16px;
  font-size: 0.74rem;
  color: var(--taupe);
  letter-spacing: 0.02em;
}

.auth-link:hover {
  color: var(--gold);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--beige);
}

.auth-divider span {
  font-size: 0.68rem;
  color: var(--sand);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.auth-switch {
  text-align: center;
  font-size: 0.78rem;
  color: var(--taupe);
  font-weight: 300;
}

.auth-switch a {
  color: var(--gold);
  font-weight: 400;
  margin-left: 4px;
}

.auth-switch a:hover {
  color: var(--gold-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ─── PASSWORD RESET ─── */
.reset-desc {
  text-align: center;
  font-size: 0.82rem;
  color: var(--taupe);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 28px;
}

/* ─── MOBILE NAV USER ─── */
.mobile-nav-user {
  display: block;
  font-size: 0.85rem;
  color: var(--charcoal);
  font-weight: 400;
  letter-spacing: 0.02em;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--beige);
  margin-bottom: 4px;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 768px) {
  .auth-main {
    padding: 40px 16px;
    align-items: flex-start;
    padding-top: 24px;
  }

  .auth-card {
    border-radius: 10px;
  }

  .auth-tabs {
    margin: 20px 24px 0;
  }

  .auth-form {
    padding: 24px 24px 32px;
  }

  .auth-logo {
    padding: 24px 24px 0;
  }
}

@media (max-width: 420px) {
  .auth-form {
    padding: 20px 20px 28px;
  }

  .auth-tabs {
    margin: 16px 20px 0;
  }

  .auth-logo {
    padding: 20px 20px 0;
  }
}
