こんなやつ作りたいとき。
とりあえず下記コピペで出来ます。あら簡単。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
h2{ text-align: center; font-size: 40px; position: relative; } h2:before{ background-color: #2190b9; content: ''; position: absolute; bottom: 0px; display: inline-block; width: 40px; height: 4px; margin: auto; left: 0; right: 0; } |
色や線幅のアレンジはCSSいじってくださいね~