There's a tricky (and super interesting) thing with IQ studies. Environmental factors play a dominant role early on, but genetics becomes more and more dominant as a person ages; significant privilege or disadvantage earlier in life notwithstanding (excepting major physical impairment by nutrition, lead, etc)! Most studies tend to find the heritability of adult IQ at around 80%.
Any research on this area is walking on egg shells and so researchers are highly incentivized to overemphasize possible environmental explanations. Nature formalized this threat/risk with their relatively recent announcement [1], but it seems to have been an unspoken 'rule' for decades at least.
[1] - https://www.nature.com/articles/s41562-022-01443-2