ghstreaa
TL;DR: RokuOS doesnt have GoogleCast/ChromeCast support and your Pixel 7 doesnt have Miracast support, so you cant mirror from your Pixel 7 to your Roku.
----------------------------------------------------------------
RokuOS native casting/mirroring protocol support:
- Supported: DIAL (casting), Miracast (mirroring), AirPlay (casting/mirroring), PlayOnRoku (casting)
- Not Supported: GoogleCast/Chromecast (casting/mirroring), MATTER (casting)
Android OS natively supports GoogleCast/Chromecast (unsupported) and DIAL (supported) - Miracast (supported) support was removed/deprecated (in favor of GoogleCast/Chromecast) since version 6.x, though some manufacturers re-enable it (e.g. Samsung via SmartView).
The YouTube/YouTube TV apps use DIAL (supported) for casting.
Your Google Pixel 7 (Android OS) cant screen mirror to your Roku because it uses GoogleCast/ChromeCast (unsupported) and not Miracast (supported).
Your YT app can cast to your Roku because it uses DIAL (supported).
Its a Google and Roku thing: Google removed/deprecated native Miracast support from Android OS (and you arent using an Android OS device that restores it), and Roku doesn't license/use GoogleCast/Chromecast.
You may be able to install/use a third-party app to provide/'restore' Miracast functionality or other 'proprietary' casting/mirroring functionality, otherwise you wont be able to mirror @ at all (because no Miracast) or cast from most apps (unless they use DIAL - most dont anymore as they (long ago) removed their DIAL support (if they ever had it) in favor of GoogleCast/ChromeCast, with a few exceptions).
(NOTE: Samsung mobile devices provide the 'best' casting/mirroring support in the Android OS world since they (in general, apart from specific firmware version/model limitations) provide both Miracast and GoogleCast/ChromeCast support via the SmartView service/app for mirroring, and apps are DIAL or GoogleCast/ChromeCast enabled for casting)