:root {
  --text: #222;
  --muted: #6b6b6b;
  --link: #1a56b4;
  --rule: #e6e6e6;
  --code-bg: #f6f6f6;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  overflow-wrap: break-word;
}

.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 2.5rem 20px 4rem;
}

/* Navigation */

.site-nav {
  margin-bottom: 3rem;
  font-size: 0.95rem;
  color: var(--muted);
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--text);
}

.site-nav a[aria-current] {
  color: var(--text);
  font-weight: 600;
}

.site-nav span {
  margin: 0 0.4rem;
}

/* Text */

h1,
h2,
h3 {
  line-height: 1.3;
  font-weight: 600;
}

h1 {
  font-size: 1.8rem;
  margin: 0 0 1rem;
}

h2 {
  font-size: 1.3rem;
  margin: 2.25rem 0 0.75rem;
}

h3 {
  font-size: 1.1rem;
  margin: 1.75rem 0 0.5rem;
}

p,
ul,
ol,
blockquote,
pre {
  margin: 0 0 1rem;
}

a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-color: rgba(26, 86, 180, 0.3);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  text-decoration-color: currentColor;
}

blockquote {
  padding-left: 1rem;
  border-left: 3px solid var(--rule);
  color: var(--muted);
}

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 2rem 0;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em;
  background: var(--code-bg);
  padding: 0.1em 0.3em;
  border-radius: 3px;
}

pre {
  background: var(--code-bg);
  padding: 0.9rem 1rem;
  border-radius: 4px;
  overflow-x: auto;
  line-height: 1.45;
}

pre code {
  padding: 0;
  background: none;
  font-size: 0.85rem;
}

img {
  max-width: 100%;
  height: auto;
}

.date {
  color: var(--muted);
}

/* Writing piece */

article > h1 + .date {
  margin: -0.6rem 0 2rem;
}

/* Projects */

.entry {
  margin-bottom: 1.75rem;
}

.entry h2 {
  font-size: 1.1rem;
  margin: 0 0 0.25rem;
}

.entry p {
  margin: 0;
}

/* Writing list */

.writing-list {
  list-style: none;
  padding: 0;
}

.writing-list li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  column-gap: 1.5rem;
  padding: 0.4rem 0;
}

.writing-list .date {
  white-space: nowrap;
}

/* Small screens */

@media (max-width: 600px) {
  body {
    font-size: 16px;
  }

  .container {
    padding-top: 1.5rem;
  }

  .site-nav {
    margin-bottom: 2rem;
  }

  h1 {
    font-size: 1.55rem;
  }
}
