Integration and Modeling of a Metasurface Spectropolarimeter for Space Applications