:root {
  --sh-primary: #692291;
  --sh-primary-dark: #15077b;
  --sh-primary-light: #ede6f1;
  --sh-text: #444444;
  --sh-muted: #686d74;
  --sh-bg: #f9f9f9;
  --sh-heading: #000000;
  --sh-error: #ed3c0d;
  --sh-success: #18d26e;
  --sh-border: #ced4da;
  --sh-placeholder: #9aa0a6;
  --sh-radius: 4px;
  --sh-card-shadow: 0 10px 29px 0 rgba(68, 88, 144, 0.1);
}

* {
  box-sizing: border-box;
}

body.auth-page {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 24px 16px;
  background: var(--sh-bg);
  color: var(--sh-text);
  font-family: "Open Sans", sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  padding: 40px 40px 32px;
  background: #fff;
  border-radius: 8px;
  box-shadow: var(--sh-card-shadow);
}

.auth-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 24px;
}

.auth-brand img {
  height: 72px;
  width: auto;
}

.auth-wordmark {
  margin-top: 10px;
  font-family: "Grenze Gotisch", cursive;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.5px;
  line-height: 1;
  color: var(--sh-heading);
  text-transform: uppercase;
}

.auth-title {
  margin: 0 0 4px;
  font-family: "Grenze Gotisch", cursive;
  font-size: 40px;
  font-weight: 800;
  line-height: 1.1;
  color: var(--sh-heading);
  text-align: center;
}

.auth-title::after {
  content: "";
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-left: 0.15em;
  border-radius: 50%;
  background-color: var(--sh-primary);
}

.auth-subtitle {
  margin: 0 0 24px;
  color: var(--sh-muted);
  text-align: center;
}

.auth-form .form-group {
  margin-bottom: 16px;
}

.auth-form label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--sh-text);
}

.form-input {
  width: 100%;
  height: 44px;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 14px;
  color: var(--sh-text);
  background: #fff;
  border: 1px solid var(--sh-border);
  border-radius: var(--sh-radius);
  box-shadow: none;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.form-input::placeholder {
  color: var(--sh-placeholder);
}

.form-input:focus {
  outline: none;
  border-color: var(--sh-primary);
  box-shadow: 0 0 0 3px rgba(105, 34, 145, 0.12);
}

.auth-actions {
  display: flex;
  justify-content: flex-end;
  margin: 4px 0 20px;
}

.auth-link {
  color: var(--sh-primary);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.auth-link:hover {
  color: var(--sh-primary-dark);
  text-decoration: underline;
}

.btn-primary {
  width: 100%;
  padding: 12px 24px;
  font-family: "Dosis", sans-serif;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
  background: var(--sh-primary);
  border: 0;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.4s;
}

.btn-primary:hover {
  background: var(--sh-primary-dark);
}

.btn-primary:disabled {
  opacity: 0.75;
  cursor: default;
}

.btn-primary.is-loading::after {
  content: "";
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-left: 8px;
  vertical-align: -3px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-top-color: #fff;
  border-radius: 50%;
  animation: auth-spin 0.8s linear infinite;
}

@keyframes auth-spin {
  to {
    transform: rotate(360deg);
  }
}

.form-alert {
  padding: 15px;
  margin-bottom: 20px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  border-radius: var(--sh-radius);
}

.form-alert[hidden] {
  display: none;
}

.form-alert-error {
  background: var(--sh-error);
}

.form-alert-success {
  background: var(--sh-success);
  text-align: center;
}

.auth-footer {
  font-size: 12px;
  color: var(--sh-muted);
  text-align: center;
}

.auth-footer p {
  margin: 0;
}

.auth-footer a {
  color: var(--sh-muted);
  text-decoration: underline;
}

.auth-footer a:hover {
  color: var(--sh-primary);
}

@media (max-width: 480px) {
  .auth-card {
    padding: 28px 20px;
  }

  .auth-title {
    font-size: 32px;
  }

  .auth-brand img {
    height: 60px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn-primary,
  .form-input {
    transition: none;
  }
}