Rational design of enhanced photoresistance in a photoswitchable fluorescent protein