:root {
  color-scheme: dark;
  --bg: #080b0f;
  --panel: rgba(17, 24, 32, 0.86);
  --text: #f4f8fb;
  --muted: #93a3b5;
  --line: rgba(255, 255, 255, 0.12);
  --green: #41e69b;
  --cyan: #5ed8ff;
  --red: #ff6978;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(65, 230, 155, 0.12), transparent 28rem),
    radial-gradient(circle at 90% 10%, rgba(94, 216, 255, 0.1), transparent 30rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.backplate {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(120deg, transparent 35%, rgba(255, 255, 255, 0.04) 36%, transparent 40%);
}

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.auth-card {
  width: 100%;
  max-width: 360px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 2.5rem;
  backdrop-filter: blur(12px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.brand.compact {
  margin-bottom: 1.5rem;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--green), #9dffd0);
  color: #06140d;
  font-weight: 900;
  font-size: 24px;
  border-radius: 10px;
}

.brand p {
  margin: 0;
  font-size: 12px;
  text-transform: uppercase;
  color: var(--muted);
  letter-spacing: 0.8px;
}

.brand h1 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input {
  width: 100%;
  padding: 0.875rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(3, 6, 10, 0.72);
  color: var(--text);
  font-size: 14px;
  transition: border-color 0.2s, background-color 0.2s;
}

.form-group input:focus {
  outline: none;
  border-color: var(--green);
  background: rgba(3, 6, 10, 0.9);
}

.form-group input::placeholder {
  color: var(--muted);
  opacity: 0.6;
}

button,
.btn-secondary {
  width: 100%;
  padding: 0.875rem;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--green), #9dffd0);
  color: #06140d;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

button:hover,
.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(65, 230, 155, 0.3);
}

button:active,
.btn-secondary:active {
  transform: translateY(0);
}

.btn-secondary {
  display: block;
  margin-top: 0.75rem;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  color: var(--text);
  text-align: center;
  text-decoration: none;
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-note {
  margin: 0 0 1.5rem 0;
  padding: 0.875rem;
  background: rgba(157, 255, 208, 0.08);
  border: 1px solid rgba(65, 230, 155, 0.3);
  border-radius: 8px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.auth-note strong {
  color: var(--text);
}

.error-message {
  margin-top: 1rem;
  padding: 0.875rem;
  background: rgba(255, 105, 120, 0.1);
  border: 1px solid rgba(255, 105, 120, 0.3);
  border-radius: 8px;
  color: #ff9aa2;
  font-size: 13px;
  text-align: center;
}

.error-message[data-type="success"] {
  background: rgba(65, 230, 155, 0.1);
  border-color: rgba(65, 230, 155, 0.3);
  color: #9dffd0;
}

@media (max-width: 480px) {
  .auth-card {
    padding: 1.5rem;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .brand h1 {
    font-size: 16px;
  }
}
/* Accessible password reveal control */
.password-input {
  position: relative;
  display: block;
  width: 100%;
}

.password-input > input {
  width: 100%;
  padding-right: 46px;
}

.password-eye {
  position: absolute;
  top: 50%;
  right: 5px;
  transform: translateY(-50%);
  width: 36px;
  min-width: 36px;
  min-height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted, #a9b7c5);
  box-shadow: none;
}

.password-eye-icon {
  display: block;
  width: 18px;
  height: 12px;
  margin: auto;
  border: 2px solid currentColor;
  border-radius: 70% 15%;
  transform: rotate(45deg);
}

.password-eye-icon::after {
  content: "";
  display: block;
  width: 4px;
  height: 4px;
  margin: 2px auto;
  border-radius: 50%;
  background: currentColor;
}

/* NexusPanel 4.2 clean UI */
:root{--nx-ui-gap:12px;--nx-ui-radius:12px}html[data-nexus-density="compact"]{--nx-ui-gap:8px}html[data-nexus-motion="reduced"] *,html[data-nexus-motion="reduced"] *::before,html[data-nexus-motion="reduced"] *::after{animation-duration:.001ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important;transition-duration:.001ms!important}.nx-ui-editor{contain:layout paint;isolation:isolate}.nx-ui-editor [data-editor-overlay]{pointer-events:none}.nx-ui-toast{position:fixed;right:16px;bottom:16px;z-index:9999;max-width:360px;pointer-events:none}
