void mainImage( out vec4 fragColor, in vec2 fragCoord )
{
// Convert the fragment coordinate to a position in the scene
vec2 uv = (2.0 * fragCoord.xy - iResolution.xy) / iResolution.y * 0.02;

// Apply a scaling factor to the position to squash it
float dp = dot(uv, uv);
uv /= dp;

// Apply a sine function to the x coordinate to give it some curvature
uv.x = sin(uv.x - 1021.5);

// Scale the position down and get the angle in radians
uv *= 0.35;
float a = atan(uv.y, uv.x);

// Calculate the time and use it to animate the scene
float t = iTime * 0.01;
float r2 = max(5.0, abs(sin(t * 0.5)) * 0.05 - length(uv));
t += r2 * r2 * cos(r2 + t) + a * 1.0;

// Rotate the position based on the time and calculate the final color
uv *= mat2(cos(t), sin(t), cos(t), cos(t));
vec3 col = 0.1 + cos(uv.y * (cos(t) * 1.5 + 1.05) + t) * sin(iTime + uv.yxy);

// Output the final color
fragColor = vec4(col, 1.0);
}