:root {
  --cyan: #00f0ff;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --pink: #ff00e6;

  --background: #02030a;
  --panel: rgba(5, 10, 25, 0.82);

  --border: rgba(0, 240, 255, 0.22);

  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.55);

  --danger: #ff4268;
}


* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


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


body {
  min-height: 100vh;

  background: var(--background);

  color: var(--text);

  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "SF Pro Display",
    "Segoe UI",
    "Microsoft YaHei",
    sans-serif;

  overflow: hidden;
}


/* =========================================================
   背景
========================================================= */

.background {
  position: fixed;

  inset: 0;

  overflow: hidden;

  background:
    radial-gradient(
      circle at 20% 80%,
      rgba(139, 92, 246, 0.18),
      transparent 40%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(0, 240, 255, 0.16),
      transparent 42%
    ),
    radial-gradient(
      circle at 50% 50%,
      rgba(255, 0, 230, 0.06),
      transparent 55%
    );

  z-index: 0;
}


#particles {
  position: absolute;

  inset: 0;

  width: 100%;
  height: 100%;

  pointer-events: none;
}


.grid {
  position: absolute;

  inset: -50%;

  background-image:
    linear-gradient(
      rgba(0, 240, 255, 0.035) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(0, 240, 255, 0.035) 1px,
      transparent 1px
    );

  background-size: 50px 50px;

  transform: perspective(600px) rotateX(60deg);

  transform-origin: center bottom;

  opacity: 0.8;
}


.scanlines {
  position: absolute;

  inset: 0;

  pointer-events: none;

  background:
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      transparent 3px,
      rgba(0, 240, 255, 0.018) 4px
    );

  animation: scan 8s linear infinite;
}


@keyframes scan {

  from {
    background-position: 0 0;
  }

  to {
    background-position: 0 160px;
  }

}


/* =========================================================
   容器
========================================================= */

.auth-container {
  position: relative;

  z-index: 10;

  width: 100%;
  min-height: 100vh;

  display: flex;

  justify-content: center;
  align-items: center;

  padding: 24px;
}


/* =========================================================
   登录卡片
========================================================= */

.auth-card {

  width: min(440px, 100%);

  padding: 42px 38px 30px;

  background:
    linear-gradient(
      145deg,
      rgba(255,255,255,0.07),
      rgba(255,255,255,0.025)
    );

  border:

    1px solid
    rgba(0, 240, 255, 0.23);

  border-radius: 24px;

  backdrop-filter: blur(30px);

  -webkit-backdrop-filter: blur(30px);

  box-shadow:

    0 30px 80px
    rgba(0, 0, 0, 0.55),

    0 0 70px
    rgba(0, 240, 255, 0.06),

    inset 0 0 50px
    rgba(0, 240, 255, 0.025);

  animation: cardIn 0.8s ease both;
}


@keyframes cardIn {

  from {
    opacity: 0;
    transform: translateY(20px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

}


/* =========================================================
   系统核心
========================================================= */

.system-mark {

  width: 100px;
  height: 100px;

  margin: 0 auto 24px;

  position: relative;

  display: flex;

  justify-content: center;
  align-items: center;
}


.system-ring {

  position: absolute;

  inset: 0;

  border-radius: 50%;

  border: 1px solid rgba(0, 240, 255, 0.3);
}


.ring-1 {
  animation: rotateA 8s linear infinite;
}


.ring-2 {

  inset: 10px;

  border-color:
    rgba(255, 0, 230, 0.35);

  animation:
    rotateB 5s linear infinite;

}


.ring-3 {

  inset: 22px;

  border-color:
    rgba(139, 92, 246, 0.4);

  animation:
    rotateA 3s linear infinite reverse;

}


.system-core {

  width: 34px;
  height: 34px;

  display: flex;

  align-items: center;
  justify-content: center;

  color: white;

  font-size: 22px;

  text-shadow:
    0 0 10px var(--cyan),
    0 0 25px var(--cyan);

  animation: corePulse 2s ease-in-out infinite;
}


@keyframes rotateA {

  to {
    transform: rotate(360deg);
  }

}


@keyframes rotateB {

  to {
    transform: rotate(-360deg);
  }

}


@keyframes corePulse {

  0%,
  100% {
    transform: scale(0.9);
    opacity: 0.7;
  }

  50% {
    transform: scale(1.1);
    opacity: 1;
  }

}


/* =========================================================
   标题
========================================================= */

.brand {
  text-align: center;
}


.brand-title {

  font-size: 30px;

  font-weight: 900;

  letter-spacing: 8px;

  background:
    linear-gradient(
      90deg,
      var(--cyan),
      var(--pink),
      var(--purple),
      var(--cyan)
    );

  background-size: 300% 100%;

  -webkit-background-clip: text;

  background-clip: text;

  color: transparent;

  animation:
    gradient 5s ease infinite;

}


@keyframes gradient {

  0% {
    background-position: 0%;
  }

  50% {
    background-position: 100%;
  }

  100% {
    background-position: 0%;
  }

}


.brand-subtitle {

  margin-top: 8px;

  color: var(--muted);

  font-size: 10px;

  letter-spacing: 3px;
}


/* =========================================================
   状态
========================================================= */

.security-status {

  margin-top: 25px;

  display: flex;

  align-items: center;
  justify-content: center;

  gap: 8px;

  color: rgba(0, 240, 255, 0.8);

  font-size: 10px;

  letter-spacing: 1.5px;
}


.status-dot {

  width: 7px;
  height: 7px;

  border-radius: 50%;

  background: var(--cyan);

  box-shadow:
    0 0 8px var(--cyan),
    0 0 18px var(--cyan);

  animation: blink 1.5s infinite;
}


@keyframes blink {

  50% {
    opacity: 0.3;
  }

}


.divider {

  height: 1px;

  margin: 25px 0;

  background:
    linear-gradient(
      90deg,
      transparent,
      rgba(0,240,255,0.3),
      transparent
    );
}


/* =========================================================
   文案
========================================================= */

.message {
  text-align: center;
}


.message h1 {

  font-size: 22px;

  margin-bottom: 10px;

  font-weight: 700;
}


.message p {

  color: rgba(255,255,255,0.72);

  font-size: 14px;

  line-height: 1.7;
}


.message .secondary {

  color: rgba(255,255,255,0.4);

  font-size: 12px;
}


/* =========================================================
   输入框
========================================================= */

#authForm {
  margin-top: 25px;
}


.input-wrapper {

  position: relative;

  display: flex;

  align-items: center;
}


.input-icon {

  position: absolute;

  left: 16px;

  color: var(--cyan);

  font-size: 16px;

  pointer-events: none;

  opacity: 0.7;
}


#password {

  width: 100%;

  height: 54px;

  padding:
    0 50px 0 45px;

  border-radius: 14px;

  border:
    1px solid
    rgba(255,255,255,0.13);

  outline: none;

  color: white;

  background:
    rgba(0,0,0,0.28);

  font-size: 15px;

  transition:
    0.25s ease;

}


#password::placeholder {
  color: rgba(255,255,255,0.3);
}


#password:focus {

  border-color:
    rgba(0,240,255,0.65);

  box-shadow:
    0 0 0 3px
    rgba(0,240,255,0.08),

    0 0 25px
    rgba(0,240,255,0.08);
}


.toggle-password {

  position: absolute;

  right: 12px;

  width: 36px;
  height: 36px;

  border: none;

  background: transparent;

  color: rgba(255,255,255,0.4);

  cursor: pointer;

  font-size: 15px;
}


/* =========================================================
   按钮
========================================================= */

.submit-button {

  width: 100%;

  height: 54px;

  margin-top: 14px;

  border: 1px solid
    rgba(0,240,255,0.4);

  border-radius: 14px;

  background:
    linear-gradient(
      90deg,
      rgba(0,240,255,0.12),
      rgba(139,92,246,0.15)
    );

  color: white;

  font-size: 12px;

  font-weight: 800;

  letter-spacing: 2px;

  cursor: pointer;

  transition: 0.25s ease;

}


.submit-button:hover {

  transform: translateY(-1px);

  border-color:
    rgba(0,240,255,0.8);

  box-shadow:
    0 0 25px
    rgba(0,240,255,0.12);
}


.submit-button:active {
  transform: translateY(0);
}


.submit-button:disabled {
  opacity: 0.6;
  cursor: wait;
}


/* =========================================================
   Loading
========================================================= */

.button-loader {

  width: 16px;
  height: 16px;

  display: inline-block;

  border-radius: 50%;

  border:
    2px solid
    rgba(255,255,255,0.25);

  border-top-color:
    var(--cyan);

  animation:
    spin 0.8s linear infinite;
}


@keyframes spin {

  to {
    transform: rotate(360deg);
  }

}


/* =========================================================
   错误
========================================================= */

.error-message {

  min-height: 22px;

  margin-top: 13px;

  text-align: center;

  color: var(--danger);

  font-size: 12px;

  line-height: 1.5;
}


.error-message.show {
  animation: shake 0.35s ease;
}


@keyframes shake {

  0%, 100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-6px);
  }

  75% {
    transform: translateX(6px);
  }

}


/* =========================================================
   安全信息
========================================================= */

.security-info {

  margin-top: 20px;

  display: flex;

  justify-content: center;

  gap: 8px;

  color:
    rgba(255,255,255,0.25);

  font-size: 8px;

  letter-spacing: 1px;
}


/* =========================================================
   Footer
========================================================= */

footer {

  margin-top: 25px;

  display: flex;

  justify-content: center;

  gap: 10px;

  color:
    rgba(255,255,255,0.2);

  font-size: 8px;

  letter-spacing: 1px;
}


/* =========================================================
   移动端
========================================================= */

@media (max-width: 500px) {

  .auth-card {

    padding:
      35px 22px 25px;

    border-radius: 20px;

  }

  .brand-title {

    font-size: 25px;

    letter-spacing: 6px;

  }

}
