/* ==========================================================================
   Blog-only stylesheet. Loaded after styles.css, on blog pages only.
   Nothing here restates a base rule; it only adds what the blog needs.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Post index
   -------------------------------------------------------------------------- */

.post-year {
  font-size: var(--font-size);
  color: var(--muted);
  letter-spacing: 0.08em;
  margin: 2.5rem 0 0.75rem;
}

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

.post-list > li {
  margin: 0 0 1.25rem;
}

.post-list a {
  font-weight: 600;
}

.post-list .post-date {
  color: var(--muted);
  font-size: 0.9em;
  margin-left: 1ch;
  white-space: nowrap;
}

.post-list .post-description {
  color: var(--muted);
  margin: 0.15rem 0 0;
  text-wrap: pretty;
}

/* --------------------------------------------------------------------------
   Post header
   -------------------------------------------------------------------------- */

.post-header {
  margin: 2rem 0 2.5rem;
}

.post-header h1 {
  margin: 0 0 0.35rem;
  text-wrap: balance;
}

.post-meta {
  color: var(--muted);
  font-size: 0.9em;
}

.post-nav {
  margin-top: 3rem;
}

/* --------------------------------------------------------------------------
   Prism normalisation

   The CDN themes ship their own font stack, background and text-shadow.
   These selectors carry an attribute selector, so matching that specificity
   is required to override them.
   -------------------------------------------------------------------------- */

pre[class*="language-"],
code[class*="language-"] {
  font-family: "Iosevka Web", ui-monospace, monospace;
  font-size: 0.95em;
  text-shadow: none;
  hyphens: none;
}

pre[class*="language-"] {
  tab-size: 4;
  background: var(--tint);
  padding: 1rem 1.25rem;
  line-height: 1.5;
  overflow: auto;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
}

code[class*="language-"] {
  background: none;
  border: none;
  padding: 0;
}

:not(pre) > code[class*="language-"] {
  background: var(--tint);
  border: 1px solid var(--rule);
  padding: 0.05em 0.4em;
}
