2024-01-12 15:08:12 +01:00
|
|
|
:root {
|
|
|
|
--font-size: 12pt;
|
|
|
|
--line-height: 1.625;
|
|
|
|
--height-unit: calc(var(--font-size) * var(--line-height));
|
|
|
|
--width-unit: 1ch;
|
|
|
|
--padding-left: calc(1 * var(--width-unit));
|
|
|
|
--padding-right: calc(1 * var(--width-unit));
|
|
|
|
--padding-top: calc(1 * var(--height-unit));
|
|
|
|
--padding-bottom: calc(1 * var(--height-unit));
|
|
|
|
--gap-vertical: calc(1 * var(--height-unit));
|
|
|
|
--gap-horizontal: calc(2 * var(--width-unit));
|
|
|
|
--column-width: clamp(32ch, 72ch, calc(100vw - var(--gap-horizontal) - var(--padding-left) - var(--padding-right) - var(--width-unit)));
|
|
|
|
font: var(--font-size)/var(--line-height) monospace;
|
|
|
|
color-scheme: light dark;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* reset */
|
|
|
|
* {
|
|
|
|
box-sizing: border-box;
|
|
|
|
}
|
|
|
|
body {
|
|
|
|
color: light-dark(#000000, #ffffff);
|
|
|
|
background-color: light-dark(#ffffff, #000000);
|
|
|
|
margin: 0;
|
|
|
|
}
|
|
|
|
h1, h2, h3, h4, h5, h6 {
|
|
|
|
font: inherit;
|
|
|
|
}
|
|
|
|
h1 {
|
|
|
|
font-weight: bold;
|
|
|
|
margin: var(--height-unit) var(--height-unit) 0 0;
|
|
|
|
}
|
|
|
|
h2, h3, h4, h5, h6 {
|
|
|
|
font-style: italic;
|
|
|
|
margin: var(--height-unit) var(--height-unit) 0 0;
|
|
|
|
}
|
|
|
|
p {
|
|
|
|
margin: var(--height-unit) 0 0 0;
|
|
|
|
hyphens: auto;
|
|
|
|
}
|
2024-01-14 23:04:54 +01:00
|
|
|
blockquote {
|
|
|
|
margin: var(--height-unit) calc(2 * var(--width-unit));
|
|
|
|
}
|
|
|
|
ul, ol {
|
|
|
|
margin: var(--height-unit) 0;
|
|
|
|
padding: 0 0 0 calc(4 * var(--width-unit));
|
|
|
|
}
|
|
|
|
ul>li::marker {
|
|
|
|
content: "- ";
|
|
|
|
}
|
2024-01-12 15:08:12 +01:00
|
|
|
hr {
|
2024-01-14 23:04:54 +01:00
|
|
|
color: inherit;
|
2024-01-12 15:08:12 +01:00
|
|
|
border: none;
|
2024-01-14 23:04:54 +01:00
|
|
|
margin: var(--height-unit) 0;
|
2024-01-12 15:08:12 +01:00
|
|
|
}
|
|
|
|
hr:after {
|
|
|
|
content: "---";
|
|
|
|
}
|
|
|
|
|
|
|
|
/* main layout */
|
|
|
|
body {
|
|
|
|
padding: var(--height-unit) var(--width-unit);
|
|
|
|
width: 100vw;
|
|
|
|
height: 100vh;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* secondary grid */
|
|
|
|
body>main {
|
2024-01-14 23:04:54 +01:00
|
|
|
height: 100%;
|
2024-01-12 15:08:12 +01:00
|
|
|
display: grid;
|
|
|
|
grid-auto-flow: column;
|
|
|
|
grid-template-columns: repeat(auto-fit, var(--column-width));
|
|
|
|
grid-gap: var(--gap-horizontal);
|
|
|
|
overflow-x: scroll;
|
|
|
|
scroll-snap-type: x proximity;
|
|
|
|
}
|
|
|
|
body>main>article {
|
|
|
|
scroll-snap-align: start;
|
|
|
|
scroll-snap-stop: always;
|
|
|
|
width: var(--column-width);
|
|
|
|
overflow-y: scroll;
|
|
|
|
}
|
2024-01-14 23:04:54 +01:00
|
|
|
body>main>article>header>h1 {
|
|
|
|
margin: unset;
|
|
|
|
display: inline-block;
|
|
|
|
}
|
|
|
|
body>main>article>article {
|
|
|
|
margin: var(--height-unit) 0 0 0;
|
|
|
|
}
|