/* https://grabient.com/_gGDgGEgGCgEcgD6gENgJugHNgIeg6pgnYgAE?style=linearSwatches&steps=13&angle=15 */
background: linear-gradient(15deg, #6424a7 0.000%, #6424a7 7.692%, #7b27a4 calc(7.692% + 1px), #7b27a4 15.385%, #902f9b calc(15.385% + 1px), #902f9b 23.077%, #9f398e calc(23.077% + 1px), #9f398e 30.769%, #a9467e calc(30.769% + 1px), #a9467e 38.462%, #ab546b calc(38.462% + 1px), #ab546b 46.154%, #a56358 calc(46.154% + 1px), #a56358 53.846%, #997245 calc(53.846% + 1px), #997245 61.538%, #878135 calc(61.538% + 1px), #878135 69.231%, #708d28 calc(69.231% + 1px), #708d28 76.923%, #599720 calc(76.923% + 1px), #599720 84.615%, #439f1e calc(84.615% + 1px), #439f1e 92.308%, #2fa221 calc(92.308% + 1px) 100.000%);
<svg xmlns="http://www.w3.org/2000/svg" width="800" height="400" viewBox="0 0 800 400" preserveAspectRatio="none">
<!-- https://grabient.com/_gGDgGEgGCgEcgD6gENgJugHNgIeg6pgnYgAE?style=linearSwatches&steps=13&angle=15 -->
<defs>
<clipPath id="bounds">
<rect x="0" y="0" width="800" height="400" />
</clipPath>
</defs>
<g clip-path="url(#bounds)"><path d="M 755.180,602.350 L -108.770,370.855 L -96.955,326.762 L 766.995,558.257 Z" fill="#6424a7" fill-opacity="1.000" /><path d="M 766.995,558.257 L -96.955,326.762 L -85.141,282.670 L 778.809,514.165 Z" fill="#7b27a4" fill-opacity="1.000" /><path d="M 778.809,514.165 L -85.141,282.670 L -73.326,238.577 L 790.624,470.072 Z" fill="#902f9b" fill-opacity="1.000" /><path d="M 790.624,470.072 L -73.326,238.577 L -61.512,194.484 L 802.439,425.979 Z" fill="#9f398e" fill-opacity="1.000" /><path d="M 802.439,425.979 L -61.512,194.484 L -49.697,150.392 L 814.253,381.886 Z" fill="#a9467e" fill-opacity="1.000" /><path d="M 814.253,381.886 L -49.697,150.392 L -37.882,106.299 L 826.068,337.794 Z" fill="#ab546b" fill-opacity="1.000" /><path d="M 826.068,337.794 L -37.882,106.299 L -26.068,62.206 L 837.882,293.701 Z" fill="#a56358" fill-opacity="1.000" /><path d="M 837.882,293.701 L -26.068,62.206 L -14.253,18.114 L 849.697,249.608 Z" fill="#997245" fill-opacity="1.000" /><path d="M 849.697,249.608 L -14.253,18.114 L -2.439,-25.979 L 861.512,205.516 Z" fill="#878135" fill-opacity="1.000" /><path d="M 861.512,205.516 L -2.439,-25.979 L 9.376,-70.072 L 873.326,161.423 Z" fill="#708d28" fill-opacity="1.000" /><path d="M 873.326,161.423 L 9.376,-70.072 L 21.191,-114.165 L 885.141,117.330 Z" fill="#599720" fill-opacity="1.000" /><path d="M 885.141,117.330 L 21.191,-114.165 L 33.005,-158.257 L 896.955,73.238 Z" fill="#439f1e" fill-opacity="1.000" /><path d="M 896.955,73.238 L 33.005,-158.257 L 44.820,-202.350 L 908.770,29.145 Z" fill="#2fa221" fill-opacity="1.000" /></g>
</svg>
["#6424a7", "#7b27a4", "#902f9b", "#9f398e", "#a9467e", "#ab546b", "#a56358", "#997245", "#878135", "#708d28", "#599720", "#439f1e", "#2fa221"]
// https://grabient.com/_gGDgGEgGCgEcgD6gENgJugHNgIeg6pgnYgAE?style=linearSwatches&steps=13&angle=15
// cosine gradient palette — https://iquilezles.org/articles/palettes/
const float STEPS = 13.0;
const float ANGLE = 15.0;
vec3 palette(float t) {
vec3 a = vec3(0.387, 0.388, 0.386);
vec3 b = vec3(0.284, 0.250, 0.269);
vec3 c = vec3(0.622, 0.461, 0.542);
vec3 d = vec3(3.753, 2.520, 0.004);
return a + b * cos(6.283185 * (c * t + d));
}
// N hard swatches sampled from the palette
vec3 stops(float t) {
float i = min(floor(clamp(t, 0.0, 1.0) * STEPS), STEPS - 1.0);
return palette(i / (STEPS - 1.0));
}
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.387, 0.388, 0.386],
[0.284, 0.250, 0.269],
[0.622, 0.461, 0.542],
[3.753, 2.520, 0.004]
]