html.app-android-controls select.app-select-native, select[data-remote-options].app-select-native {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    clip-path: inset(50%) !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    pointer-events: none !important;
    min-width: 0 !important;
    max-width: 1px !important;
    min-height: 0 !important;
}
.app-select-trigger {
    width: 100%; min-height: 44px; text-align: left; white-space: normal;
    cursor: pointer; padding-right: 2.5rem !important;
}
.app-select-trigger:focus-visible { outline: 3px solid #3b82f6; outline-offset: 2px; }
.app-select-trigger[aria-invalid="true"] { outline: 2px solid #dc3545; }
.app-select-trigger:disabled { opacity: .65; cursor: default; }
html.app-android-controls dialog.app-select-dialog, dialog.app-remote-select-dialog {
    box-sizing: border-box; width: min(92vw, 440px); max-width: 92vw;
    position: fixed; inset: 0; margin: auto;
    height: fit-content; min-height: 0; min-width: 0;
    font: 16px/1.4 system-ui, sans-serif; text-align: left;
    max-height: 55vh; max-height: 55dvh; padding: 0; border: 1px solid #cbd5e1;
    border-radius: 16px; background: #fff; color: #1e293b;
    box-shadow: 0 16px 48px #0f172a40; overflow: hidden;
}
.app-select-dialog[open] { display: flex; flex-direction: column; }
.app-select-dialog::backdrop { background: #0f172a66; }
.app-select-header { display: flex; flex-shrink: 0; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid #e2e8f0; }
.app-select-header h2 { flex: 1; min-width: 0; overflow-wrap: anywhere; margin: 0; font: 600 16px/1.4 system-ui, sans-serif; }
.app-select-header button { flex-shrink: 0; min-height: 44px; border: 0; border-radius: 8px; background: #eff6ff; color: #1d4ed8; padding: 8px 12px; font: 600 14px system-ui, sans-serif; }
.app-select-dialog input { box-sizing: border-box; flex-shrink: 0; margin: 12px 16px; width: calc(100% - 32px); min-height: 44px; border: 1px solid #94a3b8; border-radius: 8px; padding: 10px; font: 16px system-ui, sans-serif; }
.app-select-options { overflow-y: auto; overscroll-behavior: contain; padding: 6px; min-height: 0; }
.app-select-options button { display: block; width: 100%; min-height: 44px; padding: 12px; border: 0; border-radius: 8px; text-align: left; background: transparent; color: inherit; font: 16px/1.4 system-ui, sans-serif; overflow-wrap: anywhere; }
.app-select-options button[aria-selected="true"] { background: #dbeafe; color: #1d4ed8; font-weight: 600; }
.app-select-options button:focus-visible { outline: 2px solid #2563eb; outline-offset: -2px; }
.app-select-options button:disabled { opacity: .5; }
.app-select-dialog [hidden] { display: none !important; }
.app-select-error { color: #b91c1c; margin: 12px 16px 0; font: 14px system-ui, sans-serif; }
.app-select-empty { padding: 12px; margin: 0; font: 14px system-ui, sans-serif; }
.app-select-load-more { flex-shrink:0;min-height:44px;margin:8px 16px;padding:10px;border:1px solid #cbd5e1;border-radius:8px;background:#eff6ff;color:#1d4ed8; }
.app-android-controls .select2-results__options { max-height: 35vh !important; max-height: 35dvh !important; overscroll-behavior: contain; }
.app-android-controls .select2-results__option { min-height: 44px; overflow-wrap: anywhere; }
.app-android-controls .select2-search__field { font-size: 16px !important; }
html.app-android-controls[data-theme="dark"] dialog.app-select-dialog,
html.app-android-controls body.dark-mode dialog.app-select-dialog { background: #1e293b; color: #e2e8f0; border-color: #475569; }
[data-theme="dark"] .app-select-header, body.dark-mode .app-select-header { border-color: #475569; }
[data-theme="dark"] .app-select-dialog input, body.dark-mode .app-select-dialog input { background: #0f172a; color: #e2e8f0; }
