/* JASSH v0.3.4 runtime visual lock
 * Loaded after the foundation stylesheet to bypass stale browser/CDN caches
 * and to keep the homepage header consistent with the About-family header.
 */

/* ---------- Desktop navigation: one blue bar, one row, search on the right ---------- */
@media (min-width: 993px) {
  html .jassh-ui .pkp_site_nav_menu {
    display: block !important;
    position: relative !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 26px !important;
    overflow: visible !important;
    background: linear-gradient(100deg,#004477 0%,#005b99 100%) !important;
    border: 0 !important;
    box-shadow: none !important;
  }
  html .jassh-ui .pkp_navigation_primary_row,
  html .jassh-ui .pkp_navigation_primary_wrapper {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
  }
  html .jassh-ui .pkp_navigation_primary_wrapper {
    display: flex !important;
    flex-flow: row nowrap !important;
    align-items: center !important;
    gap: 14px !important;
    min-height: 56px !important;
  }
  html .jassh-ui .pkp_navigation_primary,
  html .jassh-ui.vl-family-home .pkp_navigation_primary {
    display: flex !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    align-items: stretch !important;
    justify-content: space-between !important;
    background: transparent !important;
    border: 0 !important;
    overflow: visible !important;
  }
  html .jassh-ui .pkp_navigation_primary > li {
    display: block !important;
    flex: 0 0 auto !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }
  html .jassh-ui .pkp_navigation_primary > li > a,
  html .jassh-ui.vl-family-home .pkp_navigation_primary > li > a {
    display: flex !important;
    align-items: center !important;
    min-height: 56px !important;
    margin: 0 !important;
    padding: 15px 12px !important;
    color: #fff !important;
    background: transparent !important;
    border: 0 !important;
    border-bottom: 4px solid transparent !important;
    border-radius: 0 !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 1.15 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
  }
  html .jassh-ui .pkp_navigation_primary > li > a:hover,
  html .jassh-ui .pkp_navigation_primary > li > a:focus,
  html .jassh-ui .pkp_navigation_primary > li > a[aria-current="page"] {
    color: #fff !important;
    background: #087ea5 !important;
    border-bottom-color: #18d2b7 !important;
    outline: 0 !important;
  }

  html .jassh-ui .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-home .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-about .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-issue .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-authors .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-reviewers .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-article .pkp_navigation_search_wrapper {
    display: block !important;
    position: static !important;
    inset: auto !important;
    flex: 0 0 360px !important;
    width: 360px !important;
    min-width: 280px !important;
    max-width: 360px !important;
    margin: 0 0 0 auto !important;
    padding: 0 !important;
    transform: none !important;
    background: transparent !important;
    border: 0 !important;
  }
  html .jassh-ui .vl-search {
    display: flex !important;
    width: 100% !important;
    height: 40px !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  html .jassh-ui .vl-search input {
    display: block !important;
    flex: 1 1 auto !important;
    width: auto !important;
    min-width: 0 !important;
    height: 40px !important;
    padding: 8px 13px !important;
    border: 1px solid #b9d5e7 !important;
    border-right: 0 !important;
    border-radius: 5px 0 0 5px !important;
    background: #fff !important;
    color: #18345d !important;
    font-size: 13.5px !important;
    line-height: 1.2 !important;
  }
  html .jassh-ui .vl-search button {
    display: flex !important;
    flex: 0 0 48px !important;
    width: 48px !important;
    height: 40px !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #b9d5e7 !important;
    border-radius: 0 5px 5px 0 !important;
    background: #00558b !important;
    color: #fff !important;
  }
  html .jassh-ui .vl-search button svg {
    width: 23px !important;
    height: 23px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
  }
}

@media (min-width: 993px) and (max-width: 1399px) {
  html .jassh-ui .pkp_site_nav_menu { padding-inline: 16px !important; }
  html .jassh-ui .pkp_navigation_primary_wrapper { gap: 8px !important; }
  html .jassh-ui .pkp_navigation_primary > li > a { padding-inline: 8px !important; font-size: 13.2px !important; }
  html .jassh-ui .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-home .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-about .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-issue .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-authors .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-reviewers .pkp_navigation_search_wrapper,
  html .jassh-ui.vl-family-article .pkp_navigation_search_wrapper {
    flex-basis: 290px !important;
    width: 290px !important;
    min-width: 240px !important;
  }
}

/* ---------- Account state: guest never gets a My Account control ---------- */
html .jassh-ui .jassh-account-wrapper.is-guest .jassh-account-toggle,
html .jassh-ui .jassh-account-wrapper[data-authenticated="0"] .jassh-account-toggle {
  display: none !important;
  visibility: hidden !important;
}
html .jassh-ui .jassh-account-wrapper.is-authenticated .jassh-account-toggle,
html .jassh-ui .jassh-account-wrapper[data-authenticated="1"] .jassh-account-toggle {
  visibility: visible !important;
}

/* ---------- Homepage hero legibility: match the approved reference ---------- */
@media (min-width: 993px) {
  html .jassh-ui .vl-home-hero {
    background-position: center 70% !important;
  }
  html .jassh-ui .vl-home-hero::before {
    content: "" !important;
    position: absolute !important;
    inset: 0 !important;
    z-index: 0 !important;
    pointer-events: none !important;
    background:
      radial-gradient(ellipse 42% 34% at 82% 16%, rgba(255,255,255,.98) 0%, rgba(255,255,255,.90) 30%, rgba(255,255,255,.62) 49%, rgba(255,255,255,.20) 68%, rgba(255,255,255,0) 82%),
      linear-gradient(0deg, rgba(0,41,86,.20) 0%, rgba(0,41,86,.08) 17%, rgba(0,41,86,0) 33%) !important;
  }
  html .jassh-ui .vl-home-hero .vl-hero-slogan {
    display: block !important;
    position: absolute !important;
    z-index: 4 !important;
    top: 25px !important;
    right: 5.5% !important;
    width: 285px !important;
    margin: 0 !important;
    padding: 6px 8px !important;
    color: #073a7a !important;
    font-size: clamp(22px, 2vw, 30px) !important;
    font-weight: 500 !important;
    line-height: 1.16 !important;
    text-align: center !important;
    text-shadow: 0 1px 0 #fff, 0 2px 10px rgba(255,255,255,.98), 0 0 18px rgba(255,255,255,.85) !important;
  }
  html .jassh-ui .vl-home-hero .vl-hero-slogan::before {
    content: "" !important;
    position: absolute !important;
    z-index: -1 !important;
    inset: -25px -45px -28px -48px !important;
    border-radius: 50% !important;
    background: radial-gradient(ellipse at center, rgba(255,255,255,.93) 0%, rgba(255,255,255,.76) 40%, rgba(255,255,255,.34) 61%, rgba(255,255,255,0) 80%) !important;
    filter: blur(1px) !important;
  }
  html .jassh-ui .vl-home-hero .vl-hero-motto {
    display: block !important;
    position: absolute !important;
    z-index: 5 !important;
    left: 50% !important;
    right: auto !important;
    bottom: 12px !important;
    transform: translateX(-50%) !important;
    margin: 0 !important;
    padding: 5px 16px !important;
    border-radius: 999px !important;
    background: rgba(0,49,96,.72) !important;
    box-shadow: 0 2px 9px rgba(0,30,72,.22) !important;
    color: #fff !important;
    font-size: 9.5px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    letter-spacing: 2.2px !important;
    text-align: center !important;
    text-shadow: 0 1px 3px rgba(0,20,60,.9) !important;
    white-space: nowrap !important;
  }
}

/* ---------- Mobile: keep the clean accordion shell ---------- */
@media (max-width: 992px) {
  html .jassh-ui .pkp_site_nav_menu:not(.pkp_site_nav_menu--isOpen) .pkp_navigation_search_wrapper,
  html .jassh-ui .pkp_site_nav_menu:not(.pkp_site_nav_menu--isOpen) .jassh-account-wrapper {
    display: none !important;
  }
  html.jassh-mobile-nav-open .jassh-ui .jassh-account-wrapper.is-guest .jassh-account-toggle,
  html.jassh-mobile-nav-open .jassh-ui .jassh-account-wrapper[data-authenticated="0"] .jassh-account-toggle {
    display: none !important;
  }
}
