/* Quiet focus feedback shared by the terminal, login, entry and admin pages. */
:root{--focus-feedback:#7ac6ff;--focus-feedback-glow:#6abfff66}
.auth-page,body:has(.admin-shell){--focus-feedback:#2979c9;--focus-feedback-glow:#2979c94d}

/* Suppress both native SVG frames and legacy component focus rectangles. */
*:focus,*:focus-within{outline:none!important;outline-offset:0!important}

/* A thin underline follows the field, without drawing a box around its value. */
:where(input:not([type=checkbox]):not([type=radio]),select,textarea):focus-visible{
  box-shadow:inset 0 -1px 0 var(--focus-feedback)!important;
}
:where(a,button,summary,[role=button],[role=tab]):focus-visible{
  text-decoration-line:underline!important;
  text-decoration-thickness:2px;
  text-underline-offset:4px;
  text-shadow:0 0 7px var(--focus-feedback-glow);
}
:where(button,summary,[role=button],[role=tab]):focus-visible svg{
  filter:drop-shadow(0 0 3px var(--focus-feedback-glow));
}
.language-option:has(input:focus-visible){
  box-shadow:inset 0 -2px 0 var(--focus-feedback)!important;
}
:where([tabindex]):not(input):not(select):not(textarea):not(button):not(a):focus-visible{
  box-shadow:inset 0 -1px 0 var(--focus-feedback)!important;
}
#chart:has(svg[tabindex]:focus-visible){
  box-shadow:inset 0 -1px 0 var(--focus-feedback);
}

/* System high-contrast mode needs an explicit keyboard indicator. */
@media(forced-colors:active){
  *:focus-visible,.language-option:has(input:focus-visible){
    outline:2px solid Highlight!important;
    outline-offset:2px!important;
    text-shadow:none;
  }
}
