A holographic sensor based on a rationally designed synthetic polymer