I was correct in the surmise in the comments. If you create a test example (in JS Fiddle or a test HTML file) then the property is being applied when you inspect in Dev Tools, but cannot be seen visually. Why is this?
There were several stories about users privacy being compromised by malicious sites adding links (often hidden) to their pages, and then using the :visited pseudo class to determine if the user had visited the URL or not.
As a result the Mozilla Developer Network states-
Note: For privacy reasons, browsers strictly limit the styles you can
apply using an element selected by this pseudo-class: only color,
background-color, border-color, border-bottom-color,
border-left-color, border-right-color, border-top-color,
outline-color, column-rule-color, fill and stroke. Note also that the
alpha component will be ignored: the alpha component of the
not-visited rule is used instead (except when the opacity is 0, in
that case the whole color is ignored, and the one of the not-visited
rule is used.
Though the color can be changed, the method getComputedStyle will lie
and always give back the value of the non-visited color.
For more information on the limitations and the motivation for them,
see Privacy and the :visited selector.
See https://developer.mozilla.org/en-US/docs/Web/CSS/:visited
The fact that the colour property was being applied was also only half true, in that it is reported as applied and visually present - but the getComputedStyle method will lie and return the colour as if the rule was not applied.
As a result malicious webmasters can no longer determine websites you have been visiting using this technique.