.reg-open { overflow: hidden; padding-right: var(--reg-sbw, 0); }

.reg {
  --reg-1000: #180d24;
  --reg-900: #231333;
  --reg-850: #9483a5;
  --reg-800: #4d3069;
  --reg-eggplant: #4c2959;
  --reg-c300: #b68cd8;
  --reg-c200: #c5a1e0;
  --reg-orange: #fe5104;
  --reg-purple: #bd4df9;
  --reg-error: #d42b5e;
  --reg-line: rgb(182 140 216 / 0.3);
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font-family: "Inter", "Inter Fallback", system-ui, sans-serif;
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.21;
  letter-spacing: 0;
  text-transform: none;
  -webkit-font-smoothing: antialiased;
}
.reg[open] { display: flex; }
.reg::backdrop { background: #231333; }

.reg__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: linear-gradient(180deg, var(--reg-900) 15%, var(--reg-eggplant) 75%);
}
.reg__panel:focus { outline: none; }

.reg__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1rem 1rem 0;
}
.reg__title {
  margin: 0;
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.21;
  letter-spacing: 0;
  text-transform: none;
  color: var(--reg-c300);
}
.reg__close {
  display: grid;
  place-items: center;
  flex: none;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--reg-1000);
  color: var(--reg-c200);
  cursor: pointer;
  transition: color 0.2s;
}
.reg__close svg { width: 1rem; height: 1rem; fill: currentColor; }
.reg__close:hover { color: #fff; }

.reg__body {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
  padding: 1rem 1rem 1.5rem;
}
.reg__body[hidden] { display: none; }

.reg__age {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}
.reg__age::before,
.reg__age::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--reg-line);
}
.reg__age picture { display: block; flex: none; }
.reg__star { display: block; flex: none; width: 4.0625rem; height: 4.0625rem; }

.reg__social {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.9375rem;
}
.reg__soc {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  height: 2.75rem;
  padding: 0 1rem;
  border-radius: 1.375rem;
  background: var(--reg-800);
  color: #fff;
  font-weight: 500;
  font-size: 0.875rem;
  line-height: 1.21;
  text-decoration: none;
  transition: filter 0.2s;
}
.reg__soc:hover { filter: brightness(1.12); }
.reg__soc-icon { display: grid; place-items: center; flex: none; width: 1rem; height: 1rem; }
.reg__soc-icon svg { width: 100%; height: 100%; }

.reg__or {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  height: 1.25rem;
  margin: 1rem 0 0;
  color: var(--reg-c300);
  font-size: 0.875rem;
  line-height: 1.21;
}
.reg__or::before,
.reg__or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--reg-line);
}

.reg__form {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
  margin-top: 1.0875rem;
}
.reg__field {
  display: grid;
  gap: 0.65625rem;
}
.reg__field + .reg__field { margin-top: 1.165rem; }
.reg__label {
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.21;
  color: #fff;
}
.reg__input {
  display: block;
  width: 100%;
  height: 2.625rem;
  margin: 0;
  padding: 0 1rem;
  border: 1px solid transparent;
  border-radius: 1.3125rem;
  background: var(--reg-900);
  color: #fff;
  font-family: inherit;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.21;
  letter-spacing: 0;
  outline: none;
  transition: border-color 0.2s;
}
.reg__input::placeholder { color: var(--reg-850); opacity: 1; }
.reg__input:focus { border-color: var(--reg-c300); }
.reg__input.is-invalid { border-color: var(--reg-error); }
.reg__input:-webkit-autofill {
  -webkit-text-fill-color: #fff;
  box-shadow: 0 0 0 2.5rem var(--reg-900) inset;
}

.reg__pass { position: relative; }
.reg__pass .reg__input { padding-right: 3rem; }
.reg__eye {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--reg-c300);
  cursor: pointer;
  translate: 0 -50%;
}
.reg__eye svg { width: 1.5rem; height: 1.5rem; fill: currentColor; }
.reg__eye:hover { color: var(--reg-c200); }
.reg__eye-off { display: none; }
.reg__eye[aria-pressed="true"] .reg__eye-on { display: none; }
.reg__eye[aria-pressed="true"] .reg__eye-off { display: block; }

.reg__hint,
.reg__err {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.21;
}
.reg__hint { color: var(--reg-c300); }
.reg__hint.is-error,
.reg__err { color: var(--reg-error); }

.reg__alert {
  margin: 1.125rem 0 0;
  padding: 0.625rem 0.875rem;
  border: 1px solid var(--reg-error);
  border-radius: 0.75rem;
  background: rgb(212 43 94 / 0.12);
  color: #fff;
  font-size: 0.875rem;
  line-height: 1.3;
}
.reg__alert a {
  color: var(--reg-orange);
  text-decoration: none;
}

.reg__foot {
  margin-top: auto;
  padding-top: 1.5rem;
}
.reg__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  height: 2.75rem;
  margin: 0;
  padding: 0 1rem;
  border: 0;
  border-radius: 1.375rem;
  background: linear-gradient(141.6deg, var(--reg-orange) -6%, var(--reg-purple) 106%);
  color: #fff;
  font-family: inherit;
  font-weight: 500;
  font-size: 0.875rem;
  line-height: 1.21;
  letter-spacing: 0;
  text-transform: none;
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s;
}
.reg__submit:hover { filter: brightness(1.06); }
.reg__submit:active { transform: scale(0.99); }
.reg__submit:disabled { cursor: progress; opacity: 0.85; }
.reg__submit.is-busy::before {
  content: "";
  width: 1rem;
  height: 1rem;
  border: 0.125rem solid rgb(255 255 255 / 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: reg-spin 0.8s linear infinite;
}

.reg__login {
  margin: 1.625rem 0 0;
  color: var(--reg-c200);
  font-size: 0.875rem;
  line-height: 1.21;
  text-align: center;
}
.reg__login a {
  color: var(--reg-orange);
  text-decoration: none;
}
.reg__login a:hover,
.reg__alert a:hover { text-decoration: underline; text-underline-offset: 0.1875rem; }

.reg__done {
  align-items: center;
  justify-content: center;
  gap: 1rem;
  text-align: center;
}
.reg__done-icon {
  display: grid;
  place-items: center;
  width: 4rem;
  height: 4rem;
  margin-bottom: 0.5rem;
  border-radius: 50%;
  background: linear-gradient(141.6deg, var(--reg-orange) 0%, var(--reg-purple) 100%);
}
.reg__done-icon svg {
  width: 1.75rem;
  height: 1.75rem;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.reg__done-title {
  margin: 0;
  font-weight: 500;
  font-size: 1.25rem;
  line-height: 1.21;
  letter-spacing: 0;
  text-transform: none;
  color: #fff;
  outline: none;
}
.reg__done-text {
  max-width: 18.5rem;
  margin: 0;
  color: var(--reg-c200);
  font-size: 0.875rem;
  line-height: 1.45;
}
.reg__done-text strong { color: #fff; font-weight: 500; overflow-wrap: anywhere; }
.reg__resend {
  width: 100%;
  height: 2.75rem;
  margin-top: 0.5rem;
  padding: 0 1rem;
  border: 0;
  border-radius: 1.375rem;
  background: var(--reg-800);
  color: #fff;
  font-family: inherit;
  font-weight: 500;
  font-size: 0.875rem;
  cursor: pointer;
  transition: filter 0.2s;
}
.reg__resend:hover:not(:disabled) { filter: brightness(1.12); }
.reg__resend:disabled { cursor: default; color: var(--reg-c300); }
.reg__status { min-height: 1.0625rem; margin: 0; color: var(--reg-c300); font-size: 0.875rem; }

.reg :focus-visible {
  outline: 0.125rem solid #fff;
  outline-offset: 0.125rem;
}
.reg .reg__input:focus-visible { outline: none; }

@media (max-width: 767.98px) {
  html.reg-open,
  html.reg-open body { background-color: #231333; }
}

@media (min-width: 768px) {
  .reg[open] {
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
  }
  .reg::backdrop {
    background: rgb(24 13 36 / 0.8);
    backdrop-filter: blur(0.375rem);
  }
  .reg__panel {
    width: 22.5rem;
    height: 44.375rem;
    max-height: 100%;
    border-radius: 1.5rem;
    box-shadow: 0 1.875rem 5rem -1.5rem rgb(0 0 0 / 0.7);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .reg[open] .reg__panel,
  .reg[open]::backdrop { animation: reg-fade 0.22s ease-out both; }
  .reg[open] .reg__star { animation: reg-star 0.6s cubic-bezier(0.2, 1.4, 0.4, 1) 0.1s both; }
}

@media (min-width: 768px) and (prefers-reduced-motion: no-preference) {
  .reg[open] .reg__panel { animation: reg-up 0.42s cubic-bezier(0.2, 0.9, 0.25, 1) both; }
  .reg[open]::backdrop { animation: reg-fade 0.3s ease both; }
}

@keyframes reg-up { from { opacity: 0; translate: 0 2rem; } to { opacity: 1; translate: 0 0; } }
@keyframes reg-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes reg-star { from { opacity: 0; scale: 0.4; rotate: -90deg; } to { opacity: 1; scale: 1; rotate: 0deg; } }
@keyframes reg-spin { to { rotate: 360deg; } }
