Case law on this seemingly requires some nexus to a border. In Almeida-Sanchez v US[0], a Mexican citizen was stopped while driving on an east-west road that was near the border but that didn't connect to the border. The marijuana that was found in his car was excluded because there was no proof he was actually crossing a border, just near it.
So I'd expect, under a functioning legal system, a warrant would be required to search your phone if you landed in JFK on a flight from Altoona.
no need to imagine
https://en.wikipedia.org/wiki/Civil_forfeiture_in_the_United...
This jogged my memory, though I couldn't find the example I was thinking of. But here's an item that is pretty similar:
https://en.wikipedia.org/wiki/Tenaha,_Texas_asset_forfeiture...
Edit: Not on the border, btw. Just people travelling inside US. I guess it was their mistake to carry cash instead of getting a bank check or something.
Maybe my anecdotal experience is influenced by me being in IT, but still.
I do know two people who have experienced them as a result of the government taking a personal interest in them, so it's certainly not impossible. However, it's not a common experience.
I've personally experienced searches of my suitcases about four times in about 100 U.S. border crossings (as a U.S. citizen, but the people performing or directing those searches generally didn't know my citizenship status), and zero electronic device searches.