Confused about backup/sim card/SD card
Bought iphone X in late December 2017. All appeared to work as it should. Photos accessible, apps working even automatic data back ups when connected to home wifi and charging overnight.
A week ago, toward the end of road-trip vacation, my phone shut it's self off. It happened while removing the phone from it's case (I originally thought I shut it down accidentally) and phone indicated I must connect to itunes store for restore. Asked multiple sources, including Apple store, how to do this and keep photos, but was told not possible without using 3rd party data recovery. After 3 days of trying all reasonable options, gave in and used itunes to restore. As expected last 2 weeks of photos are gone.
My question(s) is(are) why are some pictures saved and others lost? What goes on sim card and what on SD card? Are they the same?
My phone says it has not been backed up in 33 weeks (about the time of purchase), yet I frequently got messages that phone was successfully backed up.
The kicker is, all photos except last 2 weeks, are still on my phone, as if no problem, but messages/voicemails/podcasts are reset to, first day welcome to iphone settings (all gone).
What data is deemed save worthy and what is not? Photos from 1-8 months ago saved, but messages and voice mail from same time is not...? Contacts are saved (even recently input contacts), yet phone "not backed up for 33 weeks" How does that work?
iPhone X, iOS 11.4.1