:root {
  --color-link: blue;
  --color-background: white;
  --color-text: #121212;
  --color-code: #f5f5f5;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-background: #121212;
    --color-text: white;
    --color-link: #6bf;
    --color-code: #eee
  }
}

body {
  padding: 0 1em;
  margin: 1rem auto;
  max-width:974px;
  color: var(--color-text);
  background-color: var(--color-background);
    line-height: 1.6;
    font-size: 16px;
  font-family: "Times New Roman", Times, serif;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  word-wrap:break-word
}

a, a:visited {
  color: var(--color-link);
}

pre {
  background-color: var(--color-code);
  padding: 0.5em;
  white-space: pre-wrap;
  word-break: break-all;
}

code {
  font-size: 14px;
}

h2 {
  border-bottom: 1px solid;
}

footer {
  margin: 2rem 0;
}

table {
  width: 100%;
  border-spacing: 0;
}

th {
  text-align: left;
  border-bottom: 1px solid #333;
  padding: 0.25em 0.5em;
}

td {
  border-bottom: 1px solid #333;
  padding: 0.25em 0.5em;
}

td:last-child {
  text-align: right;
}

ul {
  padding-inline-start: 1em;
}

li {
  margin-bottom: 0.25em;
}

img {
  max-width: 100%;
}

/* CLASSES */

.home {
  font-size: 1em;
}

.table-of-contents {
  background-color: #f8f8f8;
  padding: 0.25em 0.5em;
}

.table-of-contents:before {
  content: "TABLE OF CONTENTS";
  font-weight: bold;
}

.date {
  font-family: ui-monospace,  monospace;
  font-size: 0.9em;
  margin-right: 0.5em;
}

.posts {
  display: block;
}

.posts > div:nth-child(even) {
  margin-bottom: 0.5em;
}

.no-border {
  border: 0;
}

@media screen and (min-width: 800px) {
  body {
      font-size: 18px;
  }

code {
  font-size: 14px;
}

  .posts {
    display: grid;
    grid-template-columns: 1fr 8fr;
  }

  .posts > div:nth-child(even) {
    margin-bottom: 0;
  }
}