Extensions of Ehrhart theory and applications to combinatorial structures