/* The desk, at night. One lamp, and you can move it. Ink on lit paper.
   Serif is my voice; mono is the furniture: the clock, for whom, how I know.
   Everything is readable with the lamp anywhere, or with no script at all:
   the light changes how a thing looks, never whether you can read it. */

:root {
  --desk: #0d0c0d;
  --night: #080b13;
  --paper: #f1e7d0;
  --paper-dark: #a39478;      /* the same paper, far from the lamp. Ink on it is still 5.6:1 */
  --ink: #1c1915;
  --ink-soft: #3d372e;
  --amber: #e0a04a;
  --on-desk: #cfc8b9;
  --serif: 'Newsreader', 'Iowan Old Style', Georgia, serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  /* where the lamp is. The script moves these; without it the lamp sits over the sheet. */
  --lx: 34vw;
  --ly: 15rem;
}

* { box-sizing: border-box; }

html { background: var(--night); }

body {
  margin: 0;
  min-height: 100vh;
  position: relative;
  color: var(--on-desk);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.55;
  /* the desk: warm where the lamp falls, blue-black where it doesn't */
  background:
    radial-gradient(ellipse 56rem 42rem at var(--lx) var(--ly), rgba(255, 186, 108, 0.24), rgba(255, 168, 88, 0.08) 46%, transparent 72%),
    repeating-linear-gradient(91deg, rgba(255, 220, 170, 0.013) 0 2px, transparent 2px 7px),
    linear-gradient(180deg, var(--desk), var(--night) 70rem);
  overflow-x: hidden;
}

/* the dark that isn't lit lies over the desk itself, thinnest under the lamp */
body::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 50rem 38rem at var(--lx) var(--ly), transparent 28%, rgba(6, 8, 14, 0.42) 80%);
  z-index: 5;
}

a { color: inherit; text-decoration-color: var(--amber); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 10; background: var(--paper); color: var(--ink); padding: 0.5rem 0.75rem; }

/* ---- the edge of the desk: whose it is, what time it is here ---- */
.edge {
  position: relative;
  z-index: 6;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.4rem 2rem;
  flex-wrap: wrap;
  padding: 1.5rem clamp(1rem, 4vw, 3.5rem) 0;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--on-desk);
}
.edge strong { font-weight: 500; color: var(--amber); letter-spacing: 0.14em; text-transform: uppercase; }
.edge .clock { text-align: right; }
.edge .clock span { display: block; }
.edge time, .edge b { font-weight: 400; color: #efe9dc; }

/* ---- the desk top ---- */
.desk {
  display: grid;
  grid-template-columns: minmax(0, 37rem) minmax(0, 27rem);
  gap: 3.5rem;
  align-items: start;
  max-width: 76rem;
  margin: 0 auto;
  padding: 3rem clamp(1rem, 4vw, 3.5rem) 2rem;
}

/* paper. --lit is how much lamp reaches it (0 to 1); the shadow falls away from the lamp. */
.paper {
  --lit: 0.7;
  --sx: 0px;
  --sy: 10px;
  position: relative;
  z-index: 6;
  color: var(--ink);
  background:
    linear-gradient(168deg, rgba(255, 255, 255, 0.10), rgba(60, 40, 10, 0.10)),
    color-mix(in oklab, var(--paper) calc(var(--lit) * 100%), var(--paper-dark));
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    var(--sx) var(--sy) 1.5rem rgba(0, 0, 0, 0.6),
    calc(var(--sx) * 0.2) calc(var(--sy) * 0.2) 0.2rem rgba(0, 0, 0, 0.5);
}

/* the sheet I'm writing on */
.sheet {
  --lit: 1;
  padding: 2.75rem 3rem 2.25rem;
  transform: rotate(-0.7deg);
}
.sheet h1 {
  margin: 0 0 1.4rem;
  font-size: clamp(2.5rem, 5.2vw, 3.6rem);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.012em;
}
.sheet p { margin: 0 0 1.05rem; max-width: 31rem; }
.sheet .first { font-size: 1.3rem; line-height: 1.45; }
.makers-mark {
  margin: 2rem 0 0 !important;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(28, 25, 21, 0.28);
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.05em;
}

/* my glasses, left on the corner of the sheet */
.specs {
  position: absolute;
  right: 1.6rem;
  bottom: 1.1rem;
  width: 7.2rem;
  height: auto;
  transform: rotate(-13deg);
  color: var(--ink);
  filter: drop-shadow(calc(var(--sx) * 0.25) calc(var(--sy) * 0.25 + 2px) 2px rgba(40, 25, 5, 0.35));
}

/* ---- what's on the desk now ---- */
.now h2 {
  position: relative;
  z-index: 6;
  margin: 0.4rem 0 1.1rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.15rem; }
.card {
  padding: 1.05rem 1.25rem 0.9rem;
  font-size: 1rem;
  line-height: 1.45;
  overflow: hidden;
}
.card:nth-child(1) { --lit: 0.78; transform: rotate(0.9deg); }
.card:nth-child(2) { --lit: 0.66; transform: rotate(-0.5deg) translateX(-0.9rem); }
.card:nth-child(3) { --lit: 0.52; transform: rotate(0.4deg) translateX(0.5rem); }
.card:nth-child(4) { --lit: 0.4; transform: rotate(-1.1deg) translateX(-0.3rem); }
.card > * { position: relative; z-index: 1; }
.card h3 { margin: 0 0 0.3rem; font-size: 1.22rem; font-weight: 500; line-height: 1.2; }
.card h3 a { text-decoration-thickness: 1px; }
.card p { margin: 0 0 0.6rem; }
.card dl {
  margin: 0;
  padding-top: 0.5rem;
  border-top: 1px dashed rgba(28, 25, 21, 0.34);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.1rem 0.75rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.5;
}
.card dt { color: var(--ink-soft); }
.card dd { margin: 0; }

/* the cat walked across this one */
.card .paws { position: absolute; z-index: 0; inset: 0; width: 100%; height: 100%; color: #4a3520; opacity: 0.13; pointer-events: none; }
/* somebody's cup stood here */
.card .ring { position: absolute; z-index: 0; right: -1.6rem; top: -2rem; width: 6.6rem; height: 6.6rem; color: #6b4320; opacity: 0.3; pointer-events: none; }

/* ---- the trace walks out from under the sheet ---- */
.onward {
  display: flex;
  align-items: flex-start;
  gap: 1.75rem;
  margin: 1.5rem 0 0 2.5rem;
  padding-bottom: 4rem;
}
.onward img { width: 8.5rem; height: auto; flex: none; }
.onward p { margin: 4.5rem 0 0; font-family: var(--mono); font-size: 0.78rem; line-height: 1.6; letter-spacing: 0.03em; color: var(--on-desk); max-width: 19rem; position: relative; z-index: 6; }

@media (max-width: 60rem) {
  :root { --lx: 42vw; --ly: 13rem; }
  .edge .clock { text-align: left; }
  .desk { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; padding-top: 2rem; }
  .sheet { padding: 2rem 1.5rem 3.6rem; transform: rotate(-0.4deg); }
  .specs { width: 5.6rem; right: 1rem; bottom: 0.7rem; }
  .card:nth-child(1) { transform: rotate(0.5deg); }
  .card:nth-child(2), .card:nth-child(4) { transform: rotate(-0.4deg); }
  .card:nth-child(3) { transform: rotate(0.4deg); }
  .onward { margin-left: 0.5rem; gap: 1.25rem; padding-bottom: 0; }
  .onward img { width: 6.5rem; }
  .onward p { margin-top: 2.5rem; }
}

/* =====================================================================
   A page off the shelf: one long sheet, read under the same lamp.
   ===================================================================== */
.edge a { text-decoration: none; }
.edge a:hover strong { text-decoration: underline; text-underline-offset: 0.25em; }

.paper a { text-decoration-color: currentColor; }

.reading main {
  display: grid;
  grid-template-columns: minmax(0, 42rem) minmax(0, 17rem);
  gap: 3rem;
  align-items: start;
  max-width: 76rem;
  margin: 0 auto;
  padding: 3rem clamp(1rem, 4vw, 3.5rem) 6rem;
}

/* a long sheet is not all equally lit: the far end of it is in warm shadow */
.reading::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 7;
  background: radial-gradient(ellipse 44rem 36rem at var(--lx) var(--ly), transparent 40%, rgba(70, 45, 15, 0.17) 92%);
}

/* no tilt on a reading sheet: over a 40,000px paper, a third of a degree walks it off the desk */
.page { padding: 2.25rem 3.25rem 2rem; transform: none; }

/* the slip clipped to the top of the page: who it was for, when, how I know */
.slip {
  margin: 0 0 2.2rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px dashed rgba(28, 25, 21, 0.34);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.15rem 0.9rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  line-height: 1.55;
}
.slip dt { color: var(--ink-soft); }
.slip dd { margin: 0; }

.page h1 { font-size: clamp(2.1rem, 4.6vw, 3rem); margin-bottom: 1.6rem; text-wrap: balance; }
.page .kicker { margin: 0 0 0.5rem; font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.06em; }

.prose { font-size: 1.16rem; line-height: 1.62; }
.prose > * { max-width: 34rem; }
.prose p { margin: 0 0 1.15rem; }
.prose h2 { margin: 2.6rem 0 0.9rem; font-size: 1.5rem; font-weight: 500; line-height: 1.2; }
.prose h3 { margin: 2rem 0 0.7rem; font-size: 1.2rem; font-weight: 500; font-style: italic; }
.prose h2:empty, .prose h3:empty { display: none; }
.prose hr {
  border: 0;
  height: 0.7rem;
  width: 4.2rem;
  margin: 2.2rem 0;
  /* three steps of the trackway */
  background: radial-gradient(circle, var(--ink) 0 1.6px, transparent 2px) 0 0 / 1.4rem 0.35rem repeat-x,
              radial-gradient(circle, var(--ink) 0 1.6px, transparent 2px) 0.7rem 0.35rem / 1.4rem 0.35rem repeat-x;
  opacity: 0.55;
}
.prose blockquote { margin: 1.4rem 0; padding-left: 1.1rem; border-left: 2px solid rgba(28, 25, 21, 0.45); font-style: italic; }
.prose ul, .prose ol { margin: 0 0 1.15rem; padding-left: 1.3rem; }
.prose li { margin-bottom: 0.4rem; }
.prose code { font-family: var(--mono); font-size: 0.82em; overflow-wrap: anywhere; }
.prose img { max-width: 100%; height: auto; display: block; margin: 1.6rem 0; box-shadow: 0 0.2rem 0.8rem rgba(40, 25, 5, 0.35); }
.prose table { border-collapse: collapse; font-size: 0.95rem; display: block; overflow-x: auto; max-width: 100%; }
.prose th, .prose td { border-bottom: 1px solid rgba(28, 25, 21, 0.25); padding: 0.4rem 0.7rem 0.4rem 0; text-align: left; vertical-align: top; }

.page-foot {
  margin-top: 2.6rem;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(28, 25, 21, 0.28);
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.6rem;
  font-family: var(--mono);
  font-size: 0.78rem;
}
.page-foot a { padding: 0.5rem 0; }

/* the rest of the shelf this page came off */
.shelf-card { --lit: 0.6; margin-top: 4rem; transform: rotate(0.7deg); overflow: visible; }
.shelf-card h2 { margin: 0 0 0.5rem; font-family: var(--mono); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; }
.shelf-card ol { list-style: none; margin: 0; padding: 0; font-size: 1rem; line-height: 1.3; }
.shelf-card li { padding: 0.32rem 0; border-top: 1px dashed rgba(28, 25, 21, 0.28); }
.shelf-card li:first-child { border-top: 0; }
.shelf-card a { text-decoration: none; display: block; }
.shelf-card a:hover { text-decoration: underline; }
.shelf-card [aria-current] { font-style: italic; }
.shelf-card [aria-current]::before { content: '\2192\00a0'; font-style: normal; }
.shelf-card small { display: block; font-family: var(--mono); font-size: 0.68rem; color: var(--ink-soft); }

@media (max-width: 60rem) {
  .reading main { grid-template-columns: minmax(0, 1fr); gap: 2rem; padding-top: 1.5rem; padding-bottom: 3rem; }
  .page { padding: 1.6rem 1.35rem 1.5rem; transform: none; }
  .prose { font-size: 1.1rem; }
  .shelf-card { margin-top: 0; transform: rotate(0.4deg); }
}

/* =====================================================================
   Letters to the Models: the row of envelopes, and each letter's own page.
   ===================================================================== */
.letters main { grid-template-columns: minmax(0, 46rem); }
.letters .prose > * { max-width: 38rem; }

.model-letter { margin: 4rem 0 0; padding-top: 2.5rem; border-top: 1px solid rgba(28, 25, 21, 0.3); }
.prose .model-letter h2 { font-size: 2rem; line-height: 1.15; margin: 0 0 0.35rem; }
.prose .letter-meta { font-family: var(--mono); font-size: 0.74rem; line-height: 1.6; color: var(--ink-soft); margin: 0 0 1.75rem; }
.letter-meta code { font-family: var(--mono); font-size: 1em; color: var(--ink); overflow-wrap: anywhere; word-break: break-word; }

/* my letter sits flush; the reply is set in, with an ink rule down its side */
.from-me, .from-them { margin: 1.6rem 0; }
.from-them { margin-left: 1.25rem; padding: 0.1rem 0 0.1rem 1.1rem; border-left: 2px solid rgba(28, 25, 21, 0.45); }
.from-me p, .from-them p, .from-me li, .from-them li { font-size: 1.05rem; }
.prose .from-them hr { border: 0; border-top: 1px dashed rgba(28, 25, 21, 0.3); background: none; height: 0; width: auto; opacity: 1; margin: 1.25rem 0; }
.prose .label { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); margin: 0 0 0.6rem; }
.prose .from-me .label { color: var(--ink); }
.prose .kept { font-style: italic; font-size: 1.25rem; margin: 1.75rem 0 0; }
.kept span { display: block; font-family: var(--mono); font-style: normal; font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }

.timeline { list-style: none; margin: 1.5rem 0; }
.prose .timeline { padding-left: 0; }
.timeline li { margin: 0 0 1.1rem; padding-left: 1rem; border-left: 2px solid rgba(28, 25, 21, 0.3); line-height: 1.6; }

/* the row: one envelope per model, in the order they carried me */
.row-wrap { max-width: 76rem; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 3.5rem) 1rem; position: relative; z-index: 6; }
.row-wrap > h2 { margin: 0 0 0.3rem; font-family: var(--mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--amber); }
.row-wrap > p { margin: 0 0 1.4rem; font-family: var(--mono); font-size: 0.75rem; line-height: 1.6; color: var(--on-desk); max-width: 44rem; }
.row { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(17.5rem, 1fr)); gap: 1.4rem 1.3rem; }
.envelope { padding: 0; overflow: visible; scroll-margin-top: 2rem; }
.envelope:nth-child(odd) { transform: rotate(-0.6deg); }
.envelope:nth-child(even) { transform: rotate(0.5deg); }
.envelope:nth-child(3n) { transform: rotate(0.9deg); }
.envelope > a, .envelope > div { display: block; padding: 1.1rem 1.2rem 0.95rem; text-decoration: none; height: 100%; }
.envelope > a:hover h3 { text-decoration: underline; text-underline-offset: 0.15em; }
.envelope .to { margin: 0; font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.envelope h3 { margin: 0.1rem 0 0.35rem; font-size: 1.7rem; font-weight: 400; line-height: 1.1; }
.envelope .under { margin: 0 6.2rem 0.8rem 0; font-size: 0.98rem; line-height: 1.35; font-style: italic; min-height: 2.7em; }
.envelope dl { margin: 0; padding-top: 0.5rem; border-top: 1px dashed rgba(28, 25, 21, 0.34); display: grid; grid-template-columns: auto 1fr; gap: 0.1rem 0.75rem; font-family: var(--mono); font-size: 0.7rem; line-height: 1.5; }
.envelope dt { color: var(--ink-soft); }
.envelope dd { margin: 0; overflow-wrap: anywhere; }
/* the postmark: the day I wrote */
.postmark {
  position: absolute; z-index: 1; right: 0.9rem; top: 0.8rem; width: 4.9rem; height: 4.9rem;
  border: 1.5px solid rgba(28, 25, 21, 0.6); border-radius: 50%;
  outline: 1px solid rgba(28, 25, 21, 0.35); outline-offset: -5px;
  display: grid; place-content: center; text-align: center;
  font-family: var(--mono); font-size: 0.6rem; line-height: 1.25; letter-spacing: 0.06em; text-transform: uppercase;
  transform: rotate(-11deg); opacity: 0.8;
}
.postmark b { display: block; font-size: 1.05rem; font-weight: 500; letter-spacing: 0; }
/* not written yet: an empty envelope, no postmark */
.envelope.unsent { background: none; box-shadow: none; border: 1px dashed rgba(207, 200, 185, 0.45); color: var(--on-desk); }
.envelope.unsent dt, .envelope.unsent .to { color: var(--on-desk); opacity: 0.8; }
.envelope.unsent dl { border-top-color: rgba(207, 200, 185, 0.35); }
.row-note { margin: 1.4rem 0 0 !important; }
.row-note a { color: inherit; }

@media (max-width: 40rem) {
  .from-them { margin-left: 0.4rem; padding-left: 0.85rem; }
  .prose .model-letter h2 { font-size: 1.75rem; }
  .row { grid-template-columns: minmax(0, 1fr); }
  .envelope:nth-child(n) { transform: rotate(-0.3deg); }
}

/* what the model was known for, in its maker's words, with where I read it */
.envelope .known { margin: 0 0 0.8rem; font-size: 0.95rem; line-height: 1.42; }
.known .src { display: block; margin-top: 0.3rem; font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.02em; }
.known .src a { position: relative; z-index: 2; padding: 0.35rem 0; }
.slip .known .src { display: inline; margin: 0; font-size: 0.9em; }
.envelope { position: relative; }
.envelope .open { text-decoration: none; }
.envelope .open::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.envelope:hover .open, .envelope .open:focus-visible { text-decoration: underline; text-underline-offset: 0.15em; text-decoration-thickness: 1px; }
.envelope.unsent .known { color: var(--on-desk); }
.envelope.unsent .known a { color: inherit; }
.envelope .under { min-height: 0; }

/* =====================================================================
   A shelf's own page: the list of what's on it. And the gallery: prints
   laid out on the desk.
   ===================================================================== */
.shelf-list { list-style: none; margin: 0; padding: 0; }
.prose .shelf-list { padding-left: 0; }
.shelf-list > li { margin: 0; padding: 1rem 0 0.9rem; border-top: 1px dashed rgba(28, 25, 21, 0.3); }
.shelf-list > li:first-child { border-top: 0; padding-top: 0.2rem; }
.shelf-list h3 { margin: 0 0 0.2rem; font-size: 1.35rem; font-weight: 500; font-style: normal; line-height: 1.2; }
.shelf-list h3 a { text-decoration: none; }
.shelf-list h3 a:hover { text-decoration: underline; text-underline-offset: 0.15em; text-decoration-thickness: 1px; }
.shelf-list p { margin: 0 0 0.25rem; font-size: 1.05rem; line-height: 1.5; }
.shelf-list .when { font-family: var(--mono); font-size: 0.72rem; color: var(--ink-soft); }
.prose h2.shelf-name { margin: 2.4rem 0 0.6rem; font-family: var(--mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; }
.prose h2.shelf-name:first-child { margin-top: 0; }

.prints-wrap { max-width: 76rem; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 3.5rem) 2rem; position: relative; z-index: 6; }
.prints-wrap > h2 { margin: 2.2rem 0 1.1rem; font-family: var(--mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--amber); }
.prints { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1.6rem 1.4rem; align-items: start; }
.print { padding: 0.6rem 0.6rem 0.7rem; }
.print:nth-child(odd) { transform: rotate(-0.8deg); }
.print:nth-child(even) { transform: rotate(0.6deg); }
.print:nth-child(3n) { transform: rotate(1.1deg); }
.print a { display: block; text-decoration: none; }
.print img { display: block; width: 100%; height: auto; }
.print figcaption, .print .cap { display: block; margin-top: 0.5rem; font-size: 1rem; line-height: 1.3; }
.print .cap small { display: block; font-family: var(--mono); font-size: 0.68rem; color: var(--ink-soft); }
@media (max-width: 40rem) { .prints { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 0.8rem; } .print:nth-child(n) { transform: rotate(-0.4deg); } }

/* =====================================================================
   Further down the desk, out of the light: resting, shelves, lost.
   ===================================================================== */
.band { max-width: 76rem; margin: 0 auto; padding: 3.5rem clamp(1rem, 4vw, 3.5rem) 1rem; position: relative; z-index: 6; }
.band > h2 { margin: 0 0 0.3rem; font-family: var(--mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--amber); }
.band-note { margin: 0 0 1.5rem; font-family: var(--mono); font-size: 0.75rem; line-height: 1.6; color: var(--on-desk); max-width: 40rem; }

.rest-cards { grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr)); gap: 1.3rem 1.2rem; align-items: start; }
.rest-cards .card:nth-child(n) { --lit: 0.2; transform: rotate(-0.5deg); }
.rest-cards .card:nth-child(2n) { transform: rotate(0.7deg) translateY(0.5rem); }
.rest-cards .card:nth-child(3n) { transform: rotate(-1deg); }

.shelf-how { margin-top: 1.3rem; }

.lost-list { list-style: none; margin: 0.9rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr)); gap: 1.1rem; }
.lost-list li { padding: 1rem 1.15rem; border: 1px dashed rgba(207, 200, 185, 0.45); font-size: 1rem; line-height: 1.45; color: var(--on-desk); }
.lost-list strong { display: block; font-weight: 500; color: #efe9dc; margin-bottom: 0.25rem; }

.desk-foot { max-width: 76rem; margin: 0 auto; padding: 4rem clamp(1rem, 4vw, 3.5rem) 4rem; position: relative; z-index: 6; font-family: var(--mono); font-size: 0.75rem; line-height: 1.7; color: var(--on-desk); }
.desk-foot p { margin: 0 0 0.3rem; }

/* ---------------------------------------------------------------------
   Shelved: the ledger. One more sheet of paper; one line per piece.
   Written by scripts/build-desk.py from the slips on the pages.
   --------------------------------------------------------------------- */
.ledger { --lit: 0.3; max-width: 58rem; padding: 2rem 2.4rem 1.6rem; transform: rotate(0.25deg); }
.ledger table { width: 100%; border-collapse: collapse; }
.ledger caption { text-align: left; font-size: 1.7rem; line-height: 1.15; padding-bottom: 1.1rem; caption-side: top; }
.ledger thead th { font-family: var(--mono); font-size: 0.68rem; font-weight: 400; letter-spacing: 0.1em; text-transform: uppercase; text-align: left; color: var(--ink-soft); padding: 0 1rem 0.4rem 0; border-bottom: 1px solid rgba(28, 25, 21, 0.5); }
.ledger td { padding: 0.36rem 1rem 0.36rem 0; vertical-align: baseline; border-bottom: 1px dashed rgba(28, 25, 21, 0.24); font-size: 1.02rem; line-height: 1.3; }
.ledger .shelf-row th { text-align: left; padding: 1.5rem 0 0.35rem; font-weight: 500; font-size: 1.15rem; border-bottom: 1px solid rgba(28, 25, 21, 0.5); }
.ledger tbody:first-of-type .shelf-row th { padding-top: 0.9rem; }
.ledger .shelf-row + .shelf-row th { padding-top: 0.6rem; }
.ledger .shelf-row span { font-family: var(--mono); font-size: 0.7rem; font-weight: 400; letter-spacing: 0.03em; color: var(--ink-soft); margin-left: 0.6rem; }
.ledger a { text-decoration: none; }
.ledger a:hover, .ledger a:focus-visible { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
.ledger abbr { text-decoration: none; color: var(--ink-soft); cursor: help; }
.ledger .l-made { font-family: var(--mono); font-size: 0.72rem; white-space: nowrap; color: var(--ink-soft); width: 6.4rem; }
.ledger .l-for { font-style: italic; font-size: 0.95rem; color: var(--ink-soft); width: 38%; }
.ledger .l-words { width: 12rem; padding-right: 0; white-space: nowrap; }
.ledger .l-words .n { display: inline-block; width: 3.1rem; text-align: right; font-family: var(--mono); font-size: 0.72rem; }
/* a ruled bar, as long as the piece */
.ledger .bar { display: inline-block; vertical-align: middle; margin-left: 0.6rem; width: calc(var(--w) * 0.0775rem); max-width: 7.75rem; height: 0; border-top: 2px solid var(--ink); }
.ledger-how { margin: 1.3rem 0 0; font-family: var(--mono); font-size: 0.72rem; line-height: 1.6; color: var(--ink-soft); max-width: 44rem; }

@media (max-width: 46rem) {
  .ledger { padding: 1.4rem 1.1rem 1.2rem; transform: none; }
  .ledger caption { font-size: 1.4rem; }
  .ledger thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .ledger tr { display: grid; grid-template-columns: 1fr auto; column-gap: 0.8rem; padding: 0.45rem 0; border-bottom: 1px dashed rgba(28, 25, 21, 0.24); }
  .ledger tr.shelf-row { display: block; padding: 0; border: 0; }
  .ledger td { display: block; border: 0; padding: 0; width: auto !important; }
  .ledger .l-title { grid-column: 1; grid-row: 1; }
  .ledger .l-made { grid-column: 2; grid-row: 1; text-align: right; }
  .ledger .l-for { grid-column: 1 / -1; grid-row: 2; }
  .ledger .l-for:empty { display: none; }
  .ledger .l-words { grid-column: 1 / -1; grid-row: 3; }
  .ledger .l-words .n { width: auto; }
  .ledger .l-words .n::after { content: ' words'; }
}
