Navigation and links in CSS
CSS controls the appearance of links and their interaction states, not the navigation destination itself. Learn link selectors, visible focus, and highlighting the element addressed by a URL fragment.
CKTIS / CSS
Programming syntax, operators and concepts. Find an explanation, explore an example and return to learning.
CSS controls the appearance of links and their interaction states, not the navigation destination itself. Learn link selectors, visible focus, and highlighting the element addressed by a URL fragment.
Positioning determines a box's location and participation in normal flow. Stacking determines which overlapping box appears in front. Understanding containing blocks and stacking contexts helps you use position and z-index correctly.
Print styles adapt a document for printing or print preview using @media print. They can hide navigation, change text presentation, and specify page margins and preferences for breaking content across pages.
Progressive enhancement starts with a usable baseline, then adds optional styles according to supported features. Missing enhancements should not prevent access to the content.
Responsive design adapts a layout to the available space instead of assuming one fixed page size. CSS supports this through flexible layouts and conditional rules, such as @media queries based on viewport width.
Safe CSS embedding requires control over rules and resource addresses, not just valid syntax. Keep trusted styles separate from user data, and do not treat a link’s appearance or its :visited state as a security guarantee.
CSS selectors determine which elements a style rule matches. They combine conditions about an element’s type, class, ID, attributes, or state with relationships in the document tree.
Document semantics describes what elements mean. CSS controls their presentation; changing display does not change the meaning defined by the document language.
The CSS table model arranges cells into related rows and columns. HTML describes the data and header relationships, while CSS controls presentation: borders, spacing, caption placement, and width calculation.
CSS typography covers font selection and text layout: font size and weight, line height, spacing, alignment, and wrapping. Distinguishing font properties from layout properties helps you predict inheritance and text behavior.
A CSS value must match the syntax of its property. Learn the difference between numbers, dimensions, and percentages, the basics of relative and absolute units, and calculations with calc(), min(), max(), and clamp().
The `swap` value keeps the invisible-text period brief and sets no deadline for a successfully loaded web font to replace the visible fallback.
Find which CSS declarations affect an element, read its property values and dimensions, and test a forced pseudo-class state and temporary style edits.
Screenshots show appearance, FPS describes frame rate, Paint flashing marks painted regions, and Layers shows compositing structure. None of these signals is a performance guarantee you can derive from CSS alone.
`format()` identifies the expected format of one font source so the browser can skip an unsupported source without fetching its data.
`format()` tells the browser what format to expect from one font source, so it can skip an unsupported source without downloading it.
Learn how a legacy CSS clipping rule hides the native radio button’s appearance while preserving its semantics and keyboard behavior.
Four zero offsets in legacy `clip: rect(0 0 0 0)` leave no visible area. An `.sr-only` utility uses that effect to hide text visually while keeping it available to screen readers.
Learn how the deprecated `clip` property uses a zero-area `rect()` to hide text visually and how it differs from modern `clip-path`.
Use `/* */` to leave notes in CSS, and learn to read a declaration as a property name, a colon, and a value. Semicolons separate declarations in a block.
Order font sources in `src` and distinguish `local()`, which looks up an installed face, from `format()`, which hints at the format of a URL resource.
abs() returns a calculation’s non-negative magnitude while preserving its CSS numeric type.
acos() maps a cosine in the domain −1 through 1 to a principal angle from 0 through 180 degrees.
`alpha()` creates a relative color that keeps the origin color channels and replaces or calculates only its alpha channel.