/* Vaznor's dashboard: the website's black and white, laid out like a settings app. */

:root {
  --bg: #070707;
  --side: #0b0b0c;
  --panel: #111112;
  --panel-2: #161618;
  --panel-3: #1c1c1f;
  --line: rgba(255, 255, 255, 0.075);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #f4f2ec;
  --soft: #c9c6bd;
  --muted: #8d8b84;
  --faint: #55544f;
  --danger: #e5484d;
  --ok: #3fb950;
  --warn: #d29922;
  --display: "Unbounded", "Helvetica Neue", sans-serif;
  --sans: "Instrument Sans", -apple-system, "Helvetica Neue", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --top: 60px;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
}
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 2px;
}
::selection {
  background: var(--text);
  color: var(--bg);
}
[hidden] {
  display: none !important;
}
.mark {
  width: 22px;
  height: 22px;
  display: block;
}
.boot {
  display: grid;
  place-items: center;
  min-height: 100dvh;
  color: var(--faint);
}
.boot .mark {
  width: 34px;
  height: 34px;
  animation: pulse 1.4s ease-in-out infinite;
}
@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}
@keyframes rise {
  from {
    transform: translateY(14px);
    opacity: 0;
  }
}
@keyframes fade {
  from {
    opacity: 0;
  }
}

/* ---- buttons ----------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--panel-2);
  font-weight: 500;
  white-space: nowrap;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, transform 0.15s var(--ease);
}
.btn:hover {
  background: var(--panel-3);
  border-color: rgba(255, 255, 255, 0.24);
}
.btn:active {
  transform: scale(0.98);
}
.btn.primary {
  background: var(--text);
  border-color: var(--text);
  color: #0a0a0a;
}
.btn.primary:hover {
  background: #fff;
}
.btn.danger {
  color: #f2999c;
}
.btn.small {
  height: 30px;
  padding: 0 11px;
  font-size: 13px;
  border-radius: 8px;
}
.btn.big {
  height: 46px;
  padding: 0 22px;
  font-size: 15px;
  border-radius: 12px;
}
.btn svg {
  width: 16px;
  height: 16px;
  flex: none;
}
.me .link {
  white-space: nowrap;
}
.btn:disabled {
  opacity: 0.5;
  cursor: default;
}
.link {
  border: 0;
  padding: 0;
  background: none;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.link:hover {
  color: var(--text);
}

/* ---- the landing page -------------------------------------------------------------- */

.landing {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 28px;
  min-height: 100dvh;
  padding: 32px 16px;
  background: radial-gradient(60% 50% at 50% 0%, rgba(255, 255, 255, 0.07), transparent 70%), var(--bg);
}
.landing-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 500 16px var(--display);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.landing-card,
.center-card {
  width: min(520px, 100%);
  padding: 40px 36px 34px;
  border: 1px solid var(--line-2);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 40%), var(--panel);
  box-shadow: 0 40px 120px -40px rgba(0, 0, 0, 0.9);
  text-align: center;
  animation: rise 0.5s var(--ease);
}
.center-card {
  margin: 20vh auto 0;
}
.eyebrow {
  margin: 0 0 12px;
  color: var(--muted);
  font: 500 12px var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.landing-card h1,
.center-card h1 {
  margin: 0 0 14px;
  font: 400 clamp(26px, 5vw, 34px) / 1.12 var(--display);
  letter-spacing: -0.04em;
}
.lede {
  margin: 0 auto 26px;
  max-width: 40ch;
  color: var(--muted);
  font-size: 15px;
}
.small {
  margin: 22px 0 0;
  color: var(--faint);
  font-size: 12.5px;
}
.note {
  margin: 0 0 18px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--panel-2);
  color: var(--muted);
  font-size: 13px;
}
.note.bad {
  background: rgba(229, 72, 77, 0.1);
  color: #f2999c;
}

/* ---- top bar ----------------------------------------------------------------------- */

.top {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 14px;
  height: var(--top);
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 7, 7, 0.86);
  backdrop-filter: blur(14px);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 500 14px var(--display);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand em {
  font-style: normal;
  font-weight: 300;
  color: var(--muted);
}
.top .spacer {
  flex: 1;
}
.me {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--soft);
  font-weight: 500;
}
.me img,
.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--panel-3);
  object-fit: cover;
}
.me form {
  margin: 0;
}
.menu-btn {
  display: none;
}

/* ---- server picker ----------------------------------------------------------------- */

.picker {
  max-width: 1080px;
  margin: 0 auto;
  padding: 48px 20px 80px;
}
.picker h1 {
  margin: 0 0 8px;
  font: 400 clamp(26px, 4vw, 36px) / 1.1 var(--display);
  letter-spacing: -0.04em;
}
.picker .lede {
  margin: 0 0 32px;
  text-align: left;
}
.servers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}
.server {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 14px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
  text-decoration: none;
  transition: border-color 0.15s, transform 0.2s var(--ease), background 0.15s;
  animation: rise 0.45s var(--ease) both;
}
.server:hover {
  border-color: var(--line-2);
  background: var(--panel-2);
  transform: translateY(-2px);
}
.server-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--panel-3);
  color: var(--soft);
  font: 500 18px var(--display);
  overflow: hidden;
}
.server-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.server-name {
  margin: 0;
  font-weight: 600;
  font-size: 15px;
  overflow-wrap: anywhere;
}
.server-sub {
  color: var(--muted);
  font-size: 13px;
}
.server.missing {
  opacity: 0.72;
}
.server.missing:hover {
  opacity: 1;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: max-content;
  padding: 2px 10px;
  border-radius: 99px;
  border: 1px solid var(--line-2);
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}
.pill.ok {
  color: #8ddb98;
  border-color: rgba(63, 185, 80, 0.32);
}
.pill.warn {
  color: #e8c26a;
  border-color: rgba(210, 153, 34, 0.35);
}
.empty {
  padding: 50px 20px;
  border: 1px dashed var(--line-2);
  border-radius: 16px;
  color: var(--muted);
  text-align: center;
}

/* ---- server view ------------------------------------------------------------------- */

.layout {
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
  min-height: calc(100dvh - var(--top));
}
.side {
  position: sticky;
  top: var(--top);
  align-self: start;
  height: calc(100dvh - var(--top));
  overflow-y: auto;
  padding: 18px 12px 24px;
  border-right: 1px solid var(--line);
  background: var(--side);
}
.side-server {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 8px 16px;
  text-decoration: none;
}
.side-server .server-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  font-size: 14px;
  flex: none;
}
.side-server b {
  display: block;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.side-server span {
  color: var(--muted);
  font-size: 12px;
}
.side-label {
  margin: 16px 10px 6px;
  color: var(--faint);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  height: 36px;
  padding: 0 10px;
  border-radius: 9px;
  color: var(--soft);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.nav-item:hover {
  background: var(--panel-2);
  color: var(--text);
}
.nav-item.on {
  background: var(--panel-3);
  color: var(--text);
}
.nav-item svg {
  width: 17px;
  height: 17px;
  flex: none;
}
.content {
  min-width: 0;
  padding: 34px clamp(16px, 4vw, 48px) 140px;
}
.content-inner {
  max-width: 860px;
  animation: fade 0.25s ease;
}
.content h1 {
  margin: 0 0 6px;
  font: 400 clamp(24px, 3vw, 30px) / 1.15 var(--display);
  letter-spacing: -0.035em;
}
.content .desc {
  margin: 0 0 28px;
  color: var(--muted);
  max-width: 62ch;
}
.banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  padding: 14px 16px;
  border: 1px solid rgba(210, 153, 34, 0.32);
  border-radius: 14px;
  background: rgba(210, 153, 34, 0.07);
  color: #e8c26a;
}
.banner p {
  margin: 0;
}

/* ---- cards and fields -------------------------------------------------------------- */

.group {
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}
.group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px 0;
}
.group-head h2 {
  margin: 0;
  font: 500 15px var(--display);
  letter-spacing: -0.02em;
}
.group-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.group-body {
  padding: 8px 20px 18px;
}
.field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 300px);
  gap: 6px 24px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.field:first-child {
  border-top: 0;
}
.field.wide {
  grid-template-columns: 1fr;
}
.field-label {
  font-weight: 500;
}
.field-help {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
}
.field-error {
  grid-column: 1 / -1;
  color: #f2999c;
  font-size: 13px;
}
.field.bad input,
.field.bad select,
.field.bad textarea {
  border-color: rgba(229, 72, 77, 0.6);
}
input[type="text"],
input[type="number"],
select,
textarea {
  width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--bg);
  transition: border-color 0.15s;
}
select {
  cursor: pointer;
}
textarea {
  min-height: 96px;
  resize: vertical;
  line-height: 1.5;
}
textarea.code {
  font: 13px/1.55 var(--mono);
}
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.42);
}
.with-unit {
  display: flex;
  align-items: center;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--bg);
}
.with-unit input {
  border: 0;
  background: transparent;
}
.with-unit span {
  padding: 0 12px 0 4px;
  color: var(--muted);
  font: 12.5px var(--mono);
}

/* A switch, like Discord's own settings. */
.switch {
  position: relative;
  justify-self: end;
  width: 44px;
  height: 26px;
  flex: none;
  appearance: none;
  margin: 0;
  border-radius: 99px;
  background: var(--panel-3);
  border: 1px solid var(--line-2);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--muted);
  transition: transform 0.22s var(--ease), background 0.2s;
}
.switch:checked {
  background: var(--text);
  border-color: var(--text);
}
.switch:checked::after {
  transform: translateX(18px);
  background: #0a0a0a;
}
.segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line-2);
  border-radius: 11px;
  background: var(--bg);
}
.segmented button {
  flex: 1;
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}
.segmented button.on {
  background: var(--panel-3);
  color: var(--text);
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}
.chips:empty {
  display: none;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 3px 6px 3px 10px;
  border: 1px solid var(--line-2);
  border-radius: 99px;
  background: var(--panel-2);
  font-size: 13px;
}
.chip i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--muted);
  flex: none;
}
.chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chip button {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
}
.chip button:hover {
  background: var(--panel-3);
  color: var(--text);
}
.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  padding: 12px 0 2px;
}
.module {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-2);
  font-weight: 500;
}

/* ---- lists of items ---------------------------------------------------------------- */

.items {
  display: grid;
  gap: 8px;
  padding: 10px 0 4px;
}
.item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 16px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-2);
}
.item-title {
  font-weight: 600;
  overflow-wrap: anywhere;
}
.item-sub {
  grid-column: 1;
  color: var(--muted);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.item .btn {
  grid-row: 1 / span 2;
  grid-column: 2;
}
.editor {
  margin-top: 12px;
  padding: 6px 16px 16px;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  background: var(--bg);
  animation: rise 0.25s var(--ease);
}
.editor .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 14px;
}
.editor .actions .spacer {
  flex: 1;
}

/* ---- overview ---------------------------------------------------------------------- */

.hero {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
}
.hero .server-icon {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  font-size: 22px;
}
.hero h1 {
  margin: 0 0 6px;
}
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
}
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}
.tile {
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s, transform 0.2s var(--ease);
}
.tile:hover {
  border-color: var(--line-2);
  background: var(--panel-2);
  transform: translateY(-2px);
}
.tile-head {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}
.tile-head svg {
  width: 17px;
  height: 17px;
  color: var(--muted);
}
.tile p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.history {
  margin: 0;
  padding: 0;
  list-style: none;
}
.history li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 14px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.history li:first-child {
  border-top: 0;
}
.history b {
  font-weight: 600;
}
.history span {
  color: var(--muted);
  font-size: 12.5px;
  white-space: nowrap;
}
h2.section-title {
  margin: 30px 0 12px;
  font: 400 16px var(--display);
  letter-spacing: -0.02em;
}

/* ---- the save bar, and toasts ------------------------------------------------------ */

.savebar {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(720px, calc(100vw - 28px));
  padding: 10px 10px 10px 18px;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  background: var(--panel-2);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7);
  transform: translateX(-50%);
  animation: rise 0.25s var(--ease);
}
.savebar p {
  flex: 1;
  margin: 0;
  font-weight: 500;
}
.savebar.shake {
  animation: shake 0.4s ease;
}
@keyframes shake {
  20%,
  60% {
    transform: translateX(calc(-50% - 6px));
  }
  40%,
  80% {
    transform: translateX(calc(-50% + 6px));
  }
}
.toasts {
  position: fixed;
  top: calc(var(--top) + 14px);
  right: 18px;
  z-index: 60;
  display: grid;
  gap: 8px;
}
.toast {
  padding: 11px 16px;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  background: var(--text);
  color: #0a0a0a;
  font-weight: 500;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.6);
  animation: rise 0.25s var(--ease);
}
.toast.bad {
  background: var(--danger);
  color: #fff;
}

/* ---- stats and charts -------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}
.stat {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 60%), var(--panel);
  animation: rise 0.4s var(--ease) both;
}
.stat:nth-child(2) {
  animation-delay: 40ms;
}
.stat:nth-child(3) {
  animation-delay: 80ms;
}
.stat:nth-child(4) {
  animation-delay: 120ms;
}
.stat-label {
  color: var(--muted);
  font-size: 12.5px;
}
.stat-value {
  margin-top: 8px;
  font: 300 30px/1 var(--display);
  letter-spacing: -0.04em;
}
.stat-sub {
  margin-top: 8px;
  color: var(--faint);
  font-size: 12.5px;
}
.stat-sub.up {
  color: #8ddb98;
}
.stat-sub.down {
  color: #f2999c;
}
.chart-card .group-body {
  padding-top: 12px;
}
.chart-wrap {
  position: relative;
}
.chart {
  display: block;
  width: 100%;
  height: auto;
  color: var(--text);
  overflow: visible;
}
.chart-line {
  fill: none;
  stroke: var(--text);
  stroke-width: 2;
  stroke-linejoin: round;
}
.chart-grid {
  stroke: var(--line);
  stroke-width: 1;
}
.chart-guide {
  stroke: var(--line-2);
  stroke-dasharray: 3 4;
}
.chart-dot {
  fill: var(--bg);
  stroke: var(--text);
  stroke-width: 2;
}
.chart-axis {
  fill: var(--faint);
  font: 11px var(--mono);
}
.chart-tip {
  position: absolute;
  top: -6px;
  transform: translate(-50%, -100%);
  padding: 5px 10px;
  border: 1px solid var(--line-2);
  border-radius: 8px;
  background: var(--panel-3);
  font-size: 12.5px;
  white-space: nowrap;
  pointer-events: none;
}
.bar-in {
  fill: var(--text);
}
.bar-out {
  fill: var(--faint);
}
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 14px;
}
.split > .group {
  margin-bottom: 16px;
}
.hbar {
  padding: 8px 0;
}
.hbar-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 13.5px;
}
.hbar-top span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hbar-track {
  height: 6px;
  border-radius: 99px;
  background: var(--panel-3);
  overflow: hidden;
}
.hbar-fill {
  height: 100%;
  border-radius: 99px;
  background: var(--text);
  transition: width 0.6s var(--ease);
}
.people {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 8px;
  padding-top: 12px;
}
.person {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  background: var(--panel-2);
}
.person-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.rank {
  width: 22px;
  color: var(--faint);
  font: 500 13px var(--display);
  text-align: center;
  flex: none;
}
.av {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--panel-3);
  color: var(--soft);
  font: 500 12px var(--display);
  object-fit: cover;
  flex: none;
}
.skeleton {
  height: 96px;
  margin-bottom: 14px;
  border-radius: 16px;
  background: linear-gradient(90deg, var(--panel) 0%, var(--panel-2) 50%, var(--panel) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
}
.skeleton.tall {
  height: 220px;
}
@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

/* ---- Discord-style messages ------------------------------------------------------------ */

.script-box {
  display: grid;
  gap: 12px;
}
.preview {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #313338;
  overflow: hidden;
}
.preview-label {
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: #b5bac1;
  font: 500 11px var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.preview-body {
  padding: 12px 14px 14px;
}
.preview-note {
  margin: 0;
  color: #b5bac1;
  font-size: 13px;
}
.preview-note.bad {
  color: #fa777c;
}
.dmsg {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 14px;
  color: #dbdee1;
  font: 15px/1.375 "gg sans", "Instrument Sans", -apple-system, sans-serif;
}
.dmsg-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #1e1f22;
}
.dmsg-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}
.dmsg-head b {
  color: #f2f3f5;
  font-weight: 600;
}
.dmsg-app {
  padding: 1px 4px;
  border-radius: 3px;
  background: #5865f2;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
}
.dmsg-time {
  color: #949ba4;
  font-size: 12px;
}
.dmsg-content {
  overflow-wrap: anywhere;
}
.dembed {
  display: flex;
  gap: 16px;
  max-width: 520px;
  margin-top: 6px;
  padding: 10px 16px 14px 12px;
  border-left: 4px solid var(--bar, #1e1f22);
  border-radius: 4px;
  background: #2b2d31;
  font-size: 14px;
}
.dembed-main {
  flex: 1;
  min-width: 0;
}
.dembed-author {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  color: #f2f3f5;
  font-size: 13.5px;
  font-weight: 600;
}
.dembed-author img,
.dembed-footer img {
  width: 22px;
  height: 22px;
  border-radius: 50%;
}
.dembed-title {
  margin-top: 6px;
  color: #f2f3f5;
  font-weight: 600;
}
.dembed-desc {
  margin-top: 6px;
  color: #dbdee1;
  overflow-wrap: anywhere;
}
.dembed-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 12px;
  margin-top: 8px;
}
.dembed-field {
  grid-column: 1 / -1;
}
.dembed-field.inline {
  grid-column: auto;
}
.dembed-fname {
  color: #f2f3f5;
  font-weight: 600;
  font-size: 13.5px;
}
.dembed-image {
  display: block;
  max-width: 100%;
  margin-top: 12px;
  border-radius: 4px;
}
.dembed-thumb {
  width: 80px;
  height: 80px;
  border-radius: 4px;
  object-fit: cover;
  flex: none;
}
.dembed-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: #b5bac1;
  font-size: 12px;
}
.dbuttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.dbutton {
  padding: 6px 14px;
  border-radius: 6px;
  background: #4e5058;
  color: #fff;
  font-size: 13.5px;
  font-weight: 500;
}
.mention {
  padding: 0 2px;
  border-radius: 3px;
  background: color-mix(in srgb, var(--mc, #5865f2) 30%, transparent);
  color: color-mix(in srgb, var(--mc, #c9cdfb) 70%, white);
  font-weight: 500;
}
.md-link {
  color: #00a8fc;
}
.md-emoji {
  width: 22px;
  height: 22px;
  vertical-align: -5px;
}
.dmsg code {
  padding: 1px 4px;
  border-radius: 4px;
  background: #1e1f22;
  font: 0.85em var(--mono);
}
.md-h1,
.md-h2,
.md-h3 {
  color: #f2f3f5;
  font-weight: 700;
  margin: 6px 0 2px;
}
.md-h1 {
  font-size: 1.5em;
}
.md-h2 {
  font-size: 1.25em;
}
.md-sub {
  color: #949ba4;
  font-size: 12px;
}
.md-quote {
  padding-left: 10px;
  border-left: 4px solid #4e5058;
}

/* ---- tools ------------------------------------------------------------------------- */

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}
.toolbar input {
  flex: 1;
  min-width: 200px;
}
.toolbar select {
  width: auto;
  min-width: 180px;
}
input[type="search"] {
  width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--bg);
}
.tag {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 99px;
  border: 1px solid var(--line-2);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
}
.tag.warn {
  color: #e8c26a;
  border-color: rgba(210, 153, 34, 0.35);
}
.tag.bad {
  color: #f2999c;
  border-color: rgba(229, 72, 77, 0.35);
}
.muted {
  color: var(--muted);
  font-size: 12.5px;
}
.cmd-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.cmd-row:first-child {
  border-top: 0;
}
.cmd-row.off .cmd-main {
  opacity: 0.5;
}
.cmd-name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.cmd-name code {
  font: 500 13.5px var(--mono);
  color: var(--text);
}
.cmd-desc {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}
.case {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 12px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.case:first-child {
  border-top: 0;
}
.case-id {
  color: var(--faint);
  font: 500 14px var(--display);
}
.case-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.case-head .av {
  width: 22px;
  height: 22px;
  font-size: 10px;
}
.case-reason {
  margin-top: 6px;
  overflow-wrap: anywhere;
}
.case-meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12.5px;
}
.tabs {
  max-width: 320px;
  margin-bottom: 14px;
}
.board-row {
  display: grid;
  grid-template-columns: 26px 36px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.board-row:first-child {
  border-top: 0;
}
.board-row .av {
  width: 36px;
  height: 36px;
}
.board-row.top1 .rank {
  color: var(--text);
}
.board-name {
  margin-bottom: 6px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.board-sub {
  margin-top: -3px;
  color: var(--muted);
  font-size: 12.5px;
}
.supporters .board-name {
  margin-bottom: 4px;
}
.supporters-head {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}
.supporters-head .field-help,
.supporters-head .note {
  margin: 0;
}
.board-value {
  display: grid;
  justify-items: end;
  font-size: 13.5px;
}
.board-value span {
  color: var(--muted);
  font-size: 12px;
}
.composer {
  display: grid;
  gap: 16px;
  padding-top: 18px;
}
.composer label {
  display: grid;
  gap: 8px;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 6px;
}

/* ---- the switcher ------------------------------------------------------------------ */

.jump {
  color: var(--muted);
}
.jump kbd {
  padding: 0 5px;
  border: 1px solid var(--line-2);
  border-radius: 5px;
  font: 11px/18px var(--mono);
}
.palette-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  justify-items: center;
  align-items: start;
  padding: 12vh 16px 16px;
  background: rgba(0, 0, 0, 0.55);
  animation: fade 0.15s ease;
}
.palette {
  width: min(560px, 100%);
  border: 1px solid var(--line-2);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.8);
  overflow: hidden;
  animation: rise 0.2s var(--ease);
}
.palette-input {
  width: 100%;
  padding: 18px 20px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-size: 16px;
}
.palette-input:focus {
  outline: none;
}
.palette-list {
  max-height: 46vh;
  overflow-y: auto;
  padding: 6px;
}
.palette-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  text-align: left;
}
.palette-item.on {
  background: var(--panel-3);
}
.palette-kind {
  color: var(--faint);
  font-size: 12.5px;
}
.palette-empty {
  margin: 0;
  padding: 18px;
  color: var(--muted);
}
.palette-foot {
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 12px;
}

/* ---- small screens ----------------------------------------------------------------- */

@media (max-width: 860px) {
  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .split {
    grid-template-columns: 1fr;
  }
  .jump span,
  .jump kbd {
    display: none;
  }
  .layout {
    grid-template-columns: 1fr;
  }
  .side {
    position: fixed;
    inset: var(--top) auto 0 0;
    z-index: 25;
    width: 270px;
    height: auto;
    transform: translateX(-100%);
    transition: transform 0.25s var(--ease);
    box-shadow: 30px 0 80px rgba(0, 0, 0, 0.7);
  }
  .layout.menu-open .side {
    transform: none;
  }
  .menu-btn {
    display: inline-flex;
  }
  .me b {
    display: none;
  }
  .field {
    grid-template-columns: 1fr;
  }
  .switch {
    justify-self: start;
  }
  .content {
    padding-top: 24px;
  }
}
@media (max-width: 520px) {
  .landing-card {
    padding: 30px 22px;
  }
  .hero .server-icon {
    width: 56px;
    height: 56px;
  }
  .savebar p {
    font-size: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
