#app .card button:hover
One ID, two class-level parts, and one type selector gives 1-2-1.
Tính điểm trọng số ưu tiên của bộ chọn CSS theo công thức (ID, Class, Element), làm nổi bật bộ chọn nào sẽ ghi đè thuộc tính và hỗ trợ so sánh hai bộ chọn.
A wins
Điền các giá trị cần thiết, dán văn bản hoặc tải lên tệp bạn muốn xử lý.
Hầu hết các công cụ cập nhật theo thời gian thực khi bạn nhập liệu; một số công cụ sử dụng một nút hành động duy nhất.
Sao chép, tải xuống hoặc chia sẻ kết quả được tạo — bạn luôn có toàn quyền kiểm soát dữ liệu của mình.
Enter one or two CSS selectors to see their specificity, shown as ids-classes-types, and which one would win a conflict.
IDs count the most, then classes, attribute selectors, and pseudo-classes, then element type selectors and pseudo-elements. Combinators like space, >, and ~ don't affect specificity.
`#main .container p` scores 1 id, 1 class, 1 type (1-1-1), while `nav ul li.active a` scores 0 ids, 1 class, 4 types (0-1-4) — the first selector wins despite matching fewer elements by name.
IDs - classes/attributes/pseudo-classes - types/pseudo-elementsOne ID, two class-level parts, and one type selector gives 1-2-1.
All calculation runs in your browser; the selectors you enter are never sent anywhere.
When specificity ties, the rule that appears later in the stylesheet (or has higher CSS layer priority) wins.
No — inline `style` attributes always outrank any selector-based specificity, regardless of what this calculator shows.
No — only which kinds of selectors appear and how many of each, not the order they're written in.
No. This implementation counts each as one pseudo-class, except :where(), which contributes zero. The full CSS spec looks inside those arguments.
Kiểm tra tỷ lệ tương phản màu sắc văn bản và nền theo tiêu chuẩn WCAG 2.1.
Tính kích thước chiều rộng hoặc chiều cao tương ứng theo tỷ lệ 16:9, 4:3, 1:1...
Tạo các quy tắc CSS clamp() cho cỡ chữ và khoảng cách co giãn mượt mà theo màn hình.
Chuyển đổi mã SVG thành chuỗi CSS background Data URI và ngược lại.
Tự động trích xuất các màu sắc chủ đạo từ bất kỳ bức ảnh nào.
Giảm dung lượng tệp vector SVG bằng cách loại bỏ mã thừa và làm gọn đường vẽ.
Tạo hệ thống cỡ chữ hài hòa theo các tỷ lệ vàng, tỷ lệ Major Third, Perfect Fourth...
Xem trước hình ảnh qua góc nhìn của các dạng mù màu (Đỏ-Xanh, Lam-Vàng...).
Tính mật độ điểm ảnh PPI, kích thước điểm ảnh (dot pitch) và tổng số pixel màn hình.
Tạo mẫu chữ ký email đẹp mắt kèm logo, chức danh, liên kết mạng xã hội.