In the back it could be too much cable tension on the rear derailleur- try turning the barrel adjuster clockwise 1/2 turn or so.
Or instead, it could be a bent derailleur hanger.
What's happening in the front seems very unusual but I suppose you may have not enough cable tension on the front derailleur.
Another possibility is excess frame flex which could be due to a cracked chainstay. Let's hope not.
Al