/* Registration / onboarding — scoped to the account creation page only. */

.auth-body {
  --auth-accent: #b88455;
  --auth-ink: #171714;
  --auth-muted: #706e67;
  --auth-help: #8a8880;
  --auth-line: #d9d9d9;
  --auth-input-bg: #fffcf7;
  --auth-danger: #b42318;
  --auth-ui: "Inter", "DM Sans", system-ui, sans-serif;
  background: #f5f2eb;
  color: var(--auth-ink);
  font-family: var(--auth-ui);
  overflow-x: hidden;
}

.auth-body .app-footer {
  margin-top: 0;
}

.auth-top {
  height: 64px;
  border-bottom: 1px solid rgba(23, 23, 20, 0.1);
  background: #f5f2eb;
}

.auth-top-inner {
  width: min(1160px, calc(100% - 48px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-wordmark {
  font-family: "Instrument Serif", Georgia, serif;
  font-size: 1.28rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  color: var(--auth-ink);
}

.auth-wordmark:focus-visible,
.auth-top-login:focus-visible,
.auth-login a:focus-visible {
  outline: 2px solid var(--auth-accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.auth-top-login {
  color: var(--auth-ink);
  font-size: 0.875rem;
  font-weight: 600;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
.auth-top-login:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-shell {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 56px 0 80px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 520px);
  gap: 72px;
  align-items: start;
}

.auth-intro h1 {
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.75rem, 4.4vw, 4.15rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin: 0 0 16px;
  max-width: 14ch;
  color: var(--auth-ink);
}

.auth-eyebrow {
  font-family: "Space Mono", ui-monospace, monospace;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a877f;
  margin: 0 0 18px;
}

.auth-lead {
  margin: 0;
  max-width: 34ch;
  font-size: 0.98rem;
  line-height: 1.5;
  color: var(--auth-muted);
}

.auth-steps {
  list-style: none;
  margin: 40px 0 0;
  padding: 0;
  border-top: 1px solid rgba(23, 23, 20, 0.1);
  max-width: 380px;
}

.auth-steps li {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 10px;
  padding: 15px 0;
  border-bottom: 1px solid rgba(23, 23, 20, 0.1);
}

.auth-steps li span {
  font-family: "Space Mono", ui-monospace, monospace;
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--auth-muted);
  padding-top: 3px;
}

.auth-steps strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--auth-ink);
}

.auth-steps p {
  margin: 4px 0 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--auth-muted);
}

.auth-panel {
  width: 100%;
  max-width: 520px;
}

.auth-form {
  width: 100%;
}

.auth-form .errorlist {
  display: block;
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  max-width: 100%;
  color: var(--auth-danger);
  font-size: 0.78rem;
  line-height: 1.4;
  font-weight: 500;
}

.auth-form .errorlist.nonfield,
.auth-form > .errorlist {
  margin: 0 0 20px;
  padding: 10px 12px;
  border: 1px solid #f0c7c2;
  border-radius: 8px;
  background: #fbf2f1;
}

.auth-field {
  margin: 0 0 22px;
}

.auth-field label {
  display: block;
  margin: 0 0 7px;
  font-size: 0.84rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--auth-ink);
}

.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="url"] {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 54px;
  margin: 0;
  padding: 0 16px;
  border: 1px solid var(--auth-line);
  border-radius: 8px;
  background: var(--auth-input-bg);
  color: var(--auth-ink);
  font-family: inherit;
  font-size: 16px;
  line-height: 1.3;
  box-shadow: none;
}

.auth-form input::placeholder {
  color: #b0aea6;
}

.auth-form input:hover {
  border-color: #c8c8c4;
}

.auth-form input:focus {
  outline: none;
  border-color: var(--auth-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.auth-form input:focus-visible {
  outline: none;
  border-color: var(--auth-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.auth-password {
  position: relative;
}

.auth-password input {
  padding-right: 48px;
}

.auth-password-toggle {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: 0;
  background: transparent;
  color: var(--auth-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 6px;
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  color: var(--auth-ink);
}

.auth-password-toggle:focus-visible {
  outline: 2px solid var(--auth-accent);
  outline-offset: 1px;
}

.auth-field.is-invalid input,
.auth-field.is-invalid .auth-slug,
.auth-form input:user-invalid,
.auth-slug:has(input:user-invalid) {
  border-color: #e3b6b2;
}

.auth-field.is-invalid input:focus,
.auth-form input:user-invalid:focus {
  border-color: var(--auth-danger);
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.12);
}

.auth-form input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 54px var(--auth-input-bg) inset;
  -webkit-text-fill-color: var(--auth-ink);
}

.auth-hint,
.auth-help,
.auth-form .helptext {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 6px 0 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--auth-help);
  overflow-wrap: break-word;
}

.auth-hint + .auth-help {
  margin-top: 3px;
}

.auth-help-url {
  font-family: "Space Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  color: #5c5a54;
  letter-spacing: -0.01em;
}

.auth-help-title {
  margin: 0 0 4px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #5c5a54;
}

.auth-help-reqs ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.auth-help-reqs li {
  position: relative;
  margin: 3px 0 0;
  padding-left: 12px;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--auth-help);
}

.auth-help-reqs li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #b0aea6;
}

.auth-slug {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 54px;
  padding: 0 4px 0 14px;
  border: 1px solid var(--auth-line);
  border-radius: 8px;
  background: var(--auth-input-bg);
}

.auth-slug:focus-within {
  border-color: var(--auth-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.auth-field.is-invalid .auth-slug:focus-within {
  border-color: var(--auth-danger);
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.12);
}

.auth-slug-affix {
  flex: none;
  font-family: "Space Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  color: #8a8880;
  white-space: nowrap;
  letter-spacing: -0.02em;
}

.auth-slug input[type="text"] {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  height: 52px;
  padding: 0 12px 0 6px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  box-shadow: none;
}

.auth-slug input[type="text"]:hover,
.auth-slug input[type="text"]:focus,
.auth-slug input[type="text"]:focus-visible,
.auth-slug input[type="text"]:user-invalid {
  border: 0;
  box-shadow: none;
}

.auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 54px;
  margin-top: 6px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  background: var(--auth-ink);
  color: #f7f5ef;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
}

.auth-submit span {
  margin-left: 8px;
  font-weight: 400;
}

.auth-submit:hover {
  background: #2c2c28;
}

.auth-submit:focus-visible {
  outline: 2px solid var(--auth-accent);
  outline-offset: 3px;
}

.auth-login {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin: 18px 0 0;
  min-height: 44px;
  font-size: 0.875rem;
  color: var(--auth-muted);
}

.auth-login a {
  color: var(--auth-ink);
  font-weight: 600;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.auth-login a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 1024px) {
  .auth-shell {
    width: min(960px, calc(100% - 40px));
    gap: 44px;
    padding-top: 44px;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 480px);
  }

  .auth-panel {
    max-width: 480px;
  }

  .auth-intro h1 {
    font-size: clamp(2.4rem, 5vw, 3.25rem);
  }

  .auth-top-inner {
    width: min(960px, calc(100% - 40px));
  }
}

@media (max-width: 840px) {
  .auth-steps {
    display: none;
  }

  .auth-intro h1 {
    max-width: 11ch;
  }
}

@media (max-width: 600px) {
  .auth-shell {
    grid-template-columns: 1fr;
    gap: 0;
    width: calc(100% - 40px);
    padding: 28px 0 56px;
  }

  .auth-intro {
    margin-bottom: 28px;
  }

  .auth-intro h1,
  .auth-lead {
    max-width: none;
  }

  .auth-intro h1 {
    font-size: 42px;
    line-height: 1.05;
    margin-bottom: 10px;
  }

  .auth-lead {
    font-size: 0.92rem;
  }

  .auth-panel {
    max-width: none;
  }

  .auth-top-inner {
    width: calc(100% - 40px);
  }

  .auth-form input[type="text"],
  .auth-form input[type="email"],
  .auth-form input[type="password"],
  .auth-form input[type="url"],
  .auth-submit {
    width: 100%;
  }

  .auth-slug {
    flex-direction: column;
    align-items: stretch;
    height: auto;
    min-height: 0;
    padding: 8px 0 0;
  }

  .auth-slug-affix {
    padding: 0 16px;
    font-size: 0.68rem;
  }

  .auth-slug input[type="text"] {
    width: 100%;
    height: 54px;
    padding: 0 16px;
  }
}

@media (max-width: 390px) {
  .auth-shell {
    width: calc(100% - 32px);
    padding: 24px 0 48px;
  }

  .auth-top-inner {
    width: calc(100% - 32px);
  }

  .auth-intro h1 {
    font-size: 40px;
  }

  .auth-wordmark {
    font-size: 1.15rem;
  }
}

.auth-invite-wrap {
  margin-top: 8px;
  padding-top: 22px;
  border-top: 1px solid var(--auth-line);
}
.auth-invite-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 16px 16px 14px;
  background: #f3f0ea;
  border-radius: 16px;
}
.auth-invite-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #ece8e0;
  color: #6f6c64;
  display: grid;
  place-items: center;
}
.auth-invite-icon svg {
  width: 18px;
  height: 18px;
  display: block;
}
.auth-invite-title {
  margin: 2px 0 4px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--auth-ink);
}
.auth-invite-copy {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--auth-muted);
}
.auth-invite-copy a {
  color: var(--auth-ink);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
