Gravar-mail: Thermodynamic basis for the optimization of binding-induced biomolecular switches and structure-switching biosensors