/* The toolbar clips its children so the segment stays round.
   The menu panel has to paint below that bar, so the clip comes off
   and the end caps keep the radius. */
.topbar-svc { overflow: visible; }
.topbar-svc > .svc-status {
  border-radius: var(--radius-lg) 0 0 var(--radius-lg);
}
.topbar-svc > .logout-form {
  display: flex;
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  overflow: hidden;
}
.topbar-svc > .lang-menu {
  display: flex;
  align-items: stretch;
}
.topbar-svc > .lang-menu > summary {
  box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.14);
}

.lang-menu { position: relative; }
.lang-menu > summary { list-style: none; cursor: pointer; }
.lang-menu > summary::-webkit-details-marker { display: none; }
.lang-menu > summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.lang-menu[open] > summary.icon-btn {
  background: var(--accent-soft);
  color: var(--text-primary);
}
.lang-menu[open] > summary.svc-action {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}
.lang-menu > form {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 40;
  display: flex; flex-direction: column; min-width: 168px; margin: 0; padding: 4px;
  background: var(--bg-surface); color: var(--text-primary);
  border: 1px solid var(--border-strong); border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}
.lang-menu > form > .lang-rule {
  height: 1px;
  margin: 4px 6px;
  background: var(--border-color);
}
.lang-menu > form > button {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  width: 100%; min-height: 36px; margin: 0; padding: 0 10px;
  border: 0; border-radius: var(--radius); background: transparent; color: inherit;
  appearance: none;
  font: inherit; font-size: .875rem; text-align: start; cursor: pointer;
}
.lang-menu > form > button:hover,
.lang-menu > form > button:focus-visible {
  background: var(--accent-soft);
  outline: none;
}
.lang-menu > form > button[aria-current="true"] { font-weight: 600; }
.lang-menu > form > button[aria-current="true"]::after {
  content: "";
  width: 5px; height: 9px; margin-top: -2px; flex: none;
  border: solid var(--accent); border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.lang-float { position: fixed; top: 16px; right: 60px; z-index: 20; width: 36px; height: 36px; }
.lang-float > summary.icon-btn {
  width: 36px; height: 36px; padding: 0; border-radius: 50%;
  background: var(--bg-surface-2); color: var(--text-secondary);
  border: 1px solid var(--border-color); box-shadow: var(--shadow-btn);
  appearance: none;
}
.lang-float > summary.icon-btn:hover { background: var(--accent-soft); color: var(--text-primary); }
