:root {
  color-scheme: light;
  --bg: #0b0f1f;
  --panel: #12182c;
  --panel-soft: #181f38;
  --accent: #32f5c8;
  --text: #f6f2e8;
  --muted: #b7bfd6;
  --line: rgba(255, 255, 255, 0.08);
  --shadow: rgba(0, 0, 0, 0.35);
  --glow: rgba(50, 245, 200, 0.2);
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --display: "Space Grotesk", "Trebuchet MS", sans-serif;
}

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

body {
  font-family: var(--display);
  background: radial-gradient(circle at top left, #1a254b 0%, #0b0f1f 55%, #0a0d18 100%);
  color: var(--text);
  min-height: 100vh;
  padding: 0;
  position: relative;
  overflow-x: hidden;
}

.bg-orbit {
  position: fixed;
  inset: -20% 0 auto 40%;
  height: 420px;
  width: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(50, 245, 200, 0.35), rgba(50, 245, 200, 0) 60%);
  filter: blur(0.5px);
  opacity: 0.8;
  animation: drift 16s ease-in-out infinite;
  z-index: 0;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.2;
  pointer-events: none;
  z-index: 0;
}

.auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: grid;
  place-content: center;
  gap: 32px;
  padding: 32px 24px;
  text-align: left;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
}

.logo {
  height: 112px;
  width: 112px;
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(50, 245, 200, 0.22), rgba(95, 156, 255, 0.2));
  display: grid;
  place-items: center;
  padding: 12px;
  box-shadow: 0 16px 36px var(--glow);
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-name {
  font-weight: 700;
  font-size: 1.7rem;
}

.brand-tag {
  font-size: 1.05rem;
  color: var(--muted);
}

.auth-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 30px;
  box-shadow: 0 30px 60px var(--shadow);
  width: min(480px, 94vw);
  margin-inline: auto;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.panel-title {
  display: flex;
  align-items: center;
  gap: 14px;
}

.panel-title-text {
  font-weight: 700;
  font-size: 1.1rem;
}

.panel-sub {
  color: var(--muted);
  font-size: 0.9rem;
}

.panel-tabs {
  display: flex;
  gap: 8px;
}

.tab {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 0.7rem;
  cursor: pointer;
}

.tab.active {
  background: var(--accent);
  color: #0a0d18;
  border-color: transparent;
}

.auth-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 14px;
}

input {
  background: var(--panel-soft);
  border: 1px solid transparent;
  color: var(--text);
  padding: 10px 12px;
  border-radius: 12px;
  font-family: var(--display);
}

input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(50, 245, 200, 0.2);
}

.form-note {
  color: var(--muted);
  font-size: 0.75rem;
}

.status {
  margin-top: 14px;
  font-size: 0.85rem;
  min-height: 18px;
}

.reverify,
.forgot {
  margin-top: 14px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(50, 245, 200, 0.3);
  background: rgba(50, 245, 200, 0.08);
  display: grid;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}

.link-btn {
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-size: 0.8rem;
  text-align: left;
  padding: 8px 0;
}

.hidden {
  display: none;
}

.btn {
  font-family: var(--display);
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn.primary {
  background: var(--accent);
  color: #0a0d18;
  box-shadow: 0 12px 30px rgba(50, 245, 200, 0.25);
}

.btn.ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.btn:hover {
  transform: translateY(-2px);
}

@keyframes drift {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(18px);
  }
}

@media (max-width: 640px) {
  .panel-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .logo {
    height: 88px;
    width: 88px;
    border-radius: 22px;
  }

  .brand {
    gap: 16px;
  }
}
