.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 0;
  pointer-events: none;
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1), opacity 220ms ease;
  /* --header-bar-height-* are the ACTUAL rendered bar heights used for internal header layout.
     These intentionally differ from --header-height (88px) in tokens.css.
     --header-height is a layout clearance token consumed by hero.css / home.css to reserve
     vertical breathing room above hero content — it is not the bar's physical height.
     Do NOT reconcile these values without auditing hero padding-top across all breakpoints. */
  --header-bar-height-desktop: 60px;
  --header-bar-height-tablet: 64px;
  --header-bar-height-mobile: 68px;
  --header-pad-desktop: clamp(2.5rem, 2.65vw, 4.25rem);
  --header-pad-tablet: 24px;
  --header-pad-mobile: 20px;
  --header-side-gap-desktop: 0px;
  --header-side-gap-tablet: 0px;
  --header-side-gap-mobile: 0px;
}

.site-header.is-hidden {
  transform: translateY(-110%);
}

.site-header .container {
  width: 100%;
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.site-header__bar {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  min-height: var(--header-bar-height-desktop);
  height: var(--header-bar-height-desktop);
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding: 0 var(--header-pad-desktop);
  box-sizing: border-box;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  overflow: visible;
  isolation: isolate;
  pointer-events: auto;
  transition:
    transform 320ms cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 220ms ease,
    backdrop-filter 220ms ease,
    -webkit-backdrop-filter 220ms ease,
    background-color 220ms ease,
    border-color 220ms ease;
}

.site-header__bar::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
  background:
    radial-gradient(340px 70px at var(--header-mx, 50%) 0%, rgba(255,255,255,0.075) 0%, rgba(255,255,255,0.028) 24%, rgba(255,255,255,0.01) 44%, transparent 76%),
    radial-gradient(circle at 18% 50%, rgba(88, 74, 212, 0.08), transparent 24%),
    radial-gradient(circle at 82% 45%, rgba(34,211,238,0.06), transparent 22%),
    linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.012) 30%, transparent 68%),
    linear-gradient(180deg, rgba(9, 14, 34, 0.7), rgba(5, 9, 22, 0.58)),
    linear-gradient(90deg, rgba(88, 74, 212, 0.06) 0%, rgba(34,211,238,0.035) 50%, rgba(88, 74, 212, 0.06) 100%),
    repeating-linear-gradient(
      115deg,
      rgba(255,255,255,0.026) 0px,
      rgba(255,255,255,0.026) 2px,
      rgba(255,255,255,0.01) 2px,
      rgba(255,255,255,0.01) 7px,
      transparent 7px,
      transparent 14px
    );
}

.site-header__bar::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 220ms ease;
  background:
    linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.04) 10%, rgba(255,255,255,0.04) 90%, transparent 100%),
    linear-gradient(90deg, transparent 0%, rgba(103, 232, 249, 0.05) 24%, rgba(167, 139, 250, 0.045) 50%, rgba(103, 232, 249, 0.05) 76%, transparent 100%);
  mask: linear-gradient(to bottom, transparent calc(100% - 1px), #000 calc(100% - 1px));
  -webkit-mask: linear-gradient(to bottom, transparent calc(100% - 1px), #000 calc(100% - 1px));
}

/* Resting header bar: transparent and no shadow/blur */
.site-header:not(.is-scrolled):not(.is-dropping) .site-header__bar {
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.site-header.is-scrolled .site-header__bar:hover::before,
.site-header.is-scrolled .site-header__bar:focus-within::before,
.site-header.is-dropping .site-header__bar:hover::before,
.site-header.is-dropping .site-header__bar:focus-within::before {
  opacity: 1;
}

.site-header.is-scrolled .site-header__bar {
  background: rgba(5, 9, 22, 0.68);
  box-shadow:
    0 10px 28px rgba(0,0,0,0.28),
    0 0 12px rgba(88,74,212,0.08);
  backdrop-filter: blur(var(--blur-panel)) saturate(var(--sat-header));
  -webkit-backdrop-filter: blur(var(--blur-panel)) saturate(var(--sat-header));
}

.site-header.is-dropping .site-header__bar {
  box-shadow:
    0 6px 18px rgba(3, 8, 24, 0.18),
    0 0 14px rgba(88, 74, 212, 0.07),
    0 0 28px rgba(34, 211, 238, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

.site-header.is-scrolled .site-header__bar::before,
.site-header.is-scrolled .site-header__bar::after {
  opacity: 1;
}

.site-header.is-dropping .site-header__bar {
  animation: header-drop 480ms cubic-bezier(0.22, 0.88, 0.24, 1);
}

@keyframes header-drop {
  0% { transform: translateY(-14px) scaleY(0.985); }
  62% { transform: translateY(3px) scaleY(1); }
  100% { transform: translateY(0) scaleY(1); }
}

.site-header__bar > * {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.56rem;
  flex-shrink: 0;
  min-width: 0;
  max-width: 260px;
  flex: 0 1 auto;
  text-decoration: none;
  transition: transform 220ms ease, opacity 220ms ease;
}

.site-brand:hover {
  transform: translateY(-0.5px);
}

.site-brand__mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.28), transparent 30%),
    linear-gradient(135deg, rgba(114, 88, 246, 1), rgba(96, 84, 226, 0.98) 52%, rgba(73, 205, 241, 0.96));
  color: white;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08),
    0 0 18px rgba(88, 74, 212, 0.18),
    0 6px 16px rgba(14, 21, 54, 0.22),
    0 0 16px rgba(78, 207, 241, 0.11);
}

.site-brand__text {
  display: grid;
  gap: 0.1rem;
  line-height: 1;
  min-width: 0;
  transform: translateY(1px);
}

.site-brand__text strong {
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  white-space: nowrap;
  background: linear-gradient(90deg, #6f57f2 0%, #9e87fa 22%, #f4f7ff 54%, #7ce9ff 82%, #35d4f2 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow:
    0 1px 0 rgba(255,255,255,0.08),
    0 0 14px rgba(88, 74, 212, 0.18),
    0 0 20px rgba(34, 211, 238, 0.08);
  filter: drop-shadow(0 2px 12px rgba(5, 10, 24, 0.3));
  -webkit-text-stroke: 0.28px rgba(10, 14, 34, 0.24);
}

.site-brand__tagline,
.site-brand__text span {
  color: rgba(232, 239, 255, 0.92);
  font-size: 0.58rem;
  letter-spacing: 0.01em;
  white-space: nowrap;
  text-shadow: 0 1px 8px rgba(4, 9, 22, 0.18);
}

.site-header__toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 14px;
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.08), rgba(6, 10, 22, 0.98)),
    linear-gradient(135deg, rgba(99,102,241,0.04), rgba(34,211,238,0.04));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.05),
    0 7px 16px rgba(3, 8, 24, 0.22),
    0 0 0 1px rgba(125, 211, 252, 0.02);
  overflow: hidden;
  transition:
    transform 220ms ease,
    border-color 220ms ease,
    background 220ms ease,
    box-shadow 220ms ease;
}

.site-header__toggle::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.04);
  pointer-events: none;
}

.site-header__toggle span {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: rgba(238, 244, 255, 0.95);
  margin: 0 auto;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
  transition: background 220ms ease;
}

.site-header__toggle span::before,
.site-header__toggle span::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: rgba(238, 244, 255, 0.95);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
  transform: translateX(-50%);
  transition: top 220ms ease, transform 220ms ease, opacity 220ms ease;
}

.site-header__toggle span::before {
  top: -6px;
}

.site-header__toggle span::after {
  top: 6px;
}

.site-header__toggle:hover {
  transform: translateY(-1px) scale(1.03);
  border-color: rgba(186, 230, 253, 0.32);
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.11), rgba(8,12,28,1)),
    linear-gradient(135deg, rgba(99,102,241,0.06), rgba(34,211,238,0.06));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 12px rgba(56, 189, 248, 0.08),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-header__toggle:hover::after {
  border-color: rgba(255,255,255,0.07);
}

.site-header__toggle:focus-visible {
  outline: none;
  border-color: rgba(186, 230, 253, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 14px rgba(56, 189, 248, 0.09),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-header__toggle[aria-expanded="true"] {
  border-color: rgba(186, 230, 253, 0.36);
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.11), rgba(8,12,28,1)),
    linear-gradient(135deg, rgba(99,102,241,0.06), rgba(34,211,238,0.06));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 14px rgba(56, 189, 248, 0.09),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-header__toggle[aria-expanded="true"]::after {
  border-color: rgba(255,255,255,0.07);
}

.site-header__toggle[aria-expanded="true"] span {
  background: transparent;
  box-shadow: none;
}

.site-header__toggle[aria-expanded="true"] span::before {
  top: 0;
  transform: translateX(-50%) rotate(45deg);
}

.site-header__toggle[aria-expanded="true"] span::after {
  top: 0;
  transform: translateX(-50%) rotate(-45deg);
}

.site-nav {
  position: absolute;
  top: calc(100% + 0.55rem);
  left: 50%;
  right: auto;
  width: 100vw;
  transform: translateX(-50%);
  z-index: 20;
  display: none;
  flex-direction: column;
  gap: 0.9rem;
  padding: 1rem max(1.25rem, calc((100vw - 1380px) / 2 + 2rem));
  border-radius: 0 0 18px 18px;
  background:
    radial-gradient(720px 180px at 18% 0%, rgba(99, 102, 241, 0.12), transparent 58%),
    radial-gradient(640px 180px at 82% 12%, rgba(34, 211, 238, 0.08), transparent 58%),
    linear-gradient(180deg, rgba(12, 19, 46, 0.72), rgba(7, 13, 34, 0.66));
  border: 0;
  border-top: 1px solid rgba(186, 230, 253, 0.16);
  box-shadow:
    0 24px 58px rgba(3, 8, 24, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -1px 0 rgba(125, 211, 252, 0.06);
  backdrop-filter: blur(var(--blur-nav)) saturate(var(--sat-nav));
  -webkit-backdrop-filter: blur(var(--blur-nav)) saturate(var(--sat-nav));
}

.site-nav.is-open {
  display: flex;
  overflow: hidden;
}

.site-nav.is-open::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(255,255,255,0.08), transparent 24%, transparent 68%, rgba(125,211,252,0.055)),
    repeating-linear-gradient(
      115deg,
      rgba(255,255,255,0.026) 0px,
      rgba(255,255,255,0.026) 1px,
      transparent 1px,
      transparent 9px
    );
  opacity: 0.55;
}

.site-nav__center,
.site-nav__end {
  display: contents;
}

.site-nav__links,
.site-nav__actions {
  display: flex;
}

.site-nav__links {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.7rem;
}

.site-nav__actions {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
}

.site-nav__link {
  position: relative;
  z-index: 2;
  color: rgba(240, 246, 255, 0.92);
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
  opacity: 0.94;
  transition: color 220ms ease, opacity 220ms ease, transform 220ms ease;
}

.site-nav__link::before {
  content: "";
  position: absolute;
  inset: -6px -8px;
  border-radius: 999px;
  background:
    linear-gradient(90deg, rgba(198, 168, 255, 0.9) 0%, rgba(127, 233, 255, 0.9) 50%, rgba(67, 217, 255, 0.9) 100%),
    radial-gradient(circle at 50% 50%, rgba(255,255,255,0.06), transparent 70%);
  opacity: 0;
  transition: opacity 220ms ease, transform 220ms ease;
  transform: scale(0.96);
  z-index: -1;
}

.site-nav__link.is-active,
.site-nav__link:hover {
  color: #ffffff;
  opacity: 1;
  transform: translateY(-0.5px);
}

.site-nav__link.is-active::before {
  opacity: 0.045;
  transform: scale(1);
}

.site-nav__active-rail {
  display: none;
}

.site-nav__button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0.14rem 0.78rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition:
    transform 220ms ease,
    border-color 220ms ease,
    background 220ms ease,
    color 220ms ease,
    box-shadow 220ms ease;
}

.site-nav__button:hover {
  transform: translateY(-0.75px) scale(1.01);
}

.site-nav__button--primary,
.site-nav__cta {
  color: #ffffff;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.9), rgba(34, 211, 238, 0.9));
  box-shadow:
    0 5px 14px rgba(34, 211, 238, 0.1),
    0 0 10px rgba(99, 102, 241, 0.06),
    inset 0 1px 0 rgba(255,255,255,0.1);
}

.site-nav__button--ghost,
.site-nav__signin {
  color: rgba(232, 238, 255, 0.88);
  background: rgba(8, 12, 28, 0.42);
  border-color: rgba(255,255,255,0.08);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.05),
    0 10px 24px rgba(3, 8, 24, 0.22);
}

.site-nav__a11y {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.08), rgba(6, 10, 22, 0.98)),
    linear-gradient(135deg, rgba(99,102,241,0.04), rgba(34,211,238,0.04));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.05),
    0 7px 16px rgba(3, 8, 24, 0.22),
    0 0 0 1px rgba(125, 211, 252, 0.02);
  overflow: hidden;
  transition: transform 220ms ease, border-color 220ms ease, background 220ms ease, box-shadow 220ms ease;
}

.site-nav__a11y::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.04);
  pointer-events: none;
}

.site-nav__a11y-icon {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  color: rgba(238, 244, 255, 0.95);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
}

.site-nav__a11y-icon svg {
  display: block;
  width: 100%;
  height: 100%;
}

.site-nav__a11y > * {
  position: relative;
  z-index: 1;
}

.site-nav__a11y span,
.site-nav__a11y i,
.site-nav__a11y svg {
  position: relative;
  z-index: 1;
}

.site-nav__a11y::selection {
  background: transparent;
}

.site-nav__a11y:hover {
  transform: translateY(-1px) scale(1.03);
  border-color: rgba(186, 230, 253, 0.32);
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.11), rgba(8,12,28,1)),
    linear-gradient(135deg, rgba(99,102,241,0.06), rgba(34,211,238,0.06));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 12px rgba(56, 189, 248, 0.08),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-nav__a11y:hover::after {
  border-color: rgba(255,255,255,0.07);
}

.site-nav__a11y:focus-visible {
  outline: none;
  border-color: rgba(186, 230, 253, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 14px rgba(56, 189, 248, 0.09),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-header__a11y-mobile {
  display: none;
  position: relative;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.08), rgba(6, 10, 22, 0.98)),
    linear-gradient(135deg, rgba(99,102,241,0.04), rgba(34,211,238,0.04));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.05),
    0 7px 16px rgba(3, 8, 24, 0.22),
    0 0 0 1px rgba(125, 211, 252, 0.02);
  overflow: hidden;
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.site-header__a11y-mobile::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.04);
  pointer-events: none;
}

.site-header__a11y-mobile:hover {
  transform: translateY(-1px) scale(1.03);
  border-color: rgba(186, 230, 253, 0.32);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.07),
    0 0 0 1px rgba(125, 211, 252, 0.05),
    0 0 12px rgba(56, 189, 248, 0.08),
    0 10px 22px rgba(3, 8, 24, 0.3);
}

.site-header__a11y-mobile .site-nav__a11y-icon {
  width: 18px;
  height: 18px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  background: transparent;
}

.theme-toggle__track {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: 48px;
  height: 26px;
  padding: 0 5px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(10, 14, 30, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 4px 10px rgba(0,0,0,0.24),
    0 0 0 1px rgba(125, 211, 252, 0.028);
  transition:
    transform 220ms ease,
    box-shadow 220ms ease,
    border-color 220ms ease,
    background 220ms ease;
}

.theme-toggle:hover .theme-toggle__track {
  transform: translateY(-0.5px) scale(1.015);
  border-color: rgba(167, 243, 255, 0.32);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.02)),
    linear-gradient(135deg, rgba(99,102,241,0.04), rgba(34,211,238,0.04));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 0 0 1px rgba(125, 211, 252, 0.045),
    0 0 14px rgba(56, 189, 248, 0.09),
    0 4px 10px rgba(0,0,0,0.24);
}

.theme-toggle__icon {
  position: relative;
  z-index: 1;
  font-size: 0.8rem;
  opacity: 0.9;
}

.theme-toggle__thumb {
  position: absolute;
  left: 4px;
  top: 50%;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #818cf8, #22d3ee);
  box-shadow:
    0 3px 10px rgba(0,0,0,0.36),
    inset 0 1px 0 rgba(255,255,255,0.2);
  transform: translateY(-50%);
  transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1), background 220ms ease, box-shadow 220ms ease;
}

@media (min-width: 980px) {
  .site-header__bar {
    grid-template-columns: minmax(220px, 292px) minmax(0, 1fr) minmax(198px, auto);
    min-height: var(--header-bar-height-desktop);
    height: var(--header-bar-height-desktop);
    padding-left: var(--header-pad-desktop);
    padding-right: var(--header-pad-desktop);
    width: 100%;
    max-width: none;
    margin: 0 auto;
    column-gap: clamp(0.85rem, 1.45vw, 1.55rem);
  }

  .site-header__toggle {
    display: none;
  }

  .site-nav {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    width: auto;
    transform: none;
    display: contents;
  }

  .site-nav__center {
    grid-column: 2;
    justify-self: center;
    align-self: center;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 clamp(0.7rem, 1.4vw, 1.1rem) 0.1rem;
  }

  .site-nav__end {
    grid-column: 3;
    justify-self: end;
    align-self: center;
    display: flex;
    min-height: var(--header-bar-height-desktop);
    align-items: center;
    justify-content: flex-end;
    margin-left: clamp(0.9rem, 1.65vw, 1.45rem);
    margin-right: 0;
  }

  .site-nav__links {
    position: relative;
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: clamp(1.08rem, 1.65vw, 1.42rem);
    white-space: nowrap;
    margin: 0;
    min-height: var(--header-bar-height-desktop);
    padding-top: 0.18rem;
    padding-bottom: 0;
    transform: translateY(1px);
  }

  .site-nav__links::before {
    content: "";
    position: absolute;
    left: -12px;
    right: -12px;
    bottom: 11px;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.04) 10%, rgba(255,255,255,0.04) 90%, transparent 100%);
    pointer-events: none;
  }

  .site-nav__links::after {
    content: "";
    position: absolute;
    left: -8px;
    right: -8px;
    top: 3px;
    height: 20px;
    pointer-events: none;
    background:
      radial-gradient(220px 24px at var(--header-mx, 50%) 0%, rgba(255,255,255,0.045), transparent 70%),
      linear-gradient(90deg, transparent 0%, rgba(103, 232, 249, 0.04) 24%, rgba(167, 139, 250, 0.035) 50%, rgba(103, 232, 249, 0.04) 76%, transparent 100%);
    opacity: 0.6;
    filter: blur(0.2px);
  }

  .site-nav__actions {
    display: inline-flex;
    min-height: var(--header-bar-height-desktop);
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: clamp(0.88rem, 1.35vw, 1.18rem);
    margin-left: 0;
    white-space: nowrap;
  }

  .site-nav__actions::before {
    content: "";
    width: 1px;
    height: 18px;
    margin-right: 0.22rem;
    background: linear-gradient(180deg, transparent 0%, rgba(255,255,255,0.08) 20%, rgba(255,255,255,0.08) 80%, transparent 100%);
    opacity: 0.7;
  }

  .site-nav__center,
  .site-nav__end,
  .site-nav__actions,
  .site-nav__actions > * {
    position: relative;
    z-index: 3;
  }

  .site-nav__cta {
    min-height: 42px;
    padding: 0.18rem 1.02rem;
  }

  .site-nav__signin {
    min-height: 28px;
    padding: 0;
    font-size: 0.82rem;
    font-weight: 500;
    background: transparent;
    border: none;
    box-shadow: none;
    color: rgba(232, 238, 255, 0.94);
    text-transform: none;
    text-shadow: 0 1px 8px rgba(4, 9, 22, 0.14);
    margin-right: 0.28rem;
    transform: translateY(0);
  }

  .site-nav__signin:hover {
    color: #ffffff;
  }

  .theme-toggle {
    margin-left: 0.24rem;
    transform: translateY(0);
  }

  .site-nav__end .theme-toggle__track {
    width: 42px;
    height: 23px;
    padding: 0 4px;
  }

  .site-nav__end .theme-toggle__thumb {
    width: 16px;
    height: 16px;
  }

  .site-nav__a11y {
    margin-left: 0.26rem;
    width: 36px;
    height: 36px;
    transform: translateY(0);
  }

  .site-brand {
    grid-column: 1;
    max-width: 292px;
    justify-self: start;
    align-self: center;
    padding-right: 0;
  }

  .site-header__nav {
    grid-column: 2 / 4;
    min-width: 0;
    display: contents;
  }

  .site-brand__text {
    max-width: 222px;
  }

  .site-brand__text strong,
  .site-brand__tagline,
  .site-brand__text span {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .site-nav__active-rail {
    display: block;
    position: absolute;
    left: 0;
    bottom: 8px;
    width: 68px;
    height: 2.5px;
    border-radius: 999px;
    pointer-events: none;
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.98), rgba(34, 211, 238, 0.98));
    box-shadow: 0 0 8px rgba(125, 211, 252, 0.12);
    transform-origin: center;
    transition:
      transform 340ms cubic-bezier(0.22, 1, 0.36, 1),
      width 340ms cubic-bezier(0.22, 1, 0.36, 1),
      opacity 180ms ease;
    opacity: 1;
  }

  .site-nav__active-rail.is-settling {
    transition:
      transform 420ms cubic-bezier(0.2, 0.9, 0.24, 1.12),
      width 420ms cubic-bezier(0.2, 0.9, 0.24, 1.12),
      opacity 180ms ease;
  }
}

@media (max-width: 979px) {
  .site-header {
    --header-side-gap-tablet: 0px;
    --header-pad-tablet: 12px;
  }

  .site-header__bar {
    min-height: var(--header-bar-height-tablet);
    height: var(--header-bar-height-tablet);
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 7px clamp(1.4rem, 5vw, 3.2rem);
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    align-items: center;
    column-gap: clamp(12px, 3.4vw, 22px);
    overflow: visible;
  }

  .site-header__bar > * {
    align-self: center;
  }

  .site-header__toggle {
    display: inline-flex;
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
    align-self: center;
    width: 40px;
    height: 40px;
    margin: 0;
    position: relative;
    inset: auto;
    z-index: 3;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
  }

  .site-brand {
    grid-column: 2;
    grid-row: 1;
    justify-self: center;
    align-self: center;
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.58rem;
    margin: 0;
    width: 100%;
    min-width: 0;
    max-width: min(320px, calc(100vw - 190px));
    text-align: center;
    pointer-events: auto;
    overflow: hidden;
  }

  .site-brand__mark {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
  }

  .site-brand__text {
    justify-items: start;
    text-align: left;
    min-width: 0;
    max-width: 100%;
  }

  .site-brand__text strong,
  .site-brand__tagline,
  .site-brand__text span {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .site-brand__text strong {
    font-size: 0.98rem;
  }

  .site-brand__tagline,
  .site-brand__text span {
    font-size: 0.62rem;
  }

  .site-header__a11y-mobile {
    display: inline-flex;
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    align-self: center;
    width: 40px;
    height: 40px;
    margin: 0;
    position: relative;
    inset: auto;
    z-index: 3;
    align-items: center;
    justify-content: center;
  }

  .site-nav__center,
  .site-nav__end,
  .site-nav__a11y,
  .theme-toggle,
  .site-nav__signin,
  .site-nav__actions,
  .site-nav__actions::before,
  .site-nav__active-rail {
    display: none !important;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 50%;
    right: auto;
    width: 100vw;
    transform: translateX(-50%);
    z-index: 20;
    display: none;
    flex-direction: column;
    gap: 0.9rem;
    padding: 1rem clamp(1.35rem, 6vw, 2.5rem);
    border-radius: 0 0 18px 18px;
    background:
      radial-gradient(620px 180px at 18% 0%, rgba(99, 102, 241, 0.2), transparent 58%),
      radial-gradient(560px 180px at 82% 12%, rgba(34, 211, 238, 0.14), transparent 58%),
      linear-gradient(180deg, rgba(12, 19, 46, 0.72), rgba(7, 13, 34, 0.68));
    border: 0;
    border-top: 1px solid rgba(186, 230, 253, 0.16);
    box-shadow:
      0 24px 56px rgba(3, 8, 24, 0.42),
      inset 0 1px 0 rgba(255, 255, 255, 0.08),
      inset 0 -1px 0 rgba(125, 211, 252, 0.055);
    backdrop-filter: blur(24px) saturate(140%);
    -webkit-backdrop-filter: blur(24px) saturate(140%);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav__links,
  .site-nav__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .site-header {
    --header-side-gap-mobile: 0px;
    --header-pad-mobile: 12px;
  }

  .site-header__bar {
    min-height: var(--header-bar-height-mobile);
    height: var(--header-bar-height-mobile);
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 8px clamp(1rem, 4vw, 1.6rem);
    grid-template-columns: 42px minmax(0, 1fr) 42px;
    column-gap: clamp(10px, 3.5vw, 18px);
  }

  .site-header__toggle {
    width: 40px;
    height: 40px;
    border-radius: 13px;
  }

  .site-header__a11y-mobile {
    width: 40px;
    height: 40px;
  }

  .site-brand {
    grid-column: 2;
    grid-row: 1;
    justify-self: center;
    align-self: center;
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    max-width: min(250px, calc(100vw - 146px));
    gap: 0.55rem;
  }



  .site-brand__mark {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
  }

  .site-brand__text {
    gap: 0.14rem;
  }

  .site-brand__text strong {
    font-size: 0.9rem;
  }

  .site-brand__tagline,
  .site-brand__text span {
    font-size: 0.56rem;
  }
}

@media (max-width: 520px) {
  .site-header__bar {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding-left: 16px;
    padding-right: 16px;
    grid-template-columns: 40px minmax(0, 1fr) 40px;
    column-gap: 8px;
  }

  .site-header__toggle,
  .site-header__a11y-mobile {
    width: 40px;
    height: 40px;
  }
  .site-header__toggle {
    border-radius: 12px;
  }

  .site-brand {
    grid-column: 2;
    grid-row: 1;
    justify-self: center;
    align-self: center;
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    max-width: min(230px, calc(100vw - 136px));
    gap: 0.5rem;
  }



  .site-brand__text strong {
    font-size: 0.84rem;
  }

  .site-brand__tagline,
  .site-brand__text span {
    font-size: 0.52rem;
  }
}

@media (max-width: 420px) {
  .site-header {
    --header-side-gap-mobile: 0px;
  }

  .site-header__bar {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding-left: 14px;
    padding-right: 14px;
    grid-template-columns: 38px minmax(0, 1fr) 38px;
    column-gap: 8px;
  }

  .site-header__toggle,
  .site-header__a11y-mobile {
    width: 38px;
    height: 38px;
  }
  .site-header__toggle {
    border-radius: 11px;
  }

  .site-brand {
    grid-column: 2;
    grid-row: 1;
    justify-self: center;
    align-self: center;
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    max-width: min(214px, calc(100vw - 128px));
    gap: 0.42rem;
  }



  .site-brand__mark {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
  }

  .site-brand__text strong {
    font-size: 0.8rem;
  }

  .site-brand__tagline,
  .site-brand__text span {
    font-size: 0.5rem;
  }
}
