:root {
  --bg: #0b0f18;
  --panel: #141b28;
  --line: #26324a;
  --fg: #d7e0f0;
  --accent: #4fc3f7;
}
* { box-sizing: border-box; }
body {
  margin: 0; padding: 0 16px 32px;
  background: var(--bg); color: var(--fg);
  font: 15px/1.45 "Segoe UI", system-ui, sans-serif;
}
header { display: flex; align-items: baseline; gap: 16px; padding: 14px 0; }
h1 { font-size: 20px; letter-spacing: 3px; margin: 0; color: var(--accent); }
h2 { font-size: 16px; margin: 0 0 10px; }
h3 { font-size: 13px; text-transform: uppercase; letter-spacing: 1px; margin: 14px 0 6px; color: #8fa3c4; }
.hidden { display: none !important; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 14px; margin-bottom: 14px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0; }
input, select, button { font: inherit; }
input, select {
  background: #0d1420; color: var(--fg); border: 1px solid var(--line);
  border-radius: 5px; padding: 6px 8px; min-width: 70px;
}
label { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: #9db0cf; }
button {
  background: #24314a; color: var(--fg); border: 1px solid var(--line);
  border-radius: 5px; padding: 7px 12px; cursor: pointer;
}
button:hover { background: #2e3d5c; }
button.primary { background: #1d5f7d; border-color: #2b86ad; }
button.secondary { background: transparent; }
.msg { min-height: 18px; margin: 6px 0 0; color: #ffab91; font-size: 13px; }
.grid { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.side { flex: 1 1 320px; min-width: 300px; }
canvas { background: #060911; border: 1px solid var(--line); border-radius: 6px; cursor: crosshair; max-width: 100%; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: right; padding: 3px 6px; border-bottom: 1px solid #1d2637; }
th:first-child, td:first-child, th:last-child, td:last-child { text-align: left; }
th { color: #8fa4c0; font-weight: 600; }
tbody tr { cursor: pointer; }
tbody tr:hover { background: #131c2c; }
tbody tr.own td { color: #cfe4ff; }
#world-table thead th { position: sticky; top: 0; background: var(--panel, #0d1420); }
.muted { color: #8fa4c0; font-weight: 400; font-size: 13px; }
.bar { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; padding: 8px 0 12px; }
ul { list-style: none; margin: 0; padding: 0; font-size: 13px; }
li { padding: 4px 0; border-bottom: 1px solid #1d2637; display: flex; gap: 8px; justify-content: space-between; }
li:last-child { border-bottom: none; }
.tag { font-size: 11px; padding: 1px 6px; border-radius: 8px; background: #223050; color: #9db0cf; }
.ok { color: #81c784; }
