The interesting question is if purpose is an epiphenomenon, as per this definition - a mental state regarded as a by-product of brain activity. In other words an epiphenomenon is the effect of a cause, but it has no causal effect itself. It is nothing but the effect of something else.
Just to get the philosophy out of the way by stating the assumptions, it is a combination of methodological naturalism in both the analytical tradition of philosophy and a variant of phenomenology as per intent.
So what I will try to do, is to reduce purpose and intent away as only an effect of function and as with no causal effect for these concepts. But I will try to avoid greedy reductionism and that comes at a price in regards to science per the ideal of only objective cause and effect.
Further I will use a sloopy style in that by way of analogy, in that between a complex math problem and the solution I won't always state all the steps to get there.
First the ladder of physical, chemistry, biochemistry, evolution, humans and then all the soft stuff. In principle it is connected by the concept of bridge laws and in the ideal of objective as described by scientific laws.
So here it is a verbal connective bridge law for the mental versus the physical. The mental is the effect/product of the physical processes in a given brain.
But and there is a big but, not all physical processes are objective in practice when you include humans in the model. How, and not why?
Because the replication of the fittest genome is an cause and effect system that for humans are not independent of cause and effect in brains.
In other words, for the greedy reductionism of objective physicalism then all physical processes are independent of brains, but that is absurd, because this text as an effect is caused in part by a brain, mine.
So what is design and intent? It is a self-referring function of a brain, which is capable of making an abstract model of cause and effect for the future.
Humans are an evolutionary variant, because in short our niche is our ability to make functional abstract models and plans, that allows us to achieve food, water and other factors in ways non-humans can't. I.e. a design is a function of a brain, that makes make functional abstract models and plans, that allows that brain and other ones to achieve food, water and other factors. And an intent is a model of a functional cause in a brain for a desired effect.
And yes, there is more. But this text is not true. It is a self-referring narrative of how to understand humans as humans as being in nature, parts of nature and functioning as parts of nature.
But it says nothing about the answer to the ultimate question of life, the universe, and everything, because that answer is subjective and thus non-hard science.