I often see Germans use this construction, and I'm not sure why. A native speaker would understand it perfectly, but it isn't natural.
We have the construction "because of" + noun; for example:
We couldn't have a picnic because of the rain.
She was sick because of the foul taste of the soup.
Captain Spliff was scared because of the huge size of the Zog Monster.
But we don't usually use this construction with a gerund:
* She was sick because of eating foul soup. (Wrong)
-> She was sich because she ate some foul soup. (Correct)
However, we do sometimes use "because of" + noun + gerund, like this:
He couldn't concentrate because Pete was playing the drums.
He couldn't concentrate because of Pete playing the drums.
When we replace the noun with a pronoun, we use a possessive:
He couldn't concentrate because of his playing the drums.
This construction is most natural when the subject of the subordinate clause is not the same as the subject of the main clause.
You can nearly always replace "because of" + noun/possessive + gerund with "because" + subordinate clause, so a good rule of thumb is:
"because of" + noun ("because of the rain")
"because" + subordinate clause ("because it rained")
I would rewrite your sentence like this:
Younger children join in street gangs because they do not get as much attention as they need.
Student or Learner