/* Header polish. Loaded on every page, additive to the theme's own header CSS —
   nothing here changes structure or the dropdown behaviour, only how it reads.

   The right-hand group is now: language · Apply now · insight. "Contact Us" is
   gone (it sat where the primary action belongs and duplicated the footer), and
   the plain "Log-in" text link became the insight wordmark, in insight's own
   colours, because that is the product students recognise. */

/* ── top-level nav items ─────────────────────────────────────────────────── */
.header__menu > ul > li > a{
  position:relative;
  font-weight:600;
  transition:color .22s ease;
}
/* One hairline that grows from the middle — the previous state change was a
   colour flick with nothing to follow it. */
.header__menu > ul > li{position:relative}
/* On the <li>, not on the <a>: the theme draws its dropdown chevron with the
   link's own ::after, and putting the underline there erased every arrow. */
.header__menu > ul > li::after{
  content:"";position:absolute;left:0;right:0;bottom:-8px;height:2px;border-radius:2px;
  background:linear-gradient(90deg,#ff00a7,#4800ff);pointer-events:none;
  transform:scaleX(0);transform-origin:center;transition:transform .28s cubic-bezier(.22,.61,.36,1);
}
.header__menu > ul > li:hover::after,
.header__menu > ul > li.current-menu-item::after,
.header__menu > ul > li.current-menu-ancestor::after{transform:scaleX(1)}

/* ── the action group on the right ───────────────────────────────────────── */
/* Apply first, language after it: the action leads, the setting follows.
   Ordered in CSS rather than in the markup so the mobile drawer, which reuses
   the same block, keeps the same reading order. */
.header__btns{display:flex;align-items:center;gap:36px}
.header__btns .nbsx-apply{order:1}
.header__btns .switcher{order:2}

/* Apply now — a white-outline pill over the hero (blueprint §3.7): no gradient,
   no shadow; the gradient budget on the first screen belongs to the dock
   numerals. Same size as before: the 1px border replaces 1px of padding.
   Once the header goes solid (core.js adds .is-solid past 80px) it fills ink. */
.nbsx-apply{
  display:inline-flex;align-items:center;gap:8px;white-space:nowrap;
  padding:10px 21px;border-radius:100px;border:1px solid rgba(255,255,255,.75);
  font-weight:800;font-size:14px;color:#fff;
  background:transparent;
  text-decoration:none;
  transition:transform .2s ease,background-color .2s ease,border-color .2s ease,color .2s ease;
}
.nbsx-apply:hover{color:#fff;transform:translateY(-1px);border-color:#fff;background-color:rgba(255,255,255,.12)}
.header.is-solid .nbsx-apply{background-color:#221c4a;border-color:#221c4a;color:#fff}
.header.is-solid .nbsx-apply:hover{background-color:#2d2560;border-color:#2d2560}
.nbsx-apply svg{flex:none}

/* Headroom (core.js, ≤700px): the bar slides away on scroll-down past 600px
   and comes back on the first scroll-up — transform only, never height. */
.header{transition:transform .25s cubic-bezier(.65,0,.35,1)}
.header.is-hidden{transform:translateY(-100%)}
@media (prefers-reduced-motion:reduce){.header{transition:none}}

/* (the old header anchor .nbsx-insight was removed 2026-09-09 — the class now names the homepage section) */

@media (max-width:1100px){
  .header__btns{gap:28px}
  .nbsx-apply{padding:10px 18px;font-size:13px}
}

/* ── insight, now a menu item ────────────────────────────────────────────── */
/* It sits third in the nav, among the sections, but it is a product name, so it
   keeps its own case and its own colours instead of pretending to be a page. */
.header__menu > ul > li.nbsx-insight-item > a{
  font-weight:800;font-size:16px;letter-spacing:-.015em;text-transform:lowercase;
  background:linear-gradient(100deg,#ff00a7,#8b7bff);
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.header__menu > ul > li.nbsx-insight-item{padding-left:2px}
/* No hairline under it — a gradient word over a gradient rule is noise. */
.header__menu > ul > li.nbsx-insight-item::after{display:none}

/* ── language switcher ───────────────────────────────────────────────────── */
/* Was a bare "En ˅" floating next to a filled button. Now a quiet capsule that
   matches the header's other controls, with the current language spelled in
   full-caps code and a globe to say what it is without a label. */
.switcher{
  position:relative;display:inline-flex;align-items:center;
  background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.16);
  border-radius:100px;padding:0;cursor:pointer;
  transition:background .2s ease,border-color .2s ease;
}
.switcher:hover{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.3)}
.switcher__select{display:inline-flex;align-items:center;gap:7px;padding:9px 14px 9px 12px}
.switcher__select::before{
  content:"";width:15px;height:15px;flex:none;opacity:.85;
  background:currentColor;
  -webkit-mask:var(--nbsx-globe) center/contain no-repeat;mask:var(--nbsx-globe) center/contain no-repeat;
}
.switcher__select-span{
  font-weight:800;font-size:12.5px;letter-spacing:.09em;text-transform:uppercase;line-height:1;
}
.switcher__select-svg{width:9px;height:6px;opacity:.75;transition:transform .22s ease}
.switcher:hover .switcher__select-svg{transform:translateY(1px)}
/* The dropdown becomes a small card rather than a bare list. */
.swithcer__dropdown{
  position:absolute;top:calc(100% + 8px);right:0;min-width:110px;z-index:40;
  background:#120e2b;border:1px solid rgba(140,125,235,.35);border-radius:14px;
  padding:6px;list-style:none;margin:0;
  box-shadow:0 22px 44px -20px rgba(0,0,0,.9);
}
.switcher__item{margin:0}
.switcher__link{
  display:block;padding:9px 12px;border-radius:10px;
  font-weight:700;font-size:13px;letter-spacing:.06em;text-transform:uppercase;
  color:#e8e4ff;text-decoration:none;transition:background .18s ease,color .18s ease;
}
.switcher__link:hover{background:linear-gradient(100deg,rgba(255,0,167,.22),rgba(72,0,255,.22));color:#fff}

:root{--nbsx-globe:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.9' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M3 12h18M12 3a15 15 0 0 1 0 18a15 15 0 0 1 0-18'/%3E%3C/svg%3E")}

/* ── layout of the bar itself ────────────────────────────────────────────── */
/* The nav sat bunched against the logo with a hole before the buttons, and the
   gaps between items came from each item's own padding, so they were uneven.
   One explicit gap, and the menu takes the middle of whatever space is left. */
.header__left{flex:1 1 auto;display:flex;align-items:center;gap:clamp(20px,3vw,44px);min-width:0}
.header__left .header__menu{margin-inline:auto}
.header__left .header__menu > ul{display:flex;align-items:center;gap:clamp(20px,2.3vw,38px)}
.header__left .header__menu > ul > li{margin:0}
.header__left .header__menu > ul > li > a{display:inline-flex;align-items:center;line-height:1}

/* The theme hangs its dropdown chevron off every top-level link, including the
   ones that have nothing to drop down. insight is a link to another product,
   not a section with children. */
.header__menu > ul > li.nbsx-insight-item > a::after{display:none}

/* ── focus, restored ──────────────────────────────────────────────────────
   The legacy stylesheet kills every focus ring on the whole site
   (assets/css/main.css:370 — `*:focus{outline:none}`), and core.css only puts
   one back inside .nbsx-sec, .nbsx-footer and .nbsx-bar. Everything else — the
   header, the legacy templates, every control on them — was focusable with no
   visual indication at all (WCAG 2.4.7). This file loads on every page and
   after main.min.css, so the ring belongs here.

   `html :focus-visible` outranks `*:focus` on specificity, so nothing needs
   !important; :focus-visible means a mouse user still sees nothing change. */
html :focus-visible{outline:2px solid #4800ff;outline-offset:2px}
/* Inside the header the ring is two-toned, because the bar itself is
   transparent: what sits behind a focused control is the hero, ink on the
   homepage and near-white on the inner pages, and no single colour survives
   both. White reads on the ink and on the dark dropdown cards; the indigo
   halo underneath it reads on a pale hero. One of the two is always visible,
   and neither is drawn until the focus is a keyboard focus. */
.header :focus-visible{outline-color:#fff;box-shadow:0 0 0 4px #4800ff}

/* ── the dropdown triggers ────────────────────────────────────────────────
   assets/nbsx/header.js gives Programs / Students / Social life the button
   role, aria-expanded and Escape; the open state now shows the same hairline
   hover already draws, so a menu opened from the keyboard is anchored to its
   heading exactly as a hovered one is. */
.header__menu > ul > li.active::after{transform:scaleX(1)}

/* ── the language capsule ─────────────────────────────────────────────────
   .switcher used to be a <button> wrapped around the list of links; it is now
   a plain positioned wrapper, and .switcher__select is the real button. Same
   box, same colours, same type — only the UA button defaults are removed, and
   the radius is there so the focus ring follows the capsule instead of boxing
   it. */
.switcher > .switcher__select{
  -webkit-appearance:none;appearance:none;
  margin:0;border:0;background:none;color:inherit;font:inherit;line-height:1;
  border-radius:100px;text-align:left;cursor:pointer;
}

/* ── The solid header ──────────────────────────────────────────────────────
   The transparent bar with white text belongs over the dark WebGL hero. Every
   other page opens on white, where it was invisible: core.js marks those pages
   .nbsx-solid-always, and here the bar paints itself — white ground, ink text,
   the ink logo, a hairline instead of a hard edge. The homepage still fades to
   the same treatment past the hero (.is-solid without .nbsx-solid-always). */
.header.is-solid{
  background:#fff;
  box-shadow:0 1px 0 rgba(34,28,74,.12);
  transition:background-color .25s cubic-bezier(.65,0,.35,1),box-shadow .25s cubic-bezier(.65,0,.35,1),transform .25s cubic-bezier(.65,0,.35,1);
}
/* The legacy .header-after is a dark canvas plate behind the bar. It belongs to
   the transparent state over the WebGL hero; on the solid header it would paint
   navy over the white ground. */
.header.is-solid .header-after{display:none}
.header.is-solid .menu,
.header.is-solid .header__menu a,
.header.is-solid .header__btns,
.header.is-solid .switcher,
.header.is-solid .switcher__btn{color:#221c4a}
.header.is-solid .header__menu > ul > li::after{background:linear-gradient(90deg,#FF00A7,#4800FF)}
/* the theme's white wordmark cannot be read on white: swap in the ink one */
.header.is-solid .logo__img{opacity:0}
.header.is-solid .logo__link{
  display:inline-block;
  background:url("img/logo-ink.png") left center / contain no-repeat;
}
/* the switcher capsule, on white: same shape, ink instead of white */
.header.is-solid .switcher{background:#fff;border-color:rgba(34,28,74,.22)}
.header.is-solid .switcher:hover{background:rgba(34,28,74,.04);border-color:rgba(34,28,74,.42)}
.header.is-solid .switcher__select{color:#221c4a}
.header.is-solid .switcher__select-svg{fill:#221c4a;color:#221c4a}
/* the burger, on white */
.header.is-solid .header__toggle span,
.header.is-solid .header__toggle span::before,
.header.is-solid .header__toggle span::after{background-color:#221c4a}
/* insight keeps its own colours in both states */
.header.is-solid .nbsx-insight-item > a{-webkit-text-fill-color:transparent}
@media (prefers-reduced-motion:reduce){.header.is-solid{transition:none}}
