Skip to content

Commit acab6ec

Browse files
DavidLiedleclaude
andcommitted
Fix navigation scroll - make entire header scrollable
Changed approach: make the entire header fixed and scrollable instead of just the nav section. This provides better UX and avoids layout conflicts. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent f1c2fd8 commit acab6ec

File tree

1 file changed

+21
-7
lines changed

1 file changed

+21
-7
lines changed

assets/css/custom.css

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,12 @@ footer {
1616
padding-top: 20px;
1717
border-top: 1px solid #e5e5e5;
1818
margin-bottom: 20px;
19-
max-height: 600px;
20-
overflow-y: auto;
2119
}
2220

2321
.book-nav h2 {
2422
font-size: 18px;
2523
margin-bottom: 10px;
2624
color: #333;
27-
position: sticky;
28-
top: 0;
29-
background: white;
30-
padding: 5px 0;
31-
z-index: 10;
3225
}
3326

3427
.book-nav ul {
@@ -101,6 +94,27 @@ blockquote {
10194
margin: 0 0 16px 0;
10295
}
10396

97+
/* Desktop: Make header fixed with scrollable nav */
98+
@media screen and (min-width: 961px) {
99+
header {
100+
position: fixed;
101+
width: 270px;
102+
overflow-y: auto;
103+
height: 100vh;
104+
padding-bottom: 50px;
105+
}
106+
107+
section {
108+
margin-left: 300px;
109+
}
110+
111+
footer {
112+
position: fixed;
113+
bottom: 0;
114+
width: 270px;
115+
}
116+
}
117+
104118
/* Mobile responsiveness */
105119
@media screen and (max-width: 960px) {
106120
.book-nav {

0 commit comments

Comments
 (0)