One consequence of electromagnetic duality (see e.g., https://doi.org/10.1038/s41467-023-36420-4) is that if we have a system described by permittivity and permeability profile $(\varepsilon, \mu)(\mathbf{r})$ that has an eigensolution with associated electric and magnetic fields $(\mathbf{E}, \mathbf{H})(\mathbf{r})$, then the "dual" problem $$ (\varepsilon', \mu') = (\mu, \varepsilon) $$ will have an eigensolution ($Z_0 = \sqrt{\mu_0/\varepsilon_0}$) $$ (\mathbf{E}', \mathbf{H}') = (Z_0\mathbf{H}, -Z_0^{-1}\mathbf{E}). $$
While I can reconcile this with Maxwell's equations, I'm having trouble reconciling it with the respectively vectorial and pseudovectorial transformation properties of $\mathbf{E}$ and $\mathbf{H}$ under spatial transformations.
In particular: suppose there is an affine transformation (i.e., proper or improper rotation) $R$ with matrix form $\mathbf{R}$ acting on the fields. We know that it acts on $\mathbf{E}(\mathbf{r})$ and $\mathbf{H}(\mathbf{r})$ in different ways since one is a vector and the other a pseudovector: $$ R \mathbf{E}(\mathbf{r}) = (\mathbf{R}\mathbf{E})(\mathbf{R}^{-1}\mathbf{r}),\\ R \mathbf{H}(\mathbf{r}) = \det(\mathbf{R})(\mathbf{R}\mathbf{H})(\mathbf{R}^{-1}\mathbf{r}). $$
Now, if I try to apply these rules to the dual solutions $(\mathbf{E}', \mathbf{H}')$ I become confused. Because, on one hand (first applying the transformation rule, then using duality): $$ R \mathbf{E}'(\mathbf{r}) = (\mathbf{R}\mathbf{E}')(\mathbf{R}^{-1}\mathbf{r}) = Z_0(\mathbf{R}\mathbf{H})(\mathbf{R}^{-1}\mathbf{r}) $$ but on the other hand (first using duality, then applying the transformation rule): $$ R \mathbf{E}'(\mathbf{r}) = Z_0 R\mathbf{H}(\mathbf{r}) = Z_0\det(\mathbf{R})(\mathbf{R}\mathbf{H})(\mathbf{R}^{-1}\mathbf{r}). $$ So... which is it?
More broadly, I'm trying to understand how in one sense duality is placing the electric and magnetic fields on the same footing - and in another sense, they are endowed with different transformation rules. I.e., why is one a vector and the other a pseudovector? Similarly, how to think about the Lorentz force equation under duality transformations?