* {
  box-sizing: border-box;
}

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

body {
  background: #0a1018;
}

.loginShell {
  min-height: 100vh;
  position: relative;
  display: grid;
  place-items: center;
  padding: 28px 16px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.92);
  font-family: Roboto, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.loginBackdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 38%, rgba(65, 104, 255, 0.22), transparent 34%),
    linear-gradient(145deg, #0a1018 0%, #15124a 48%, #3b1555 100%);
}

.loginLayer {
  position: absolute;
  inset: 0;
}

.loginLayerBase {
  background:
    radial-gradient(circle at 18% 22%, rgba(0, 122, 255, 0.16), transparent 26%),
    radial-gradient(circle at 80% 78%, rgba(255, 87, 142, 0.14), transparent 28%);
}

.loginLayerGlow {
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.07), transparent 46%, rgba(255, 255, 255, 0.05));
}

.loginLayerPattern {
  opacity: 0.24;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(circle at center, black 0%, transparent 74%);
}

.loginCard {
  width: min(408px, 100%);
  min-height: 620px;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  justify-items: center;
  gap: 28px;
  padding: 72px 28px 24px;
}

.loginLogo {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 48px;
  margin-top: 70px;
  color: white;
}

.loginLogoIcon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  object-fit: cover;
  flex: 0 0 auto;
  box-shadow: 0 12px 32px rgba(66, 119, 255, 0.28);
}

.loginFormBlock {
  width: 100%;
  display: grid;
  align-content: center;
  gap: 18px;
  margin-top: 8px;
}

.loginExplainer {
  display: grid;
  gap: 6px;
  text-align: center;
}

.loginExplainer h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.15;
  font-weight: 800;
}

.loginExplainer p {
  margin: 0;
  color: rgba(255, 255, 255, 0.62);
  font-size: 15px;
  font-weight: 500;
}

.loginField {
  display: grid;
  gap: 7px;
}

.loginPhoneInput {
  min-height: 56px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.loginPhoneInput:focus-within {
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.2);
}

.loginFlag {
  display: grid;
  place-items: center;
  padding-left: 14px;
}

.loginPhoneInput input {
  min-height: 54px;
  border: 0;
  border-radius: 0;
  padding: 0 16px 0 8px;
  background: transparent;
  color: white;
  font-size: 17px;
  outline: 0;
  box-shadow: none;
}

.loginPhoneInput input::placeholder {
  color: rgba(255, 255, 255, 0.34);
}

.loginPasswordInput {
  grid-template-columns: 1fr;
}

.loginPasswordInput input {
  padding-left: 16px;
}

.loginHint {
  margin: 0;
  color: rgba(255, 255, 255, 0.5);
  font-size: 13px;
  text-align: left;
}

.loginError {
  margin: -4px 0 0;
  color: #ff5d67;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

.loginButton {
  width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.93);
  color: #111318;
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
}

.loginButton:disabled {
  cursor: default;
  opacity: 0.38;
}

.loginBackButton {
  min-height: 34px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.62);
  font-weight: 700;
  cursor: pointer;
}

.otpCells {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.otpCell {
  width: 100%;
  aspect-ratio: 1;
  min-height: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.11);
  color: white;
  text-align: center;
  font-size: 24px;
  font-weight: 800;
  outline: 0;
  padding: 0;
}

.otpCell:focus {
  border-color: rgba(255, 255, 255, 0.34);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.2);
}

.loginDone {
  align-self: center;
  display: grid;
  justify-items: center;
  gap: 12px;
  text-align: center;
}

.loginDoneIcon {
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #0a1018;
  background: rgba(255, 255, 255, 0.92);
}

.loginDone h1 {
  margin: 0;
  font-size: 28px;
}

.loginDone p {
  margin: 0;
  color: rgba(255, 255, 255, 0.64);
}

.loginFooter {
  max-width: 336px;
  color: rgba(255, 255, 255, 0.48);
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

.loginFooter a {
  color: rgba(255, 255, 255, 0.76);
  text-decoration: none;
}

.isHidden {
  display: none !important;
}

@media (max-width: 480px) {
  .loginShell {
    align-items: stretch;
    padding: 0 18px;
  }

  .loginCard {
    min-height: 100vh;
    width: 100%;
    padding: 58px 0 22px;
  }
}
