.fn-header-user-tools {
  display: flex;
  float: right;
  align-items: center;
  gap: 16px;
  row-gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}
.fn-header-user-tools > .news_btn {
  order: 0;
  margin-right: 0;
}
.fn-header-user-tools > .space_lang {
  order: 1;
}
.fn-header-user-tools > .fn-area-switch {
  order: 2;
}
.fn-header-user-tools > .log_link {
  order: 3;
}
.fn-area-switch {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  box-sizing: border-box;
  width: 140px;
  height: 30px;
  padding: 2px;
  border-radius: 100px;
  background: #b3b3b326;
  border: 1.5px solid #ffffff40;
  box-shadow: inset 0 0 6px #003c9729;
  backdrop-filter: blur(3px);
}
a.fn-area-switch__tab {
  color: #000000;
}

.fn-area-switch__label {
  position: relative;
}
.fn-area-switch__clip {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
}
.fn-area-switch__clip text {
  font: inherit;
}
.fn-area-switch__tab:not(.fn-area-switch__tab--active) .fn-area-switch__text {
  color: rgb(0 26 86 / 20%);
  mix-blend-mode: multiply;
}
@supports (
  (backdrop-filter: blur(5px)) or (-webkit-backdrop-filter: blur(5px))
) {
  .fn-area-switch__tab:not(.fn-area-switch__tab--active) .fn-area-switch__text {
    /*color: transparent;*/
  }
  /* XD background blur uses the glyphs as its mask; 25% controls the fill. */
  .fn-area-switch__tab:not(.fn-area-switch__tab--active)
    > .fn-area-switch__label::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgb(0 0 0 / 25%);
    -webkit-backdrop-filter: blur(5px) brightness(90%);
    backdrop-filter: blur(5px) brightness(90%);
    clip-path: var(--fn-area-switch-text-clip);
    mix-blend-mode: multiply;
    pointer-events: none;
  }
}

.fn-area-switch > a.fn-area-switch__tab {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 0;
  height: 24px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border-radius: 18px;
  background: transparent;
  color: #64748b;
  font-family: "Univers LT 65", Arial, sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 24px;
  text-decoration: none;
  white-space: nowrap;
}
.fn-area-switch > a.fn-area-switch__tab--active {
  background: #fff;
  color: #182743;
  box-shadow: 0 1px 3px rgb(24 39 67 / 22%);
}
.fn-area-switch > a.fn-area-switch__tab:hover {
  color: #182743;
}
.fn-area-switch > a.fn-area-switch__tab:focus-visible {
  outline: 2px solid #79aef2;
  outline-offset: 2px;
}
@media (max-width: 767px) {
  .fn-header-user-tools {
    gap: 6px;
  }
  .fn-header-user-tools > .news_btn,
  .fn-header-user-tools > .space_lang {
    padding-left: 4px;
    padding-right: 4px;
  }
}
@media (max-width: 480px) {
  .fn-header-user-tools .fn-header-news-label {
    display: none;
  }
}

@media (min-width: 991px) and (max-width: 1399px) {
  .fn-header-user-tools--switch {
    gap: 6px;
  }
  .fn-header-user-tools--switch > .news_btn,
  .fn-header-user-tools--switch > .space_lang {
    padding-left: 4px;
    padding-right: 4px;
  }
  .fn-header-user-tools--switch .fn-header-news-label {
    display: none;
  }
}

@media (max-width: 359px) {
  .fn-header--area-switch .logo.mobile {
    margin-right: 8px;
  }
}

/* The indicator follows a drag without waiting for the destination page. */
.fn-area-switch--interactive {
  position: relative;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.fn-area-switch__thumb {
  display: none;
}
.fn-area-switch--interactive > .fn-area-switch__thumb {
  display: block;
  position: absolute;
  left: 2px;
  top: 50%;
  width: calc((100% - 4px) / 2);
  height: 24px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 1px 3px rgb(24 39 67 / 22%);
  transform: translate(calc(var(--fn-area-switch-position, 0) * 100%), -50%);
  transition:
    transform 160ms cubic-bezier(0.2, 0.8, 0.2, 1),
    background-color 160ms;
  pointer-events: none;
}
.fn-area-switch--interactive > a.fn-area-switch__tab {
  position: relative;
  cursor: pointer;
  -webkit-user-drag: none;
}
.fn-area-switch--interactive > a.fn-area-switch__tab--active {
  background: transparent;
  box-shadow: none;
}
.fn-area-switch--interactive[data-position="prime"] > .fn-area-switch__thumb {
  background: #182743;
}
.fn-area-switch--interactive[data-position="prime"]
  > a.fn-area-switch__tab--active {
  color: #fff;
}
.fn-area-switch--interactive[data-dragging] > .fn-area-switch__thumb {
  transition: none;
}
.fn-area-switch--interactive[data-dragging] > a.fn-area-switch__tab {
  cursor: grabbing;
}
@media (prefers-reduced-motion: reduce) {
  .fn-area-switch--interactive > .fn-area-switch__thumb {
    transition: none;
  }
}

/* Keep the profile menu inside the viewport, anchored to the avatar's right edge. */
.fn-header-user-tools > .log_link {
  position: relative;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  float: none;
  display: block;
}
.fn-header-user-tools > .log_link > .bullet_log {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  background: transparent;
  text-decoration: none;
}
.fn-header-user-tools > .log_link > .bullet_log:focus-visible {
  outline: 2px solid #79aef2;
  outline-offset: 2px;
}
.fn-header-user-tools .top_user_photo {
  display: inline-flex;
  flex: 0 0 auto;
  float: none;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 50px;
  height: 50px;
  margin: 0;
  padding: 2px;
  border: 2px solid #17c964;
  border-radius: 50%;
  background: #fff;
  overflow: hidden;
}
.fn-header-user-tools .top_user_photo > img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.fn-header-user-tools > .log_link > .log_div {
  top: 100% !important; /* The existing global rule also sets top with !important. */
  right: 0;
  left: auto;
  width: max-content;
  min-width: 200px;
  max-width: calc(100vw - 24px);
  padding-top: 8px;
}
.fn-header-user-tools .log_div > .user_menu {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0;
}
.fn-header-user-tools .log_div > .user_menu a {
  box-sizing: border-box;
  width: 100%;
  white-space: normal;
  overflow-wrap: break-word;
}

/* The notification follows the icon even when the News label is hidden. */
.header_fix .news_btn .fn-header-news-icon {
  position: relative;
  display: inline-flex;
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  margin-right: 7px;
  transform: translateY(-1px);
}
.header_fix .news_btn .fn-header-news-icon > svg {
  display: block;
  width: 20px !important;
  height: 20px !important;
  margin: 0 !important;
  transform: none;
}
.header_fix .fn-header-news-icon > .notification-dot {
  box-sizing: border-box;
  width: 10px;
  height: 10px;
  top: -2px;
  left: -2px;
  right: auto;
  margin: 0;
  pointer-events: none;
}

.fn-header-user-tools .fn-header-user-initials {
  color: #233357;
  font-family: "Univers LT 65", Arial, sans-serif;
  font-size: 16px;
  letter-spacing: 0.5px;
}
.fn-header-user-tools .fn-header-profile-summary {
  box-sizing: border-box;
  padding: 12px 20px 10px;
  margin: 0 0 4px;
  border-bottom: 1px solid #e5e7eb;
  color: #233357;
  font-family: "Univers LT 65", Arial, sans-serif;
  line-height: 1.3;
  white-space: normal;
  overflow-wrap: anywhere;
}
