hasLayout 觸發:zoom:1 或具體 height.clearfix::after{content:"";display:block;clear:both;}height:1% 或 overflow:hiddenbody{line-height:1.5;} 統一基準.clear{height:0;line-height:0;font-size:0;clear:both;}*{margin:0;padding:0;} 歸零,再按需建構<li><a>...</a></li><li>... 避免換行產生空白節點display:flex;align-items:center;justify-content:center;.side{width:200px;}.main{flex:1;}grid-template: auto 1fr auto / 200px 1fr 200px;「佈局不在多 hack,而在於理解文檔流、BFC、Flex/Grid 格式化上下文的本質規律。」