:root {
  --paper: #f7f8fc;
  --surface: #ffffff;
  --ink: #171a1f;
  --muted: #5d6471;
  --rule: #d9dee8;
  --accent: #4256c7;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "STIX Two Text", "Iowan Old Style", Georgia, serif;
  font-size: 18px;
  line-height: 1.62;
}
a { color: var(--accent); text-underline-offset: 0.18em; }
a:focus-visible { outline: 3px solid rgba(23,143,145,.4); outline-offset: 4px; }
.reader-nav {
  position: sticky;
  z-index: 10;
  top: 0;
  display: flex;
  min-height: 60px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 max(20px, calc((100vw - 980px) / 2));
  border-bottom: 1px solid var(--rule);
  background: rgba(247,248,252,.94);
  backdrop-filter: blur(12px);
  font-family: "IBM Plex Sans", Arial, sans-serif;
  font-size: 13px;
}
.reader-wordmark { color: var(--ink); font-weight: 600; text-decoration: none; }
.reader-wordmark span { margin-left: 8px; font-weight: 400; }
.reader-links { display: flex; gap: 18px; }
.reader-links a { color: var(--muted); text-decoration: none; }
.reader-shell { width: min(calc(100% - 40px), 980px); margin: 0 auto; }
.reader-title { max-width: 820px; padding: 80px 0 48px; }
.reader-label {
  margin: 0 0 18px;
  color: var(--accent);
  font-family: "IBM Plex Mono", Menlo, monospace;
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.reader-title h1 { margin: 0; font-size: clamp(2.1rem, 5vw, 3.25rem); font-weight: 500; letter-spacing: -.03em; line-height: 1.06; }
.reader-author, .reader-date { margin: 20px 0 0; color: var(--muted); font-family: "IBM Plex Sans", Arial, sans-serif; font-size: 14px; }
.reader-date { margin-top: 2px; }
.reader-toc { margin-bottom: 52px; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.reader-toc summary { cursor: pointer; padding: 14px 0; color: var(--accent); font-family: "IBM Plex Mono", Menlo, monospace; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.reader-toc nav { padding: 0 0 22px; columns: 2; column-gap: 48px; }
.reader-toc ul { margin: 0; padding-left: 22px; }
.reader-toc a { color: var(--muted); font-size: 14px; text-decoration: none; }
.paper-body { max-width: 760px; padding-bottom: 110px; }
.paper-body h1, .paper-body header { display: none; }
.paper-body h2 { margin: 3.3em 0 .75em; font-size: 1.82rem; font-weight: 500; letter-spacing: -.02em; line-height: 1.15; }
.paper-body h3 { margin: 2.35em 0 .6em; font-size: 1.35rem; font-weight: 500; line-height: 1.2; }
.paper-body h4 { margin: 2em 0 .5em; font-size: 1.08rem; }
.paper-body p { margin: 0 0 1.15em; }
.paper-body blockquote { margin: 1.8em 0; padding: 0 0 0 20px; border-left: 3px solid var(--accent); color: var(--muted); }
.paper-body table { display: block; width: 100%; margin: 2em 0; overflow-x: auto; border-collapse: collapse; font-family: "IBM Plex Sans", Arial, sans-serif; font-size: 14px; }
.paper-body th, .paper-body td { padding: 9px 12px; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; }
.paper-body pre { max-width: 100%; overflow-x: auto; padding: 16px; background: #eef1f8; font-size: 14px; }
.paper-body code { font-family: "IBM Plex Mono", Menlo, monospace; }
.paper-body math[display="block"] { display: block; max-width: 100%; margin: 1.5em 0; overflow-x: auto; overflow-y: hidden; padding: 6px 2px; }
.paper-body figure { margin: 2em 0; }
.paper-body img, .paper-body svg { max-width: 100%; height: auto; }
.paper-body .proof { padding-left: 18px; border-left: 1px solid var(--rule); }
.paper-body ol, .paper-body ul { padding-left: 1.4em; }

/* LaTeXML web edition */
.ltx_page_main,
.ltx_page_content {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  background: transparent;
}

.ltx_document {
  width: min(calc(100% - 40px), 780px);
  max-width: 780px;
  margin: 0 auto;
  padding: 74px 0 110px;
  background: transparent;
}

.ltx_title_document {
  max-width: 760px;
  margin: 0 0 22px;
  font-size: clamp(2rem, 5vw, 2.85rem);
  font-weight: 500;
  letter-spacing: -.035em;
  line-height: 1.08;
  text-align: left;
}

.ltx_authors,
.ltx_dates {
  margin: 0;
  color: var(--muted);
  font-family: "IBM Plex Sans", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  text-align: left;
}

.ltx_dates { margin-top: 5px; }

.ltx_abstract {
  margin: 42px 0 36px;
  padding: 24px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.ltx_title_abstract,
.ltx_title_contents {
  margin: 0 0 12px;
  color: var(--accent);
  font-family: "IBM Plex Mono", Menlo, monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.ltx_abstract .ltx_p { margin: 0; color: #343944; font-size: 16px; line-height: 1.58; }
.ltx_TOC { margin: 0 0 64px; padding: 0 0 28px; border-bottom: 1px solid var(--rule); }
.ltx_TOC .ltx_toclist { margin: 0; padding-left: 20px; }
.ltx_TOC .ltx_toclist_section { margin-top: 4px; }
.ltx_TOC .ltx_tocentry { margin: 4px 0; }
.ltx_TOC a { color: var(--muted); font-family: "IBM Plex Sans", Arial, sans-serif; font-size: 13px; text-decoration: none; }
.ltx_TOC a:hover { color: var(--accent); }

.ltx_document .ltx_section { margin-top: 0; }
.ltx_document .ltx_title_section {
  margin: 3.2em 0 .72em;
  font-size: 1.78rem;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.18;
  text-align: left;
}
.ltx_document .ltx_title_subsection {
  margin: 2.25em 0 .58em;
  font-size: 1.32rem;
  font-weight: 500;
  line-height: 1.22;
  text-align: left;
}
.ltx_document .ltx_title_subsubsection { margin: 2em 0 .5em; font-size: 1.08rem; text-align: left; }
.ltx_document .ltx_p { margin: 0 0 1.12em; text-align: left; }
.ltx_document .ltx_theorem,
.ltx_document .ltx_proof {
  margin: 1.7em 0;
  padding: 2px 0 2px 20px;
  border-left: 2px solid var(--rule);
}
.ltx_document .ltx_theorem .ltx_title { font-weight: 600; }
.ltx_document .ltx_proof { border-left-width: 1px; }
.ltx_document .ltx_equation,
.ltx_document .ltx_eqn_table,
.ltx_document math[display="block"] {
  display: block;
  max-width: 100%;
  margin: 1.35em 0;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 7px 2px;
}
.ltx_document table:not(.ltx_eqn_table) {
  display: block;
  max-width: 100%;
  margin: 1.8em 0;
  overflow-x: auto;
  border-collapse: collapse;
  font-family: "IBM Plex Sans", Arial, sans-serif;
  font-size: 14px;
}
.ltx_document th,
.ltx_document td { padding: 8px 11px; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; }
.ltx_document pre { max-width: 100%; overflow-x: auto; padding: 16px; background: #eef1f8; font-size: 14px; }
.ltx_document code { font-family: "IBM Plex Mono", Menlo, monospace; }
.ltx_document img,
.ltx_document svg { max-width: 100%; height: auto; }
.ltx_document .ltx_figure {
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  contain: inline-size layout paint;
}
/* LaTeXML's TikZ SVGs omit a viewBox. Keep their intrinsic coordinate width
   inside the scrollable figure instead of shrinking only the SVG viewport. */
.ltx_document svg.ltx_picture { max-width: none; }
.ltx_document ol,
.ltx_document ul { padding-left: 1.4em; }

@media (max-width: 640px) {
  body { font-size: 17px; }
  .reader-nav { padding: 0 14px; }
  .reader-wordmark span { display: none; }
  .reader-shell { width: min(calc(100% - 28px), 980px); }
  .reader-title { padding-top: 58px; }
  .reader-title h1 { font-size: clamp(2rem, 10vw, 2.7rem); }
  .reader-toc nav { columns: 1; }
  .paper-body h2 { font-size: 1.55rem; }
  .ltx_document { width: min(calc(100% - 28px), 780px); padding-top: 54px; }
  .ltx_title_document { font-size: clamp(1.85rem, 8.4vw, 2.3rem); }
  .ltx_document .ltx_title_section { font-size: 1.52rem; }
  .ltx_TOC .ltx_toclist_section { display: none; }
  .ltx_document .ltx_itemize .ltx_item,
  .ltx_document .ltx_enumerate .ltx_item { white-space: normal; }
  .ltx_document .ltx_item .ltx_tag + .ltx_para {
    display: block;
    max-width: 100%;
  }
}

@media print {
  .reader-nav, .reader-toc, .ltx_TOC { display: none; }
  body { background: white; }
  .reader-shell { width: auto; }
  .ltx_document { width: auto; max-width: none; padding: 0; }
}
