.buildingBody .sign {
  position: absolute;
  z-index: 2;
  right: 6px;
  bottom: 8px;
  left: 6px;
  display: grid;
  min-height: 30px;
  padding: 7px 3px 5px;
  place-items: center;
  color: #141c28;
  border: 2px solid #141c28;
  border-radius: 4px;
  background: #e5c65c;
  box-shadow: 0 4px 0 rgba(2, 6, 10, .5);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .012em;
}

.bldState {
  position: absolute;
  z-index: 4;
  top: 7px;
  right: 14px;
  padding: 4px 5px;
  color: #f0e6cd;
  border: 1px solid rgba(212, 175, 55, .4);
  border-radius: 4px;
  background: rgba(16, 23, 34, .92);
  box-shadow: 0 3px 0 rgba(2, 6, 10, .45);
  font-family: var(--utility);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.bld:not(:disabled):hover,
.bld.selected {
  z-index: 5;
  outline: 0;
}

.bld:not(:disabled):hover { transform: translateY(-3px); }
.bld.selected { transform: translateY(-7px); }

.bld:focus-visible {
  z-index: 6;
  outline: 3px solid #fff;
  outline-offset: -3px;
}

.bld:not(:disabled):hover .buildingBody {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .88), 0 8px 0 #0b1926;
  filter: none;
}

.bld.selected .buildingBody {
  border-color: #fff5c7;
  box-shadow: 0 0 0 4px #d4af37, 0 9px 0 #0b1926;
  filter: none;
}

.bld.selected .bldState {
  opacity: 1;
  color: #141c28;
  background: #e5c65c;
}

.bldState { opacity: 1; }
.bld.is-available .bldState { opacity: 0; }

.bld.done {
  opacity: .46;
  filter: none;
}

.bld.busted {
  opacity: .72;
  filter: none;
}

.bld.is-locked:not(.busted) {
  opacity: .58;
  filter: grayscale(.4);
}

.bld:not(:disabled):active {
  transform: translateY(-1px);
}

.bld.hit .buildingBody {
  animation: storefrontHit .5s ease-out both;
}

@keyframes storefrontHit {
  30% { filter: brightness(1.35); transform: translateY(-3px); }
}

.stateIcon {
  margin-right: 2px;
}

.message {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 16px;
  overflow: hidden;
  color: #f0e6cd;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color .18s ease, background-color .18s ease;
}

.message--error {
  display: inline-block;
  flex: 0 1 auto;
  padding: 3px 10px;
  color: #9cc3e8;
  border-radius: 8px;
  background: rgba(66, 133, 189, .16);
}

.buildingInteraction {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1px 14px;
  min-height: var(--control-h);
  margin: 0;
  padding: 5px 12px;
  color: var(--game-ivory);
  border: 1px solid var(--glass-line);
  border-radius: var(--control-radius);
  background: rgba(10, 14, 20, .6);
  box-shadow: inset 0 1px rgba(255, 255, 255, .05);
  animation: interaction-plate-in .18s ease-out both;
}

.buildingInteraction[hidden] { display: none; }

.buildingInteraction[data-visual-state="selected"] {
  border-color: var(--glass-line-strong);
  box-shadow: 0 0 16px rgba(212, 175, 55, .18), inset 0 1px rgba(255, 255, 255, .07);
}

.buildingInteractionName {
  grid-row: 1 / 3;
  overflow: hidden;
  max-width: 16ch;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .03em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.buildingInteractionLabel {
  color: var(--game-muted);
  font-family: var(--utility);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.buildingInteractionValue {
  color: var(--game-gold-light);
  font-family: var(--display);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

@keyframes interaction-plate-in {
  from { opacity: 0; transform: translateY(5px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .buildingInteraction,
  .bld.hit .buildingBody { animation: none; }
}
