#css

[ follow ]
#container-queries
Web development
fromWebKit
2 days ago

Name-only @container queries: A solution to the naming wars

Name-only @container queries simplify styling by improving scoping without increasing specificity, addressing conflicts in CSS for elements with similar names.
#svg
Web development
fromFrontendmasters
1 week ago

SVG Filters Guide: Getting Started with the Basics

SVG filters can enhance design without requiring artistic skills, and a structured approach can simplify their implementation.
Typography
fromCsswizardry
5 days ago

font-family Doesn't Fall Back the Way You Think - CSS Wizardry

Font-family declarations are self-contained and do not inherit fallback options from parent elements.
jQuery
fromCSS-Tricks
6 days ago

Selecting a Date Range in CSS | CSS-Tricks

A date range selector allows users to choose a time frame for various scheduling and booking tasks.
#javascript
fromwww.jqueryscript.net
2 months ago
Web development

Weekly Web Design & Development News: Collective #643

Essential 2026-ready JavaScript and CSS libraries, AI tools, developer resources, design assets, and updated top-10 audits for modern web development.
fromwww.jqueryscript.net
4 months ago
Web development

Weekly Web Design & Development News: Collective #632

Weekly roundup of web development and design resources: JS/CSS libraries, code snippets, UI components, AI tools, design freebies, and major news like Gemini 3 Pro.
JavaScript
fromRubyflow
1 week ago

Practical CSS: simplifying UI code with pseudo-classes

CSS pseudo-classes can simplify UI interactions by handling presentation logic, allowing JavaScript to focus on behavior.
fromdaverupert.com
1 week ago
Web development

Inverted themes with light-dark()

Adaptive light-dark() support enhances design systems by allowing seamless theme switching without significant performance trade-offs.
#specificity
fromCSS-Tricks
1 week ago
Web development

Alternatives to the !important Keyword | CSS-Tricks

Using !important in CSS can lead to chaos and should be replaced with better practices for maintainability.
fromManuel Matuzovic
2 months ago
Web development

Lowering the specificity of multiple rules at once - Manuel Matuzovic

Anonymous @layer groups reset rules so normal unlayered author rules override them, preserving low specificity and improving readability.
Web development
fromCSS-Tricks
1 week ago

Alternatives to the !important Keyword | CSS-Tricks

Using !important in CSS can lead to chaos and should be replaced with better practices for maintainability.
Web development
fromCSS-Tricks
1 week ago

New CSS Multi-Column Layout Features in Chrome | CSS-Tricks

New CSS properties in Chrome 145+ allow multi-column layouts to avoid horizontal scrolling by enabling vertical wrapping of content.
Web development
fromCSS-Tricks
1 week ago

Making Complex CSS Shapes Using shape() | CSS-Tricks

Creating complex CSS shapes with randomness and curves is challenging but achievable using modern features and generators.
Games
fromCSS-Tricks
2 weeks ago

Front-End Fools: Top 10 April Fools' UI Pranks of All Time | CSS-Tricks

Tech April Fools' Day announcements often blur the line between reality and joke, showcasing genuine innovations alongside humorous concepts.
Web development
fromCsswizardry
2 weeks ago

What Is CSS Containment and How Can I Use It? - CSS Wizardry

CSS containment optimizes browser performance by defining boundaries for DOM elements, allowing the browser to skip unnecessary work during changes.
fromThe JetBrains Blog
3 weeks ago

Expanding Our Core Web Development Support in PyCharm 2026.1 | The PyCharm Blog

With PyCharm 2026.1, users can leverage a comprehensive set of editing and formatting tools for modern web languages, including basic React support with code completion and navigation.
Python
fromJoshwcomeau
3 weeks ago

Sneaky Header Blocker Trick * Josh W. Comeau

The site header itself has a transparent background that never changes. It sits in front of the page using position: fixed and doesn't really do anything special.
React
Web design
fromPiccalilli
1 month ago

Building dynamic toggletips using anchored container queries

Chrome 143 introduces anchored container queries, enabling dynamic styling based on active fallback positions in anchor positioning layouts.
#selectors
Typography
fromPiccalilli
1 month ago

An in-depth guide to customising lists with CSS

Lists should be styled and spaced like regular text, with appropriate indentation, bullet/number styles, positioning, and extra space for multi-digit numbering.
fromLogRocket Blog
1 month ago

CSS @container scroll-state: Replace JS scroll listeners now - LogRocket Blog

Scroll containers have always been a weak spot in CSS. For years, if you wanted a navigation bar to restyle itself once it became sticky, or a photo to react when it entered the viewport, JavaScript was the only real option. Most of us have written the same pattern: add a scroll listener, call getBoundingClientRect() a few times, flip some classes, and hope the main thread keeps up. It's a lot of machinery for something that should be simple.
Web development
Web development
fromCSS-Tricks
1 month ago

Interop 2026 | CSS-Tricks

Major browser engines are collaborating to deliver consistent support for new CSS features, enabling anchor positioning, advanced attr(), contrast-color(), and text fragments.
fromCSS-Tricks
2 months ago

Approximating contrast-color() With Other CSS Features | CSS-Tricks

There have been a few drafts of a specification function for this functionality, most recently, contrast-color() (formerly color-contrast()) in the CSS Color Module Level 5 draft. But with Safari and Firefox being the only browsers that have implemented it so far, the final version of this functionality is likely still a ways off. There has been a lot of functionality added to CSS in the meantime; enough that I wanted to see whether we could implement it in a cross-browser friendly way today. Here's what I have: color: oklch(from <your color> round(1.21 - L) 0 0);
Web development
Web development
fromCSS-Tricks
2 months ago

Trying to Make the Perfect Pie Chart in CSS | CSS-Tricks

Create accessible, HTML-customizable pie charts using CSS with minimal JavaScript to avoid heavy libraries and address conic-gradient limitations.
Web development
fromSmashing Magazine
2 months ago

CSS @scope: An Alternative To Naming Conventions And Heavy Abstractions - Smashing Magazine

@scope enables true scoping of CSS to components, reducing style leakage and the need for complex naming conventions and specificity wars.
Web development
fromSmashing Magazine
2 months ago

CSS @scope: An Alternative To Naming Conventions And Heavy Abstractions - Smashing Magazine

Rigid class naming alone cannot prevent CSS leakage; true scoping like the @scope rule is needed to make styles maintainable for complex, interactive front ends.
UX design
fromIshadeed
2 months ago

The Too Early Breakpoint

Avoid switching to a mobile layout before available space requires it to preserve design integrity and ensure truly responsive CSS.
Web design
fromCloud Four
2 months ago

Faking a Fieldset-Legend

Mimic a native <legend> overlay by slicing a bordered container into three areas, using CSS Grid and pseudo-elements for a transparent, center-aligned, multi-line heading.
Web development
fromCSS-Tricks
2 months ago

ReliCSS | CSS-Tricks

Use ReliCSS to detect outdated CSS, prioritize high-severity legacy hacks for removal, review medium-severity hacks, and automate handling of low-severity vendor prefixes.
Web development
fromCSS-Tricks
2 months ago

How to Style the New ::search-text and Other Highlight-y Pseudo-Elements | CSS-Tricks

Chrome 144 added ::search-text pseudo-element to style find-in-page matches and related highlight pseudo-elements enable customizable highlights for accessibility and usability.
#wordpress
fromSmashing Magazine
2 months ago

Unstacking CSS Stacking Contexts - Smashing Magazine

Stacking contexts are incredibly useful, but they're also widely misunderstood and often mistakenly created, leading to a slew of layout issues that can be tricky to solve. Have you ever set z-index: 99999 on an element in your CSS, and it doesn't come out on top of other elements? A value that large should easily place that element visually on top of anything else, assuming all the different elements are set at either a lower value or not set at all.
Web design
Web design
fromCSS-Tricks
2 months ago

Open Props @custom-media Recipes | CSS-Tricks

Firefox Nightly supports the @custom-media at-rule (behind a flag), enabling reusable aliases for complex media queries to simplify CSS and reduce repetition.
Web development
fromCSS-Tricks
2 months ago

Responsive Hexagon Grid Using Modern CSS | CSS-Tricks

Modern CSS features (corner-shape, sibling-index(), unit-division) enable a simpler, media-query-free responsive hexagon grid implementation currently supported in Chrome.
fromCSS-Tricks
2 months ago

What's !important #3: Popover Context Menus, @scope, New Web Platform Features, and More | CSS-Tricks

The developer community hasn't wasted any time kicking off 2026 with some really great articles, demos, and insights. Firefox 147 and Chrome 144 also shipped, and while they're not jam-packed with features, the releases are still pretty exciting for what's normally a slow time of year, so without further ado, here's what's important from the last couple of weeks (or should I say the first couple of weeks, of 2026?)...
Web development
Web design
fromMedium
2 months ago

Generate Animated Effects for the Web with Claude

AI tools like Anthropic's Claude can generate high-quality web animated effects and ready-to-use prompts, streamlining creation of polished, lightweight UI animations.
fromSmashing Magazine
3 months ago

Smashing Animations Part 8: Theming Animations Using CSS Relative Colour - Smashing Magazine

I've recently refreshed the animated graphics on my website with a new theme and a group of pioneering characters, putting into practice plenty of the techniques I shared in this series. A few of my animations change appearance when someone interacts with them or at different times of day. The colours in the graphic atop my blog pages change from morning until night every day.
Web design
fromSitePoint Forums | Web Development & Design Community
3 months ago

iOS Safari bottom padding issue? (Footer overlapping content)

The site is https://spectrumoutage.org - it works perfectly on Chrome desktop and Android, but when I load it on my iPhone (Safari), the bottom footer seems to float up and cover the last 50px of the content.
Web development
Web development
fromCSS-Tricks
3 months ago

Future CSS: :drag (and Maybe ::dragged-image?) | CSS-Tricks

The :drag pseudo-class enables styling of elements during active user dragging, allowing CSS-only drag-state visuals without JavaScript class toggling.
fromeLearning
3 months ago

Captivate 13 Flip Card Widget - eLearning

Greetings. Can someone please tell me how to get the image on the back of the flip card to fill the card like the image on the front of the card? See attachment with identical image on front and back. I have read the help documentation but did not fine the information needed. Basically, I need the images on the front and back to be the same dimensions. Thank you.
UX design
Web frameworks
fromRaymondcamden
3 months ago

An Astro site for my CSS Snippets

A simple Astro site was created to organize and render frequently used CSS snippets, storing each tip as a separate Markdown file for quick reuse.
Web development
fromFrontendmasters
3 months ago

!important and CSS Custom Properties

CSS custom property declarations can be marked !important, but the !important keyword applies to the declaration, not to the stored custom property value.
Web design
fromCSS-Tricks
3 months ago

What's !important #2: Conditional View Transitions, CSS/SVG Text Effects, the Best of CSS Bluesky, and More | CSS-Tricks

Recent CSS developments include conditional view transitions, accessibility annotations for design systems, SVG/CSS text effects, and browser AI controversy with an AI kill switch.
Web development
fromCSS-Tricks
3 months ago

text-decoration-inset is Like Padding for Text Decorations | CSS-Tricks

text-decoration-inset clips text decoration ends using independent left/right length insets, aligning decorations to glyphs and enabling transitions, animations, and precise styling.
#web-development
fromCSS-Tricks
3 months ago

What's !important #1: Advent Calendars, CSS Wrapped, Web Platform Updates, and More | CSS-Tricks

Welcome to the first ever What's !important, a roundup of the best CSS and web development news from the last two weeks. If you're pressed for time (who isn't?) or you just can't stand missing out on anything CSS-related, this is the place to recap: the best CSS/web dev articles from around the web, interesting announcements and quick-read links that we shared, the best of what Chrome, Firefox, and Safari have recently shipped, and more, probably. Let's dig in!
Web development
#typography
fromCSS-Tricks
3 months ago

Responsive List of Avatars Using Modern CSS (Part 1) | CSS-Tricks

You are for sure wondering what the novelty we are bringing here is, right? It has been done countless times. You are right. The main idea is not complex, but the new thing is the responsive part. We will see how to dynamically adjust the overlap between the images so they can fit inside their container. And we will make some cool animations for it along the way!
UX design
fromPiccalilli
4 months ago

A pragmatic guide to modern CSS colours - part two

In my previous article on colours, I dove into the practical side of the new colour features for developers who primarily copy and paste values from a design file into their editor. With all the new colour features that we have in CSS now, we can do more with colours in the browser than designers can do in their design apps, and it opens up a whole world of possibilities.
Web development
#html
fromCSS-Tricks
4 months ago

CSS Wrapped 2025 | CSS-Tricks

The Chrome Dev Team recaps the new CSS features that shipped in Google Chrome this past year in one amazingly designed webpage. They cover new functionality for creating more customizable components, next-gen interactions, and optimizing ergonomics.
Web development
fromCSS-Tricks
4 months ago

Fit width text in 1 line of CSS | CSS-Tricks

text-grow: &lt;fit-target&gt; &lt;fit-method&gt;? &lt;length&gt;?; text-shrink: &lt;fit-target&gt; &lt;fit-method&gt;? &lt;length&gt;?; per-line: For text-grow, lines of text shorter than the container will grow to fit it. For text-shrink, lines of text longer than the container will shrink to fit it. consistent: For text-grow, the shortest line will grow to fit the container while all other lines grow by the same scaling factor. For text-shrink, the longest line will shrink to fit the container while all other lines shrink by the same scaling factor.
Typography
fromSmashing Magazine
4 months ago

State, Logic, And Native Power: CSS Wrapped 2025 - Smashing Magazine

CSS Wrapped 2025 is out! We're entering a world where CSS can increasingly handle logic, state, and complex interactions once reserved for JavaScript. It's no longer just about styling documents, but about crafting dynamic, ergonomic, and robust applications with a native toolkit more powerful than ever. Here's an unpacking of the highlights and how they connect to the broader evolution of modern CSS.
Web development
fromTheregister
4 months ago

Novel clickjacking attack relies on CSS and SVG

Security researcher Lyra Rebane has devised a novel clickjacking attack that relies on Scalable Vector Graphics (SVG) and Cascading Style Sheets (CSS). Rebane demonstrated the technique at BSides Tallinn in October and has now published a summary of her approach. The attack, which has yet to be fully mitigated, relies on the fact that SVG filters can leak information across origins, in violation of the web's same-origin policy.
Information security
Web development
fromCSS-Tricks
4 months ago

Scrollytelling on Steroids With Scroll-State Queries | CSS-Tricks

Scroll-driven storytelling leverages ancient scroll practices to create immersive narratives while modern CSS-based scroll-driven animations enable smoother, more accessible interactive design.
Web development
fromTreehouse Blog
4 months ago

Front-End Web Development: Build and Design Interactive Websites

Front-end development enables creation of visual, interactive websites using HTML, CSS, and JavaScript and offers an accessible path for beginners.
Web development
fromLogRocket Blog
4 months ago

How to create fancy corners using CSS corner-shape - LogRocket Blog

Use the new CSS corner-shape property combined with advanced border-radius to create complex corner geometries like squircles and arrows without SVGs, masking, or clipping.
#animations
Web development
fromCSS-Tricks
4 months ago

Should We Even Have :closed? | CSS-Tricks

A :closed pseudo-class is not strictly necessary because details:not(:open) already targets closed state, though naming and top-layer semantics motivate further spec consideration.
fromSitePoint Forums | Web Development & Design Community
4 months ago

Custom CSS code to change Tooltip B/G

Can someone pls share a custom css code to change the tooltip B/G color from blue to orange (#ff6e3d) ? The tooltip is found on the listing card module on 2 pages namely: (1) Home Page &amp; (2) Listing page. Home Page &gt; Card Module &gt; Tooltip screenshot Home page link Listing page &gt; Card Module &gt; Tooltip screenshot Listing page link There are 3x tooltips on the card module ie Detail Video, Gallery &amp; Preview. The custom code code should apply to the 3x tooltip on the 2x pages. Thanks in Advance.
Web development
fromCSS-Tricks
4 months ago

The "Most Hated" CSS Feature: asin(), acos(), atan() and atan2() | CSS-Tricks

What if we wanted to go the other way around? If we have a ratio that represents the sine, cosine or tangent of an angle, how can we get the original angle? This is where inverse trigonometric functions come in! Each inverse function asks what the necessary angle is to get a given value for a specific trigonometric function; in other words, it undoes the original trigonometric function. So...
Web development
Web development
fromLogRocket Blog
5 months ago

When to use CSS text-wrap: balance vs. text-wrap: pretty - LogRocket Blog

text-wrap controls how inline text wraps in CSS, offering values like wrap, nowrap, and balance to manage overflow and improve typographic balance.
Web development
fromFrontendmasters
5 months ago

Super Simple Full-Bleed & Breakout Styles

Modern CSS offers multiple valid approaches for full-bleed and breakout elements; choose between vw-offset techniques or grid-based column spanning based on layout needs and scrollbar behavior.
Web development
fromCSS-Tricks
5 months ago

The "Most Hated" CSS Feature: tan() | CSS-Tricks

tan() computes tangent (opposite divided by adjacent) enabling calculation of triangle dimensions for CSS layouts, such as arranging elements into polygonal slices.
Web development
fromFrontendmasters
5 months ago

Perfectly Pointed Tooltips: A Foundation

The CSS Anchor Positioning API can place tooltips responsively without JavaScript, preventing overflow and edge cutoffs while reducing weight and performance costs.
fromTechzine Global
5 months ago

CSS finally gets support for if() function

After years of developer frustration and questions on online forums, it's finally happening: CSS is getting an if() function to apply styling when a condition is met. For the first time, developers can make logical decisions directly in stylesheets, without separate code blocks. This opens up whole new possibilities for web designers. CSS is a mature styling language that determines how web pages look.
Web development
fromCSS-Tricks
6 months ago

We Completely Missed width/height: stretch | CSS-Tricks

What does stretch do? The quick answer is that stretch does the same thing as declaring 100%, but ignores padding when looking at the available space. In short, if you've ever wanted 100% to actually mean 100% (when using padding), stretch is what you're looking for: div { padding: 3rem 50vw 3rem 1rem; width: 100%; /* 100% + 50vw + 1rem, causing overflow */ width: stretch; /* 100% including padding, no overflow */ }
Web development
UX design
fromFrontendmasters
6 months ago

Modern CSS Round-Out Tabs

Use CSS shape() with clip-path to carve rounded, flared tab shapes out of an element without extra DOM elements, enabling variable and flexible coordinates.
Web development
from2ality
6 months ago

Web development for beginners: Styling HTML via CSS

CSS (Cascading Style Sheets) defines the presentation of HTML by applying cascading style rules to control backgrounds, fonts, spacing, borders, and layout.
Web development
fromPiccalilli
6 months ago

A pragmatic guide to modern CSS colours - part one

Modern CSS color syntax uses space-separated functions and unified alpha channels, letting developers omit rgba() and commas, with only IE lacking support.
fromLogRocket Blog
6 months ago

Would You Use If() functions in CSS? - LogRocket Blog

The CSS if() function introduces real conditional logic to CSS. It allows you to write conditions inline instead of relying on media queries or workarounds : Works with style() , media() , and supports() queries for theming, responsive tweaks, and state-based styling Fits property-level decisions, while media and container queries still handle broader layout changes Supports nested logic and pairs well with calc() for advanced patterns Currently supported only in Chromium browsers, so use progressive enhancement and @supports checks
Web development
Web development
fromCSS-Tricks
6 months ago

Getting Creative With shape-outside | CSS-Tricks

Using CSS shape-outside lets text flow around an image's contours, breaking rigid boxes and adding movement, personality, and engagement to long-form layouts.
fromFrontendmasters
6 months ago

How much do you really know about media queries?

Earlier this year, I realized that I knew very little about possibly most of the media queries. Maybe that's not surprising - since I never hear about them. Beyond the classics like @media(min-width: 400px) and the user-preference media queries such as @media (prefers-reduced-motion: reduce), and maaaybe orientation, I can't say that I was using media queries a whole lot. Especially since flexbox, grid layout, and calc() became fairly normalized, in addition to newer sizing values such as min-content, max-content, fit-content, and more recently, stretch.
Web development
Web development
fromUtilitybend
6 months ago

Styling siblings with CSS has never been easier. Experimenting with sibling-count and sibling-index | utilitybend

sibling-index() and sibling-count() enable selecting elements by position among siblings, simplifying staggered animations and conditional CSS logic.
Typography
fromTerence Eden's Blog
6 months ago

Targetting specific characters with CSS rules

CSS can target specific Unicode characters by loading different fonts with @font-face and unicode-range, enabling per-character styling without extra markup.
Web development
fromWebKit
6 months ago

Position-area: Clear and explicit or short and sweet?

A proposed center-span-inline-end CSS keyword would explicitly specify the start and end when spanning columns, increasing clarity at the cost of slight verbosity.
Web development
fromCSS-Tricks
6 months ago

Touring New CSS Features in Safari 26 | CSS-Tricks

Safari 26.0 is a major release adding 75 new features, 3 deprecations, and 171 improvements, including significant new CSS capabilities like anchor positioning.
[ Load more ]