On Windows 11 use the new WM Window Decoration Styles API, introduced
in ce42d92503. This will match the OS Title bar color to that of the
main window top bar and also do similar color matching with content
in separate windows like Preferences. Note that this will not have any
effect on versions of Windows prior to 11.
Pull Request: https://projects.blender.org/blender/blender/pulls/134054