.auth-page {
  min-height: 100svh;
  background:
    linear-gradient(90deg, rgba(7, 9, 8, 0.96), rgba(7, 9, 8, 0.72)),
    url("assets/hero-workspace.png") center / cover fixed;
}

.auth-shell {
  min-height: 100svh;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  display: grid;
  align-content: center;
  gap: 28px;
  padding: 48px 0;
}

.auth-brand {
  width: max-content;
  color: var(--ink);
  font-size: 18px;
  font-weight: 760;
  text-decoration: none;
}

.auth-panel {
  width: min(460px, 100%);
  padding: clamp(24px, 5vw, 38px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 21, 20, 0.84);
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(18px);
}

.auth-panel h1 {
  margin-bottom: 28px;
  font-size: clamp(44px, 8vw, 76px);
}

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

.auth-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.auth-form input {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 14px;
  background: rgba(248, 244, 234, 0.08);
  color: var(--ink);
  font: inherit;
  outline: none;
}

.auth-form input:focus {
  border-color: var(--accent-strong);
  box-shadow: 0 0 0 3px rgba(242, 189, 121, 0.18);
}

.auth-form input::placeholder {
  color: rgba(201, 192, 179, 0.62);
}

.password-field {
  position: relative;
  display: block;
}

.password-field input {
  padding-right: 68px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  min-width: 50px;
  min-height: 34px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--accent-strong);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 760;
}

.password-toggle:hover,
.password-toggle:focus-visible {
  background: rgba(242, 189, 121, 0.12);
  outline: none;
}

.email-builder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 244, 234, 0.08);
  overflow: hidden;
}

.email-builder:focus-within {
  border-color: var(--accent-strong);
  box-shadow: 0 0 0 3px rgba(242, 189, 121, 0.18);
}

.email-builder input {
  min-height: 48px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.email-builder input:focus {
  border-color: transparent;
  box-shadow: none;
}

.email-builder > span {
  padding: 0 14px 0 10px;
  color: var(--accent-strong);
  font-weight: 760;
  white-space: nowrap;
}

.code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 128px;
  align-items: end;
  gap: 10px;
}

.code-row .button {
  min-height: 50px;
  margin: 0;
  padding: 0 12px;
  font-size: 14px;
}

.auth-form .button {
  width: 100%;
  margin-top: 8px;
  cursor: pointer;
  font: inherit;
}

.auth-message {
  min-height: 22px;
  margin: 0;
  color: var(--green);
  font-size: 14px;
  line-height: 1.55;
}

.auth-message.error {
  color: var(--accent-strong);
}

.auth-switch {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.auth-switch.compact {
  margin-top: 8px;
}

.auth-switch a {
  color: var(--accent-strong);
  font-weight: 760;
}

@media (max-width: 560px) {
  .auth-shell {
    justify-content: stretch;
  }

  .code-row {
    grid-template-columns: 1fr;
  }
}
