/* Actual game toolbar translated from game/ui/toolbar.gd.
   Load after sequence.css. The shared tray is intentionally absent: the game
   uses separate 30%-radius swatches, with the labels outside the moving tiles. */
.game-toolbar.is-game-toolbar {
  --tool-size: 72px;
  --tool-gap: calc(var(--tool-size) * .145833);
  --tool-label-size: calc(var(--tool-size) * .1875);
  --tool-shadow: calc(var(--tool-size) * .0625);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex: none;
  width: max-content;
  max-width: 100%;
  gap: var(--tool-gap);
  padding: 9px 12px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}
.game-toolbar.is-game-toolbar [data-tool="land"] { --swatch: #c4e5a7; --swatch-picked: #b0de89; }
.game-toolbar.is-game-toolbar [data-tool="water"] { --swatch: #97d4e4; --swatch-picked: #74c6dd; }
.game-toolbar.is-game-toolbar [data-tool="trees"] { --swatch: #93ca9e; --swatch-picked: #74bb82; }
.game-toolbar.is-game-toolbar [data-tool="buildings"] { --swatch: #e7baa7; --swatch-picked: #e0a389; }
.game-toolbar.is-game-toolbar [data-tool="paths"] { --swatch: #e7d0b1; --swatch-picked: #e0c196; }
.game-toolbar.is-game-toolbar button[data-tool],
.game-toolbar.is-game-toolbar button[data-tool]:hover,
.game-toolbar.is-game-toolbar button[data-tool][aria-current="step"] {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  flex: 0 0 var(--tool-size);
  width: var(--tool-size);
  min-width: 0;
  min-height: 0;
  gap: calc(var(--tool-size) * .0625);
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #fff;
  background: transparent;
  box-shadow: none;
  filter: none;
  opacity: 1;
  font: 400 var(--tool-label-size)/1.3 system-ui, -apple-system, sans-serif;
  transition: none;
  touch-action: manipulation;
}
.game-toolbar.is-game-toolbar .tool-swatch {
  position: relative;
  display: block;
  flex: none;
  width: var(--tool-size);
  height: var(--tool-size);
  border: calc(var(--tool-size) * .0520833) solid transparent;
  border-radius: 30%;
  background: var(--swatch);
  box-shadow: 0 calc(var(--tool-size) * .03125) var(--tool-shadow) #0000002e;
  transform-origin: center;
  transition: transform .18s cubic-bezier(.18,.8,.3,1.3), background-color .18s, border-color .18s, box-shadow .18s;
}
.game-toolbar.is-game-toolbar button[data-tool] .tool-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  display: block;
  width: calc(var(--tool-size) * .78);
  height: calc(var(--tool-size) * .78);
  object-fit: contain;
  opacity: 1;
  filter: none;
  transform: translate(-50%, -50%);
  transition: none;
  pointer-events: none;
}
.game-toolbar.is-game-toolbar .tool-label {
  display: block;
  flex: none;
  width: max-content;
  padding: 1px calc(var(--tool-size) * .0729167);
  border-radius: 999px;
  color: #fff;
  background: rgb(20 43 54 / 50%);
  text-shadow: 0 1px 2px rgb(20 43 54 / 60%);
  white-space: nowrap;
  pointer-events: none;
}
.game-toolbar.is-game-toolbar button[aria-current="step"] { z-index: 1; }
.game-toolbar.is-game-toolbar button[aria-current="step"] .tool-swatch {
  background: var(--swatch-picked);
  border-color: #fff;
  box-shadow: 0 0 calc(var(--tool-size) * .166667) rgb(255 255 255 / 55%);
  transform: scale(1.12);
  animation: game-tool-bob 1.6s ease-in-out infinite;
}
.game-toolbar.is-game-toolbar button[data-tool]:hover .tool-swatch {
  border-color: rgb(255 255 255 / 70%);
}
.game-toolbar.is-game-toolbar button[aria-current="step"]:hover .tool-swatch { border-color: #fff; }
.game-toolbar.is-game-toolbar button[data-tool]:focus-visible {
  outline: 2px solid #153d4e;
  outline-offset: 7px;
  border-radius: calc(var(--tool-size) * .3);
}
.game-toolbar.is-game-toolbar button[data-tool]:active .tool-swatch {
  animation: none;
  transform: scale(.98);
}
.game-toolbar.is-game-toolbar .tool-badge {
  position: absolute;
  z-index: 2;
  top: calc(var(--tool-size) * -.15625);
  right: calc(var(--tool-size) * -.15625);
  display: grid;
  place-items: center;
  width: calc(var(--tool-size) * .458333);
  height: calc(var(--tool-size) * .458333);
  border: calc(var(--tool-size) * .03125) solid rgb(255 255 255 / 95%);
  border-radius: 50%;
  background: var(--badge-color, #e4f6d5);
  box-shadow: 0 calc(var(--tool-size) * .020833) calc(var(--tool-size) * .052083) #00000047;
  transform-origin: center;
  pointer-events: none;
}
.game-toolbar.is-game-toolbar .tool-badge[hidden] { display: none; }
.game-toolbar.is-game-toolbar button[data-tool] .tool-badge img {
  display: block;
  position: static;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 1;
  filter: none;
  transform: none;
  transition: none;
}
.game-toolbar.is-game-toolbar .tool-badge.is-new-pick {
  animation: game-tool-badge-in .3s cubic-bezier(.18,.8,.3,1.4);
}
@keyframes game-tool-bob {
  0%, 100% { transform: translateY(0) scale(1.12); }
  50% { transform: translateY(calc(var(--tool-size) * -.041667)) scale(1.12); }
}
.journey:not(.is-painting) .game-toolbar .tool-swatch{animation-play-state:paused}
@keyframes game-tool-badge-in {
  from { transform: scale(.4); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
@media (max-width: 760px) {
  .game-toolbar.is-game-toolbar {
    --tool-size: clamp(45px, calc((100vw - 80px) / 5.6), 62px);
    --tool-label-size: max(10px, calc(var(--tool-size) * .1875));
  }
}
@media (max-height: 720px) and (min-width: 761px) {
  .game-toolbar.is-game-toolbar { --tool-size: 58px; }
}
@media (prefers-reduced-motion: reduce) {
  .game-toolbar.is-game-toolbar .tool-swatch,
  .game-toolbar.is-game-toolbar .tool-badge { animation: none !important; transition: none; }
}
