5;
            yOffset = 0;
            zoom = 1;
            charIndex = 0;
            currentFrame = 0;
            frameTimes = [];
            avgFps = 0;
        }

        function animate() {
            const startTime = performance.now();
            drawMandelbrot();
            const endTime = performance.now();
            const frameTime = endTime - startTime;

            frameTimes.push(frameTime);
            if (frameTimes.length > 20) {
                frameTimes.shift();
            }

 