<!--  As an open source project with a dedicated but small maintainer team, it can sometimes take a long time for issues to be addressed so please be patient and we will get back to you as soon as we can.
-->

### Preflight Checklist
<!-- Please ensure you've completed the following steps by replacing [ ] with [x]-->

* [x] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/master/CONTRIBUTING.md) for this project.
* [x] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/master/CODE_OF_CONDUCT.md) that this project adheres to.
* [x] I have searched the issue tracker for an issue that matches the one I want to file, without success.

### Issue Details

* **Electron Version:**
  * 9.3.4
* **Operating System:**
  * Arch Linux
* **Last Known Working Electron version:**
  * 9.3.3

### Expected Behavior
```
❱ echo lang: $LANG lc_all: $LC_ALL
lang: en_US.UTF-8 lc_all:
❱ electron9 -i                    
> process.env.LC_ALL
undefined
```

### Actual Behavior
```
❱ echo lang: $LANG lc_all: $LC_ALL
lang: en_US.UTF-8 lc_all:
❱ electron9 -i                    
> process.env.LC_ALL
'en_US'
```

`en_US` is not a valid locale—it has to be `en_US.UTF-8`, however, Electron overrides this, even if `--lang=en_US.UTF-8` is passed or `LC_ALL` is set correctly when invoking Electron. With this invalid value, many C programs fail to run.

### To Reproduce
Run the above commands.

### Additional Information
Problem introduced in  #26242
shell/browser/electron_browser_main_parts.cc
public:
  DarkThemeObserver() = default;
  
  void OnNativeThemeUpdated(ui::NativeTheme* observed_theme) override {
    UpdateDarkThemeSetting();
  }
};
#endif
ElectronBrowserMainParts* ElectronBrowserMainParts::self_ = nullptr;
ElectronBrowserMainParts::ElectronBrowserMainParts(
    const content::MainFunctionParams& params)
    : fake_browser_process_(new BrowserProcessImpl),
      browser_(new Browser),
      node_bindings_(
          NodeBindings::Create(NodeBindings::BrowserEnvironment::kBrowser)),
      electron_bindings_(new ElectronBindings(node_bindings_->uv_loop())) {
  DCHECK(!self_) << "Cannot have two ElectronBrowserMainParts";
  self_ = this;
}
ElectronBrowserMainParts::~ElectronBrowserMainParts() {
  asar::ClearArchives();
}
ElectronBrowserMainParts* ElectronBrowserMainParts::Get() {