/* Refined mobile navigation: compact, calm, and aligned with the close control. */
.page-thomas-home .primary-nav .mobile-nav-contact {
  display: none;
}

.page-thomas-home .primary-nav .mobile-nav-actions {
  display: none;
}

@media (max-width: 980px) {
  .page-thomas-home .primary-nav .mobile-nav-contact {
    display: block;
  }

  .page-thomas-home .primary-nav .mobile-nav-actions {
    width: fit-content;
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
  }
}

@media (max-width: 980px) {
  .page-thomas-home .primary-nav .mobile-nav-actions a {
    width: auto;
    min-height: 44px;
    padding: 11px 0 9px 20px;
    display: block;
    border: 0;
    color: #252722;
    background: transparent;
    font-family: var(--font-body);
    font-size: 20px;
    font-weight: 500;
    line-height: 1.15;
    letter-spacing: .095em;
    text-align: right;
    text-transform: uppercase;
    transform: translateX(14px);
    opacity: 0;
    transition: color .25s ease, opacity .36s ease, transform .48s cubic-bezier(.16, 1, .3, 1);
  }

  .page-thomas-home .primary-nav .mobile-nav-actions a::after {
    display: block;
    right: 0;
    left: auto;
    bottom: 5px;
    transform: none;
  }

  .page-thomas-home.nav-open .primary-nav .mobile-nav-actions a {
    transform: translateX(0);
    opacity: 1;
  }

  .page-thomas-home.nav-open .primary-nav .mobile-nav-actions a:first-child { transition-delay: .2s; }
  .page-thomas-home.nav-open .primary-nav .mobile-nav-actions a:last-child { transition-delay: .24s; }
}

@media (min-width: 621px) and (max-width: 980px) {
  .page-thomas-home .nav-toggle {
    transition: border-color .3s ease, background-color .3s ease;
  }

  .page-thomas-home.nav-open .nav-toggle {
    border-color: rgba(183, 149, 82, .42);
    background: rgba(255, 255, 255, .78);
  }

  .page-thomas-home .primary-nav {
    justify-content: flex-start;
    align-items: flex-end;
    gap: 0;
    padding: 108px 28px 42px;
    background:
      radial-gradient(circle at 100% 0, rgba(183, 149, 82, .1), transparent 32%),
      linear-gradient(145deg, #fff 0%, #fffdf8 100%);
  }

  .page-thomas-home .primary-nav::before {
    content: "";
    width: 32px;
    height: 1px;
    margin: 0 0 15px;
    background: var(--gold);
  }

  .page-thomas-home .primary-nav a {
    width: fit-content;
    min-height: 48px;
    padding: 11px 0 10px 24px;
    font-family: var(--font-body);
    font-size: clamp(22px, 3vw, 26px);
    font-weight: 500;
    line-height: 1.15;
    letter-spacing: .095em;
    text-align: right;
    text-transform: uppercase;
  }

  .page-thomas-home .primary-nav .mobile-nav-actions a {
    min-height: 48px;
    padding: 11px 0 10px 24px;
    font-size: clamp(22px, 3vw, 26px);
  }

  .page-thomas-home .primary-nav a::after {
    right: 0;
    left: auto;
    bottom: 5px;
    transform: none;
  }
}

@media (max-width: 620px) {
  .page-thomas-home .site-topbar,
  .page-thomas-home .site-topbar.is-hidden {
    transform: none !important;
  }

  .page-thomas-home .site-topbar {
    padding-right: max(14px, env(safe-area-inset-right));
  }

  .page-thomas-home .nav-toggle {
    width: 42px;
    height: 42px;
    border: 1px solid transparent;
    transition: border-color .3s ease, background-color .3s ease;
  }

  .page-thomas-home.nav-open .nav-toggle {
    border-color: rgba(183, 149, 82, .38);
    background: rgba(255, 255, 255, .76);
  }

  .page-thomas-home .nav-toggle > span:not(.sr-only) {
    width: 19px;
    height: 1px;
  }

  .page-thomas-home .primary-nav {
    height: 100dvh;
    min-height: 100dvh;
    max-height: 100dvh;
    justify-content: flex-start;
    align-items: flex-end;
    gap: 0;
    padding:
      max(96px, calc(env(safe-area-inset-top) + 82px))
      max(20px, env(safe-area-inset-right))
      max(30px, env(safe-area-inset-bottom))
      24px;
    background:
      radial-gradient(circle at 100% 0, rgba(183, 149, 82, .1), transparent 31%),
      linear-gradient(145deg, #fff 0%, #fffdf8 100%);
  }

  .page-thomas-home .primary-nav::before {
    content: "";
    width: 28px;
    height: 1px;
    margin: 0 1px 12px 0;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: right center;
    transition: transform .45s cubic-bezier(.16, 1, .3, 1) .08s;
  }

  .page-thomas-home.nav-open .primary-nav::before {
    transform: scaleX(1);
  }

  .page-thomas-home .primary-nav a {
    width: fit-content;
    min-height: 44px;
    padding: 11px 0 9px 20px;
    color: #252722;
    font-family: var(--font-body);
    font-size: 20px;
    font-weight: 500;
    line-height: 1.15;
    letter-spacing: .095em;
    text-align: right;
    text-transform: uppercase;
    transform: translateX(14px);
    opacity: 0;
    transition:
      color .25s ease,
      opacity .36s ease,
      transform .48s cubic-bezier(.16, 1, .3, 1);
  }

  .page-thomas-home .primary-nav a::after {
    right: 0;
    left: auto;
    bottom: 5px;
    transform: none;
  }

  .page-thomas-home.nav-open .primary-nav a {
    transform: translateX(0);
    opacity: 1;
  }

  .page-thomas-home.nav-open .primary-nav > a:nth-child(2) { transition-delay: .04s; }
  .page-thomas-home.nav-open .primary-nav > .primary-nav-sector > .primary-nav-sector-link { transition-delay: .08s; }
  .page-thomas-home.nav-open .primary-nav > a:nth-child(4) { transition-delay: .12s; }
  .page-thomas-home.nav-open .primary-nav > a:nth-child(5) { transition-delay: .16s; }
}

/* Mobile dropdown navigation: keep the brand on the header centerline while
   the menu opens as a contained, centered panel beneath it. */
@media (max-width: 980px) {
  .page-thomas-home .site-topbar {
    position: fixed;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
  }

  .page-thomas-home .topbar-brand {
    position: absolute;
    z-index: 2;
    left: 50%;
    top: 50%;
    height: auto;
    transform: translate(-50%, -50%);
  }

  .page-thomas-home .topbar-brand img,
  .page-thomas-home .site-topbar.is-scrolled .topbar-brand img {
    width: 148px;
    height: 38px;
    object-position: center;
  }

  .page-thomas-home .nav-toggle { margin-left: auto; }

  .page-thomas-home .primary-nav {
    position: fixed;
    top: 74px;
    right: 16px;
    bottom: auto;
    left: 16px;
    width: auto;
    height: auto;
    min-height: 0;
    max-height: calc(100dvh - 90px);
    padding: 28px 20px 30px;
    overflow-y: auto;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    text-align: center;
    border: 1px solid rgba(183, 149, 82, .32);
    border-radius: 2px;
    background: rgba(255, 253, 248, .98);
    box-shadow: 0 18px 40px rgba(40, 34, 24, .14);
    transform: translateY(-12px);
    transition: opacity .25s ease, visibility .25s ease, transform .3s cubic-bezier(.16, 1, .3, 1);
  }

  .page-thomas-home.nav-open .primary-nav { transform: translateY(0); }

  .page-thomas-home .primary-nav::before { margin: 0 auto 18px; }

  .page-thomas-home .primary-nav > a,
  .page-thomas-home .primary-nav-sector,
  .page-thomas-home .primary-nav-sector-link {
    align-self: center;
    text-align: center;
  }

  .page-thomas-home .primary-nav > a,
  .page-thomas-home .primary-nav-sector-link {
    width: 100%;
    padding-inline: 8px;
  }

  .page-thomas-home .primary-nav a::after {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
  }

  .page-thomas-home .primary-nav-sector {
    width: 100%;
    align-items: center;
  }

  .page-thomas-home .primary-nav-sector-chevron {
    right: auto;
    margin-left: 8px;
  }

  .page-thomas-home .primary-nav-sector-menu {
    width: min(100%, 340px);
    padding: 8px 0 0;
    border-right: 0;
    border-top: 1px solid rgba(183, 149, 82, .25);
  }

  .page-thomas-home .primary-nav .primary-nav-sector-menu a {
    grid-template-columns: minmax(0, 1fr);
    text-align: center;
  }

  .page-thomas-home .primary-nav .mobile-nav-actions {
    width: min(100%, 310px);
    align-items: center;
    justify-items: center;
    margin-inline: auto;
  }

  .page-thomas-home .primary-nav .mobile-nav-actions a {
    width: 100%;
    padding-inline: 12px;
    text-align: center;
    transform: none;
  }

  .page-thomas-home .primary-nav .mobile-language {
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 980px) {
  .page-thomas-home .primary-nav-sector {
    width: min(310px, calc(100vw - 48px));
    align-self: auto;
    flex-direction: column;
    align-items: flex-end;
  }

  .page-thomas-home .primary-nav-sector-link { width: fit-content; }
  .page-thomas-home .primary-nav-sector-chevron { right: -14px; }

  .page-thomas-home .primary-nav-sector-menu {
    position: static;
    width: 100%;
    max-height: 0;
    margin: 0;
    padding: 0 16px 0 0;
    grid-template-columns: 1fr;
    gap: 0;
    overflow: hidden;
    background: transparent;
    border: 0;
    border-right: 1px solid rgba(183, 149, 82, .38);
    box-shadow: none;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: none;
    transition: max-height .42s cubic-bezier(.16, 1, .3, 1), opacity .24s ease, visibility .24s ease, margin .3s ease;
  }

  .page-thomas-home .primary-nav-sector-menu::before { display: none; }

  .page-thomas-home .primary-nav .primary-nav-sector-menu a {
    min-height: 38px;
    padding: 8px 0;
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    color: #4b4a44;
    border: 0;
    background: transparent;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 400;
    letter-spacing: .02em;
    line-height: 1.3;
    text-align: left;
    text-transform: none;
    white-space: normal;
    transform: none;
    opacity: 1;
    transition: color .2s ease;
  }

  .page-thomas-home .primary-nav .primary-nav-sector-menu a:hover,
  .page-thomas-home .primary-nav .primary-nav-sector-menu a:focus-visible { color: #8c6725; }

  .page-thomas-home .primary-nav-sector.is-open .primary-nav-sector-menu {
    max-height: 360px;
    margin-top: 4px;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
  }
}

/* Keep homepage headings light and editorial, including text layered over imagery. */
body.page-thomas-home h1,
body.page-thomas-home h2,
body.page-thomas-home h3,
body.page-thomas-home h4,
body.page-thomas-home h5,
body.page-thomas-home h6,
body.page-thomas-home h1 *,
body.page-thomas-home h2 *,
body.page-thomas-home h3 *,
body.page-thomas-home h4 *,
body.page-thomas-home h5 *,
body.page-thomas-home h6 *,
body.page-thomas-home main > section:not(#top) h2,
body.page-thomas-home main > section:not(#top) h2 * {
  font-weight: 200 !important;
  -webkit-text-stroke: 0 !important;
}

body.page-thomas-home main > section#development-path > h2,
body.page-thomas-home main > section#development-path > h2#development-path-title,
body.page-thomas-home main > section#capability-overview h2,
body.page-thomas-home main > section#investment h2,
body.page-thomas-home main > section#ecosystem h2,
body.page-thomas-home main > section#ecosystem .network-heading h2,
body.page-thomas-home main > section#news h2,
body.page-thomas-home main > section#news .news-title h2,
body.page-thomas-home main > section#contact h2 {
  font-weight: 200 !important;
  -webkit-text-stroke: 0 !important;
}

@media (min-width: 981px) {
  /* Lift the hero copy into the visual center of the waterfront image. */
  body.page-thomas-home .opening-copy { transform: translateY(-12px); }
}

@media (max-width: 350px), (max-height: 620px) and (max-width: 620px) {
  .page-thomas-home .primary-nav {
    padding-top: max(84px, calc(env(safe-area-inset-top) + 74px));
  }

  .page-thomas-home .primary-nav::before {
    margin-bottom: 7px;
  }

  .page-thomas-home .primary-nav a {
    min-height: 44px;
    padding-block: 10px 8px;
    font-size: 19px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-thomas-home .primary-nav::before,
  .page-thomas-home .primary-nav a {
    transition-duration: .01ms;
    transition-delay: 0s !important;
  }
}

/* Keep the marked hero headline in the site's unified Plus Jakarta Sans system. */
body.page-thomas-home .opening-copy h1,
body.page-thomas-home .opening-copy h1 * {
  font-family: var(--font-body) !important;
  font-weight: 300 !important;
  letter-spacing: -.02em !important;
  line-height: 1.08 !important;
  overflow: visible !important;
  -webkit-text-stroke: 0 !important;
}

/* Reduce the marked hero headline by 10% and reserve room for Vietnamese diacritics. */
@media (min-width: 1200px) {
  body.page-thomas-home main > section#top .opening-copy h1 {
    font-size: 45px !important;
    line-height: 1.2 !important;
    letter-spacing: .005em !important;
    padding-block: .08em .1em;
  }

  body.page-thomas-home main > section#top .opening-copy h1 > span {
    font-size: inherit !important;
    line-height: inherit !important;
  }
}

@media (min-width: 981px) and (max-width: 1199px) {
  body.page-thomas-home main > section#top .opening-copy h1 {
    font-size: 30.5px !important;
    line-height: 1.24 !important;
    letter-spacing: .005em !important;
    padding-block: .08em .1em;
  }

  body.page-thomas-home main > section#top .opening-copy h1 > span {
    font-size: inherit !important;
    line-height: inherit !important;
  }
}

@media (min-width: 621px) and (max-width: 980px) {
  body.page-thomas-home .opening-copy h1 {
    font-size: clamp(39px, 5.76vw, 43px) !important;
    line-height: 1.2 !important;
    letter-spacing: -.01em !important;
    padding-block: .08em .1em;
  }

  body.page-thomas-home .opening-copy h1 > span {
    font-size: inherit !important;
    line-height: inherit !important;
  }
}

@media (max-width: 620px) {
  body.page-thomas-home .opening-copy h1 {
    font-size: 25px !important;
    line-height: 1.22 !important;
    letter-spacing: -.01em !important;
    padding-block: .1em .12em;
  }

  body.page-thomas-home .opening-copy h1 > span {
    font-size: inherit !important;
    line-height: inherit !important;
  }
}

/* Match the primary banner CTA label to the Discovery Group eyebrow. */
body.page-thomas-home .opening-actions a:first-child {
  font-family: var(--font-body) !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
}

body.page-thomas-home .opening-label,
body.page-thomas-home .opening-actions a:last-child {
  font-family: var(--font-body) !important;
}

/* Match the marked Brand Story heading to the site's Plus Jakarta Sans display system. */
body.page-thomas-home main > section#about .brand-story-copy h2,
body.page-thomas-home main > section#about .brand-story-copy h2 * {
  font-family: var(--font-body) !important;
  font-weight: 300 !important;
  -webkit-text-stroke: 0 !important;
}

/* Keep the marked timeline heading in the same Plus Jakarta Sans family. */
body.page-thomas-home main > section#development-path > h2#development-path-title,
body.page-thomas-home main > section#development-path > h2#development-path-title * {
  font-family: var(--font-body) !important;
  font-weight: 300 !important;
  -webkit-text-stroke: 0 !important;
}

/* Use the Development Path title as the shared section-heading reference. */
body.page-thomas-home main > section:not(#top) h2,
body.page-thomas-home main > section:not(#top) h2 * {
  font-family: var(--font-body) !important;
  font-size: var(--dg-h2) !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
  letter-spacing: .005em !important;
  -webkit-text-stroke: 0 !important;
  text-rendering: optimizeLegibility;
}

body.page-thomas-home main > section:not(#top) h2 {
  padding-block: .14em .08em;
}

body.page-thomas-home main > section:not(#top) h2 * {
  font-size: inherit !important;
  line-height: inherit !important;
  letter-spacing: inherit !important;
  padding: 0;
}

/* Keep key homepage section headings on the same Plus Jakarta Sans scale as
   the Development Path reference. */
body.page-thomas-home main > section#news .news-title h2,
body.page-thomas-home main > section#news .news-title h2 *,
body.page-thomas-home main > section#ecosystem .network-heading h2,
body.page-thomas-home main > section#ecosystem .network-heading h2 *,
body.page-thomas-home main > section#sectors > h2,
body.page-thomas-home main > section#sectors > h2 *,
body.page-thomas-home main > section#capability-overview .capability-copy h2,
body.page-thomas-home main > section#capability-overview .capability-copy h2 * {
  font-family: var(--font-body) !important;
  font-size: var(--dg-h2) !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
  letter-spacing: .005em !important;
  -webkit-text-stroke: 0 !important;
  text-rendering: optimizeLegibility;
}

body.page-thomas-home main > section#news .news-title h2,
body.page-thomas-home main > section#ecosystem .network-heading h2,
body.page-thomas-home main > section#sectors > h2,
body.page-thomas-home main > section#capability-overview .capability-copy h2 {
  padding-block: .14em .08em;
}

body.page-thomas-home main > section#news .news-title h2 *,
body.page-thomas-home main > section#ecosystem .network-heading h2 *,
body.page-thomas-home main > section#sectors > h2 *,
body.page-thomas-home main > section#capability-overview .capability-copy h2 * {
  font-size: inherit !important;
  line-height: inherit !important;
  letter-spacing: inherit !important;
  padding: 0;
}

@media (max-width: 620px) {
  body.page-thomas-home main > section:not(#top) h2,
  body.page-thomas-home main > section:not(#top) h2 * {
    font-size: var(--dg-h2) !important;
    line-height: 1.34 !important;
    letter-spacing: .01em !important;
  }

  body.page-thomas-home main > section#news .news-title h2,
  body.page-thomas-home main > section#news .news-title h2 *,
  body.page-thomas-home main > section#ecosystem .network-heading h2,
  body.page-thomas-home main > section#ecosystem .network-heading h2 *,
  body.page-thomas-home main > section#sectors > h2,
  body.page-thomas-home main > section#sectors > h2 *,
  body.page-thomas-home main > section#capability-overview .capability-copy h2,
  body.page-thomas-home main > section#capability-overview .capability-copy h2 * {
    font-size: var(--dg-h2) !important;
    line-height: 1.34 !important;
    letter-spacing: .01em !important;
  }
}

@media (min-width: 981px) {
  body.page-thomas-home .opening-actions a:first-child {
    font-size: clamp(12px, .95vw, 16px) !important;
    letter-spacing: .12em !important;
  }
}

/* Open the hero description slightly without changing its measure or line rhythm. */
body.page-thomas-home .opening-intro {
  letter-spacing: .02em !important;
}

/* Vietnamese-safe hero typography: keep tone marks attached and lines separated. */
body.page-thomas-home main > section#top .opening-copy h1,
body.page-thomas-home main > section#top .opening-copy h1 * {
  font-family: "Montserrat", sans-serif !important;
  font-weight: 400 !important;
  line-height: 1.28 !important;
  letter-spacing: -.018em !important;
  font-kerning: normal;
  font-feature-settings: "kern" 1;
  text-rendering: optimizeLegibility;
  overflow: visible !important;
  -webkit-text-stroke: 0 !important;
}

body.page-thomas-home main > section#top .opening-copy h1 {
  padding-block: .12em .16em;
}

body.page-thomas-home main > section#top .opening-copy h1 > span {
  display: block !important;
  padding-block: .04em .06em;
  white-space: nowrap;
}

body.page-thomas-home main > section#top .opening-copy h1 > span + span {
  margin-top: .1em !important;
}

@media (max-width: 980px) {
  body.page-thomas-home main > section#top .opening-copy h1,
  body.page-thomas-home main > section#top .opening-copy h1 * {
    line-height: 1.3 !important;
    letter-spacing: -.014em !important;
  }
}

@media (max-width: 620px) {
  body.page-thomas-home main > section#top .opening-copy h1,
  body.page-thomas-home main > section#top .opening-copy h1 * {
    line-height: 1.2 !important;
    letter-spacing: -.01em !important;
    text-align: center;
  }

  body.page-thomas-home main > section#top .opening-copy h1 > span {
    padding-block: .02em .03em;
  }

body.page-thomas-home main > section#top .opening-copy h1 > span + span {
    margin-top: 0 !important;
  }
}

/* Final mobile menu alignment overrides. */
@media (max-width: 980px) {
  .page-thomas-home .site-topbar { position: fixed; grid-template-columns: 1fr auto; align-items: center; }
  .page-thomas-home .topbar-brand { position: absolute; z-index: 2; left: 50%; top: 50%; height: auto; transform: translate(-50%, -50%); }
  .page-thomas-home .topbar-brand img,
  .page-thomas-home .site-topbar.is-scrolled .topbar-brand img { width: 148px; height: 38px; object-position: center; }
  .page-thomas-home .nav-toggle { margin-left: auto; }
  .page-thomas-home .primary-nav {
    top: 74px;
    right: 16px;
    bottom: auto;
    left: 16px;
    width: auto;
    height: auto;
    min-height: 0;
    max-height: calc(100dvh - 90px);
    padding: 28px 20px 30px;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    border: 1px solid rgba(183, 149, 82, .32);
    border-radius: 2px;
    background: rgba(255, 253, 248, .98);
    box-shadow: 0 18px 40px rgba(40, 34, 24, .14);
    transform: translateY(-12px);
  }
  .page-thomas-home.nav-open .primary-nav { transform: translateY(0); }
  .page-thomas-home .primary-nav::before { margin-inline: auto; }
  .page-thomas-home .primary-nav > a,
  .page-thomas-home .primary-nav-sector,
  .page-thomas-home .primary-nav-sector-link { align-self: center; text-align: center; }
  .page-thomas-home .primary-nav > a,
  .page-thomas-home .primary-nav-sector-link { width: 100%; padding-inline: 8px; }
  .page-thomas-home .primary-nav a::after { right: auto; left: 50%; transform: translateX(-50%); }
  .page-thomas-home .primary-nav-sector { width: 100%; align-items: center; }
  .page-thomas-home .primary-nav-sector-chevron { right: auto; margin-left: 8px; }
  .page-thomas-home .primary-nav-sector-menu {
    width: min(100%, 340px);
    padding: 8px 0 0;
    border: 0;
    border-top: 1px solid rgba(183, 149, 82, .25);
  }
  .page-thomas-home .primary-nav .primary-nav-sector-menu a { width: 100%; display: flex; align-items: center; justify-content: center; gap: 10px; text-align: center; }
  .page-thomas-home .primary-nav .mobile-nav-actions { width: min(100%, 310px); margin-inline: auto; align-items: center; justify-items: center; }
  .page-thomas-home .primary-nav .mobile-nav-actions a { width: 100%; padding-inline: 12px; text-align: center; }
  .page-thomas-home .primary-nav .mobile-language { justify-content: center; text-align: center; }
}

/* Mobile hero header: pin the brand to the left until the navigation is open.
   The open state keeps the logo on the menu's visual axis. */
@media (max-width: 980px) {
  .page-thomas-home .topbar-brand {
    position: relative;
    left: auto;
    top: auto;
    height: 100%;
    transform: none;
    justify-content: flex-start;
  }

  .page-thomas-home .topbar-brand img,
  .page-thomas-home .site-topbar.is-scrolled .topbar-brand img {
    width: 148px;
    height: 38px;
    object-position: left center;
  }

  .page-thomas-home.nav-open .topbar-brand {
    position: absolute;
    left: 50%;
    top: 50%;
    height: auto;
    transform: translate(-50%, -50%);
  }

  .page-thomas-home.nav-open .topbar-brand img,
  .page-thomas-home.nav-open .site-topbar.is-scrolled .topbar-brand img {
    object-position: center;
  }
}

@media (max-width: 620px) {
  body.page-thomas-home > .site-topbar {
    padding-left: 20px !important;
    padding-right: 12px !important;
  }
}

/* Align the mobile hero headline with the Discovery Group eyebrow above it. */
@media (max-width: 620px) {
  body.page-thomas-home main > section#top .opening-copy h1,
  body.page-thomas-home main > section#top .opening-copy h1 * {
    text-align: left !important;
  }
}

/* Keep language controls beside the mobile menu trigger, outside the dropdown. */
@media (max-width: 980px) {
  .page-thomas-home > .site-topbar > .mobile-language {
    position: absolute;
    z-index: 4;
    top: 50%;
    right: 64px;
    display: flex;
    transform: translateY(-50%);
  }

  .page-thomas-home > .site-topbar > .mobile-language button {
    width: 28px;
    height: 28px;
  }

  .page-thomas-home > .site-topbar > .mobile-language button img {
    width: 20px;
    height: 14px;
  }

  .page-thomas-home .primary-nav .mobile-language {
    display: none !important;
  }

  .page-thomas-home > .site-topbar > .nav-toggle {
    z-index: 4;
  }

  /* Leave room for the language rail when the navigation panel is open. */
  .page-thomas-home.nav-open .topbar-brand {
    position: relative;
    left: auto;
    top: auto;
    height: 100%;
    transform: none;
    justify-content: flex-start;
  }

  .page-thomas-home.nav-open .topbar-brand img,
  .page-thomas-home.nav-open .site-topbar.is-scrolled .topbar-brand img {
    width: 148px;
    height: 38px;
    object-position: left center;
  }
}

@media (max-width: 380px) {
  .page-thomas-home > .site-topbar > .mobile-language {
    right: 60px;
    gap: 2px;
    padding: 3px;
  }

  .page-thomas-home > .site-topbar > .mobile-language button {
    width: 25px;
    height: 27px;
  }
}

@media (max-width: 340px) {
  .page-thomas-home .topbar-brand img,
  .page-thomas-home .site-topbar.is-scrolled .topbar-brand img,
  .page-thomas-home.nav-open .topbar-brand img,
  .page-thomas-home.nav-open .site-topbar.is-scrolled .topbar-brand img {
    width: 120px;
    height: 32px;
  }

  .page-thomas-home > .site-topbar > .mobile-language {
    right: 58px;
  }
}
