body {
  margin: 0;
  font-family: monospace;
  background: url("bg.jpg") center/cover no-repeat fixed;
  color: #e0e0ff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  min-height: 100vh;
  padding: 1rem;
}

.title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #cdc6ff;
}

#main-container {
  display: flex;
  flex-direction: row;
  gap: 2rem;
  align-items: flex-start;
  justify-content: center;
  width: 100%;
  max-width: 1200px;
}

#left-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#material-toolbar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.material-btn {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease;
  position: relative;
}

.material-btn img {
  width: 28px;
  height: 28px;
  pointer-events: none;
}

.material-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 0 8px #ffffff44;
}

.material-btn.selected {
  outline: 3px solid #cdc6ff;
}

#canvas-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#sim {
  border: 2px solid #ccc;
  background-color: #111;
  image-rendering: pixelated;
}

#bottom-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
  gap: 1rem;
  background: rgba(0, 0, 0, 0.6);
  padding: 0.5rem 1rem;
  border-radius: 12px;
  box-shadow: 0 0 8px #000;
}

#clear-btn {
  background: #ff4249;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.2s ease;
}

#clear-btn:hover {
  background: #ff5e64;
}

#brush-size {
  accent-color: #c1b7ff;
}

