<main>
  <p>CSS <strong><code>width</code></strong> 속성은 요소의 너비를 설정합니다.
</main>
p {
  width: fit-content;
  margin: 10px;
  background: yellow;
}

main {
  width: 50%;
  border: 1px solid red;
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.