14 / 16

CSS ScopingURL copied

get_custom_css_links() discovers and loads custom CSS:

  1. Root CSS: Applies globally (/posts/custom.css or /posts/style.css)
  2. Folder CSS: Automatically scoped to section via wrapper class (e.g., #main-content.section-demo-books-flat-land)
  3. Content wrapped in <Style> tag with scoped selector to prevent cross-section leakage
  4. All CSS changes swapped via #scoped-css-container for HTMX compatibility