/* Explicit native SELECT owners only; original values/form validation remain
 * on the original fields. The top layer escapes profile/modal clipping. */
@layer orator-quiet-edges {
  html[data-theme] .buddy-select-toggle{color:var(--ui-text)!important;background:var(--ui-control)!important;background-image:none!important;border:0!important;box-shadow:none!important;transform:none!important}
  html[data-theme] .buddy-select-option{color:var(--ui-text)!important;background:transparent!important;background-image:none!important;border:0!important;box-shadow:none!important;transform:none!important}
  html[data-theme] .buddy-select-option[aria-selected="true"],html[data-theme] .buddy-select-option:not(:disabled):is(:hover,:focus-visible){color:var(--ui-accent-ink)!important;background:color-mix(in srgb,var(--ui-accent-fill) 12%,var(--ui-panel))!important}
  html[data-theme] .buddy-select-toggle:focus-visible,html[data-theme] .buddy-select-option:focus-visible{outline:2px solid var(--ui-accent-fill)!important;outline-offset:-2px!important}
}
.buddy-select-box{position:relative;min-width:0;width:100%}
.buddy-native-select{position:absolute!important;width:1px!important;height:1px!important;min-height:0!important;padding:0!important;border:0!important;clip-path:inset(50%);overflow:hidden;white-space:nowrap;pointer-events:none}
.buddy-select-toggle{box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0;font:inherit;line-height:1.4;text-align:left;cursor:pointer}
.buddy-select-value{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.buddy-select-toggle::after{content:'⌄';flex:none;color:var(--ui-muted)}
.buddy-select-toggle:disabled,.buddy-select-option:disabled{opacity:.45;cursor:not-allowed}
.buddy-select-toggle[aria-invalid="true"]{outline:2px solid var(--ui-danger);outline-offset:-2px}
.buddy-select-list{box-sizing:border-box;position:fixed;inset:auto;margin:0;z-index:110;max-height:220px;overflow:auto;overscroll-behavior:contain;padding:4px;border:0;border-radius:12px;color:var(--ui-text);background:var(--ui-panel);box-shadow:var(--ui-menu-shadow)}
.buddy-select-box[hidden],.buddy-select-list[hidden]{display:none!important}
.buddy-select-option{box-sizing:border-box;display:block;width:100%;min-height:40px;padding:10px;border-radius:8px;font:inherit;text-align:left;overflow-wrap:anywhere}
/* Unsupported anchors use one user-open rectangle, never an idle/scroll loop. */
@supports(position-anchor:--buddy-select){
  .buddy-select-list[popover]:not(.buddy-select-list-fallback){top:anchor(bottom);left:anchor(left);width:anchor-size(width);margin:4px 0;max-height:min(220px,calc(100dvh - 24px));position-try-fallbacks:flip-block}
}
@media(max-width:767px){.buddy-select-toggle,.buddy-select-option{font-size:16px}}
@media(forced-colors:active){
  @layer orator-quiet-edges {
    html[data-theme] .buddy-select-toggle,html[data-theme] .buddy-select-option{color:ButtonText!important;background:Canvas!important;border:1px solid ButtonText!important;forced-color-adjust:none}
    html[data-theme] .buddy-select-option[aria-selected="true"],html[data-theme] .buddy-select-option:not(:disabled):is(:hover,:focus-visible){color:HighlightText!important;background:Highlight!important}
    html[data-theme] .buddy-select-toggle:focus-visible,html[data-theme] .buddy-select-option:focus-visible{outline-color:Highlight!important}
  }
  .buddy-select-list{background:Canvas;border:1px solid ButtonText}
}
