/* ===========================================
   Header Auth Styles - Pre-login pages
   Used on: login, register, forgot_password,
   reset_password, error, login_with_recovery,
   reset_recovery_login pages
   =========================================== */

/* Pre-login pages: language switcher in header */
.language-switcher.prelogin-header {
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Noto Serif JP', '游明朝', serif;
  font-weight: 500;
  font-size: 15px;
  line-height: 1.4;
  cursor: pointer;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
  backdrop-filter: blur(4px);
  transition: all 0.3s ease;
  user-select: none;
  min-width: 70px;
  box-sizing: border-box;
  border: 1px solid rgba(255, 255, 255, 0.4);
  outline: 1px solid rgba(255, 255, 255, 0.15);
  outline-offset: 2px;
}

.language-switcher.prelogin-header:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0.08) 100%);
  border-color: rgba(255, 255, 255, 0.6);
  outline-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.15), inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.language-switcher.prelogin-header:active {
  transform: translateY(-50%) scale(0.98);
}

.language-switcher.prelogin-header span {
  color: rgba(255, 255, 255, 0.95);
  text-align: center;
  letter-spacing: 0.05em;
  margin: 0;
  padding: 0;
  line-height: inherit;
}

.language-switcher.prelogin-header .lang-toggle-jp {
  font-stretch: condensed;
  letter-spacing: -0.03em;
  font-size: 0.85em;
}

/* Pre-login pages: language switcher fixed position (e.g., error page) */
.language-switcher.prelogin-fixed {
  position: fixed;
  top: 20px;
  right: 20px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Noto Serif JP', '游明朝', serif;
  font-weight: 500;
  font-size: 15px;
  line-height: 1.4;
  cursor: pointer;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
  backdrop-filter: blur(4px);
  transition: all 0.3s ease;
  user-select: none;
  min-width: 70px;
  box-sizing: border-box;
  border: 1px solid rgba(255, 255, 255, 0.4);
  outline: 1px solid rgba(255, 255, 255, 0.15);
  outline-offset: 2px;
  z-index: 100;
}

.language-switcher.prelogin-fixed:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0.08) 100%);
  border-color: rgba(255, 255, 255, 0.6);
  outline-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.15), inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.language-switcher.prelogin-fixed:active {
  transform: scale(0.98);
}

.language-switcher.prelogin-fixed span {
  color: rgba(255, 255, 255, 0.95);
  text-align: center;
  letter-spacing: 0.05em;
  margin: 0;
  padding: 0;
  line-height: inherit;
}

.language-switcher.prelogin-fixed .lang-toggle-jp {
  font-stretch: condensed;
  letter-spacing: -0.03em;
  font-size: 0.85em;
}

/* ===========================================
   Mobile styles for auth pages
   =========================================== */
@media (max-width: 768px) {
  .language-switcher.prelogin-header {
    right: 15px;
    padding: 6px 12px;
    font-size: 13px;
    min-width: 60px;
  }

  .language-switcher.prelogin-fixed {
    top: 15px;
    right: 15px;
    padding: 6px 12px;
    font-size: 13px;
    min-width: 60px;
  }

  /* Auth page logo mobile styles */
  .logo-wrapper {
    display: block !important;
    margin: 20px 0 15px 5px !important;
  }

  .logo-katakana {
    display: block !important;
    font-size: 11px !important;
    margin-bottom: 2px !important;
  }

  .logo-text {
    display: block !important;
    font-size: 28px !important;
    line-height: 1 !important;
  }
}
