Why does the Cascade for CSS Custom Properties Not Work? [duplicate]
问题 This question already has an answer here : CSS scoped custom property ignored when used to calculate variable in outer scope (1 answer) Closed last year . I have a full working CodePen here showing the problem. I'm using CSS custom properties like so: :root { --global-primary-colour-hue: 211; --global-primary-colour-saturation: 100%; --global-primary-colour-lightness: 50%; --global-primary-colour-opacity: 1; --global-primary-colour: hsla( var(--global-primary-colour-hue), var(--global-primary