
.em-seg {
  display: inline-flex;
  align-items: stretch;
  box-sizing: border-box;
  height: 24px;
}
.em-seg > button {
  appearance: none;
  position: relative;
  box-sizing: border-box;
  border: 1px solid var(--border, #333);
  border-radius: 0;
  margin: 0 0 0 -1px;
  padding: 0 10px;
  background: var(--bg-input, #25252a);
  color: var(--text-dim, #888);
  font: inherit;
  font-family: var(--font, system-ui), sans-serif;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}
.em-seg > button:first-child { margin-left: 0; border-radius: var(--radius-sm, 4px) 0 0 var(--radius-sm, 4px); }
.em-seg > button:last-child { border-radius: 0 var(--radius-sm, 4px) var(--radius-sm, 4px) 0; }
.em-seg > button:only-child { border-radius: var(--radius-sm, 4px); }
.em-seg > button:hover:not(:disabled):not([aria-pressed="true"]) {
  z-index: 1;
  background: var(--bg-hover, #2a2a32);
  border-color: var(--border-strong, #444);
  color: var(--text, #e0e0e0);
}
.em-seg > button[aria-pressed="true"] {
  z-index: 2;
  background: var(--accent-tint-selected, rgba(91, 141, 239, 0.18));
  border-color: var(--accent, #5b8def);
  color: var(--text, #e0e0e0);
}
.em-seg > button[aria-pressed="true"]:hover:not(:disabled) {
  background: var(--accent-tint-strong, rgba(91, 141, 239, 0.25));
}
.em-seg > button:focus-visible {
  z-index: 3;
  outline: 2px solid var(--accent, #5b8def);
  outline-offset: 2px;
}

.em-seg > button:disabled { color: var(--text-faint, #555); cursor: default; }
