248 lines
3.3 KiB
CSS
248 lines
3.3 KiB
CSS
:root {
|
|
--main-hue: 40;
|
|
--main-saturation: 100%;
|
|
--main-color: hsl(var(--main-hue), var(--main-saturation), 70%);
|
|
--link-color: hsl(var(--main-hue), var(--main-saturation), 75%);
|
|
--header-color: hsl(0, 0%, 100%);
|
|
--text-color: hsl(0, 0%, 77%);
|
|
--grey-color: hsl(0, 0%, 61%);
|
|
--highlight-color: hsla(0, 0%, 100%, 0.05);
|
|
--body-color: hsl(220, 5%, 12%);
|
|
--font-family: "Segoe UI", system-ui;
|
|
--font-family-mono: monospace;
|
|
--font-size: 18px;
|
|
--line-height: 1.6;
|
|
--letter-spacing: -0.02em;
|
|
--max-width: 65ch;
|
|
--padding: 0.78571429em 0.92857143em;
|
|
--border-radius: 5px;
|
|
--gap: 1rem;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
html {
|
|
height: 100%;
|
|
}
|
|
|
|
body {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
height: 100%;
|
|
overflow-x: hidden;
|
|
overflow-y: scroll;
|
|
font-family: var(--font-family);
|
|
font-size: var(--font-size);
|
|
line-height: var(--line-height);
|
|
letter-spacing: var(--letter-spacing);
|
|
color: var(--text-color);
|
|
background-color: var(--body-color);
|
|
word-break: break-word;
|
|
tab-size: 4;
|
|
}
|
|
|
|
main,
|
|
section,
|
|
article {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: var(--gap);
|
|
}
|
|
|
|
a {
|
|
color: var(--link-color);
|
|
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);
|
|
}
|
|
|
|
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);
|
|
}
|
|
|
|
blockquote p::before {
|
|
content: "\201C";
|
|
}
|
|
|
|
blockquote p::after {
|
|
content: "\201D";
|
|
}
|
|
|
|
h1 {
|
|
color: white;
|
|
font-size: 2.2rem;
|
|
font-weight: normal;
|
|
}
|
|
|
|
h2 {
|
|
color: var(--header-color);
|
|
font-size: 1.8rem;
|
|
font-weight: normal;
|
|
margin-top: var(--gap);
|
|
padding-bottom: var(--gap);
|
|
border-bottom: 1px solid var(--highlight-color);
|
|
}
|
|
|
|
h3 {
|
|
color: var(--header-color);
|
|
font-size: 1.3rem;
|
|
font-weight: normal;
|
|
}
|
|
|
|
hr {
|
|
border-top: none;
|
|
border-bottom: 1px solid var(--highlight-color);
|
|
}
|
|
|
|
th,
|
|
td {
|
|
width: 50%;
|
|
text-align: left;
|
|
vertical-align: baseline;
|
|
}
|
|
|
|
th {
|
|
border-bottom: 1px solid var(--highlight-color);
|
|
}
|
|
|
|
th:empty {
|
|
display: none;
|
|
}
|
|
|
|
body > header,
|
|
main {
|
|
width: 100%;
|
|
max-width: var(--max-width);
|
|
padding: var(--padding);
|
|
}
|
|
|
|
body > header {
|
|
max-width: calc(var(--max-width) + 4rem);
|
|
}
|
|
|
|
main {
|
|
flex: 1;
|
|
padding-bottom: 3rem;
|
|
}
|
|
|
|
nav {
|
|
display: flex;
|
|
gap: 1rem;
|
|
list-style-type: none;
|
|
align-items: center;
|
|
}
|
|
|
|
nav a {
|
|
color: var(--grey-color);
|
|
}
|
|
|
|
nav a:hover {
|
|
text-decoration: none;
|
|
}
|
|
|
|
.title {
|
|
color: var(--main-color);
|
|
}
|
|
|
|
article header time {
|
|
font-size: 0.8rem;
|
|
color: var(--grey-color);
|
|
}
|
|
|
|
.blog li {
|
|
display: flex;
|
|
}
|
|
|
|
.blog li time {
|
|
flex: 1;
|
|
text-align: right;
|
|
color: var(--grey-color);
|
|
}
|
|
|
|
.comment {
|
|
color: gray;
|
|
font-style: italic;
|
|
}
|
|
|
|
.char,
|
|
.string {
|
|
color: greenyellow;
|
|
}
|
|
|
|
.keyword {
|
|
color: var(--link-color);
|
|
}
|
|
|
|
.function {
|
|
color: var(--link-color);
|
|
}
|
|
|
|
.builtin {
|
|
color: #fffab5;
|
|
}
|
|
|
|
.number {
|
|
color: cyan;
|
|
}
|
|
|
|
.variable {
|
|
color: gray;
|
|
}
|
|
|
|
.parameter {
|
|
color: orange;
|
|
}
|
|
|
|
.section {
|
|
color: lightgreen;
|
|
}
|
|
|
|
.operator {
|
|
color: white;
|
|
}
|
|
|
|
.punctuation {
|
|
color: gray;
|
|
}
|
|
|
|
@media (min-width: 800px) {
|
|
article header,
|
|
h2 {
|
|
margin-left: -1rem;
|
|
}
|
|
|
|
article header time {
|
|
margin-left: 0.5rem;
|
|
}
|
|
} |