fix(nav): hide mobile drawer/search off-flow to kill blank band

Desktop was rendering .mobile-header / .mobile-navbar in document flow
because Bootstrap 5 has no visible-xs-block and drawer CSS only ran
inside max-width:767px. Hide drawer shell by default; only show as fixed
off-canvas on small screens. Also fix orphan CSS rules in navbar-core,
give .navbar-search position:fixed so the overlay never reserves height.
This commit is contained in:
kate522 committed 2026-07-22 19:40:34 +08:00
1 parent 584cb4e871
commit fb5418e5e4
2 files changed
+244 -203

No files matched your search

+11 -10
View File
@@ -50,10 +50,6 @@
transition: 0.3s;
}
margin-left: -100%;
}
.header {
padding: 8px 20px;
background: var(--header-bg);
@@ -252,14 +248,12 @@ body.nav-fixed .slide-header {
z-index: 999;
width: 100%;
top: 0;
left: 0;
right: 0;
-webkit-backdrop-filter: saturate(5) blur(20px);
backdrop-filter: saturate(5) blur(20px);
}
.mobile-navbar + .fixed-body {
z-index: 996;
}
.navbar-top {
margin: 0;
border-radius: 0 !important;
@@ -385,6 +379,11 @@ badge.top,
}
.navbar-search {
position: fixed;
left: 0;
right: 0;
top: 0;
width: 100%;
visibility: hidden;
transform: translateY(-101%);
padding: 10px 30px;
@@ -396,11 +395,13 @@ badge.top,
z-index: 998;
transition: all 0.5s;
border-radius:0 0 var(--main-radius) var(--main-radius);
pointer-events: none;
}
.navbar-search.show {
visibility: unset;
visibility: visible;
transform: translateY(0);
pointer-events: auto;
}
.navbar-top .navbar-right .sub-menu {
@@ -672,7 +673,7 @@ badge.top,
height: 36px;
}
@media (min-width: 768px) {
.container {
width: 95%;
}