/* https://grabient.com/_gLugGQgEsgD6gEsgD6gHCgH0gImgOEgMggK8eSvovogA?style=linearGradient&steps=21&angle=90 */
background: linear-gradient(90deg, #d7621d 0.000%, #dc6d27 5.000%, #df7732 10.000%, #e2803d 15.000%, #e38848 20.000%, #e38e52 25.000%, #e1935b 30.000%, #df9662 35.000%, #db9668 40.000%, #d6966d 45.000%, #d0936f 50.000%, #c98e70 55.000%, #c2886f 60.000%, #ba806c 65.000%, #b17767 70.000%, #a86d61 75.000%, #9f6259 80.000%, #965650 85.000%, #8e4a46 90.000%, #853e3b 95.000%, #7e3230 100.000%);
<svg xmlns="http://www.w3.org/2000/svg" width="800" height="400" viewBox="0 0 800 400" preserveAspectRatio="none">
<!-- https://grabient.com/_gLugGQgEsgD6gEsgD6gHCgH0gImgOEgMggK8eSvovogA?style=linearGradient&steps=21&angle=90 -->
<defs>
<linearGradient id="gradient" x1="0.000" y1="0.500" x2="1.000" y2="0.500">
<stop offset="0.000" stop-color="#d7621d" /><stop offset="0.050" stop-color="#dc6d27" /><stop offset="0.100" stop-color="#df7732" /><stop offset="0.150" stop-color="#e2803d" /><stop offset="0.200" stop-color="#e38848" /><stop offset="0.250" stop-color="#e38e52" /><stop offset="0.300" stop-color="#e1935b" /><stop offset="0.350" stop-color="#df9662" /><stop offset="0.400" stop-color="#db9668" /><stop offset="0.450" stop-color="#d6966d" /><stop offset="0.500" stop-color="#d0936f" /><stop offset="0.550" stop-color="#c98e70" /><stop offset="0.600" stop-color="#c2886f" /><stop offset="0.650" stop-color="#ba806c" /><stop offset="0.700" stop-color="#b17767" /><stop offset="0.750" stop-color="#a86d61" /><stop offset="0.800" stop-color="#9f6259" /><stop offset="0.850" stop-color="#965650" /><stop offset="0.900" stop-color="#8e4a46" /><stop offset="0.950" stop-color="#853e3b" /><stop offset="1.000" stop-color="#7e3230" />
</linearGradient>
</defs>
<rect x="0" y="0" width="800" height="400" fill="url(#gradient)" />
</svg>
["#d7621d", "#dc6d27", "#df7732", "#e2803d", "#e38848", "#e38e52", "#e1935b", "#df9662", "#db9668", "#d6966d", "#d0936f", "#c98e70", "#c2886f", "#ba806c", "#b17767", "#a86d61", "#9f6259", "#965650", "#8e4a46", "#853e3b", "#7e3230"]
// https://grabient.com/_gLugGQgEsgD6gEsgD6gHCgH0gImgOEgMggK8eSvovogA?style=linearGradient&steps=21&angle=90
// cosine gradient palette — https://iquilezles.org/articles/palettes/
const float STEPS = 21.0;
const float ANGLE = 90.0;
vec3 palette(float t) {
vec3 a = vec3(0.640, 0.290, 0.190);
vec3 b = vec3(0.250, 0.300, 0.250);
vec3 c = vec3(0.450, 0.500, 0.550);
vec3 d = vec3(0.900, 0.800, 0.700);
return a + b * cos(6.283185 * (c * t + d));
}
// N stops sampled from the palette, blended like the CSS gradient
vec3 stops(float t) {
float n = STEPS - 1.0;
float x = clamp(t, 0.0, 1.0) * n;
return mix(palette(floor(x) / n), palette(min(floor(x) + 1.0, n) / n), fract(x));
}
void mainImage(out vec4 fragColor, in vec2 fragCoord) {
vec2 p = fragCoord - 0.5 * iResolution.xy;
// CSS angle: 0 = up, clockwise; span = CSS gradient-line length
vec2 dir = vec2(sin(radians(ANGLE)), cos(radians(ANGLE)));
float len = abs(iResolution.x * dir.x) + abs(iResolution.y * dir.y);
float t = dot(p, dir) / len + 0.5;
fragColor = vec4(stops(t), 1.0);
}
[
[0.640, 0.290, 0.190],
[0.250, 0.300, 0.250],
[0.450, 0.500, 0.550],
[0.900, 0.800, 0.700]
]