/* ═══ Language switcher (templates/partials/lang-switch.php + js/site-translate.js) ═══
   Self-contained: every token has a literal fallback, so the same file serves
   the main header (which defines --h-*) and the /news header (which does not). */
.tc-lang-wrap{position:relative;flex-shrink:0}
.tc-lang-btn.tc-lang-on{border-color:var(--h-red,#E31937);color:var(--h-red,#E31937);background:var(--h-red-soft,rgba(227,25,55,.07))}
.tc-lang-btn.tc-lang-err{opacity:.5}
.tc-lang-drop{position:absolute;top:calc(100% + 10px);right:0;z-index:300;width:216px;padding:6px;background:#fff;border:1px solid var(--h-line,#E4EAF0);border-radius:14px;box-shadow:0 24px 60px rgba(10,19,43,.16),0 4px 12px rgba(10,19,43,.06);opacity:0;visibility:hidden;transform:translateY(8px);transition:opacity .2s,transform .2s,visibility .2s;max-height:calc(100vh - 96px);overflow-y:auto}
.tc-lang-drop.tc-open{opacity:1;visibility:visible;transform:translateY(0)}
.tc-lang-head{font:700 10.5px/1.3 'DM Sans',system-ui,sans-serif;text-transform:uppercase;letter-spacing:.09em;color:rgba(10,19,43,.64);padding:6px 10px 8px;margin-bottom:4px;border-bottom:1px solid var(--h-line,#E4EAF0)}
.tc-lang-opt{display:flex;align-items:baseline;justify-content:space-between;gap:10px;width:100%;padding:7px 10px;border:0;border-radius:8px;background:none;cursor:pointer;font:500 13px/1.35 'DM Sans',system-ui,sans-serif;color:#0A132B;text-align:left;transition:color .16s,background .16s}
.tc-lang-opt small{font-size:11px;font-weight:500;color:rgba(10,19,43,.5)}
.tc-lang-opt:hover,.tc-lang-opt:focus-visible{color:#C11430;background:rgba(227,25,55,.07);outline:none}
.tc-lang-opt.tc-lang-active{color:#C11430;font-weight:700;background:rgba(227,25,55,.05)}
.tc-lang-foot{font:400 10.5px/1.45 'DM Sans',system-ui,sans-serif;color:rgba(10,19,43,.64);padding:8px 10px 4px;margin-top:4px;border-top:1px solid var(--h-line,#E4EAF0)}

/* Bottom bar, shown only while a translation is active (built by the script) */
.tc-lang-note{position:fixed;left:16px;bottom:16px;z-index:990;display:flex;align-items:center;gap:10px;max-width:min(560px,calc(100vw - 32px));padding:9px 10px 9px 14px;background:#0A132B;color:#fff;border-radius:12px;box-shadow:0 12px 34px rgba(10,19,43,.28);font:400 12px/1.4 'DM Sans',system-ui,sans-serif}
.tc-lang-note[hidden]{display:none}
.tc-lang-note-en{flex-shrink:0;height:28px;padding:0 11px;border:1px solid rgba(255,255,255,.35);border-radius:8px;background:none;color:#fff;font:600 11.5px 'DM Sans',system-ui,sans-serif;cursor:pointer;white-space:nowrap}.tc-lang-note-en:hover{background:rgba(255,255,255,.12)}
.tc-lang-note-x{flex-shrink:0;width:26px;height:26px;border:0;border-radius:7px;background:none;color:#fff;font-size:18px;line-height:1;cursor:pointer;opacity:.7}.tc-lang-note-x:hover{opacity:1;background:rgba(255,255,255,.12)}

/* Google's own chrome — top banner, hover balloon, original-text highlight, spinner */
body>.skiptranslate,iframe.skiptranslate,.goog-te-banner-frame,#goog-gt-tt,.goog-te-balloon-frame,.goog-tooltip,.VIpgJd-ZVi9od-aZ2wEe-wOHMyf,.VIpgJd-ZVi9od-aZ2wEe-OiiCO{display:none!important}
.goog-text-highlight,.VIpgJd-yAWNEb-VIpgJd-fmcmS-sn54Q{background:none!important;box-shadow:none!important}
body{top:0!important}
/* Google drops the spaces around a protected code once the sentence is translated */
html.translated-ltr .tc-nt{margin:0 .22em}

/* ── Main header: translated menu labels are wider than the English ones and
   ran under the search / globe buttons. The script measures the row and steps
   data-fit up (1→4) until it fits; each step is a little tighter. ── */
.tc-menu[data-fit] .tc-link{white-space:nowrap}
.tc-menu[data-fit="1"]{gap:0}.tc-menu[data-fit="1"] .tc-link{padding:6px 8px;font-size:12.5px}
.tc-menu[data-fit="2"]{gap:0}.tc-menu[data-fit="2"] .tc-link{padding:6px 6px;font-size:12px;gap:3px}
.tc-menu[data-fit="3"]{gap:0}.tc-menu[data-fit="3"] .tc-link{padding:6px 5px;font-size:11.5px;gap:3px}.tc-menu[data-fit="3"] .tc-link::after{display:none}
.tc-menu[data-fit="4"]{gap:0}.tc-menu[data-fit="4"] .tc-link{padding:6px 4px;font-size:10.5px;gap:0;letter-spacing:0}.tc-menu[data-fit="4"] .tc-link::after{display:none}
.tc-menu[data-fit] .tc-link::before{left:6px;right:6px}
/* still too wide at the tightest step → use the drawer, as tablets do */
.tc-hdr.tc-nav-collapsed .tc-nav{display:none!important}.tc-hdr.tc-nav-collapsed .tc-ham{display:flex!important}

/* ── /news header: no .tc-act-btn there, so the button is styled to match its search box ── */
.np-bar .tc-lang-btn{display:grid;place-items:center;width:38px;height:38px;padding:0;border:1px solid var(--line-2,#D5DCE6);border-radius:8px;background:var(--paper,#F7F9FC);color:var(--mute,#5B6578);cursor:pointer;transition:border-color .2s,color .2s,background .2s}
.np-bar .tc-lang-btn:hover{border-color:#E31937;color:#E31937}
@media(max-width:860px){.np-bar .tc-lang-wrap{margin-left:auto}.np-bar .tc-lang-wrap+.np-cta{margin-left:0}.np-bar .tc-lang-btn{width:34px;height:34px}
  /* a translated "Morning brief" is wider — trim it rather than let it drop to its own row */
  html.translated-ltr .np-bar .np-cta{display:block;flex:0 1 auto;min-width:0;line-height:32px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}}
/* phone: brand + globe + "Morning brief" must stay on ONE row */
@media(max-width:520px){.np-bar .nw-wrap{column-gap:6px}.np-bar .tc-lang-btn{width:30px;height:30px;border-color:transparent;background:none}.np-bar .np-cta{padding:0 9px}html.translated-ltr .np-bar .np-cta{max-width:100px}
  /* long translated one-liners (Tamil, Malayalam) pushed the page sideways */
  html.translated-ltr .nw-more,html.translated-ltr main .nw-btn{white-space:normal;max-width:100%;height:auto;min-height:40px;padding-block:8px;text-align:center}}
@media(max-width:380px){.np-bar .np-brand img{height:20px;width:auto}.np-bar .np-brand span{font-size:20px}}

/* phones: sit above the sticky "Talk to an expert" bar */
@media(max-width:768px){.tc-lang-note{left:12px;right:12px;bottom:calc(84px + env(safe-area-inset-bottom,0px));max-width:none}.tc-lang-note span{flex:1}}
@media print{.tc-lang-note,.tc-lang-wrap{display:none!important}}
