# CSS: Reset by Kevin Powell.css

> Source: <https://gist.github.com/Lego2012/7b7956734f2ab4a95fd0c311cd8bbe95>
> Published: 2024-01-05 19:53:29+00:00

CSS: Reset by Kevin Powell.css

      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      
Learn more about bidirectional Unicode characters

 
    Show hidden characters

/* 

*   Kevin Powell

*   https://youtu.be/cCAtD_BAHNw 

*/

*, *::before, *::after {

  box-sizing: border-box;

}

* {

  margin: 0;

  padding: 0;

  font: inherit; /* Get rid of all font sizes and heights */

}

html {

  color-scheme: dark light; /* Default dark */

  hanging-punctuation: first last; /* Not supported in Chrome */

}

body {

  min-height: 100vh;

}

/* Media responsive */

img, picture, svg, video {

  display: block;

  max-width: 100%;

}

h1, h2, h3, h4, h5, h6 {

  text-wrap: balance;

}

p {

  max-width: 75ch;

  text-wrap: pretty; /* Prevents orphans on lines */

}

@media (prefers-reduced-motion: no-preference) {

  :has(:target) {

    scroll-behavior: smooth;

    scroll-padding-top: 3rem;

  }

}
