Party hails 'historic' result, but it is not immediately clear whether it will be able to form a government.