Is it possible to give an endorsement via text message or email?
Easy, peasy. Fill out a label/sticker with the endorsement printed on it. Then, all you have to do is sign it and place your CFI number on it. You can then either scan it or take a photo of it. Your student can upload the scanned document or photo into an electronic logbook. If they do not have an electronic logbook, they can print out the endorsement at the FBO to put into their paper logbook. When you and the student are together again, you can place the actual label/sticker in their logbook. Alternatively, you can use regular paper. Then you can cut the endorsement into a manageable size and tape it into the logbook. Also, if you and your student use the same software for your electronic logbooks, many have a function to sign endorsements electronically even at a distance (through the internet).