.language-control {
  position: relative;
  z-index: 60;
  flex: none;
  font-family: "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.header-actions {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

.language-trigger {
  display: grid;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid #dededb;
  border-radius: 999px;
  place-items: center;
  color: #050505;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(5, 5, 5, 0.06);
  appearance: none;
  cursor: pointer;
}

.language-trigger:hover,
.language-trigger[aria-expanded="true"] {
  color: #050505;
  border-color: #c9c9c5;
  background: #f5f5f2;
}

.language-trigger svg {
  display: block;
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.language-popover {
  position: absolute;
  z-index: 70;
  top: calc(100% + 12px);
  right: 0;
  display: grid;
  width: min(280px, calc(100vw - 40px));
  gap: 4px;
  padding: 10px;
  border: 1px solid #dededb;
  border-radius: 22px;
  color: #050505;
  background: #ffffff;
  box-shadow:
    0 22px 54px rgba(5, 5, 5, 0.14),
    0 4px 14px rgba(5, 5, 5, 0.08);
}

.language-popover[hidden] {
  display: none;
}

.language-option {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 14px;
  border: 0;
  border-radius: 14px;
  color: #050505;
  background: transparent;
  font: 600 0.95rem/1.2 "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-align: left;
  cursor: pointer;
}

.language-option:hover,
.language-option:focus-visible,
.language-option[aria-checked="true"] {
  color: #050505;
  background: #f3f3f0;
}

.language-option-check {
  width: 17px;
  height: 17px;
  flex: none;
  visibility: hidden;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.language-option[aria-checked="true"] .language-option-check {
  visibility: visible;
}

.mobile-language-launcher {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 0;
  border-radius: 14px;
  color: #050505;
  background: transparent;
  font: 600 0.95rem/1.2 "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-align: left;
  cursor: pointer;
}

.mobile-language-launcher:hover,
.mobile-language-launcher:focus-visible {
  color: #050505;
  background: #f3f3f0;
}

.mobile-language-launcher-icon,
.mobile-language-launcher-chevron {
  width: 19px;
  height: 19px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.mobile-language-launcher-current {
  min-width: 0;
  margin-left: auto;
  overflow: hidden;
  color: #777774;
  font-size: 0.82rem;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-language-launcher-chevron {
  width: 15px;
  height: 15px;
}

.language-control--floating {
  position: fixed;
  z-index: 80;
  top: 20px;
  right: 24px;
}

.site-nav .header-actions {
  gap: 18px;
}

.invite-topbar-inner .language-control {
  margin-left: auto;
}

.legal-mobile-menu {
  display: none;
  position: relative;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
}

.legal-mobile-menu summary {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  gap: 9px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #050505;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(67deg, #eeaeca, #94bbe9) border-box;
  box-shadow: 0 2px 8px rgba(5, 5, 5, 0.06);
  cursor: pointer;
  font: 600 0.9rem/1.2 "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  list-style: none;
}

.legal-mobile-menu summary::before {
  width: 16px;
  height: 12px;
  border-radius: 2px;
  background:
    linear-gradient(#050505, #050505) 0 0 / 16px 2px no-repeat,
    linear-gradient(#050505, #050505) 0 5px / 16px 2px no-repeat,
    linear-gradient(#050505, #050505) 0 10px / 16px 2px no-repeat;
  content: "";
}

.legal-mobile-menu summary:hover,
.legal-mobile-menu[open] summary {
  background:
    linear-gradient(#f5f5f2, #f5f5f2) padding-box,
    linear-gradient(67deg, #eeaeca, #94bbe9) border-box;
}

.legal-mobile-menu summary::-webkit-details-marker {
  display: none;
}

.legal-mobile-menu nav {
  position: absolute;
  z-index: 70;
  top: calc(100% + 12px);
  right: 0;
  display: grid;
  width: min(280px, calc(100vw - 40px));
  gap: 4px;
  padding: 10px;
  border: 1px solid #dededb;
  border-radius: 22px;
  color: #050505;
  background: #ffffff;
  box-shadow:
    0 22px 54px rgba(5, 5, 5, 0.14),
    0 4px 14px rgba(5, 5, 5, 0.08);
}

.legal-mobile-menu nav a {
  display: flex;
  min-height: 48px;
  align-items: center;
  padding: 0 14px;
  border-radius: 14px;
  color: #050505;
  font-weight: 600;
  text-decoration: none;
}

.legal-mobile-menu nav a:hover,
.legal-mobile-menu nav a:focus-visible,
.legal-mobile-menu nav a[aria-current="page"] {
  color: #050505;
  background: #f3f3f0;
}

@media (max-width: 820px) {
  .header-actions .desktop-nav,
  .site-nav .legal-desktop-nav {
    display: none;
  }

  .header-actions .mobile-menu,
  .site-nav .legal-mobile-menu {
    display: block;
  }

  .header-actions--language-in-menu .language-control {
    position: absolute;
  }

  .header-actions--language-in-menu .language-trigger {
    display: none;
  }

  .header-actions--language-in-menu .language-popover {
    position: fixed;
    top: 76px;
    right: 20px;
  }
}

@media (max-width: 540px) {
  .header-actions {
    gap: 9px;
  }

  .language-popover {
    position: fixed;
    top: 76px;
    right: 20px;
  }

  .language-control--floating {
    top: 14px;
    right: 20px;
  }
}

@media (max-width: 720px) {
  :root {
    --nav-height: 64px;
  }

  .site-nav {
    min-height: var(--nav-height);
    align-items: center;
    flex-direction: row;
    gap: 14px;
    padding: 0 20px;
  }

  .site-nav .header-actions {
    gap: 9px;
  }
}
