/*
 * An upgrade for a ship not yet unlocked (a fighter type's ammo, the Twin
 * Haul's own upgrades) looks out of reach, as a locked unit card does
 * (deck-locked.css): grey and hatched behind a dashed edge, its name and
 * icon dimmed, its price behind a padlock. Players can tune it out until
 * the ship is theirs (the owner, 2026-12-04). Nothing changes its size.
 */
.upgrade[data-locked='true'] {
  border-style: dashed;
  background: repeating-linear-gradient(
    135deg,
    var(--bg-2) 0 6px,
    color-mix(in srgb, var(--bg-2) 96%, white) 6px 12px
  );
}

.upgrade[data-locked='true'] .upgrade__name,
.upgrade[data-locked='true'] .upgrade__effect {
  color: var(--text-dim);
}

.upgrade[data-locked='true'] .upgrade__head .unit-icon,
.upgrade[data-locked='true'] .upgrade__path {
  opacity: 0.45;
}

.upgrade[data-locked='true'] .upgrade__short {
  color: var(--warn);
}

.upgrade[data-locked='true'] .upgrade__buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  color: var(--text-dim);
  cursor: help;
}

.upgrade[data-locked='true'] .upgrade__buy::before {
  content: '';
  width: 0.6rem;
  height: 0.7rem;
  background: currentColor;
  -webkit-mask: var(--padlock) center / contain no-repeat;
  mask: var(--padlock) center / contain no-repeat;
}
