It is not some magical phenomenon that ever comes from anywhere else, as far as we've ever seen, or been able to deduce. It is extremely probable and reasonable, to surmise that intelligence is a product of the brain. Not necessarily a human brain, but any sort of brain-like thing, in which information can similarly be relayed. Without any such circuitry, how would any sort of thought or awareness happen?
We can look at any sort of complex process, from fractals to colonies of bacteria, and think, who knows? Maybe intelligence is an undetectable side-effect of that, too - the problem is that there's no known reason that would be true. It would serve no evolutionary purpose, and we can discern no manner in which it could work, nor even the slightest shred of evidence that it does.
It's pure fanciful conjecture based on nothing but imagination, and quite frankly, ignorance, on a variety of subjects. That makes it extremely unlikely to have any real merit.
* * *
* * *
All very much a part of the material world. It's just a matter of looking closely enough.
The brain produces neural impulses, but it's also equipped to read them. Without the nervous system, they're just tiny indistinct bursts of electricity. They don't exist as thoughts or feelings, until the brain interprets them as such, which has more to do with which pathways are being stimulated.
As Gautama realized two and a half millennia ago, consciousness is not a real thing. It's an illusion. Anatta.
* * *