/* ═══════════════════════════════════════════════════════════════
   Curriculum Vitae · Md Dilshadur Rahman
   A single sheet of paper on a quiet desk. Lora for reading, Inter
   for the small furniture (dates, labels, the reader bar). The sheet
   keeps a printed CV's habits: dates in the left margin, a hairline
   under each part, nothing that does not help the reader.
   Shares its palette with dilshadur.com and the annotation sites.
   ═══════════════════════════════════════════════════════════════ */

:root {
  --desk: #EEECE6;
  --paper: #FFFEFB;
  --ink: #1C1D20;
  --ink-2: #44464C;
  --ink-3: #66686E;
  --rule: #E4E1D9;
  --rule-strong: #CFCBC1;
  --accent: #24466F;
  --accent-soft: rgba(36, 70, 111, 0.07);
  --link-line: rgba(36, 70, 111, 0.32);
  --warm: #9E4E24;
  --glass: rgba(238, 236, 230, 0.86);
  --sheet-shadow:
    0 1px 1px rgba(28, 29, 32, 0.04),
    0 2px 6px -2px rgba(28, 29, 32, 0.06),
    0 18px 40px -18px rgba(28, 29, 32, 0.18);

  --serif: 'Lora', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', -apple-system, 'Helvetica Neue', Arial, sans-serif;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  --sheet-w: 860px;
  --pad-x: 84px;
  --gutter-w: 158px;
  --bar-h: 56px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --desk: #0B0C0E;
  --paper: #16181B;
  --ink: #E4E2DC;
  --ink-2: #BDBBB5;
  --ink-3: #8F8E89;
  --rule: #26282C;
  --rule-strong: #34363B;
  --accent: #A9C3E4;
  --accent-soft: rgba(169, 195, 228, 0.08);
  --link-line: rgba(169, 195, 228, 0.36);
  --warm: #F0B07C;
  --glass: rgba(11, 12, 14, 0.84);
  --sheet-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.035),
    0 24px 60px -24px rgba(0, 0, 0, 0.8);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--bar-h) + 28px);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--desk);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 16.5px;
  line-height: 1.6;
  font-kerning: normal;
  font-variant-ligatures: common-ligatures;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1,
h2,
h3,
h4,
p,
ol,
ul {
  margin: 0;
}

ol,
ul {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

::selection {
  background: rgba(214, 140, 72, 0.26);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 6px;
  background: var(--ink);
  color: var(--paper);
  font: 500 14px/1 var(--sans);
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

/* Links read like links in a printed text: a fine rule, not a color block */
.sheet a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--link-line);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s ease, color 0.2s ease;
}

.sheet a:hover {
  color: var(--accent);
  text-decoration-color: currentColor;
}

.u {
  color: inherit;
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0% 1px no-repeat;
  padding-bottom: 2px;
  transition: background-size 0.4s var(--ease-out);
}

.u:hover {
  background-size: 100% 1px;
}

/* ── The reader bar ───────────────────────────────────────────── */
.reader {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(1.2) blur(14px);
  backdrop-filter: saturate(1.2) blur(14px);
}

.reader__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: calc(var(--sheet-w) + 48px);
  height: var(--bar-h);
  margin: 0 auto;
  padding: 0 24px;
  padding-left: max(24px, env(safe-area-inset-left));
  padding-right: max(24px, env(safe-area-inset-right));
}

.reader__start {
  display: flex;
  align-items: center;
  min-width: 0;
}

.home {
  display: grid;
  place-items: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  transition: transform 0.4s var(--ease-out), box-shadow 0.2s;
}

.home img {
  display: block;
  width: 26px;
  height: 26px;
  border-radius: 999px;
}

.home:hover {
  transform: translateX(-2px);
  box-shadow: 0 0 0 1px var(--rule-strong);
}

.reader__div {
  flex: none;
  width: 1px;
  height: 18px;
  margin: 0 14px;
  background: var(--rule-strong);
}

.reader__title {
  overflow: hidden;
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reader__tools {
  display: flex;
  flex: none;
  align-items: center;
  gap: 6px;
}

.tool {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font: 500 13px/1 var(--sans);
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background-color 0.2s;
}

.tool svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tool:hover,
.tool[aria-expanded="true"] {
  color: var(--ink);
  border-color: var(--rule-strong);
}

.tool--round {
  width: 36px;
  padding: 0;
  justify-content: center;
  border-color: var(--rule-strong);
}

.tool--round:active svg {
  transform: rotate(-20deg);
}

/* the icon names the theme a press brings: a moon by day, a sun by night */
.tool--round .i-sun,
html[data-theme="dark"] .tool--round .i-moon {
  display: none;
}

html[data-theme="dark"] .tool--round .i-sun {
  display: block;
}

.reader__progress {
  height: 1px;
  background: var(--rule);
}

.reader__progress span {
  display: block;
  height: 1px;
  background: var(--ink-3);
  transform: scaleX(0);
  transform-origin: 0 50%;
}

/* contents, as a small card that drops from the bar */
.contents {
  position: relative;
}

.contents__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 248px;
  padding: 10px;
  border: 1px solid var(--rule);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: var(--sheet-shadow);
  font: 400 14.5px/1.3 var(--serif);
}

.contents__panel a {
  display: block;
  padding: 9px 12px;
  border-radius: 6px;
  color: var(--ink-2);
  text-decoration: none;
  transition: background-color 0.15s, color 0.15s;
}

.contents__panel a:hover,
.contents__panel a[aria-current] {
  background: var(--accent-soft);
  color: var(--ink);
}

/* ── Contents in the margin (wide screens) ────────────────────── */
.margin-toc {
  display: none;
}

@media (min-width: 1280px) {
  .margin-toc {
    display: block;
    position: fixed;
    top: calc(var(--bar-h) + 76px);
    left: calc(50% - var(--sheet-w) / 2 - 196px);
    width: 160px;
    font: 400 13px/1.3 var(--sans);
  }

  .margin-toc a {
    position: relative;
    display: block;
    padding: 6px 0 6px 16px;
    color: var(--ink-3);
    text-decoration: none;
    transition: color 0.2s;
  }

  .margin-toc a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 5px;
    height: 5px;
    margin-top: -2.5px;
    border-radius: 999px;
    background: var(--warm);
    opacity: 0;
    transform: scale(0.4);
    transition: opacity 0.25s, transform 0.35s var(--ease-out);
  }

  .margin-toc a:hover {
    color: var(--ink);
  }

  .margin-toc a[aria-current] {
    color: var(--ink);
  }

  .margin-toc a[aria-current]::before {
    opacity: 1;
    transform: none;
  }

  .contents {
    display: none;
  }
}

/* ── The desk and the sheet ───────────────────────────────────── */
.desk {
  padding: 40px 24px 0;
}

.sheet {
  max-width: var(--sheet-w);
  margin: 0 auto;
  padding: 88px var(--pad-x) 56px;
  border-radius: 3px;
  background: var(--paper);
  box-shadow: var(--sheet-shadow);
  outline: none;
  transition: background-color 0.3s ease;
}

.js .sheet {
  animation: settle 0.8s var(--ease-out) both;
}

/* a whisper of paper: fine grain under the ink, never on top of it */
.sheet {
  position: relative;
  isolation: isolate;
}

.sheet::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='g'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.42  0 0 0 0 0.37  0 0 0 0 0.30  0 0 0 0.6 0'/></filter><rect width='100%25' height='100%25' filter='url(%23g)'/></svg>");
  background-size: 180px 180px;
  opacity: 0.055;
  pointer-events: none;
}

html[data-theme="dark"] .sheet::before {
  opacity: 0.03;
  mix-blend-mode: screen;
  filter: invert(1);
}

@keyframes settle {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

.desk__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 12px;
  max-width: var(--sheet-w);
  margin: 0 auto;
  padding: 28px 0 calc(48px + env(safe-area-inset-bottom));
  font: 400 13px/1.5 var(--sans);
  color: var(--ink-3);
}

.desk__foot a:hover {
  color: var(--ink);
}

/* ── Masthead ─────────────────────────────────────────────────── */
.masthead {
  padding-bottom: 36px;
  border-bottom: 1px solid var(--rule-strong);
}

.masthead__kicker,
.smallcaps,
.part__title,
.when,
.kind,
.pub-group__title,
.filter,
.colophon {
  font-family: var(--sans);
}

.masthead__kicker {
  margin-bottom: 18px;
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.masthead__name {
  font-family: var(--serif);
  font-size: clamp(36px, 5.4vw, 50px);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.018em;
  color: var(--ink);
}

.masthead__role {
  margin-top: 12px;
  font-size: 18px;
  font-style: italic;
  color: var(--ink-2);
}

.masthead__contact {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  margin-top: 22px;
  font: 400 14px/1.6 var(--sans);
  color: var(--ink-2);
}

.masthead__contact li:not(:last-child)::after {
  content: "·";
  margin: 0 10px;
  color: var(--ink-3);
}

.masthead__contact a {
  text-decoration-color: transparent;
}

.masthead__interests {
  margin-top: 18px;
  max-width: 62ch;
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-2);
}

.smallcaps {
  margin-right: 10px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ── Parts ────────────────────────────────────────────────────── */
.part {
  padding-top: 52px;
}

.part__title {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.part__title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
}

.part__sub {
  margin: 34px 0 16px;
  padding-left: var(--gutter-w);
  font-family: var(--serif);
  font-size: 17px;
  font-style: italic;
  font-weight: 400;
  color: var(--ink-2);
}

.part__title + .part__sub {
  margin-top: 0;
}

.part__note {
  margin: -6px 0 22px var(--gutter-w);
  max-width: 60ch;
  font-size: 14.5px;
  font-style: italic;
  line-height: 1.6;
  color: var(--ink-3);
}

/* an entry: the date in the margin, the substance beside it */
.entries {
  display: grid;
  gap: 22px;
}

.entries--tight {
  gap: 11px;
}

.entry {
  display: grid;
  grid-template-columns: var(--gutter-w) minmax(0, 1fr);
  align-items: baseline;
}

.when {
  padding-right: 18px;
  font-size: 12.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  line-height: 1.5;
  color: var(--ink-3);
  white-space: nowrap;
}

.what {
  min-width: 0;
}

.title,
h4.title {
  font-family: var(--serif);
  font-size: 17.5px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: -0.003em;
  color: var(--ink);
  text-wrap: pretty;
}

.where {
  margin-top: 2px;
  font-style: italic;
  color: var(--ink-2);
  text-wrap: pretty;
}

.detail {
  margin-top: 3px;
  font-size: 15.5px;
  color: var(--ink-2);
  text-wrap: pretty;
}

.detail cite {
  font-style: italic;
  color: var(--ink);
}

p.what {
  color: var(--ink);
  text-wrap: pretty;
}

p.what em {
  color: var(--ink-2);
}

.kind {
  margin-right: 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* peer review: a quiet two-column list */
.reviews {
  columns: 2;
  column-gap: 40px;
  margin-left: var(--gutter-w);
}

.reviews li {
  break-inside: avoid;
  padding: 3px 0;
  font-size: 15.5px;
  color: var(--ink);
}

.reviews span {
  margin-left: 6px;
  font: 500 12.5px/1 var(--sans);
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
}

/* ── Publications ─────────────────────────────────────────────── */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin: 0 0 30px var(--gutter-w);
  padding-bottom: 16px;
  border-bottom: 1px solid var(--rule);
}

/* each label carries its own underline, a few pixels under the word */
.filter {
  position: relative;
  padding: 4px 0 7px;
  border: 0;
  background: none;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
  transition: color 0.2s;
}

.filter::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  opacity: 0;
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 0.35s var(--ease-out), opacity 0.2s ease;
}

.filter:hover {
  color: var(--ink-2);
}

.filter:hover::after {
  opacity: 0.55;
  transform: none;
}

.filter[aria-pressed="true"] {
  color: var(--ink);
}

.filter[aria-pressed="true"]::after {
  opacity: 1;
  transform: none;
}

.count {
  margin-left: 3px;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
}

.pubs {
  transition: opacity 0.18s ease;
}

.pubs.is-switching {
  opacity: 0;
}

.pub-group + .pub-group {
  margin-top: 40px;
}

.pub-group__title {
  margin: 0 0 18px var(--gutter-w);
  font-family: var(--serif);
  font-size: 17px;
  font-style: italic;
  font-weight: 400;
  color: var(--ink-2);
}

.pub .when {
  font-variant-numeric: tabular-nums;
}

.pub__title {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.42;
  color: var(--ink);
  text-wrap: pretty;
}

.pub__authors {
  margin-top: 3px;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ink-2);
}

.pub__authors strong {
  font-weight: 600;
  color: var(--ink);
}

.pub__venue {
  margin-top: 2px;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ink-2);
}

.pub__venue i {
  color: var(--ink);
}

.pub__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 0;
  margin-top: 6px;
  font: 400 13px/1.6 var(--sans);
  color: var(--ink-3);
}

.pub__meta > * {
  white-space: nowrap;
}

/* separators trail the item before them, as punctuation would */
.pub__meta > :not(:last-child)::after {
  content: "·";
  display: inline-block;
  margin: 0 9px;
  color: var(--ink-3);
  text-decoration: none;
}

.pub__note {
  font-style: normal;
}

.sheet .pub__meta a {
  color: var(--accent);
  text-decoration-color: var(--link-line);
}

.sheet .pub__meta a:hover {
  text-decoration-color: currentColor;
}

.pub__ext {
  margin-left: 2px;
  font-size: 0.92em;
  text-decoration: none;
  display: inline-block;
}

.pub-error {
  margin-left: var(--gutter-w);
  font-style: italic;
  color: var(--ink-3);
}

/* ── Colophon ─────────────────────────────────────────────────── */
.colophon {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 24px;
  margin-top: 64px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--ink-3);
}

/* ── Medium screens ───────────────────────────────────────────── */
@media (max-width: 900px) {
  :root {
    --pad-x: 48px;
    --gutter-w: 146px;
  }

  .when {
    font-size: 12px;
  }
}

/* ── Phones: the sheet becomes the page, dates move above ─────── */
@media (max-width: 640px) {
  :root {
    --pad-x: 22px;
    --gutter-w: 0px;
    --bar-h: 52px;
  }

  body {
    font-size: 16px;
  }

  .reader__inner {
    padding: 0 14px;
  }

  .reader__div {
    margin: 0 10px;
  }

  .tool {
    padding: 0 10px;
  }

  .desk {
    padding: 0;
  }

  .sheet {
    padding-top: 40px;
    padding-bottom: 40px;
    border-radius: 0;
    box-shadow: none;
  }

  .masthead {
    padding-bottom: 28px;
  }

  .masthead__role {
    font-size: 17px;
  }

  .masthead__contact {
    font-size: 13.5px;
  }

  .part {
    padding-top: 44px;
  }

  .part__title {
    margin-bottom: 22px;
  }

  .entry {
    grid-template-columns: minmax(0, 1fr);
  }

  .when {
    white-space: normal;
    padding: 0 0 2px;
    font-size: 12px;
    letter-spacing: 0.04em;
  }

  .entries {
    gap: 24px;
  }

  .entries--tight {
    gap: 14px;
  }

  .title,
  .pub__title {
    font-size: 17px;
  }

  .reviews {
    columns: 1;
  }

  .filters {
    gap: 2px 18px;
    margin-bottom: 26px;
  }

  .part__note {
    margin-top: -4px;
  }

  .desk__foot {
    padding: 24px 22px calc(36px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 380px) {
  .tool__label {
    display: none;
  }

  .tool {
    width: 36px;
    padding: 0;
    justify-content: center;
    border-color: var(--rule-strong);
  }
}

@media (pointer: coarse) {
  .tool {
    height: 40px;
    min-width: 40px;
  }

  .home {
    width: 40px;
    height: 40px;
  }

  .filter {
    padding-top: 12px;
  }

  .contents__panel a {
    padding: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── Print: the page becomes the paper it imitates ──────────────
   The downloadable PDF is printed from this page (tools/build-pdf.mjs),
   so this block is the PDF's design: US Letter, a calm text block,
   dates in the margin, a running foot with the page number. */
.print-only {
  display: none;
}

@media print {
  @page {
    size: letter;
    margin: 0.85in 0.8in 0.9in;

    @bottom-left {
      content: "Md Dilshadur Rahman · Curriculum Vitae";
      font-family: 'Inter', 'Helvetica Neue', Arial, sans-serif;
      font-size: 7.5pt;
      letter-spacing: 0.02em;
      color: #77787C;
      vertical-align: top;
      padding-top: 0.28in;
    }

    @bottom-right {
      content: counter(page) " of " counter(pages);
      font-family: 'Inter', 'Helvetica Neue', Arial, sans-serif;
      font-size: 7.5pt;
      font-variant-numeric: tabular-nums;
      color: #77787C;
      vertical-align: top;
      padding-top: 0.28in;
    }
  }

  /* the first page carries the masthead instead of a running foot */
  @page :first {
    @bottom-left {
      content: none;
    }

    @bottom-right {
      content: none;
    }
  }

  :root,
  html[data-theme="dark"] {
    --paper: #FFFFFF;
    --desk: #FFFFFF;
    --ink: #17181B;
    --ink-2: #3A3C41;
    --ink-3: #6B6D72;
    --rule: #DEDBD3;
    --rule-strong: #C9C5BB;
    --accent: #24466F;
    --link-line: transparent;
    --gutter-w: 1.3in;
    --pad-x: 0px;
  }

  html {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  body {
    font-size: 10pt;
    line-height: 1.48;
    background: #FFFFFF;
  }

  p {
    orphans: 3;
    widows: 3;
  }

  .reader,
  .margin-toc,
  .filters,
  .part__note,
  .desk__foot,
  .skip-link,
  .pub__ext {
    display: none !important;
  }

  .print-only {
    display: inline;
  }

  .desk {
    padding: 0;
  }

  .sheet {
    max-width: none;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    animation: none !important;
  }

  .sheet::before {
    content: none;
  }

  /* links stay live in the PDF: navy, without underlines */
  .sheet a {
    color: var(--accent);
    text-decoration: none;
  }

  .sheet .title a,
  .detail a {
    color: inherit;
  }

  /* masthead */
  .masthead {
    padding-bottom: 16pt;
  }

  .masthead__kicker {
    margin-bottom: 10pt;
    font-size: 7.5pt;
    letter-spacing: 0.18em;
  }

  .masthead__name {
    font-size: 27pt;
    letter-spacing: -0.012em;
  }

  .masthead__role {
    margin-top: 5pt;
    font-size: 11.5pt;
  }

  .masthead__contact {
    margin-top: 11pt;
    font-size: 8.5pt;
  }

  .masthead__contact li:not(:last-child)::after {
    margin: 0 7pt;
  }

  .masthead__interests {
    max-width: none;
    margin-top: 9pt;
    font-size: 9.5pt;
  }

  .smallcaps {
    font-size: 7pt;
  }

  /* parts */
  .part {
    padding-top: 20pt;
  }

  .part__title {
    gap: 12pt;
    margin-bottom: 11pt;
    font-size: 7.5pt;
    letter-spacing: 0.18em;
  }

  .part__sub {
    margin: 13pt 0 7pt;
    font-size: 10.5pt;
  }

  .pub-group__title {
    margin: 13pt 0 7pt var(--gutter-w);
    font-size: 10.5pt;
  }

  .part__title + .part__sub {
    margin-top: 0;
  }

  .pub-group + .pub-group {
    margin-top: 14pt;
  }

  .entries {
    gap: 9pt;
  }

  .entries--tight {
    gap: 4.5pt;
  }

  .when {
    padding-right: 12pt;
    font-size: 7.75pt;
    line-height: 1.75;
  }

  .title,
  .pub__title {
    font-size: 10.75pt;
    line-height: 1.35;
  }

  .where,
  .detail,
  .pub__authors,
  .pub__venue,
  p.what,
  .reviews li {
    font-size: 9.5pt;
    line-height: 1.45;
  }

  .where {
    margin-top: 1pt;
  }

  .detail {
    margin-top: 1.5pt;
  }

  .pub__meta {
    margin-top: 2.5pt;
    font-size: 7.75pt;
  }

  .pub__meta > :not(:last-child)::after {
    margin: 0 6pt;
  }

  .kind {
    font-size: 7pt;
  }

  .reviews {
    column-gap: 24pt;
  }

  .reviews li {
    padding: 1.5pt 0;
  }

  .reviews span {
    font-size: 7.75pt;
  }

  .colophon {
    margin-top: 26pt;
    padding-top: 9pt;
    font-size: 7.5pt;
  }

  /* keep things whole across pages */
  .part__title,
  .part__sub,
  .pub-group__title {
    break-after: avoid;
    break-inside: avoid;
  }

  .pub-group__title + .entries > :first-child,
  .part__sub + .entries > :first-child,
  .part__title + .entries > :first-child {
    break-before: avoid;
  }

  .entry,
  .pub,
  .masthead,
  .colophon,
  .reviews {
    break-inside: avoid;
  }

  /* the running foot already names the document */
  .colophon > span:first-child {
    display: none;
  }

  .colophon {
    justify-content: flex-end;
  }
}
