* {
  box-sizing: border-box;
}

:root {
  color: #fff;
  background: #020713;
  font-family: "Montserrat", Arial, sans-serif;
  font-synthesis: none;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  background: #020713;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.login-page {
  position: relative;
  min-height: 100vh;
  padding: 24px 64px 44px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 7%, rgba(55, 98, 158, 0.2), transparent 330px),
    radial-gradient(circle at 50% 62%, rgba(14, 57, 105, 0.24), transparent 520px),
    radial-gradient(circle at 50% 50%, rgba(255, 184, 42, 0.055), transparent 310px),
    linear-gradient(180deg, #020914 0%, #010711 100%);
}

.login-page::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.45) 0 1px, transparent 1px),
    radial-gradient(circle, rgba(255, 255, 255, 0.24) 0 1px, transparent 1px);
  background-position: 18px 70px, 96px 120px;
  background-size: 142px 142px, 192px 192px;
  opacity: 0.1;
}

.login-glow {
  position: absolute;
  top: 142px;
  left: 50%;
  width: 820px;
  height: 620px;
  transform: translateX(-50%);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 52%, rgba(40, 82, 138, 0.28), transparent 58%),
    radial-gradient(circle at 50% 42%, rgba(255, 190, 61, 0.07), transparent 48%);
  filter: blur(10px);
  pointer-events: none;
}

.login-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 72px;
}

.login-logo {
  display: block;
  width: 220px;
  text-decoration: none;
}

.login-logo img {
  display: block;
  width: 100%;
  height: auto;
}

.login-nav {
  position: absolute;
  top: 24px;
  right: 0;
  display: flex;
  align-items: center;
  color: rgba(231, 236, 247, 0.88);
}

.login-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: rgba(231, 236, 247, 0.88);
  font-size: 18px;
  line-height: 1;
  font-weight: 400;
  text-decoration: none;
  transition: color 160ms ease;
}

.login-nav-link:hover {
  color: #fff;
}

.login-nav-link svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-nav-link.is-active svg {
  color: #ffc43f;
}

.login-card {
  position: relative;
  z-index: 1;
  width: min(100%, 384px);
  min-height: 0;
  margin: 56px auto 0;
  padding: 24px 30px 27px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 20%, rgba(37, 76, 131, 0.18), transparent 280px),
    linear-gradient(180deg, rgba(5, 15, 33, 0.68), rgba(4, 13, 28, 0.58));
  border: 1px solid rgba(145, 166, 205, 0.32);
  border-radius: 14px;
  box-shadow:
    inset 0 0 46px rgba(67, 104, 161, 0.1),
    0 30px 105px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(6px);
}

.login-step[hidden] {
  display: none;
}

.login-card-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 22px;
  color: rgba(226, 233, 246, 0.95);
  background: linear-gradient(180deg, rgba(25, 42, 73, 0.94), rgba(19, 34, 61, 0.88));
  border-radius: 16px;
  box-shadow: inset 0 0 26px rgba(105, 137, 190, 0.12);
}

.login-card-icon svg {
  width: 32px;
  height: 32px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-card h1 {
  margin: 0;
  color: #fff;
  font-size: 26px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0;
}

.login-copy {
  display: grid;
  gap: 6px;
  margin: 16px 0 28px;
  color: rgba(222, 228, 241, 0.82);
  font-size: 14px;
  line-height: 1.45;
  font-weight: 400;
}

.login-form {
  width: 100%;
  text-align: left;
}

.login-input-wrap {
  position: relative;
}

.login-input-wrap svg {
  position: absolute;
  top: 50%;
  left: 18px;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  fill: none;
  stroke: rgba(209, 219, 238, 0.82);
  stroke-width: 1.55;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-input-wrap input {
  width: 100%;
  height: 52px;
  padding: 0 18px 1px 52px;
  color: #fff;
  font-size: 16px;
  font-weight: 400;
  background: rgba(2, 11, 25, 0.38);
  border: 1px solid rgba(142, 163, 199, 0.34);
  border-radius: 10px;
  outline: none;
  box-shadow:
    inset 0 0 34px rgba(62, 99, 150, 0.08),
    0 0 0 1px rgba(6, 11, 24, 0.18);
}

.login-input-wrap input:focus {
  border-color: rgba(255, 199, 73, 0.78);
  box-shadow:
    inset 0 0 34px rgba(62, 99, 150, 0.1),
    0 0 0 3px rgba(255, 194, 71, 0.08);
}

.login-input-wrap input::placeholder {
  color: rgba(216, 224, 238, 0.76);
}

.login-message {
  min-height: 0;
  margin: 0;
  color: rgba(193, 201, 216, 0.8);
  font-size: 13px;
  line-height: 1.35;
}

.login-message.is-error {
  min-height: 21px;
  margin: 10px 0 12px;
  color: #ffb4a8;
}

.login-message.is-success {
  min-height: 21px;
  margin: 10px 0 12px;
  color: rgba(255, 202, 73, 0.95);
}

.login-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  height: 52px;
  margin-top: 14px;
  color: #05080d;
  font-size: 16px;
  line-height: 1;
  font-weight: 700;
  background: linear-gradient(180deg, #ffd965 0%, #ffc33e 46%, #ffbd37 100%);
  border: 0;
  border-radius: 10px;
  box-shadow:
    0 0 38px rgba(255, 184, 51, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition:
    filter 160ms ease,
    transform 160ms ease;
}

.login-submit:hover {
  filter: brightness(1.035);
  transform: translateY(-1px);
}

.login-submit svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-or {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  margin: 28px 0 22px;
  color: rgba(222, 228, 241, 0.82);
}

.login-or span {
  height: 1px;
  background: rgba(149, 166, 198, 0.28);
}

.login-or b {
  font-size: 13px;
  line-height: 1;
  font-weight: 400;
}

.login-back {
  margin: 0;
  color: rgba(222, 228, 241, 0.82);
  font-size: 14px;
  line-height: 1.4;
  font-weight: 400;
}

.login-back a {
  color: #ffc43f;
  text-decoration: none;
  transition: color 160ms ease;
}

.login-back a:hover {
  color: #ffd56a;
}

.login-support {
  margin: 30px 0 0;
  color: rgba(222, 228, 241, 0.82);
  font-size: 14px;
  line-height: 1.3;
  font-weight: 400;
}

.login-support a {
  color: #ffc43f;
  text-decoration: none;
}

.login-support a:hover {
  color: #ffd56a;
}

.pin-back {
  position: absolute;
  top: 25px;
  left: 30px;
  padding: 0;
  color: rgba(222, 228, 241, 0.82);
  font-size: 14px;
  line-height: 1;
  font-weight: 500;
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: color 160ms ease;
}

.pin-back:hover {
  color: #ffc43f;
}

.pin-icon {
  margin-top: 8px;
}

.pin-copy {
  display: block;
  max-width: 340px;
  margin-right: auto;
  margin-left: auto;
  margin-bottom: 28px;
}

.pin-email {
  color: #ffc43f;
  white-space: nowrap;
}

.pin-form {
  text-align: center;
}

.pin-fields {
  display: grid;
  grid-template-columns: repeat(4, 62px);
  justify-content: center;
  gap: 12px;
}

.pin-input {
  width: 62px;
  height: 62px;
  color: #fff;
  font-size: 26px;
  line-height: 1;
  font-weight: 700;
  text-align: center;
  background: rgba(2, 11, 25, 0.38);
  border: 1px solid rgba(142, 163, 199, 0.36);
  border-radius: 12px;
  outline: none;
  box-shadow:
    inset 0 0 28px rgba(62, 99, 150, 0.08),
    0 0 0 1px rgba(6, 11, 24, 0.18);
}

.pin-input:focus {
  border-color: rgba(255, 199, 73, 0.8);
  box-shadow:
    inset 0 0 28px rgba(62, 99, 150, 0.1),
    0 0 0 3px rgba(255, 194, 71, 0.08);
}

.pin-message {
  min-height: 20px;
  margin: 14px 0 0;
  color: rgba(255, 202, 73, 0.95);
  font-size: 13px;
  line-height: 1.4;
  font-weight: 500;
}

.pin-resend {
  margin: 20px 0 0;
  color: rgba(222, 228, 241, 0.82);
  font-size: 14px;
  line-height: 1.35;
  font-weight: 500;
  background: transparent;
  border: 0;
  cursor: default;
}

.pin-resend:not(:disabled) {
  color: #ffc43f;
  cursor: pointer;
}

.pin-resend:not(:disabled):hover {
  color: #ffd56a;
}

.pin-hint {
  margin: 18px 0 0;
  color: rgba(222, 228, 241, 0.68);
  font-size: 13px;
  line-height: 1.4;
}

@media (max-width: 900px) {
  .login-page {
    padding: 28px 20px 42px;
  }

  .login-header {
    align-items: flex-start;
    min-height: 108px;
  }

  .login-logo {
    width: 220px;
  }

  .login-nav {
    top: 68px;
    right: 50%;
    transform: translateX(50%);
  }

  .login-card {
    min-height: auto;
    margin-top: 54px;
    padding: 34px 28px 38px;
  }

  .pin-back {
    top: 24px;
    left: 26px;
  }
}

@media (max-width: 560px) {
  .login-page {
    padding: 22px 16px 34px;
  }

  .login-logo {
    width: 194px;
  }

  .login-nav {
    gap: 14px;
  }

  .login-nav-link {
    gap: 8px;
    font-size: 14px;
  }

  .login-nav-link svg {
    width: 19px;
    height: 19px;
  }

  .login-card {
    margin-top: 36px;
    padding: 28px 20px 30px;
    border-radius: 14px;
  }

  .login-card-icon {
    width: 78px;
    height: 78px;
    margin-bottom: 24px;
  }

  .login-card-icon svg {
    width: 39px;
    height: 39px;
  }

  .login-card h1 {
    font-size: 26px;
  }

  .login-copy {
    margin: 20px 0 30px;
    font-size: 15px;
  }

  .login-input-wrap input {
    height: 58px;
    padding-left: 58px;
    font-size: 16px;
    border-radius: 11px;
  }

  .login-input-wrap svg {
    left: 21px;
    width: 22px;
    height: 22px;
  }

  .login-submit {
    height: 58px;
    gap: 12px;
    font-size: 17px;
    border-radius: 11px;
  }

  .login-submit svg {
    width: 23px;
    height: 23px;
  }

  .login-or {
    gap: 14px;
    margin: 28px 0 24px;
  }

  .login-back,
  .login-support {
    font-size: 15px;
  }

  .login-support {
    margin-top: 34px;
  }

  .pin-back {
    position: static;
    display: block;
    margin: 0 0 22px;
    font-size: 15px;
    text-align: left;
  }

  .pin-icon {
    margin-top: 0;
  }

  .pin-copy {
    margin-bottom: 28px;
  }

  .pin-fields {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
  }

  .pin-input {
    width: 100%;
    height: 62px;
    font-size: 26px;
    border-radius: 12px;
  }

  .pin-message {
    font-size: 13px;
  }

  .pin-resend,
  .pin-hint {
    font-size: 14px;
  }
}
