It is based motly on inherited genes, and is a refined skill.
It is nearly impossible to use magic outside of the type you were born with.
The limitaions on power are based mostly on mental capacity, so some people can be much stronger than others, and some neurodivergent people are massively powerful.
There are some exceptions, in cases of mortal fuckery or non mortal beings.
Immortal beings have a vastly higher capacity for magical power, having different, more resilient minds.
Types of magics