Legal impossibility occurs when a person's actions, though they may seem like an attempt to commit a crime, cannot result in legal liability because the intended crime is not actually prohibited by law. This means that the individual has not engaged in any conduct that would qualify as a criminal offense due to a lack of applicable law or because the act itself is not criminal under any circumstances. It’s crucial to distinguish legal impossibility from factual impossibility, as the former relates to the law’s definitions and boundaries around criminal actions.