Ryan Hardie’s second-half penalty secured a famous victory for the Sky Bet Championship’s bottom club against Liverpool.