The ordinary understanding of the legitimacy of democratic governments is that their authority derives from a popular mandate; the government can legitimately impose laws on citizens because those citizens have the ability to replace the government if they choose.
The argument that popular consent makes the decisions of democratic governments legitimate is based on the assumption that the people impacted by those decisions are the citizens who are alive and voting.
Because greenhouse gas pollution endures for so long in the atmosphere, people for tens of thousands of years will be affected by the choices we make now. In particular, how much fossil fuel we collectively choose to burn during the next few decades will have a huge impact on the kind of world many future generations inhabit. We have a choice between passing on a world that largely resembles the one we inherited or passing on one that is radically transformed, largely in ways that are deeply harmful to the life prospects of future generations of human beings.
In this way, citizens and governments have entered into a conspiracy against future generations. Governments do not meaningfully restrict the use of fossil fuels. Indeed, they positively encourage it. This policy is popular because it facilitates many things that people value: from inexpensive domestic and foreign travel to cheap and uninterrupted electricity, air conditioning, winter heating, consumer goods, and all the conveniences and pleasures that exist in our energy-intensive lives. In order to maintain those lifestyles, we choose to burn vast quantities of fossil fuels.
The consequence is that many people with no political voice are made to suffer. This in turn undermines the moral legitimacy of the arrangement. The consent of the governed is a point in favour of democratic governments, but they must also be held accountable for the consequences of their actions on defenceless members of future generations who will suffer from the pollution we produce but who have no political voice.
What we are doing now is effectively treating members of future generations as our slaves, or at least as people whose interests do not matter at all. When democratic governments choose to treat people in that way, they lose the ability to convincingly argue that their behaviour is ethical. The question for individuals then becomes: “What should I do personally, living in this unjust society?”