/* Force compact forms and modals - high specificity */
body [role="dialog"],
body .fixed.inset-0 [role="dialog"],
body [data-radix-dialog-content],
body .mle-modal,
body [class*="dialog"],
body [class*="modal"] {
  max-height: 85vh !important;
  max-width: 95vw !important;
  overflow-y: auto !important;
  padding: 0.75rem 1rem !important;
  font-size: 13px !important;
}

body [role="dialog"] input,
body [role="dialog"] textarea,
body [role="dialog"] select,
body [data-radix-dialog-content] input,
body [class*="dialog"] input {
  height: 2rem !important;
  min-height: 2rem !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 13px !important;
  margin-bottom: 0.25rem !important;
}

body [role="dialog"] label,
body [role="dialog"] .text-xs,
body [role="dialog"] .text-sm,
body [data-radix-dialog-content] label {
  font-size: 11px !important;
  margin-bottom: 2px !important;
  line-height: 1.2 !important;
}

body [role="dialog"] .space-y-3 > * + *,
body [role="dialog"] .space-y-4 > * + *,
body [role="dialog"] .gap-3,
body [role="dialog"] .gap-4,
body [data-radix-dialog-content] .space-y-3 > * + * {
  margin-top: 0.4rem !important;
  gap: 0.4rem !important;
}

body [role="dialog"] h1,
body [role="dialog"] h2,
body [role="dialog"] h3,
body [data-radix-dialog-content] h2 {
  font-size: 1rem !important;
  margin: 0 0 0.5rem 0 !important;
  line-height: 1.3 !important;
}

body [role="dialog"] .grid,
body [role="dialog"] .grid-cols-2 {
  gap: 0.5rem !important;
}

/* Reduce overall spacing */
body [role="dialog"] p,
body [role="dialog"] .text-slate-500 {
  font-size: 12px !important;
  margin: 0.25rem 0 !important;
}
