/* TOBI 8-language switcher styles v3 */
.tobi-language-desktop,
.tobi-language-float {
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

.tobi-language-float {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  transition: transform .25s ease, opacity .25s ease;
}

.tobi-language-float.is-suppressed {
  transform: translateY(120%);
  opacity: 0;
  pointer-events: none;
}

.tobi-language-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid rgba(11, 31, 58, 0.12);
  border-radius: 999px;
  background: #fff;
  color: #0B1F3A;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(11, 31, 58, 0.08);
  transition: border-color .2s ease, box-shadow .2s ease;
}

.tobi-language-trigger:hover,
.tobi-language-trigger:focus-visible {
  border-color: #FF5B2E;
  box-shadow: 0 4px 12px rgba(255, 91, 46, 0.18);
  outline: none;
}

.tobi-language-trigger__globe,
.tobi-language-trigger__chevron {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tobi-language-trigger__chevron {
  transition: transform .2s ease;
}

.is-open .tobi-language-trigger__chevron {
  transform: rotate(180deg);
}

.tobi-language-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 156px;
  background: #fff;
  border: 1px solid rgba(11, 31, 58, 0.10);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(11, 31, 58, 0.14);
  padding: 6px;
  display: none;
  flex-direction: column;
  gap: 2px;
}

.tobi-language-desktop .tobi-language-menu,
.tobi-language-float .tobi-language-menu {
  right: 0;
}

.is-open .tobi-language-menu {
  display: flex;
}

.tobi-language-option {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px 10px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #0B1F3A;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  transition: background .15s ease;
}

.tobi-language-option:hover,
.tobi-language-option:focus-visible {
  background: #FFF0EB;
  outline: none;
}

.tobi-language-option__short {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 4px;
  background: #F4F6F8;
  color: #0B1F3A;
  font-size: 11px;
  font-weight: 700;
}

.tobi-language-option[aria-checked="true"] {
  color: #FF5B2E;
  font-weight: 600;
}

.tobi-language-option[aria-checked="true"] .tobi-language-option__short {
  background: #FF5B2E;
  color: #fff;
}

.tobi-language-option svg {
  width: 14px;
  height: 14px;
  margin-left: auto;
  fill: none;
  stroke: #FF5B2E;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0;
}

.tobi-language-option[aria-checked="true"] svg {
  opacity: 1;
}

/* Mobile panel inside drawer */
.tobi-language-mobile-panel {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.tobi-language-mobile-panel > p {
  margin: 0 0 10px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  opacity: 0.7;
}

.tobi-language-mobile-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.tobi-language-mobile-options .tobi-language-option {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-radius: 8px;
  padding: 10px;
}

.tobi-language-mobile-options .tobi-language-option:hover,
.tobi-language-mobile-options .tobi-language-option:focus-visible {
  background: rgba(255, 91, 46, 0.20);
}

.tobi-language-mobile-options .tobi-language-option__short {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.tobi-language-mobile-options .tobi-language-option[aria-checked="true"] .tobi-language-option__short {
  background: #FF5B2E;
}

.tobi-language-mobile-options .tobi-language-option svg {
  stroke: #fff;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .tobi-language-float,
  .tobi-language-trigger__chevron,
  .tobi-language-option,
  .tobi-language-trigger {
    transition: none;
  }
}
