A versatile electrostatic trap with open optical access