*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  color: #333;
  font-family:
    system-ui,
    -apple-system,
    sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  margin: 0;
  padding: 1rem 2rem;
}

main {
  margin: 0 auto;
  max-width: 960px;
}

h1 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}

h2 {
  font-size: 1rem;
  margin: 1.5rem 0 0.5rem;
}

a {
  color: inherit;
}

p {
  margin: 0 0 0.75rem;
}

hr {
  border: none;
  border-top: 1px solid #ddd;
  margin: 1.5rem 0;
}

code {
  background: #f5f5f5;
  border-radius: 3px;
  font-size: 0.875em;
  padding: 0.1em 0.3em;
}

label {
  margin-right: 0.25rem;
}

button {
  margin-left: 0.25rem;
}

/* Event log — use for demos that emit events, instead of console.log */
.demo-output {
  border: 1px solid #ddd;
  font-family: monospace;
  font-size: 0.875rem;
  list-style: none;
  margin: 0.5rem 0;
  max-height: 8rem;
  min-height: 2rem;
  overflow-y: auto;
  padding: 0.5rem;
}

.demo-output:empty::before {
  color: #999;
  content: "No events yet";
}
