In Japanese, mahou shoujo 魔法少女 means "magical girl," or more literally, "magic girl," in the sense of a "girl," shoujo 少女, who can use "magic," mahou 魔法.
In anime, this specifically refers to a genre that deals with girls becoming able to use magic, generally by forming a pact, "contract," keiyaku 契約, with some bizarre magical being, and then transforming into all sorts of cute outfits, to battle in order to save the world and fill it with love, peace, hope, sugar, spice, and everything nice!
The most classic example of it being Sailor Moon, which is a shoujo manga, which means it's targeted at young girls, which means it also has a lot of romance and dokidoki and stuff that shoujo manga has.
A lot of classic mahou shoujo series are targeted at the shoujo demographic. After all, in a mahou shoujo, the protagonist is a shoujo, a "girl," so it follows the reader that would identify best with it would be a shoujo too. Another example being the PreCure franchise, also targeted at girls.
However, note that the mahou shoujo genre has been subverted to death already. In every way imaginable.
To begin with, just like how in Power Rangers, which would be for boys, each ranger transforms into one specific color, when magical girls transformed, they always transformed into the one same magical outfit. And then came Cardcaptor Sakura, which had the magical girl change into a different outfit literally every time.
And who said it has to be a light-hearted series about hope and stuff, anyway? Why not be a series about despair and hopelessness! That's how we got Mahou Shoujo Madoka Magica.
Next, in a stroke of moronic genius, one wise idiot philosophized the following question: "who said a magical girl has to be a girl?"
Obviously, it HAS to be a girl. If it was a boy it would be a "magical boy." That's... that's literally in the word: magical GIRL, mahou SHOUJO, not mahou SHOUNEN. And what's up with that question, anyway? I mean, there are already dozens of series where a boy can transform into a demon or a huge nine-tailed fox or whatever in order to fight.
But nope. It had to be a magical GIRL boy. Which meant, of course, that it was boy, that transformed into a magical girl. For example, in Kore wa Zombie Desu Ka?, when the protagonist, who's a guy, transforms, he ends up in "girls' clothes," josou 女装: a cross-dressing magical girl. He's also a zombie, by the way, but that's unrelated.
In Ore, Twintail ni Narimasu, the protagonist, through the power of his sheer love for the pigtails hairstyle, which's far stronger than that weak, generic "love" from generic mahou shoujo anime, and also alien tech, he's able to make his body "turn into a female body," nyotaika 女体化, and transforms into a pigtailed gender-bent magical girl. (I'm not making this up.)
But that didn't stop there. Next, an even more moronic sage, set to surpass all these idiots, pondered the following doubt: "who said a magical girl has to be a girl? Part 2: Electric Boogaloo."
Which's how we get Mahou Shoujo Ore, a series about a girl who transforms into a magical macho dude.
At least a mahou shoujo is still a "girl," shoujo, right? I mean, it has to be a young woman. If it was an adult woman, it wouldn't be a "magical girl," it would be a "witch," majo 魔女.
Except not exactly, because a "witch" is a "woman that uses magic," meanwhile a mahou shoujo is not a "girl that uses magic," a mahou shoujo is a "girl that is magic," a magical girl. A "girl-witch" would be, instead, a majokko 魔女っ子.
Also, the term mahou-tsukai 魔法使い refers to a "magic user" in the traditional fantasy sense: a wizard. Terms like madoushi 魔道士 and majutsushi 魔術師 also exist to refer to sorcerers and stuff. Sumber https://japanese-with-anime.blogspot.com/