Editorial tile grid
Two-column grid of square story tiles, with photo, paper news, big-word and flat color tiles, split by hairline rules.
snippet.html124 lines
<section class="etg">
<div class="etg__grid">
<a class="etg__tile etg__tile--photo etg__tile--forest" href="#">
<span class="etg__tag"><i></i>Podcast</span>
<span class="etg__portrait" aria-hidden="true"></span>
<span class="etg__cap etg__cap--serif">Why the best interface is the one you stop noticing
<small>Field Notes hosted by Mara Ellison</small>
</span>
</a>
<a class="etg__tile etg__tile--paper" href="#">
<span class="etg__tag"><svg viewBox="0 0 16 16" aria-hidden="true"><path d="M2 3h12M2 6.5h12M2 10h8M2 13.5h8" stroke="currentColor" stroke-width="1.2" fill="none"/></svg>News</span>
<span class="etg__read">Read</span>
<span class="etg__lockup" aria-hidden="true"><b>P</b>PARCELWISE</span>
<span class="etg__cap etg__cap--center">Welcome to the Parcelwise team
<small>by Ines Okafor and Tomas Lind</small>
</span>
</a>
<a class="etg__tile etg__tile--ink" href="#">
<span class="etg__tag"><i></i>Perspective</span>
<span class="etg__word" aria-hidden="true">“Slow”</span>
<span class="etg__cap">What we learned from the second year</span>
</a>
<a class="etg__tile etg__tile--sun" href="#">
<span class="etg__list">
<span>The tinkerers.</span>
<span>The late bloomers.</span>
<span>The stubborn.</span>
<span>The quiet ones.</span>
<span>The ones who ship.</span>
<span>The people nobody</span>
</span>
</a>
<a class="etg__tile etg__tile--green" href="#">
<svg class="etg__doodle" viewBox="0 0 200 200" aria-hidden="true"><path d="M100 20 C 60 70, 30 140, 50 165 C 70 185, 100 150, 108 120 C 118 150, 140 185, 160 170 C 182 150, 150 70, 106 22 C 90 8, 82 30, 100 50"/></svg>
<span class="etg__cap">Meet the portfolio</span>
</a>
<a class="etg__tile etg__tile--blue" href="#">
<svg class="etg__doodle" viewBox="0 0 200 200" aria-hidden="true"><path d="M100 30 C 120 50, 125 100, 118 140 L 82 140 C 75 100, 80 50, 100 30 Z M82 140 L 66 165 L 82 158 M118 140 L 134 165 L 118 158 M92 160 L 90 186 M108 160 L 110 186 M100 70 m-6 0 a6 6 0 1 0 12 0 a6 6 0 1 0 -12 0 M40 50 l12 12 m0 -12 l-12 12 M160 60 l8 8 m0 -8 l-8 8"/></svg>
<span class="etg__cap etg__cap--dark">Open roles across the portfolio</span>
</a>
</div>
</section>
<style>
.etg {
--etg-bg: #fbf7f0;
--etg-ink: #111111;
--etg-rule: #cdc6b6;
--etg-gap: clamp(0.75rem, 2.2vw, 2rem);
box-sizing: border-box;
background: var(--etg-bg);
color: var(--etg-ink);
padding: clamp(1rem, 3.4vw, 3rem);
font-family: ui-sans-serif, system-ui, "Helvetica Neue", Arial, sans-serif;
}
.etg *, .etg *::before, .etg *::after { box-sizing: border-box; }
.etg__grid { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: var(--etg-gap); padding: 0 var(--etg-gap); border-inline: 1px solid var(--etg-rule); }
.etg__tile { position: relative; display: block; aspect-ratio: 1; margin-top: var(--etg-gap); overflow: hidden; color: #fff; text-decoration: none; isolation: isolate; }
.etg__tile::before { content: ""; position: absolute; top: calc(var(--etg-gap) * -0.5); left: 0; right: 0; height: 1px; background: var(--etg-rule); }
.etg__tile:nth-child(-n+2) { margin-top: 0; }
.etg__tile:nth-child(-n+2)::before { display: none; }
.etg__tile:nth-child(-n+2) { margin-bottom: 0; }
.etg__tile:focus-visible { outline: 3px solid var(--etg-ink); outline-offset: 3px; }
.etg__tile::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, 0); transition: background 0.25s; z-index: 1; pointer-events: none; }
.etg__tile:hover::after { background: rgba(255, 255, 255, 0.07); }
.etg__tag { position: absolute; z-index: 2; top: 1.5rem; left: 1.5rem; display: inline-flex; align-items: center; gap: 0.5rem; font: 0.8125rem/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 0.1em; text-transform: uppercase; }
.etg__tag i { width: 1.1rem; height: 1.1rem; border-radius: 50%; background: currentColor; }
.etg__tag svg { width: 1rem; height: 1rem; }
.etg__read { position: absolute; z-index: 2; top: 1.5rem; right: 1.5rem; font: 0.8125rem/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 0.1em; text-transform: uppercase; color: var(--etg-ink); }
.etg__cap { position: absolute; z-index: 2; left: 1.5rem; right: 1.5rem; bottom: 1.5rem; font-size: clamp(1.25rem, 2.1vw, 1.875rem); line-height: 1.15; letter-spacing: -0.015em; }
.etg__cap small { display: block; margin-top: 0.7rem; font-size: clamp(0.75rem, 1vw, 0.9375rem); letter-spacing: 0; line-height: 1.3; }
.etg__cap--serif { font-family: ui-serif, Georgia, serif; letter-spacing: -0.01em; }
.etg__cap--center { text-align: center; color: var(--etg-ink); }
.etg__cap--dark { color: var(--etg-ink); }
.etg__tile--forest { background: linear-gradient(160deg, #0f4a3a, #0a2f26); }
.etg__portrait { position: absolute; z-index: 0; left: 50%; top: 18%; width: 62%; aspect-ratio: 0.9; transform: translateX(-50%); background:
radial-gradient(ellipse 34% 30% at 50% 36%, #2e7a63 0 98%, transparent 100%),
radial-gradient(ellipse 30% 14% at 50% 14%, #0b2a21 0 98%, transparent 100%),
radial-gradient(ellipse 52% 40% at 50% 100%, #245f4d 0 98%, transparent 100%); }
.etg__tile--forest::after { background: linear-gradient(to top, rgba(0, 0, 0, 0.55), transparent 45%); opacity: 1; }
.etg__tile--forest:hover::after { background: linear-gradient(to top, rgba(0, 0, 0, 0.45), rgba(255, 255, 255, 0.06) 60%); }
.etg__tile--paper { color: var(--etg-ink); background: #fff; box-shadow: inset 0 0 0 1px #ece6d8; }
.etg__lockup { position: absolute; z-index: 1; left: 50%; top: 44%; transform: translate(-50%, -50%); display: flex; align-items: center; gap: 0.9rem; color: var(--etg-ink); font: 600 clamp(1.1rem, 2.6vw, 2.25rem)/1 ui-sans-serif, system-ui, sans-serif; letter-spacing: 0.06em; white-space: nowrap; }
.etg__lockup b { display: grid; place-items: center; width: 1.6em; height: 1.6em; border: 3px solid var(--etg-ink); border-radius: 38%; font-size: 1em; }
.etg__tile--ink { background: #000; }
.etg__word { position: absolute; z-index: 1; inset: 0; display: grid; place-items: center; padding-bottom: 6%; font-size: clamp(4rem, 13vw, 11rem); font-weight: 500; letter-spacing: -0.05em; line-height: 1; }
.etg__tile--sun { background: #f9b13a; color: var(--etg-ink); }
.etg__list { position: absolute; inset: 14% 1.5rem 0 2.75rem; display: flex; flex-direction: column; font: 400 clamp(1.1rem, 2.1vw, 1.9rem)/1.55 ui-serif, Georgia, serif; -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 92%); mask-image: linear-gradient(to bottom, #000 62%, transparent 92%); }
.etg__list span { opacity: 0; transform: translateY(0.4em); animation: etg-in 0.4s ease-out forwards; }
.etg__list span:nth-child(2) { animation-delay: 0.08s; }
.etg__list span:nth-child(3) { animation-delay: 0.16s; }
.etg__list span:nth-child(4) { animation-delay: 0.24s; }
.etg__list span:nth-child(5) { animation-delay: 0.32s; }
.etg__list span:nth-child(6) { animation-delay: 0.4s; }
@keyframes etg-in { to { opacity: 1; transform: none; } }
.etg__tile--green { background: #007354; }
.etg__tile--blue { background: #2189c7; }
.etg__doodle { position: absolute; z-index: 1; left: 50%; top: 8%; width: 56%; height: 70%; transform: translateX(-50%); fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.4s ease; }
.etg__tile:hover .etg__doodle { transform: translateX(-50%) rotate(-3deg) scale(1.03); }
@media (prefers-reduced-motion: reduce) {
.etg__list span { animation: none; opacity: 1; transform: none; }
.etg__doodle, .etg__tile::after { transition: none; }
.etg__tile:hover .etg__doodle { transform: translateX(-50%); }
}
@media (max-width: 640px) {
.etg__grid { grid-template-columns: 1fr; padding: 0; border-inline: 0; }
.etg__tile:nth-child(2) { margin-top: var(--etg-gap); }
.etg__tile:nth-child(2)::before { display: block; }
}
</style>