* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  color: #e9e4d8;
  background: #0a0a0b;
  font: 14px/1.35 "Segoe UI", "Helvetica Neue", sans-serif;
  display: flex;
  flex-direction: column;
}

header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 12px;
  padding: 8px 14px;
  background: #0e0f11;
  border-bottom: 1px solid #1f1f21;
}
header strong { font-size: 15px; font-weight: 650; letter-spacing: -0.02em; }
.sep { color: #7a766c; font-size: 13px; }
header button, header select {
  height: 30px;
  border: 1px solid #3a3a3a;
  background: #1a1b1e;
  color: #eeeae0;
  border-radius: 4px;
  padding: 0 10px;
  font: inherit;
  cursor: pointer;
}
#play { background: #1d3a36; border-color: #2f6a62; color: #9ee8dc; }
header label { color: #9a9588; font-size: 13px; display: flex; align-items: center; gap: 6px; }
#scenes { max-width: 220px; min-width: 140px; }
#speed { width: 88px; accent-color: #8a8578; }

.board {
  position: relative;
  flex: 1;
  min-height: 0;
  background: #070708;
  overflow: hidden;
}
#map {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}
#wait {
  position: absolute;
  inset: 0;
  margin: 0;
  display: grid;
  place-items: center;
  color: #8c877c;
  font-size: 14px;
  pointer-events: none;
}
#wait.off { display: none; }

.pip {
  position: absolute;
  left: 16px;
  bottom: 16px;
  margin: 0;
  width: min(280px, 32vw);
  background: #101113;
  border: 1px solid #2c2c2c;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.45);
}
.pip img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: #111; }
.pip figcaption {
  padding: 6px 8px;
  font-size: 11px;
  color: #9a9588;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.key {
  position: absolute;
  right: 16px;
  bottom: 16px;
  margin: 0;
  padding: 8px 10px;
  list-style: none;
  background: rgba(12, 12, 14, 0.86);
  border: 1px solid #2a2a2a;
  font-size: 12px;
  color: #b8b3a6;
}
.key li { display: flex; align-items: center; gap: 7px; margin: 3px 0; }
.key i { width: 10px; height: 10px; display: inline-block; }
.soil { background: #c9a36a; }
.bed { background: #8d8d90; }
.sand { background: #d8c15a; }
.big { background: #b4533a; border-radius: 40% 55% 45% 50%; }

footer {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 8px 16px;
  background: #101113;
  border-top: 1px solid #262626;
  color: #8c877c;
  font-size: 12px;
}
footer b { color: #d8c15a; font-weight: 600; text-transform: lowercase; }
#stNote { margin-left: auto; }

.banner {
  margin: 0;
  padding: 9px 16px 11px;
  background: #12110e;
  border-top: 1px solid #2a2618;
  color: #b8b09a;
  font-size: 13px;
}
.banner a { color: #d8c15a; }
.banner code {
  font: 12px/1 ui-monospace, Consolas, monospace;
  color: #eeeae0;
}
