I suggest you read "Hooked: How to Build Habit-Forming Products.".
* Got rid of the native apps (except for Messenger Lite) years ago
* Switched to mbasic.facebook.com in the browser
* Recently I logged out of said mobile site
Now every time my muscle memory goes to facebook.com it asks me to login and I close the tab. I don't miss it at all and have no urge to login once I see the login form. I think I may have finally quashed my FB addiction!
Of course, you can go the Replicant/PostmarketOS/etc. or Purism/PinePhone or whatnot route, but then you're missing out on so many things and/or have to spend so much time on things (not worth it for me) that you might as well not get a smartphone. A smartphone is greatly reduces in value if your banking app and $popular_messenger_app doesn't work. And besides, it only solves part of the problem: I still have a device too large to comfortably use, in spite of being quite tall with big hands.
Self control and discipline start somewhere.
If you set yourself up not to need to exert this discipline, like in your example of keeping junk food out of the house, that's a burden off your mind.
That's mental energy you can use for other things.
(This simple analogy of requiring exhaustible mental resources for discipline doesn't necessarily apply to everyone. But there are some people it does apply to.)