Complexity Classes (P, NP) vs Language Hierarchies (REC, RE)
All the classes you mention are classes of languages, formally, even if P and NP are often discussed in different (more sloppy?) terms. Note that terminology revolving around decision problems is equivalent to formal languages; the decision is always whether a word is in the given language, i.e. the problem is to solve the word problem.

What you need to do is go back to the formal definitions. Summarising:


$\mathrm{RE}$ contains languages which are accepted by any TM.
$\mathrm{REC}$ contains all languages which are decided by any TM.
$\mathrm{NP}$ contains all languages which are accepted by any polynomial-time TM.
$\mathrm{P}$ contains all languages which are decided by any polynomial-time and deterministic TM.


It's already quite clear from the definitions that we have

$\qquad\displaystyle \mathrm{P} \subseteq \mathrm{NP} \subseteq \mathrm{REC} \subseteq \mathrm{RE}$.

So, essentially, computability and complexity theory deal with the same kind of questions: which kinds of problems can I solve with which type of machine?

In fact, the famous Complexity Zoo diagram (via the companion the wiki) displays "computability", "complexity" and "Chomsky" classes in a single inclusion hierarchy -- because they all use the same formalism.

I recommend you check out some of our reference questions on computability and complexity theory; you'll the similarities.