Eh, it's somewhat subjective, messy, and hilarious.
To me, "cartoon" refers to Western animation while "anime" refers to Japanese animation (and Eastern animation by extension). They're just terms that help me mostly when having a discussion. However, I wouldn't be offended if you called a Japanese animated work a cartoon because when you split the hairs it's still an animated work.
The idea of one having some level of "maturity" while another seems like a moot point to me.
To me, "cartoon" refers to Western animation while "anime" refers to Japanese animation (and Eastern animation by extension). They're just terms that help me mostly when having a discussion. However, I wouldn't be offended if you called a Japanese animated work a cartoon because when you split the hairs it's still an animated work.
The idea of one having some level of "maturity" while another seems like a moot point to me.