/* Any .css file in _static/ is loaded automatically by Jupyter Book.
   Add small tweaks here rather than editing the theme. */

/* Slightly smaller text in the (wide) schedule table */
table.table td, table.table th {
  font-size: 0.92rem;
}

/* Make the "Homepage" link at the top of the sidebar look like the section headings
   (Course Info, Lectures): same weight and colour, flush left instead of indented. */
nav.bd-links .bd-sidenav__home-link li > a {
  font-weight: var(--pst-sidebar-header-font-weight);
  color: var(--pst-color-text-base);
  /* keep the text aligned with the headings, but leave room so the blue "current page"
     bar sits in the gutter to the left of the text instead of touching it */
  margin-left: -0.65rem;
  padding-left: 0.65rem;
}

/* Phone sidebars (the slide-in panels). The browser's default <dialog> styles set margin:auto
   with both top and bottom pinned, so the theme's 100vh-tall panel gets centred vertically.
   On iPhones 100vh is taller than the visible screen, which pushes the top of the panel (and
   its "Contents" heading) off screen. Pin each panel to the top, size it to the visible
   viewport, and anchor it to its own side (navigation left, contents right). */
@media (max-width: 1199.98px) {
  dialog#pst-primary-sidebar-modal[open],
  dialog#pst-secondary-sidebar-modal[open] {
    top: 0;
    bottom: auto;
    margin-top: 0;
    margin-bottom: 0;
    height: 100vh;      /* fallback for old browsers */
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
  }
  dialog#pst-primary-sidebar-modal[open] {
    left: 0;
    right: auto;
    margin-left: 0;
    margin-right: auto;
  }
  dialog#pst-secondary-sidebar-modal[open] {
    right: 0;
    left: auto;
    margin-right: 0;
    margin-left: auto;
  }
}