@import url("https://fonts.googleapis.com/css2?family=Rowdies&display=swap"); /* MAIN CODE SHOWCASING THE USE OF PADDING */ .p-top { padding-top: 30px; } .p-right { padding-right: 30px; } .p-bottom { padding-bottom: 30px; } .p-left { padding-left: 30px; } .p-allFourSides { padding: 30px; } /* -------------------------- */ * { margin: 0; padding: 0; box-sizing: border-box; } html, body { height: 100%; } body { font-family: "Rowdies", cursive; color: #262626; } .container { width: 100%; height: 100%; border: 16px ridge #ff6550; background: #ffe7e7; text-align: center; } .box { margin-top: 3rem; display: grid; grid-template-columns: repeat(3, minmax(200px, 1fr)); justify-content: center; align-items: center; gap: 3rem; padding: 2rem; } [class^="p-"] { border: 4px solid tomato; } [class^="p-"] > div { width: 100px; height: 100px; background: #d33a25; } @media (max-width: 900px) { .box { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); } }