<sign>
A math function that returns -1 for negative numbers, 0 for zero, and 1 for positive numbers. It's useful for logic-based styling directly in your CSS.
Syntax
/* Usage Example */
.dynamic-element {
/* Scale based on whether the --score variable is positive or negative */
transform: scale(sign(var(--score)));
}
<sign> Browser support
Newly available
Since
2025 82% global usage
Since 2025 this feature works across the latest devices and browser versions. This feature might not work in older devices or browsers.
138+
118+
15.4+
138+