/* I4MD GLOBAL HEADER — shared across public, editorial and research pages.
   The homepage remains transparent over the founding engraving. */
.site-header.i4md-global-header{
  position:sticky;top:0;z-index:30;
  display:flex;align-items:center;justify-content:space-between;flex-wrap:nowrap;
  box-sizing:border-box;min-height:84px;padding:7px 4vw;
  border:0;box-shadow:none;background:rgba(242,239,232,.97);
}
.site-header.i4md-global-header.i4md-global-header--home{background:transparent}
.site-header.i4md-global-header .brand{
  display:inline-block!important;box-sizing:border-box;
  width:210px!important;height:70px!important;flex:0 0 210px!important;
  background-image:url('/i4md-logo.png?v=20261017-2')!important;
  background-position:left center!important;background-size:100% auto!important;
  background-repeat:no-repeat!important;mix-blend-mode:normal!important;
  font-size:0!important;line-height:0!important;text-decoration:none;
}
.site-header.i4md-global-header .brand > *{display:none!important}
.site-header.i4md-global-header .nav-toggle{
  display:none!important;align-items:center;justify-content:center;
  flex:0 0 auto;gap:13px;min-height:42px;padding:9px 12px;
  position:relative;z-index:2;cursor:pointer;
  border:1px solid rgba(32,30,26,.62);border-radius:9px;
  background:rgba(242,239,232,.95);color:var(--ink,#171714);
  font:700 10px/1 Arial,Helvetica,sans-serif;
  letter-spacing:.14em;text-transform:uppercase;
}
.site-header.i4md-global-header.i4md-header-ready .nav-toggle{display:inline-flex!important}
.site-header.i4md-global-header .nav-toggle:hover,
.site-header.i4md-global-header .nav-toggle[aria-expanded="true"]{
  border-color:var(--accent,#7b1919);color:var(--accent,#7b1919)
}
.site-header.i4md-global-header .nav-toggle:focus-visible,
.site-header.i4md-global-header #site-nav a:focus-visible{
  outline:2px solid var(--accent,#7b1919);outline-offset:3px
}
.site-header.i4md-global-header .nav-toggle-lines{
  display:flex;flex-direction:column;justify-content:center;gap:4px;width:17px
}
.site-header.i4md-global-header .nav-toggle-lines i{
  display:block;width:17px;height:1.5px;background:currentColor
}
/* Without JavaScript, the navigation remains available as ordinary links. */
.site-header.i4md-global-header #site-nav{
  display:flex;position:static;width:auto;min-width:0;
  padding:0;margin:0;border:0;border-radius:0;box-shadow:none;
  background:transparent;flex-direction:row;gap:22px;overflow:visible;
}
.site-header.i4md-global-header #site-nav a{
  display:block;padding:6px 0;border:0;
  color:var(--ink,#171714);font:700 11px/1.35 Arial,Helvetica,sans-serif;
  letter-spacing:.12em;text-transform:uppercase;text-decoration:none;
  border-radius:0;
}
.site-header.i4md-global-header #site-nav a:hover,
.site-header.i4md-global-header #site-nav a:focus-visible{
  color:var(--accent,#7b1919);text-decoration:underline;text-underline-offset:4px;
  background:transparent
}
/* The homepage's compact menu is used on all JavaScript-enabled pages. */
.site-header.i4md-global-header.i4md-header-ready #site-nav{
  display:none;position:absolute;top:calc(100% - 1px);right:4vw;
  width:min(300px,calc(100vw - 40px));margin:0;padding:9px 20px 15px;
  border:1px solid #292722;border-radius:12px;background:#f2efe8;
  box-shadow:0 14px 25px rgba(25,22,18,.14);
  flex-direction:column;gap:0;overflow:hidden;
}
.site-header.i4md-global-header.i4md-header-ready #site-nav.open{display:flex}
.site-header.i4md-global-header.i4md-header-ready #site-nav a{
  padding:15px 2px;border-top:1px solid #c9c4b9;border-radius:0;
}
.site-header.i4md-global-header.i4md-header-ready #site-nav a:first-child{border-top:0}
@media(max-width:850px){
  .site-header.i4md-global-header{min-height:68px;padding:6px 20px}
  .site-header.i4md-global-header .brand{
    width:168px!important;height:56px!important;flex-basis:168px!important
  }
  .site-header.i4md-global-header.i4md-header-ready #site-nav{right:20px}
  .site-header.i4md-global-header:not(.i4md-header-ready){
    flex-wrap:wrap;row-gap:4px
  }
  .site-header.i4md-global-header:not(.i4md-header-ready) #site-nav{
    width:100%;flex-direction:column;gap:0
  }
  .site-header.i4md-global-header:not(.i4md-header-ready) #site-nav a{
    padding:10px 0;border-top:1px solid #c9c4b9
  }
}
@media(prefers-reduced-motion:reduce){
  .site-header.i4md-global-header{transition:none}
}


/* I4MD / PERSISTENT QUIET PROCEDURE — scroll-responsive institutional masthead.
   The sticky shell remains visible at every scroll position and retains its
   original 84/68px footprint; only the inner bar and logo compress. */
.site-header.i4md-global-header.i4md-scroll-active{
  position:sticky;top:0;
  height:84px;min-height:84px;
  background:transparent!important;
  isolation:isolate;
  /* Keep the sticky shell visible while its contents downsize. */
}
.site-header.i4md-global-header.i4md-scroll-active::before{
  content:"";position:absolute;inset:0 0 auto;z-index:-1;
  height:var(--i4md-bar-height,84px);
  background:rgba(242,239,232,.97);
  border-bottom:1px solid rgba(41,39,34,.14);
  pointer-events:none;
  transition:background-color .24s ease,border-bottom-color .24s ease;
}
.site-header.i4md-global-header.i4md-global-header--home.i4md-scroll-active::before{
  background:rgba(242,239,232,var(--i4md-compact,0));
  border-bottom-color:rgba(41,39,34,var(--i4md-compact-rule,0));
}
.site-header.i4md-global-header.i4md-scroll-active::after{
  content:"";position:absolute;z-index:1;pointer-events:none;
  top:calc(var(--i4md-bar-height,84px) - 1px);
  left:var(--i4md-indicator-left,4%);width:16%;height:1px;
  background:rgba(116,35,31,.65);opacity:var(--i4md-compact,0);
}
.site-header.i4md-global-header.i4md-scroll-active .brand{
  transform-origin:left center;
  transform:translate3d(0,var(--i4md-center-shift,0px),0) scale(var(--i4md-brand-scale,1));
}
.site-header.i4md-global-header.i4md-scroll-active .nav-toggle{
  transform:translate3d(0,var(--i4md-center-shift,0px),0);
}
.site-header.i4md-global-header.i4md-scroll-active #site-nav{
  top:calc(var(--i4md-bar-height,84px) - 1px);
}
.site-header.i4md-global-header .i4md-header-context{
  position:absolute;left:calc(4vw + 164px);top:var(--i4md-context-top,35px);
  max-width:calc(100vw - 430px);overflow:hidden;text-overflow:ellipsis;
  white-space:nowrap;pointer-events:none;
  font:700 10px/1.4 Arial,Helvetica,sans-serif;letter-spacing:.13em;
  text-transform:uppercase;color:#56514a;
  opacity:var(--i4md-compact,0);
}
.site-header.i4md-global-header .i4md-header-context.i4md-context-changed{
  animation:i4md-context-entry 140ms ease-out both;
}
@keyframes i4md-context-entry{
  from{opacity:0;translate:0 3px}
  to{opacity:var(--i4md-compact,0);translate:0 0}
}
@media(max-width:850px){
  .site-header.i4md-global-header.i4md-scroll-active{
    height:68px;min-height:68px;
  }
  .site-header.i4md-global-header .i4md-header-context{
    left:164px;max-width:calc(100vw - 295px);
  }
}
@media(max-width:600px){
  .site-header.i4md-global-header .i4md-header-context{display:none}
}
@media(prefers-reduced-motion:reduce){
  .site-header.i4md-global-header.i4md-scroll-active::before{
    transition:none;
  }
  .site-header.i4md-global-header .i4md-header-context.i4md-context-changed{
    animation:none;
  }
}

/* Stroke icons replace mobile emoji-font fallbacks in visible controls and links. */
.i4md-ui-icon{
  display:inline-block;vertical-align:-.14em;width:.9em;height:.9em;
  margin-inline-start:.12em;flex:none;overflow:visible;
  fill:none;stroke:currentColor;stroke-width:1.7;
  stroke-linecap:round;stroke-linejoin:round;
}
.i4md-ui-icon--search{width:.68em;height:.68em;margin-inline-start:0;vertical-align:-.02em}
.i4md-ui-icon--status{width:.8em;height:.8em;margin-inline-start:0;stroke-width:1.5}
.symptom-gate.is-selected::after{
  content:"";width:15px;height:15px;right:16px;top:10px;
  background:transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2395352d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 19 19 5M8 5h11v11'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* Direct registry search — the icon shares the responsive header's quiet controls. */
.site-header.i4md-global-header .brand{margin-right:auto}
.site-header.i4md-global-header .i4md-header-search{
  display:inline-flex;align-items:center;justify-content:center;
  flex:0 0 42px;width:42px;height:42px;margin:0 10px 0 0;
  border:1px solid rgba(32,30,26,.62);border-radius:9px;
  background:rgba(242,239,232,.95);color:var(--ink,#171714);
  cursor:pointer;position:relative;z-index:2;
}
.site-header.i4md-global-header .i4md-header-search svg{
  width:19px;height:19px;fill:none;stroke:currentColor;
  stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;
}
.site-header.i4md-global-header .i4md-header-search:hover{
  border-color:var(--accent,#7b1919);color:var(--accent,#7b1919);
}
.site-header.i4md-global-header .i4md-header-search:focus-visible{
  outline:2px solid var(--accent,#7b1919);outline-offset:3px;
}
.site-header.i4md-global-header.i4md-scroll-active .i4md-header-search{
  transform:translate3d(0,var(--i4md-center-shift,0px),0);
}
@media(max-width:850px){
  .site-header.i4md-global-header .i4md-header-search{
    width:40px;height:40px;flex-basis:40px;margin-right:8px;
  }
}
@media(max-width:400px){
  .site-header.i4md-global-header .nav-toggle-label{display:none}
  .site-header.i4md-global-header .nav-toggle{min-width:40px;gap:0}
}

/* Venture-wide cross-document page transition standard (180ms). */
@view-transition {
  navigation: auto;
}
/* Header identity remains stable across same-origin document navigation. */
.site-header.i4md-global-header > .brand {
  view-transition-name: i4md-logo;
}
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 180ms;
  animation-timing-function: ease-out;
}
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root),
  ::view-transition-new(root),
  ::view-transition-old(i4md-logo),
  ::view-transition-new(i4md-logo) {
    animation-duration: 0.01ms !important;
  }
}
