Category strip
A row of photo tiles edge to edge, each with a white tall-caps label, that zoom on hover.
Part of the style
Tall Caps Showroom
7 parts that belong together, with their tokens, type and rules.
https://kitbash.me/components/tall-caps-showroom/rooms/figma.html?palette=7ef8064dfd89d2ff
Use the Figma MCP server (https://mcp.figma.com/mcp). Download https://kitbash.me/components/tall-caps-showroom/rooms/figma.html?palette=7ef8064dfd89d2ff and pass that whole HTML document to the html_to_figma tool, so the part "Category strip" lands as editable layers in my open Figma file. Fonts come from Google Fonts: if a face is missing in Figma, pick the closest one.
Code
<style>
/* Goes after the pack's base.css */
:root {
--ink: #fbf4ee;
--ink-soft: rgba(251, 244, 238, 0.65);
--paper: #251a1a;
--paper-soft: rgba(37, 26, 26, 0.65);
--tile: #2b2020;
--rule: rgba(251, 244, 238, 0.18);
--rule-dark: rgba(37, 26, 26, 0.28);
--scrim: rgba(251, 244, 238, 0.32);
}
</style>
<nav class="rooms" aria-label="Shop by room">
<a class="rooms__tile" href="#">
<img class="rooms__picture" src="assets/drawing-room.jpg" alt="Pale green drawing room with tall windows and a chandelier" width="800" height="615" loading="lazy">
<span class="rooms__label">Drawing</span>
</a>
<a class="rooms__tile" href="#">
<img class="rooms__picture" src="assets/bedroom.jpg" alt="Dark panelled bedroom with a green canopy bed" width="800" height="606" loading="lazy">
<span class="rooms__label">Bedroom</span>
</a>
<a class="rooms__tile" href="#">
<img class="rooms__picture" src="assets/shaker-room.jpg" alt="Plain timber room with ladder-back chairs and an open door" width="800" height="373" loading="lazy">
<span class="rooms__label">Kitchen</span>
</a>
<a class="rooms__tile" href="#">
<img class="rooms__picture" src="assets/entrance-hall.jpg" alt="Entrance hall with a curving stair and painted wallpaper" width="800" height="772" loading="lazy">
<span class="rooms__label">Hallway</span>
</a>
</nav>
<style>
.rooms {
display: grid;
grid-template-columns: repeat(4, minmax(0, 1fr));
background: var(--ink);
}
.rooms__tile {
position: relative;
display: grid;
place-items: end center;
aspect-ratio: 5 / 6;
overflow: hidden;
color: var(--paper);
text-decoration: none;
isolation: isolate;
}
.rooms__picture {
position: absolute;
inset: 0;
z-index: -2;
width: 100%;
height: 100%;
object-fit: cover;
transition: transform var(--zoom) var(--ease);
}
.rooms__tile::after {
content: "";
position: absolute;
inset: 0;
z-index: -1;
background: linear-gradient(to top, var(--scrim), transparent 55%);
}
.rooms__tile:hover .rooms__picture,
.rooms__tile:focus-visible .rooms__picture {
transform: scale(1.05);
}
.rooms__tile:focus-visible {
outline: var(--rule-thin) solid var(--paper);
outline-offset: -6px;
}
.rooms__label {
padding: 0 var(--space-s) clamp(1.25rem, 3vw, 2.5rem);
font-family: var(--font-display);
font-size: var(--display-m);
line-height: 1;
letter-spacing: var(--track-display);
text-transform: uppercase;
}
@media (max-width: 40rem) {
.rooms {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
.rooms__tile {
aspect-ratio: 1 / 1.15;
}
}
</style>