/* Shared by the site footer and the standalone error page. */
.language-picker {
  grid-column: 1 / -1;
  position: relative;
  justify-self: right;
  inline-size: fit-content;
  max-inline-size: 100%;
  color: #F8FAFC;
  font-size: .9375rem;
  overflow-wrap: anywhere;
}
.language-picker summary {
  min-block-size: 44px;
  padding: .65rem 1rem;
  border: 1px solid #A9B8C6;
  border-radius: 6px;
  cursor: pointer;
}
.language-picker summary:hover { background: #172635; }
.language-picker summary:focus-visible,
.language-picker a:focus-visible { outline: 2px solid #6EE8FF; outline-offset: 3px; }
/* Keep the open menu out of footer layout and above the trigger. */
.language-picker nav {
  position: absolute;
  right: 0;
  bottom: calc(100% + .5rem);
  z-index: 10;
  inline-size: min(20rem, calc(100vw - 2rem));
  max-block-size: min(24rem, 60vh);
  overflow-y: auto;
  padding: .5rem;
  border: 1px solid #A9B8C6;
  border-radius: 6px;
  background: #0E1C29;
  box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .35);
}
.language-picker ul {
  display: grid;
  gap: .25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.language-picker a {
  display: block;
  min-block-size: 44px;
  margin: 0;
  padding: .65rem 1rem;
  border-radius: 6px;
  background: transparent;
  color: #F8FAFC;
  font-size: inherit;
  font-weight: 400;
  text-decoration: none;
}
.language-picker a:hover { background: #172635; text-decoration: underline; }
.language-picker a[aria-current="page"] { background: #0B4D7C; font-weight: 600; }
.error-footer { display: flex; justify-content: flex-end; min-inline-size: 0; margin-block-start: 2rem; }
/* flex-end follows RTL direction; the picker stays at the physical right. */
.error-footer .language-picker { margin-left: auto; margin-right: 0; }
