/*
 * onno.solin.co stylesheet
 * Plain, personal, readable. Deliberately not the Solin look.
 * System fonts only: no webfonts, no external requests of any kind.
 */

:root {
  --bg: #faf8f4;
  --fg: #22211f;
  --muted: #6b675f;
  --rule: #e2ddd3;
  --accent: #8a4b2a;
  --code-bg: #f0ece4;
  --measure: 40rem;
  --serif: Charter, "Iowan Old Style", Georgia, "Noto Serif", "DejaVu Serif", "Palatino Linotype", "Book Antiqua", "Times New Roman", serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1c1b19;
    --fg: #e6e2da;
    --muted: #a39d92;
    --rule: #3a3833;
    --accent: #d99a73;
    --code-bg: #26241f;
  }
}

* { box-sizing: border-box; }

html {
  font-family: var(--serif);
  font-size: 112.5%;
  line-height: 1.6;
  background: var(--bg);
  color: var(--fg);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0 1.25rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}
a:hover { text-decoration-thickness: 2px; }

/* Header */
.site-header {
  max-width: var(--measure);
  width: 100%;
  margin: 0 auto;
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid var(--rule);
}
.site-header .site-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: 0.01em;
}
.site-header .site-title a {
  color: var(--fg);
  text-decoration: none;
}
.site-header .tagline {
  margin: 0.15rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.site-nav {
  margin-top: 0.9rem;
  font-size: 0.9rem;
}
.site-nav a {
  color: var(--muted);
  text-decoration: none;
  margin-right: 1.1rem;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--fg);
  text-decoration: underline;
}

/* Main */
main {
  max-width: var(--measure);
  width: 100%;
  margin: 0 auto;
  padding: 2rem 0 3rem;
  flex: 1;
}

h1, h2, h3 {
  line-height: 1.25;
  font-weight: 700;
  margin: 2rem 0 0.6rem;
}
h1 { font-size: 1.9rem; margin-top: 0; }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.1rem; }

p, ul, ol, blockquote, pre, figure, table {
  margin: 0 0 1.2rem;
}
ul, ol { padding-left: 1.4rem; }
li { margin-bottom: 0.3rem; }

.meta {
  color: var(--muted);
  font-size: 0.9rem;
  margin: -0.4rem 0 1.8rem;
}

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

code, pre {
  font-family: var(--mono);
  font-size: 0.85em;
}
code {
  background: var(--code-bg);
  padding: 0.1em 0.3em;
  border-radius: 3px;
}
pre {
  background: var(--code-bg);
  padding: 0.9rem 1rem;
  overflow-x: auto;
  border-radius: 4px;
  line-height: 1.45;
}
pre code {
  background: none;
  padding: 0;
  font-size: inherit;
}

figure img {
  max-width: 100%;
  height: auto;
  display: block;
}
figcaption {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 0.4rem;
}

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.95rem;
}
th, td {
  text-align: left;
  padding: 0.4rem 0.6rem 0.4rem 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
th { font-weight: 700; }

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

/* Post list on the index page */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.post-list li {
  margin: 0 0 1.6rem;
}
.post-list .post-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0;
}
.post-list .post-title a {
  color: var(--fg);
  text-decoration: none;
}
.post-list .post-title a:hover { text-decoration: underline; }
.post-list .post-date {
  color: var(--muted);
  font-size: 0.85rem;
  display: block;
  margin: 0.1rem 0 0.25rem;
}
.post-list .post-summary {
  margin: 0;
}

/* Footer */
.site-footer {
  max-width: var(--measure);
  width: 100%;
  margin: 0 auto;
  padding: 1.25rem 0 2rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.85rem;
}
.site-footer p { margin: 0 0 0.3rem; }
.site-footer a { color: var(--muted); }

@media (max-width: 480px) {
  html { font-size: 100%; }
  .site-header { padding-top: 1.4rem; }
  h1 { font-size: 1.6rem; }
}
