Laboratory-based Tender X-ray Emission Spectroscopy: Instrumental, Experimental, and Theoretical Advances and Application to the Study of Phosphorus and Sulfur Electronic Structure