/* Register page
   Works together with login.css on the same page: it reuses the color
   variables (--lime, --lime-deep, --red, ...) and the shared input/button
   base styles from there. */

/* ---------- Register card ---------- */

#register-page {
  position: relative;
  width: min(100%, 380px);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 2rem;
  background: rgba(24, 10, 32, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.55),
    0 0 70px rgba(138, 58, 163, 0.25);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

/* the same tiny pulsing red dot as the login card */
#register-page::after {
  content: "";
  position: absolute;
  top: 16px;
  right: 16px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 10px 2px rgba(255, 77, 94, 0.7);
  animation: pulse 2.4s ease-in-out infinite;
}

#register-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* ---------- Register button ---------- */

#register-btn {
  margin-top: 0.5rem;
  background: linear-gradient(135deg, var(--lime-deep), var(--lime));
  color: #10091a;
  box-shadow: 0 10px 30px rgba(181, 240, 28, 0.25);
}

#register-btn:hover:not(:disabled) {
  filter: brightness(1.08);
  box-shadow: 0 12px 38px rgba(181, 240, 28, 0.38);
}

/* secondary button: same look as "Create your own!" on the login card */
#back-btn {
  background: rgba(138, 58, 163, 0.14);
  border-color: rgba(255, 255, 255, 0.14);
  color: #d9c8e4;
}

#back-btn:hover:not(:disabled) {
  border-color: var(--lime);
  color: var(--lime);
  background: rgba(181, 240, 28, 0.06);
}

@media (prefers-reduced-motion: reduce) {
  #register-page::after {
    animation: none;
  }
}

/* while an error is showing, the fields get a soft red edge (same as login) */
#register-form:has(.login-message.error:not([hidden])) input:not(:focus) {
  border-color: rgba(255, 77, 94, 0.55);
}