/* Single-select popovers share the calm calendar palette and strict-CSP assets. */
.ky-select-field { display: block; position: relative; min-width: 0; width: 100%; }
.ky-select-field select.ky-select-native { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 44px; margin: 0; opacity: 0; pointer-events: none; }
.ky-select-field button.ky-select-control { display: flex; align-items: center; width: 100%; min-width: 0; min-height: 44px; height: auto; padding: 10px 36px 10px 12px; border: 1px solid var(--control-border, #72889d); border-radius: 10px; background: var(--surface, #edf1f4) url('/static/select-chevron.svg?v=20260927-v4') no-repeat right 10px center / 16px; color: var(--ink-secondary, #304d6c); font: inherit; font-weight: 400; line-height: 1.4; text-align: left; box-shadow: none; cursor: pointer; }
.ky-select-value { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ky-select-control[aria-expanded="true"], .ky-select-control:focus-visible { outline: 2px solid var(--focus, #2f648f); outline-offset: 2px; }
.ky-select-field button.ky-select-control:disabled { opacity: 1; color: var(--muted, #4e647b); cursor: default; border-style: dashed; }
.ky-select-panel, dialog.ky-select-panel { position: fixed; inset: auto; box-sizing: border-box; margin: 0; padding: 5px; width: 220px; height: fit-content; min-height: 0; max-height: 320px; border: 1px solid var(--border, #bdccd8); border-radius: 12px; background: var(--surface, #edf1f4); color: var(--ink, #203f68); box-shadow: 0 8px 24px var(--shadow-dialog, #0f3b8233); overflow-y: auto; overscroll-behavior: contain; font: 15px/1.4 var(--font-body, sans-serif); outline: none; }
.ky-select-panel::backdrop { background: transparent; }
.ky-select-option { display: flex; align-items: center; position: relative; min-height: 44px; box-sizing: border-box; padding: 10px 34px 10px 12px; border: 1px solid transparent; border-radius: 8px; cursor: pointer; overflow-wrap: anywhere; }
.ky-select-option[aria-selected="true"] { color: var(--action, #2f648f); font-weight: 600; }
.ky-select-option[aria-selected="true"]::after { content: ''; position: absolute; right: 11px; top: calc(50% - 7px); width: 7px; height: 12px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }
.ky-select-option.is-cursor { background: var(--sky, #dbe7f0); border-color: var(--control-border, #72889d); }
.ky-select-option:hover:not([aria-disabled="true"]) { background: var(--sky, #dbe7f0); }
.ky-select-option[aria-disabled="true"] { color: var(--muted, #4e647b); cursor: default; text-decoration: line-through; }
.ky-select-group { padding: 8px 12px 4px; color: var(--muted, #4e647b); font-size: 12px; font-weight: 600; }

.mode-label { width: 172px; max-width: 100%; margin-left: auto; flex-shrink: 0; }
.mode-label .ky-select-field { min-width: 0; max-width: 100%; }
.writing-panel .field-heading { flex-wrap: wrap; }
