/* Public language selector (English, తెలుగు, हिन्दी): partials/lang-switch.blade.php and the Feed World
   navbar draw it, js/core/translate.js runs it. Also hides Google Translate's own toolbar and highlights. */

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  margin: 0;
  padding: .3rem .55rem;
  border: 1px solid rgba(0, 0, 0, .12);
  border-radius: 9999px;
  background: #fff;
  color: #1f2937;
  font-size: .85rem;
  line-height: 1;
  cursor: pointer;
}

.lang-switch svg { flex: none; opacity: .7; }

.lang-switch__select {
  appearance: auto;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0 .1rem;
  cursor: pointer;
  outline: none;
}

.lang-switch:focus-within { box-shadow: 0 0 0 3px rgba(34, 197, 94, .3); }

/* ---- In the Feed World navbar: a pill matching the search button ----------------- */
.fw-navbar-actions .lang-switch {
  height: 36px;
  gap: 6px;
  padding: 0 10px 0 11px;
  border: 1px solid #eef2e6;
  background: #fff;
  color: var(--fw-forest, #14532d);
  box-shadow: 0 3px 8px rgba(15, 23, 42, .10);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

.fw-navbar-actions .lang-switch svg { opacity: 1; }

.fw-navbar-actions .lang-switch__select { font-weight: 700; color: #111827; max-width: 84px; }

/* Phones: no room in the bar, so the selector moves into the ☰ menu (below) */
@media (max-width: 640px) {
  .fw-navbar-actions .lang-switch { display: none; }
}

/* ---- In the navbar's ☰ menu (phones only) ------------------------------------------ */
.fw-mobile-lang { display: none; }

@media (max-width: 640px) {
  .fw-mobile-lang { display: block; padding: 4px 16px 10px; }

  .fw-mobile-lang .lang-switch {
    display: flex;
    width: 100%;
    height: 44px;
    padding: 0 14px;
    gap: 10px;
    border: 0;
    border-radius: 12px;
    background: #f1f5f2;
    color: var(--fw-forest, #14532d);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
  }

  .fw-mobile-lang .lang-switch svg { opacity: 1; }

  .fw-mobile-lang .lang-switch__select { flex: 1; min-width: 0; color: #111827; }
}

/* ---- Translated pages: Telugu and Hindi menu labels are much longer than the English ones, so they
   may wrap onto two lines instead of running into each other (Google sets html.translated-ltr) ---- */
html.translated-ltr .fw-nav-label {
  display: block;
  max-width: 82px;
  white-space: normal;
  text-align: center;
  line-height: 1.15;
  font-size: 9.5px;
}

html.translated-ltr .fw-nav-btn { padding-inline: 5px; }

/* ---- In the My Exports lesson top bar ---------------------------------------------- */
.tp-topbar__actions .lang-switch {
  height: 38px;
  padding: 0 10px;
  border-color: rgba(15, 23, 42, .12);
  font-size: 13px;
  font-weight: 600;
}

/* ---- Google Translate: hide its toolbar, tooltips and highlights; keep the page from moving down ---- */
.goog-te-banner-frame,
iframe.skiptranslate,
.skiptranslate > iframe,
#goog-gt-tt,
.goog-te-balloon-frame,
.VIpgJd-ZVi9od-ORHb-OEVmcd,
.VIpgJd-ZVi9od-aZ2wEe-wOHMyf { display: none !important; }

body { top: 0 !important; }

.goog-text-highlight { background: none !important; box-shadow: none !important; }

font[style] { background: none !important; box-shadow: none !important; }
