/* arvin.kilambi.com - personal blog.
   Editorial layout: flat paper, hairline rules, serif reading type,
   sans for labels and dates. No cards, no shadows, no gradients. */

:root {
  --ink: #1c1a17;
  --muted: #6f6a5e;
  --hairline: #d8d2c4;
  --hairline-strong: #b9b2a2;
  --link: #00507a;
  --paper: #fffdf8;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia,
           "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.62;
}

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap {
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ---------- masthead ---------- */

.masthead {
  border-bottom: 2px solid var(--ink);
  padding: 1.6rem 0 0.9rem;
  margin-bottom: 2.2rem;
}

.masthead .wordmark {
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

.masthead .wordmark a { color: var(--ink); }
.masthead .wordmark a:hover { text-decoration: none; }

.masthead .tagline {
  color: var(--muted);
  font-style: italic;
  font-size: 1.02rem;
  margin-top: 0.3rem;
}

.masthead nav {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 0.9rem;
  color: var(--muted);
}

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

/* ---------- home ---------- */

.post-list { list-style: none; margin: 0; padding: 0; }

.post-list li {
  border-bottom: 1px solid var(--hairline);
  padding: 1.05rem 0 1.15rem;
}

.post-list li:first-child { padding-top: 0.2rem; }

.post-list .date {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.post-list .title {
  font-size: 1.32rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0.25rem 0 0.3rem;
}

.post-list .title a { color: var(--ink); }

.post-list .summary {
  color: #454138;
  font-size: 1.0rem;
  line-height: 1.5;
}

.empty-note {
  color: var(--muted);
  font-style: italic;
  padding: 0.4rem 0 0.6rem;
}

.section-label {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--hairline-strong);
  padding-bottom: 0.4rem;
  margin: 2.6rem 0 1.1rem;
}

.about p { max-width: 38rem; }

.edit-note {
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- article ---------- */

article h1 {
  font-size: 2.15rem;
  line-height: 1.16;
  letter-spacing: -0.015em;
  margin: 0 0 0.6rem;
}

article .dateline {
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 1rem;
  margin-bottom: 1.6rem;
}

article p { margin: 0 0 1.15rem; }

article h2 {
  font-size: 1.35rem;
  line-height: 1.3;
  margin: 2rem 0 0.7rem;
}

/* Floated figures: text wraps; float releases under 720px. */
figure.fig-right, figure.fig-left {
  width: 45%;
  margin: 0.35rem 0 1rem;
}
figure.fig-right { float: right; margin-left: 1.6rem; }
figure.fig-left  { float: left;  margin-right: 1.6rem; }

figure.fig-right img, figure.fig-left img,
figure.fig-wide img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--hairline);
}

figcaption {
  font-family: var(--sans);
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--muted);
  border-top: 1px solid var(--hairline-strong);
  margin-top: 0.5rem;
  padding-top: 0.45rem;
}

figure.fig-wide { margin: 1.8rem 0; }

/* Interactive chart block */
.post-chart {
  width: 100%;
  height: 330px;
  margin: 1.6rem 0 0.4rem;
}

.chart-block { margin: 1.8rem 0; }
.chart-block figcaption { margin-top: 0.2rem; }

/* Pull quote */
.pullquote {
  font-size: 1.38rem;
  line-height: 1.42;
  font-style: italic;
  border-top: 1px solid var(--hairline-strong);
  border-bottom: 1px solid var(--hairline-strong);
  padding: 1.1rem 0.4rem;
  margin: 2rem 0;
  clear: both;
}

/* End-of-post notes / sources */
.post-notes {
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--muted);
  border-top: 1px solid var(--hairline);
  margin-top: 2.4rem;
  padding-top: 1rem;
  clear: both;
}

.post-notes p { margin: 0 0 0.6rem; }

/* ---------- footer ---------- */

footer {
  border-top: 1px solid var(--hairline-strong);
  margin-top: 3.2rem;
  padding: 1.1rem 0 2.2rem;
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--muted);
}

footer p { margin: 0.2rem 0; }

/* ---------- narrow screens ---------- */

@media (max-width: 720px) {
  body { font-size: 18px; }
  figure.fig-right, figure.fig-left {
    float: none;
    width: 100%;
    margin: 1.2rem 0;
  }
  .post-chart { height: 300px; }
  article h1 { font-size: 1.8rem; }
  .pullquote { font-size: 1.22rem; }
}
