Repository: flutter
Issue: ToggleButton border radius and fill gets inverted only in Flutter Web with HTML renderer
Labels: engine,platform-web,c: rendering,e: web_html,has reproducible steps,P3,team-web,triaged-web,found in release: 3.24,found in release: 3.26

### Steps to reproduce

1. Create a Flutter project with web enabled
2. Use the provided code in the project as a widget
3. Run the app with following: `flutter run -d web-server --web-renderer html --web-port 3000 --debug`
4. Open browser in `localhost:3000` and see the result

### Expected results

The radius and fill should be symmetric.

### Actual results

The radius is inwards and the fill is inverted resulting in a asymmetric radius and fill

### Code sample

<details open><summary>Code sample</summary>

```dart
class Example extends StatefulWidget {
  const Example({super.key});

  @override
  State<Example> createState() => _ExampleState();
}

class _ExampleState extends State<Example> {
  List<bool> isSelected = [true, false];

  @override
  Widget build(BuildContext context) {
    final ThemeData(:textTheme) = Theme.of(context);

    return ToggleButtons(
      borderRadius: BorderRadius.circular(30),
      textStyle: textTheme.bodySmall,
      constraints: const BoxConstraints(maxHeight: 40),
      isSelected: isSelected,
      onPressed: (index) {
        setState(() {
          for (var i = 0; i < isSelected.length; i++) {
            isSelected[i] = i == index;
          }
        });
      },
      children: const [
        Padding(
          padding: EdgeInsets.all(8.0),
          child: Text("Asset (e.g. bank account)"),
        ),
        Padding(
          padding: EdgeInsets.all(8.0),
          child: Text("Liability (e.g. credit card)"),
        ),
      ],
    );
  }
}
```

</details>


### Screenshots or Video

<details open>
<summary>Screenshots / Video demonstration</summary>

<img width="491" alt="image" src="https://github.com/user-attachments/assets/76f8b18a-05c8-4c32-bf6d-4ea60f09506a">

</details>

### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
[✓] Flutter (Channel stable, 3.22.3, on macOS 14.6.1 23G93 darwin-arm64, locale en-BD)
    • Flutter version 3.22.3 on channel stable at /Users/krtirtho/fvm/versions/3.22.3
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision b0850beeb2 (8 weeks ago), 2024-07-16 21:43:41 -0700
    • Engine revision 235db911ba
    • Dart version 3.4.4
    • DevTools version 2.34.3

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/krtirtho/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.11+0-17.0.11b1207.24-11852314)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.4)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15F31d
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • CHROME_EXECUTABLE = /Applications/Brave Browser.app/Contents/MacOS/Brave Browser

[✓] Android Studio (version 2024.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.11+0-17.0.11b1207.24-11852314)

[✓] VS Code (version 1.93.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.84.0

[✓] Connected device (3 available)
    • macOS (desktop)                 • macos                 • darwin-arm64   • macOS 14.6.1 23G93 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad • darwin         • macOS 14.6.1 23G93 darwin-arm64
    • Chrome (web)                    • chrome                • web-javascript • Brave Browser 128.1.69.168

[✓] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>