.auth-page {
  align-items: center;
}

.auth-page .auth-card {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  width: 30rem;
  padding: 2.5rem;
  background: hsl(var(--bg) / 0.75);
  backdrop-filter: blur(8px);
  border: 1px solid hsl(var(--text) / 0.15);
  border-radius: 2rem;
  transition: all 0.3s ease;
}

.auth-page .auth-card h1 {
  width: fit-content;
  font-size: 2.6rem;
  user-select: text;
}

.auth-page.login .auth-card h1 {
  background: linear-gradient(270deg, hsl(var(--color1)), hsl(var(--color2)));
  -webkit-background-clip: text;
}

.auth-page .auth-card-form {
  margin: 0.5rem 0 -1.5rem 0;
  padding: 0 0.5rem;
  width: 100%;
  height: 100%;
}

.auth-page .auth-card-switcher {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
  position: relative;
}

.auth-page .auth-card-switcher::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  transform: translateX(0);
  width: 8.5rem;
  height: 3px;
  background: linear-gradient(90deg, hsl(var(--color1)), hsl(var(--color2)));
  transition: transform 0.3s ease;
}

.auth-page.login .auth-card-switcher::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  transform: translateX(calc(100% + 1rem));
  width: 8.5rem;
  height: 3px;
  background: linear-gradient(270deg, hsl(var(--color1)), hsl(var(--color2)));
  transition: transform 0.3s ease;
}


.auth-page .auth-card-switch:hover {
  background: hsl(var(--text) / 0.03);
}

.auth-page .auth-card-switch {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 8.5rem;
  padding: 0.75rem;
  border-radius: 12px 12px 0 0;
  border: 1px hsl(var(--text) / 0.15) solid;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.auth-page .auth-card-input {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin-top: 0.6rem;
  transition: opacity 0.3s ease, margin-top 0.3s ease 0.3s, max-height 0.3s ease 0.3s, padding 0.3s ease 0.3s, border 0.3s ease 0.3s;
  border-radius: 0.5rem;
  border: 1px hsl(var(--text) / 0.15) solid;
  position: relative;
}

.auth-page .auth-card-input.nickname,
.auth-page .auth-card-input.email,
.auth-page .auth-card-input.password-repeat {
  opacity: 0;
  margin-top: 0;
  pointer-events: none;
  max-height: 0;
  padding: 0;
  overflow: hidden;
}

.auth-page.register .auth-card-input {
  margin-top: 0.8rem;
}

.auth-page.register .auth-card-input.nickname,
.auth-page.register .auth-card-input.email,
.auth-page.register .auth-card-input.password-repeat {
  opacity: 1;
  margin-top: 0.8rem;
  max-height: 100px;
  padding: initial;
  border: 1px hsl(var(--text) / 0.15) solid;
  overflow: visible;
  pointer-events: auto;
  transition: opacity 0.3s ease, margin-top 1s ease, max-height 0.6s ease, padding 1s ease;
}

.auth-page .auth-card-input input {
  font-family: 'Inter';
  padding: 1rem 1.2rem 1rem 3.15rem;
  font-size: 0.95rem;
  font-weight: 450;
  background-color: hsl(var(--bg) / 0);
  color: hsl(var(--text));
  border: none;
  width: 100%;
}

.auth-page .auth-card-input input::placeholder {
  font-family: 'Rubik';
  color: hsl(var(--text));
}

.auth-page .auth-card-input input:focus,
.auth-page .auth-card-input input:focus-visible {
  outline: none;
  border: none;
  box-shadow: none;
}

.auth-page .auth-card-input input:-webkit-autofill,
.auth-page .auth-card-input input:-webkit-autofill:hover,
.auth-page .auth-card-input input:-webkit-autofill:focus,
.auth-page .auth-card-input input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px transparent inset !important;
  -webkit-text-fill-color: hsl(var(--text)) !important;
  transition: background-color 9999s ease-in-out 0s;
  border-radius: 0.5rem;
}

.auth-page .auth-card-input .auth-card-input-icon,
.auth-page .auth-card-input .auth-card-password-show {
  position: absolute;
  z-index: 1;
}

.auth-page .auth-card-input .auth-card-input-icon {
  left: 1rem;
  bottom: 0.85rem;
  width: 1.5rem;
  height: 1.5rem;
}

.auth-page .auth-card-input .auth-card-password-show {
  right: 1rem;
  bottom: 0.85rem;
  width: 1.5rem;
  height: 1.5rem;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.auth-page .auth-card-input .auth-card-password-show:hover {
  transform: scale(1.05)
}

.auth-page .auth-complete-knp {
  margin-top: 1.5rem;
  width: 100%;
}

.auth-page .auth-complete-knp-text {
  padding: 0.7rem 0;
}

.auth-page .auth-card-error {
  position: relative;
  z-index: -1;
  margin-top: 0.5rem;
  margin-bottom: 0.25rem;
  font-size: 0.85rem;
  color: red;
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-2rem);
  transition: opacity 0.2s, transform 0.2s;
}

.auth-page .auth-card-error.active {
  opacity: 1;
  transform: translateY(0);
}

.auth-page .auth-card-social-logins {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-top: 1rem;
}

.auth-page .auth-card-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1rem;
  border-radius: 0.5rem;
  border: 1px hsl(var(--text) / 0.15) solid;
  color: hsl(var(--text));
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.auth-page .auth-card-social-btn img {
  width: 1.25rem;
  height: 1.25rem;
}

.auth-page .auth-card-social-btn:hover {
  background: hsl(var(--text) / 0.08);
}

.popup.captcha {
  width: auto;
  border-radius: 1.5rem;
}

.popup.captcha .popup-content {
  padding: 1rem;
}

.popup .popup-captcha {
  user-select: none;
  -webkit-user-drag: none;
  display: flex;
  justify-content: center;
  transform-origin: center center;
}

.popup .popup-captcha .g-recaptcha {
  transform-origin: center center;
}