Process markdown for output