Totti inspires five-goal thriller