I know it's easier said than done op but you have to find ways to keep your temper. And certainly don't threaten to throw your DD out. They need to feel loved and secure when they are at their most unlovable.
Teens can be infuriating as they just don't see the impact their behaviour is having on others like an adult would. They don't say sorry easily either. And that means you have to step back, don't get over-involved with things that she is perfectly able to handle at seventeen. Ignore the bad. Praise the good. Pick your battles and protect your own mental health eg pay the money for a dress in to her account in the first place, and let her sort it all out completely by herself, the returns and everything.
If she is not complying with taking medication, then let the doctor talk to her or someone at the prescribing clinic.
If she is not eating properly, keep a full fruit bowl and leave a bowl of healthy easily microwaveable food in the fridge like pasta with Bolognese sauce or a home made veggie casserole, or invest in an air fryer and buy frozen battered fish and air fry frozen chips and let her sort it out herself.
Just push all the responsibility back on to her and support from the sidelines. She's getting frustrated because you are still parenting from the top down. You need to try and change that to parenting alongside and say things like "I'll be interested to see what choices you make concerning X, y and z". And let her suffer the direct consequences if she gets it wrong. Only step in if you think she is in serious danger.
In order to separate from you and become an adult, she is going to reject you and your values for a while. It's perfectly normal teenage behaviour. It's a huge psychological and physical change going from a teen to an adult and they test you while it's happening to make sure you are their steady rock while going through this scary process. She needs to feel psychologically safe while she rattles a few cages, and makes a bit for independence; she needs you to hold steady.
You don't need to tolerate being walked over or spoken to disrespectfully, but you need to be able to model being calm, grounded and fair. Just walk away from any rude or angry talk.
Your teen is also dealing with your unhappy relationship with your DH and the tension in the home that that creates. She probably also feels some impacts from your own poor mental health. So it's good you are getting support for that. Be a bit selfish op. Build up your own resilience and take some time out for yourself. It's exhausting starting a new job. It can feel extremely lonely parenting a teen who is acting out and it sounds like you have zero support from your DH.
I'm through the difficult teen stage and it can be hellish so I sympathise. But I don't think it's a good idea to link Christmas or birthday treats to general behaviour. Those things happened anyway because teens need to feel loved and appreciated for who they are like anyone else. Even when they are being a complete pita.
So my suggestion would be to take her a mug of hot chocolate, apologise for your irritation and bad temper tonight, talk to her like an adult and explain that you are under pressure in your new job, and tell her that she is loved and wanted at home whatever happens between you and her dad, and that you are looking forward to celebrating her birthday in London. And that will model to her taking responsibility for poor behaviour, saying sorry, and trying to make things better, which she will in turn model back to you.
This difficult period doesn't last forever op, things will improve. But it will be a few years before you and your DD are out the other side so look after yourself in the meantime. It's a gruelling marathon and you need to take fuel stops along the way and do stuff that builds you up physically and mentally. Good luck 💐
Edited: just read your update regarding anxiety and eating issues so obviously she needs specialist help with that and above advice may not apply.