:root {
  --bg: #12081f;
  --text: #f4eefc;
  --hint: #b5a4d4;
  --btn: #7c3aed;
  --btn-text: #ffffff;
  --sec: #1c1030;
  --link: #c4b5fd;
  --line: rgba(196, 181, 253, 0.22);
  --accent: #a855f7;
  --accent-2: #6d28d9;
  --radius: 12px;
  --font: "Manrope", "Segoe UI", system-ui, sans-serif;
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("https://cdn.jsdelivr.net/fontsource/fonts/manrope@latest/latin-400-normal.woff2") format("woff2");
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(120% 80% at 8% -12%, rgba(168, 85, 247, 0.38), transparent 55%),
    radial-gradient(90% 70% at 100% 0%, rgba(109, 40, 217, 0.32), transparent 52%),
    radial-gradient(70% 50% at 50% 110%, rgba(124, 58, 237, 0.18), transparent 50%),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
}

body {
  padding: 14px 12px calc(20px + env(safe-area-inset-bottom));
}

.wrap {
  width: min(400px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 10px;
}

.panel {
  background: linear-gradient(160deg, rgba(42, 22, 72, 0.92), rgba(24, 14, 42, 0.88));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  box-shadow: 0 6px 18px rgba(76, 29, 149, 0.18);
  backdrop-filter: blur(8px);
}

.panel .row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.panel .row:last-child { border-bottom: 0; }
.panel .row span { color: var(--hint); }
.panel .row b {
  font-weight: 650;
  text-align: right;
  overflow-wrap: anywhere;
  color: var(--link);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(124, 58, 237, 0.22);
  border: 1px solid rgba(196, 181, 253, 0.35);
  color: var(--link) !important;
}

.status-pill::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 6px currentColor;
}

.status-pill.ok {
  background: rgba(52, 211, 153, 0.16);
  border-color: rgba(52, 211, 153, 0.45);
  color: #6ee7b7 !important;
}

.status-pill.warn {
  background: rgba(251, 191, 36, 0.16);
  border-color: rgba(251, 191, 36, 0.45);
  color: #fbbf24 !important;
}

.status-pill.bad {
  background: rgba(248, 113, 113, 0.16);
  border-color: rgba(248, 113, 113, 0.45);
  color: #fca5a5 !important;
}

.form {
  display: grid;
  gap: 8px;
}

label {
  font-size: 12px;
  color: var(--hint);
  font-weight: 600;
}

input {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(18, 8, 31, 0.72);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: 15px;
  outline: none;
}

input:focus {
  border-color: rgba(168, 85, 247, 0.85);
  box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.22);
}

.btn {
  border: 0;
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--btn-text);
  cursor: pointer;
  box-shadow: 0 5px 14px rgba(124, 58, 237, 0.3);
}

.btn.secondary {
  background: rgba(42, 22, 72, 0.9);
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: none;
}

.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: 0.55; cursor: default; }

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: #1a0f2e;
  color: #f4eefc;
  border: 1px solid rgba(168, 85, 247, 0.55);
  padding: 9px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(76, 29, 149, 0.4);
  z-index: 20;
}

.toast.err {
  border-color: #f87171;
  color: #ffe8e8;
}

.denied {
  text-align: center;
  padding: 40px 16px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.denied b {
  display: block;
  font-size: 18px;
  color: #fca5a5;
}
