Pixel Pete saysA modal is an overlay + centered box you show on demand and dismiss on close or backdrop click.
The pattern: a full-screen semi-transparent overlay with a centered content box, toggled by a class. Open on a trigger, close on the X, the backdrop, or Escape. Modern HTML has a native <dialog> element (showModal()) that handles focus trapping and Escape for free — prefer it, but the manual DHTML version still teaches the mechanics.
Power-ups you unlock
Overlay + centered box, toggled by a class
Close on X, backdrop click, or Escape
Native <dialog> + showModal() is the modern way
dialog handles focus trapping and Escape
Quirks Mode attacks — common mistakes
No Escape/backdrop close (trap users)
Forgetting focus management/trapping
Reinventing what native <dialog> provides
Boss battleBuild an open/close modal with a backdrop-click to dismiss.