@import url("https://fonts.googleapis.com/css2?family=Syne:wght@500;600;700;800&family=Figtree:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap");

.auth-v3 {
  --c-bg: #f3f6f8;
  --c-panel: #ffffff;
  --c-ink: #0c1a22;
  --c-text: #13232d;
  --c-muted: #60707c;
  --c-line: #dce4ea;
  --c-accent: #0ea5a0;
  --c-accent-bright: #2dd4bf;
  --c-accent-soft: #e6f8f5;
  --c-accent-deep: #0b7f7a;
  --c-danger: #c23b45;
  --font-ui: "Syne", "Figtree", ui-sans-serif, system-ui, sans-serif;
  --font-body: "Figtree", "Syne", ui-sans-serif, system-ui, sans-serif;
  min-height: 100dvh;
  margin: 0;
  color: var(--c-text);
  background: var(--c-bg);
  font-family: var(--font-body);
}

.auth-v3 *,
.auth-v3 *::before,
.auth-v3 *::after { box-sizing: border-box; }

.auth-v3 button,
.auth-v3 input,
.auth-v3 a { font-family: inherit; letter-spacing: 0; }

.auth-v3 .auth-atmosphere {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(980px 520px at 88% -12%, rgba(14, 165, 160, 0.16), transparent 58%),
    radial-gradient(760px 480px at -8% 108%, rgba(45, 212, 191, 0.1), transparent 55%),
    radial-gradient(640px 360px at 48% 42%, rgba(255, 255, 255, 0.55), transparent 70%),
    linear-gradient(165deg, #eef4f7 0%, #f5f7f9 42%, #e8eef2 100%);
}

.auth-v3 .auth-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(300px, 440px) minmax(0, 1fr);
  min-height: 100dvh;
}

.auth-v3 .auth-brand {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 28px 28px 24px;
  color: #e7eef4;
  background:
    linear-gradient(165deg, rgba(14, 165, 160, 0.18) 0%, transparent 34%),
    linear-gradient(180deg, #071018 0%, #0b1822 55%, #0a151d 100%);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.auth-v3 .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  width: fit-content;
  color: inherit;
  text-decoration: none;
}

.auth-v3 .brand .mark {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 14px;
  background:
    url("/nodedistro-logo.png") center 8% / 180% auto no-repeat,
    linear-gradient(145deg, #2dd4bf, #0b7f7a);
  box-shadow:
    0 10px 28px rgba(14, 165, 160, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.auth-v3 .brand div { display: grid; min-width: 0; }

.auth-v3 .brand strong {
  font-family: var(--font-ui);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #fff;
}

.auth-v3 .brand span {
  margin-top: 2px;
  color: #7f93a4;
  font-size: 11px;
  font-weight: 500;
}

.auth-v3 .auth-brand-copy { display: grid; gap: 12px; margin-top: auto; }

.auth-v3 .eyebrow {
  margin: 0;
  color: #8ee0d8;
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.auth-v3 h1 {
  margin: 0;
  max-width: 12ch;
  color: #fff;
  font-family: var(--font-ui);
  font-size: clamp(36px, 4vw, 52px);
  font-weight: 750;
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.auth-v3 .auth-brand-copy p:last-child {
  margin: 0;
  max-width: 34ch;
  color: #9aafbf;
  font-size: 15px;
  line-height: 1.5;
}

.auth-v3 .auth-points {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.auth-v3 .auth-points li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #d5e2eb;
  font-size: 14px;
}

.auth-v3 .auth-points li::before {
  content: "";
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 99px;
  background: linear-gradient(135deg, #2dd4bf, #0ea5a0);
  box-shadow: 0 0 0 4px rgba(14, 165, 160, 0.16);
}

.auth-v3 .auth-stage {
  display: grid;
  place-items: center;
  padding: 32px 24px;
}

.auth-v3 .auth-card {
  width: min(440px, 100%);
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 22px 60px rgba(7, 16, 24, 0.12);
}

.auth-v3 .auth-card-head { display: grid; gap: 6px; }

.auth-v3 .auth-card-head h2 {
  margin: 0;
  color: var(--c-ink);
  font-family: var(--font-ui);
  font-size: 28px;
  font-weight: 750;
  letter-spacing: -0.045em;
}

.auth-v3 .auth-card-head p {
  margin: 0;
  color: var(--c-muted);
  font-size: 14px;
  line-height: 1.45;
}

.auth-v3 .auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  border-radius: 14px;
  background: #eef3f6;
}

.auth-v3 .tab {
  min-height: 40px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: #60707c;
  padding: 0 10px;
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
  cursor: pointer;
}

.auth-v3 .tab.active {
  background: #fff;
  color: var(--c-ink);
  box-shadow: 0 6px 16px rgba(7, 16, 24, 0.08);
}

.auth-v3 .tab:hover { color: var(--c-ink); }

.auth-v3 .field {
  display: grid;
  gap: 7px;
  color: #3d5160;
  font-size: 13px;
  font-weight: 650;
}

.auth-v3 .field input {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--c-line);
  border-radius: 14px;
  background: #fff;
  color: var(--c-ink);
  padding: 0 14px;
  font-size: 15px;
  font-weight: 500;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-v3 .field input::placeholder { color: #93a3ae; }

.auth-v3 .field input:focus {
  border-color: #7ed8d3;
  box-shadow: 0 0 0 4px rgba(14, 165, 160, 0.16);
}

.auth-v3 .auth-consent {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: #4c6170;
  font-size: 13px;
  line-height: 1.45;
}

.auth-v3 .auth-consent input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--c-accent-deep);
}

.auth-v3 .auth-consent a {
  color: var(--c-accent-deep);
  font-weight: 700;
}

.auth-v3 .auth-status {
  min-height: 0;
  margin: 0;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.4;
}

.auth-v3 .auth-status:empty { display: none; }

.auth-v3 .auth-status[data-tone="error"] {
  padding: 10px 12px;
  background: #fff1f2;
  color: #9f2430;
}

.auth-v3 .auth-status[data-tone="pending"] {
  padding: 10px 12px;
  background: #f4f7f9;
  color: #3d5160;
}

.auth-v3 .auth-status[data-tone="ok"] {
  padding: 10px 12px;
  background: var(--c-accent-soft);
  color: #0b5f5b;
}

.auth-v3 .auth-submit {
  min-height: 48px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #2dd4bf 0%, #0ea5a0 55%, #0b7f7a 100%);
  color: #041016;
  font-family: var(--font-ui);
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -0.02em;
  box-shadow: 0 12px 28px rgba(14, 165, 160, 0.32);
  cursor: pointer;
}

.auth-v3 .auth-submit:hover { filter: brightness(1.04); }

.auth-v3 .auth-submit:disabled {
  cursor: wait;
  filter: saturate(0.7);
  opacity: 0.72;
}

.auth-v3 .link-button {
  justify-self: center;
  border: 0;
  background: transparent;
  color: var(--c-accent-deep);
  padding: 0;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.auth-v3 .link-button:hover { text-decoration: underline; }

.auth-v3 .auth-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 16px;
  margin: 2px 0 0;
}

.auth-v3 .auth-links a {
  color: #60707c;
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.auth-v3 .auth-links a:hover { color: var(--c-ink); }

@media (max-width: 860px) {
  .auth-v3 .tab { padding: 0 8px; font-size: 12px; white-space: nowrap; }
  .auth-v3 .auth-shell { grid-template-columns: 1fr; }
  .auth-v3 .auth-brand { gap: 18px; padding: 22px 20px 20px; }
  .auth-v3 .auth-brand-copy { margin-top: 8px; }
  .auth-v3 h1 { max-width: none; font-size: 36px; }
  .auth-v3 .auth-points { display: none; }
  .auth-v3 .auth-stage { padding: 18px 16px 28px; align-items: start; }
  .auth-v3 .auth-card { padding: 22px 18px; }
}
