/* Header only. The existing WorkScout logos, body content and footer are untouched. */
@media (min-width: 1100px) {
  body.ese-header-navigation #header > .container { display: flex; align-items: center; }
  body.ese-header-navigation #header .left-side { display: flex; align-items: center; flex: 1 1 auto; width: auto; min-width: 0; float: none; }
  body.ese-header-navigation #header #logo_nh { flex: 0 0 auto; margin-right: 34px; }
  body.ese-header-navigation #header #navigation { display: block !important; flex: 1 1 auto; min-width: 0; width: auto; }
  body.ese-header-navigation #navigation > ul { display: flex; align-items: center; float: none; width: 100%; gap: 3px; }
  body.ese-header-navigation #navigation > ul > li { float: none; flex: 0 0 auto; }
  body.ese-header-navigation #navigation > ul > .ese-header-book { margin-left: auto !important; padding-left: 28px; }
  body.ese-header-navigation #header .right-side { display: flex; position: static; flex: 0 0 auto; margin-left: 20px; }
  body.ese-header-navigation #navigation li:not(.ese-menu-dismissed):focus-within > ul,
  body.ese-header-navigation #navigation li.ese-menu-open > ul { opacity: 1; visibility: visible; pointer-events: auto; transform: none; }
  body.ese-header-navigation #navigation li.ese-menu-dismissed > ul { opacity: 0; visibility: hidden; pointer-events: none; }
  /* Keep the native compact panel width; rows follow the panel, with equal 6px insets. */
  body.ese-header-navigation #navigation .sub-menu { width: 208px; min-width: 208px; }
  body.ese-header-navigation #navigation .sub-menu > li { width: 100%; box-sizing: border-box; }
  body.ese-header-navigation #navigation .sub-menu > li > a { display: block; width: 100%; box-sizing: border-box; }
}
@media (max-width: 1099px) {
  body.ese-header-navigation #header > .container { display: flex; align-items: center; justify-content: space-between; }
  body.ese-header-navigation #header .left-side { float: none; flex: 1 1 auto; width: auto; min-width: 0; }
  body.ese-header-navigation #header .right-side { display: flex; position: static; flex: 0 0 auto; width: auto; }
  body.ese-header-navigation #header #navigation { display: none !important; }
  body.ese-header-navigation #header .mmenu-trigger { display: block !important; margin: 0; float: none; width: 44px; min-width: 44px; }
  body.ese-header-navigation #header .mmenu-trigger .hamburger { display: flex; align-items: center; justify-content: center; width: 44px; min-width: 44px; height: 44px; padding: 10px; box-sizing: border-box; }
}
@layer ese-readable-text {
  body.ese-header-navigation #navigation .ese-header-book > a,
  body.ese-header-navigation #mobile-nav .ese-header-book > a {
    --ese-ink: #fff; color: #fff !important; -webkit-text-fill-color: #fff !important;
    background: #2e73db !important; border-radius: 6px; padding: 12px 20px;
    line-height: 1.4; font-weight: 600; text-align: center; text-decoration: none;
  }
  body.ese-header-navigation #navigation .ese-header-book > a:is(:hover,:focus-visible),
  body.ese-header-navigation #mobile-nav .ese-header-book > a:is(:hover,:focus-visible) {
    color: #fff !important; background: #0d203e !important;
  }
  body.ese-header-navigation #navigation a:focus-visible,
  body.ese-header-navigation #mobile-nav a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
}
body.ese-header-navigation #mobile-nav > .ese-header-book { margin: 18px 20px; }
body.ese-header-navigation #mobile-nav > .ese-header-book > a { display: block; }

/* Homepage dropdowns follow the template's transparent/sticky header states. */
@layer ese-readable-text {
  body.home.ese-header-navigation #header-container:not(.cloned) #navigation .sub-menu {
    --ese-ink: #0d203e;
    background: #fff !important;
  }
  body.home.ese-header-navigation #header-container:not(.cloned) #navigation .sub-menu a {
    --ese-ink: #0d203e;
    color: #0d203e !important;
    -webkit-text-fill-color: #0d203e !important;
  }
  body.home.ese-header-navigation #header-container:not(.cloned) #navigation .sub-menu a:is(:hover,:focus-visible) {
    background: #edf3fd !important;
    color: #0d203e !important;
  }
  body.home.ese-header-navigation #header-container.cloned #navigation .sub-menu {
    --ese-ink: #fff;
    background: #0d203e !important;
  }
  body.home.ese-header-navigation #header-container.cloned #navigation .sub-menu a {
    --ese-ink: #fff;
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
  }
  body.home.ese-header-navigation #header-container.cloned #navigation .sub-menu a:is(:hover,:focus-visible) {
    background: #16355c !important;
    color: #fff !important;
  }
}
