A microscopic look at why the world is running out of sand