/* Shared visual language for app-owned confirmation and input dialogs. */
body .wf-dialog-overlay {
  position: fixed; inset: 0; z-index: 2147483646;
  display: flex; align-items: center; justify-content: center;
  box-sizing: border-box; padding: max(20px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  background: rgba(0, 0, 0, .56); overscroll-behavior: contain;
}
body .wf-dialog-panel {
  box-sizing: border-box; width: min(100%, 400px); max-height: 85vh; max-height: 85dvh;
  overflow-y: auto; margin: 0; padding: 24px; display: block;
  border: 1px solid var(--wf-ui-line, #5b503b); border-radius: 16px;
  background: var(--wf-ui-surface, #20211d); color: var(--wf-ui-ink, #e7e1d4);
  box-shadow: 0 24px 70px #0005; font-family: inherit;
}
body .wf-dialog-panel h2 { margin: 0 0 12px; color: inherit; font-family: inherit; font-size: 19px; font-weight: 600; line-height: 1.5; letter-spacing: 0; }
body .wf-dialog-panel p { margin: 0; color: var(--wf-ui-muted, #b7ae9b); font-size: 14px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
body .wf-dialog-panel input {
  box-sizing: border-box; display: block; width: 100%; min-height: 48px; margin: 18px 0 0; padding: 10px 12px;
  border: 1px solid var(--wf-ui-line, #5b503b); border-radius: 8px;
  color: var(--wf-ui-ink, #e7e1d4); background: var(--wf-ui-raised, #292a24); font: inherit; font-size: 16px;
}
body .wf-dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }
body .wf-dialog-actions button {
  box-sizing: border-box; min-width: 88px; min-height: 44px; margin: 0; padding: 10px 20px;
  border: 1px solid var(--wf-ui-line, #5b503b) !important; border-radius: 8px !important;
  background: transparent !important; color: var(--wf-ui-ink, #e7e1d4) !important;
  box-shadow: none !important; font: inherit; font-size: 14px; font-weight: 500; text-shadow: none !important;
  cursor: pointer; touch-action: manipulation;
}
body .wf-dialog-actions .wf-dialog-accept { background: var(--wf-ui-accent, #c2a66c) !important; color: var(--wf-ui-on-accent, #191b17) !important; border-color: transparent !important; }
body .wf-dialog-actions .is-danger { background: #a44035 !important; color: #fff8ee !important; }
body .wf-dialog-actions button::before, body .wf-dialog-actions button::after { content: none !important; }
body .wf-dialog-panel :is(input, button):focus-visible { outline: 2px solid var(--wf-ui-accent, #c2a66c) !important; outline-offset: 3px; }
@media (max-width: 420px) { body .wf-dialog-panel { padding: 22px 20px 20px; } body .wf-dialog-actions button { flex: 1; } }
