Qus : Which of the following is true about the CSS box model?
QusCSS बॉक्स मॉडल के बारे में इनमें से कौन-सी बात सही है?
A. It consists of Margin, Padding, Border, Content B. It consists of Padding, Border, Shadow
C. It consists of Content, Outline, Shadow D. It consists of Border, Margin, Shadow
Solution
A. It consists of Margin, Padding, Border, Content
Explanation
<div><span style="font-size: 14px;">The CSS Box Model describes how every HTML element is represented as a rectangular box. It consists of the following four parts (from inside to outside):</span></div><div><span style="font-size: 14px;"><br></span></div><div><span style="font-size: 14px;">Content – The actual text, image, or other content inside the element.</span></div><div><span style="font-size: 14px;">Padding – Space between the content and the border.</span></div><div><span style="font-size: 14px;">Border – The border surrounding the padding and content.</span></div><div><span style="font-size: 14px;">Margin – The outermost space outside the border, separating the element from other elements.</span></div><div><span style="font-size: 14px;"><br></span></div><div><span style="font-size: 14px;">Order of the CSS Box Model:</span></div><div><span style="font-size: 14px;"><br></span></div><div><span style="font-size: 14px;">Margin</span></div><div><span style="font-size: 14px;"> └── Border</span></div><div><span style="font-size: 14px;"> └── Padding</span></div><div><span style="font-size: 14px;"> └── Content</span></div>