1/* A gradient going from the top to bottom
2 starting red and finishing orange */
3
4.class {
5 background: linear-gradient(to bottom, #f32b60, #ff8f1f);
6}
1body{
2 /*Radial Gradient*/
3 background-image: radial-gradient(#EA52F8 5.66%, #0066FF 94.35%);
4 /*Linear Gradient*/
5 background-image: linear-gradient(45.34deg, #EA52F8 5.66%, #0066FF 94.35%);
6}
1/* A gradient tilted 100 degrees,
2 starting gray and finishing black */
3
4.class {
5 background: linear-gradient(100deg, rgba(63, 63, 63, 0.8) 0%, rgba(255, 255, 255, 0) 25%);
6}
7
8/* A gradient going from the bottom to top
9 starting red and finishing orange */
10
11.class {
12 background: linear-gradient(to top, #f32b60, #ff8f1f);
13}
14
1#show_bg_2 {
2
3background-image:
4 /*two color gradient over an image*/
5linear-gradient(to bottom, rgba(245, 246, 252, 0.52),
6rgba(117, 19, 93, 0.73)),url('images/background.jpg');
7
8width: 80%;
9height: 400px;
10background-size: cover;
11}
1.yourElementClass{
2 background: linear-gradient(to top, #fff000 0%, #000fff 100%);
3 /* 1st property: from where the 100% starts */
4 /* 2nd property: the first color */
5 /* 3rd property: the second color */
6 /* to add some colors to the gradient, do the same thing of 2nd and 3rd properties, edit the color and the color-stop */
7}
1background: repeating-linear-gradient(to right top, rgb(0, 102, 255), rgb(0, 204, 255));