fix(frontend): remove blank gap above nav on non-home pages

Complete the fixed-nav contract: when body.nav-fixed and the header
is not the hero overlay (show-slide), take .header out of flow so
body padding alone reserves space. Avoids double offset from sticky
nav still occupying document flow on single/archive pages.
This commit is contained in:
2026-07-14 23:51:31 +08:00
parent 2c38a0e9ea
commit 8d276844ef
+18
View File
@@ -3,6 +3,24 @@ body.nav-fixed {
padding-top: var(--nav-height, 60px);
}
/* Fixed nav without hero overlay: take header out of flow.
body.nav-fixed already reserves --nav-height via padding-top. */
body.nav-fixed .header:not(.show-slide) {
position: fixed;
top: 0;
left: 0;
right: 0;
width: 100%;
z-index: 1000;
}
/* Nav lives inside the fixed header — don't keep sticky (double offset). */
body.nav-fixed .header:not(.show-slide) .site-nav,
body.nav-fixed .header:not(.show-slide) .navbar.navbar-top {
position: relative;
top: auto;
}
/* Hero sits under transparent fixed/absolute header (zibll slide-header) */
body.nav-fixed .header-slider-container,
body.nav-fixed .header-components-container,