Fix foundation stacking