@charset "utf-8";

/* ECP Style Menus — CSS-only dropdown navigation
 * Replaces Superfish JS plugin (removed 2026-04-10).
 * Imported by ecpstyle.css.
 */

/* ── Top-level menu bar ─────────────────────────────────────────────── */
ul#Menu1 {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  list-style: none;
  margin: 0;
  padding: 0;
  background-color: transparent;
}

/* Each top-level item is a positioning context for its dropdown */
ul#Menu1 > li {
  position: relative;
  background: transparent;
  transition: background 0.2s;
}

ul#Menu1 > li:hover,
ul#Menu1 > li:focus-within {
  background: rgba(255, 255, 255, 0.12);
}

/* Top-level links */
ul#Menu1 > li > a {
  display: block;
  padding: 0.75em 1em;
  color: #ffffff;
  text-decoration: none;
  white-space: nowrap;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
}

ul#Menu1 > li:first-child > a {
  border-left: none;
}

ul#Menu1 > li > a:hover,
ul#Menu1 > li > a:focus {
  color: #ffffff;
}

/* ── Dropdown sub-menus ─────────────────────────────────────────────── */
ul#Menu1 > li > ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 999;
  min-width: 220px;
  margin: 0;
  padding: 0.5em 0;
  list-style: none;
  background: #0a0ab8;
  box-shadow: 2px 3px 6px rgba(0, 0, 0, 0.2);
}

/* Show dropdown on hover or keyboard focus-within */
ul#Menu1 > li:hover > ul,
ul#Menu1 > li:focus-within > ul {
  display: block;
}

/* Dropdown items */
ul#Menu1 > li > ul > li {
  margin: 0;
  padding: 0;
}

ul#Menu1 > li > ul > li > a {
  display: block;
  padding: 0.4em 1em;
  color: #ffffff;
  text-decoration: none;
  white-space: nowrap;
}

ul#Menu1 > li > ul > li > a:hover,
ul#Menu1 > li > ul > li > a:focus {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

/* ── Mobile hamburger toggle ────────────────────────────────────────── */
#toggle-menu {
  display: none;
}

/* Base hidden state — shown only on mobile via media query.
   Sizing and icon scale are set inside the media query where they apply. */
#toggle-label {
  display: none;
  cursor: pointer;
  color: #ffffff;
}

/* NOTE: The primary mobile nav overrides live in nav-global.html's inline
   <style> block (max-width: 768px). The block below handles the wider
   tablet breakpoint (769px–960px) where the menu may need to collapse but
   the hamburger styling from nav-global.html already applies.
   Do not duplicate tap-target or positioning rules here. */
@media only screen and (max-width: 960px) {
  #toggle-label {
    /* WCAG 44×44px tap target — mirrors nav-global.html mobile rule */
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    font-size: 2rem;
    padding: 0.25em;
  }

  ul#Menu1 {
    display: none;
    flex-direction: column;
    /* Static position so menu expands the masthead rather than overlapping */
    position: static;
    width: 100%;
    box-sizing: border-box;
  }

  #toggle-menu:checked ~ ul#Menu1 {
    display: flex;
  }

  /* Top-level items: full width, generous tap target */
  ul#Menu1 > li {
    width: 100%;
  }

  ul#Menu1 > li > a {
    white-space: normal;
    width: 100%;
    box-sizing: border-box;
  }

  /* On mobile, dropdowns are inline (not absolute) */
  ul#Menu1 > li > ul {
    position: static;
    box-shadow: none;
    background: rgba(0, 0, 100, 0.35);
    padding-left: 1em;
    width: 100%;
  }

  /* Dropdown items: full width, wrappable */
  ul#Menu1 > li > ul > li {
    width: 100%;
  }

  ul#Menu1 > li > ul > li > a {
    white-space: normal;
    width: 100%;
    box-sizing: border-box;
  }

  /* Always show sub-menus on mobile (accordion-style) */
  ul#Menu1 > li > ul {
    display: block;
  }
}

/* ── Searchbox (used on NAV_Search.html) ────────────────────────────── */
.searchbox {
  display: block;
  background-color: var(--color-gray-light, #cccccc);
  text-align: center;
  margin-inline: auto;
  width: 90%;
}
