CSS gradients let you display smooth transitions between two or more specified colors.
CSS defines two types of gradients:
To create a linear gradient you must define at least two color stops. Color stops are the colors you want to render smooth transitions among. You can also set a starting point and a direction (or an angle) along with the gradient effect.
background-object: linear-gradient(direction, color-stop1, color-stop2, ...);
directions: to top, to bottom (default), to left, to right, to bottom right, to top left, etc.
If you want more control over the direction of the gradient, you can define an angle, instead of the predefined directions (to bottom, to top, to right, to left, to bottom right, etc.).
background-object: linear-gradient(angle, color-stop1, color-stop2);
The angle is specified as an angle between a horizontal line and the gradient line.
background-object: linear-gradient(color-stop1, color-stop2, color-stop3);
A radial gradient is defined by its center.
To create a radial gradient you must also define at least two color stops.