OverPicture is a Safari Extension that allows you to play any web video in Picture-In-Picture mode.
You can enable Picture-in-Picture for any web video while it is playing by selecting the OverPicture Extension from the Safari share menu. OverPicture also supports video players like YouTube that lack native Picture-in-Picture support.
OverPicture is available for macOS and iPadOS.
Note: You can enable the OverPicture Extension from the Safari share menu.