frontend-dorset/exercises/assets/css/style-6.css

74 lines
2.0 KiB
CSS

/* ============= WEB BROWSER RESETS ============ */
* { margin: 0; padding: 0; border: none }
*, *::before, *::after { box-sizing: border-box }
html { height: 100%; font-size: 100%; font: inherit; vertical-align: baseline;
scroll-behavior: smooth; scroll-padding-top: 20px }
body { max-width: 1920px; line-height: 1.5; margin-left: auto; margin-right: auto;
min-height: 100vh; text-rendering: optimizeSpeed }
img { width: 100%; height: auto; display: block }
h1, h2, h3, h4 { width: 100% }
input, button, textarea, select { font: inherit }
/* ================= ENDS ================ */
/* Desktops */
@media (min-width: 768px) { body { padding: 4% 20% } }
/* Mobiles */
@media (max-width: 767px) { body { padding: 12% 8% } }
body {background-color: #c2ffc2 }
h1, h2, h2 { color: #008000; letter-spacing: -2px; }
/* Main heading */
h1 {
font-family: 'Oswald', sans-serif;
font-weight: bold;
font-size: calc(38px + (64 - 38) * ((100vw - 320px) /(1600 - 320)));
line-height: 1.1;
margin-bottom: 30px;
}
/* Small headings */
h2 {
font-family: 'Oswald', sans-serif;
font-weight: bold;
font-size: calc(28px + (54 - 28) * ((100vw - 320px) /(1600 - 320)));
line-height: 1.3;
margin-top: 42px;
margin-bottom: 4px;
letter-spacing: 0.5px;
}
/* Text paragraphs */
p {
font-family: 'Lato', sans-serif;
font-size: calc(17px + (22 - 17) * ((100vw - 320px) /(1600 - 320)));
color: #011301;
line-height: 1.6;
margin-bottom: 20px;
}
/* Images */
img {
margin-bottom: 32px;
border-radius: 15px;
}
/* Passive link styles */
a:link, a:visited {
text-decoration: none;
padding-bottom: 2px;
color: #006600;
border-bottom: solid 2px #006600;
}
/* Interactive link styles */
a:hover, a:focus, a:active {
text-decoration: none;
padding-bottom: 2px;
color: #222;
border-bottom: solid 2px #222;
}