/* Header-wide disclosures share one glass surface; mobile keeps the same links in flow. */
:root {
  --mega-ink: #172b49;
  --mega-muted: #53647d;
  --mega-line: #bdcce066;
  --mega-accent: #293895;
  --mega-ease: cubic-bezier(.22, .7, .22, 1);
}
/* Keep the header's blur on a sibling layer so it does not block the panel's backdrop. */
.site-header, .inner-page .site-header { -webkit-backdrop-filter: none; backdrop-filter: none; }
.site-header::after { content: ''; position: absolute; inset: 0; z-index: -2; border-radius: inherit; pointer-events: none; -webkit-backdrop-filter: blur(22px) saturate(130%); backdrop-filter: blur(22px) saturate(130%); }
.site-header > nav { position: static; }
.site-header .site-nav-mega { position: static; }
.site-header .site-nav-mega[data-open]::before {
  inset-block-start: calc(100% - 8px);
  inset-inline: 0;
  width: auto;
  max-width: none;
  height: 25px;
}
.site-header .site-nav-mega > .site-nav-link { padding-inline-start: 12px; }
.site-header .site-nav-mega > .site-nav-toggle { width: 32px; }
.site-nav-mega[data-open] > .site-nav-link > .site-nav-label::after { transform: scaleX(1); }
.site-header .mega-menu {
  position: absolute;
  inset-block-start: calc(100% + 14px);
  inset-inline: 0;
  z-index: 8;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 264px;
  gap: 12px;
  width: auto;
  max-width: none;
  max-height: min(640px, calc(100dvh - 150px));
  padding: 12px;
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid #ffffffbf;
  border-radius: 24px;
  background: linear-gradient(125deg, #fffffff5, #f0f5fbed 65%, #e1ebf5f0);
  color: var(--mega-ink);
  box-shadow: 0 28px 70px #06152e38, 0 5px 18px #102a4514, inset 0 1px 0 #fff;
  -webkit-backdrop-filter: blur(28px) saturate(145%);
  backdrop-filter: blur(28px) saturate(145%);
  scrollbar-gutter: stable;
}
.mega-menu[hidden] { display: none !important; }
.mega-menu[data-closing] { pointer-events: none; }
.site-header .mega-menu[data-closing] { z-index: 7; }
.mega-main { min-width: 0; padding: 19px 22px 8px; }
.mega-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.mega-eyebrow { display: flex; align-items: center; gap: 8px; color: var(--mega-muted); font-size: 12px; font-weight: 500; line-height: 1.8; }
.mega-eyebrow::before { content: ''; width: 18px; height: 2px; border-radius: 2px; background: var(--red, #ed1c24); }
.mega-title { margin: 7px 0 0; color: var(--mega-ink); font-size: clamp(21px, 1.8vw, 28px); font-weight: 700; line-height: 1.65; }
.site-header .mega-menu a { text-decoration: none; white-space: normal; }
.site-header .mega-menu a::after { content: none; }
.site-header .mega-menu a[data-active] { color: var(--mega-accent); }
.mega-menu svg { display: block; width: 22px; height: 22px; flex-shrink: 0; }
.site-header .mega-menu .mega-overview {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-shrink: 0;
  min-height: 44px;
  padding: 9px 14px;
  border: 1px solid #bac9de;
  border-radius: 11px;
  background: #ffffff8c;
  color: var(--mega-accent);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.7;
  transition: background 160ms, border-color 160ms;
}
.site-header .mega-menu .mega-overview:hover { background: #fff; border-color: var(--mega-accent); }
.mega-overview svg { width: 17px; height: 17px; }
.mega-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.site-header .mega-menu .mega-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 17px;
  min-width: 0;
  min-height: 167px;
  padding: 18px 16px;
  border: 1px solid var(--mega-line);
  border-radius: 16px;
  background: linear-gradient(140deg, #ffffffae, #ffffff40);
  color: var(--mega-ink);
  transition: background 180ms, border-color 180ms, box-shadow 180ms, transform 180ms var(--mega-ease);
}
.mega-card-icon { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid #c9d5e8; border-radius: 12px; background: linear-gradient(135deg, #fff, #eaf0fb); color: var(--mega-accent); box-shadow: 0 3px 8px #263c6810, inset 0 1px 0 #fff; }
.mega-card-icon svg { width: 23px; height: 23px; }
.mega-card-copy { display: grid; gap: 6px; min-width: 0; }
.mega-card-title { color: var(--mega-ink); font-size: 16px; font-weight: 700; line-height: 1.8; overflow-wrap: anywhere; }
.mega-card-description { color: var(--mega-muted); font-size: 12px; font-weight: 400; line-height: 1.9; }
.mega-card > .mega-arrow { position: absolute; inset-inline-end: 16px; top: 27px; color: #7183a0; transition: transform 180ms var(--mega-ease), color 180ms; }
.mega-arrow svg { width: 19px; height: 19px; }
.site-header .mega-menu .mega-card:is(:hover, :focus-visible) { transform: translateY(-3px); background: #fff; border-color: #94a9cf; box-shadow: 0 10px 24px #23477c10; }
.mega-card:is(:hover, :focus-visible) > .mega-arrow { transform: translateX(-3px); color: var(--mega-accent); }
.site-header .mega-menu .mega-card:is([aria-current=page], [data-active]) { border-color: var(--mega-accent); background: #edf1ff; }
.site-header .mega-menu .mega-footer {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 57px;
  margin-top: 19px;
  padding: 13px 2px 3px;
  border-top: 1px solid var(--mega-line);
  border-radius: 0;
  background: transparent;
  color: var(--mega-accent);
  font-size: 14px;
  line-height: 1.8;
}
.mega-footer-note { color: var(--mega-muted); font-size: 12px; font-weight: 400; }
.mega-footer strong { margin-inline-start: auto; font-weight: 500; }
.site-header .mega-menu .mega-footer:hover { color: #182867; }
.mega-footer:hover strong { text-decoration: underline; text-underline-offset: 5px; }
.mega-footer > svg { width: 18px; height: 18px; }
.site-header .mega-menu .mega-feature {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: space-between;
  gap: 0;
  min-height: 327px;
  padding: 23px 22px;
  overflow: hidden;
  border: 1px solid #d5e5ff33;
  border-radius: 17px;
  background: radial-gradient(ellipse at 25% 35%, #536e9a80, transparent 65%), linear-gradient(145deg, #293f64, #10243d);
  color: #fff;
}
.mega-feature--products::before { content: ''; position: absolute; z-index: -1; inset: 10% -28% 20%; border: 1px solid #c8dbfa20; border-radius: 50%; transform: rotate(-25deg); box-shadow: 0 0 0 25px #d4e4ff07, 0 0 0 50px #d4e4ff05; pointer-events: none; }
.mega-feature-label { position: relative; z-index: 1; align-self: flex-start; color: #d5e2f4; font:9px/1.7 AbayanNumerals,Arial, sans-serif; letter-spacing: 1.65px; }
.mega-feature img { width: 100%; height: 164px; margin: 4px 0 10px; object-fit: contain; transition: transform 260ms var(--mega-ease); }
.mega-feature--products img { transform: scale(1.17); filter: drop-shadow(0 16px 14px #0004); }
.mega-feature-copy { position: relative; z-index: 1; display: grid; gap: 5px; padding-inline-end: 22px; }
.mega-feature-copy strong { color: #fff; font-size: 22px; font-weight: 700; line-height: 1.7; }
.mega-feature-copy > span { color: #d5e2f4; font-size: 12px; font-weight: 400; line-height: 1.8; }
.mega-feature-arrow { position: absolute; inset-inline-end: 19px; bottom: 38px; display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid #c6d7f154; border-radius: 50%; background: #ffffff0d; }
.mega-feature--about img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; margin: 0; object-fit: cover; }
.mega-feature--about::before { content: ''; position: absolute; z-index: -1; inset: 0; background: linear-gradient(180deg, #10243e5c, #10243e08 30%, #10243ee8 85%); }
.mega-feature--about .mega-feature-label { padding: 5px 8px; border: 1px solid #ffffff45; border-radius: 6px; background: #122c4a80; backdrop-filter: blur(8px); }
.mega-feature--products:is(:hover, :focus-visible) img { transform: scale(1.23) translateY(-3px); }
.mega-feature--about:is(:hover, :focus-visible) img { transform: scale(1.04); }
.site-header .mega-menu :is(.mega-card, .mega-overview, .mega-footer):focus-visible { outline: 2px solid var(--mega-accent); outline-offset: 3px; box-shadow: 0 0 0 5px #fff; }
.site-header .mega-menu .mega-feature:focus-visible { outline: 2px solid #fff; outline-offset: -5px; box-shadow: none; }
html[dir=ltr] :is(.mega-arrow, .mega-overview, .mega-footer) > svg { transform: rotate(180deg); }
html[dir=ltr] .mega-card:is(:hover, :focus-visible) > .mega-arrow { transform: translateX(3px); }
@media(min-width:1201px) and (max-width:1380px) {
  .site-header { gap: 10px; padding-inline: 18px; }
  .site-header .brand, .site-header .brand img { width: 144px; }
  .site-header > nav { gap: 10px; }
  .site-header .site-nav-link { padding-inline: 6px; font-size: 15px; }
  html[lang=en] .site-header .site-nav-link { font-size: 14px; }
  .site-header .site-nav-mega > .site-nav-link { padding-inline: 8px 2px; }
  .site-header .site-nav-mega > .site-nav-toggle { width: 28px; }
  .site-header .header-consult { display: none; }
  .site-header .mega-menu { grid-template-columns: minmax(0, 1fr) 230px; }
  .mega-main { padding-inline: 15px; }
  .mega-card-title { font-size: 15px; }
  .site-header .mega-menu .mega-card { padding-inline: 13px; }
}
/* The customer portal is a utility action beside the site's primary navigation. */
.site-portal {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 8px 12px;
  border: 1px solid #d3e0f2;
  border-radius: 10px;
  background: #edf3fc;
  color: var(--mega-ink);
  font-size: 14px;
  line-height: 1.55;
  text-decoration: none;
  transition: background-color var(--action-time), border-color var(--action-time);
}
.site-header > .site-portal { flex: none; white-space: nowrap; }
.site-portal strong { font-weight: 700; }
.site-portal svg { display: block; flex: none; }
.site-portal-external { color: var(--mega-accent); }
.site-portal:is(:hover, :focus-visible) { background: #fff; border-color: #fff; }
.site-portal:active { background: #dde8f7; }
.mobile-menu > nav > .site-portal {
  display: flex;
  gap: 12px;
  min-height: 66px;
  margin-block-end: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 16px;
}
.site-portal-tile {
  display: grid;
  flex: none;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #dbe6f8;
  color: var(--mega-accent);
}
.site-portal-copy { display: grid; gap: 2px; min-width: 0; }
.site-portal-copy small { color: var(--mega-muted); font-size: 12px; font-weight: 500; }
.mobile-menu .site-portal-external { margin-inline-start: auto; }
@media(min-width:1201px) {
  header.site-header:has(> .site-portal) {
    inset-inline: max(16px, calc((100vw - 1560px) / 2));
    gap: clamp(9px, calc(2vw - 16px), 14px);
    padding-inline: 16px;
  }
  .site-header:has(> .site-portal) > nav {
    flex: 1 0 auto;
    justify-content: center;
    gap: clamp(10px, calc(4vw - 38px), 26px);
    margin: 0;
    margin-inline-end: clamp(6px, calc(2vw - 18px), 12px);
    padding-inline: 8px 10px;
    border-inline-end: 1px solid #d6e4ff38;
  }
  .site-header:has(> .site-portal) :is(.brand, .brand img) { width: 132px; }
  .site-header:has(> .site-portal) :is(nav > .site-nav-link, .site-nav-mega > .site-nav-link) { padding-inline: 3px; }
  .site-header:has(> .site-portal) .site-nav-mega > .site-nav-toggle { width: 26px; }
  html[lang=en] .site-header:has(> .site-portal) > nav { gap: clamp(10px, calc(3vw - 26px), 22px); }
  html[lang=en] .site-header:has(> .site-portal) > nav .site-nav-link { font-size: 14px; }
  html[lang=en] .site-header > .site-portal { gap: 6px; padding-inline: 10px; font-size: 13px; }
}
@media(min-width:1451px) and (max-width:1640px) {
  .site-header:has(> .site-portal) .language-selector > summary { width: 46px; padding: 9px; }
  .site-header:has(> .site-portal) .language-selector :is(.language-current, .language-chevron) { display: none; }
}
@media(max-width:1200px) {
  .site-header > .site-portal { display: none; }
}
@media(prefers-reduced-motion:reduce) {
  .site-portal { transition: none; }
}

/* An accordion on touch screens: decorative content yields to generous link targets. */
.mobile-menu .mega-menu { display: block; margin: 0 10px 12px; padding: 12px; border: 1px solid #b5c9eb33; border-radius: 13px; background: #071a3038; color: #fff; }
.mobile-menu .mega-main { padding: 0; }
.mobile-menu .mega-heading { display: block; margin: 0 0 10px; }
.mobile-menu .mega-heading-copy, .mobile-menu .mega-feature { display: none; }
.mobile-menu .mega-overview { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 44px; padding: 9px 10px; border-radius: 8px; color: #fff; font-size: 14px; font-weight: 500; }
.mobile-menu .mega-overview svg { width: 18px; height: 18px; }
.mobile-menu .mega-grid { grid-template-columns: minmax(0, 1fr); gap: 7px; }
.mobile-menu .mega-card { display: flex; align-items: center; gap: 12px; min-height: 68px; padding: 11px 10px; border: 1px solid #b5c9eb29; border-radius: 10px; background: #ffffff06; }
.mobile-menu .mega-card-icon { width: 38px; height: 38px; flex-shrink: 0; border-color: #c8d7f236; background: #ffffff0c; color: #e0eaff; box-shadow: inset 0 1px 0 #ffffff12; }
.mobile-menu .mega-card-copy { gap: 1px; }
.mobile-menu .mega-card-title { color: #fff; font-size: 15px; }
.mobile-menu .mega-card-description { color: #c2d0e5; font-size: 12px; }
.mobile-menu .mega-card > .mega-arrow { position: static; margin-inline-start: auto; color: #c2d0e5; }
.mobile-menu .mega-footer { display: flex; align-items: center; gap: 10px; min-height: 48px; margin-top: 12px; padding: 12px 10px 3px; border-top: 1px solid #b5c9eb33; color: #e0eaff; font-size: 13px; }
.mobile-menu .mega-footer-note { display: none; }
.mobile-menu .mega-footer strong { margin-inline-start: 0; margin-inline-end: auto; }
.mobile-menu .mega-footer svg { width: 18px; height: 18px; }
.mobile-menu .mega-menu a:is(:hover, :focus-visible) { background: #ffffff14; }
.mobile-menu .mega-card:is([aria-current=page], [data-active]) { background: #ffffff18; border-color: #c8d7f2a0; }
.mobile-menu .mega-menu a::after { content: none; }
@media(prefers-reduced-motion:reduce) {
  .mega-menu :is(a, img, .mega-arrow) { transition: none !important; }
  .mega-menu .mega-card:is(:hover, :focus-visible), .mega-card:is(:hover, :focus-visible) > .mega-arrow { transform: none; }
  .mega-feature--products:is(:hover, :focus-visible) img { transform: scale(1.17); }
  .mega-feature--about:is(:hover, :focus-visible) img { transform: none; }
}
