      wordWrap: 'on'
      });

      // Auto-resize editor
      window.addEventListener('resize', () => {
        editor.layout();
      });
    });

    // Populate samples list
    function populateSamples() {
      const samplesList = document.getElementById('samplesList');
      samplesList.innerHTML = '';

      samples.forEach((sample, index) => {
        const li = document.createElement('li');
        li.className = `sample-item ${index === 0 ? 'active' : ''}`;
        li.innerHTML = `
           