-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle.css
More file actions
313 lines (291 loc) · 8.58 KB
/
Copy pathstyle.css
File metadata and controls
313 lines (291 loc) · 8.58 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
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
:root {
--ink: #1b1b1f;
--muted: #6b6b76;
--accent: #1f6feb;
--line: #e6e6ea;
--bg: #fbfbfd;
--panel: #fff;
--code: #f0f0f4;
--maxw: 62rem;
--readw: 42rem;
}
html[data-theme="dark"] {
--ink: #e9e9ec;
--muted: #9b9ba6;
--accent: #6aa8ff;
--line: #2b2b33;
--bg: #17171b;
--panel: #1e1e24;
--code: #26262e;
}
* { box-sizing: border-box; }
/* Theme switch: circular reveal of the new theme from the toggle button.
Falls back to an instant swap where the View Transitions API is absent. */
::view-transition-old(root),
::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-old(root) { z-index: 0; }
::view-transition-new(root) {
z-index: 1;
animation: theme-reveal .45s ease-in;
}
@keyframes theme-reveal {
from { clip-path: circle(0 at var(--vt-x, 50%) var(--vt-y, 0)); }
to { clip-path: circle(var(--vt-r, 150%) at var(--vt-x, 50%) var(--vt-y, 0)); }
}
@media (prefers-reduced-motion: reduce) {
::view-transition-new(root) { animation: none; }
}
html { -webkit-text-size-adjust: 100%; }
body {
margin: 0;
font: 18px/1.7 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
color: var(--ink);
background: var(--bg);
transition: background-color .2s ease, color .2s ease;
}
header.site, footer.site {
max-width: var(--maxw);
margin: 0 auto;
padding: 1.5rem 1.25rem;
}
header.site {
border-bottom: 1px solid var(--line);
display: flex;
align-items: center;
justify-content: space-between;
}
.header-actions { display: flex; align-items: center; gap: .5rem; }
.theme-toggle, .rss-link, .search-toggle {
display: inline-flex;
align-items: center;
justify-content: center;
background: none;
border: 1px solid var(--line);
border-radius: 8px;
padding: .4rem .5rem;
line-height: 0;
cursor: pointer;
color: var(--ink);
}
.theme-toggle:hover, .rss-link:hover, .search-toggle:hover { color: var(--accent); border-color: var(--accent); }
/* The search border lives on the container: clicking the magnifier grows the
pill leftward around the borderless inline input while the icon stays put. */
.site-search {
position: relative;
display: inline-flex;
align-items: center;
border: 1px solid var(--line);
border-radius: 8px;
}
.site-search:hover, .site-search:focus-within { border-color: var(--accent); }
.site-search .search-toggle { border: none; }
.site-search .search-toggle:hover { border: none; }
.search-input {
width: 0;
padding: .4rem 0;
opacity: 0;
font: inherit;
font-size: .9rem;
line-height: 18px; /* match the 18px icons so the pill equals the buttons */
color: var(--ink);
background: none;
border: none;
transition: width .25s ease, padding .25s ease, opacity .2s ease;
}
.search-input:focus { outline: none; }
.site-search.open .search-input {
width: 14rem;
max-width: 45vw;
padding: .4rem 0 .4rem .6rem;
opacity: 1;
}
.search-results {
position: absolute;
top: calc(100% + .5rem);
right: 0;
z-index: 20;
width: 22rem;
max-width: 90vw;
max-height: 60vh;
overflow-y: auto;
background: var(--bg);
border: 1px solid var(--line);
border-radius: 8px;
box-shadow: 0 8px 24px rgba(0, 0, 0, .15);
}
.search-results a {
display: block;
padding: .6rem .8rem;
text-decoration: none;
color: var(--ink);
border-bottom: 1px solid var(--line);
}
.search-results a:last-child { border-bottom: none; }
.search-results a:hover { background: var(--line); }
.search-results strong { display: block; font-size: .95rem; }
.search-results time { color: var(--muted); font-size: .75rem; }
.search-results .snippet { display: block; color: var(--muted); font-size: .8rem; line-height: 1.4; }
.search-results mark { background: var(--accent); color: var(--bg); border-radius: 2px; padding: 0 .1em; }
.search-empty { margin: 0; padding: .6rem .8rem; color: var(--muted); font-size: .85rem; }
.theme-toggle .icon-sun { display: none; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
html[data-theme="dark"] .theme-toggle .icon-sun { display: inline; }
.menu-toggle {
display: none;
background: none;
border: 1px solid var(--line);
border-radius: 8px;
font-size: 1.25rem;
line-height: 1;
padding: .35rem .55rem;
cursor: pointer;
color: var(--ink);
}
footer.site {
border-top: 1px solid var(--line);
color: var(--muted);
font-size: .9rem;
margin-top: 4rem;
}
.brand {
font-weight: 700;
font-size: 1.25rem;
letter-spacing: -.01em;
color: var(--ink);
text-decoration: none;
display: inline-flex;
align-items: center;
gap: .4rem;
}
.brand-shark { width: 20px; height: 20px; display: block; }
.layout {
max-width: var(--maxw);
margin: 0 auto;
padding: 2rem 1.25rem;
display: grid;
grid-template-columns: minmax(0, 1fr) 14rem;
gap: 3rem;
align-items: start;
}
main { min-width: 0; max-width: var(--readw); }
.sidebar { font-size: .95rem; }
.sidebar h2 {
font-size: .8rem;
text-transform: uppercase;
letter-spacing: .05em;
color: var(--muted);
margin: 0 0 .6rem;
}
.sidebar ul { list-style: none; margin: 0 0 2rem; padding: 0; }
.sidebar .side-latest li { margin-bottom: .8rem; line-height: 1.35; }
.sidebar .side-latest time { display: block; color: var(--muted); font-size: .78rem; }
.sidebar .side-archive li { margin-bottom: .3rem; }
.sidebar .side-archive .count { color: var(--muted); font-size: .85em; }
.sidebar h2 a { color: inherit; text-decoration: none; }
.sidebar h2 a:hover { color: var(--accent); }
.side-cloud { line-height: 1.9; margin: 0 0 2rem; }
.side-cloud a { color: var(--ink); margin-right: .4rem; white-space: nowrap; }
.side-cloud a.on { color: var(--accent); }
.side-cloud a.off { color: var(--muted); }
.side-cloud a:hover { color: var(--accent); text-decoration: none; }
@media (max-width: 46rem) {
.layout { grid-template-columns: 1fr; gap: 2rem; }
main { max-width: none; }
.menu-toggle { display: block; }
.sidebar {
position: fixed;
top: 4rem;
right: 1rem;
width: 16rem;
max-width: calc(100vw - 2rem);
max-height: calc(100vh - 5rem);
overflow-y: auto;
margin: 0;
padding: 1rem 1.25rem .25rem;
background: var(--panel);
border: 1px solid var(--line);
border-radius: 10px;
box-shadow: 0 10px 30px rgba(0, 0, 0, .12);
display: none;
z-index: 20;
}
.sidebar.open { display: block; }
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.intro p {
font-size: 1.15rem;
color: var(--muted);
margin: 0 0 2.5rem;
}
.entries { list-style: none; margin: 0; padding: 0; }
.entry { padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.entry-title {
font-size: 1.4rem;
font-weight: 650;
letter-spacing: -.01em;
color: var(--ink);
}
.entry time { display: block; color: var(--muted); font-size: .85rem; margin: .25rem 0 .5rem; }
.entry .hook { margin: 0; color: var(--muted); }
.entry .read-more { display: block; text-align: right; margin-top: .5rem; font-size: .9rem; font-weight: 600; }
.post h1 {
font-size: 2.1rem;
line-height: 1.2;
letter-spacing: -.02em;
margin: 0 0 .5rem;
}
.post-tags {
margin: 0 0 2rem;
font-size: .85rem;
}
.post-tags a { color: var(--muted); margin-right: .5rem; }
.post-tags a:hover { color: var(--accent); }
.tag-cloud { line-height: 2.1; }
.tag-cloud a {
margin-right: .7rem;
white-space: nowrap;
color: var(--ink);
font-weight: 600;
}
.tag-cloud a:hover { color: var(--accent); text-decoration: none; }
.post h2 { font-size: 1.4rem; margin: 2.5rem 0 .75rem; letter-spacing: -.01em; }
.post h3 { font-size: 1.15rem; margin: 2rem 0 .5rem; }
.post p { margin: 0 0 1.25rem; }
.post img { max-width: 100%; height: auto; border-radius: 8px; display: block; margin: 1.5rem auto; }
.post blockquote {
margin: 1.5rem 0;
padding: .25rem 0 .25rem 1.25rem;
border-left: 3px solid var(--line);
color: var(--muted);
}
.post pre {
background: #1b1b1f;
color: #f5f5f7;
padding: 1rem 1.25rem;
border-radius: 8px;
overflow-x: auto;
font-size: .85rem;
line-height: 1.5;
}
.post code {
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-size: .9em;
background: var(--code);
padding: .1em .35em;
border-radius: 4px;
}
.post pre code { background: none; padding: 0; }
.post table { border-collapse: collapse; width: 100%; margin: 1.5rem 0; font-size: .95rem; }
.post th, .post td { border: 1px solid var(--line); padding: .5rem .75rem; text-align: left; }
.post-nav {
display: flex;
justify-content: space-between;
gap: 1.5rem;
margin-top: 3.5rem;
padding-top: 1.5rem;
border-top: 1px solid var(--line);
font-size: .9rem;
}
.post-nav a { max-width: 47%; color: var(--accent); }
.post-nav .next { margin-left: auto; text-align: right; }