Solomon had been given great wisdom by the LORD, and much of that is shown in the book of Proverbs.
We know that Solomon loved many strange (I Kings 11:1) & outlandish (Nehemiah 13:26) women, which turned away his heart.
It would seem that he didn't actually lose the wisdom.
However when his heart was turned, he apparently saw everything with a turned heart & a jaded mind.
He also apparently saw everything through darkly sinned-tainted lenses, as would appear to be shown in the book of Ecclesiastes.
Those two books show Solomon's wisdom, but in two very different conditions.
One where he apparently had a close walk with the LORD, but the other when he was out of fellowship.
So, can we relate to the book of Ecclesiastes, today?
Is it like a look into the mind of a backslider?
Does that book, more than most of the others, show us how that “backslidden”, “out of fellowship”,
“sin-tainted”, “Laodicean”, “end-times” American Christians are thinking & seeing the world, today?
How much more do "we" think like Ecclesiastes, than we do like the book of Proverbs?