The fact that this trope is placed in opposition is highly ironic and self-defeating because Romanticism is a product and creation of the Enlightenment itself. Depending on the thinker, its a correction, rejection or broadening of the Enlightenment but the fact is, its a feeling that can only really exist in a post-Enlightenment world.
The longing and nostalgia for nature and being closer to earth is felt more keenly with the rise of industrialization, Walter Scott's nostalgia for medieval Scotland and England only came about after the integration of Scotland with the United Kingdom (of which he was a proud supporter-he regarded Scotland as "a costume" and not a country), the passion for national folklore comes about as a result of the rise of nation states in the wake of the American and the French Revolution (both of them Enlightenment projects) where a new society of multiple classes, no longer bounded by Kingdoms (at least in theory) needed a narrative of shared history to bind it together. Likewise the strong emphasis on individualism and feeling in romanticism is a product of an era that asserted and invented Human Rights. Critics of Romanticism often point out that much of the trope deals with sentimental hankering for a sanitized past from the comfort of a present built on dislodging it. Defenders point out, that if the world of science and technology was supposed to represent the pinnacle of human feeling and achievement, why do people reject the present, why do people remain unhappy with progress?
The Enlightenment itself, for a long time, for much of the 18th Century, had a strongly utopian character. In 18th Century France, thinkers and writers described a modern nation state of secularization, freedom of speech and religion and an end to warfare, thinking that it would bring about modernity and true freedom. The optimism of the Enlightenment suffered a reaction with the contradictions of The French Revolution where progressive ideas were accompanied by violence, both by angry mobs and by the State, and later resulted in the rise of Napoleon, who paradoxically repressed, consolidated and extended the Revolution across Europe. Later on, there was the irony that the rise of nationalism actually eroded the cosmopolitan character of the Enlightenment and people faced up to the fact people will now die for their country instead of King and God, rather than ending conflict altogether.
Romanticism as such contains the disillusionment at good ideas producing contradictory results, a nostalgia for the world that science and modern society is displacing and in the more radical instances, an attempt at regaining or redeeming that utopian aim in the Enlightenment. As such, neither can really exist or displace the other.