Selection indicator is inaccurate

The white outline clearly shows me that I am currently hovering over a specific object, but clicking on that highlighted object will select an object adjacent to it when the hitboxes are close. This occurs regardless of the highlighted object I am clicking on (building, resource, or unit) and the accidentally selected object (building, resource, or unit). The expected behavior is that the white outline that surrounds an object when hovering over it should always indicate that clicking on it selects that specific object.