Sorry for the delay, I was called out of town. Did you compare your Mail settings on the iPhone and iPad? So you are sure they are IMAP settings?
As far as Thunderbird for the desktop, I'm not familiar with that program, but I still believe that is where the problem is. To test, have someone send you an email to the address that you use on the 3 platforms. Check the mail on the iPhone and iPad. If it arrives fine, then do not check for mail on the desktop. After 30 minutes, which you gave as a time that mail disappeared before, check the iPhone and iPad again. If the mail is still there, then open the mail program on the desktop and see if you receive the mail, and then check the iPhone and iPad. See if the mail is still there. You may also wish to check the Thunderbird program to see if you have any rules set up to do anything special with mail that has been received, such as move it to another folder, etc. See if the mail disappears. Without being able to see the devices and the mail settings, it is difficult to diagnose anymore than what has been done. There are no settings on the iPhone or iPad that would delete mail as you have described.