Before committing to repair, it's worth quickly checking:
Whether the Type Cover and Pen are actually paired/charged — Bluetooth radio issues (sometimes resolved by a firmware update via the Surface app, or a Bluetooth driver reinstall) can knock out both at once.
Uninstall, reinstall and update audio driver.
Running the Surface Diagnostic Toolkit, which will flag whether these are genuine hardware failures or driver/firmware issues.