Retailers are frequently running out of everything from flour and fresh meat to toilet paper and pharmaceuticals. Here’s why.