/* MTS global masthead — Career Areas bar style on all pages */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 44, 82, 0.04);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  padding: clamp(18px, 3vw, 26px) max(24px, 5%);
  z-index: 999;
  font-family: "Roboto", Helvetica, Arial, sans-serif;
  box-shadow: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  transition:
    background 0.45s ease,
    box-shadow 0.45s ease,
    border-color 0.45s ease,
    backdrop-filter 0.45s ease;
}

#masthead .site-header {
  padding: clamp(7.6px, 1.266vw, 10.97px) max(24px, 5%);
}

/* Dual logos: 38px layout box; penguin scaled on hero */
#masthead .site-header .logo .logo-img {
  max-width: 100%;
  box-sizing: border-box;
  object-fit: contain;
  object-position: center;
  filter: none;
}

#masthead .site-header:not(.mts-header--scrolled) .logo-img--on-hero {
  display: block;
  width: calc(38px * 129 / 166);
  height: 38px;
  transform: scale(1.4870625);
  transform-origin: center center;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.35));
}

#masthead .site-header .logo .logo-img--on-light {
  width: calc(38px * 129 / 166);
  height: 38px;
  display: none !important;
}

#masthead .site-header.mts-header--scrolled .logo-img--on-hero {
  display: none !important;
}

#masthead .site-header.mts-header--scrolled .logo-img--on-light {
  display: block !important;
}

/* Solid white bar once scrolled (matches Career Areas) */
#masthead .site-header.mts-header--scrolled {
  background: #ffffff !important;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08), 0 8px 24px rgba(0, 18, 42, 0.08);
  border-bottom-color: rgba(0, 0, 0, 0.1);
}

#masthead .site-header:not(.mts-header--scrolled) .main-nav ul li a {
  text-shadow: 0 1px 12px rgba(0, 18, 42, 0.55);
}

#masthead .site-header.mts-header--scrolled .main-nav ul li a {
  color: #111111 !important;
  text-shadow: none !important;
}

#masthead .site-header.mts-header--scrolled .main-nav ul li a:hover,
#masthead .site-header.mts-header--scrolled .main-nav ul li a.active {
  color: #000000 !important;
}

#masthead .site-header.mts-header--scrolled .main-nav ul li a::after {
  background: #002c52;
}

#masthead .site-header.mts-header--scrolled .mts-careers-search-btn {
  background: #111111;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow:
    0 2px 12px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

#masthead .site-header.mts-header--scrolled .mts-careers-search-btn:hover {
  background: #1a1a1a;
  color: #ffffff;
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

#masthead .site-header.mts-header--scrolled .mts-icon-search {
  color: #ffffff;
}

.header-container {
  max-width: min(1300px, 94vw);
  margin-inline: auto;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(14px, 2.5vw, 28px);
}

#page #masthead ~ * header.site-header {
  display: none !important;
}

.main-nav {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(10.125px, 1.8vw, 24.75px);
  row-gap: 5.625px;
  margin: 0;
  padding: 0;
}

.main-nav ul li a {
  color: rgba(255, 255, 255, 0.94);
  text-decoration: none;
  font-weight: 400;
  font-size: clamp(0.85rem, 1.08vw, 1.0625rem);
  letter-spacing: 0.02em;
  position: relative;
  transition: color 0.25s ease, opacity 0.25s ease;
}

.main-nav ul li a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0%;
  height: 1px;
  background: rgba(128, 214, 251, 0.95);
  transition: width 0.25s ease;
}

.main-nav ul li a:hover,
.main-nav ul li a.active {
  color: #fff;
}

.main-nav ul li a:hover::after,
.main-nav ul li a.active::after {
  width: 100%;
}

/* Careers pill — Career Areas typography */
#masthead .mts-careers-search-btn {
  gap: 7.5px;
  padding: 8px 16px 8px 12px;
  font-family: "Roboto", Helvetica, Arial, sans-serif;
  font-size: 1.09375rem;
  font-weight: 400;
  font-style: normal;
  line-height: 1.25;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#masthead .mts-careers-label {
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  color: inherit;
}

#masthead .mts-icon-search {
  width: 20.625px;
  height: 20.625px;
}

#masthead .mts-icon-search circle,
#masthead .mts-icon-search path {
  stroke-width: 1.75;
}

.mts-careers-search-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: none;
  color: #111;
  cursor: pointer;
  border-radius: 999px;
  box-shadow:
    0 4px 20px rgba(0, 0, 0, 0.12),
    0 1px 0 rgba(255, 255, 255, 0.65) inset;
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.mts-careers-search-btn:hover {
  background: #fafbfc;
  box-shadow:
    0 8px 28px rgba(0, 0, 0, 0.14),
    0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.mts-careers-search-btn:active {
  transform: translateY(1px);
}

.mts-careers-search-btn:focus-visible {
  outline: 2px solid #80d6fb;
  outline-offset: 3px;
}

.mts-icon-search {
  flex-shrink: 0;
  display: block;
  color: #111;
}

.mts-careers-label {
  font-family: inherit;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
  color: inherit;
}

.menu-toggle {
  display: none;
}

@media (max-width: 768px) {
  .header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
  }

  .main-nav {
    flex: unset;
    min-width: unset;
    justify-content: flex-start;
    display: none;
    position: absolute;
    top: 70px;
    right: 5%;
    background: #002c52;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  }

  .main-nav ul {
    flex-direction: column;
    gap: 11.25px;
  }

  .main-nav.show {
    display: flex;
    flex-direction: column;
  }

  .menu-toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
  }

  .menu-toggle span {
    width: 26px;
    height: 3px;
    background-color: #80d6fb;
    border-radius: 2px;
  }

  #masthead .mts-careers-search-btn {
    padding: 6px 12px 6px 9px;
    font-family: "Roboto", Helvetica, Arial, sans-serif;
    font-size: 1.015625rem;
    font-weight: 400;
    font-style: normal;
    line-height: 1.25;
    letter-spacing: 0.02em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }
}

/* Careers search modal */
.mts-careers-modal[hidden] {
  display: none !important;
}

.mts-careers-modal:not([hidden]) {
  display: flex;
  align-items: center;
  justify-content: center;
}

.mts-careers-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
  font-family: "Roboto", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  font-weight: 400;
  padding: 24px;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.mts-careers-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 28, 52, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: pointer;
}

.mts-careers-modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  font-family: inherit;
  font-size: 16px;
  line-height: 1.5;
  font-weight: 400;
  background: linear-gradient(165deg, #002c52 0%, #001a33 100%);
  color: #f8fbff;
  padding: clamp(28px, 5vw, 44px);
  border-radius: 12px;
  box-shadow:
    0 8px 40px rgba(0, 44, 82, 0.45),
    0 0 0 1px rgba(128, 214, 251, 0.35),
    inset 0 1px 0 rgba(128, 214, 251, 0.12);
  border: 1px solid rgba(128, 214, 251, 0.4);
}

.mts-careers-modal__eyebrow {
  margin: 0 0 8px;
  font-family: inherit;
  font-size: 0.875rem;
  line-height: 1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #80d6fb;
  font-weight: 600;
}

.mts-careers-modal__title {
  margin: 0 0 10px;
  font-family: inherit;
  font-size: clamp(2rem, 3.5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: #fff;
  line-height: 1.25;
}

.mts-careers-modal__lead {
  margin: 0 0 28px;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: rgba(232, 245, 255, 0.92);
  font-weight: 400;
}

.mts-careers-modal__form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.mts-careers-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mts-careers-field__label {
  font-family: inherit;
  font-size: 0.875rem;
  line-height: 1rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(128, 214, 251, 0.95);
}

.mts-careers-field input {
  width: 100%;
  box-sizing: border-box;
  background: rgba(0, 26, 48, 0.45);
  border: 1px solid rgba(128, 214, 251, 0.25);
  border-bottom: 2px solid rgba(128, 214, 251, 0.35);
  color: #fff;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  border-radius: 6px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.mts-careers-field input::placeholder {
  color: rgba(200, 226, 243, 0.45);
}

.mts-careers-field input:focus {
  border-color: #80d6fb;
  background: rgba(0, 35, 65, 0.55);
  box-shadow: 0 0 0 3px rgba(128, 214, 251, 0.2);
}

.mts-careers-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.mts-careers-modal__search {
  flex: 1 1 auto;
  min-width: 140px;
  padding: 11px 24px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.875rem;
  line-height: 1.5;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  background: #f24e1e;
  color: #fff;
  border: none;
  border-radius: 6px;
  box-shadow: 0 4px 16px rgba(242, 78, 30, 0.35);
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.mts-careers-modal__search:hover {
  background: #c93d10;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(242, 78, 30, 0.45);
}

.mts-careers-modal__cancel {
  padding: 11px 20px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.5;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  background: transparent;
  color: rgba(232, 245, 255, 0.92);
  border: 2px solid rgba(128, 214, 251, 0.55);
  border-radius: 6px;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.mts-careers-modal__cancel:hover {
  border-color: #80d6fb;
  background: rgba(128, 214, 251, 0.12);
  color: #fff;
}

.mts-careers-modal__hint {
  margin: 14px 0 0;
  font-family: inherit;
  font-size: 0.8125rem;
  line-height: 1.5;
  font-weight: 400;
  color: rgba(200, 226, 243, 0.72);
}

.mts-careers-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  background: rgba(128, 214, 251, 0.1);
  border: 1px solid rgba(128, 214, 251, 0.35);
  border-radius: 8px;
  color: #80d6fb;
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.mts-careers-modal__close:hover {
  background: rgba(128, 214, 251, 0.2);
  color: #fff;
  border-color: #80d6fb;
}

/* Active nav — match inline overrides from page widgets */
.main-nav a.active {
  border-bottom: none !important;
}

#masthead .site-header:not(.mts-header--scrolled) .main-nav a.active {
  color: #fff !important;
  font-weight: 400 !important;
}
