/* The Nexus dropdown in the top bar. Shared by every page (both page styles); js/nav.js opens it on click and keyboard. */
.nav-links .has-sub { position: relative; }
.sub-btn { font: inherit; font-size: .95rem; color: var(--text-2); background: none; border: 0; padding: 0; margin: 0; cursor: pointer; display: inline-flex; align-items: center; gap: .35rem; line-height: inherit; }
.sub-btn:hover, .has-sub.open > .sub-btn, .has-sub.in > .sub-btn { color: var(--text); }
.has-sub.in > .sub-btn { box-shadow: 0 2px 0 var(--ember); }
.sub-btn:focus-visible { outline: 2px solid var(--ember); outline-offset: 4px; border-radius: 4px; }
.sub-btn .chev { width: 12px; height: 12px; transition: transform .2s; }
.has-sub.open > .sub-btn .chev { transform: rotate(180deg); }
.nav-links .sub { list-style: none; margin: 0; position: absolute; top: calc(100% + 14px); left: -14px; min-width: 210px; padding: 8px; background: var(--surface); border: 1px solid var(--line-2); border-radius: 12px; box-shadow: 0 24px 60px rgba(0,0,0,.55); display: none; flex-direction: column; gap: 0; z-index: 120; }
.nav-links .sub::before { content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; }
.nav-links .sub a { display: block; padding: .6rem .8rem; border-radius: 8px; color: var(--text-2); white-space: nowrap; box-shadow: none; text-decoration: none; }
.nav-links .sub a:hover, .nav-links .sub a:focus-visible { background: rgba(255,157,26,.09); color: var(--text); }
.nav-links .sub a[aria-current] { color: var(--ember); box-shadow: none; }
.has-sub.open > .sub { display: flex; }
html.no-js .has-sub:focus-within > .sub { display: flex; }
@media (hover: hover) and (min-width: 821px) { .has-sub:hover > .sub { display: flex; } }

@media (max-width: 820px) {
  .nav-links { max-height: calc(100vh - 72px); overflow-y: auto; }
  .nav-links .has-sub { width: 100%; }
  .sub-btn { width: 100%; padding: .8rem 0 .4rem; cursor: default; color: var(--text-3); font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; }
  .sub-btn:hover, .has-sub.in > .sub-btn { color: var(--text-3); box-shadow: none; }
  .sub-btn .chev { display: none; }
  .nav-links .sub, .has-sub.open > .sub { display: flex; position: static; min-width: 0; padding: 0 0 0 14px; background: none; border: 0; border-radius: 0; box-shadow: none; }
  .nav-links .sub::before { display: none; }
  .nav-links .sub a { border-radius: 0; white-space: normal; }
  .nav-links .sub a:hover, .nav-links .sub a:focus-visible { background: none; }
  .nav-links .sub li:last-child { padding-top: 0; }
  html.no-js .nav-links .has-sub { width: auto; }
}
