SwiftUI: How to change List selected item color

iPadOS uses a different selection color when an external keyboard is connected. But the problem is that it doesn't change the text color to white, making it difficult to read:

A simple List with NavigationLink produces this behavior by default:

var body: some View {
    List {
        ForEach(searchResults) { item in
            NavigationLink(destination: ContentDetailView(item: item)) {
                ListItemView(item: item)
            }
        }
    }
}

I tried to improve text legibility by changing all Text colors to white when the cell is selected. But this doesn't work because the text becomes even more unreadable when no external keyboard is connected.

Is there a way to change the selection color when an external keyboard is connected? Or maybe detect when an external keyboard is connected to manually change the text color for this specific case?