I literally started again, I used to eat a lot of processed foods, lots of sweet things, was also a very heavy drinker most of my teens and twenties.
I basically set a calorie target, started tracking and focused on taking processed sugar out first (so I was getting those calories from meat, fish, dairy and vegetables) - I went pretty low carb (not none but around 100g per day max) as I felt good on lower carb (still fairly low carb compared to many but up around 300g per day currently on 3,750 Cals).
I didn’t do much in the way of cheat meals/refeeds etc. I’ve always been a bit all or nothing and actually didn’t want to spend all week looking forward to one indulgent meal at the weekend. I focused then (and still do) on enjoying the foods I was eating instead. Doesn’t feel like a diet, I like what I eat and maintaining or cutting weight I find easy these days, it took me a long time to get over the mental side of eating more to gain muscle though......
In short, I took everything I used to eat and changed the lot - only way I felt I could make it sustainable