The problem is simple. When you execute a forehand, you proceed by habit, so to speak. You treat the execution of a tennis shot as a single block of information after sufficiently many repetitions of the same thing. It is indeed the efficient thing to do: you need to free up your ability to focus from all the moving parts of a forehand to tracking the ball and picking the right reponse out of your bag of tricks to become a good player. However, when you do shadow strokes, there you mind about your form -- and it becomes even clearer when you slow things down.
If you want to get a professional-level form, you will need to do thousands of repetitions doing the right thing -- and as few as possible doing the wrong thing. So, I have a solution for you.
1) For the next week or the next few weeks, depending on how many repetitions you can get every day, you will not play a match or have a friendly hitting session. If you ever get to hit a ball in a live situation before having worked enough on your form, you will go back to your bad habit, so you need to stop it right now.
2) You will do at least one hunred forehands per day, slowly as shadow strokes in front of a camera or mirror. You should do most of them as if they were real forehands: that means you can only occassionally look at the mirror because you should practice looking at your contact point and tracking the ball with your eyes, as well. If you can do a thousand of those shadow strokes per day in the next week, do it. However, you have to realize that you do have to complete your transition over several days because sleep allows you to modify the paths in your brain -- which is what you want to do.
3) Once you have done this for a few days, you can get a bucket of ball and go to a court alone. You'll go on the court, position yourself at the baseline and you will be hitting off self-feed balls. You shouldn't worry about what your shot looks like: don't look where the ball goes for now. Moreover, you should be doing a full stroke: you start from the ready position and toss the ball up; you do a unit turn and adjust your position with respect to the ball by moving your feet; you take the racket back and extend your non hitting arm; you hit the ball and tuck in your non hitting arm; and you follow through properly. Also, try to AVOID hitting hard. You want to slow it down enough so you can pay attention to your form. If you wish, you can stand inside the baseline.
Moreover, before hitting a ball, shadow your stroke, say 50 times, then begin to hit. Between each ball, shadow it, say, 10 times. And, when you sent the whole basket on the other side of the net, you retrieve the balls, then do 50 more shadow strokes and go over the whole basket again (slowly, as well).
4) Once you have done this a few times (say, you have over 2000 shadows strokes and 300 or 400 slow forehands), you can start picking up the pace. You don't try to forcefully hit hard, but just allow yourself to rotate more violently into your shot. Film yourself and you'll see that your form will be neat. If you are satisfied, you can then move up to playing an actual person again.
I won't lie to you: it's annoying to do. You know you can hit good shots, you want so bad to hit hard, but changing what neuropaths are geared to instantly accomplish a forehand shot is an insanely long process and the more you are careful about it, the greater the quality of the end product. A great Russian academy gets kid doing shadow strokes and live feeds for 3 whole years before they even get to play a match -- and they aren't allowed to do it outside on their own either -- to make sure their form is irreproachable before they start thinking about how to adjust to match situations. I ask you to do this for just a week or two, depending on how much time you can afford to spend per week.