/* nav.css — one slice of the site stylesheet, split by concern.
   Load order is fixed in base.html and mirrors the old single-file
   source order; do not reorder the <link> tags. tokens.css holds
   every colour and must load first. */
/*********************************************************************


                            Navigation in header


**********************************************************************/
.navbar {
  /* Bootstrap gives the navbar a 20px bottom margin, which stacks with
     .topspace on the first row and leaves a 60px void under a full-width
     band. The band sets its own rhythm; the gap belongs to .topspace. */
  margin-bottom: 0;
  border-width: 1px 0;
  -webkit-border-radius: 0;
  -webkit-background-clip: padding-box;
  -moz-border-radius: 0;
  -moz-background-clip: padding;
  border-radius: 0;
  background-clip: padding-box;
  width: 100%;
}
.navbar.stick {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1030;
  background-color: var(--bg-translucent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.navbar-collapse {
  -webkit-border-radius: 0;
  -webkit-background-clip: padding-box;
  -moz-border-radius: 0;
  -moz-background-clip: padding;
  border-radius: 0;
  background-clip: padding-box;
  /* No uppercase and no 300 weight: neither survives a handwriting face —
     caps read as shouting in a hand, and the light weight gets synthesised. */
  font-family: var(--font-hand-display);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: 0.02em;
}
.navbar-collapse .navbar-nav {
  float: none;
  margin: 0 auto;
  text-align: center;
}
.navbar-collapse .navbar-nav > li {
  float: none;
  display: inline-block;
}
.navbar-collapse .navbar-nav > li > a {
  padding: 15px 30px;
}
.navbar-collapse .navbar-nav > li > a > i {
  margin-right: 6px;
}
.dropdown ul.dropdown-menu {
  top: 85%;
  text-align: left;
}
.dropdown ul.dropdown-menu > li > a {
  padding: 5px 30px;
}
.navbar-default {
  background-color: var(--bg-translucent);
  border-color: var(--border);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.navbar-default .navbar-nav > li > a {
  color: var(--text);
}
.navbar-default .navbar-nav > li > a:hover,
.navbar-default .navbar-nav > li > a:focus {
  color: var(--accent-hover);
  background-color: transparent;
  box-shadow: inset 0 -3px 0 var(--accent-line);
}
.navbar-default .navbar-nav > .active > a,
.navbar-default .navbar-nav > .active > a:hover,
.navbar-default .navbar-nav > .active > a:focus {
  color: var(--accent);
  font-weight: 700;
  background-color: transparent;
  box-shadow: inset 0 -3px 0 var(--accent);
}
.navbar-default .dropdown ul.dropdown-menu > li > a {
  color: var(--text);
}
.navbar-default .dropdown ul.dropdown-menu > li > a:hover {
  background-color: var(--bg-elev-2);
  color: var(--text-strong);
}
.navbar-default .navbar-toggle {
  border-color: var(--border);
}
.navbar-default .navbar-toggle:hover,
.navbar-default .navbar-toggle:focus {
  background-color: var(--bg-elev-2);
}
.navbar-default .navbar-toggle .icon-bar {
  background-color: var(--text);
}
.navbar-default .navbar-collapse,
.navbar-default .navbar-form {
  border-color: var(--border);
}
.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .open > a:hover,
.navbar-default .navbar-nav > .open > a:focus {
  background-color: var(--bg-elev);
  color: var(--text-strong);
}
/* Phones
/////////////////////////////////////////////////////////////////////*/
/* There is no bar on a phone. The band, its borders and its background are
   all dropped and the navbar becomes a fixed, transparent layer holding one
   button in the top-left corner; the menu opens as a panel floating over the
   page rather than pushing it down. Taking the navbar out of flow is what
   removes the strip — the header now runs to the top of the screen. */
@media (max-width: 767px) {
.navbar.navbar-sticky,
  .navbar.navbar-sticky.stick {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1040;
    min-height: 0;
    margin: 0;
    background: transparent;
    border: 0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
.navbar-sticky .container-fluid {
    padding: 0;
  }
  /* Bootstrap pulls .navbar-header 15px outward inside a container-fluid to
     cancel that container's padding. The padding is gone, so the pull has to
     go too or the button hangs off the left edge of the screen. */
.navbar-sticky .container-fluid > .navbar-header {
    display: flex;
    align-items: center;
    margin-right: 0;
    margin-left: 0;
  }
  /* The button is the only thing left over the cover, so it carries its own
     translucent ground — a bare icon on the artwork would be unreadable. */
.navbar-default .navbar-toggle {
    float: none;
    margin: 10px 0 10px 10px;
    padding: 9px 10px;
    border-radius: 8px;
    border-color: var(--border);
    background-color: var(--bg-translucent);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
.navbar-default .navbar-toggle:hover,
  .navbar-default .navbar-toggle:focus {
    background-color: var(--bg-elev-2);
  }
  /* The dropdown: a panel hung off the button, not a full-width tray. It is
     translucent over whatever it covers, so the page reads through it. */
.navbar-collapse#site-nav {
    position: absolute;
    top: 100%;
    left: 10px;
    width: 232px;
    max-height: none;
    margin: 0;
    padding: 4px 0;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-translucent);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    box-shadow: none;
    overflow: hidden;
  }
  /* Stacked rows, not centred inline items: a menu that drops down wants to
     read as a list, and the active marker moves from an underline to a rule
     down the left edge, which is where the eye is in a vertical list. */
.navbar-collapse .navbar-nav {
    text-align: left;
    margin: 0;
  }
.navbar-collapse .navbar-nav > li {
    display: block;
  }
.navbar-collapse .navbar-nav > li > a {
    padding: 12px 16px;
  }
.navbar-collapse .navbar-nav > li + li > a {
    border-top: 1px solid var(--border);
  }
.navbar-collapse .navbar-nav > li > a > i {
    display: inline-block;
    width: 22px;
    margin-right: 8px;
    text-align: center;
  }
.navbar-default .navbar-nav > li > a:hover,
  .navbar-default .navbar-nav > li > a:focus {
    box-shadow: none;
    background-color: var(--bg-elev);
  }
.navbar-default .navbar-nav > .active > a,
  .navbar-default .navbar-nav > .active > a:hover,
  .navbar-default .navbar-nav > .active > a:focus {
    box-shadow: inset 3px 0 0 var(--accent);
    background-color: var(--bg-elev);
  }
}
/* Tablets: six items at the desktop 30px gutter wrap onto a second row, which
   reads as a mistake rather than a menu. Tighten the gutter instead. */
@media (min-width: 768px) and (max-width: 991px) {
  .navbar-collapse .navbar-nav > li > a {
    padding: 18px 13px;
  }
  .navbar-collapse {
    font-size: 19px;
  }
}
