"Environment and/or society ( which is part of your environment ) apply selective pressures favoring cognitive abilities. These selections produce increased cognition in decedents indicating genetic influence in cognitive abilities."
Human cognition has not remained stagnant over time. It has evolved. This evolution of cognition was driven by selective forces regardless of those forces being social or environmental or combination thereof. It is important to not confuse technology with our ability to think. However, there is a point where cognition allows for the advancement of knowledge and technology. Somehow we reached that point.
To assume that once we reached this point, human cognition stopped evolving would be more elective than attempting to explore hypothetical situations as applied to our understandings of past peoples to help analyze the question.
We know that we can force selection for intelligence in other mammals [0]( dogs in this thread ). We also know there are significant indications of intelligence related to genetics in humans [1]. ( the wikipedia names a number of caveats, however there remains significant evidence that a portion of intelligence is determined genetically ).
The fact that societies advance to where the selective pressure for cognitive abilities reduces is recognized and not part of this argument. The argument is specifically regarding the selection for intelligence. It is also understood that IQ can be increased through training and society.[2]
[0] https://apps.dtic.mil/sti/pdfs/ADA555235.pdf [1] https://en.wikipedia.org/wiki/Heritability_of_IQ [2] https://en.wikipedia.org/wiki/Flynn_effect