251 lines
3.3 KiB
CSS
Raw Normal View History

2024-03-31 20:43:49 +02:00
:root {
2025-02-25 17:01:59 +01:00
--hue: 220;
--body-color: hsl(var(--hue), 20%, 12%);
--text-color: hsl(var(--hue), 20%, 77%);
--main-color: hsl(calc(var(--hue) + 180), 100%, 75%);
2024-03-31 20:43:49 +02:00
--header-color: hsl(0, 0%, 100%);
--grey-color: hsl(0, 0%, 61%);
--highlight-color: hsla(0, 0%, 100%, 0.05);
2025-02-25 17:01:59 +01:00
--font-family: system-ui, sans-serif;
2024-03-31 20:43:49 +02:00
--font-family-mono: monospace;
--font-size: 18px;
--line-height: 1.6;
2024-04-04 13:53:29 +02:00
--letter-spacing: -0.02em;
2024-03-31 20:43:49 +02:00
--max-width: 65ch;
--padding: 0.78571429em 0.92857143em;
--border-radius: 5px;
2024-04-04 09:12:14 +02:00
--gap: 1rem;
2024-03-31 20:43:49 +02:00
}
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
height: 100%;
}
body {
2025-02-25 17:01:59 +01:00
color: var(--text-color);
background-color: var(--body-color);
font-family: var(--font-family);
font-size: var(--font-size);
line-height: var(--line-height);
letter-spacing: var(--letter-spacing);
2024-03-31 20:43:49 +02:00
display: flex;
flex-direction: column;
align-items: center;
height: 100%;
overflow-x: hidden;
overflow-y: scroll;
word-break: break-word;
tab-size: 4;
}
main,
section,
article {
display: flex;
flex-direction: column;
gap: var(--gap);
}
a {
2025-02-25 17:01:59 +01:00
color: var(--main-color);
2024-03-31 20:43:49 +02:00
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
ul,
ol {
list-style-position: inside;
}
pre {
white-space: pre-wrap;
}
blockquote,
pre {
padding: var(--padding);
border-radius: var(--border-radius);
background-color: var(--highlight-color);
}
2024-04-02 21:54:41 +02:00
code {
font-family: var(--font-family-mono);
font-size: 90%;
word-break: break-word;
}
p > code {
padding: 0.15em 0.3em;
border-radius: var(--border-radius);
background-color: var(--highlight-color);
}
2024-03-31 20:43:49 +02:00
blockquote p::before {
content: "\201C";
}
blockquote p::after {
content: "\201D";
}
h1 {
color: white;
font-size: 2.2rem;
2024-04-04 11:37:35 +02:00
font-weight: normal;
2024-03-31 20:43:49 +02:00
}
h2 {
color: var(--header-color);
font-size: 1.8rem;
2024-04-04 09:12:14 +02:00
font-weight: normal;
2024-03-31 20:43:49 +02:00
margin-top: var(--gap);
padding-bottom: var(--gap);
border-bottom: 1px solid var(--highlight-color);
}
h3 {
color: var(--header-color);
2024-07-30 00:12:12 +02:00
font-size: 1.4rem;
2024-03-31 20:43:49 +02:00
font-weight: normal;
}
hr {
border-top: none;
border-bottom: 1px solid var(--highlight-color);
}
th,
td {
width: 50%;
text-align: left;
vertical-align: baseline;
2024-03-31 20:43:49 +02:00
}
th {
border-bottom: 1px solid var(--highlight-color);
}
th:empty {
display: none;
}
2024-04-04 11:37:35 +02:00
body > header,
2024-04-02 18:12:41 +02:00
main {
2024-04-02 12:23:37 +02:00
width: 100%;
max-width: var(--max-width);
padding: var(--padding);
}
2024-04-04 11:37:35 +02:00
body > header {
2024-04-02 12:23:37 +02:00
max-width: calc(var(--max-width) + 4rem);
}
main {
flex: 1;
2024-04-04 09:12:14 +02:00
padding-bottom: 3rem;
2024-04-02 12:23:37 +02:00
}
nav {
display: flex;
gap: 1rem;
list-style-type: none;
2024-07-30 00:12:12 +02:00
justify-content: center;
2024-04-02 12:23:37 +02:00
}
2024-04-02 16:20:44 +02:00
nav a {
2024-04-02 12:23:37 +02:00
color: var(--grey-color);
}
2024-04-02 16:20:44 +02:00
nav a:hover {
2024-04-02 12:23:37 +02:00
text-decoration: none;
}
.title {
color: var(--main-color);
}
2024-04-04 11:37:35 +02:00
article header time {
2024-04-02 12:23:37 +02:00
font-size: 0.8rem;
color: var(--grey-color);
}
2024-07-30 00:12:12 +02:00
img {
width: 100%;
border-radius: 3px;
}
2024-04-04 11:37:35 +02:00
.blog li {
display: flex;
}
.blog li time {
flex: 1;
text-align: right;
color: var(--grey-color);
}
2024-03-31 20:43:49 +02:00
.comment {
color: gray;
font-style: italic;
}
.char,
.string {
color: greenyellow;
}
.keyword {
2025-02-25 17:01:59 +01:00
color: var(--main-color);
2024-03-31 20:43:49 +02:00
}
.function {
2025-02-25 17:01:59 +01:00
color: var(--main-color);
2024-03-31 20:43:49 +02:00
}
.builtin {
color: #fffab5;
}
.number {
color: cyan;
}
.variable {
color: gray;
}
.parameter {
color: orange;
}
.section {
color: lightgreen;
}
.operator {
color: white;
}
.punctuation {
color: gray;
2024-04-04 09:12:14 +02:00
}
@media (min-width: 800px) {
2024-04-04 11:37:35 +02:00
article header,
2024-04-04 09:12:14 +02:00
h2 {
margin-left: -1rem;
}
2024-04-04 11:37:35 +02:00
article header time {
margin-left: 0.5rem;
2024-04-04 09:12:14 +02:00
}
2024-03-31 20:43:49 +02:00
}