Catalonia has 'won right to statehood'