/* The site navigation bar that public/nav.js builds. Colours from art's palette
   (public/art/palette.json). */
.site-nav {
  flex: none;
  background: #181425;
  border-bottom: 1px solid #3a4466;
  font:
    14px/1.4 system-ui,
    sans-serif;
}
.site-nav ul {
  list-style: none;
  margin: 0 auto;
  max-width: 1240px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  align-items: center;
  padding-block: 10px;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.site-nav li + li::before {
  content: "";
  display: inline-block;
  width: 1px;
  height: 14px;
  margin: 0 12px;
  vertical-align: -2px;
  background: #3a4466;
}
/* In the row, art's one-line logo at the left, a gap rather than a line before the links. */
.site-nav:not(.slim) .site-nav-logo {
  margin-right: 16px;
}
.site-nav .site-nav-logo + li::before {
  display: none;
}
/* Below 380px the logo gap and separators use 8px margins; navigation links may wrap. */
@media (max-width: 379.98px) {
  .site-nav:not(.slim) .site-nav-logo {
    margin-right: 8px;
  }
  .site-nav li + li::before {
    margin: 0 8px;
  }
}
.site-nav a {
  color: #c0cbdc;
  text-decoration: none;
}
.site-nav a:hover {
  color: #feae34;
}
/* The current page: a yellow face with plum text, ringed in amber and lifted onto a plum
   shadow. */
.site-nav a[aria-current="page"] {
  position: relative;
  top: -2px;
  padding: 1px 6px;
  color: #3e2731;
  background: #fee761;
  border: 1px solid #181425;
  font-weight: 700;
  box-shadow:
    0 0 0 2px #feae34,
    0 0 0 3px #181425,
    0 2px 0 3px #3e2731;
}
.site-nav a:focus-visible {
  outline: 2px solid #feae34;
  outline-offset: 2px;
}
/* On /play/, a narrow column down the left side, so the game keeps the full height and the rest
   of the width. Its width includes the left safe-area inset. */
.site-nav.slim {
  box-sizing: border-box;
  width: calc(64px + env(safe-area-inset-left, 0px));
  border-bottom: 0;
  border-right: 1px solid #3a4466;
  font-size: 13px;
  line-height: 1;
}
/* The padding holds the current page's lift and ring inside the column. */
.site-nav.slim ul {
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 16px;
  padding: 14px 0 0 env(safe-area-inset-left, 0px);
  white-space: nowrap;
}
.site-nav.slim li + li::before {
  display: none;
}
.site-nav.slim a:focus-visible {
  outline-offset: -2px;
}
/* Art's logo, at 1x at the row's left or the column's top: art/README.md, Logo. */
.site-logo img {
  display: block;
  image-rendering: pixelated;
}

/* The homepage's pale canvas uses quiet navigation without changing the game page. */
.home .site-nav {
  background: transparent;
  border-bottom-color: #8b9bb4;
}
.home .site-nav a {
  color: #181425;
}
.home .site-nav a:hover {
  color: #3a4466;
  text-decoration: underline;
  text-underline-offset: 5px;
}
.home .site-nav a[aria-current="page"] {
  top: 0;
  padding: 0;
  color: #181425;
  background: none;
  border: 0;
  box-shadow: none;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}
.home .site-nav a:focus-visible {
  outline-color: #3a4466;
  outline-offset: 4px;
}
