:root {
  --bg: #070709;
  --panel: rgba(255, 255, 255, .028);
  --panel-solid: #0e0e12;
  --line: rgba(255, 255, 255, .075);
  --line-strong: rgba(255, 255, 255, .14);
  --text: #f6f6f8;
  --muted: #a2a2b2;
  --dim: #6c6c7c;
  --accent: #ff2d46;
  --accent-soft: rgba(255, 45, 70, .13);
  --ok: #48d17f;
  --warn: #ffb020;
  --r-lg: 20px;
  --r-md: 14px;
  --r-sm: 10px;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

/* ----------------------------------------------------------------- gate */

.gate {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.gatecard {
  width: min(420px, 100%);
  padding: 28px 26px 22px;
  border-radius: var(--r-lg);
  background: var(--panel-solid);
  border: 1px solid var(--line-strong);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
  text-align: center;
}

.gatecard .logo { margin: 0 auto 16px; }
.gatecard h2 { margin: 0 0 6px; font-size: 22px; letter-spacing: -.02em; }
.gatecard p { margin: 0 0 18px; font-size: 13.5px; color: var(--muted); }
.gatecard .verify { display: flex; gap: 8px; }
.gatecard .note { margin-top: 12px; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: -.005em;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(760px 380px at 50% -160px, rgba(255, 45, 70, .22), transparent 72%),
    radial-gradient(520px 320px at 92% 8%, rgba(120, 40, 255, .08), transparent 70%);
}

.shell {
  position: relative;
  width: min(780px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 70px;
}

/* ---------------------------------------------------------------- brand */

.top {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 22px;
}

.logo {
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, #ff5468, #ff2d46 46%, #b3122a);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .45),
    0 8px 22px rgba(255, 45, 70, .32);
  color: #fff;
}
.logo svg { width: 19px; height: 19px; display: block; }

.top h1 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.01em;
}
.top small {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--dim);
  letter-spacing: .02em;
}

.top .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--warn); }
.dot.ok { background: var(--ok); box-shadow: 0 0 10px rgba(72, 209, 127, .7); }
.dot.bad { background: var(--accent); box-shadow: 0 0 10px rgba(255, 45, 70, .7); }

/* ------------------------------------------------------------------ hero */

.hero { padding: 14px 0 30px; }

.hero h2 {
  margin: 0;
  font-size: clamp(30px, 5vw, 44px);
  line-height: 1.06;
  font-weight: 800;
  letter-spacing: -.035em;
}
.hero h2 em {
  font-style: normal;
  background: linear-gradient(96deg, #ff8a9b, #ff2d46 55%, #ff5f74);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p {
  margin: 12px 0 0;
  max-width: 480px;
  font-size: 14.5px;
  color: var(--muted);
}

/* ----------------------------------------------------------------- card */

.card {
  position: relative;
  padding: 24px;
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012));
  border: 1px solid var(--line);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .06),
    0 24px 60px rgba(0, 0, 0, .45);
  backdrop-filter: blur(14px);
}
.card + .card { margin-top: 14px; }

.cardhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.cardhead h3 { margin: 0; font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
.cardhead span { font-size: 12px; color: var(--dim); }

.card p.sub { margin: 4px 0 0; font-size: 13px; color: var(--muted); }

/* --------------------------------------------------------------- presets */

.presets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: 8px;
  margin-top: 18px;
}

.chip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 12px 13px;
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, .025);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  cursor: pointer;
  text-align: left;
  transition: border-color .16s, background .16s, transform .1s;
}
.chip:hover { background: rgba(255, 255, 255, .05); border-color: var(--line-strong); }
.chip:active { transform: scale(.985); }
.chip b { font-size: 13.5px; font-weight: 700; letter-spacing: -.01em; }
.chip small { font-size: 11px; color: var(--dim); font-weight: 500; }

.chip.on {
  background: var(--accent-soft);
  border-color: rgba(255, 45, 70, .55);
  box-shadow: inset 0 0 0 1px rgba(255, 45, 70, .16);
}
.chip.on b { color: #fff; }
.chip.on small { color: rgba(255, 160, 175, .9); }
.chip.on::after {
  content: "";
  position: absolute;
  top: 9px; right: 9px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px rgba(255, 45, 70, .8);
}

/* ---------------------------------------------------------------- custom */

.custom { display: none; gap: 8px; margin-top: 8px; }
.custom.on { display: flex; }

input, select {
  height: 44px;
  padding: 0 13px;
  border-radius: var(--r-sm);
  background: rgba(0, 0, 0, .35);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color .16s, background .16s;
}
input:focus, select:focus { border-color: rgba(255, 45, 70, .6); background: rgba(0, 0, 0, .5); }
input::placeholder { color: var(--dim); }
select { cursor: pointer; }
select option { background: #12121a; }

/* --------------------------------------------------------------- controls */

.controls {
  display: grid;
  grid-template-columns: 132px 1fr auto;
  gap: 8px;
  margin-top: 16px;
  align-items: end;
}
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--dim);
  padding-left: 2px;
}
.field input { width: 100%; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 22px;
  border: 0;
  border-radius: var(--r-sm);
  background: linear-gradient(180deg, #ff4459, #e81c34);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -.005em;
  cursor: pointer;
  white-space: nowrap;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .3),
    0 10px 24px rgba(232, 28, 52, .3);
  transition: filter .15s, transform .1s, opacity .15s;
}
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .5; cursor: progress; }

.btn.ghost {
  background: rgba(255, 255, 255, .04);
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: none;
}
.btn.ghost:hover { background: rgba(255, 255, 255, .08); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 12px; border-radius: 8px; }

/* ---------------------------------------------------------------- output */

.note { margin-top: 10px; min-height: 18px; font-size: 13px; font-weight: 500; color: var(--muted); }
.note.err { color: #ff7585; }
.note.ok { color: var(--ok); }

.output {
  margin-top: 14px;
  padding: 15px;
  border-radius: var(--r-md);
  background: rgba(0, 0, 0, .42);
  border: 1px solid rgba(255, 45, 70, .3);
  animation: pop .2s ease-out both;
}
@keyframes pop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

.output pre {
  margin: 0;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 13px;
  line-height: 1.9;
  color: #ffe7ea;
  white-space: pre-wrap;
  word-break: break-all;
  user-select: all;
}

.output .bar { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- verify */

.verify { display: flex; gap: 8px; margin-top: 16px; }
.verify input { flex: 1; min-width: 0; font-family: ui-monospace, Consolas, monospace; letter-spacing: .07em; text-transform: uppercase; font-size: 13px; }

.facts {
  display: none;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1px;
  margin-top: 14px;
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--line);
  border: 1px solid var(--line);
}
.facts.on { display: grid; }
.facts div { padding: 12px 14px; background: var(--panel-solid); }
.facts span {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dim);
}
.facts b { display: block; margin-top: 3px; font-size: 13px; font-weight: 600; }

/* ----------------------------------------------------------------- table */

.tablewrap { margin-top: 14px; overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
th {
  padding: 9px 10px;
  text-align: left;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dim);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
td { padding: 11px 10px; border-bottom: 1px solid rgba(255, 255, 255, .045); color: var(--muted); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
td.k { color: var(--text); font-family: ui-monospace, Consolas, monospace; font-size: 11.5px; letter-spacing: .02em; }
tr.dead td { opacity: .42; }
tbody tr:hover td { background: rgba(255, 255, 255, .022); }

.pill {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--muted);
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line);
}
.pill.ok { color: var(--ok); border-color: rgba(72, 209, 127, .3); background: rgba(72, 209, 127, .08); }
.pill.warn { color: var(--warn); border-color: rgba(255, 176, 32, .3); background: rgba(255, 176, 32, .08); }
.pill.bot { color: #ff9db0; border-color: rgba(225, 29, 46, .45); background: rgba(225, 29, 46, .12); }

.origin .by { color: var(--dim); font-size: 11px; white-space: nowrap; }

.owner { white-space: nowrap; }

.owner .av {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
  object-fit: cover;
  background: rgba(255, 255, 255, .08);
}

.owner .av.ph { display: inline-block; }

.owner .nm { font-size: 12px; color: var(--text); }

.owner .nm.dim { color: var(--dim); }

.pill.bad { color: #ff7585; border-color: rgba(255, 45, 70, .35); background: rgba(255, 45, 70, .1); }

.rowbtns { display: flex; gap: 6px; justify-content: flex-end; }

.headbtns { display: flex; gap: 8px; align-items: center; }

.headbtns .danger { color: #ff98a6; border-color: rgba(255, 45, 70, .42); }
.headbtns .danger:hover { background: rgba(255, 45, 70, .14); color: #ffc2ca; }

.empty { padding: 26px 0; text-align: center; font-size: 13px; color: var(--dim); }

/* ------------------------------------------------------------------ alert */

.alert {
  display: none;
  padding: 14px 16px;
  border-radius: var(--r-md);
  background: rgba(255, 45, 70, .09);
  border: 1px solid rgba(255, 45, 70, .32);
  color: #ffc2ca;
  font-size: 13px;
  line-height: 1.6;
}
.alert.on { display: block; }
.alert b { color: #fff; }

code {
  padding: 1px 6px;
  border-radius: 5px;
  background: rgba(255, 255, 255, .07);
  font-family: ui-monospace, Consolas, monospace;
  font-size: .92em;
  color: #ffd7dc;
}

.hidden { display: none !important; }

.foot {
  margin-top: 30px;
  text-align: center;
  font-size: 11.5px;
  color: var(--dim);
}

/* -------------------------------------------------------- discord profile */

.who {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-strong);
}

.who img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: block;
  background: rgba(255, 255, 255, .08);
  object-fit: cover;
}

.who span {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.who .btn { height: 26px; padding: 0 10px; font-size: 11px; border-radius: 6px; }

.who-note {
  margin: 14px 0 0 !important;
  font-size: 12.5px;
  color: var(--muted);
}

@media (max-width: 640px) {
  .top { flex-wrap: wrap; }
  .top .right { width: 100%; margin-left: 0; justify-content: space-between; }
  .shell { padding-top: 18px; }
  .controls { grid-template-columns: 1fr 1fr; }
  .controls .btn { grid-column: 1 / -1; width: 100%; }
  .hero h2 { font-size: 30px; }
  .card { padding: 18px; border-radius: 16px; }
}
