Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CSS Fundamentals
Search
Cheesecake Labs
May 14, 2018
Programming
49
0
Share
CSS Fundamentals
Beatriz Silveira
Cheesecake Labs
May 14, 2018
More Decks by Cheesecake Labs
See All by Cheesecake Labs
Cats' wellness & care
cheesecakelabs
0
70
How do we create the first impressions?
cheesecakelabs
0
75
Menstrual cup: suit and freedom
cheesecakelabs
0
93
Life is a cycle, better with a bicycle
cheesecakelabs
0
77
Interview Process: how to get the best of people
cheesecakelabs
1
120
My capsule wardrobe experience
cheesecakelabs
3
83
Stonewall Rebellion and its impact on LGBTQIA+ history
cheesecakelabs
1
63
Pregnancy, childbirth and breastfeeding: What do I have to do with it?
cheesecakelabs
0
65
MBTI - Psychological types described by Jung
cheesecakelabs
0
160
Other Decks in Programming
See All in Programming
Agentic UI beyond Chats Architecture Patterns & Open Standards @ngMunich 05/2026
manfredsteyer
PRO
0
130
1人1案件のプロダクトエンジニア時代に、"プロセス監督"としてチャレンジしたこと
non0113
0
160
iOS26時代の新規アプリ開発
yuukiw00w
0
180
2026年のソフトウェア開発を考える(2026/05版) / Software Engineering Scrum Fest Niigata 2026 Edition
twada
PRO
24
14k
色即是空、空即是色、データサイエンス
kamoneggi
1
140
運用エージェントは "作る" から "育てる" へ - 記憶と自己進化の3層設計パターン / self-evolving-agents-three-layer-agent-design
gawa
7
450
Oxlintはいかにしてtsgolintのlint ruleを呼び出しているのか
syumai
1
420
Cloudflare で始める Data Platform
ta93abe
0
210
リセットCSSを1行消したらアクセシビリティが向上した話
pvcresin
4
530
Sans tests, vos agents ne sont pas fiables
nabondance
0
150
書き換えて学ぶTemporal #fukts
pirosikick
2
390
Modding RubyKaigi for Myself
yui_knk
0
380
Featured
See All Featured
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.4k
Chasing Engaging Ingredients in Design
codingconduct
0
190
Into the Great Unknown - MozCon
thekraken
41
2.5k
Un-Boring Meetings
codingconduct
0
290
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.5k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
140
Building AI with AI
inesmontani
PRO
1
1k
Leo the Paperboy
mayatellez
7
1.8k
The untapped power of vector embeddings
frankvandijk
2
1.7k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.7k
Design in an AI World
tapps
1
210
Transcript
CSS Fundamentals
Timeline • css1- released in 1996 • css2 - released
in 1998 • css3 - in Development (Split up into independent modules) • https://www.w3.org/TR/
Selectors • Element • Class • ID • Universal •
Attribute
Selection by Element
Selection by Class
Selection by ID
Selection by Attributes
Selection Universal
None
Cascading Style & Specificity Inline Styles #ID .class :pseudo-class [attribute]
<Tag> ::pseudo-element
Combinators • Adjacent Sibling • General Sibling • Child •
Descendant • Group of Selectors
Adjacent Sibling Combinator
General Sibling Combinator
Child Combinator
Descendant Combinator
Group of Selectors
But why Do I need selectors and Combinators ? Spoiler:
To Apply properties
Properties
But how this property interfere in my CSS ?
Every element in HTML is interpreted as a box by
CSS CSS Box Model
Margin Collapsing
Display Property display: block;
Display Property display: inline display: inline-block
Positioning Elements with CSS • Position: • static • Fixed
• Relative • Absolute
Positioning Elements with CSS Position: Static Default value
Positioning Elements with CSS
Positioning Elements with CSS <div> Top Bottom Left Right
Fixed Position
Z-index
Absolute & Relative
Absolute & Relative
Pixel, Percentages & More
How is the size calculated? Absolute Viewport Relative Font Relative
px rem vh em vw %
Rules to remember
REM x EM https://codepen.io/beatriz1304/pen/ELReaJ
vh & vw https://codepen.io/beatriz1304/pen/VxdGKa
Box-sizing box-sizing: content-box; box-sizing: border-box;
Box-sizing
Box-sizing
Some cases not covered • Font Family • pseudo class
and pseudo elements • @media query • Flexbox • Grid Layout • Images • Transition • Animation