Complete backend rewrite of options page