🏠 Home / Hub

CSS Basic Lessons

CSS အခြေခံများ — Selectors မှ Grid အထိ Interactive examples

10 Lessons · All CSS Basics Covered

Part 1 — Foundation

Part 2 — Layout

Part 3 — Modern CSS

📋 CSS Quick Cheat Sheet

Selectors

div ← element
.class ← class
#id ← id
div > p ← child
:hover ← pseudo

Box Model

margin: 10px 20px;
padding: 8px 16px;
border: 1px solid #ccc;
box-sizing: border-box;
width / height

Typography

font-size: 16px / 1rem;
font-weight: bold / 700;
line-height: 1.5;
text-align: center;
color: #333;

Flexbox

display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap;
gap: 16px;

Grid

display: grid;
grid-template-columns:
repeat(3, 1fr);
gap: 16px;
grid-area: name;

Position

position: relative;
position: absolute;
position: fixed;
top/right/bottom/left
z-index: 10;

Animation

transition: all 0.3s;
transform: scale(1.1);
@keyframes name { }
animation: name 1s
infinite;

Modern CSS

--color: #42b883;
color: var(--color);
width: calc(100% - 20px);
font-size: clamp(
14px, 2vw, 18px);

📌 Study Checklist