body.frontpage-landing,
body.path-local-spacechildpages,
body.path-login {
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: Inter, system-ui, sans-serif;
}

.frontpage-landing #page-wrapper,
.frontpage-landing #page,
.frontpage-landing #page-content,
.frontpage-landing #region-main-box,
.frontpage-landing #region-main,
body.path-local-spacechildpages #page,
body.path-local-spacechildpages .embedded-main {
  margin: 0;
  padding: 0;
}

/* Allow sticky positioning to work across all Moodle wrapper elements */
.frontpage-landing #page-wrapper,
.frontpage-landing #page,
.frontpage-landing #page-content,
.frontpage-landing #region-main-box,
.frontpage-landing #region-main {
  overflow: visible !important;
}

/*
 * Moodle force #page-wrapper height:100%/flex which traps sticky inside
 * a non-scrolling flex ancestor.  Force the landing header to fixed so
 * it always anchors to the viewport, then push <main> down by the same
 * height so no content is hidden underneath.
 */
body.frontpage-landing header {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 9999 !important;
}

body.frontpage-landing main {
  padding-top: 73px !important;
}

.frontpage-landing #page-wrapper,
.frontpage-landing #page,
body.path-local-spacechildpages #page,
body.path-local-spacechildpages .embedded-main {
  min-height: 100vh;
}

body.path-local-spacechildpages #page.has-fake-blocks .embedded-blocks {
  display: none;
}

body.path-local-spacechildpages #page,
body.path-local-spacechildpages .embedded-main,
body.path-local-spacechildpages .embedded-main > *,
.frontpage-landing #region-main > * {
  width: 100%;
}

body.path-local-spacechildpages .embedded-main {
  display: block;
}
