/* One painted surface for the header and navigation rail. */
body.eg-unified-navigation > .eg-navigation-glass {
  --navigation-height:120px;
  --navigation-width:70px;
  position:fixed;
  inset:0;
  z-index:109;
  pointer-events:none;
  background:#101015;
  clip-path:polygon(0 0,100% 0,100% var(--navigation-height),var(--navigation-width) var(--navigation-height),var(--navigation-width) 100%,0 100%);
  opacity:0;
  transition:opacity .45s cubic-bezier(.4,0,.2,1);
}
body.eg-unified-navigation > .eg-navigation-glass.is-visible { opacity:1; }
@supports ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
  body.eg-unified-navigation .eg-navigation-glass {
    background:rgba(12,12,16,.78);
    -webkit-backdrop-filter:blur(24px) saturate(110%) brightness(.8);
    backdrop-filter:blur(24px) saturate(110%) brightness(.8);
  }
}
@media(prefers-reduced-motion:reduce) {
  body.eg-unified-navigation > .eg-navigation-glass { transition:none; }
}
html body.eg-unified-navigation > header.eg-header,
html body.eg-unified-navigation > header.eg-header.is-scrolled,
html body.eg-unified-navigation aside.eg-side:not(.is-chat-open) {
  background:transparent !important;
  -webkit-backdrop-filter:none !important;
  backdrop-filter:none !important;
  box-shadow:none !important;
  border:0 !important;
}
html body.eg-unified-navigation > header.eg-header { z-index:110; }
/* A soft, local shade keeps the logo legible over bright profile covers. */
body.profile-detail-page:has([data-community-profile]) .eg-header .eg-brand {
  position:relative;
  isolation:isolate;
}
body.profile-detail-page:has([data-community-profile]) .eg-header .eg-brand::before {
  content:"";
  position:absolute;
  inset:-8px -14px;
  z-index:-1;
  border-radius:50%;
  background:radial-gradient(ellipse,rgba(0,0,0,.4) 0%,rgba(0,0,0,.18) 45%,transparent 75%);
  filter:blur(8px);
  opacity:0;
  pointer-events:none;
  transition:opacity .3s ease;
}
body.profile-detail-page:has([data-community-profile]) .eg-header:not(.is-scrolled) .eg-brand::before {
  opacity:1;
}
@media(prefers-reduced-motion:reduce) {
  body.profile-detail-page:has([data-community-profile]) .eg-header .eg-brand::before { transition:none; }
}
html body.eg-unified-navigation .eg-side :is(.eg-side-top,.eg-side-scroll,.eg-side-bottom) {
  background:transparent !important;
}
/* Keep the expanded rail legible where the page background changes beneath it. */
@media (min-width:761px) {
  html body.eg-unified-navigation aside.eg-side.is-open:not(.is-chat-open,.is-scrolled) {
    background:#0d0d12 !important;
  }
}
/* The same surface moves into the off-canvas menu on small screens. */
body.eg-unified-navigation .eg-navigation-glass.is-mobile-drawer {
  position:absolute;
  inset:0;
  z-index:-1;
  pointer-events:none;
  background:#101015;
  clip-path:none;
  border-radius:inherit;
  opacity:1;
}
@supports ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
  body.eg-unified-navigation .eg-navigation-glass.is-mobile-drawer {
    background:rgba(12,12,16,.78);
  }
}

/* Restrict the compositor's blur surfaces to the two visible strips. */
body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer) {
  background: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  clip-path: none;
  opacity: 1;
  transition: none;
}
body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::before,
body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::after {
  content: "";
  position: absolute;
  background: #101015;
  opacity: 0;
  transition: opacity .45s cubic-bezier(.4,0,.2,1);
}
body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::before {
  inset: 0 0 auto;
  height: var(--navigation-height);
}
body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::after {
  inset: var(--navigation-height) auto 0 0;
  width: var(--navigation-width);
}
body.eg-home.eg-unified-navigation > .eg-navigation-glass.is-visible:not(.is-mobile-drawer)::before,
body.eg-home.eg-unified-navigation > .eg-navigation-glass.is-visible:not(.is-mobile-drawer)::after {
  opacity: 1;
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::before,
  body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::after {
    background: rgba(12,12,16,.78);
    -webkit-backdrop-filter: blur(24px) saturate(110%) brightness(.8);
    backdrop-filter: blur(24px) saturate(110%) brightness(.8);
  }
}
@media (prefers-reduced-motion: reduce) {
  body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::before,
  body.eg-home.eg-unified-navigation > .eg-navigation-glass:not(.is-mobile-drawer)::after {
    transition: none;
  }
}
