/* Sidebar scrolling and compact selectors */
.topbar {
  height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
  scrollbar-width: thin;
}

.topbar::-webkit-scrollbar {
  width: 6px;
}

.topbar::-webkit-scrollbar-track {
  background: transparent;
}

.topbar::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  background-clip: padding-box;
}

.top-actions {
  flex: 1 0 auto;
  min-height: min-content;
}

.tabs,
.sidebar-collapsed .tabs {
  overflow: visible;
  scrollbar-width: auto;
}

.timezone-menu,
.language-menu {
  border-radius: 11px;
  background:
    radial-gradient(circle at 100% 0, rgba(48, 207, 174, 0.07), transparent 9rem),
    #121d30;
  box-shadow: 0 16px 42px rgba(2, 8, 18, 0.42), inset 0 1px rgba(255, 255, 255, 0.03);
}

.selector-popover-head {
  gap: 8px;
}

.selector-popover-head > div {
  gap: 0;
}

.selector-popover-head strong {
  font-size: 11px;
}

.selector-popover-head span:not(.selector-popover-icon) {
  display: none;
}

.selector-popover-icon {
  border-radius: 7px;
  font-size: 8px;
}

.timezone-search {
}

.timezone-search::before {
}

.timezone-search::after {
}

.timezone-search input {
  border-radius: 7px;
  font-size: 11px;
}

.timezone-options {
}

.language-options {
}

.timezone-option,
.language-option {
}

.timezone-option {
}

.language-option {
}

.selector-option-copy {
  gap: 0;
}

.selector-option-code {
  width: 27px;
  height: 27px;
  border-radius: 7px;
  font-size: 8px;
}

.selector-option-check {
  width: 17px;
  height: 17px;
}

[aria-selected="true"] .selector-option-check {
  box-shadow: 0 0 0 3px rgba(48, 207, 174, 0.08);
}

@media (max-width: 760px) {
  body.mobile-nav-open {
    height: 100dvh;
    overflow: hidden;
    overscroll-behavior: none;
    touch-action: none;
  }

  .topbar {
    bottom: auto;
    height: 100dvh;
    max-height: 100dvh;
    padding-bottom: max(15px, env(safe-area-inset-bottom));
  }

  .mobile-nav-toggle {
    transition: opacity 120ms ease, transform 120ms ease;
  }

  .mobile-nav-open .mobile-nav-toggle {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.88);
  }

  .mobile-nav-open .topbar .sidebar-collapse {
    display: grid;
  }

  .timezone-menu,
  .language-menu {
  }
}

/* Mobile alignment and single-line selector options */
.timezone-option,
.language-option {
}

.timezone-option .selector-option-copy,
.language-option .selector-option-copy {
  min-width: 0;
}

.language-option .selector-option-code {
}

.language-option .selector-option-copy {
}

.timezone-option .selector-option-check,
.language-option .selector-option-check {
  justify-self: end;
  align-self: center;
}

.language-option {
}

.language-option .selector-option-copy {
}

.language-option .selector-option-copy small {
  display: none;
}

.language-option .selector-option-copy strong {
  display: block;
}

@media (max-width: 760px) {
  .topbar .tabs,
  .sidebar-collapsed .topbar .tabs {
    justify-items: stretch;
  }

  .topbar .tab,
  .sidebar-collapsed .topbar .tab {
    grid-template-columns: 30px minmax(0, 1fr);
    justify-content: stretch;
    justify-items: start;
    text-align: left;
  }

  .topbar .nav-label {
    justify-self: start;
    text-align: left;
  }

  .topbar .nav-group-label {
    width: 100%;
    text-align: left;
  }
}

/* Dense sidebar selector layout */
.timezone-menu {
  right: 0;
  left: auto;
  width: min(226px, calc(100vw - 30px));
}

.language-menu {
}

.selector-popover-head {
  min-height: 38px;
  padding: 6px 7px 6px 9px;
}

.selector-popover-icon {
  width: 24px;
  height: 24px;
}

.timezone-search {
  padding: 5px;
}

.timezone-search::before {
  top: 14px;
  left: 16px;
}

.timezone-search::after {
  top: 23px;
  left: 25px;
}

.timezone-search input {
  min-height: 32px;
  padding-left: 30px;
}

.timezone-options {
  max-height: min(184px, 32vh);
  padding: 3px;
}

.language-options {
}

.timezone-option {
  min-height: 39px;
  grid-template-columns: minmax(0, 1fr) 16px;
  column-gap: 6px;
  padding: 4px 6px;
}

.timezone-option .selector-option-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
}

.timezone-option .selector-option-copy strong {
  line-height: 1.15;
}

.timezone-option .selector-option-copy small {
  margin-top: 2px;
  line-height: 1.1;
}

.language-option {
}

.language-option .selector-option-code {
}

.language-option .selector-option-code::after {
  margin-left: 5px;
  color: #66758b;
  content: "\2014";
}

.language-option[aria-selected="false"] .selector-option-code {
  color: #8190a5;
}

.language-option .selector-option-copy strong {
  line-height: 1.2;
}

.timezone-option .selector-option-check,
.language-option .selector-option-check {
  width: 15px;
  height: 15px;
}

[aria-selected="true"] .selector-option-check::after {
  width: 5px;
  height: 2px;
}

@media (max-width: 760px) {
  .timezone-menu {
    width: min(226px, calc(100vw - 58px));
  }

  .language-menu {
  }
}

/* Full-width selectors, refreshed logo and sidebar button states */
.brand-mark {
  display: block;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border: 0;
  border-radius: 12px;
  background: none;
  box-shadow: 0 10px 26px rgba(20, 174, 225, 0.16);
  object-fit: contain;
  transform: none;
}

.brand-mark::after {
  display: none;
}

.timezone-menu,
.language-menu {
  right: 0;
  left: 0;
  width: 100%;
}

.timezone-options,
.language-options {
}

.timezone-option,
.language-option {
  position: relative;
  width: 100%;
  padding-right: 29px;
}

.language-option {
}

.language-option .selector-option-code {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: #8c9bb0;
  font: 720 8px/1 ui-monospace, SFMono-Regular, Consolas, monospace;
}

.language-option .selector-option-code::after {
  display: none;
}

.language-option[aria-selected="true"] .selector-option-code {
  border-color: rgba(48, 207, 174, 0.24);
  background: rgba(48, 207, 174, 0.11);
  color: #62dfc4;
}

.language-option .selector-option-copy strong {
  font-size: 11px;
}

.language-options {
  gap: 4px;
  padding: 5px;
}

.language-menu .selector-popover-head {
  display: none;
}

.language-option {
  display: grid;
  min-height: 38px;
  grid-template-columns: 29px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  padding: 5px 31px 5px 7px;
}

.language-option .selector-option-check {
}

.timezone-option .selector-option-check,
.language-option .selector-option-check {
  position: absolute;
  top: 50%;
  right: 8px;
  grid-column: auto;
  margin: 0;
  transform: translateY(-50%);
}

.language-option .selector-option-code {
  grid-row: 1;
  grid-column: 1;
  align-self: center;
}

.language-option .selector-option-copy {
  display: block;
  grid-row: 1;
  grid-column: 2;
  align-self: center;
}

.topbar .button.secondary:hover,
.topbar .button.secondary:focus-visible {
  border-color: rgba(48, 207, 174, 0.32);
  background: rgba(48, 207, 174, 0.11);
  color: #effffb;
  box-shadow: 0 6px 18px rgba(4, 12, 25, 0.22);
}

@media (max-width: 760px) {
  .timezone-menu,
  .language-menu {
    width: 100%;
  }
}
