/* Lecture decks: vellum pages set on the black sky, after the reader's print preview.
   Each slide is drawn at 1600 x 900 and scaled to fit by deck.js. */
@font-face { font-family: "IM Fell English SC"; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/fell-sc.woff2) format("woff2"); }

:root {
  --paper: #ece2cc; --ink: #1d1712; --rubric: #8e1f14;
  --ink-2: color-mix(in srgb, var(--ink) 62%, var(--paper));
  --book: "IM Fell English", Georgia, serif;
  --sc: "IM Fell English SC", "IM Fell English", Georgia, serif;
  --display: "Cinzel", Georgia, serif;
  --black: "UnifrakturCook", "IM Fell English", serif;
}
html, body { height: 100%; }
body { overflow: hidden; }
body.reading { overflow: auto; }

/* ------------------------------------------------------------ chrome */
.bar { position: fixed; z-index: 5; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 4px;
  padding: 8px 12px; background: linear-gradient(var(--ground) 60%, transparent); font-family: "IBM Plex Mono", monospace;
  font-size: 12px; letter-spacing: .12em; color: var(--bone-dim); transition: opacity .3s; }
body.idle:not(.reading) .bar { opacity: 0; pointer-events: none; }
.bar a, .bar button { color: var(--bone-dim); background: none; border: 1px solid transparent; font: inherit; font-size: 16px;
  min-width: 36px; height: 34px; cursor: pointer; text-decoration: none; display: inline-grid; place-items: center; }
.bar a:hover, .bar button:hover, .bar button[aria-pressed="true"] { color: var(--bone); border-color: var(--rule); background: var(--surface); }
.bar :focus-visible { outline: 2px solid var(--rust); outline-offset: 1px; }
.bar .name { text-transform: uppercase; margin-left: 6px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.bar .sp { flex: 1; }
.bar .count { min-width: 64px; text-align: center; }
@media (max-width: 520px) { .bar .name { display: none; } }

/* ------------------------------------------------------------ the deck */
.deck { height: 100%; display: grid; place-items: center; }
.frame { display: none; }
.frame.on { display: block; }
.stage { position: relative; }
.slide { position: absolute; top: 0; left: 0; width: 1600px; height: 900px; transform-origin: 0 0; transform: scale(var(--s, .5));
  background: var(--paper); color: var(--ink); font-family: var(--book); overflow: hidden;
  padding: 104px 132px 96px; display: flex; flex-direction: column;
  box-shadow: 0 40px 90px rgba(0,0,0,.75); -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.slide::before { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2;
  background:
    radial-gradient(ellipse at center, transparent 58%, rgba(40,25,10,.30) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .2 0 0 0 0 .1 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.rule { position: absolute; inset: 34px; border: 1.5px solid color-mix(in srgb, var(--ink) 45%, transparent); pointer-events: none; }
.rule::after { content: ""; position: absolute; inset: 6px; border: 1px solid color-mix(in srgb, var(--ink) 28%, transparent); }
.rh { position: absolute; top: 56px; left: 0; right: 0; text-align: center; font: 600 15px var(--display); letter-spacing: .4em; color: var(--ink-2); text-transform: uppercase; }
.folio { position: absolute; bottom: 50px; left: 0; right: 0; text-align: center; font: 22px var(--sc); color: var(--ink-2); letter-spacing: .1em; }
.folio::before, .folio::after { content: "◆"; font-size: 10px; vertical-align: 4px; margin: 0 16px; color: var(--rubric); }

.sec { font: 24px var(--sc); letter-spacing: .22em; color: var(--rubric); margin: 0 0 6px; }
.sec::before { content: "☞ "; letter-spacing: 0; }
h2 { font: 600 50px/1.12 var(--display); margin: 0 0 22px; letter-spacing: .03em; }
h2 em { font: italic 400 58px/1 var(--book); letter-spacing: 0; }
.body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 22px; justify-content: center; }
.body > .col { display: flex; flex-direction: column; gap: 22px; justify-content: center; min-width: 0; }
.slide:has(.side) .body { display: grid; grid-template-columns: 1fr 470px; gap: 64px; align-items: center; }
.side { display: flex; flex-direction: column; gap: 18px; justify-content: center; align-items: center; min-height: 0; height: 100%; }

p { margin: 0; }
.prose { font-size: 36px; line-height: 1.36; }
.prose.small { font-size: 28px; color: var(--ink-2); }
.drop::first-letter { font: 600 3.1em/.82 var(--display); float: left; padding: .06em .1em 0 0; color: var(--rubric); }
.big { font-size: 50px; line-height: 1.26; }
.lead { font: 30px/1.3 var(--book); font-style: italic; color: var(--ink-2); }
.cap { font: 24px var(--sc); letter-spacing: .18em; color: var(--rubric); }
.form { font-style: italic; color: var(--rubric); }
p.cel { font-size: 30px; line-height: 1.3; }
p.eng { font-size: 32px; line-height: 1.32; }
strong { font-weight: 400; color: var(--rubric); }
.orn { text-align: center; color: var(--rubric); font-size: 34px; line-height: 1; margin: -4px 0; }

.epi { margin: 0; padding: 0 0 0 34px; border-left: 3px solid var(--rubric); }
.epi p { font: italic 40px/1.34 var(--book); }
.epi cite { display: block; margin-top: 16px; font: 24px var(--sc); font-style: normal; letter-spacing: .14em; color: var(--ink-2); }
.epi cite::before { content: "— "; }
.l-epigraph .epi p { font-size: 50px; }

/* the three tongues, after the chapbook's own typefaces */
.rite { display: flex; flex-direction: column; gap: 4px; }
.ln { font-size: 34px; line-height: 1.32; }
.ln.old { font: 600 32px/1.4 var(--display); letter-spacing: .04em; color: var(--rubric); }
.ln.old-eng { font-size: 34px; color: var(--rubric); }
.ln.cel, .cel { letter-spacing: .07em; }
.ln.eng, .eng { font-style: italic; }
.ln.lc { font-size: 32px; padding-left: 26px; border-left: 2px solid var(--ink-2); color: var(--ink); }
.ln.role { font: 20px var(--sc); letter-spacing: .2em; color: var(--rubric); margin-top: 12px; }
.ln.role:first-child { margin-top: 0; }
.ln.dir { font-size: 26px; color: var(--ink-2); }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.l-rite .ln { font-size: 30px; }
.l-rite .ln.lc { font-size: 28px; }

/* pictures */
.fig { margin: 0; display: flex; flex-direction: column; gap: 8px; align-items: center; min-height: 0; max-height: 100%; }
.fig img { display: block; max-width: 100%; min-height: 0; object-fit: contain; }
.fig.photo img { max-height: 560px; border: 1px solid color-mix(in srgb, var(--ink) 55%, transparent); padding: 7px; background: color-mix(in srgb, var(--paper) 80%, #fff); box-shadow: 0 6px 18px rgba(40,25,10,.25); filter: sepia(.18); }
.fig.ms img { mix-blend-mode: multiply; filter: sepia(.35) contrast(1.06); }
.fig.page img { max-height: 600px; }
.fig.tall img { max-height: 620px; }
.fig.strip { width: 100%; }
.fig.strip img { max-height: 200px; width: auto; }
.srcs.n1 .fig.strip img { max-height: 175px; }
.src.wide .fig.strip img { max-height: 190px; }
.fig figcaption { font: 24px/1.3 var(--book); text-align: center; }
.credit { font: italic 15px/1.3 var(--book); color: var(--ink-2); text-align: center; max-width: 100%; }

/* title */
.l-title .body { align-items: center; text-align: center; gap: 18px; }
.l-title h1 { font: 700 150px/1 var(--black); color: var(--rubric); margin: 0; letter-spacing: 0; }
.l-title .sub { font: italic 40px/1.3 var(--book); max-width: 1100px; }
.l-title .by { font: 30px var(--sc); letter-spacing: .2em; color: var(--ink-2); }
.fig.seal img { height: 250px; }
.l-statement .body { text-align: center; align-items: center; padding: 0 40px; }
.l-statement .big { font-size: 58px; }
.l-statement .by { font: 44px var(--black); color: var(--rubric); margin-top: 20px; }
.l-epigraph .body { justify-content: center; }
.l-plate .body { align-items: center; }
.l-plate .fig img { height: 590px; max-height: none; width: auto; }

/* the cut-up: a rite line above the Claves it came from */
.l-cut .rite { text-align: center; }
.l-cut .ln { font-size: 40px; }
.srcs { display: grid; gap: 28px; }
.srcs.n2 { grid-template-columns: 1fr 1fr; }
.srcs.n3 { gap: 6px; }
.srcs.n3 .src { display: grid; grid-template-columns: 1.5fr 1fr; grid-template-rows: auto auto auto; column-gap: 34px; row-gap: 0; padding: 10px 0 8px; text-align: left; align-items: center; }
.srcs.n3 .src .fig { grid-row: 1 / 4; }
.srcs.n3 .src .fig img { max-height: 135px; }
.srcs.n3 .src .cel, .srcs.n3 .src .eng { font-size: 26px; }
.src { display: flex; flex-direction: column; gap: 6px; align-items: center; text-align: center; padding: 18px 16px 14px;
  border-top: 1px solid color-mix(in srgb, var(--ink) 35%, transparent); }
.src .cel { font-size: 28px; }
.src .eng { font-size: 28px; }
.srcs.n1 .src .cel, .srcs.n1 .src .eng { font-size: 34px; }
.src.wide { border: 0; padding: 0; }
.src.wide .cel { font-size: 28px; }
.src.wide .eng { font-size: 30px; line-height: 1.3; }

/* participants and stations */
.roles { display: grid; gap: 14px; }
.role-def { font-size: 27px; line-height: 1.3; }
.stations { display: grid; grid-template-columns: repeat(4, 1fr); gap: 34px; }
.st { display: flex; flex-direction: column; gap: 14px; padding-top: 18px; border-top: 2px solid var(--rubric); }
.st p { font-size: 27px; line-height: 1.32; }
.st .st-name { font: 600 32px var(--display); }
.st .st-name em { font-style: normal; }
.reading, .bib { display: grid; gap: 12px; }
.reading p { font-size: 28px; line-height: 1.3; }
.bib p { font-size: 28px; line-height: 1.3; }
.bib .cap { margin-top: 14px; }

/* Yuggothic */
.utter { display: grid; gap: 4px; }
.u-id { display: flex; gap: 18px; font: 18px "IBM Plex Mono", monospace; letter-spacing: .08em; color: var(--ink-2); }
.u-id span:first-child { color: var(--rubric); }
.u-y, .ow .u-y { font: italic 34px/1.3 var(--book); color: var(--rubric); }
.u-e { font-size: 30px; line-height: 1.3; }
.one-word .u-y { font-size: 30px; }
.one-word .u-e { font-size: 26px; }
.reuse { font-size: 22px; line-height: 1.3; color: var(--ink-2); padding-left: 18px; border-left: 2px solid color-mix(in srgb, var(--rubric) 50%, transparent); }
.gloss { border-collapse: collapse; width: 100%; }
.gloss td { padding: 7px 14px 7px 0; vertical-align: top; font-size: 23px; line-height: 1.28; border-bottom: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); }
.gloss .g-form { font: italic 28px var(--book); color: var(--rubric); white-space: nowrap; }
.gloss .g-id { font: 16px "IBM Plex Mono", monospace; color: var(--ink-2); white-space: nowrap; padding-right: 0; }
table:not(.gloss) { border-collapse: collapse; width: 100%; font-size: 27px; line-height: 1.3; }
table:not(.gloss) th { font: 20px var(--sc); letter-spacing: .16em; color: var(--rubric); text-align: left; padding: 6px 18px 8px 0; border-bottom: 1.5px solid var(--ink-2); font-weight: 400; }
table:not(.gloss) td { padding: 8px 18px 8px 0; border-bottom: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); vertical-align: top; }

.lineage { display: flex; flex-direction: column; gap: 46px; }
.chain { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr; align-items: stretch; gap: 14px; }
.arrow { align-self: center; font-size: 44px; color: var(--rubric); }
.node { display: flex; flex-direction: column; gap: 10px; padding: 18px 18px 16px; border: 1.5px solid color-mix(in srgb, var(--ink) 50%, transparent); background: color-mix(in srgb, var(--paper) 70%, #fff); }
.node.lc, .node.end { border-color: var(--rubric); border-width: 2px; }
.n-hand { font: 600 25px/1.2 var(--display); }
.n-what { font-size: 23px; line-height: 1.3; }
.n-line { font: italic 23px/1.3 var(--book); color: var(--rubric); }
.branches { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; padding: 0 12%; position: relative; }
.branches::before { content: ""; position: absolute; top: -46px; left: 30%; right: 30%; height: 30px; border: 1.5px dashed var(--ink-2); border-top: 0; }
.node.dim { opacity: .72; border-style: dashed; background: transparent; }
.one-word { display: grid; gap: 14px; }
.one-word > * { padding-left: 22px; border-left: 3px solid var(--rubric); }
.l-wide h2 .form { font-style: italic; }
.stats { display: grid; grid-template-columns: 1fr 1.6fr; gap: 60px; align-items: start; }
.stat b { display: block; font: 600 200px/1 var(--display); color: var(--rubric); }
.stat p { font-size: 32px; line-height: 1.3; margin-top: 10px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.dir { display: grid; gap: 8px; }
.dir p { font-size: 28px; line-height: 1.3; }
.dir-h { font-size: 34px !important; }
.rules { display: grid; gap: 26px; }
.rules p { font-size: 34px; line-height: 1.32; }

/* ------------------------------------------------------------ overview */
body.grid .deck { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; padding: 64px 16px 40px;
  height: auto; place-items: start stretch; }
body.grid { overflow: auto; }
body.grid .frame { display: block; cursor: pointer; outline: 1px solid var(--rule); }
body.grid .frame.on { outline: 3px solid var(--rust); }
body.grid .notes { display: none; }

/* ------------------------------------------------------------ reading view */
body.reading .deck { display: flex; flex-direction: column; align-items: center; gap: 0; height: auto; padding: 60px 16px 80px; }
body.reading .frame { display: block; width: min(100%, 1100px); }
.notes { display: none; }
body.reading .notes { display: block; color: var(--bone); font-size: 18px; line-height: 1.55; padding: 22px 4px 40px; }
body.reading .notes:empty { padding: 0 0 28px; }
.notes p, .p-notes p { margin: 0 0 .8em; }
.notes strong, .p-notes strong { color: var(--rust-bright); }
.notes .form, .p-notes .form { color: var(--gold); }

/* ------------------------------------------------------------ presenter window */
body.presenting .bar, body.presenting .deck { display: none; }
.presenter { position: fixed; inset: 0; display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) minmax(0, 1.4fr) auto; gap: 18px; padding: 18px; }
.presenter[hidden] { display: none; }
.p-now { grid-row: 1 / 3; position: relative; overflow: hidden; display: grid; place-items: center; }
.p-next { position: relative; opacity: .8; overflow: hidden; }
.p-now .frame, .p-next .frame { display: block; }
.p-notes { overflow: auto; color: var(--bone); font-size: 22px; line-height: 1.5; padding-right: 8px; }
.p-notes p { margin: 0 0 .8em; }
.p-notes strong { color: var(--rust-bright); }
.p-clock { grid-column: 1 / -1; display: flex; justify-content: space-between; font: 22px "IBM Plex Mono", monospace; color: var(--bone-dim); letter-spacing: .1em; }
.p-time { color: var(--bone); cursor: pointer; }
.black { position: fixed; inset: 0; background: #000; z-index: 9; }

/* ------------------------------------------------------------ print: one slide to a page */
@media print {
  @page { size: 1600px 900px; margin: 0; }
  html, body { height: auto; overflow: visible; background: #fff; }
  .bar, .presenter, .notes, .black { display: none !important; }
  .deck { display: block !important; padding: 0 !important; height: auto; }
  .frame { display: block !important; width: 1600px !important; break-after: page; outline: 0 !important; margin: 0 !important; }
  .stage { width: 1600px !important; height: 900px !important; }
  .slide { transform: none !important; box-shadow: none; }
}
