Thiago Ribeiro scored a hat-trick as Cagliari beat Serie A rivals Pescara 4-2 in the fourth round of the Coppa Italia on Wednesday evening.