/* Green Ink: compact shared ENG / தமிழ் preference control.
   Reuses existing ink, paper and border tokens; no changes to navigation layout. */
.gi-language-toggle{
  display:inline-flex;
  align-items:center;
  justify-self:end;
  flex:0 0 auto;
  gap:2px;
  padding:2px;
  border:1px solid var(--line);
  border-radius:999px;
  background:var(--paper);
  white-space:nowrap;
  max-width:100%;
}
.gi-language-toggle button{
  appearance:none;
  border:0;
  border-radius:999px;
  background:transparent;
  color:var(--ink);
  font-family:var(--body);
  font-size:10.5px;
  line-height:1.2;
  font-weight:650;
  min-height:29px;
  min-width:37px;
  padding:6px 7px;
  cursor:pointer;
  transition:background-color .15s ease,color .15s ease;
}
.gi-language-toggle button.is-active{
  color:var(--paper);
  background:var(--good);
}
.gi-language-toggle button:not(.is-active):active{background:var(--card);}
.gi-language-toggle button:focus-visible{outline:2px solid var(--stamp);outline-offset:2px;}
/* Only bilingual study screens receive the shared language toggle. */
@media(max-width:480px){
  #screen-chapters .app-header .title,
  #screen-content .app-header .title,
  #screen-flash .app-header .title{
    max-width:138px;
    font-size:15px;
  }
  #screen-chapters .app-header .back,
  #screen-content .app-header .back,
  #screen-flash .app-header .back{padding-left:8px;padding-right:8px;}
}
@media(max-width:360px){
  #screen-chapters .app-header .gi-language-toggle button,
  #screen-content .app-header .gi-language-toggle button,
  #screen-flash .app-header .gi-language-toggle button{
    font-size:10px;min-width:34px;padding:5px 5px;min-height:27px;
  }
  #screen-chapters .app-header .title,
  #screen-content .app-header .title,
  #screen-flash .app-header .title{max-width:115px;}
}
@media(prefers-reduced-motion:reduce){
  .gi-language-toggle button{transition:none;}
}
