/* The public and client pages share this header. */
html.client-page { scroll-behavior: auto; }

.react-site #root .sticky.top-0.z-50,
.react-site #root .min-\[950px\]\:hidden.block.relative.z-50 {
  display: none !important;
}

.premium-header {
  font: 650 14px/1.4 system-ui, sans-serif;
}

.premium-nav-wrap {
  position: relative;
  gap: clamp(.75rem, 1.6vw, 1.6rem);
}

.premium-logo { flex: 0 0 auto; }
.premium-logo img { width: clamp(8rem, 12vw, 11rem); }

.premium-navigation {
  gap: clamp(.55rem, 1.15vw, 1.15rem);
  margin-left: auto;
}

.premium-header .premium-navigation > a,
.premium-services-menu > summary { white-space: nowrap; }

.premium-header .premium-navigation > a { color: inherit; }
.premium-header .premium-navigation > a:hover { color: #fff; }
.premium-header .premium-services-dropdown a { color: rgba(255,255,255,.84); }
.premium-header .premium-services-dropdown a:hover { color: #fff; }
.client-portal .skip-link { color: #fff; }

.b2b-account-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: .65rem;
}

.premium-header .b2b-account-actions > a,
.b2b-account-menu > summary {
  display: inline-flex;
  min-height: 2.5rem;
  align-items: center;
  border-radius: .55rem;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}

.b2b-account-actions .b2b-account-cta,
.b2b-account-menu > summary {
  padding: 0 .8rem;
  border: 1px solid #8975d0;
  background: #4f368e;
}

.b2b-account-actions > a:hover,
.b2b-account-menu > summary:hover { text-decoration: underline; }

.b2b-account-menu { position: relative; }
.b2b-account-menu > summary { cursor: pointer; list-style: none; }
.b2b-account-menu > summary::-webkit-details-marker { display: none; }
.b2b-account-menu > summary::after {
  width: .4rem;
  height: .4rem;
  margin: -.2rem 0 0 .5rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  content: '';
  transform: rotate(45deg);
}

.b2b-account-menu[open] > summary::after {
  margin-top: .2rem;
  transform: rotate(225deg);
}

.b2b-account-panel {
  position: absolute;
  top: calc(100% + .55rem);
  right: 0;
  width: min(14rem, calc(100vw - 2rem));
  max-height: calc(100dvh - 4.5rem);
  overflow: auto;
  box-sizing: border-box;
  padding: .4rem;
  border: 1px solid #ded9ec;
  border-radius: .7rem;
  background: #fff;
  box-shadow: 0 16px 36px #0f172a35;
}

.b2b-account-panel p {
  margin: 0 .15rem .3rem;
  padding: .55rem .6rem;
  border-bottom: 1px solid #e9e5f1;
  color: #4f368e;
  font-size: .8rem;
}

.premium-header .b2b-account-panel a,
.b2b-account-panel button {
  display: block;
  box-sizing: border-box;
  width: 100%;
  padding: .6rem .7rem;
  border: 0;
  border-radius: .35rem;
  background: transparent;
  color: #241946;
  font: inherit;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.b2b-account-panel form { margin: 0; }
.b2b-account-panel a:hover,
.b2b-account-panel button:hover { background: #f0ebfa; }
.premium-header :focus-visible { outline: 2px solid #b7a5f6; outline-offset: 2px; }
.client-portal :is(#upload, #file-requests, #credit-history, #order-details) { scroll-margin-top: 5.25rem; }

@media (max-width: 1120px) {
  .premium-nav-wrap { min-height: 64px; }
  .premium-menu-button { display: inline-flex; margin-left: auto; font: inherit; cursor: pointer; }
  .premium-navigation {
    position: absolute;
    inset: calc(100% + 1px) 0 auto;
    display: none;
    max-height: calc(100dvh - 72px);
    flex-direction: column;
    align-items: stretch;
    gap: .2rem;
    box-sizing: border-box;
    overflow-y: auto;
    padding: .65rem;
    border-radius: 0 0 .7rem .7rem;
    background: #0f172a;
    box-shadow: 0 16px 36px #0f172a35;
  }
  .premium-navigation.open { display: flex; }
  .premium-navigation > a,
  .premium-services-menu > summary { display: block; padding: .6rem .7rem; }
  .premium-services-dropdown { position: static; width: auto; transform: none; margin-top: .25rem; box-shadow: none; }
}

@media (max-width: 410px) {
  .premium-nav-wrap { width: calc(100% - 1.25rem); gap: .5rem; }
  .premium-logo img { width: clamp(5.3rem, 25vw, 7rem); }
  .premium-menu-button,
  .b2b-account-actions .b2b-account-cta,
  .b2b-account-menu > summary { padding-inline: .55rem; }
  .b2b-account-actions { gap: .45rem; }
}
