Safer batteries for storing energy at massive scale