/* Shared primary navigation for the homepage and all completed interior pages. */
.global-site-nav {
  position: sticky;
  z-index: 80;
  top: 0;
  display: block;
  min-height: 78px;
  color: #f4efe4;
  background: rgba(7, 10, 8, .96) !important;
  border-bottom: 1px solid rgba(244, 239, 228, .11) !important;
  backdrop-filter: blur(18px) !important;
  -webkit-backdrop-filter: blur(18px) !important;
}

.global-nav-inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  width: min(calc(100% - 64px), 1440px);
  min-height: 78px;
  margin-inline: auto;
  gap: clamp(18px, 2.4vw, 38px);
}

.global-wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  flex-shrink: 0;
  color: #f4efe4;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -.025em;
}

.global-wordmark:hover { color: #f4efe4; }

.global-wordmark .logo-dot,
.global-wordmark #nav-logo-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #caff4d;
}

.global-nav-desktop {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  gap: clamp(6px, 1.25vw, 22px);
}

.global-nav-group { position: relative; }
.global-nav-group > summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 9px;
  color: rgba(244, 239, 228, .72);
  font-family: 'Instrument Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  list-style: none;
  transition: color 180ms ease;
}

.global-nav-group > summary::-webkit-details-marker,
.global-nav-mobile > summary::-webkit-details-marker,
.global-mobile-section > summary::-webkit-details-marker { display: none; }

.global-nav-group > summary::marker,
.global-nav-mobile > summary::marker,
.global-mobile-section > summary::marker { content: ''; }

.global-nav-group > summary:hover,
.global-nav-group[open] > summary,
.global-nav-group:has([aria-current='page']) > summary { color: #f4efe4; }

.global-nav-chevron {
  width: 8px;
  height: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 180ms ease;
}

.global-nav-group[open] > summary .global-nav-chevron,
.global-mobile-section[open] > summary .global-nav-chevron {
  transform: translateY(2px) rotate(225deg);
}

.global-nav-dropdown {
  position: absolute;
  top: calc(100% + 7px);
  left: 50%;
  display: grid;
  min-width: 244px;
  padding: 10px;
  background: #171c18;
  border: 1px solid rgba(244, 239, 228, .14);
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .42);
  transform: translateX(-50%);
}

.global-nav-group-research .global-nav-dropdown { min-width: 258px; }

.global-nav-dropdown a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 12px 15px;
  color: rgba(244, 239, 228, .76);
  border-radius: 10px;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 16px;
  line-height: 1.35;
  transition: color 160ms ease, background-color 160ms ease;
}

.global-nav-dropdown a:hover,
.global-nav-dropdown a:focus-visible,
.global-nav-dropdown a[aria-current='page'] {
  color: #f4efe4;
  background: rgba(202, 255, 77, .09);
}

.global-nav-dropdown a[aria-current='page']::before {
  content: '';
  width: 6px;
  height: 6px;
  margin-right: 10px;
  border-radius: 50%;
  background: #caff4d;
  box-shadow: 0 0 12px rgba(202, 255, 77, .45);
}

.global-nav-contact {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  color: rgba(244, 239, 228, .72);
  font-family: 'Instrument Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 180ms ease;
}

.global-nav-contact:hover { color: #f4efe4; }

.global-nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 11px 24px;
  color: #f4efe4;
  background: transparent;
  border: 1px solid #caff4d;
  border-radius: 999px;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 15px;
  font-weight: 550;
  line-height: 1;
  white-space: nowrap;
  transition: color 180ms ease, background-color 180ms ease, transform 180ms ease;
}

.global-nav-cta:hover {
  color: #111714;
  background: #caff4d;
  transform: translateY(-1px);
}

.global-nav-mobile { display: none; }

@media (max-width: 1180px) {
  .global-nav-inner { width: min(calc(100% - 40px), 1440px); gap: 16px; }
  .global-nav-desktop { gap: 2px; }
  .global-nav-group > summary,
  .global-nav-contact { font-size: 13px; }
  .global-nav-cta { padding-inline: 18px; font-size: 13px; }
}

@media (max-width: 940px) {
  .global-site-nav,
  .global-nav-inner { min-height: 68px; }
  .global-nav-inner {
    grid-template-columns: auto 1fr auto auto;
    width: min(calc(100% - 40px), 1440px);
    gap: 12px;
  }
  .global-nav-desktop,
  .global-nav-contact { display: none; }
  .global-nav-cta { grid-column: 3; }
  .global-nav-mobile { position: relative; display: block; grid-column: 4; }
  .global-nav-mobile > summary {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    color: #f4efe4;
    border: 1px solid rgba(244, 239, 228, .28);
    border-radius: 50%;
    cursor: pointer;
    list-style: none;
  }
  .global-nav-mobile[open] > summary {
    color: #111714;
    background: #caff4d;
    border-color: #caff4d;
  }
  .global-menu-icon {
    position: relative;
    width: 16px;
    height: 12px;
    border-top: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
  }
  .global-menu-icon::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 0;
    right: 0;
    border-top: 1.5px solid currentColor;
  }
  .global-nav-mobile[open] .global-menu-icon { height: 1px; border-bottom: 0; }
  .global-mobile-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    display: grid;
    width: min(380px, calc(100vw - 40px));
    max-height: calc(100dvh - 92px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 12px;
    background: #171c18;
    border: 1px solid rgba(244, 239, 228, .14);
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .42);
  }
  .global-mobile-section { border-bottom: 1px solid rgba(244, 239, 228, .1); }
  .global-mobile-section > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 52px;
    padding: 12px 14px;
    color: #f4efe4;
    font-size: 16px;
    font-weight: 550;
    cursor: pointer;
    list-style: none;
  }
  .global-mobile-section .global-nav-dropdown {
    position: static;
    min-width: 0;
    padding: 0 6px 10px 14px;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    transform: none;
  }
  .global-mobile-section .global-nav-dropdown a {
    min-height: 46px;
    padding: 10px 14px;
    font-size: 15px;
  }
  .global-mobile-direct {
    display: flex;
    align-items: center;
    min-height: 52px;
    padding: 12px 14px;
    color: #f4efe4;
    border-bottom: 1px solid rgba(244, 239, 228, .1);
    font-size: 16px;
    font-weight: 550;
  }
  .global-mobile-direct:last-child { border-bottom: 0; }
}

@media (max-width: 560px) {
  .global-nav-inner { width: min(calc(100% - 28px), 1440px); gap: 8px; }
  .global-wordmark { font-size: 20px; }
  .global-nav-cta { min-height: 42px; padding-inline: 14px; font-size: 12px; }
  .global-mobile-panel { width: min(360px, calc(100vw - 28px)); }
}

@media (max-width: 390px) {
  .global-nav-cta { display: none; }
  .global-nav-mobile { grid-column: 4; }
}

/* Shared legal footer row. Kept in the primary shell so every page exposes the policies. */
.footer-legal {
  display: flex;
  flex: 1 0 100%;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px clamp(14px, 2vw, 26px);
  width: 100%;
  margin-top: 3px;
  padding-top: 22px;
  color: rgba(244, 239, 228, .58);
  border-top: 1px solid rgba(244, 239, 228, .1);
  font-family: 'Instrument Sans', sans-serif;
  font-size: 12px;
  line-height: 1.5;
}
.footer-legal-label {
  color: #caff4d;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.footer-legal a { padding-block: 8px; transition: color 160ms ease; }
.footer-legal a:hover,
.footer-legal a[aria-current='page'] { color: #f4efe4; }
.footer-copyright { margin-left: auto; color: rgba(244, 239, 228, .42); }

@media (max-width: 720px) {
  .footer-legal { align-items: flex-start; gap: 4px 18px; }
  .footer-legal-label { flex-basis: 100%; margin-bottom: 5px; }
  .footer-copyright { flex-basis: 100%; margin: 9px 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  .global-nav-chevron,
  .global-nav-cta,
  .global-nav-dropdown a { transition: none; }
  .global-nav-cta:hover { transform: none; }
}
