Password for parts of published/self hosted website based on obsidian?

As a lot of people I have a “second” brain in obsidian, so I store a lot of things in there.
I use one vault for everything because I have links from everywhere (from personal to work and so on)
I want to share some of the notes with my students and coworkers
Current publish option doesn’t suggest to have passwords page-based, you can only password the entire website

Is there any way to make page-based passwords (enetering passoword for specifc page, not an authorisation tool)?
If not what would be the easiest way to maintain md → pdf routine (GH Pages doesn’t work well with Latex, which is exremely important)

Adding here the related FR in case someone stumbles onto this: < Password protection for individual notes in Obsidian Publish would be great>