Minimalist geometric light bulb illustration with a hanging pull cord that triggers a background color change from white to dark blue.

Interactive CSS Light Bulb Toggle

This Interactive CSS Light Bulb Toggle transforms a standard theme switch into a playful interaction. It creates a convincing illusion of a physical pull-cord using standard click events. Rather than using a complex physics engine, it relies on precise timing between mouse/touch events and CSS transforms to mimic the tension and release of a rope when the user clicks the button.

Technologies:
HTML CSS JavaScript
Difficulty: Intermediate
Browser Support (as of Jan 2026):
Chrome Chrome 80+ Edge Edge 80+ Safari Safari 13+ Firefox Firefox 70+
Features:
CSS Drawing Dark Mode Switch Click Micro-interaction Tactile Feedback
License: MIT
Folding/Collapsing Profile Card Starring Batwoman

Folding/Collapsing Profile Card Starring Batwoman

An interactive profile card featuring a dynamic theme toggle triggered by clicks on the avatar or menu button.