In a word, panic. Anxiety and fear make the world appear frightening and senseless; stocking up on certain items like toilet paper is one way to restore a feeling of control. Panic buying is also driven in part by herd mentality; if people see that others are hoarding hand sanitizer, they assume they should too.