It's not really either, but somewhat orthogonal
Socialism and capitalism deal with how an economy is organized, not necessarily directly with the system of representation. Thus you can have anarchosocialists and Nicolas Maduro both claiming to represent the true spirit of socialism. As another example, as long as relatively free commerce is permitted, and private enterprise dominates the economy, a country might be considered capitalist. But the government might be a dictatorship that tells its citizens who they can marry and executes any dissenters, or it might be as laissez-faire in every area of life as it is with the economy. Libertarian parties and Jair Bolsonaro both want capitalist systems, after all.
Your proposed system deals with government, not economy directly. You haven't said that any of the shareholders get profits from the government (nor would such a system work; the government usually needs net funding from its citizens to get anything done, not the other way around). It could be argued that it's capitalist in spirit, maybe, insofar as it applies a market ethos to government.
But you could imagine a country that implements your model where everyone owns an equal share of the government, where citizens vote to nationalize most industries and distribute the gains, which fits a typical socialist model (at least as implemented in the real world). Or, you can imagine a country where the citizens own an equal share of the government but vote instead to have unrestricted commerce and high levels of private ownership. Or, you could imagine a country where these shares end up concentrated in the hands of a few people, who will probably vote for something similar to the United States today, or other countries where wealthy people have high political influence.
Your system is probably much more likely in a highly capitalist society, but it's strictly consistent with either a socialist or capitalist economy, or something in between.
That said, some aspects of this model are unclear, and if clarified might lead to a clear socialist or capitalist economy, or at least change the probaility of either. For instance, can people freely buy and sell their shares, or only when they enter or leave a nation? Do children acquire shares from their parents when they die, or are new shares issued?