/* Give Consult One's fixed controls separate, predictable positions. */
body .trp-language-switcher.trp-floating-switcher {
  position: fixed !important;
  inset: auto auto max(24px, env(safe-area-inset-bottom)) 24px !important;
  transform: none !important;
  border-radius: 10px !important;
  z-index: 999900 !important;
}
body .c1-scheme {
  position: fixed !important;
  inset: auto auto calc(96px + env(safe-area-inset-bottom)) 24px !important;
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 8px !important;
  width: max-content !important;
  max-width: calc(100vw - 48px) !important;
  padding: 8px 12px !important;
  border-radius: 12px !important;
  transform: none !important;
  z-index: 999890 !important;
}
body .c1-scheme::before { display: none !important; }
body .c1-social-float {
  position: fixed !important;
  inset: 50% 0 auto auto !important;
  transform: translateY(-50%) !important;
}
/* A short viewport needs horizontal social links above the chat launcher. */
@media (max-height: 520px) and (min-width: 601px) {
  body .c1-social-float {
    inset: auto 24px 96px auto !important;
    flex-direction: row !important;
    width: auto !important;
    transform: none !important;
  }
}
@media (max-width: 600px) {
  body .trp-language-switcher.trp-floating-switcher {
    inset: auto auto calc(80px + env(safe-area-inset-bottom)) 12px !important;
    padding: 0 !important;
    --font-size: 12px !important;
    --flag-size: 16px !important;
    --switcher-padding: 0 !important;
  }
  body .trp-floating-switcher .trp-language-switcher-inner { padding: 0 !important; }
  body .trp-floating-switcher .trp-language-item {
    box-sizing: border-box;
    min-height: 44px;
    padding: 8px 10px !important;
    font-size: 12px !important;
  }
  body .c1-scheme {
    inset: auto auto calc(156px + env(safe-area-inset-bottom)) 12px !important;
    gap: 6px !important;
    padding: 6px 8px !important;
    max-width: calc(100vw - 24px) !important;
  }
  body .c1-scheme .c1-mode-btn,
  body .c1-scheme .c1-scheme-dot {
    display: grid !important;
    place-items: center;
    width: 44px !important;
    height: 44px !important;
    flex: 0 0 44px;
  }
  #c1wa-root { right: 12px; bottom: max(16px, env(safe-area-inset-bottom)); }
  #c1wa-root .c1wa-launch { font-size: 13px; padding: 13px 18px; }
}
/* Keep the surrounding controls from covering an open conversation. */
body:has(#c1wa-panel:not([hidden])) .c1-social-float {
  visibility: hidden !important;
  pointer-events: none !important;
}
@media (max-width: 600px) {
  body:has(#c1wa-panel:not([hidden])) .c1-scheme,
  body:has(#c1wa-panel:not([hidden])) .trp-floating-switcher {
    visibility: hidden !important;
    pointer-events: none !important;
  }
}
