Sorry you find yourself in this situation but you have come to the right place. It is good that you regognize how you contributed to your M reaching this point and are taking steps to change. Keep the work going in this area because it is important that your W sees that you are able to sustain your changes and not revert back to bad behaviors. You are going to need patience with this, it sounds like your W put a lot of effort in before dropping the bomb so you will not be able to solve this overnight.
Sandi and others on this board will be along soon with good advice for you. Stay strong and keep working on your improvements!