/* Top menu: hover and current page / section (js/umbc-nav.js adds the classes) */

/* Desktop menu items */
a.umbc-navlink {
  text-decoration: underline !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: 8px;
  text-decoration-color: transparent !important;
  transition: color .2s ease, text-decoration-color .2s ease;
}
a.umbc-navlink:hover,
a.umbc-navlink:focus-visible {
  color: #63c5f1 !important;
  text-decoration-color: #63c5f1 !important;
}
a.umbc-navlink.umbc-active {
  color: #ff9600 !important;
  text-decoration-color: #ff9600 !important;
}

/* Register button */
a.umbc-reg-link > div { transition: background-color .2s ease, border-color .2s ease; }
a.umbc-reg-link:hover > div { background-color: rgba(0, 157, 226, .25) !important; }
a.umbc-reg-link.umbc-active > div { background-color: #009de2 !important; }

/* Phone menu */
a.umbc-mnav h2 { transition: color .2s ease; }
a.umbc-mnav:hover h2 { color: #ffffff !important; }
a.umbc-mnav.umbc-active h2 { color: #ffffff !important; text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; text-decoration-color: #ff9600; }

/* Logo → home */
a.umbc-logo-link { position: absolute; inset: 0; display: block; cursor: pointer; z-index: 1; }
a.umbc-logo-link svg { transition: opacity .2s ease; }
a.umbc-logo-link:hover svg { opacity: .85; }

/* "Home" drop-down (sections of the home page) */
.umbc-caret { display: inline-block; margin-left: 4px; font-size: .75em; transition: transform .2s ease; }
a.umbc-dd-link[aria-expanded="true"] .umbc-caret { transform: rotate(180deg); }
.umbc-dd {
  position: fixed; z-index: 10050; min-width: 220px; padding: 8px; margin-top: 6px;
  background: #fff; border-radius: 14px; box-shadow: 0 18px 40px rgba(16, 61, 81, .22), 0 2px 6px rgba(16, 61, 81, .08);
  border-top: 3px solid #ff9600;
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s ease, transform .18s ease, visibility .18s;
  font-family: "Metropolis 2", "Segoe UI", Arial, sans-serif;
}
.umbc-dd.open { opacity: 1; visibility: visible; transform: none; }
.umbc-dd::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }   /* keeps hover while moving the mouse down */
.umbc-dd a {
  display: block; padding: 10px 14px; border-radius: 9px; color: #103d51; font-size: 15px; line-height: 1.3;
  text-decoration: none; white-space: nowrap; transition: background-color .15s ease, color .15s ease;
}
.umbc-dd a:hover, .umbc-dd a:focus-visible { background: #eaf7fd; color: #0b8fd0; outline: none; }
.umbc-dd a.umbc-active { color: #e88700; font-weight: 600; }
#mission, #about { scroll-margin-top: 110px; }

/* Programs mega menu: every level with its programs */
.umbc-dd.umbc-dd-mega { padding: 14px 14px 10px; min-width: 0; width: min(760px, calc(100vw - 16px)); }
.umbc-mega { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 6px 14px; }
.umbc-mega-col { min-width: 0; }
.umbc-dd a.umbc-mega-cat {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px; margin-bottom: 2px;
  font-weight: 700; color: #103d51; white-space: normal; font-family: "Metropolis 6", "Segoe UI", Arial, sans-serif; font-size: 14.5px;
  border-bottom: 2px solid #eaf2f6; border-radius: 9px 9px 0 0;
}
.umbc-mega-ic { flex: 0 0 auto; width: 28px; height: 28px; }
.umbc-mega-ic svg { display: block; width: 100%; height: 100%; }
.umbc-mega-col > a:not(.umbc-mega-cat) { padding: 7px 10px; font-size: 14px; white-space: normal; color: #2b3a44; }
.umbc-dd a.umbc-mega-all {
  display: block; margin-top: 10px; padding: 11px 12px; text-align: center; border-radius: 10px;
  background: #103d51; color: #fff; font-weight: 600; font-size: 14px;
}
.umbc-dd a.umbc-mega-all:hover { background: #18506a; color: #fff; }
.umbc-dd .umbc-mega-col > a.umbc-active { color: #e88700; font-weight: 600; }
