/* Global viewport polish (hidden native scrollbar gutter + overlay scroll thumb), unified centered dark pill nav (homepage + subpages) & single-row bottom footer. */
html {
  scrollbar-width: none;
}

html::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

/* Overlay scroll thumb (scroll-thumb.js): visible only while scrolling, near the right edge, or while dragged. */
.scroll-thumb {
  position: fixed;
  top: 0;
  right: 3px;
  width: 7px;
  z-index: 2147483000;
  border-radius: 999px;
  background: rgba(25, 35, 34, .52);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .6);
  opacity: 0;
  pointer-events: none;
  touch-action: none;
  cursor: default;
  transition: opacity .3s ease, width .15s ease, background-color .15s ease;
}

.scroll-thumb.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.scroll-thumb:hover,
.scroll-thumb.is-dragging {
  width: 10px;
  background: rgba(25, 35, 34, .72);
}

@media (prefers-reduced-motion: reduce) {
  .scroll-thumb { transition: none; }
}

/* Shared Floating Navigation Glass Pill (transparent->docked on homepage, permanently docked on subpages) */
.site-bar {
  --dock: 0;
}

.site-bar.is-docked {
  --dock: 1;
  position: absolute;
  top: 8px;
  left: 0;
  right: 0;
  margin-inline: auto;
  width: min(var(--measure, 74rem), calc(100% - 2 * var(--gutter, 1.25rem)));
  min-height: 3.5rem;
  padding: .5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 1000;
  isolation: isolate;
}

.site-bar:not(.is-docked)::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  opacity: clamp(0, calc(4 - 4 * var(--dock)), 1);
  height: 7.5rem;
  background: linear-gradient(to bottom, rgba(0, 0, 0, .52), rgba(0, 0, 0, .38) 46%, transparent);
  pointer-events: none;
  z-index: -1;
}

.site-bar > a:first-child {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* On white subpages, desktop shows only the centered dark pill; compact screens show the dark wordmark at top-left */
.site-bar.is-docked:not(.compact) > a:first-child,
.site-bar.is-docked .header-cta {
  visibility: hidden;
  pointer-events: none;
}

.site-bar .header-cta {
  min-height: 44px;
}

.site-bar:not(.compact) > nav[aria-label="Main navigation"] {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  left: 50%;
  top: calc(10px - 2px * var(--dock));
  transform: translateX(-50%);
  min-height: 3.4rem;
  padding: 0 1.05rem;
  color: #ffffff;
  isolation: isolate;
  gap: clamp(.85rem, 1.55vw, 1.45rem);
  font: 500 .96rem/1.3 'Figtree', system-ui, sans-serif;
}

.site-bar:not(.compact) > nav[aria-label="Main navigation"] a {
  color: #ffffff;
  text-decoration: none;
  white-space: nowrap;
}

.site-bar:not(.compact) > nav[aria-label="Main navigation"] a:hover {
  text-decoration: underline;
  text-underline-offset: .32em;
}

.site-bar:not(.compact) > nav[aria-label="Main navigation"]::before,
.site-bar.compact #menu::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 calc(-6.3rem * var(--dock));
  background: #162520;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 1rem;
  box-shadow: 0 6px 22px rgba(10, 23, 20, .2);
  opacity: var(--dock);
  pointer-events: none;
}

@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-bar:not(.compact) > nav[aria-label="Main navigation"]::before,
  .site-bar.compact #menu::before {
    background: rgba(18, 32, 28, .90);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }
}

.site-bar:not(.compact) > nav[aria-label="Main navigation"] > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.site-bar:not(.compact) > nav .nav-logo,
.site-bar:not(.compact) > nav .nav-cta {
  display: inline-flex;
  position: absolute;
  white-space: nowrap;
  opacity: clamp(0, calc(3 * var(--dock) - 2), 1);
}

.site-bar:not(.compact) > nav .nav-logo {
  right: 100%;
  padding: 0 .55rem;
}

.site-bar:not(.compact) > nav .nav-logo img {
  display: block;
  width: 5.1rem;
  height: auto;
}

.site-bar:not(.compact) > nav .nav-cta {
  left: 100%;
  min-height: 2.35rem;
  padding: .38rem .85rem;
  border-radius: .5rem;
  background: #ffffff;
  color: #192322 !important;
  font-weight: 600;
  font-size: .9rem;
  text-decoration: none !important;
}

.site-bar:not(.compact) > nav .nav-cta:hover {
  background: #eef3f0;
  text-decoration: none !important;
}

.site-bar nav a[aria-current=location]:not(.nav-cta),
.site-bar nav a[aria-current=page]:not(.nav-cta) {
  text-decoration: underline;
  text-underline-offset: .36em;
}

/* Compact mobile menu surface (identical across homepage and subpages) */
.menu-title,
.site-bar #menu,
.site-bar nav[hidden],
#mobile-links[hidden] { display: none; }

.site-bar.compact > nav:not(#mobile-links),
.site-bar.compact .header-cta { display: none; }
.site-bar.compact { max-width: calc(100% - 1.5rem); }
.site-bar.compact > a:first-child img { display: block; width: 7.5rem; max-width: min(7.5rem, 42vw); height: auto; }

.site-bar.compact .bar-actions {
  position: fixed;
  inset: 14px clamp(12px, 5vw, 24px) auto auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  isolation: isolate;
  z-index: 3;
}

.site-bar.compact #menu {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  align-self: flex-end;
  width: calc(48px + 23px * var(--dock));
  height: 48px;
  padding: 10px 10px 10px calc(10px + 23px * var(--dock));
  border: 0;
  background: none;
  color: #ffffff;
  isolation: isolate;
  cursor: pointer;
}

.site-bar.compact #menu span {
  display: block;
  width: 20px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
}

.site-bar.compact #menu::before {
  inset: 0;
  border-radius: 14px;
}

.site-bar.compact #menu .menu-chip {
  display: block;
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  opacity: var(--dock);
  pointer-events: none;
}

.site-bar.compact .bar-actions:has(#menu[aria-expanded=true]) {
  width: min(15.5rem, calc(100vw - 2rem));
  max-height: calc(100svh - 28px);
  overflow-y: auto;
  border-radius: 14px;
  background: #192622;
  color: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2), 0 10px 30px rgba(10, 22, 18, .28);
}

@supports (backdrop-filter: blur(1px)) {
  .site-bar.compact .bar-actions:has(#menu[aria-expanded=true]) {
    background: rgba(22, 37, 32, .96);
    backdrop-filter: blur(14px);
  }
}

.site-bar.compact .bar-actions #menu[aria-expanded=true] {
  width: 100%;
  min-height: 48px;
  padding: 0;
  color: #ffffff;
  flex-shrink: 0;
}

.site-bar.compact #menu[aria-expanded=true]::before { display: none; }
.site-bar.compact #menu[aria-expanded=true] .menu-chip { opacity: 1; left: 14px; }
.site-bar.compact #menu[aria-expanded=true] .menu-title {
  display: block;
  position: absolute;
  left: 44px;
  font: 600 1rem/1.2 'Figtree', system-ui, sans-serif;
}
.site-bar.compact #menu[aria-expanded=true] span { position: absolute; right: 16px; top: 23px; width: 18px; }
.site-bar.compact #menu[aria-expanded=true] span:nth-last-child(3) { transform: rotate(45deg); }
.site-bar.compact #menu[aria-expanded=true] span:nth-last-child(2) { opacity: 0; }
.site-bar.compact #menu[aria-expanded=true] span:last-child { transform: rotate(-45deg); }

.site-bar.compact .bar-actions #mobile-links:not([hidden]) {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: .3rem .55rem .55rem;
  border-top: 1px solid rgba(255, 255, 255, .18);
  color: #ffffff;
}

.site-bar.compact #mobile-links a {
  display: flex;
  align-items: center;
  padding: .5rem .85rem;
  min-height: 44px;
  color: #ffffff;
  border-radius: 8px;
  font-weight: 500;
  text-decoration: none;
}

.site-bar.compact #mobile-links a:hover,
.site-bar.compact #mobile-links a[aria-current=location],
.site-bar.compact #mobile-links a[aria-current=page] {
  background: rgba(255, 255, 255, .12);
}

.site-bar.compact #mobile-links .menu-cta {
  justify-content: center;
  color: #192322;
  background: #ffffff;
  font-weight: 600;
  margin-top: .35rem;
}

/* Mobile native role picker */
#people .role-picker { display: none; }
@media (max-width: 42em) {
  #people .role-options { display: none; }
  #people .role-picker {
    display: grid;
    grid-area: choices;
    gap: .35rem;
    font-size: .92rem;
    font-weight: 600;
  }
  #people .role-picker select {
    appearance: auto;
    min-height: 46px;
    width: 100%;
    border: 1px solid #76847e;
    background: #ffffff;
    color: #192322;
    border-radius: 8px;
    padding: .55rem .8rem;
    font: 400 1rem/1.4 'Figtree', system-ui, sans-serif;
  }
  #people .role-layout {
    grid-template-areas: "choices" "details" "photo";
    grid-template-rows: auto auto auto;
    gap: 1rem;
  }
  #people #role-panel { min-height: 0 !important; }
  #people #role-photo { aspect-ratio: 16 / 9; }
}

@media (min-width: 51em) and (max-width: 63em) {
  #people .role-layout {
    grid-template-areas: "choices choices" "photo details";
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
    grid-template-rows: auto auto;
  }
}

/* Unified 4-Column Site Footer + Single-Row Bottom Bar across all pages */
.site-foot {
  background: #f4f6f4;
  border-top: 1px solid #dce2de;
  padding: clamp(2.75rem, 5vw, 3.75rem) 0 1.65rem;
  color: #192322;
  font: 400 .94rem/1.55 'Figtree', system-ui, sans-serif;
}

.site-foot > .wrap {
  width: min(var(--measure, 74rem), calc(100% - 2 * var(--gutter, 1.25rem)));
  margin-inline: auto;
}

.foot-grid {
  display: grid;
  grid-template-columns: 1.65fr repeat(3, minmax(0, 1fr));
  gap: 2rem 2.25rem;
  align-items: start;
}

.foot-grid > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .5rem;
}

.identity img {
  display: block;
  width: 8.25rem;
  height: auto;
}

.identity p {
  margin: .55rem 0 0;
  color: #36443f;
  font-size: .96rem;
  max-width: 28ch;
}

.identity-loc {
  font-size: .86rem;
  color: #525e59;
  margin-top: .1rem;
}

.foot-grid h3 {
  margin: 0 0 .35rem;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .045em;
  text-transform: uppercase;
  color: #525e59;
}

.foot-grid a {
  color: #192322;
  text-decoration: none;
  line-height: 1.45;
}

.foot-grid a:hover {
  text-decoration: underline;
  text-underline-offset: .22em;
}

.site-foot .footer-social {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
}

.site-foot .footer-social svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: #36443f;
}

/* Single horizontal bottom row: Copyright + PRR emblem strip + GreenAI eSports PDF chip */
.foot-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.75rem;
  margin-top: 2.25rem;
  padding-top: 1.35rem;
  border-top: 1px solid #dce2de;
}

.foot-copy {
  font-size: .86rem;
  color: #525e59;
  white-space: nowrap;
}

.funding-link {
  display: block;
  width: clamp(14rem, 23vw, 19.5rem);
  border-radius: 6px;
}

.funding-link img.funding {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  transition: opacity .16s ease;
}

.funding-link:hover img.funding {
  opacity: .86;
}

.prr-sheet-link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  min-height: 36px;
  padding: .36rem .78rem;
  border: 1px solid #cfd8d3;
  border-radius: 999px;
  background: #ffffff;
  color: #36443f;
  font-size: .8rem;
  font-weight: 500;
  line-height: 1.25;
  text-decoration: none !important;
  transition: border-color .15s ease, color .15s ease, box-shadow .15s ease;
}

.prr-sheet-link:hover {
  border-color: #8c9a93;
  color: #192322;
  box-shadow: 0 2px 8px rgba(25, 35, 34, .06);
  text-decoration: none !important;
}

.prr-badge {
  display: inline-block;
  padding: .15rem .42rem;
  border-radius: 999px;
  background: #eef2ef;
  color: #36443f;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .03em;
}

.prr-ext {
  font-size: .8rem;
  color: #6b7873;
}

@media (max-width: 860px) {
  .foot-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.65rem 1.5rem;
  }
  .foot-grid > .identity {
    grid-column: 1 / -1;
    padding-bottom: .35rem;
  }
  .foot-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: .95rem;
  }
}

@media (max-width: 540px) {
  .foot-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (prefers-reduced-transparency: reduce) {
  .site-bar nav::before,
  .site-bar.compact #menu::before {
    background: #162520 !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-bar *, .site-bar *::before {
    animation: none !important;
    transition: none !important;
  }
}
