Dash PNG download ignoring CSS

Hi all, I’m having an issue in Dash where the downloaded png image of a plot (created via the mode bar) is showing a slightly different image to the original.

In the dashboard, the image looks like this:
image

This includes some custom CSS, to hide part of the x-axis that users don’t need to see:

#graph-id .xaxislayer-above [class$="tick"] {
    display: none;
}

However, when I download the plot using the mode bar icon, it looks like the below - note the highlighted bit, that’s hidden in the original.

Is there any way to get Dash to apply the CSS to the downloaded image, so that it looks like the plot in the dashboard?