:root {
  color-scheme: dark;
  --bg: #0b0b10;
  --card: #121219;
  --line: #22222e;
  --line-2: #2c2c3a;
  --ink: #ececf2;
  --dim: #8b8b9e;
  --accent: #7c5cff;
  --accent-ink: #a996ff;
  --ok: #4ec98a;
  --bad: #ff6b6b;
  --warn: #e0a63c;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.5 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: -40% 0 auto 50%;
  width: 780px; height: 780px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(124,92,255,.13), transparent 62%);
  pointer-events: none;
}

.card {
  position: relative;
  width: 100%;
  max-width: 372px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 28px 26px 22px;
  box-shadow: 0 28px 70px -34px rgba(0,0,0,.9);
}

.hidden { display: none !important; }

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--accent-ink);
  font-weight: 620;
  font-size: 17px;
  letter-spacing: -.01em;
  margin-bottom: 22px;
}
.brand span { color: var(--ink); }

.brand .uid {
  font-size: 12px;
  font-weight: 500;
  color: var(--dim);
  background: #0e0e15;
  border: 1px solid var(--line-2);
  border-radius: 7px;
  padding: 3px 8px;
  letter-spacing: .01em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.discord {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--line);
  color: var(--dim);
  text-decoration: none;
  transition: color .15s, background-color .15s, border-color .15s;
}
.discord:hover {
  color: var(--accent-ink);
  border-color: var(--accent);
}
.discord:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 2px;
}
.discord svg { display: block; }

.tabs {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}
.tab {
  appearance: none;
  background: none;
  border: 0;
  color: var(--dim);
  font: inherit;
  font-size: 14px;
  padding: 9px 0 11px;
  cursor: pointer;
  transition: color .16s;
}
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); }
.ink {
  position: absolute;
  bottom: -1px; left: 0;
  width: 50%; height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transition: transform .22s cubic-bezier(.65,0,.35,1);
}
.ink.right { transform: translateX(100%); }

.pane { display: flex; flex-direction: column; }
.pane.tight { margin-top: 18px; }

label {
  font-size: 12px;
  color: var(--dim);
  margin-bottom: 6px;
  letter-spacing: .01em;
}
label + input { margin-bottom: 14px; }

input {
  appearance: none;
  width: 100%;
  background: #0e0e15;
  border: 1px solid var(--line-2);
  border-radius: 9px;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  padding: 10px 12px;
  transition: border-color .15s, box-shadow .15s;
}
input::placeholder { color: #55556a; }
input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,92,255,.16);
}
input:disabled { opacity: .55; }

.inline { display: flex; align-items: stretch; }
.inline input { flex: 1; border-top-right-radius: 0; border-bottom-right-radius: 0; }
.inline .go {
  position: relative;
  margin-left: -1px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
.inline .go:focus-visible, .inline input:focus { z-index: 1; }

.go {
  appearance: none;
  position: relative;
  margin-top: 6px;
  border: 0;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 600;
  font-size: 14px;
  padding: 11px 14px;
  cursor: pointer;
  transition: background-color .45s ease, border-color .45s ease,
              color .45s ease, filter .2s, opacity .2s;
}
.go:hover { filter: brightness(1.09); }
.go:disabled { opacity: .6; cursor: default; filter: none; }
.go.working { color: transparent !important; pointer-events: none; }
.go.working::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 15px; height: 15px;
  margin: -8px 0 0 -8px;
  border: 2px solid var(--accent-ink);
  border-right-color: transparent;
  border-radius: 50%;
  animation: go-spin .62s linear infinite;
}
.go.ghost.working::after { border-color: var(--accent-ink); border-right-color: transparent; }
@keyframes go-spin { to { transform: rotate(360deg); } }
.go.ghost {
  width: 100%;
  margin-top: 0;
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent-ink);
}
.go.ghost:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  filter: none;
}
.go.small { width: auto; margin-top: 0; padding: 0 16px; white-space: nowrap; }

.go:focus-visible, .tab:focus-visible, .link:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 2px;
}

.link {
  appearance: none;
  display: block;
  width: 100%;
  margin-top: 16px;
  background: none;
  border: 0;
  color: var(--dim);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  padding: 4px;
}
.link:hover { color: var(--ink); }

.msg {
  margin: 14px 0 0;
  min-height: 18px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--bad);
}
.msg.ok { color: var(--ok); }
.msg:empty { margin: 0; min-height: 0; }

.rows { display: flex; flex-direction: column; gap: 1px; }
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.row:first-child { border-top: 1px solid var(--line); }
.row.quiet { color: var(--dim); font-size: 13px; }
.row .game { text-transform: capitalize; padding-right: 12px; }
.row .val { color: var(--dim); font-size: 13px; font-variant-numeric: tabular-nums; }
.row .meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}
.pill {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 4px;
  border: 1px solid currentColor;
}
.pill.on { color: var(--accent-ink); }
.pill.off { color: var(--bad); }
.pill.paused { color: var(--warn); }
.empty { color: var(--dim); font-size: 13px; padding: 12px 0; }

.cf-turnstile { margin: 2px 0 12px; min-height: 65px; }

@media (max-width: 520px) {
  input { font-size: 16px; }
  .card { padding: 24px 20px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
