The worldborder always renders behind clouds, even if those clouds are behind the world border.
World border renders behind clouds and the sun
Clouds render in front of world border
Wrong rendering order of particles, hitboxes, clouds, transparent blocks, breaking animations and various other transparent textures
World border is rendered behind transparent blocks
Clouds are rendered in front of chunk borders