Analytical Valuation of Compound Options Under Regime-Switching Dynamics