The recent decline is blamed on the smart phone and worsening education, nothing to do with leaded gasoline.
The surge in obesity is thanks to the sugar lobby
https://www.npr.org/sections/thetwo-way/2016/09/13/493739074/50-years-ago-sugar-industry-quietly-paid-scientists-to-point-blame-at-fat
https://www.cpreview.org/articles/2024/6/sugarcoating-the-truth-the-role-of-lobbying-in-americas-obesity-epidemic

https://pmc.ncbi.nlm.nih.gov/articles/PMC4822166/
And labels are still misleading. recommended daily sugar is 50 grams yet in Canada the %dv indicates 100 grams daily, in the US 300 grams daily!


USA 42g = 14% -> 100% = 300 grams
Canada 39g = 39% -> 100% = 100 grams
The US version uses high-fructose corn syrup (HFCS), Canadian Classic Coca-Cola uses a mixture of sugars, including cane sugar.
The powerful corn lobby is behind the surge in obesity.
Your link for nature doesn't work, however decline in cognition (at later age) is not the same as global decline in IQ
https://pmc.ncbi.nlm.nih.gov/articles/PMC4237034/
It is abundantly evident that there is a deleterious effect of obesity/high fat feeding on cognitive performance. In human clinical studies, obesity has been shown to increase the risk of the development of mild cognitive impairment, in the form of short-term memory and executive function deficits, as well as dementia and Alzheimer's disease.
The exact mechanisms or mediators that underlie the connections between obesity and the risk of cognitive impairment are still unknown but potential avenues of further research include brain atrophy, disruption in cerebrovascular function, development of Alzheimer's disease related pathology, BBB breakdown, and systemic and central inflammation.
Dementia is indeed also on the rise, but that's more related to old age, people getting older. However obesity can also contribute to 'brain aging'.
However smart phone / education are responsible for decline in global IQ (reading and math scores going down since 2008)
Rise in obesity is thanks to our diet, cheap sugars, processed food, leading to a decline in cognition at later age.