How can I fix poorly stained pine trim with routing grooves and rosettes?
The problem is that pine in general is a difficult wood to stain. Some areas will absorb lots of stain, others that won't. But you have made it worse (not intentionally so) because of the routed regions. These offer much end grain on the surface, which just loves to soak up stain.

There are solutions. First, use a sanding sealer. This is usually a thin, clear liquid that when dry, will plug up the pores of the pine, controlling how your stain is absorbed. (Many sanding sealers are just shellac.)

You can also use a gel stain, a stain that is designed for these problem woods.

As for the existing wood that has been stained and is showing a problem, this will be difficult to fix without stripping. If not much has been stained like that, I'd just replace it with fresh wood.