
:root {
  color-scheme: dark;
  --bg: #080d18;
  --panel: #111a2b;
  --panel2: #0c1423;
  --line: #26354d;
  --text: #edf3ff;
  --muted: #94a5c0;
  --blue: #78a9ff;
  --green: #36d6a0;
  --red: #ff7084;
  --yellow: #f2c66d;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.6 system-ui, -apple-system, sans-serif;
}

button,
input,
textarea {
  font: inherit;
}

.topbar {
  max-width: 1200px;
  margin: auto;
  padding: 30px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid var(--line);
}

.brand h1 {
  font-size: clamp(25px, 4vw, 36px);
  margin: 5px 0;
  letter-spacing: -1px;
}

.brand p {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  color: var(--blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .16em;
}

.connection {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  white-space: nowrap;
}

main {
  max-width: 1200px;
  padding: 22px;
  margin: auto;
}

.notice {
  padding: 15px 17px;
  border: 1px solid #65532c;
  background: #282113;
  color: #f3dfad;
  border-radius: 11px;
  margin-bottom: 20px;
}

.section {
  margin: 20px 0;
  padding: 21px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 15px;
  min-width: 0;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 18px;
}

h2 {
  font-size: 20px;
  margin: 5px 0;
}

h3 {
  font-size: 16px;
  margin: 0;
}

.server-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.server-card {
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 17px;
  min-width: 0;
}

.server-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.server-card p {
  color: var(--muted);
  margin: 12px 0;
}

.server-card code {
  color: #a8c4f4;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.server-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  margin-top: 15px;
  padding-top: 11px;
  font-size: 12px;
  color: var(--muted);
}

.dot {
  display: inline-block;
  flex: 0 0 auto;
  height: 9px;
  width: 9px;
  border-radius: 50%;
  background: #67758d;
}

.dot.ok {
  background: var(--green);
  box-shadow: 0 0 9px #36d6a077;
}

.dot.bad {
  background: var(--red);
}

.market-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric {
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 16px;
  min-width: 0;
}

.metric span,
.metric small {
  display: block;
  color: var(--muted);
}

.metric strong {
  display: block;
  font-size: clamp(19px, 3vw, 27px);
  margin: 9px 0;
  overflow-wrap: anywhere;
}

.metric small {
  font-size: 11px;
}

input,
textarea {
  background: #080e1a;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 11px 13px;
  outline: none;
  width: 100%;
}

input:focus,
textarea:focus {
  border-color: var(--blue);
}

.section-heading input {
  max-width: 290px;
}

textarea {
  resize: vertical;
  font: 13px/1.6 monospace;
}

label {
  display: block;
  margin: 15px 0 8px;
  color: var(--muted);
}

button {
  border: 0;
  border-radius: 9px;
  padding: 11px 17px;
  font-weight: 750;
  cursor: pointer;
  transition: opacity .2s, transform .2s;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
}

button:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.primary {
  background: var(--blue);
  color: #081222;
}

.secondary {
  background: #24344e;
  color: var(--text);
}

.tool-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.tool {
  padding: 14px;
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
  min-width: 0;
  overflow-wrap: anywhere;
}

.tool:hover,
.tool.selected {
  border-color: var(--blue);
}

.tool strong,
.tool small {
  display: block;
}

.tool small {
  color: var(--muted);
  margin-top: 6px;
}

.tool-meta {
  color: #8ea9d4;
  font-size: 11px;
  margin-top: 9px;
}

.empty {
  padding: 23px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: 10px;
}

.muted {
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 13px 0;
}

.result {
  background: #070c14;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px;
  font: 12px/1.6 monospace;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 500px;
  overflow: auto;
}

footer {
  padding: 30px 15px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

footer a {
  display: block;
  margin-top: 9px;
  color: var(--blue);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

@media (max-width: 760px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .market-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tool-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  main {
    padding: 13px;
  }

  .topbar {
    padding: 23px 15px;
  }

  .section {
    padding: 15px;
  }

  .server-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .section-heading input {
    max-width: none;
  }

  .connection {
    font-size: 12px;
  }
}
