:root { color-scheme: light; }
body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  margin: 0; padding: 16px; color: #1a1a1a; background: #fff; line-height: 1.5;
}
main { max-width: 640px; margin: 0 auto; }
label { display: block; margin: 16px 0 4px; font-weight: 600; }
input { font: inherit; width: 100%; box-sizing: border-box; min-height: 44px; padding: 8px; border: 1px solid #595959; border-radius: 4px; }
button, .button {
  font: inherit; min-height: 44px; min-width: 44px; padding: 8px 16px; margin-top: 16px;
  background: #0b57d0; color: #fff; border: 0; border-radius: 4px; cursor: pointer;
}
a { color: #0b57d0; display: inline-block; min-height: 44px; line-height: 44px; }
:focus-visible { outline: 2px solid #0b57d0; outline-offset: 2px; }
.error { color: #b3261e; font-weight: 600; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
textarea { font: inherit; width: 100%; box-sizing: border-box; padding: 8px; border: 1px solid #595959; border-radius: 4px; }
.mono { font-family: ui-monospace, Consolas, "Courier New", monospace; }
.warning { background: #fff4ce; color: #1a1a1a; border: 1px solid #7a5b00; border-radius: 4px; padding: 8px 12px; }

/* PC list */
main:has(#pc-table) { max-width: 1000px; }
.bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.bar button { margin-top: 0; }
.controls { display: flex; flex-wrap: wrap; gap: 16px; align-items: end; margin-bottom: 16px; }
.check { display: flex; align-items: center; gap: 8px; }
.check input { width: 24px; min-height: 24px; }
.check label { margin: 0; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 8px; border-bottom: 1px solid #c4c4c4; vertical-align: top; }
th .sort { margin: 0; background: none; color: #0b57d0; padding: 8px 0; text-decoration: underline; font-weight: 600; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 8px; }
.dot.on { background: #146c2e; }
.dot.off { background: #595959; }
.button.connect, button.connect { display: inline-block; margin: 0; line-height: 28px; text-decoration: none; color: #fff; }
.button.muted { background: #595959; }
button.connect:disabled { background: #e0e0e0; color: #1a1a1a; cursor: not-allowed; }
summary { cursor: pointer; min-height: 44px; line-height: 44px; }
dl { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; margin: 0 0 8px; }
dt { font-weight: 600; }
dd { margin: 0; overflow-wrap: anywhere; }
tr[hidden] { display: none; }
@media (max-width: 639px) {
  table, tbody, tr, td, th { display: block; }
  thead { position: absolute; left: -9999px; }
  tr { border: 1px solid #595959; border-radius: 4px; margin-bottom: 16px; padding: 8px; }
  td, th[scope="row"] { border: 0; padding: 4px 8px; overflow-wrap: anywhere; }
  td[data-label]::before, th[scope="row"]::before { content: attr(data-label) ": "; font-weight: 600; }
  th[scope="row"] { font-weight: 400; }
  td.actions .connect { display: block; width: 100%; text-align: center; box-sizing: border-box; }
}
