Oops, I use folding, but I removed these icons to have less clutter, I use only hotkeys for that. Unfortunately you’re right, when icons are displayed, they stay on top. If you always have H1 as the first line of the page (so you’re not using e.g. front matter) it’s possible to move that icon, you can modify px value in the code below to your needs. Otherwise I don’t think it’s possible to select this element with pure CSS, because it’s rendered as sibling to headers (and other foldable elements) and in codemirror’s html it’s not described in any way which element it affects.
.CodeMirror-code>:first-child .CodeMirror-guttermarker-subtle {
padding-top: 20px;
}
Or if you’d like to test how it works for you without these icons:
.CodeMirror-guttermarker-subtle {
display: none;
}