(day44)css样式、css布局
目录 一、css样式 (一)文字样式 (1)文字字体font-family (2)字体大小font-size (3)字体粗细font-weight (4)字体颜色color (二)文本样式 (1)文字对齐text-align (2)文字装饰text-decoration (3)首行缩进text-indent (三)背景样式 (1)背景颜色color (2)背景图片image (3)背景重复repeat (4)背景位置position (四)显示样式 (1)边框border (2)宽高 (3)display属性 二、css布局 (一)盒子模型 (1)外边距magin (2)边框border (3)内边距padding (4)内容content (二)浮动float (1)三种取值 (2)clear (3)overflow溢出属性 (4)清楚浮动 (三)定位position (四)是否脱离文档流 (五)z-index (六)opacity 一、css样式 (一)文字样式 (1)文字字体font-family font-family可以放置多个字体,如果浏览器不支持第一个字体,则会尝试下一个 body { font-family:"Microsoft Yahei", "微软雅黑", "Arial", sans-serif; } (2)字体大小font-size