/* MXPro V4.5 Bilingual Switcher & English Typography Adjustments */

/* Header Language Switcher Button (Desktop & Tablet) */
.header-op-lang {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 36px;
  line-height: 36px !important;
  padding: 0 12px !important;
  margin-left: 8px;
  border-radius: 18px !important;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(0, 0, 0, 0.03);
  color: #424242;
  font-size: 13px !important;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}
.header-op-lang:hover {
  border-color: #e50914;
  color: #e50914;
  background: rgba(229, 9, 20, 0.06);
}
.header-op-lang .mx-lang-globe {
  width: 15px;
  height: 15px;
  display: inline-block;
  flex-shrink: 0;
  fill: currentColor;
}
@media (max-width: 899px) {
  .header-op-lang {
    width: auto !important;
    padding: 0 10px !important;
  }
  .header-op-lang span {
    display: inline !important;
  }
}

/* Mobile top bar compact language button */
.side-op .mx-lang-mobile {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  height: 28px;
  line-height: 28px !important;
  padding: 0 7px !important;
  margin-right: 4px;
  border-radius: 14px !important;
  border: 1px solid rgba(0, 0, 0, 0.15);
  font-size: 12px !important;
  font-weight: 700;
  width: auto !important;
  color: #424242;
  vertical-align: middle;
}
.side-op .mx-lang-mobile:hover {
  border-color: #e50914;
  color: #e50914;
}

/* Floating Right Toolbar Language Button */
.fixedGroup .fixedGroup-item.mx-lang-item {
  font-size: 13px;
  font-weight: 700;
  color: #424242;
}
.fixedGroup .fixedGroup-item.mx-lang-item .mx-lang-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 4px;
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.3px;
}
.fixedGroup .fixedGroup-item.mx-lang-item:hover .mx-lang-badge {
  background-color: #f2f2f2;
  color: #e50914;
}

/* English layout breathing room */
html[lang="en"] .module-item-title {
  width: auto;
  min-width: 78px;
  margin-right: 16px;
}
@media (max-width: 559px) {
  html[lang="en"] .module-item-title {
    min-width: 64px;
    margin-right: 10px;
  }
  .side-op {
    width: auto !important;
    min-width: 118px;
  }
  .homepage .navbar {
    width: calc(100vw - 125px) !important;
  }
  .navbar.open,
  .page .navbar {
    width: calc(100vw - 165px) !important;
  }
}

html[lang="en"] .drop_content {
  width: auto;
  min-width: 168px;
}
html[lang="en"] .member_group .user_list_drop .logout a,
html[lang="en"] .member_group .user_list_drop li a {
  width: 100%;
  white-space: nowrap;
}
html[lang="en"] .module-info-item-title {
  white-space: nowrap;
}
html[lang="en"] .header-op-user {
  min-width: 92px;
  padding: 0 14px;
  white-space: nowrap;
}
html[lang="en"] .navbar-item a span {
  white-space: nowrap;
}

/* Fix sidebar menu item hover layout shift (prevent icon/label wrapping & jumping) */
@media (min-width: 1025px) {
  .sidebar .navbar-item {
    height: 40px;
    line-height: 40px;
  }
  html[lang="en"] .sidebar .navbar-item {
    padding-left: 10px;
  }
  .sidebar .navbar-item a.links {
    display: flex;
    align-items: center;
    position: relative;
    width: 100%;
    height: calc(100% - 2px);
    padding-right: 14px;
    box-sizing: border-box;
  }
  .sidebar .navbar-item i:not(.icon-arrow-go) {
    flex-shrink: 0;
    line-height: 1;
  }
  .sidebar .navbar-item a.links span {
    flex: 1;
    min-width: 0;
    margin-left: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 38px;
  }
  html[lang="en"] .sidebar .navbar-item a.links span {
    margin-left: 7px;
    font-size: 13.5px;
  }
  .sidebar .navbar-item i.icon-arrow-go {
    float: none !important;
    position: absolute;
    right: 0;
    top: 50%;
    margin: 0 !important;
    line-height: 1;
    transform: translate(-8px, -50%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease, color 0.2s ease;
  }
  .sidebar .navbar-item:hover i.icon-arrow-go {
    margin: 0 !important;
    transform: translate(0, -50%);
    opacity: 1;
  }
  .sidebar .navbar-item .links small {
    top: 50%;
    right: 16px;
    transform: translateY(-50%) scale(0.8);
    transform-origin: center right;
  }
  .sidebar .navbar-item.active .links small {
    right: 4px;
  }
}
@media (min-width: 559px) and (max-width: 1024px) {
  html[lang="en"] .sidebar .navbar-item a.links span {
    display: block;
    font-size: 12px;
    padding: 0 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}
html[lang="en"] .mx-sort-pill {
  width: auto !important;
  min-width: 68px;
  padding: 0 12px 0 8px !important;
}
html[lang="en"] .mxprofoot .grid-item-name {
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
html[lang="en"] .fixedGroup .fixedGroup-item .fixedGroup__cell {
  white-space: nowrap;
}
