The Size Paradox
Hard+60 XP
Mission Briefing
This is the Day 2 finale. Normally, adding padding and borders makes an element bigger than its defined width. You must keep Spark's total size locked at 100px.
The Concept: Border Box
box-sizing: border-box tells the browser to include padding and border in the element's total width and height.
The Objective
- Target the .spark-character.
- Set width and height to 100px.
- Add 20px padding.
- Add a 5px border.
- Set box-sizing to border-box to ensure it remains 100px total.
Constraints
cssbox-model
Live Visual OutputAuto-Evaluating Target
style.cssCSS Style Injector
Loading...