CSS3 is a third generation of the CSS specification recommendations from the W3C
Here comes new selectors, pseudo elements and classes, properties and values specifically created to answer the needs and solve the problem of modern web design and development
Regular RGB - rgb(x, x, x): rgb(255, 0, 0)
RGB with alpha-opacity - rgba(x, x, x, y): rgba(255, 0, 0, 0.2)
Alpha opacity:
0.0 = 0% = No Opacity
1.0 = 100% = Full Opacity
HSL Stands for Hue, Saturation and Luminosity (Lightness)
1. Regular HSL - hsl (x%, x%, x%) - hsl (0, 100%, 50%)
2. HSL with alpha-opacity -
hsla (x%, x%, x%, y)
hsla (0, 100%, 50%, 0.5)
Red - 0 Degree
Yellow - 60 Degree
Green - 120 Degree
Cyan - 180 Degree
Blue - 240 Degree
Magneta - 300 Degree
Numbers followed by -webkit, -moz, or -o- specify the first version that work with a prefix
Syntax:
background: linear-gradient(direction, color-stop1, color-stop2, ...);
Example
Result