:root {
  color-scheme: light dark;
  --bg: #f7f7f5;
  --card: #ffffff;
  --text: #1c1c1a;
  --muted: #62625c;
  --line: #deded8;
  --accent: #1f6f43;
  --accent-text: #ffffff;
  --link: #1d5fc4;
  --danger: #b3261e;
  --online: #1f9d55;
  --offline: #77776f;
  --unknown: #b07a00;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161614;
    --card: #1f1f1c;
    --text: #ecece6;
    --muted: #a2a29a;
    --line: #34342f;
    --accent: #5cc08a;
    --accent-text: #0e1a13;
    --link: #7fb0ff;
    --danger: #f2877f;
    --online: #4cd08a;
    --offline: #9a9a92;
    --unknown: #e0b030;
  }
}
:where(*) { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
.col { max-width: 640px; margin: 0 auto; padding: 24px 16px 48px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
h1 { font-size: 1.5rem; margin: 0; }
.note { color: var(--muted); margin: 0; }
.banner { border: 1px solid var(--line); background: var(--card); border-radius: 8px; padding: 12px 16px; margin: 0; }
.banner.bad { border-color: var(--danger); color: var(--danger); }
.btn { min-height: 44px; padding: 0 16px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); background: var(--card); color: var(--text); border-radius: 8px; font: inherit; text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.danger { color: var(--danger); border-color: var(--danger); }
.btn.link { background: none; border-color: transparent; color: var(--link); padding: 0 4px; }
.btn:focus-visible, summary:focus-visible, .menu .items button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tb { background: var(--card); border-bottom: 1px solid var(--line); }
.tbin { max-width: 640px; margin: 0 auto; padding: 8px 16px; min-height: 56px; display: flex; align-items: center; gap: 8px; }
.tbin strong { flex: none; }
.tbin .where { font-size: 1rem; font-weight: 400; color: var(--muted); white-space: nowrap; flex: none; }
.tbin .sp1 { flex: 1; }
.menu { position: relative; min-width: 0; }
.acct { min-height: 44px; line-height: 42px; padding: 0 12px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); cursor: pointer; list-style: none; }
.acct::-webkit-details-marker { display: none; }
.menu .items { position: absolute; right: 0; top: calc(100% + 4px); background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 4px; display: grid; gap: 2px; min-width: 200px; z-index: 2; }
.menu .items button { min-height: 44px; text-align: left; border: 0; background: none; color: var(--text); font: inherit; padding: 0 12px; border-radius: 6px; cursor: pointer; }
.menu .items button:hover { background: var(--bg); }
.menu .items button.dng { color: var(--danger); }
.list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.row { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.l1 { display: flex; align-items: center; gap: 12px; min-height: 44px; min-width: 0; }
.l1 .name { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.l2 { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 0.875rem; flex-wrap: wrap; }
.l2.gone { color: var(--danger); }
.rmv { min-height: 44px; margin-left: auto; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.dot.on { background: var(--online); }
.dot.off { background: transparent; border: 2px solid var(--offline); }
.dot.rm { background: var(--danger); }
.dot.cant { background: transparent; border: 2px dashed var(--unknown); }
.confirm { border: 1px solid var(--danger); border-radius: 8px; padding: 12px 16px; background: var(--card); display: grid; gap: 12px; }
.confirm .actions { display: flex; gap: 8px; }
@media (max-width: 600px) {
  .signin {
    width: 100%;
  }
}
