:root {
  --ink: #0b0b0b;
  --mute: #8a8a8a;
  --line: #ececec;
  --blue: #2f6bff;
  --f: "Inter", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: #fff; color: var(--ink); font: 15px/1.4 var(--f); -webkit-font-smoothing: antialiased; }
body { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input[type=text], input[type=password] { font: inherit; color: inherit; border: 0; border-bottom: 1px solid var(--ink); padding: 6px 0; outline: none; background: none; border-radius: 0; }
::selection { background: var(--blue); color: #fff; }

#side { position: sticky; top: 0; height: 100vh; padding: 28px 24px; display: flex; flex-direction: column; gap: 28px; }
.brand { font-weight: 600; letter-spacing: -.02em; font-size: 17px; }
#nav { display: flex; flex-direction: column; gap: 2px; overflow: auto; }
#nav a { padding: 5px 0; color: var(--mute); display: flex; align-items: center; gap: 8px; white-space: nowrap; }
#nav a.on, #nav a:hover { color: var(--ink); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); display: inline-block; flex: none; }
.prefs { margin-top: auto; display: flex; flex-direction: column; gap: 10px; font-size: 13px; color: var(--mute); }
.tog { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.tog input { appearance: none; width: 26px; height: 15px; border-radius: 8px; background: var(--line); position: relative; margin: 0; cursor: pointer; transition: background .2s; flex: none; }
.tog input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 11px; height: 11px; border-radius: 50%; background: #fff; transition: transform .2s; }
.tog input:checked { background: var(--ink); }
.tog input:checked::after { transform: translateX(11px); }
.tog input:checked + span { color: var(--ink); }

main { padding: 28px 48px 80px; min-width: 0; max-width: 1180px; }
h1 { font-size: 44px; line-height: 1.05; letter-spacing: -.035em; font-weight: 600; margin: 0 0 6px; }
.sub { color: var(--mute); font-size: 13px; display: flex; gap: 18px; flex-wrap: wrap; margin-bottom: 40px; }
.sub button, .act { color: var(--mute); }
.sub button:hover, .act:hover { color: var(--ink); }
.back { color: var(--mute); font-size: 13px; display: inline-block; margin-bottom: 18px; }
.back:hover { color: var(--ink); }
.muted { color: var(--mute); }

.stats { display: flex; gap: 48px; flex-wrap: wrap; margin: 0 0 48px; }
.stat b { display: block; font-size: 30px; font-weight: 600; letter-spacing: -.03em; line-height: 1.1; }
.stat span { font-size: 13px; color: var(--mute); }

.bar { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.bar h2 { font-size: 13px; font-weight: 500; color: var(--mute); margin: 0; }
.btn { font-weight: 500; }
.btn:hover { color: var(--blue); }

.newlink { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; margin: 6px 0 24px; }
.newlink input { width: 260px; max-width: 100%; }
.made { margin: 0 0 28px; display: flex; gap: 16px; align-items: baseline; flex-wrap: wrap; }
.made code, .addr code { font: 14px/1.4 ui-monospace, "SF Mono", Menlo, monospace; word-break: break-all; }

.t { width: 100%; border-collapse: collapse; }
.t th { text-align: left; font-weight: 400; font-size: 12px; color: var(--mute); padding: 10px 16px 10px 0; border-bottom: 1px solid var(--ink); white-space: nowrap; }
.t td { padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); vertical-align: baseline; }
.t tr.go { cursor: pointer; }
.t tr.go:hover td { color: var(--blue); }
.t .n { font-variant-numeric: tabular-nums; }
.t .name { font-weight: 500; }
.t .dim td { color: var(--mute); }
.badge { font-size: 11px; font-weight: 500; color: var(--blue); margin-left: 10px; letter-spacing: .01em; }
.flags { letter-spacing: 2px; }
.t td.m { display: none; }
main .prefs.foot { display: none; }
.empty { color: var(--mute); padding: 24px 0; }

.addr { display: flex; gap: 16px; align-items: baseline; flex-wrap: wrap; margin: -24px 0 40px; }
.danger { color: var(--mute); font-size: 13px; margin-top: 48px; display: inline-block; }
.danger:hover { color: #d00; }

#toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px); opacity: 0; background: var(--ink); color: #fff; font-size: 13px; padding: 8px 14px; border-radius: 20px; transition: .25s; pointer-events: none; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 820px) {
  body { display: block; }
  #side { position: sticky; top: 0; height: auto; z-index: 5; background: rgba(255,255,255,.94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); padding: 16px 18px 0; gap: 10px; }
  #nav { flex-direction: row; gap: 20px; overflow-x: auto; scrollbar-width: none; padding-bottom: 12px; border-bottom: 1px solid var(--line); margin: 0 -18px; padding-left: 18px; padding-right: 18px; }
  #nav::-webkit-scrollbar { display: none; }
  .prefs { display: none; }
  main .prefs.foot { display: flex; position: static; margin-top: 56px; }
  main { padding: 24px 18px 60px; }
  h1 { font-size: 32px; }
  .stats { gap: 22px 32px; }
  .stat b { font-size: 24px; }
  .t thead { display: none; }
  .t, .t tbody, .t tr, .t td { display: block; }
  .t tr { padding: 14px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; }
  .t td { border: 0; padding: 0; }
  .t td.name { grid-column: 1; }
  .t td.lead { grid-column: 2; grid-row: 1; text-align: right; }
  .t td.d { display: none; }
  .t td.m { display: block; grid-column: 1 / -1; font-size: 13px; color: var(--mute); }
}
