Optimizing the specificity window of biomolecular receptors using structure-switching and allostery.