ビル – css building –

ビルアイコン アイコン

cssのみで 「ビル」 アイコンを作成してみました。

ソース

html

<div class="building"></div>

css

/* 枠 */
.building {
	font-size: 100px;
	position: relative;
	width: 1.1em;
	height: 1.4em;
	border: 0.1em solid #39a9d6;
	border-radius: 0.1em;
}
/* 窓・入り口 */
.building::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	width: 1.1em;
	height: 1.4em;
	background:
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 0.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 0.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.5em 0.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.7em 0.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 0.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 0.3em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 0.3em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.5em 0.3em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.7em 0.3em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 0.3em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 0.5em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 0.5em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.5em 0.5em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.7em 0.5em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 0.5em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 0.7em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 0.7em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.5em 0.7em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.7em 0.7em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 0.7em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 0.9em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 0.9em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.5em 0.9em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.7em 0.9em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 0.9em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.1em 1.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.9em 1.1em / 0.1em 0.1em no-repeat,
		linear-gradient(to bottom, #39a9d6 0%, #39a9d6 100%) 0.3em 1.1em / 0.5em 0.3em no-repeat /* 入り口 */
	;
}

タイトルとURLをコピーしました