.step { display: none; } .step.show { display: block; } /* Add styling for buttons, progress indicator, etc. */ var currentStep = 1; var totalSteps = 4; function showStep(stepNumber) { var steps = document.getElementsByClassName('step'); for (var i = 0; i < steps.length; i++) { steps[i].classList.remove('show'); } document.getElementById('step-' + stepNumber).classList.add('show'); } document.getElementById('next-step').addEventListener('click', function() { if (currentStep < totalSteps) { currentStep++; showStep(currentStep); } }); document.getElementById('prev-step').addEventListener('click', function() { if (currentStep > 1) { currentStep--; showStep(currentStep); } }); document.getElementById('preview-step').addEventListener('click', function() { // Perform any necessary