a tool for shared writing and social publishing
1@import "tailwindcss";
2
3@theme inline {
4 --breakpoint-*: initial;
5 --breakpoint-sm: 640px;
6 --breakpoint-md: 960px;
7 --breakpoint-lg: 1280px;
8
9 --radius-*: initial;
10 --radius-none: 0;
11 --radius-md: 0.25rem;
12 --radius-lg: 0.5rem;
13 --radius-full: 9999px;
14
15 --color-*: initial;
16 --color-inherit: inherit;
17 --color-transparent: transparent;
18 --color-current: currentColor;
19 --color-primary: rgb(var(--primary));
20 --color-secondary: color-mix(
21 in oklab,
22 rgb(var(--primary)),
23 rgb(var(--bg-page)) 25%
24 );
25 --color-tertiary: color-mix(
26 in oklab,
27 rgb(var(--primary)),
28 rgb(var(--bg-page)) 55%
29 );
30 --color-border: color-mix(
31 in oklab,
32 rgb(var(--primary)),
33 rgb(var(--bg-page)) 75%
34 );
35 --color-border-light: color-mix(
36 in oklab,
37 rgb(var(--primary)),
38 rgb(var(--bg-page)) 85%
39 );
40 --color-white: #ffffff;
41 --color-accent-1: rgb(var(--accent-1));
42 --color-accent-2: rgb(var(--accent-2));
43 --color-accent-contrast: rgb(var(--accent-contrast));
44 --color-bg-leaflet: rgb(var(--bg-leaflet));
45 --color-bg-page: rgb(var(--bg-page));
46 --color-highlight-1: var(--highlight-1);
47 --color-highlight-2: rgb(var(--highlight-2));
48 --color-highlight-3: rgb(var(--highlight-3));
49 --color-test: #e18181;
50 --color-test-blue: #48d1ef;
51
52 --text-*: initial;
53 --text-xs: 0.75rem;
54 --text-sm: 0.875rem;
55 --text-base: 1rem;
56 --text-lg: 1.125rem;
57 --text-xl: 1.625rem;
58 --text-2xl: 2rem;
59
60 --shadow-sm: 0.9px 1.5px 1.7px -1.8px rgba(var(--primary), 0.2),
61 4.2px 6.9px 7.8px -3.5px rgba(var(--primary), 0.15);
62 --shadow-md: 1.2px 2.5px 2.7px -1.8px rgba(var(--primary), 0.1),
63 5.6px 11.6px 12.5px -3.5px rgba(var(--primary), 0.15);
64
65 --font-sans: var(--font-quattro);
66 --font-serif: Garamond;
67}
68
69/*
70 The default border color has changed to `currentcolor` in Tailwind CSS v4,
71 so we've added these compatibility styles to make sure everything still
72 looks the same as it did with Tailwind CSS v3.
73
74 If we ever want to remove these styles, we need to add an explicit border
75 color utility to any element that depends on these defaults.
76*/
77@layer base {
78 *,
79 ::after,
80 ::before,
81 ::backdrop,
82 ::file-selector-button {
83 border-color: var(--color-gray-200, currentcolor);
84 }
85}
86
87@layer base {
88 :root {
89 --bg-leaflet: 240, 247, 250;
90 --bg-page: 255, 255, 255;
91 --bg-page-alpha: 1;
92
93 --primary: 39, 39, 39;
94
95 --accent-1: 0, 0, 225;
96 --accent-2: 255, 255, 255;
97 --accent-contrast: 0, 0, 225;
98 --accent-1-is-contrast: "true";
99 --accent-contrast-similar-to-text: 0;
100 --link-underline: none;
101 --accent-light: color-mix(
102 in oklab,
103 rgb(var(--accent-contrast)),
104 rgb(var(--bg-page)) 85%
105 );
106
107 --highlight-1: 255, 177, 177;
108 --highlight-2: 253, 245, 203;
109 --highlight-3: 255, 205, 195;
110
111 --list-marker-width: 36px;
112 --page-width-unitless: min(
113 var(--page-width-setting),
114 calc(var(--leaflet-width-unitless) - 12)
115 );
116 --page-width-units: min(
117 calc(var(--page-width-unitless) * 1px),
118 calc(100vw - 12px)
119 );
120
121 --gripperSVG: url("/gripperPattern.svg");
122 --gripperSVG2: url("/gripperPattern2.svg");
123 --hatchSVG: url("/hatchPattern.svg");
124 --wavySVG: (url("/RSVPBackground/wavy.svg"));
125
126 --safe-padding-bottom: max(calc(env(safe-area-inset-bottom) - 8px), 16px);
127 }
128 @media (max-width: 640px) {
129 :root {
130 --list-marker-width: 20px;
131 }
132 }
133
134 @media (min-width: 640px) {
135 :root {
136 /*picks between max width and screen width with 64px of padding*/
137 --page-width-unitless: min(
138 var(--page-width-setting),
139 calc(var(--leaflet-width-unitless) - 128)
140 );
141 --page-width-units: min(
142 calc(var(--page-width-unitless) * 1px),
143 calc(100vw - 128px)
144 );
145 }
146 }
147
148 html,
149 body {
150 @apply h-full;
151 @apply p-0;
152 @apply overscroll-y-none;
153 min-height: -webkit-fill-available;
154 @apply font-sans;
155 font-synthesis: none;
156 }
157
158 #__next {
159 height: 100%;
160 }
161
162 /* START FONT STYLING */
163 h1 {
164 @apply text-2xl;
165 @apply font-bold;
166 }
167
168 h2 {
169 @apply text-xl;
170 @apply font-bold;
171 }
172
173 h3 {
174 @apply text-lg;
175 @apply font-bold;
176 }
177
178 h4 {
179 @apply text-base;
180 @apply font-bold;
181 }
182
183 p {
184 @apply text-base;
185 }
186
187 small {
188 @apply text-sm;
189 }
190
191 a {
192 @apply text-accent-contrast;
193 @apply hover:cursor-pointer;
194 @apply hover:underline;
195 }
196
197 .postPageContent a {
198 text-decoration-line: var(--link-underline, none);
199 }
200
201 p {
202 font-size: inherit;
203 }
204
205 ::placeholder {
206 @apply text-tertiary;
207 @apply italic;
208 }
209
210 /* Scope custom fonts to document content only (not sidebar/UI chrome) */
211 .pageScrollWrapper,
212 .footnote-side-column,
213 .footnote-popover,
214 #interaction-drawer {
215 font-family: var(--theme-font, var(--font-quattro));
216 font-size: var(--theme-font-base-size, 16px);
217 }
218
219 .pageScrollWrapper h1,
220 .pageScrollWrapper h2,
221 .pageScrollWrapper h3,
222 .pageScrollWrapper h4 {
223 font-family: var(
224 --theme-heading-font,
225 var(--theme-font, var(--font-quattro))
226 );
227 }
228
229 /* Scale heading sizes relative to the custom base font size */
230 .pageScrollWrapper h1 {
231 font-size: 2em;
232 }
233 .pageScrollWrapper h2 {
234 font-size: 1.625em;
235 }
236 .pageScrollWrapper h3 {
237 font-size: 1.125em;
238 }
239 .pageScrollWrapper h4 {
240 font-size: 1em;
241 }
242
243 /* Scale text size classes relative to the custom base font size.
244 Tailwind's text-sm/text-base/text-lg compile to fixed rem values
245 which ignore the custom base size set on .pageScrollWrapper. */
246 .pageScrollWrapper .textSizeSmall {
247 font-size: 0.875em;
248 }
249 .pageScrollWrapper .textSizeLarge {
250 font-size: 1.125em;
251 }
252
253 .pageScrollWrapper pre {
254 font-family: var(--theme-font, var(--font-quattro));
255 }
256
257 /* Apply custom fonts to publication homepage */
258 .pubWrapper {
259 font-family: var(--theme-font, var(--font-quattro));
260 }
261
262 .pubWrapper h1,
263 .pubWrapper h2,
264 .pubWrapper h3,
265 .pubWrapper h4 {
266 font-family: var(
267 --theme-heading-font,
268 var(--theme-font, var(--font-quattro))
269 );
270 }
271 /*END FONT STYLING*/
272
273 /* START GLOBAL STYLING */
274
275 /* END GLOBAL STYLING */
276}
277
278img {
279 font-size: 0;
280}
281
282button:hover {
283 cursor: pointer;
284}
285
286blockquote {
287 margin: 0;
288}
289
290/* Hide scrollbar for Chrome, Safari and Opera */
291.no-scrollbar::-webkit-scrollbar {
292 display: none;
293}
294.no-scrollbar {
295 scrollbar-width: none;
296}
297
298input::-webkit-outer-spin-button,
299input::-webkit-inner-spin-button {
300 -webkit-appearance: none;
301 margin: 0;
302}
303input[type="number"] {
304 -moz-appearance: textfield;
305}
306
307::-webkit-calendar-picker-indicator {
308 mask-image: url(/timeInputIcon.svg);
309 mask-size: 100% 100%;
310 background-image: url(/gripperPattern1.svg);
311 background-color: color-mix(
312 in oklab,
313 rgb(var(--primary)),
314 rgb(var(--bg-page)) 55%
315 );
316}
317
318.inline-code {
319 display: inline;
320 font-size: 1em;
321 @apply bg-border-light;
322 @apply font-mono;
323 @apply px-px;
324 @apply py-px;
325 @apply -mx-px;
326 @apply -my-px;
327 @apply rounded-[4px];
328 @apply box-decoration-clone;
329}
330
331pre.shiki code {
332 display: block;
333}
334
335pre.shiki {
336 @apply sm:p-3;
337 @apply p-2;
338 @apply rounded-md;
339 @apply overflow-auto;
340 @apply sm:min-h-12;
341 @apply min-h-10;
342
343 @media (min-width: 640px) {
344 @apply p-3;
345 }
346}
347
348.highlight:has(+ .highlight) {
349 @apply rounded-r-none;
350}
351.highlight + .highlight {
352 @apply rounded-l-none;
353}
354
355.highlight {
356 @apply px-px;
357 @apply py-px;
358 @apply -mx-px;
359 @apply -my-px;
360 @apply rounded-[4px];
361 @apply box-decoration-clone;
362}
363
364.selection-highlight {
365 background-color: transparent;
366 @apply py-[1.5px];
367}
368
369.block-focused .selection-highlight {
370 background-color: Highlight;
371}
372
373.block-focused:focus-within .selection-highlight {
374 background-color: transparent;
375}
376
377.ProseMirror .atMention.ProseMirror-selectednode,
378.ProseMirror .didMention.ProseMirror-selectednode {
379 @apply text-accent-contrast;
380 @apply px-0.5;
381 @apply rounded-[4px];
382 @apply box-decoration-clone;
383 background-color: rgba(var(--accent-contrast), 0.2);
384 border: 1px solid rgba(var(--accent-contrast), 1);
385}
386
387.mention {
388 @apply cursor-pointer;
389 @apply text-accent-contrast;
390 @apply px-0.5;
391 @apply rounded-[4px];
392 @apply box-decoration-clone;
393 background-color: rgba(var(--accent-contrast), 0.2);
394 border: 1px solid transparent;
395 display: inline;
396 white-space: normal;
397}
398
399.multiselected .block-focused:focus-within .selection-highlight {
400 background-color: transparent;
401}
402
403.transparent-outline {
404 @apply outline-solid;
405 @apply outline-transparent;
406}
407
408.selected-outline {
409 @apply border;
410 @apply focus:outline-solid;
411 @apply focus:outline-2;
412 @apply focus:outline-offset-1;
413 @apply focus-within:outline-solid;
414 @apply focus-within:outline-2;
415 @apply focus-within:outline-offset-1;
416 @apply hover:outline-solid;
417 @apply hover:outline-2;
418 @apply hover:outline-offset-1;
419}
420
421.input-with-border {
422 @apply border;
423 @apply border-border;
424 @apply bg-bg-page;
425 @apply rounded-md;
426 @apply px-1;
427 @apply py-0.5;
428 @apply hover:border-tertiary;
429
430 @apply focus:border-tertiary;
431 @apply focus:outline-solid;
432 @apply focus:outline-tertiary;
433 @apply focus:outline-2;
434 @apply focus:outline-offset-1;
435
436 @apply focus-within:border-tertiary;
437 @apply focus-within:outline-solid;
438 @apply focus-within:outline-tertiary;
439 @apply focus-within:outline-2;
440 @apply focus-within:outline-offset-1;
441
442 @apply disabled:border-border-light;
443 @apply disabled:hover:border-border-light;
444 @apply disabled:bg-border-light;
445 @apply disabled:text-tertiary;
446}
447
448.block-border {
449 @apply border;
450 @apply border-border-light;
451 @apply rounded-lg;
452 @apply outline-solid;
453 @apply outline-offset-1;
454 @apply outline-2;
455 @apply outline-transparent;
456 @apply hover:border-border;
457}
458
459.block-border-selected {
460 @apply border;
461 @apply border-border;
462 @apply rounded-lg;
463 @apply outline-solid;
464 @apply outline-offset-1;
465 @apply outline-2;
466 @apply outline-border;
467}
468
469.blockquote {
470 @apply border-l-2;
471 @apply border-border;
472 @apply pl-3;
473 @apply ml-2;
474}
475
476.container {
477 @apply border;
478 @apply border-border-light;
479 @apply rounded-md;
480 background: rgba(var(--bg-page), var(--bg-page-alpha));
481}
482
483.transparent-container {
484 @apply border;
485 @apply border-border-light;
486 @apply rounded-md;
487}
488
489.frosted-container {
490 background: rgba(var(--bg-page), 0.75);
491 @apply border;
492 @apply border-bg-page;
493 @apply rounded-md;
494}
495
496.opaque-container {
497 @apply bg-bg-page;
498 @apply border;
499 @apply border-border-light;
500 @apply rounded-md;
501}
502
503.accent-container {
504 background: color-mix(
505 in oklab,
506 rgb(var(--accent-contrast)),
507 rgb(var(--bg-page)) 85%
508 );
509 @apply rounded-md;
510}
511
512.menuItem {
513 @apply text-secondary;
514 @apply hover:text-secondary;
515 @apply data-highlighted:bg-[var(--accent-light)];
516 @apply data-highlighted:outline-none;
517 @apply hover:bg-[var(--accent-light)];
518 text-align: left;
519 font-weight: 800;
520 padding: 0.25rem 0.5rem;
521 border-radius: 0.25rem;
522 outline: none !important;
523 cursor: pointer;
524 background-color: transparent;
525 display: flex;
526 gap: 0.5rem;
527
528 :hover {
529 text-decoration: none !important;
530 background-color: rgb(var(--accent-light));
531 }
532}
533
534.pwa-padding {
535 padding-top: max(calc(env(safe-area-inset-top) - 8px)) !important;
536}
537.pwa-padding-bottom {
538 padding-bottom: var(--safe-padding-bottom);
539}
540
541/* animation for new star in publish success illustration */
542@keyframes new-star-animation {
543 0% {
544 transform: scale(0);
545 opacity: 0;
546 }
547 50% {
548 transform: scale(0.1);
549 opacity: 0;
550 }
551 80% {
552 transform: scale(1.2);
553 opacity: 1;
554 }
555 100% {
556 transform: scale(1);
557 }
558}
559
560.new-star {
561 animation-name: new-star-animation;
562 animation-duration: 1s;
563 animation-iteration-count: 1;
564 animation-timing-function: ease-in;
565}
566
567.footnote-scope {
568 counter-reset: footnote;
569}
570.footnote-ref {
571 counter-increment: footnote;
572 cursor: pointer;
573 color: rgb(var(--color-tertiary));
574 opacity: 0.7;
575}
576.footnote-ref::after {
577 content: counter(footnote);
578 vertical-align: super;
579 padding-left: 2px;
580 font-size: 75%;
581 line-height: 0rem;
582}
583.footnote-ref ~ br.ProseMirror-trailingBreak {
584 display: inline;
585 width: 4px;
586}
587.footnote-ref ~ img.ProseMirror-separator {
588 display: none;
589}
590
591.footnote-side-enter {
592 animation: footnote-fade-in 200ms ease-out;
593}
594@keyframes footnote-fade-in {
595 from {
596 opacity: 0;
597 transform: translateX(-8px);
598 }
599 to {
600 opacity: 1;
601 transform: translateX(0);
602 }
603}
604
605.footnote-side-item {
606 overflow: hidden;
607 transition:
608 max-height 200ms ease,
609 opacity 200ms ease;
610 background: rgba(var(--bg-page), var(--bg-page-alpha));
611 border-radius: 4px;
612 padding: 4px 6px;
613}
614.footnote-side-item:not(:hover):not(:focus-within):not(.footnote-side-focused) {
615 max-height: calc(4.5em + 8px);
616 opacity: calc(var(--bg-page-alpha) * 0.7);
617}
618.footnote-side-item:not(:hover):not(:focus-within):not(.footnote-side-focused)
619 .footnote-item
620 > div:last-of-type {
621 display: -webkit-box;
622 -webkit-line-clamp: 3;
623 -webkit-box-orient: vertical;
624 overflow: hidden;
625 text-overflow: ellipsis;
626}
627.footnote-side-item:hover,
628.footnote-side-item:focus-within,
629.footnote-side-item.footnote-side-focused {
630 max-height: 40em;
631 opacity: var(--bg-page-alpha);
632}