Improving Unicode support in the Beamer template

The default Beamer template didn't work for a markdown source with Unicode characters. I copied some features from the normal Latex template and it seems to work better.