投稿日: 27/06/201501/07/2019widthの指定をボーダーの太さ込みの値に設定する width = border + padding + コンテンツ にするには box-sizing: border-box; こっちが標準ならいいのに。。。