Rio de Janeiro is improving. The city is as beautiful as ever, but now it is also safer and has become a magnet for investments. Rio will host the World Cup next year and the Olympic Games in 2016, and the infrastructure that we are building is improving mobility, housing and the entire urban landscape. Despite some faltering, Brazil is doing well economically and Rio is also benefitting from that, so on the surface there are reasons to be optimistic. Despite this positive outlook, we are also experiencing a crisis of trust. Thousands of people have taken the streets to demand answers from the political establishment, who have been scratching their heads as to why this negative sentiment has suddenly erupted. After all, there is no shortage of jobs and our economy is doing just fine. But the voices on the streets are justified. What we currently experience in Brazil is undeniable political turmoil, and there is small consolation in the knowledge that protests are inherently democratic. Democracy is loud by definition, and yet those rallies indicate a wider phenomenon -- they are happening in squares around the world -- discontent is the common, if varied theme. Because these protests are aimed at politicians and the political landscape, they can only be explained through a political lens -- as such, they indicate a crisis of representative democracy.

If we are to understand this crisis, we must head back some 2,800 years and step into the Greek city-states, the Polis. In the Polis, citizens engaged personally in heated debate over political issues. Those debates took place at the Agora, a square located at the center of the Polis. That was the birth of direct democracy, the form of government by which citizens' opinions forged rules and legislature.

As cities grew, direct democracy became less and less feasible. The Roman Empire transformed the Greek Agoras into forums, where assemblies of elected officials would gather and vote on policy initiatives. Later, the English Parliament added the concept of social contract, which further legitimized representative democracy by concluding that individuals willingly submit to the decision of the majority in exchange for the protection of their rights. Subsequently, the principles of equality, the universal vote, and popular sovereignty matured in line with representative democracy. Yet, throughout the centuries, the political model has remained the same as in ancient times.

It was this form of democracy that defined, with minor variations, the present-day political structure of the majority of the world's nations. Elected representatives are so embedded in the basic notion of what constitutes a democratic nation, that it has become indistinguishable from any other form of democratic governance. On the international stage, representative democracies and their heads of state came to wield immense power. That international governance system crystallized after World War II, when heads of states assumed significant influence over policies relating to economics, war, energy, aid and human rights. That was the pinnacle of nation states.

Two recent phenomena are prompting a significant change to what people perceive as democracy. First, the rising power of the cities. The world has become mostly urbanized and according to UN Habitat, 70 percent of us will be living in cities by 2050. Most of the world's most pressing issues belong to cities: health, education, mobility and even matters that apparently pertained to nations, such as climate change and employment.

The political analyst Benjamin Barber points out that globalization has diluted country boundaries and that the old institutional order of nation states has become "dysfunctional". Designed in the past, it is failing to address 21st century challenges. As a response, we observe the rise of new forms of international governance, such as the C40 Cities Climate Leadership Group, a network of the Mayors of the world's largest cities that promotes effective policies on urban sustainable development and reduction of carbon emissions. In 2012 at the Rio+20 UN Summit, C40 Mayors committed to cutting carbon emissions by 1.3 gigatons in 2030, the equivalent to the emissions of Canada and Mexico combined, while national governments remain entangled in complex multilateral negotiations.

The second phenomenon is the ubiquity of the digital revolution. Technology has shrunk the world and squeezed distances. It has made it possible for people to connect and communicate on an unprecedented scale. Debates among citizens are now more agile and much more varied than they were in the Greek agora. The difference is that those heated urban debates now take place online across multimedia platforms with data, words, pictures and video streaming.

The digital revolution has deepened the crisis within representative democracy. But as it forces its demise, it might also dictate its future. Traditional representative democracy within nations is no longer enough. People want more participation and collaboration with their government. They demand to be closer to institutions and authorities. The Polis is back and the Internet is the new Agora.

How do we deal with this revolution and merge the two phenomena? There are no easy answers. First, we must listen. In essence, people yearn to connect with institutions, more than merely participating in the electoral process. Legitimacy has to be renewed everyday in real-time and not once every four years. Formal consultation must develop into constant collaboration.

There are some attempts in many parts of the world. Under Mayor Rahm Emanuel's administration, Chicago has adopted the "City Hall in Your Community" initiative that aims to increase transparency and ask its citizens to propose agendas and priorities. Mayor Bloomberg of New York City has promoted Hackathons to engage the tech community and leading design thinkers to solve urban problems. I myself have used the Google Hangout platform to debate with prominent critics of my administration online. There are many other innovative and participative solutions employing technology to amplify democracy. And there is much more do be done.

What we are witnessing is the birth of something I call Polisdigitocracy. This is a form of government that counts participation and transparency as its cornerstones and uses technology as its guide. The digital revolution is allowing democracy to recall its foundations and evolution is modernizing and reinforcing our fundamental values. And we are only at the beginning of that journey.