.language-toggle {
  position: fixed;
  top: 54px;
  left: 50%;
  right: auto;
  z-index: 9998;
  min-width: 76px;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(63, 224, 255, 0.45);
  border-radius: 999px;
  background: rgba(4, 14, 25, 0.92);
  color: #a7f2ff;
  box-shadow: 0 0 18px rgba(63, 224, 255, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  font: 700 12px/1 ui-sans-serif, system-ui, sans-serif;
  cursor: pointer;
  transform: translateX(-50%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.language-toggle:hover {
  transform: translate(-50%, -1px);
  border-color: rgba(55, 240, 165, 0.8);
  background: rgba(8, 29, 38, 0.96);
  color: #75f3bd;
}

.language-toggle:focus-visible {
  outline: 2px solid #3fe0ff;
  outline-offset: 3px;
}

html[dir="rtl"] .text-left {
  text-align: right;
}

html[dir="rtl"] .text-right {
  text-align: left;
}

html[dir="rtl"] main [class~="text-[6.5px]"],
html[dir="rtl"] main [class~="text-[7px]"],
html[dir="rtl"] main [class~="text-[7.5px]"] {
  font-size: 9px;
}

html[dir="rtl"] main [class~="text-[8px]"] {
  font-size: 10px;
}

html[dir="rtl"] main [class~="text-[9px]"] {
  font-size: 11px;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child {
  direction: ltr;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child > button {
  direction: ltr;
  unicode-bidi: isolate;
  white-space: nowrap;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 .btn-ghost {
  letter-spacing: normal;
  text-transform: none;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between {
  direction: ltr;
}

html[dir="ltr"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child {
  order: 3;
}

html[dir="ltr"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > :nth-child(2) {
  order: 2;
}

html[dir="ltr"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:last-child {
  order: 1;
}

html[dir="rtl"] main div:has(> div[style*="translate3d(-50%"]) {
  direction: ltr;
}

html[dir="rtl"] main .select-none.text-center {
  width: 140px;
  direction: rtl;
  white-space: normal;
  line-height: 1.15;
  letter-spacing: normal;
}

html[dir="rtl"] main .select-none.text-center > .whitespace-nowrap.text-\[13px\] {
  white-space: normal;
}

html[dir="rtl"] main .absolute[class*="bottom-[104px]"][class*="right-6"] > .glass {
  width: min(248px, calc(100vw - 32px));
  direction: ltr;
  text-align: left;
}

html[dir="rtl"] main .absolute[class*="bottom-[104px]"][class*="right-6"] {
  right: auto;
  left: 24px;
}

html[dir="rtl"] main .absolute[class*="bottom-[104px]"][class*="right-6"] > .glass .font-mono {
  direction: rtl;
  text-align: right;
  font-family: ui-sans-serif, system-ui, sans-serif;
  font-size: 9px;
  overflow-wrap: anywhere;
}

html[dir="rtl"] main .absolute[class*="bottom-[104px]"][class*="right-6"] > .glass .font-mono > div {
  white-space: normal;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child > button:first-child::before {
  content: "←";
  margin-right: 0.4rem;
}

html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child > button:nth-child(2)::after {
  content: "→";
  margin-left: 0.4rem;
}

html[dir="rtl"] main .right-8.top-1\/2 {
  right: auto;
  left: 2rem;
}

html[dir="rtl"] main p,
html[dir="rtl"] main h1,
html[dir="rtl"] main h2,
html[dir="rtl"] main h3 {
  line-height: 1.75;
}

.neo-presenters-card {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.8rem;
  padding: 0.7rem 1.1rem 0.8rem;
  border: 1px solid rgba(63, 224, 255, 0.35);
  border-radius: 14px;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(63, 224, 255, 0.12), transparent 75%),
    linear-gradient(135deg, rgba(6, 20, 33, 0.92), rgba(7, 15, 28, 0.82));
  box-shadow:
    0 0 24px rgba(63, 224, 255, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.neo-presenters-label {
  color: #76eaff;
  font: 700 9px/1.2 ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.neo-presenters-names {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.neo-presenters-names span {
  padding: 0.35rem 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font: 800 13px/1.15 ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0.1em;
  text-shadow: 0 0 12px rgba(63, 224, 255, 0.2);
}

@media (max-width: 600px) {
  .language-toggle {
    top: 50px;
    left: 50%;
    right: auto;
    min-width: 68px;
    min-height: 32px;
    padding: 0 11px;
    font-size: 11px;
  }

  .neo-presenters-card {
    max-width: calc(100vw - 36px);
    gap: 0.45rem;
    padding: 0.6rem 0.7rem 0.7rem;
  }

  .neo-presenters-names {
    gap: 0.35rem;
  }

  .neo-presenters-names span {
    padding: 0.32rem 0.5rem;
    font-size: 11px;
  }

  html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between {
    padding-right: 12px;
    padding-left: 12px;
  }

  html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2:first-child > button {
    padding-right: 0.55rem;
    padding-left: 0.55rem;
    font-size: 0.65rem;
  }

  html[dir="rtl"] main:has(.absolute[class*="bottom-[104px]"][class*="right-6"]) .flex.h-full.flex-col.justify-center.px-6 {
    justify-content: flex-start;
    padding-top: 72px;
  }

  html[dir="rtl"] main:has(.absolute[class*="bottom-[104px]"][class*="right-6"]) .pointer-events-auto.max-w-\[430px\] > div:last-child > .mt-5.space-y-1\.5 {
    display: none;
  }
}

@media (max-width: 340px) {
  html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between {
    flex-wrap: wrap;
    row-gap: 0.4rem;
  }

  html[dir="rtl"] main .absolute.inset-x-0.bottom-0.z-30 > .flex.items-center.justify-between > .flex.items-center.gap-2 {
    flex: 0 0 100%;
    justify-content: space-between;
  }

  html[dir="rtl"] main .absolute[class*="bottom-[104px]"][class*="right-6"] {
    right: auto;
    left: 16px;
    bottom: 132px;
  }
}

@media (max-width: 340px) and (max-height: 600px) {
  html[dir="rtl"] main:has(.absolute[class*="bottom-[104px]"][class*="right-6"]) .pointer-events-auto.max-w-\[430px\] h2 {
    font-size: 21px;
    line-height: 1.1;
  }

  html[dir="rtl"] main:has(.absolute[class*="bottom-[104px]"][class*="right-6"]) .pointer-events-auto.max-w-\[430px\] > div:nth-child(3) {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .language-toggle {
    transition: none;
  }
}
