Alex_P wants to use the primary color from the color scheme when in dark mode and a custom color otherwise. Since SCSS is not processed at runtime, awesomerobot suggests using CSS custom properties in common/color_definitions.scss. This involves declaring a variable with the dark-light-choose function, which automatically switches between the two colors based on the scheme. Alex_P confirms this solution works but notes the function parameters are in a different order than the function name.
but of course it is not possible because there is no if in CSS and SCSS is not processed at runtime.
And as far as I can see Discourse does not add any classes to indicate whether the dark scheme is active, and CSS does not allow custom properties in selectors.