html,
.AuthBody {
  max-width: 100%;
  overflow-x: hidden;
}

.AuthBody {
  margin: 0;
  min-height: 100vh;
  color: var(--shifto-color-ink);
  background:
    radial-gradient(ellipse 42% 28% at 7% 10%, rgba(249, 217, 194, 0.58), rgba(249, 217, 194, 0.18) 44%, rgba(249, 217, 194, 0) 78%),
    radial-gradient(ellipse 44% 32% at 96% 7%, rgba(143, 133, 247, 0.3), rgba(143, 133, 247, 0.12) 44%, rgba(143, 133, 247, 0) 76%),
    radial-gradient(ellipse 54% 30% at 55% 92%, rgba(249, 217, 194, 0.45), rgba(249, 217, 194, 0.14) 46%, rgba(249, 217, 194, 0) 80%),
    linear-gradient(180deg, rgba(255, 251, 247, 0.96), rgba(248, 247, 255, 0.72)),
    var(--shifto-color-cream);
}

.AuthPage {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(1.25rem, 4vw, 4rem);
}

.AuthShell {
  width: min(1180px, calc(100vw - 2.5rem));
  min-height: min(680px, calc(100vh - 5rem));
  display: grid;
  grid-template-columns: minmax(0, 0.48fr) minmax(0, 0.52fr);
  gap: clamp(1.25rem, 2.4vw, 2rem);
  padding: clamp(1rem, 1.8vw, 1.5rem);
  border: 1px solid rgba(49, 47, 54, 0.12);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 36px 80px rgba(49, 47, 54, 0.12),
    0 3px 0 rgba(255, 255, 255, 0.92) inset;
}

.AuthBrandPanel {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 2rem;
  overflow: hidden;
  border-radius: 20px;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  background:
    radial-gradient(ellipse 120% 74% at -16% -14%, rgba(255, 255, 255, 0.98) 0%, rgba(255, 251, 247, 0.94) 28%, rgba(255, 251, 247, 0) 58%),
    radial-gradient(ellipse 118% 84% at 42% 24%, rgba(248, 247, 255, 0.94) 0%, rgba(248, 247, 255, 0.5) 42%, rgba(248, 247, 255, 0) 74%),
    radial-gradient(ellipse 110% 78% at 86% 50%, rgba(249, 217, 194, 0.82) 0%, rgba(249, 217, 194, 0.34) 38%, rgba(249, 217, 194, 0) 72%),
    radial-gradient(ellipse 106% 72% at 100% 100%, rgba(215, 79, 170, 0.82) 0%, rgba(215, 79, 170, 0.42) 40%, rgba(215, 79, 170, 0) 72%),
    radial-gradient(ellipse 96% 70% at 16% 100%, rgba(143, 133, 247, 0.92) 0%, rgba(143, 133, 247, 0.5) 40%, rgba(143, 133, 247, 0) 74%),
    linear-gradient(135deg, var(--shifto-color-paper) 0%, var(--shifto-color-cream) 24%, var(--shifto-color-soft-lilac) 48%, #f1cfe9 72%, var(--shifto-color-purple) 100%);
  box-shadow:
    0 24px 56px rgba(143, 133, 247, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.AuthBrandLogo {
  position: relative;
  z-index: 2;
  display: inline-flex;
  width: min(13.5rem, 62%);
  text-decoration: none;
}

.AuthBrandLogo img {
  display: block;
  width: 100%;
  height: auto;
}

.AuthBrandSentence {
  position: relative;
  z-index: 2;
  grid-row: 3;
  align-self: end;
  max-width: 24rem;
  margin: 0;
  color: var(--shifto-color-ink);
  font-size: clamp(1.4rem, 2vw, 2rem);
  font-weight: var(--shifto-weight-extrabold);
  line-height: 1.18;
  letter-spacing: 0;
  text-shadow: 0 1px 18px rgba(255, 255, 255, 0.38);
}

.AuthActionPanel {
  min-width: 0;
  display: grid;
  align-items: center;
  padding: clamp(2rem, 5vw, 4.75rem);
}

.AuthActionInner {
  width: 100%;
  max-width: 27rem;
  margin-inline: auto;
}

.AuthKicker {
  margin: 0 0 0.75rem;
  color: var(--shifto-color-purple);
  font-size: var(--shifto-font-size-2);
  font-weight: var(--shifto-weight-extrabold);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.AuthTitle {
  margin: 0;
  color: var(--shifto-color-ink);
  font-family: var(--shifto-font-display);
  font-size: clamp(2.25rem, 3.6vw, 3.5rem);
  font-weight: var(--shifto-weight-extrabold);
  line-height: 1.02;
  letter-spacing: 0;
}

.AuthCopy {
  margin: 1rem 0 0;
  color: var(--shifto-color-muted-ink);
  font-size: var(--shifto-font-size-3);
  line-height: var(--shifto-line-body);
}

.AuthForm {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
}

.AuthField {
  display: grid;
  gap: 0.5rem;
}

.AuthField label {
  color: var(--shifto-color-ink);
  font-size: var(--shifto-font-size-2);
  font-weight: var(--shifto-weight-extrabold);
}

.AuthField input {
  width: 100%;
  min-height: 3.25rem;
  border: 1px solid rgba(49, 47, 54, 0.18);
  border-radius: 10px;
  background: #f7f7fb;
  color: var(--shifto-color-ink);
  font: inherit;
  font-size: var(--shifto-font-size-3);
  padding: 0.75rem 0.875rem;
  outline: none;
  transition:
    background var(--shifto-duration-fast) var(--shifto-ease-standard),
    border-color var(--shifto-duration-fast) var(--shifto-ease-standard),
    box-shadow var(--shifto-duration-fast) var(--shifto-ease-standard);
}

.AuthField input::placeholder {
  color: rgba(49, 47, 54, 0.44);
}

.AuthField input:hover {
  border-color: rgba(49, 47, 54, 0.28);
}

.AuthField input:focus {
  border-color: var(--shifto-focus-border);
  background: var(--shifto-color-paper);
  box-shadow: 0 0 0 4px rgba(143, 133, 247, 0.22);
}

.AuthPrimaryButton,
.AuthSecondaryButton {
  min-height: 3.25rem;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  border-radius: var(--shifto-radius-pill);
  font: inherit;
  font-size: var(--shifto-font-size-3);
  font-weight: var(--shifto-weight-extrabold);
  line-height: 1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform var(--shifto-duration-fast) var(--shifto-ease-standard),
    filter var(--shifto-duration-fast) var(--shifto-ease-standard),
    box-shadow var(--shifto-duration-fast) var(--shifto-ease-standard),
    border-color var(--shifto-duration-fast) var(--shifto-ease-standard);
}

.AuthPrimaryButton {
  width: 100%;
  border: 0;
  background: var(--shifto-color-ink);
  color: var(--shifto-color-light-text);
  box-shadow: 0 14px 26px rgba(49, 47, 54, 0.18);
}

.AuthPrimaryButton:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(49, 47, 54, 0.22);
}

.AuthPrimaryButton:disabled {
  cursor: not-allowed;
  filter: grayscale(0.12);
  opacity: 0.62;
  transform: none;
  box-shadow: none;
}

.AuthSecondaryButton {
  width: 100%;
  border: 0;
  color: var(--shifto-color-light-text);
  background:
    radial-gradient(circle at 18% 20%, rgba(249, 217, 194, 0.78), rgba(249, 217, 194, 0) 34%),
    radial-gradient(circle at 78% 32%, rgba(143, 133, 247, 0.74), rgba(143, 133, 247, 0) 46%),
    var(--shifto-color-pink);
  box-shadow: var(--shifto-shadow-inset), 0 14px 28px rgba(215, 79, 170, 0.16);
}

.AuthSecondaryButton:hover {
  transform: translateY(-1px);
  filter: saturate(1.06);
}

.AuthPrimaryButton:focus-visible,
.AuthSecondaryButton:focus-visible,
.AuthLegal a:focus-visible,
.AuthBrandLogo:focus-visible {
  outline: 3px solid var(--shifto-focus-ring);
  outline-offset: 4px;
}

.AuthStatus {
  min-height: 1.375rem;
  border-radius: 14px;
  color: var(--shifto-color-muted-ink);
  font-size: var(--shifto-font-size-2);
  line-height: var(--shifto-line-body);
  white-space: pre-line;
}

.AuthStatus.active {
  padding: 0.75rem 1rem;
  border: 1px solid transparent;
}

.AuthStatus.success {
  border-color: var(--shifto-success-border);
  background: var(--shifto-success-bg);
  color: var(--shifto-success-text);
}

.AuthStatus.error {
  border-color: var(--shifto-danger-border);
  background: var(--shifto-danger-bg);
  color: var(--shifto-danger-text);
}

.AuthLegal {
  margin: 1.5rem 0 0;
  color: var(--shifto-color-muted-ink);
  font-size: var(--shifto-font-size-1);
  line-height: var(--shifto-line-body);
}

.AuthLegal a {
  color: #8c2b69;
  font-weight: var(--shifto-weight-bold);
  text-decoration: none;
}

.AuthLegal a:hover {
  color: var(--shifto-color-pink);
  text-decoration: underline;
}

@media (max-width: 920px) {
  .AuthPage {
    padding: 1.25rem;
  }

  .AuthShell {
    min-height: 0;
    grid-template-columns: 1fr;
  }

  .AuthBrandPanel {
    min-height: 25rem;
  }

  .AuthBrandSentence {
    max-width: 30rem;
  }
}

@media (max-width: 640px) {
  .AuthPage {
    display: block;
    padding: 1rem;
  }

  .AuthShell {
    width: calc(100vw - 2rem);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.75rem;
    border-radius: 20px;
  }

  .AuthBrandPanel {
    min-height: 20rem;
    border-radius: 16px;
    padding: 1.25rem;
  }

  .AuthBrandLogo {
    width: min(12rem, 72%);
  }

  .AuthBrandSentence {
    font-size: 1.25rem;
  }

  .AuthActionPanel {
    padding: 1.5rem 1rem 1.75rem;
  }

  .AuthTitle {
    font-size: clamp(2rem, 10vw, 2.45rem);
  }
}
