File size: 7,970 Bytes
6afedde
dd194bf
 
 
 
 
6afedde
 
 
 
dd194bf
6afedde
dd194bf
6afedde
 
dd194bf
 
 
 
 
 
 
6afedde
 
 
 
dd194bf
 
 
6afedde
 
dd194bf
 
 
 
6afedde
dd194bf
 
 
 
6afedde
dd194bf
 
6afedde
 
dd194bf
 
 
 
 
 
6afedde
dd194bf
 
 
6afedde
 
dd194bf
 
6afedde
 
 
 
 
 
 
 
dd194bf
 
 
 
 
 
 
 
 
 
 
 
 
 
6afedde
 
dd194bf
 
 
 
 
6afedde
 
dd194bf
 
 
6afedde
 
 
 
 
 
 
dd194bf
 
 
 
6afedde
dd194bf
 
6afedde
 
 
 
 
 
 
 
 
 
fd6b678
6afedde
 
fd6b678
 
 
 
 
dd194bf
fd6b678
 
 
 
 
 
 
 
dd194bf
fd6b678
 
 
 
 
 
dd194bf
 
 
 
fd6b678
6afedde
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4ac9663
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9d91de3
 
 
e4a2025
 
dd194bf
9d91de3
 
e4a2025
 
 
 
 
 
 
 
dd194bf
e4a2025
 
 
 
dd194bf
e4a2025
 
 
 
 
 
 
 
 
 
 
54b202e
e4a2025
 
 
 
 
dd194bf
 
9d91de3
 
 
92e99d3
e4a2025
 
92e99d3
e4a2025
 
92e99d3
 
 
 
 
 
dd194bf
e4a2025
 
 
 
 
 
 
 
 
 
dd194bf
 
 
 
9d91de3
 
e4a2025
9d91de3
 
 
e4a2025
 
 
9d91de3
 
 
dd194bf
9d91de3
dd194bf
 
 
9d91de3
 
 
 
 
 
e4a2025
9d91de3
dd194bf
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
/* ============================================================================ */
/* Page grid (tokens in _grid.css)                                              */
/* ---------------------------------------------------------------------------- */
/* .content-grid holds the TOC rail and <main> on the same row; <main> spans    */
/* the screen and repeats the same named lines, so every block picks a column:  */
/* body by default, .wide and .full-width break out, sidenotes go to margin.    */
/* ============================================================================ */

.content-grid {
  display: grid;
  grid-template-columns: var(--layout-cols);
  align-items: start;
  margin-top: var(--layout-content-top);
}

.content-grid > main {
  grid-column: screen;
  grid-row: 1;
  display: grid;
  grid-template-columns: var(--layout-cols);
  align-content: start;
  min-width: 0;
  margin: 0;
  padding: 0;
}

.content-grid > main > * {
  grid-column: body;
  min-width: 0;
}

/* The first body line, the first TOC line and the first sidenote share a top edge */
.content-grid > main > :first-child {
  margin-top: 0;
}

/* Prose measure */
.content-grid > main > :is(p, ul, ol, h2, h3, h4, blockquote) {
  max-width: var(--layout-prose);
}

.content-grid > main :is(p, li) {
  font-size: var(--layout-prose-font-size);
}

/* Long references, URLs and DOIs wrap inside their column; inline citations never break */
.sidenote,
.footer li,
.meta-col {
  overflow-wrap: anywhere;
}

.content-grid main a[href^="#bib-"] {
  white-space: nowrap;
}

/* ============================================================================ */
/* Width helpers                                                                */
/* ============================================================================ */

.wide,
.full-width {
  box-sizing: border-box;
  position: relative;
  z-index: var(--z-elevated);
}

.content-grid > main > .wide,
.content-grid > main > .html-embed--wide {
  grid-column: body-start / margin-end;
}

/* <HtmlEmbed wide> follows the grid instead of its own centered 1100px box */
.content-grid > main > .html-embed--wide {
  width: auto;
  margin-left: 0;
  padding: 0;
  transform: none;
  border-radius: 0;
  -webkit-mask: none;
  mask: none;
}

.content-grid > main > .full-width {
  grid-column: screen;
  padding: var(--spacing-5);
  background: color-mix(in srgb, var(--primary-color) 5%, var(--surface-bg));
  border-block: 1px solid var(--border-color);
}

.full-width > * {
  max-width: 1800px;
  margin-inline: auto;
}

.full-width figure figcaption {
  text-align: center !important;
}

@media (--bp-content-collapse) {
  .content-grid > main > :is(.wide, .html-embed--wide) {
    grid-column: screen;
    padding-inline: var(--layout-outer);
  }

  .content-grid > main > .full-width {
    padding: var(--spacing-4) var(--layout-outer);
  }
}

/* ============================================================================ */
/* Theme toggle placement                                                       */
/* ============================================================================ */

#theme-toggle {
  position: absolute;
  top: var(--spacing-4);
  left: var(--spacing-4);
  margin: 0;
  z-index: var(--z-overlay);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: var(--page-bg);
  box-shadow: 0 2px 12px rgba(0, 0, 0, .08);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  color: var(--text-color);
  transition: transform 150ms ease, box-shadow 150ms ease;
}

#theme-toggle:active {
  transform: scale(0.92);
}

@media (--bp-content-collapse) {
  #theme-toggle {
    top: var(--spacing-2);
    left: var(--spacing-2);
    width: 36px;
    height: 36px;
  }
}

/* ------------------------------------------------------------------------- */
/* D3 neural embed responsiveness                                            */
/* Stack canvas (left) over network (right) on small screens                 */
/* ------------------------------------------------------------------------- */
@media (--bp-md) {
  .d3-neural .panel {
    flex-direction: column;
  }

  .d3-neural .panel .left {
    flex: 0 0 auto;
    width: 100%;
  }

  .d3-neural .panel .right {
    flex: 0 0 auto;
    width: 100%;
    min-width: 0;
  }
}

/* ============================================================================ */
/* Auto figure numbering                                                        */
/* Applies a CSS counter across all figure-bearing components:                  */
/* Reference (.reference-wrapper), Image (.image-wrapper figure),               */
/* and HtmlEmbed (.html-embed)                                                  */
/* ============================================================================ */

.content-grid > main {
  counter-reset: figure;
}

/* Increment on every figure-like component */
.content-grid > main .reference-wrapper,
.content-grid > main .image-wrapper > figure,
.content-grid > main figure.html-embed {
  counter-increment: figure;
}

/* Display "Figure N · " before each figcaption */
.content-grid > main .reference-wrapper .reference__caption::before,
.content-grid > main .image-wrapper > figure > figcaption::before,
.content-grid > main figure.html-embed > .html-embed__desc::before {
  content: "Figure " counter(figure) " · ";
  font-weight: 600;
}

/* ============================================================================ */
/* "paper" template - academic project-page layout (single centered column)     */
/* Activated by frontmatter `template: "paper"` -> data-template="paper"        */
/* The single column itself comes from the paper tokens in _grid.css.           */
/* ============================================================================ */

/* ---- Paper hero banner: placed between meta and content in index.astro ---- */

.paper-hero-banner {
  max-width: 920px;
  margin: 32px auto 0;
  padding: 0 16px;
}

.paper-hero-banner .html-embed {
  border-radius: 8px;
  overflow: hidden;
}

.paper-hero-banner .html-embed__card {
  border-radius: 8px;
}

/* Thin separator between banner area and content */
[data-template="paper"] .paper-hero-banner + .content-grid {
  margin-top: 48px;
  border-top: 1px solid var(--border-color);
  padding-top: 40px;
}

/* When no banner, separator is directly below meta */
[data-template="paper"] .hero-paper-meta + .content-grid {
  margin-top: 32px;
  border-top: 1px solid var(--border-color);
  padding-top: 40px;
}

[data-template="paper"] .table-of-contents,
[data-template="paper"] .toc-topbar {
  display: none;
}

/* ---- Typography: clean left-aligned headings ---- */

[data-template="paper"] .content-grid > main h2 {
  text-align: left;
  font-size: 1.75em;
  font-weight: 700;
  margin-top: 2.5em;
  margin-bottom: 0.8em;
  border-bottom: none;
  padding-bottom: 0;
}

[data-template="paper"] .content-grid > main > h2:first-child {
  margin-top: 0;
}

[data-template="paper"] .content-grid > main h3 {
  font-size: 1.3em;
  font-weight: 600;
  margin-top: 2em;
  margin-bottom: 0.6em;
}

[data-template="paper"] .content-grid > main :is(p, li) {
  font-size: inherit;
}

/* ---- No figure numbering ---- */

[data-template="paper"] .content-grid > main {
  counter-reset: none;
}

[data-template="paper"] .content-grid > main .reference-wrapper .reference__caption::before,
[data-template="paper"] .content-grid > main .image-wrapper > figure > figcaption::before,
[data-template="paper"] .content-grid > main figure.html-embed > .html-embed__desc::before {
  content: none;
}

/* ---- Footer: headings above their content ---- */

[data-template="paper"] .footer-inner > * > .footer-heading {
  grid-column: body;
  justify-self: start;
  text-align: left;
  padding-right: 0;
  margin-top: 16px;
  margin-bottom: 8px;
}

[data-template="paper"] .template-credit p {
  margin-top: 32px;
}