/* Default style for larger screens */
body {
    max-width: 100ch;
    margin: 0 auto; /* Optional: centers the layout on desktop */

    font-family: 'Computer Modern Serif', serif;
    font-size: 17.5px;
}

/* Style for phones (screens smaller than 768px) */
@media (max-width: 768px) {
    body {
        max-width: 100%;
        padding: 0 1rem; /* Optional: adds a little breathing room on the edges */
    }
}

figure img, img.figure, img.small_figure {
    width: auto;
    height: auto;
    display: block;
    margin: 2em auto;
    max-width: 90%;
    max-height: 250px;
}

figcaption {
    margin: auto;
    margin-top: -0.5em;
    margin-bottom: 0em;
    width: 95%;
    text-align: center;
}

/* make solid line all the way across the screen */
hr {
  border: 0;
  border-top: 1px solid #000;   /* solid line */
  margin: 2rem 0;               /* spacing above/below */
  width: 100%;                  /* exactly the container/text width */
}

/* make solid line 600px long at most */
hr.hr-600 {
  width: 600px !important;
  margin: 2rem auto !important;   /* centers it */
  max-width: 100%;                /* don’t overflow on small screens */
}

/* Stop iOS from “inflating” text sizes */
html, body {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}



/* TOC matches body text size on large screens */
.toc {
  text-align: center;
  font-size: 1em;      /* same as body on large screens */
  margin: 0;
}

.toc-inner {
  display: inline-block;
  white-space: nowrap;
}

/* Only underline links, never the separators */
.toc a { text-decoration: underline; }
.toc .toc-sep { text-decoration: none !important; }




/* Make hash-jumps land with a little “air” above the heading text */
.toc-jump {
  display: block;
  height: 0;              /* no space in layout */
  scroll-margin-top: 2rem;  /* offset ONLY when jumped-to */
  visibility: hidden;
  pointer-events: none;
}



/* Make all links black by default */
a,
a:link,
a:visited {
  color: #000;
}
/* Turn purple on hover (and keyboard focus, which is nice) */
a:hover,
a:focus {
  color: rgb(170,13,255);
}
/* Optional: keep underline behavior consistent */
a { text-decoration: underline; }

