.hotbar {
  height: 48px;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
}

/* ── Hotbar preset buttons ─────────────────────────────────── */
.hotbar-presets {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  margin-bottom: 2px;
}

.hotbar-preset-label {
  color: #888;
  font-size: 10px;
  margin-right: 2px;
}

.hotbar-preset-btn {
  width: 22px;
  height: 16px;
  background: #1a1a1a;
  border: 1px solid #444;
  color: #aaa;
  font-size: 10px;
  cursor: pointer;
  border-radius: 2px;
  padding: 0;
  line-height: 14px;
  transition: background 0.1s;
}

.hotbar-preset-btn:hover {
  background: #333;
  color: #fff;
  border-color: #888;
}

.hotbar-preset-btn.preset-active {
  background: #2a4a2a;
  border-color: #4caf50;
  color: #4caf50;
  font-weight: bold;
}

.hotbar-item:hover {
  cursor: pointer;
  box-shadow: 0px 0px 10px 0px white;
}

.active {
  animation: fade 0.25s ease-in-out;
}

@keyframes fade {
  0% {   box-shadow: 0px 0px 0px 0px white; }
  50% {   box-shadow: 0px 0px 10px 0px white; }
  100% {   box-shadow: 0px 0px 0px 0px white; }
}

.hotbar-item {
  color: grey;
  display: flex;
  height: 32px;
  width: 32px;
  user-select: none;
  align-items: flex-end;
  justify-content: center;
  border: 1px solid black;
  background-image: url("/png/bg2.png");
  margin: 2px;
  position: relative;
  box-shadow: 0px 0px 10px 0px black;
}

.hotbar-item .hotbar-text {
  flex: 1 1 auto;
  z-index: 10;
  font-size: 8px;
  color: white;
  text-align: center;
}

.hotbar-item .hotbar-key {
  font-size: 8px;
  pointer-events: none;
  position: absolute;
  left: 2px;
  top: 2px;
}

.hotbar-item canvas {
  position: absolute;
  pointer-events: none;
  width: 32px;
  height: 32px;
}

