 divider should be horizontal (spanning across)
        divider.className = 'horizontal-divider';
        divider.style.top = `calc(${splitRatio * 100}%)`;
        divider.style.left = '0';
      } else {
        // For left/right layout, divider should be vertical (spanning down)
        divider.className = 'vertical-divider';
        divider.style.left = `calc(${splitRatio * 100}%)`;
        divider.style.top = '0';
      }
    }

    // Add event listeners for dragging
    divider.addEventListener('mouse