Stir garlic into the pan and place over medium-high heat; cook and stir for 30 seconds. Pour in vinegar and scrape up any browned bits from the bottom of the pan. Add apple cider and Dijon mustard, bring mixture to a boil, and cook until sauce is reduced and thick, 3 to 4 minutes. Stir in rosemary and red pepper flakes; season with salt and black pepper to taste.