:root {
  --registration-bg: #07090f;
  --registration-ink: rgba(255, 255, 255, 0.96);
  --registration-ink-muted: rgba(255, 255, 255, 0.66);
  --registration-line: rgba(255, 255, 255, 0.12);
  --registration-card-bg: rgba(8, 10, 18, 0.52);
  --registration-card-border: rgba(255, 255, 255, 0.1);
  --registration-bg-shift: 10vh;
}

html:has(.registration-stage),
body:has(.registration-stage) {
  margin: 0;
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
}

body:has(.registration-stage) {
  background: var(--registration-bg);
}

.registration-stage,
.registration-stage * {
  box-sizing: border-box;
}

.registration-stage {
  position: relative;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  isolation: isolate;
  color: var(--registration-ink);
  color-scheme: dark;
}

.registration-bg {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  width: 100%;
  height: calc(100vh + var(--registration-bg-shift));
  z-index: 0;
  background-image: var(--registration-hero-image);
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center center;
  transform: translateY(var(--registration-bg-shift));
}

.registration-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 50%, transparent 0%, rgba(7, 9, 15, 0.35) 55%, rgba(7, 9, 15, 0.78) 100%),
    linear-gradient(180deg, rgba(7, 9, 15, 0.55) 0%, rgba(7, 9, 15, 0.35) 45%, rgba(7, 9, 15, 0.65) 100%);
}

.registration-stage .page.page-center {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-height: auto;
  padding-top: calc(max(28px, calc(env(safe-area-inset-top) + 12px)) + 36px + 0.75rem);
}

.registration-shell {
  position: relative;
  padding-top: 0;
  padding-bottom: 0;
}

.registration-brand-wrap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  justify-content: center;
  padding: max(28px, calc(env(safe-area-inset-top) + 12px)) 22px 0;
  pointer-events: none;
}

.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  pointer-events: auto;
}

.auth-brand-logo {
  height: 36px;
  width: auto;
  display: block;
}

.auth-brand-divider {
  width: 1px;
  height: 30px;
  background: rgba(255, 255, 255, 0.22);
}

.auth-brand-product {
  color: var(--registration-ink);
  font-size: 28px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.015em;
}

.registration-card {
  border: 1px solid var(--registration-card-border);
  background: var(--registration-card-bg);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 20px 60px -16px rgba(0, 0, 0, 0.55);
  color: var(--registration-ink);
}

.registration-card .card-body {
  padding: calc(var(--tblr-card-spacer-y, 1.5rem) / 2) calc(var(--tblr-card-spacer-x, 1.5rem) / 2);
}

.registration-card .card-title,
.registration-card h1,
.registration-card h2 {
  color: var(--registration-ink);
}

.registration-card .text-secondary,
.registration-after-card {
  color: var(--registration-ink-muted) !important;
}

.registration-card .form-label,
.registration-card .form-check-label {
  color: var(--registration-ink-muted);
}

.registration-card .form-control,
.registration-card .form-select {
  background-color: rgba(255, 255, 255, 0.06);
  border-color: var(--registration-line);
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
  caret-color: #ffffff;
}

.registration-card .form-control::placeholder,
.registration-card .form-select::placeholder {
  color: rgba(255, 255, 255, 0.45);
  -webkit-text-fill-color: rgba(255, 255, 255, 0.45);
  opacity: 1;
}

.registration-card .form-control:focus,
.registration-card .form-select:focus {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(120, 170, 255, 0.55);
  box-shadow: 0 0 0 3px rgba(70, 140, 255, 0.14);
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
}

.registration-card .form-control:-webkit-autofill,
.registration-card .form-control:-webkit-autofill:hover,
.registration-card .form-control:-webkit-autofill:focus,
.registration-card .form-select:-webkit-autofill,
.registration-card .form-select:-webkit-autofill:hover,
.registration-card .form-select:-webkit-autofill:focus {
  -webkit-text-fill-color: #ffffff;
  caret-color: #ffffff;
  box-shadow: 0 0 0 1000px rgba(18, 20, 28, 0.98) inset;
  transition: background-color 99999s ease-out;
}

.registration-card .form-select {
  /* Keep Tabler's chevron; only override the fill color. */
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23c8d0dc' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}

.registration-card .form-select option {
  background-color: #12141c;
  color: var(--registration-ink);
}

.registration-card .input-group > .form-select:not(:last-child) {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.registration-card .g-recaptcha {
  display: table;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
  margin-bottom: 0.75rem;
}

.registration-card .input-group-text {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  min-width: 2.75rem;
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--registration-line);
  color: var(--registration-ink-muted);
}

.registration-card .input-group-text a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 100%;
  min-height: 2.375rem;
  padding: 0;
  line-height: 0;
}

.registration-card .input-group-text svg {
  display: block;
  flex-shrink: 0;
}

.registration-card .card-footer,
.registration-card .registration-card-footer {
  padding: calc(var(--tblr-card-spacer-y, 1.5rem) / 2) calc(var(--tblr-card-spacer-x, 1.5rem) / 2);
  background: rgba(255, 255, 255, 0.03);
  border-top: 1px solid var(--registration-line);
  color: var(--registration-ink-muted);
}

.registration-card .btn-link {
  color: rgba(147, 197, 253, 0.95);
  background: transparent;
  border: 0;
  box-shadow: none;
  text-decoration: none;
}

.registration-card .btn-link:hover,
.registration-card .btn-link:focus {
  color: rgba(191, 219, 254, 1);
  background: transparent;
  border: 0;
  box-shadow: none;
  text-decoration: underline;
}

.login-method-toggle {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.login-method-toggle-track {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.3rem;
  padding: 0.3rem;
  border: 1px solid var(--registration-line);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.registration-card .login-method-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.85rem;
  padding: 0.6rem 0.7rem;
  border: 1px solid transparent;
  border-radius: 0.6rem;
  background: transparent;
  color: var(--registration-ink-muted);
  font-weight: 600;
  line-height: 1.2;
  box-shadow: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.registration-card .login-method-btn:hover,
.registration-card .login-method-btn:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: transparent;
  color: var(--registration-ink);
}

.registration-card .login-method-btn.is-active,
.registration-card .login-method-btn.is-active:hover,
.registration-card .login-method-btn.is-active:focus {
  background: var(--tblr-primary, #206bc4);
  border-color: transparent;
  color: #ffffff;
  box-shadow: 0 8px 18px -10px rgba(32, 107, 196, 0.9);
}

.registration-card .login-method-btn:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(70, 140, 255, 0.22);
}

.registration-card .login-method-btn .icon {
  width: 1.15rem;
  height: 1.15rem;
  flex-shrink: 0;
  color: currentColor;
}

.login-sending-status .progress {
  height: 0.35rem;
  background: rgba(255, 255, 255, 0.08);
}

.login-sending-status .progress-bar-indeterminate {
  width: 40%;
  animation: login-progress-indeterminate 1.2s ease-in-out infinite;
}

@keyframes login-progress-indeterminate {
  0% {
    transform: translateX(-120%);
  }

  100% {
    transform: translateX(320%);
  }
}

.registration-after-card a,
.registration-card a:not(.btn) {
  color: rgba(147, 197, 253, 0.95);
}

.registration-after-card a:hover,
.registration-card a:not(.btn):hover {
  color: rgba(191, 219, 254, 1);
}

@media (max-width: 640px) {
  .auth-brand-logo {
    height: 32px;
  }

  .auth-brand-divider {
    height: 26px;
  }

  .auth-brand-product {
    font-size: 24px;
  }
}
