How to get differently-sized header or footer depending on page number?

I don’t understand how this does not answer the question:

The code does allow you to have a much larger footer/header (margins) on odd pages than on even pages. Well, actually, I messed up a little, I set smaller margins for odd pages, but the fix is to just swap the values:

context page(margin: if is-odd-page() { 1.5cm } else { 1cm })[

Maybe you mean how to do the same thing but without calling context page()[] or context [#set page();] at the start of every new page? Meaning, you are only allowed to call set page() once at the very top of a document. Then I don’t think it is possible.

If I now understand correctly, then sure. There is a similar topic, where I wrote a post comparing page.fill and page.background.