* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  display: flex;
  flex-direction: column;
  font: 14px/1.45 -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #2b2b2b;
  background: #f4f2ee;
}

#toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 8px 12px;
  background: #fff;
  border-bottom: 1px solid #e2ded6;
}
.brand { font-weight: 600; margin-right: 4px; }
.tools { display: flex; gap: 4px; }
.actions { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-wrap: wrap; }

button {
  font: inherit;
  padding: 5px 12px;
  border: 1px solid #cfc9bd;
  border-radius: 6px;
  background: #fbfaf7;
  color: #2b2b2b;
  cursor: pointer;
}
button:hover { background: #f0ede6; }
button.active { background: #205d9e; border-color: #205d9e; color: #fff; }
button:disabled { opacity: 0.45; cursor: default; }
.chk { display: flex; align-items: center; gap: 4px; font-size: 13px; color: #555; }

main { flex: 1; display: flex; min-height: 0; }
#canvasWrap { flex: 1; position: relative; min-width: 0; }
#canvas { position: absolute; inset: 0; display: block; touch-action: none; }

#sidebar {
  width: 264px;
  flex: none;
  background: #fff;
  border-left: 1px solid #e2ded6;
  overflow-y: auto;
  padding: 12px 14px;
}
#sidebar h2 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8a857b;
  margin: 14px 0 6px;
}
#sidebar section:first-child h2 { margin-top: 0; }
#sidebar ul { margin: 0; padding-left: 18px; }
#sidebar li { margin-bottom: 6px; }
.help li { font-size: 13px; color: #555; }
.muted { color: #999; }
.small { font-size: 12px; }

#panel .row { margin-bottom: 8px; }
#panel .row label { display: inline-block; min-width: 64px; color: #555; }
#panel input[type="number"] {
  width: 84px;
  font: inherit;
  padding: 3px 6px;
  border: 1px solid #cfc9bd;
  border-radius: 5px;
}
#panel button { margin-right: 6px; }
#roomsList li { font-size: 13px; }

#status {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 12px;
  background: #fff;
  border-top: 1px solid #e2ded6;
  font-size: 12px;
  color: #777;
  white-space: nowrap;
  overflow: hidden;
}
