﻿@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:wght@300;400;500;600;700;800&display=swap");

*,
*::before,
*::after {
  box-sizing: border-box;
}

body.auth-page {
  min-height: 100vh;
  margin: 0;
  font-family: "Noto Sans", Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  color: #111827;
  background:
    radial-gradient(circle at 12% 18%, rgba(59, 130, 246, .14), transparent 30%),
    radial-gradient(circle at 86% 80%, rgba(57, 181, 74, .13), transparent 28%),
    linear-gradient(135deg, #edf2f7 0%, #d9e2ec 100%);
  overflow-x: hidden;
}

body.auth-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(37, 99, 235, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, .055) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(135deg, rgba(0, 0, 0, .78), rgba(0, 0, 0, .18));
}

body.auth-page-register {
  height: 100vh;
  overflow: hidden;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(420px, 1.05fr);
}

.auth-shell-single {
  grid-template-columns: minmax(320px, 1fr);
}

.auth-panel {
  min-width: 0;
}

.auth-panel-brand {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 34px 38px;
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.18), transparent 28%),
    linear-gradient(160deg, #18203a 0%, #111827 100%);
  color: #fff;
}

.auth-page-register .auth-panel-brand {
  justify-content: flex-start;
  gap: clamp(28px, 8vh, 72px);
  height: 100vh;
  overflow: hidden;
}

.auth-page-register .auth-brand-card {
  margin-top: clamp(8px, 5vh, 48px);
}

.auth-page-register .auth-shell {
  height: 100vh;
  min-height: 0;
}

.auth-page-register .auth-panel-form {
  height: 100vh;
  min-height: 0;
  align-items: flex-start;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.auth-register-guide {
  width: min(100%, 430px);
  padding: 18px;
  border: 1px solid rgba(191, 219, 254, 0.2);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.075);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
  backdrop-filter: blur(10px);
}

.auth-register-guide-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.auth-register-guide-head span {
  color: #bfdbfe;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.auth-register-guide-head strong {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(34, 197, 94, .16);
  color: #bbf7d0;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.auth-register-steps {
  display: grid;
  gap: 12px;
}

.auth-register-step {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 11px;
  align-items: start;
}

.auth-register-step-num {
  width: 28px;
  height: 28px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(59, 130, 246, .18);
  color: #dbeafe;
  font-size: 12px;
  font-weight: 900;
}

.auth-register-step strong {
  display: block;
  margin-bottom: 2px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
}

.auth-register-step p {
  margin: 0;
  color: rgba(255, 255, 255, .66);
  font-size: 12px;
  line-height: 1.45;
}

.auth-home-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 8px;
  width: fit-content;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.08);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.auth-home-link:hover {
  background: rgba(255, 255, 255, 0.14);
}

.auth-home-link.is-pressing,
.auth-inline-back.is-pressing,
.auth-links a.is-pressing,
.auth-footer-text a.is-pressing {
  transform: translateY(-1px) scale(.985);
  opacity: .92;
  color: #2f9a3e;
}

.auth-brand-card {
  max-width: 420px;
  position: relative;
}

.auth-brand-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.2);
  color: #bfdbfe;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  animation: authBrandBadgeIn .42s cubic-bezier(.22, 1, .36, 1) both;
}

.auth-brand-card h1 {
  margin: 22px 0 14px;
  font-size: 38px;
  line-height: 1.12;
  position: relative;
  animation: authBrandTitleIn .56s cubic-bezier(.22, 1, .36, 1) .06s both;
}

.auth-brand-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.7;
  animation: authBrandCopyIn .5s cubic-bezier(.22, 1, .36, 1) .14s both;
}

.auth-brand-list {
  margin: 28px 0 0;
  padding-left: 18px;
  color: rgba(255, 255, 255, 0.86);
  display: grid;
  gap: 10px;
  font-size: 14px;
}

.auth-brand-list li {
  animation: authBrandListIn .42s cubic-bezier(.22, 1, .36, 1) both;
}

.auth-brand-list li:nth-child(1) { animation-delay: .2s; }
.auth-brand-list li:nth-child(2) { animation-delay: .26s; }
.auth-brand-list li:nth-child(3) { animation-delay: .32s; }

.auth-panel-form {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.auth-panel-form-centered {
  padding: 40px 20px;
}

.auth-card {
  position: relative;
  width: 100%;
  max-width: 470px;
  padding: 34px 30px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  transform-origin: center top;
  transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.auth-card.auth-card-linking {
  transform: translateY(-4px) scale(.994);
  opacity: .96;
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.14);
}

.auth-card-header {
  text-align: center;
  margin-bottom: 28px;
}

.auth-avatar {
  width: 72px;
  height: 72px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #39b54a, #2f9a3e);
  color: #fff;
  box-shadow: 0 12px 24px rgba(57, 181, 74, 0.28);
}

.auth-avatar svg {
  width: 38px;
  height: 38px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-card-header h2 {
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 800;
}

.auth-card-header p {
  margin: 0;
  font-size: 14px;
  color: #6b7280;
  line-height: 1.6;
}

.auth-notice,
.auth-error {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.5;
}

.auth-notice {
  background: #ecfdf3;
  border: 1px solid #a7f3d0;
  color: #166534;
}

.auth-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
}

.auth-form {
  display: grid;
  gap: 16px;
}

.auth-doc-grid {
  display: grid;
  grid-template-columns: minmax(112px, .34fr) minmax(0, 1fr);
  gap: 12px;
}

.auth-field label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #111827;
}

.auth-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  padding: 0 12px;
  background: #fff;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.auth-input-wrap:focus-within {
  border-color: #39b54a;
  box-shadow: 0 0 0 3px rgba(57, 181, 74, 0.15);
  transform: scale(1.01);
}

.auth-input-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  color: #39b54a;
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}

.auth-input-wrap input,
.auth-input-wrap select {
  flex: 1;
  min-width: 0;
  min-height: 46px;
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: #111827;
  font-family: "Noto Sans", Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

.auth-password-wrap {
  gap: 10px;
}

.auth-select-field {
  position: relative;
}

.auth-select-field select.native-select-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.auth-select-field .custom-select {
  position: relative;
  width: 100%;
}

.auth-select-field .custom-select-trigger {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 13px;
  border: 1px solid #d1d9e0;
  border-radius: 10px;
  background: #fff;
  color: #1f2937;
  font-family: "Noto Sans", Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.auth-select-field .custom-select-trigger:hover {
  background: #fafbfc;
}

.auth-select-field .custom-select-trigger:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, .12);
}

.auth-select-field .custom-select-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-select-field .custom-select-chevron {
  color: #5a6478;
  font-size: 11px;
  line-height: 1;
  transition: transform .16s ease;
}

.auth-select-field .custom-select.is-open .custom-select-chevron {
  transform: rotate(180deg);
}

.auth-select-field .custom-select-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 30;
  display: grid;
  gap: 4px;
  padding: 6px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, .14);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-4px) scale(.98);
  transform-origin: top;
  transition: opacity .14s ease, transform .14s ease, visibility .14s ease;
}

.auth-select-field .custom-select.is-open .custom-select-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.auth-select-field .custom-select-option {
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #334155;
  font-family: "Noto Sans", Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.auth-select-field .custom-select-option:hover {
  background: #f0f6ff;
  color: #1d4ed8;
}

.auth-select-field .custom-select-option.is-selected {
  background: #2563eb;
  color: #fff;
}

.auth-toggle-btn {
  border: none;
  background: transparent;
  color: #6b7280;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.auth-toggle-btn:hover {
  color: #39b54a;
}

.auth-links {
  display: flex;
  align-items: center;
}

.auth-links-right {
  justify-content: flex-end;
}

.auth-links a,
.auth-footer-text a,
.auth-inline-back {
  color: #39b54a;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.auth-link-recover {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  gap: 8px;
  padding: 4px 2px;
  color: #2f9a3e;
  text-shadow: 0 0 0 rgba(47, 154, 62, 0);
  transition: color 0.18s ease, transform 0.18s ease, opacity 0.18s ease, text-shadow 0.22s ease;
}

.auth-link-recover::after {
  content: "→";
  position: relative;
  left: auto;
  right: auto;
  bottom: auto;
  height: auto;
  border-radius: 0;
  background: none;
  font-size: 13px;
  font-weight: 800;
  opacity: 0;
  transform: translateX(-8px);
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.auth-links a:hover,
.auth-footer-text a:hover,
.auth-inline-back:hover {
  text-decoration: underline;
}

.auth-link-recover:hover {
  text-decoration: none;
  color: #248336;
  text-shadow: 0 8px 18px rgba(47, 154, 62, 0.16);
}

.auth-link-recover:hover::after,
.auth-link-recover.is-pressing::after {
  transform: translateX(0);
  opacity: 1;
}

.auth-link-recover.is-pressing {
  transform: translateX(2px);
}

.auth-submit-btn {
  width: 100%;
  min-height: 48px;
  margin-top: 2px;
  border: none;
  border-radius: 10px;
  background: #39b54a;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  font-family: "Noto Sans", Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.auth-submit-btn:hover {
  background: #2f9a3e;
  transform: translateY(-1px);
  box-shadow: 0 14px 24px rgba(57, 181, 74, 0.24);
}

.auth-submit-btn::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -38%;
  width: 34%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.42), transparent);
  opacity: 0;
  transform: skewX(-20deg);
}

.auth-submit-btn.is-submitting {
  animation: authSubmitTap .14s ease;
  box-shadow: 0 8px 14px rgba(57, 181, 74, 0.16);
}

.auth-submit-btn.is-submitting::after {
  opacity: 1;
  animation: authSubmitSheen .18s ease-out forwards;
}

.auth-footer-text {
  margin-top: 18px;
  text-align: center;
  font-size: 13px;
  color: #6b7280;
}

.auth-inline-back {
  display: inline-flex;
  margin-bottom: 18px;
  font-size: 13px;
}

.auth-page-restore .auth-inline-back {
  animation: authRestoreBackIn .12s ease-out both;
}

.auth-page-restore .auth-card {
  max-width: 480px;
  padding: 26px 28px;
  animation: authRestoreCardIn .14s ease-out both;
}

.auth-verify-form {
  gap: 18px;
}

.verification-code-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 7px;
  max-width: 330px;
  margin: 0 auto;
}

.verification-code-grid input {
  width: 100%;
  min-height: 46px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f8fafc;
  color: #111827;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 20px;
  font-weight: 800;
  text-align: center;
  outline: none;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}

.verification-code-grid input:focus {
  border-color: #39b54a;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(57, 181, 74, 0.15);
  transform: translateY(-1px);
}

.auth-resend-form {
  margin-top: 14px;
  text-align: center;
}

.auth-text-action {
  border: 0;
  padding: 0;
  background: transparent;
  color: #39b54a;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
}

.auth-text-action:hover,
.auth-text-action:focus-visible {
  text-decoration: underline;
}

.auth-page-restore .auth-panel-form-centered {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 18px;
}

.auth-page-restore .auth-card-header {
  margin-bottom: 18px;
}

.auth-page-restore .auth-avatar {
  width: 62px;
  height: 62px;
  margin-bottom: 12px;
}

.auth-page-restore .auth-avatar svg {
  width: 32px;
  height: 32px;
}

.auth-page-restore .auth-card-header {
  animation: authRestoreHeaderIn .12s ease-out both;
}

.auth-restore-help {
  margin: -6px 0 14px;
}

.auth-restore-help summary {
  width: fit-content;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  cursor: pointer;
  list-style: none;
  padding: 6px 10px 6px 7px;
  font-size: 12px;
  font-weight: 800;
}

.auth-restore-help summary::-webkit-details-marker {
  display: none;
}

.auth-restore-help summary span {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #2563eb;
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.auth-restore-help[open] summary {
  margin-bottom: 9px;
  background: #dbeafe;
}

.auth-restore-guide {
  padding: 11px 12px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: linear-gradient(135deg, #f8fbff 0%, #f0fdf4 100%);
}

.auth-restore-guide p {
  margin: 0 0 7px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.42;
}

.auth-restore-guide p:last-child {
  margin-bottom: 0;
}

.auth-restore-guide strong {
  margin-right: 5px;
  color: #0f172a;
  font-weight: 800;
}

.auth-page-restore .auth-form,
.auth-page-restore .auth-footer-text,
.auth-page-restore .auth-restore-help {
  animation: authRestoreFormIn .12s ease-out both;
}

.auth-hidden-step {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transform: translateX(-16px);
  transition: opacity 0.35s ease, max-height 0.35s ease, transform 0.35s ease, margin 0.35s ease;
}

.auth-hidden-step.auth-visible-step {
  opacity: 1;
  max-height: 140px;
  transform: translateX(0);
}

.auth-form-static .auth-hidden-step,
.auth-form-static .auth-doc-grid.auth-hidden-step {
  opacity: 1;
  max-height: none;
  overflow: visible;
  transform: none;
}

@keyframes authSubmitTap {
  0% { transform: translateY(0) scale(1); }
  45% { transform: translateY(1px) scale(.996); }
  100% { transform: translateY(0) scale(1); }
}

@keyframes authRestoreBackIn {
  0% {
    opacity: .75;
    transform: translateY(-3px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes authRestoreCardIn {
  0% {
    opacity: .82;
    transform: translateY(6px) scale(.994);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  }
}

@keyframes authRestoreHeaderIn {
  0% {
    opacity: .82;
    transform: translateY(4px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes authRestoreFormIn {
  0% {
    opacity: .82;
    transform: translateY(4px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes authBrandBadgeIn {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes authBrandTitleIn {
  0% {
    opacity: 0;
    transform: translateY(18px);
    letter-spacing: -.02em;
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    letter-spacing: 0;
  }
}

@keyframes authBrandCopyIn {
  0% {
    opacity: 0;
    transform: translateY(14px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes authBrandListIn {
  0% {
    opacity: 0;
    transform: translateX(-14px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}


@keyframes authSubmitSheen {
  0% {
    left: -38%;
  }
  100% {
    left: 118%;
  }
}

@media (min-width: 1600px) {
  .auth-shell {
    grid-template-columns: minmax(420px, 1fr) minmax(520px, 1fr);
  }

  .auth-shell.auth-shell-single {
    grid-template-columns: minmax(320px, 1fr);
  }

  .auth-panel-brand {
    padding: 46px 54px;
  }

  .auth-brand-card h1 {
    font-size: 46px;
  }

  .auth-brand-card p {
    font-size: 17px;
  }

  .auth-brand-list {
    font-size: 15px;
  }

  .auth-panel-form {
    padding: 54px 24px;
  }

  .auth-card {
    max-width: 520px;
    padding: 40px 36px;
  }

  .auth-page-restore .auth-card {
    max-width: 500px;
    padding: 30px 32px;
  }
}

@media (min-width: 981px) and (max-height: 780px) {
  .auth-page-restore .auth-panel-form-centered {
    padding: 16px 18px;
  }

  .auth-page-restore .auth-card {
    max-width: 468px;
    padding: 20px 24px;
  }

  .auth-page-restore .auth-inline-back {
    margin-bottom: 12px;
  }

  .auth-page-restore .auth-avatar {
    width: 52px;
    height: 52px;
    margin-bottom: 10px;
  }

  .auth-page-restore .auth-avatar svg {
    width: 28px;
    height: 28px;
  }

  .auth-page-restore .auth-card-header {
    margin-bottom: 14px;
  }

  .auth-page-restore .auth-card-header h2 {
    margin-bottom: 6px;
    font-size: 22px;
  }

  .auth-page-restore .auth-card-header p {
    font-size: 13px;
    line-height: 1.45;
  }

  .auth-page-restore .auth-restore-help {
    margin-bottom: 10px;
  }

  .auth-page-restore .auth-restore-help summary {
    min-height: 30px;
    padding-top: 5px;
    padding-bottom: 5px;
  }

  .auth-page-restore .auth-restore-guide {
    padding: 10px 12px;
  }

  .auth-page-restore .auth-form {
    gap: 12px;
  }

  .auth-page-restore .auth-field label {
    margin-bottom: 5px;
  }

  .auth-page-restore .auth-input-wrap input,
  .auth-page-restore .auth-input-wrap select,
  .auth-page-restore .auth-select-field .custom-select-trigger {
    min-height: 42px;
  }

  .auth-page-restore .auth-submit-btn {
    min-height: 44px;
  }

  .auth-page-restore .auth-footer-text {
    margin-top: 12px;
  }
}

@media (max-width: 980px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-panel-brand {
    padding: 28px 24px 22px;
    gap: 24px;
  }

  .auth-page-register .auth-panel-brand {
    gap: 18px;
    height: auto;
    overflow: visible;
  }

  .auth-page-register .auth-brand-card {
    margin-top: 0;
  }

  .auth-page-register .auth-shell {
    height: 100vh;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }

  .auth-page-register .auth-panel-brand {
    flex: 0 0 auto;
  }

  .auth-page-register .auth-panel-form {
    flex: 1 1 auto;
    height: auto;
    min-height: 0;
    overflow-y: auto;
  }

  .auth-register-guide {
    width: 100%;
  }

  .auth-brand-card {
    max-width: none;
  }

  .auth-page-login .auth-shell {
    min-height: 100vh;
  }

  .auth-page-login .auth-panel-brand {
    justify-content: flex-start;
    padding: 18px 18px 16px;
    gap: 14px;
  }

  .auth-page-login .auth-home-link {
    min-height: 34px;
    padding: 7px 12px;
    font-size: 12px;
  }

  .auth-page-login .auth-brand-badge {
    min-height: 26px;
    padding: 5px 10px;
    font-size: 11px;
  }

  .auth-page-login .auth-brand-card h1 {
    max-width: 620px;
    margin: 12px 0 8px;
    font-size: clamp(25px, 7vw, 36px);
    line-height: 1.08;
  }

  .auth-page-login .auth-brand-card p {
    max-width: 560px;
    font-size: 14px;
    line-height: 1.5;
  }

  .auth-page-login .auth-brand-list {
    display: none;
  }

  .auth-page-login .auth-panel-form {
    align-items: flex-start;
    padding-top: 18px;
  }

  .auth-page-restore .auth-panel-form-centered {
    min-height: 100vh;
    align-items: flex-start;
    padding-top: 24px;
    padding-bottom: 24px;
  }
}

@media (max-width: 640px) {
  body.auth-page-register {
    height: auto;
    min-height: 100svh;
    overflow-y: auto;
  }

  .auth-page-register .auth-shell {
    height: auto;
    min-height: 100svh;
  }

  .auth-panel-form,
  .auth-panel-form-centered {
    padding: 22px 14px;
  }

  .auth-card {
    padding: 26px 18px;
  }

  .auth-doc-grid {
    grid-template-columns: 1fr;
  }

  .auth-card-header h2 {
    font-size: 21px;
  }

  .auth-brand-card h1 {
    font-size: 30px;
  }

  .auth-page-register .auth-panel-brand {
    max-height: none;
    padding: 12px 14px;
    gap: 8px;
    justify-content: flex-start;
    overflow: visible;
  }

  .auth-page-register .auth-home-link {
    min-height: 30px;
    padding: 5px 10px;
    font-size: 11px;
  }

  .auth-page-register .auth-brand-badge {
    min-height: 22px;
    padding: 4px 8px;
    font-size: 10px;
  }

  .auth-page-register .auth-brand-card h1 {
    max-width: 340px;
    margin: 7px 0 5px;
    font-size: clamp(20px, 6vw, 24px);
    line-height: 1.06;
  }

  .auth-page-register .auth-brand-card p {
    max-width: 360px;
    font-size: 12px;
    line-height: 1.32;
  }

  .auth-register-guide {
    display: none;
  }

  .auth-page-register .auth-panel-form {
    padding-top: 12px;
    overflow: visible;
  }

  .auth-page-login .auth-panel-brand {
    padding: 14px 14px 12px;
    gap: 10px;
  }

  .auth-page-login .auth-brand-card h1 {
    font-size: clamp(22px, 7vw, 30px);
  }

  .auth-page-login .auth-brand-card p {
    font-size: 13px;
    line-height: 1.45;
  }

  .auth-page-login .auth-panel-form {
    padding: 16px 12px 22px;
  }

  .auth-page-login .auth-card {
    border-radius: 12px;
    padding: 24px 18px;
  }

  .auth-page-login .auth-avatar {
    width: 58px;
    height: 58px;
    margin-bottom: 12px;
  }

  .auth-page-login .auth-avatar svg {
    width: 31px;
    height: 31px;
  }

  .auth-page-login .auth-card-header {
    margin-bottom: 22px;
  }

  .auth-page-restore .auth-card {
    padding: 24px 18px;
  }

  .auth-page-restore .auth-restore-guide {
    padding: 11px;
  }
}

.auth-session-overlay[hidden] {
  display: none;
}

.auth-session-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(15, 23, 42, .58);
  backdrop-filter: blur(9px);
}

.auth-session-modal {
  width: min(390px, 100%);
  border: 1px solid rgba(248, 113, 113, .35);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 26px 80px rgba(15, 23, 42, .34);
  padding: 24px;
  text-align: center;
}

.auth-session-icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  margin: 0 auto 14px;
  background: #fee2e2;
  color: #dc2626;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-session-icon svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-session-modal h3 {
  margin: 0 0 8px;
  color: #111827;
  font-size: 20px;
  font-weight: 900;
}

.auth-session-modal p {
  margin: 0 0 18px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.5;
}

.auth-session-modal button {
  min-height: 40px;
  border: 0;
  border-radius: 10px;
  background: #dc2626;
  color: #fff;
  padding: 9px 18px;
  font-family: inherit;
  font-weight: 800;
  cursor: pointer;
}

@media (max-width: 430px) {
  .auth-page-login .auth-brand-card p {
    display: none;
  }

  .auth-page-login .auth-brand-card h1 {
    margin-bottom: 0;
  }
}

