:root {
  --mp-bg: #2b2b2b;
  --mp-surface: #343a40;
  --mp-border: rgba(255, 255, 255, 0.14);
  --mp-cyan: #009ea0;
  --mp-cyan-hover: #00997c;
  --mp-green: #29c97c;
  --mp-gray: #6f6b67;
}

html,
body.auth-page {
  min-height: 100%;
}

body.auth-page {
  margin: 0;
  color: #ffffff;
  background:
    radial-gradient(circle at 12% 8%, rgba(0, 158, 160, 0.18), transparent 30rem),
    radial-gradient(circle at 88% 12%, rgba(41, 201, 124, 0.13), transparent 28rem),
    radial-gradient(circle at 42% 115%, rgba(0, 158, 160, 0.10), transparent 34rem),
    linear-gradient(145deg, #202323 0%, #303639 46%, #191d1f 100%);
  font-family: 'Roboto Condensed', sans-serif;
  overflow-x: hidden;
}

body.auth-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 50%, transparent 0 48%, rgba(0, 0, 0, 0.28) 100%),
    linear-gradient(115deg, transparent 0 24%, rgba(255, 255, 255, 0.055) 24.08% 24.16%, transparent 24.24% 100%),
    linear-gradient(148deg, transparent 0 62%, rgba(0, 158, 160, 0.12) 62.08% 62.20%, transparent 62.30% 100%);
  opacity: 0.64;
  animation: authConstellation 14s ease-in-out infinite alternate;
}

.login-dark {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 16px;
  position: relative;
  z-index: 1;
  overflow: hidden;
  isolation: isolate;
  perspective: 1200px;
}

.auth-orb-canvas {
  display: block;
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  opacity: 0.98;
  pointer-events: none;
}

@media (min-width: 768px) {
  .login-dark::after {
    display: none;
  }
}

.login-dark::before {
  content: "";
  position: absolute;
  inset: -18%;
  z-index: -2;
  background:
    radial-gradient(circle at 69% 44%, rgba(0, 158, 160, 0.24), transparent 28rem),
    radial-gradient(circle at 28% 54%, rgba(41, 201, 124, 0.12), transparent 24rem),
    linear-gradient(90deg, rgba(0, 0, 0, 0.20), transparent 45%, rgba(0, 0, 0, 0.18));
  opacity: 0.72;
  pointer-events: none;
  animation: authAmbientShift 18s ease-in-out infinite alternate;
}

.login-dark::after {
  content: "";
  position: absolute;
  width: min(74vw, 520px);
  height: min(74vw, 520px);
  right: -210px;
  top: 12%;
  z-index: -1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, rgba(0, 158, 160, 0.22), transparent 42%),
    repeating-conic-gradient(from 18deg, rgba(41, 201, 124, 0.18) 0 2deg, transparent 2deg 18deg);
  opacity: 0.34;
  -webkit-mask-image: radial-gradient(circle, transparent 0 42%, #000 43% 44%, transparent 45% 100%);
  mask-image: radial-gradient(circle, transparent 0 42%, #000 43% 44%, transparent 45% 100%);
  pointer-events: none;
  animation: authArtifactOrbit 20s linear infinite;
}

.login-dark form {
  width: min(92vw, 390px);
  padding: 32px;
  position: relative;
  z-index: 2;
  color: #ffffff;
  background: linear-gradient(145deg, rgba(52, 58, 64, 0.88), rgba(43, 43, 43, 0.86));
  border: 1px solid var(--mp-border);
  border-radius: 18px;
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.30),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(14px);
  animation: authCardIn 180ms ease-out;
}

@keyframes authCardIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes authConstellation {
  from { transform: translate3d(-8px, -6px, 0) scale(1); opacity: 0.52; }
  to { transform: translate3d(12px, 10px, 0) scale(1.018); opacity: 0.70; }
}

@keyframes authAmbientShift {
  from { transform: translate3d(-18px, -10px, 0) scale(1); }
  to { transform: translate3d(24px, 16px, 0) scale(1.035); }
}

@keyframes authArtifactOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.login-dark .illustration {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(0, 158, 160, 0.95), rgba(41, 201, 124, 0.86));
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 24px;
  font-size: 56px;
}

.login-dark .form-group {
  margin-bottom: 14px;
}

.login-dark form .form-control {
  height: 48px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  box-shadow: none;
  outline: none;
}

.login-dark form .form-control::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.login-dark form .form-control:focus {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.10);
  border-color: var(--mp-cyan);
  box-shadow: 0 0 0 0.18rem rgba(0, 158, 160, 0.18);
}

.login-dark .password-field {
  position: relative;
}

.login-dark .password-field .form-control {
  padding-right: 48px;
}

.login-pass-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  color: rgba(255, 255, 255, 0.62);
  line-height: 1;
  transform: translateY(-50%);
  transition: color 120ms ease;
}

.login-pass-icon:hover {
  color: var(--mp-green);
  cursor: pointer;
}

.login-dark form .btn-primary {
  position: relative;
  min-height: 48px;
  margin-top: 12px;
  padding: 11px 16px;
  overflow: hidden;
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(0, 158, 160, 0.95), rgba(41, 201, 124, 0.86)),
    var(--mp-cyan);
  border: 0;
  border-radius: 12px;
  box-shadow: none;
  font-size: 1.08rem;
  font-weight: 700;
  text-shadow: none;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  will-change: transform;
  isolation: isolate;
  transition: transform 160ms cubic-bezier(0.2, 0, 0.2, 1), background 160ms ease, box-shadow 160ms ease;
}

.login-dark form .btn-primary::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  padding: 1px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(103, 255, 230, 0.78), rgba(41, 201, 124, 0.76));
  pointer-events: none;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0.82;
  transition: opacity 160ms ease, background 160ms ease;
}

.login-dark form .btn-primary:hover,
.login-dark form .btn-primary:focus,
.login-dark form .btn-primary:active {
  color: #ffffff;
  background:
    radial-gradient(circle at 22% 18%, rgba(107, 255, 231, 0.22), transparent 46%),
    linear-gradient(135deg, rgba(0, 178, 180, 0.98), rgba(47, 224, 139, 0.96)),
    var(--mp-cyan);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
  outline: none;
  transform: translate3d(0, -1px, 0);
}

.login-dark form .btn-primary:hover::before,
.login-dark form .btn-primary:focus::before,
.login-dark form .btn-primary:active::before {
  background: linear-gradient(135deg, rgba(126, 255, 238, 0.98), rgba(56, 224, 141, 0.94));
  opacity: 1;
}

.login-dark form > p.text-center {
  margin: 0 0 16px;
  padding: 10px 12px;
  color: #ffffff;
  background: rgba(0, 158, 160, 0.14);
  border: 1px solid rgba(0, 158, 160, 0.26);
  border-radius: 12px;
}

.login-dark form .forgot {
  display: block;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.66);
  font-size: 13px;
  text-align: center;
  text-decoration: none;
  transition: color 120ms ease;
}

.login-dark form .forgot:hover,
.login-dark form .forgot:focus,
.login-dark form .forgot:active {
  color: #ffffff;
  text-decoration: none;
}

.pay_info {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.login-dark form .pay_info .forgot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  margin-top: 0;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.095);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.72);
  line-height: 1;
}

.login-dark form .pay_info .forgot:hover,
.login-dark form .pay_info .forgot:focus,
.login-dark form .pay_info .forgot:active {
  color: #ffffff;
  background: rgba(0, 158, 160, 0.18);
  border-color: rgba(0, 158, 160, 0.28);
}

.pay_info svg {
  display: block;
  width: 116px;
  height: 28px;
  margin: 2px auto 0;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.88);
  border-radius: 8px;
  box-sizing: content-box;
  flex-basis: 116px;
}

.logo {
  height: 20px;
}

html[data-theme="light"] body.auth-page {
  color: #153236;
  background:
    radial-gradient(circle at 10% 6%, rgba(0, 158, 160, 0.16), transparent 28rem),
    radial-gradient(circle at 88% 10%, rgba(41, 201, 124, 0.14), transparent 30rem),
    radial-gradient(circle at 48% 112%, rgba(0, 158, 160, 0.11), transparent 34rem),
    linear-gradient(145deg, #f7fbfb 0%, #edf5f4 48%, #dfecec 100%);
}

html[data-theme="light"] body.auth-page::before {
  background:
    radial-gradient(ellipse at 50% 50%, transparent 0 52%, rgba(0, 112, 116, 0.10) 100%),
    linear-gradient(115deg, transparent 0 24%, rgba(0, 112, 116, 0.10) 24.08% 24.16%, transparent 24.24% 100%),
    linear-gradient(148deg, transparent 0 62%, rgba(41, 201, 124, 0.12) 62.08% 62.20%, transparent 62.30% 100%);
  opacity: 0.72;
}

html[data-theme="light"] .auth-orb-canvas {
  opacity: 0.88;
}

html[data-theme="light"] .login-dark::before {
  background:
    radial-gradient(circle at 68% 44%, rgba(0, 158, 160, 0.18), transparent 28rem),
    radial-gradient(circle at 29% 55%, rgba(41, 201, 124, 0.16), transparent 24rem),
    linear-gradient(90deg, rgba(255, 255, 255, 0.32), transparent 45%, rgba(255, 255, 255, 0.22));
  opacity: 0.84;
}

html[data-theme="light"] .login-dark::after {
  background:
    radial-gradient(circle at 50% 50%, rgba(0, 112, 116, 0.20), transparent 42%),
    repeating-conic-gradient(from 18deg, rgba(20, 144, 91, 0.22) 0 2deg, transparent 2deg 18deg);
  opacity: 0.42;
}

html[data-theme="light"] .login-dark form {
  color: #153236;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.90), rgba(238, 247, 247, 0.86));
  border-color: rgba(22, 58, 62, 0.14);
  box-shadow:
    0 20px 46px rgba(29, 74, 76, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

html[data-theme="light"] .login-dark .illustration {
  color: #ffffff;
  border-color: rgba(0, 112, 116, 0.18);
  box-shadow: 0 12px 28px rgba(0, 112, 116, 0.16);
}

html[data-theme="light"] .login-dark form .form-control {
  color: #153236;
  background: rgba(255, 255, 255, 0.76);
  border-color: rgba(22, 58, 62, 0.18);
}

html[data-theme="light"] .login-dark form .form-control::placeholder {
  color: rgba(21, 50, 54, 0.50);
}

html[data-theme="light"] .login-dark form .form-control:focus {
  color: #153236;
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(0, 158, 160, 0.70);
  box-shadow: 0 0 0 0.18rem rgba(0, 158, 160, 0.16);
}

html[data-theme="light"] .login-pass-icon {
  color: rgba(21, 50, 54, 0.54);
}

html[data-theme="light"] .login-pass-icon:hover {
  color: #009ea0;
}

html[data-theme="light"] .login-dark form > p.text-center {
  color: #164246;
  background: rgba(0, 158, 160, 0.10);
  border-color: rgba(0, 158, 160, 0.20);
}

html[data-theme="light"] .login-dark form .forgot {
  color: rgba(21, 50, 54, 0.66);
}

html[data-theme="light"] .login-dark form .forgot:hover,
html[data-theme="light"] .login-dark form .forgot:focus,
html[data-theme="light"] .login-dark form .forgot:active {
  color: #007f82;
}

html[data-theme="light"] .pay_info {
  border-top-color: rgba(22, 58, 62, 0.10);
}

html[data-theme="light"] .login-dark form .pay_info .forgot {
  color: #17464a;
  background: rgba(255, 255, 255, 0.64);
  border-color: rgba(0, 112, 116, 0.12);
}

html[data-theme="light"] .login-dark form .pay_info .forgot:hover,
html[data-theme="light"] .login-dark form .pay_info .forgot:focus,
html[data-theme="light"] .login-dark form .pay_info .forgot:active {
  color: #005f63;
  background: rgba(0, 158, 160, 0.11);
  border-color: rgba(0, 158, 160, 0.24);
}

html[data-theme="light"] .pay_info svg {
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 8px 18px rgba(29, 74, 76, 0.08);
}

@media (max-height: 720px) {
  .login-dark {
    align-items: flex-start;
  }
}

@media (max-width: 420px) {
  .login-dark {
    padding: 18px 12px;
  }

  .login-dark::before {
    inset: -18% -70%;
    opacity: 0.36;
  }

  .login-dark::after {
    width: 420px;
    height: 420px;
    right: -240px;
    top: 5%;
    opacity: 0.50;
  }

  .login-dark form {
    width: 100%;
    padding: 24px 18px;
  }

  .login-dark .illustration {
    width: 76px;
    height: 76px;
    margin-bottom: 20px;
    border-radius: 20px;
    font-size: 48px;
  }
}

@media (max-width: 767px) {
  .auth-orb-canvas {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-orb-canvas {
    display: none;
  }

  body.auth-page::before,
  .login-dark::before,
  .login-dark::after,
  .login-dark form {
    animation: none;
  }
}
