語法:
background-image: linear-gradient(direction, color-stop1, color-stop2, ...);
/* 從上到下,藍色漸變到紅色 */
linear-gradient(blue, red);
/* 漸變軸為45度,從藍色漸變到紅色 */
linear-gradient(45deg, blue, red);
/* 從右下到左上、從藍色漸變到紅色 */
linear-gradient(to left top, blue, red);
/* 從下到上,從藍色開始漸變、到高度40%位置是綠色漸變開始、最后以紅色結束 */
linear-gradient(0deg, blue, green 40%, red);
0deg=to top;
90deg=to right;
180deg=to bottom;
-90deg=to left;
