* { box-sizing: border-box; }

:root {
  --bg: #0a1628;
  --fg: #c3d2e6;
  --bold: #eef4ff;
  --muted: #5c7495;
  --accent: #5eb1ff;
  --indent: 0.75rem;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 15px;
  line-height: 1.65;
}

.bar {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  color: var(--muted);
  font-size: 0.8rem;
  padding: 0.75rem 1rem;
}

.bar .mirror {
  display: none;
}

.bar a {
  color: var(--muted);
}

.bar a:hover {
  color: var(--accent);
}

main {
  max-width: 760px;
  margin: 0 auto;
  padding: 0.5rem 1rem 3rem;
}

h1 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--bold);
  margin: 1.75rem 0 0.75rem;
  letter-spacing: 0.03em;
}

h2 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--fg);
  margin: 1.25rem 0 0.5rem var(--indent);
}

p, dl, ul.plain {
  margin: 0 0 0.75rem var(--indent);
  color: var(--fg);
}

.name-line {
  margin-left: var(--indent);
}

.quote .cite {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
}

.name-line .opt {
  white-space: nowrap;
}

.name-line b {
  color: var(--bold);
}

a {
  color: var(--accent);
  text-decoration: none;
  overflow-wrap: break-word;
}

a:hover {
  text-decoration: underline;
}

/* term/value pairs (books, philosophy): term over values on small screens, two columns on wide ones */
.pairs dt {
  color: var(--muted);
  font-size: 0.8rem;
}

.pairs dt:not(:first-child) {
  margin-top: 0.5rem;
}

.pairs dd {
  margin: 0;
}

/* wider screens: switch to the full man-page layout */
@media (min-width: 640px) {
  :root {
    --indent: 3rem;
  }

  .bar {
    flex-direction: row;
    justify-content: space-between;
    font-size: 0.85rem;
    padding: 0.5rem 1.5rem;
  }

  .bar .mirror {
    display: inline;
  }

  main {
    padding: 0.5rem 1.5rem 4rem;
  }

  .pairs {
    display: grid;
    grid-template-columns: 18ch 1fr;
    column-gap: 2ch;
  }

  .pairs dt {
    grid-column: 1;
    font-size: inherit;
  }

  .pairs dd {
    grid-column: 2;
  }

  .pairs dt:not(:first-child),
  .pairs dt:not(:first-child) + dd {
    margin-top: 0.35rem;
  }
}
