/* Language switcher (i18n Phase 0): header globe + burger row.
   Extracted from app.css so the guest auth layout (Auth/_layout.php) can load the
   switcher chrome without pulling in the whole app stylesheet. Loaded by both
   layouts/main.php and Auth/_layout.php — edit here, not in app.css. */
.lang-switcher { position: relative; }
.lang-switcher summary { list-style: none; }
.lang-switcher summary::-webkit-details-marker { display: none; }
.lang-globe {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  /* Sits on the appbar (dark in both themes), same as the header links around it —
     --on-accent, never --text, which would go near-black in dark mode and vanish. */
  color: color-mix(in srgb, var(--on-accent) 85%, transparent);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.lang-globe:hover { background: color-mix(in srgb, var(--on-accent) 14%, transparent); color: var(--on-accent); }
.lang-switcher[open] .lang-globe { background: color-mix(in srgb, var(--on-accent) 14%, transparent); color: var(--on-accent); }
.lang-globe svg { width: 18px; height: 18px; }
.lang-menu {
  position: absolute;
  top: calc(100% + 6px);
  /* Логический отступ, а не right: глобус стоит у края по направлению письма, и при
     RTL он у ЛЕВОГО края. Меню шире глобуса (min-width 150px против 34px), поэтому
     привязка к физически правому краю уводила бы его за пределы экрана. */
  inset-inline-end: 0;
  min-width: 150px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-dropdown);
  padding: 6px;
  z-index: 300;
}
.lang-menu form { margin: 0; }
.lang-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  text-align: start;
  cursor: pointer;
}
/* A translucent darken-on-tint reads as the same faint highlight in both themes
   (it lightens instead of darkens once --text itself goes pale in dark mode). */
.lang-opt:hover { background: color-mix(in srgb, var(--text) 6%, transparent); }
/* Plain --brand on --surface is 2.5:1 (light) / 8.6:1 (dark) — under AA in light.
   Blending it toward --text keeps the brand hue as the "active" cue while clearing
   4.5:1 in both themes (5.3:1 light / 10.8:1 dark at this mix). */
.lang-opt.on { font-weight: 700; color: color-mix(in srgb, var(--brand) 45%, var(--text)); }
.lang-check { font-size: 12px; }
/* .menu-lang-row/.menu-lang-form were dead code — nav_drawer.php's higher-specificity
   .nvd-panel rules repaint the same properties, so both were deleted. .menu-lang-opt
   keeps `font: inherit`: nav_drawer only sets font-size/font-weight, not the family. */
.menu-lang-opt { font: inherit; cursor: pointer; }
.menu-lang-opt.on { font-weight: 600; }
