.autofill-panel .db-btn { display:inline-flex; align-items:center; justify-content:center; min-height:40px; padding:8px 12px; border:1px solid #cbd5e1; border-radius:6px; background:#fff; color:#172033; font:inherit; cursor:pointer; }
.autofill-panel .db-btn-primary { background:var(--db-color-primary, #1e40af); color:#fff; border-color:transparent; }
.autofill-panel .db-btn:disabled { opacity:.5; cursor:default; }
.autofill-panel [hidden] { display:none !important; }
.autofill-registry-section { margin:16px 0; padding:12px 0; border-bottom:1px solid #d6dae2; }
.autofill-registry-section summary { cursor:pointer; }
.autofill-register { color:var(--db-color-text, var(--color-ink, #172033)); font-family:inherit; font-size:14px; line-height:1.5; min-width:0; }
.autofill-register [hidden] { display:none !important; }
.autofill-register-title { margin:0 0 6px; font-size:20px; font-weight:700; }
.autofill-register-help { margin:6px 0 16px; color:var(--db-color-text-sub, #596579); font-size:13px; }
.autofill-register-field { display:flex; flex-direction:column; gap:8px; margin-top:20px; font-weight:600; }
.autofill-register .autofill-register-input { display:block; box-sizing:border-box; width:100%; min-height:44px; margin:0; padding:10px 12px; border:1px solid #94a3b8; border-radius:6px; background:#fff; color:#172033; font:inherit; font-weight:400; }
.autofill-register .autofill-register-input:focus-visible, .autofill-register button:focus-visible { outline:2px solid #1e40af; outline-offset:2px; }
.autofill-register-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:10px; }
.autofill-register .db-btn { display:inline-flex; align-items:center; justify-content:center; min-height:44px; padding:9px 14px; border:1px solid #cbd5e1; border-radius:6px; background:#fff; color:#172033; font:inherit; cursor:pointer; }
.autofill-register .db-btn-primary { background:var(--db-color-primary, #1e40af); color:#fff; border-color:transparent; font-weight:600; }
.autofill-register .db-btn:disabled { opacity:.45; cursor:default; }
.autofill-register-selected { margin:16px 0 0; padding:12px 0; border-bottom:1px solid #d6dae2; overflow-wrap:anywhere; }
.autofill-register-place { padding:12px 0; border-bottom:1px solid #d6dae2; }
.autofill-register-place p { margin:4px 0; }
.autofill-register-next { width:100%; margin-top:8px; }
.autofill-register-search { margin-top:18px; }
.autofill-register-error { color:#b42318; margin:12px 0; min-height:20px; font-size:13px; }
@media (max-width:480px) { .autofill-register-title { font-size:18px; } .autofill-register-actions .db-btn { flex:1 1 auto; } }

/* Listing previews keep decisions and their action visible; other autofill screens keep their shell. */
.autofill-panel.af-listing-frame { display:flex; flex-direction:column; min-height:0; max-height:calc(90dvh - 8rem); overflow:hidden; }
.autofill-panel .af-listing-header { flex:none; gap:12px; }
.autofill-panel .af-listing-body { flex:1 1 auto; min-height:0; overflow-y:auto; overscroll-behavior:contain; padding-right:4px; }
.autofill-panel .af-listing-footer { flex:none; display:grid; gap:8px; margin-top:10px; padding:12px 0 0; border-top:1px solid #cbd5e1; background:#fff; }
.autofill-panel .af-listing-footer > p { margin:0; font-size:14px; line-height:1.4; }
.autofill-panel .af-listing-footer > p:empty { display:none; }
.autofill-panel .af-listing-footer > button { width:100%; min-height:44px; }
.autofill-panel .af-listing-progress { color:#1e40af; font-weight:600; }
.autofill-panel .af-value-choices { margin:10px 0; border:1px solid #dbe4ee; border-radius:8px; padding:10px; min-width:0; }
.autofill-panel .af-value-choices > legend, .autofill-panel .af-value-choices > summary { font-size:16px; font-weight:700; line-height:1.5; overflow-wrap:anywhere; }
.autofill-panel .af-value-choices > summary { cursor:pointer; min-height:24px; }
.autofill-panel .af-value-required { border-color:#93c5fd; background:#f8fbff; }
.autofill-panel .af-value-note { display:block; margin:4px 0; color:#475569; font-size:14px; line-height:1.4; }
.autofill-panel .af-value-choice { display:grid; grid-template-columns:22px minmax(0,1fr); gap:8px; min-height:44px; margin-top:6px; padding:8px 10px; border:1px solid #cbd5e1; border-radius:6px; background:#fff; cursor:pointer; }
.autofill-panel .af-value-choice input { width:20px; height:20px; margin:0; align-self:center; accent-color:#1d4ed8; }
.autofill-panel .af-value-choice-value { display:inline; font-size:16px; font-weight:600; overflow-wrap:anywhere; }
.autofill-panel .af-value-choice-source { display:inline; margin-left:8px; font-size:14px; font-weight:400; color:#475569; }
.autofill-panel .af-value-choice--selected { border-color:#2563eb; background:#eff6ff; }
.autofill-panel .af-value-option-group { margin-top:8px; padding:8px; border:1px solid #cbd5e1; border-radius:6px; }
.autofill-panel .af-value-option-group > p { margin:0 0 4px; }
.autofill-panel .af-value-reference { margin:10px 0; padding:8px 10px; border:1px solid #e2e8f0; border-radius:6px; color:#475569; font-size:14px; line-height:1.5; }
.autofill-panel .af-value-reference > summary { cursor:pointer; font-weight:600; }
.autofill-panel .af-value-reference-field { margin:8px 0; }
.autofill-panel .af-value-reference-field > h4 { margin:0; font-size:14px; font-weight:600; }
.autofill-panel .af-value-reference-list { margin:4px 0 0; padding-left:18px; overflow-wrap:anywhere; }
.autofill-panel .af-value-reference p { margin:4px 0; }
@media (max-width:480px) {
  .autofill-panel.af-listing-frame { max-height:calc(90dvh - 7rem); }
  .autofill-panel .af-value-choice-source { display:block; margin-left:0; }
}
