Neo-brutalist blocks are a flat fill, a heavy black border, and a shadow that is a shifted copy of the shape with no blur. The page writes a .brutal rule and a .brutal:active rule. The opening color #427f9c, a 3px border, an 8px radius, and a 6px offset produce a black label (because that teal prefers black text), border 3px solid #111, and box-shadow 6px 6px 0 #111. On press, the element translates by the same 6px and the shadow disappears, so the block looks like it sat down onto the offset.
The shadow color is black, not a tint of the fill. If your page background is also near black, the offset vanishes. Use a light page color behind it. Radius can go soft, but a large radius with a hard shadow starts to look like a sticker rather than a rubber stamp. The active state uses transform, so a parent with overflow hidden can clip the resting shadow. Leave room.
This is one opinionated component. The box-shadow page is where you stack arbitrary layers, blurs, and spreads.
Base #427f9c, border 3px, shadow offset 6px, radius 8px.
.brutal { background: #427f9c; color: #000000; border: 3px solid #111; border-radius: 8px; box-shadow: 6px 6px 0 #111; } .brutal:active { transform: translate(6px, 6px); box-shadow: none; }
Oddsock runs this in your browser. It is free, it does not upload the work, and it does not ask for an account.
The active rule translates by the same offset as the shadow and then removes the shadow. If those numbers diverge, the block appears to jump past its own shadow.
Not in this snippet. It is a hard offset. Blurred layers belong on the box-shadow page.
The fill is tested against black and white, and black wins on #427f9c. A darker base can flip the label to white.
The shadow is #111. On a near-black background it has no edge. Use a pale page behind this treatment.
The CSS is there for :active. Keyboard users still need a :focus-visible style, which this snippet does not include.