-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Expand file tree
/
Copy pathhead-custom.html
More file actions
215 lines (184 loc) · 4.39 KB
/
head-custom.html
File metadata and controls
215 lines (184 loc) · 4.39 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
<!-- Custom CSS -->
<link rel="stylesheet" href="{{ '/assets/css/custom.css' | relative_url }}">
<style>
/* Table of Contents Styles */
.toc {
background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
border: 1px solid #dee2e6;
border-radius: 0.5rem;
padding: 1.5rem;
margin: 2rem 0;
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.toc h3 {
margin-top: 0;
color: #495057;
font-size: 1.2rem;
border-bottom: 2px solid #157878;
padding-bottom: 0.5rem;
}
.toc ul {
list-style: none;
padding-left: 0;
}
.toc li {
margin: 0.5rem 0;
}
.toc a {
color: #157878;
text-decoration: none;
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
transition: all 0.2s ease;
display: block;
}
.toc a:hover {
background-color: #157878;
color: white;
}
.toc-level-2 {
padding-left: 1rem;
}
.toc-level-3 {
padding-left: 2rem;
}
/* Enhanced Main Content */
.main-content {
line-height: 1.8;
}
.main-content h1,
.main-content h2,
.main-content h3,
.main-content h4 {
color: #2c3e50;
margin-top: 2rem;
margin-bottom: 1rem;
}
.main-content h2 {
border-bottom: 2px solid #157878;
padding-bottom: 0.5rem;
}
.main-content h3 {
border-left: 4px solid #157878;
padding-left: 1rem;
}
/* Code block enhancements */
.main-content pre {
background: #2d3748;
border-radius: 0.5rem;
padding: 1.5rem;
overflow-x: auto;
}
.main-content code {
background: #f1f3f4;
color: #d73a49;
padding: 0.2rem 0.4rem;
border-radius: 0.25rem;
font-size: 0.9em;
}
.main-content pre code {
background: none;
color: #e2e8f0;
padding: 0;
}
/* Link styles */
.main-content a {
color: #157878;
text-decoration: none;
border-bottom: 1px solid transparent;
transition: all 0.2s ease;
}
.main-content a:hover {
border-bottom-color: #157878;
}
/* List enhancements */
.main-content ul li,
.main-content ol li {
margin: 0.5rem 0;
}
/* Footer enhancements */
.site-footer {
border-top: 2px solid #157878;
margin-top: 3rem;
padding-top: 2rem;
}
.footer-stats {
text-align: center;
margin-top: 1rem;
padding: 1rem;
background: #f8f9fa;
border-radius: 0.5rem;
}
.footer-stats p {
margin: 0;
color: #6c757d;
}
/* Responsive improvements */
@media screen and (max-width: 768px) {
.language-toggle {
text-align: center;
}
.btn-lang {
display: block;
margin: 0.5rem auto;
max-width: 200px;
}
.toc {
margin: 1rem 0;
padding: 1rem;
}
}
/* Scroll to top button */
.scroll-to-top {
position: fixed;
bottom: 2rem;
right: 2rem;
background: #157878;
color: white;
border: none;
border-radius: 50%;
width: 3rem;
height: 3rem;
cursor: pointer;
opacity: 0;
transition: opacity 0.3s ease;
z-index: 1000;
}
.scroll-to-top.show {
opacity: 1;
}
</style>
<!-- Add scroll to top functionality -->
<script>
document.addEventListener('DOMContentLoaded', function() {
// Create scroll to top button
const scrollBtn = document.createElement('button');
scrollBtn.innerHTML = '↑';
scrollBtn.className = 'scroll-to-top';
scrollBtn.title = 'Scroll to top';
document.body.appendChild(scrollBtn);
// Show/hide scroll button
window.addEventListener('scroll', function() {
if (window.pageYOffset > 300) {
scrollBtn.classList.add('show');
} else {
scrollBtn.classList.remove('show');
}
});
// Scroll to top functionality
scrollBtn.addEventListener('click', function() {
window.scrollTo({
top: 0,
behavior: 'smooth'
});
});
});
</script>
<!-- Favicon -->
<link rel="icon" type="image/x-icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>🐍</text></svg>">
<!-- Additional Meta Tags -->
<meta name="keywords" content="Python, tutorials, learning, programming, resources, books, courses, guides, development">
<meta name="robots" content="index, follow">
<meta property="og:type" content="website">
<meta property="og:image" content="{{ '/assets/images/og-image.svg' | absolute_url }}">
<meta name="twitter:card" content="summary_large_image">