Skip to content

Commit

Permalink
css units
Browse files Browse the repository at this point in the history
  • Loading branch information
maykos_launchbase committed Mar 17, 2020
1 parent 2cec183 commit 347f700
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 18 deletions.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Responsividade

## CSS Units

Unidades de medidas do CSS

Layout Fixo
`px` - Pixels

Layout Fluido
`%` - Porcentagem
`auto` - Automática
`vh` - Viewport Height
`vw` - Viewport Width

Textos fixos
`1px` = 0.75pt
`16px` = 12pt

Texto fluidos
`em` - multiplicado pelo pai
`rem` - multiplicado pelo root

2 changes: 0 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,6 @@ <h2>
</section>
</main>



<section id="form">
<form action="">
<h3>Quero Estudar na Rocket!</h3>
Expand Down
48 changes: 32 additions & 16 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
outline: 0;
}

html {
/* a cada 1rem será considera 10px */
font-size: 62.5%;
}

html,
body {
height: 100vh;
Expand All @@ -15,6 +20,10 @@ body {
-webkit-font-smoothing: antialiased;
}

body {
font-size: 1.6rem;
}

header {
background-color: #7159c1;
}
Expand All @@ -24,7 +33,9 @@ header .container {
align-items: center;
justify-content: space-between;

width: 980px;
width: 90%;
max-width: 980px;

margin: auto;
}

Expand All @@ -46,8 +57,8 @@ header nav ul li a {
text-decoration: none;
color: white;
text-transform: uppercase;
font-size: 14px;
padding: 24px;
font-size: 1.4rem;
padding: 2.4rem;
transition: all 250ms linear 0s;
}

Expand All @@ -57,19 +68,19 @@ header nav ul li a:hover {

h2 {
color: rgb(75, 75, 75);
font-size: 36px;
line-height: 46px;
font-size: 3.6rem;
line-height: 4.6rem;
}

h3 {
color: rgb(75, 75, 75);
font-size: 28px;
line-height: 38px;
font-size: 2.8rem;
line-height: 3.8rem;
}

.button {
display: inline-block;
font-size: 16px;
font-size: 1.6rem;
font-weight: 600;
color: rgb(255, 255, 255);
background-color: rgb(113, 89, 193);
Expand All @@ -93,16 +104,18 @@ section.hero {
}

section.hero .container {
width: 980px;
width: 90%;
max-width: 980px;

margin: auto;

display: flex;
}

section.hero p {
color: rgb(154, 142, 191);
font-size: 18px;
line-height: 32px;
font-size: 1.8rem;
line-height: 3.2rem;
margin: 10px 0px 0px;
}

Expand All @@ -118,7 +131,8 @@ main {
CARDS
==================*/
.cards {
width: 980px;
width: 90%;
max-width: 980px;
margin: auto;

display: grid;
Expand All @@ -127,8 +141,8 @@ CARDS
}

.text--medium {
font-size: 16px;
line-height: 26px;
font-size: 1.6rem;
line-height: 2.6rem;
font-weight: 400;
color: #ecf0f1;
}
Expand Down Expand Up @@ -300,7 +314,9 @@ FORM
}

#form form {
width: 980px;
width: 90%;
max-width: 980px;

background: white;

padding: 40px;
Expand Down Expand Up @@ -334,7 +350,7 @@ FORM
display: block;
margin: -4px 8px 10px;
padding: 12px;
font-size: 16px;
font-size: 1.6rem;
}

#form .button {
Expand Down

0 comments on commit 347f700

Please sign in to comment.