/* Re-templated pages on geser.net: his FrontPage/Dreamweaver markup rendered inside the shell of
   his front page. Loaded after _site.css (tokens --paper --ink --ink-soft --meta --rule --link
   --accent --measure --sans --grey). Everything is scoped under main.reader and touches
   presentation only - the text is his, untouched. build-reader.mjs copies this file to
   /_reader.css. Adapted 22.09.2026 from apps/socio-ch/src/styles/reader.css: Arial instead of
   the serif, bold black links as on his front page, headings in his weight. ASCII only. */

main.reader { padding: 0.5rem 0 1rem; }
main.reader > :first-child { margin-top: 0; }
main.reader > h1 {
  font-weight: 700; font-size: clamp(1.5rem, 4vw, 2rem); line-height: 1.2;
  margin: 0 0 1.25rem;
}

/* one face, one scale: <font face>, <font size>, Word's inline pt sizes and its colour
   attributes all go back to the shell's Arial and ink (Calibri, Arial Narrow, navy, #2F295A
   were his tints on white; the shell keeps the page light) */
main.reader font,
main.reader [style*="font-family"], main.reader [style*="font-size"], main.reader [style*="color"],
main.reader [face] {
  font-family: inherit !important; font-size: 1em !important; color: inherit !important;
}
main.reader font[size="1"], main.reader font[size="2"],
main.reader font[size="-1"], main.reader font[size="-2"] { font-size: 0.92em !important; }
main.reader font[size="4"], main.reader font[size="5"],
main.reader font[size="6"], main.reader font[size="7"],
main.reader font[size^="+"] { font-size: 1.15em !important; line-height: 1.3; font-weight: 700; }
main.reader :is(h1, h2, h3, h4, h5, h6, sup, sub) :is(font, span, a, b, i, u, em, strong, small)
  { font-size: inherit !important; }

/* text carriers: a measure and a line-height; his justified paragraphs read ragged-right here */
main.reader p, main.reader li, main.reader dd, main.reader dt, main.reader blockquote {
  max-width: var(--measure); line-height: 1.5; margin-top: 0; margin-bottom: 0.8em;
}
main.reader [align="justify"], main.reader [style*="justify"] { text-align: left !important; }
main.reader [align="center"], main.reader [style*="text-align: center"], main.reader [style*="text-align:center"]
  { text-align: left !important; }
main.reader p, main.reader div, main.reader ul, main.reader ol, main.reader dl, main.reader blockquote,
main.reader center, main.reader pre { width: auto !important; }
main.reader center { text-align: left; }
main.reader [style*="line-height"] { line-height: 1.5 !important; }
main.reader ul, main.reader ol { padding-left: 1.5em; }
main.reader blockquote { margin-left: 1em; margin-right: 0; }
main.reader pre { white-space: pre-wrap; }
main.reader [nowrap] { white-space: normal !important; }
main.reader h1, main.reader h2, main.reader h3, main.reader h4, main.reader h5, main.reader h6 {
  font-weight: 700; line-height: 1.25; margin: 1.5em 0 0.5em;
}
main.reader h1 { font-size: 1.6rem; }
main.reader h2 { font-size: 1.35rem; }
main.reader h3 { font-size: 1.15rem; }
main.reader h4, main.reader h5, main.reader h6 { font-size: 1rem; }
main.reader :is(h1, h2, h3, h4, h5, h6) font[size] { font-size: inherit !important; }
main.reader b, main.reader strong { font-weight: 700; }
main.reader i, main.reader em { font-style: italic; }
main.reader u { text-decoration: underline; }

/* Word's title classes, the roles they played, in the shell's scale */
main.reader .MsoTitle { font-size: 1.35em; font-weight: 700; line-height: 1.25; margin: 0 0 0.5em; }
main.reader .MsoSubtitle { font-size: 1.1em; color: var(--meta); margin: 0 0 1.25em; }
main.reader .MsoFootnoteText, main.reader .fussnoten { font-size: 0.9em; color: var(--ink-soft); }

/* tables. build-reader.mjs classifies every table (see classifyTable): layout tables
   (.tbl-layout - frames, sidebars, anything nesting tables or holding prose) stack into blocks in
   source order; data tables (.tbl-data - grids of short cells) keep their grid inside a scroll
   box; lists (.tbl-list, below) lose their grid. Borders, colours and cell heights of layout
   tables are dropped: they drew the old frame. Table rules ported 22.09.2026 from
   apps/socio-ch/src/styles/reader.css (keep the two in step; weights are 700 here). */
main.reader table { max-width: 100% !important; height: auto !important; margin: 1em 0; }
main.reader table[width], main.reader table[style*="width"] { width: auto !important; }
main.reader table.tbl-layout,
main.reader table.tbl-layout > :is(tbody, thead, tfoot),
main.reader table.tbl-layout > :is(tbody, thead, tfoot) > tr,
main.reader table.tbl-layout > :is(tbody, thead, tfoot) > tr > :is(td, th)
  { display: block; width: auto !important; height: auto !important; margin: 0; padding: 0; border: 0 !important; }
main.reader table.tbl-layout > tbody > tr > :is(td, th) { padding: 0.25em 0; }
/* hollow tables (build-reader.mjs isHollowTable: no letter or digit, no image, rule or control)
   were FrontPage spacers and dotted frames - nothing to show */
main.reader table.tbl-hollow { display: none; }
main.reader .table-scroll { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 1em 0; }
main.reader .table-scroll > table { border-collapse: collapse; margin: 0; }
main.reader .table-scroll td, main.reader .table-scroll th
  { padding: 0.3em 0.6em; vertical-align: top; overflow-wrap: break-word; font-size: 0.95em; border: 1px solid var(--rule); }
main.reader .table-scroll th { font-weight: 700; text-align: left; }

/* lists (.tbl-list - his publication and link lists, icon | author | title): no grid, one light
   rule under each row, the author column bold. The cell roles come from build-reader.mjs
   (markListCells): .cell-empty holds nothing, .cell-icon an image only, .cell-author the first
   worded cell of a row that has two (author | title). At phone width each row becomes a block,
   author above title; only cells without any text are hidden. */
main.reader table.tbl-list { border-collapse: collapse; border: 0 !important; width: 100% !important; }
main.reader table.tbl-list :is(td, th)
  { padding: 0.45em 0.6em 0.45em 0; height: auto !important; vertical-align: top; text-align: left;
    overflow-wrap: break-word; border: 0 !important; border-bottom: 1px solid var(--rule) !important; }
main.reader table.tbl-list :is(td, th):last-child { padding-right: 0; }
main.reader table.tbl-list tr:last-child > :is(td, th) { border-bottom: 0 !important; }
main.reader table.tbl-list .cell-author, main.reader table.tbl-list .cell-author a { font-weight: 700; }
main.reader table.tbl-list .cell-icon { border-bottom: 0 !important; }
main.reader table.tbl-list tr:not(:has(> :is(td, th):not(.cell-empty):not(.cell-icon))) > :is(td, th)
  { border-bottom: 0 !important; padding: 0; }
main.reader table.tbl-list .cell-icon p { margin: 0; }
main.reader table.tbl-list .cell-icon img { display: block; margin: 0.25em 1em 0.25em 0; max-width: 12rem; }
@media (max-width: 40em) {
  main.reader table.tbl-list,
  main.reader table.tbl-list > :is(tbody, thead, tfoot),
  main.reader table.tbl-list > :is(tbody, thead, tfoot) > tr,
  main.reader table.tbl-list > :is(tbody, thead, tfoot) > tr > :is(td, th)
    { display: block; width: auto !important; }
  main.reader table.tbl-list > :is(tbody, thead, tfoot) > tr
    { padding: 0.55em 0; border-bottom: 1px solid var(--rule); }
  main.reader table.tbl-list > :is(tbody, thead, tfoot) > tr:last-child { border-bottom: 0; }
  main.reader table.tbl-list :is(td, th) { padding: 0.1em 0 !important; border: 0 !important; }
  main.reader table.tbl-list .cell-empty { display: none; }
  main.reader table.tbl-list .cell-icon { display: inline-block; padding: 0 !important; }
  main.reader table.tbl-list .cell-icon p, main.reader table.tbl-list .cell-icon font { display: inline; }
  main.reader table.tbl-list .cell-icon img { display: inline-block; max-height: 3rem; width: auto; margin: 0 0.5em 0.25em 0; vertical-align: middle; }
  main.reader table.tbl-list .cell-author { display: block; }
  main.reader table.tbl-list > :is(tbody, thead, tfoot) > tr:not(:has(> :is(td, th):not(.cell-empty):not(.cell-icon)))
    { border-bottom: 0; padding: 0; }
}
main.reader * { background-image: none !important; background-color: transparent !important; }

/* images */
main.reader img { max-width: 100%; height: auto; }
main.reader img[align="left"] { margin: 0.25em 1em 0.5em 0; }
main.reader img[align="right"] { margin: 0.25em 0 0.5em 1em; }
main.reader img[hspace] { margin-left: 0; margin-right: 0.3em; }
main.reader img[width="1"], main.reader img[height="1"] { display: none; }

/* links: bold and black as on his front page, underlined on hover. In-page links are mostly his
   tables of contents here and look like any link; only footnote references (in a sup, or Word's
   _ftn/_edn anchors) go small and plain. */
main.reader a { color: var(--link); text-decoration: none !important; font-weight: 700; }
/* his lists print the URL as the link text: a long address may break anywhere, the page never
   scrolls sideways */
main.reader a, main.reader p, main.reader li, main.reader td, main.reader th { overflow-wrap: anywhere; }
main.reader a:hover { text-decoration: underline !important; }
main.reader sup a, main.reader a:has(sup), main.reader a:has(.MsoFootnoteReference),
main.reader a[href^="#_ftn"], main.reader a[href^="#_edn"] { font-size: 0.85em; font-weight: 400; color: var(--ink-soft); }
main.reader sup { line-height: 0; }
main.reader a[name]:target, main.reader [id]:target { scroll-margin-top: 1rem; }

/* rules */
main.reader hr { border: 0; border-top: 1px solid var(--rule); height: 0; margin: 1.5em 0; width: 100% !important; }

/* the colophon's original-page line sits with the takedown note */
footer.colophon p.original { color: var(--ink-soft); }

/* his style: colours come in as tokens on <html> (see build-reader.mjs); keep the page light,
   his tints were designed for a white screen. His link colour was black on every page. */
html.his-colours { color-scheme: light; }
/* the header graphics of the removed chrome (the SUZ header of his 2012 pages, the institute
   logo of the FrontPage include) sit above the name bar, as on his front page */
.chrome { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end; gap: 0.75rem 1.5rem; padding: 0.25rem 0 0.75rem; }
.chrome img { max-width: 100%; height: auto; display: block; }
.chrome img[width] { width: auto; max-height: 6rem; }

/* image QA 22.09.2026 (measured on 27 pages at 390/1100): a data grid squeezed his rowspan photo
   column to 24px, dead FrontPage counters showed a broken icon, 1-2px spacer gifs became squares */
main.reader .table-scroll img { max-width: min(100vw - 2.5rem, 40rem); }
main.reader img[src*="fpcount.exe"] { display: none; }
main.reader img[height="1"] { height: 1px; }
main.reader img[height="2"] { height: 2px; }
main.reader a { overflow-wrap: anywhere; }

/* publication years (build-reader.mjs markYears, data from tools/paper_years.py): a small grey
   year after a link to a dated paper on list pages - a real <span class="added year">, so the
   PDF glyph of _site.css keeps the link's own ::after and colour. */
main.reader .year { font-size: 0.8em; color: var(--meta); margin-left: 0.4em; white-space: nowrap; font-style: normal; font-weight: 400; }
main.reader a.a-empty::after, main.reader a.a-empty ::after { content: none !important; padding: 0 !important; margin: 0 !important; }
