Snapshot mosaic

A title over a rounded tile grid that alternates one wide tile with two tall ones, each tile a different color world.

Open preview
snippet.html99 lines
<section class="snm">
  <h2 class="snm__title">Snapshots</h2>
  <div class="snm__grid">
    <figure class="snm__tile snm__tile--wide snm__a" aria-label="Phone render on a plinth">
      <span class="snm__plinth"></span>
      <span class="snm__phone snm__phone--lay"><i>09<br>24</i></span>
      <span class="snm__phone snm__phone--back"></span>
    </figure>
    <figure class="snm__tile snm__b" aria-label="Leaning phone">
      <span class="snm__phone snm__phone--lean"><em></em><em></em><em></em></span>
      <span class="snm__floor"></span>
    </figure>
    <figure class="snm__tile snm__c" aria-label="Phone side profiles">
      <span class="snm__side" style="--x:30%;--h:84%"><em></em><em></em></span>
      <span class="snm__side" style="--x:44%;--h:84%"></span>
      <span class="snm__side" style="--x:68%;--h:40%"></span>
      <span class="snm__side" style="--x:80%;--h:40%"></span>
    </figure>
    <figure class="snm__tile snm__tile--wide snm__d" aria-label="Scattered 3D blocks">
      <span style="--l:22%;--t:62%;--w:14%;--r:-8deg"></span>
      <span style="--l:34%;--t:40%;--w:18%;--r:12deg"></span>
      <span style="--l:50%;--t:48%;--w:22%;--r:-4deg"></span>
      <span style="--l:62%;--t:30%;--w:16%;--r:18deg"></span>
      <span style="--l:70%;--t:58%;--w:20%;--r:-14deg"></span>
      <span style="--l:44%;--t:72%;--w:12%;--r:6deg"></span>
      <span style="--l:78%;--t:22%;--w:10%;--r:-6deg"></span>
    </figure>
    <figure class="snm__tile snm__e" aria-label="Shield mark">
      <svg viewBox="0 0 100 120" aria-hidden="true"><path d="M6 6h88v64c0 24-26 40-44 46C32 110 6 94 6 70z" fill="#fff"/><path d="M26 34h16l16 30V34h16v44H58L42 48v30H26z" fill="#2200ff"/><path d="m50 88 4 9h10l-8 6 3 9-9-6-9 6 3-9-8-6h10z" fill="#2200ff"/></svg>
    </figure>
    <figure class="snm__tile snm__f" aria-label="Chat screen on a phone">
      <div class="snm__screen">
        <p class="snm__bubble">Who tops the scoring chart this season?</p>
        <div class="snm__stat"><b>Season stats</b><span>Goals <strong>14</strong></span><span>Assists <strong>9</strong></span></div>
        <p class="snm__bubble snm__bubble--me">Looks like a two-player race, though a late run could change it.</p>
        <span class="snm__ask">Ask anything<i></i></span>
      </div>
    </figure>
  </div>
</section>

<style>
  .snm {
    --snm-bg: #ecebe7;
    --snm-ink: #0a0a0a;
    --snm-gap: 15px;
    box-sizing: border-box;
    padding: clamp(2.5rem, 6vw, 4rem) clamp(1rem, 9.7vw, 140px) 4rem;
    background: var(--snm-bg);
    color: var(--snm-ink);
    font-family: "Avenir Next", "Helvetica Neue", ui-sans-serif, system-ui, sans-serif;
  }
  .snm *, .snm *::before, .snm *::after { box-sizing: border-box; }
  .snm__title { margin: 0 0 1.5rem; font-size: clamp(2rem, 4vw, 3rem); font-weight: 300; letter-spacing: 0.01em; }
  .snm__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--snm-gap); }
  .snm__tile { position: relative; margin: 0; overflow: hidden; border-radius: 20px; aspect-ratio: 573 / 763; isolation: isolate; }
  .snm__tile--wide { grid-column: 1 / -1; aspect-ratio: 1160 / 773; }
  .snm__tile > * { transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
  .snm__tile:hover > * { transform: scale(1.03); }
  .snm__tile:hover > .snm__phone--lean { transform: rotate(-7deg) scale(1.03); }

  .snm__a { background: radial-gradient(120% 90% at 80% 0%, #8c9199 0%, #2a2d31 45%, #111315 100%); }
  .snm__plinth { position: absolute; left: 14%; right: -6%; top: 30%; bottom: -10%; background: linear-gradient(135deg, #3a3d42, #181a1c); transform: skewY(-12deg); }
  .snm__phone { position: absolute; display: block; border-radius: 14px; background: #0c0d0f; border: 3px solid #25272b; box-shadow: 0 30px 50px -20px rgb(0 0 0 / 0.7); }
  .snm__phone--lay { left: 28%; top: 38%; width: 36%; height: 20%; transform: rotate(-28deg); background: linear-gradient(115deg, #7a2bd6, #1ec8a5 80%); }
  .snm__phone--lay i { position: absolute; inset: 0; display: grid; place-items: center; font: 700 2.4rem/0.9 ui-sans-serif, system-ui, sans-serif; font-style: normal; color: #fff; text-align: center; transform: rotate(90deg); }
  .snm__phone--back { left: 62%; top: 34%; width: 32%; height: 24%; transform: rotate(-24deg); background: linear-gradient(135deg, #2e3033, #111); }

  .snm__b { background: linear-gradient(160deg, #2a3036, #14181c 70%); }
  .snm__phone--lean { left: 28%; top: 8%; width: 40%; height: 70%; transform: rotate(-7deg); background: linear-gradient(170deg, #38434b, #1a2026); }
  .snm__phone--lean em { position: absolute; right: -3px; width: 5px; height: 9%; border-radius: 3px; background: #4ce6a0; }
  .snm__phone--lean em:nth-child(1) { top: 22%; } .snm__phone--lean em:nth-child(2) { top: 36%; } .snm__phone--lean em:nth-child(3) { top: 52%; height: 4%; }
  .snm__floor { position: absolute; left: 0; right: 0; bottom: 0; height: 22%; background: linear-gradient(180deg, #20262b, #0d1013); }

  .snm__c { background: #000; }
  .snm__side { position: absolute; left: var(--x); top: 50%; width: 5.5%; height: var(--h); transform: translateY(-50%); border-radius: 8px; background: linear-gradient(90deg, #17181a, #0b0b0c); border: 1px solid #2a2b2e; }
  .snm__side em { position: absolute; left: 0; width: 100%; height: 8%; background: #4ce6a0; border-radius: 4px; }
  .snm__side em:first-child { top: 22%; } .snm__side em:last-child { top: 36%; }

  .snm__d { background: #4b3a9e; background-image: radial-gradient(rgb(255 255 255 / 0.07) 1px, transparent 1.5px); background-size: 4px 4px; }
  .snm__d span { position: absolute; left: var(--l); top: var(--t); width: var(--w); aspect-ratio: 2.4; transform: rotate(var(--r)); background: linear-gradient(135deg, #3de2c4, #1b9e92); box-shadow: 0 14px 18px -8px rgb(20 10 90 / 0.8); animation: snm-drift 6s ease-in-out infinite alternate; }
  .snm__d span:nth-child(even) { animation-delay: -3s; background: linear-gradient(135deg, #98e8cf, #4fb9a5); }

  .snm__e { background: #2200ff; display: grid; place-items: center; }
  .snm__e svg { width: 40%; height: auto; }

  .snm__f { background: #2200ff; display: grid; place-items: center; }
  .snm__screen { display: flex; flex-direction: column; gap: 0.6rem; width: 54%; height: 82%; padding: 1rem 0.8rem; border-radius: 28px; background: #12063a; color: #fff; font-size: 0.6875rem; line-height: 1.35; }
  .snm__bubble { margin: 0; padding: 0.6rem 0.7rem; border-radius: 10px; background: rgb(255 255 255 / 0.1); }
  .snm__bubble--me { background: #2200ff; }
  .snm__stat { display: grid; gap: 0.25rem; padding: 0.6rem 0.7rem; border: 1px solid #3a22ff; border-radius: 10px; background: #0a0220; }
  .snm__stat span { display: flex; justify-content: space-between; }
  .snm__ask { display: flex; align-items: center; justify-content: space-between; margin-top: auto; padding: 0.45rem 0.6rem; border-radius: 99px; background: rgb(255 255 255 / 0.12); color: rgb(255 255 255 / 0.7); }
  .snm__ask i { width: 16px; height: 16px; border-radius: 50%; background: #2200ff; }

  @keyframes snm-drift { to { translate: 0 -10px; } }
  @media (max-width: 560px) { .snm__grid { grid-template-columns: 1fr; } .snm__tile { aspect-ratio: 4 / 5; } .snm__tile--wide { aspect-ratio: 4 / 3; } }
  @media (prefers-reduced-motion: reduce) { .snm__tile > * { transition: none; } .snm__d span { animation: none; } .snm__tile:hover > * { transform: none; } .snm__tile:hover > .snm__phone--lean { transform: rotate(-7deg); } }
</style>

Kind
Section
Category
Gallery
Added
6 Nov 2026
Canvas
Full width
File
snippet.html
Size
99 lines · 7.3 KB
  • light
  • portfolio
  • mosaic
  • case-studies

One file: HTML, a style block and, when needed, a small script. Paste it anywhere. Nothing to install.