:root{
  --bg:#05070b;
  --bg-soft:#0a0e14;
  --card:#0c1118;
  --card-2:#101722;
  --border:#1a2430;
  --text:#f5f7fa;
  --muted:#98a2b3;
  --accent:#ffffff;
  --accent-soft:rgba(255,255,255,.08);
  --success:#22c55e;
  --danger:#ef4444;
  --shadow:0 30px 80px rgba(0,0,0,.55);
  --radius:28px;
}

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

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

body{
  min-height:100vh;
  font-family: Inter, Arial, Helvetica, sans-serif;
  color:var(--text);
  background:
    radial-gradient(circle at top, rgba(255,255,255,.06), transparent 30%),
    linear-gradient(180deg, #06080c 0%, #040608 100%);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  overflow-x:hidden;
}

body::before,
body::after{
  content:"";
  position:fixed;
  inset:auto;
  width:360px;
  height:360px;
  border:1px solid rgba(255,255,255,.04);
  border-radius:40px;
  transform:rotate(45deg);
  pointer-events:none;
  z-index:0;
}

body::before{
  left:-180px;
  top:18%;
}

body::after{
  right:-180px;
  bottom:14%;
}

.auth-shell{
  position:relative;
  z-index:1;
  width:100%;
  max-width:460px;
}

.auth-card{
  background:linear-gradient(180deg, rgba(18,24,33,.96), rgba(10,14,20,.98));
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:34px 28px 28px;
  text-align:center;
  backdrop-filter:blur(10px);
}

.eyebrow{
  display:inline-block;
  margin-bottom:10px;
  color:#aeb8c5;
  font-size:12px;
  letter-spacing:.18em;
  text-transform:uppercase;
}

h1{
  font-size:clamp(32px, 5vw, 46px);
  line-height:1.05;
  margin-bottom:12px;
  font-weight:800;
  letter-spacing:-0.03em;
}

.desc{
  color:var(--muted);
  font-size:16px;
  line-height:1.6;
  margin-bottom:28px;
}

.brand-orb{
  position:relative;
  width:124px;
  height:124px;
  margin:0 auto 26px;
  display:flex;
  align-items:center;
  justify-content:center;
}

.brand-orb .spin-ring{
  position:absolute;
  inset:0;
  border-radius:50%;
  border:2px solid rgba(34,197,94,.18);
  border-top-color:rgba(34,197,94,.9);
  animation:spin 1s linear infinite;
  box-shadow:0 0 24px rgba(34,197,94,.14);
}

.brand-orb.is-success .spin-ring{
  animation:none;
  border-color:rgba(34,197,94,.8);
}

.brand-orb.is-error .spin-ring{
  animation:none;
  border-color:rgba(239,68,68,.8);
  box-shadow:0 0 24px rgba(239,68,68,.16);
}

.brand-core{
  width:88px;
  height:88px;
  border-radius:50%;
  background:linear-gradient(180deg, #141a22 0%, #0e131a 100%);
  border:1px solid rgba(255,255,255,.06);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  box-shadow:inset 0 0 24px rgba(255,255,255,.03);
}

.brand-core img{
  width:72px;
  height:72px;
  object-fit:cover;
  border-radius:50%;
  display:block;
}

.btn-discord{
  width:100%;
  min-height:56px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.08);
  background:linear-gradient(180deg, #202734 0%, #171d27 100%);
  color:#fff;
  text-decoration:none;
  font-weight:700;
  font-size:17px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  transition:.18s ease;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04);
}

.btn-discord:hover{
  transform:translateY(-1px);
  border-color:rgba(255,255,255,.14);
  background:linear-gradient(180deg, #262e3b 0%, #1b222d 100%);
}

.btn-discord:active{
  transform:translateY(0);
}

.discord-mark{
  width:10px;
  height:10px;
  border-radius:50%;
  background:#fff;
  opacity:.92;
}

.mini-note{
  margin-top:16px;
  color:#7f8a99;
  font-size:14px;
}

.steps{
  display:grid;
  gap:10px;
  margin-top:24px;
}

.step{
  min-height:46px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.06);
  background:#111722;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:15px;
  color:#7e8794;
  transition:.2s ease;
}

.step.active{
  color:#fff;
  border-color:rgba(255,255,255,.12);
  background:#141c28;
}

.step.done{
  color:var(--success);
  border-color:rgba(34,197,94,.25);
  background:rgba(34,197,94,.06);
}

.success-check,
.error-icon{
  width:54px;
  height:54px;
  margin:18px auto 0;
  border-radius:50%;
  display:none;
  align-items:center;
  justify-content:center;
  font-size:28px;
  font-weight:800;
}

.success-check{
  color:var(--success);
  background:rgba(34,197,94,.08);
  border:1px solid rgba(34,197,94,.3);
}

.error-icon{
  color:var(--danger);
  background:rgba(239,68,68,.08);
  border:1px solid rgba(239,68,68,.3);
}

.success-check.show,
.error-icon.show{
  display:flex;
}

.error-box{
  margin-top:18px;
  padding:14px 16px;
  border-radius:16px;
  background:rgba(239,68,68,.07);
  border:1px solid rgba(239,68,68,.18);
  color:#ffb4b4;
  text-align:left;
  font-size:14px;
  line-height:1.5;
  word-break:break-word;
}

.link-back{
  display:inline-flex;
  margin-top:18px;
  color:#d7dee8;
  text-decoration:none;
  font-weight:600;
  font-size:15px;
}

.link-back:hover{
  color:#fff;
}

@keyframes spin{
  to{ transform:rotate(360deg); }
}

@media (max-width:540px){
  body{
    padding:16px;
  }

  .auth-card{
    padding:28px 20px 22px;
    border-radius:24px;
  }

  .brand-orb{
    width:108px;
    height:108px;
    margin-bottom:22px;
  }

  .brand-core{
    width:78px;
    height:78px;
  }

  .brand-core img{
    width:64px;
    height:64px;
  }

  .desc{
    font-size:15px;
  }

  .btn-discord{
    min-height:54px;
    font-size:16px;
  }

  .step{
    font-size:14px;
    padding:0 10px;
  }
}