CSS Event Card

A compact event row with a tear-off calendar date badge, ready for agendas and listings.

  • event
  • calendar
  • date
  • meetup
  • schedule
  • list
HTML
<article class="event-card">
  <time class="event-date" datetime="2026-11-24">
    <span>Nov</span>
    <strong>24</strong>
  </time>
  <div>
    <h3>Design Systems Meetup</h3>
    <p>6:30 PM · Berlin</p>
  </div>
</article>
CSS
.event-card {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 320px;
  padding: 12px 18px 12px 12px;
  border: 1px solid #e4e4e7;
  border-radius: 16px;
  background: #fff;
  font-family: system-ui, sans-serif;
}

.event-date {
  flex: none;
  display: flex;
  flex-direction: column;
  width: 56px;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 0 0 1px #e4e4e7, 0 4px 10px -6px rgba(0, 0, 0, 0.3);
  line-height: 1;
  text-align: center;
}

.event-date span {
  padding: 5px 0;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.event-date strong {
  padding: 7px 0 9px;
  color: #18181b;
  font-size: 22px;
}

.event-card h3 {
  margin: 0 0 4px;
  color: #18181b;
  font-size: 15px;
  line-height: 1.3;
}

.event-card p {
  margin: 0;
  color: #71717a;
  font-size: 13px;
}

About this CSS Event Card

This CSS Event Card is 53 lines of pure CSS (0.9 KB) with no JavaScript and no dependencies. It uses box shadows and Flexbox. It works in current versions of Chrome, Edge, Safari and Firefox. It works in any stack: plain HTML, React, Vue, Svelte, Astro, WordPress or Webflow.

CSS features used

Customize it

The colors in this snippet. Search and replace them to match your brand:

  • #e4e4e7
  • #fff
  • #ef4444
  • #18181b
  • #71717a

How to use this event card

  1. Copy the HTML and paste it where you want the element to appear.
  2. Copy the CSS into your stylesheet, or inside a <style> tag.
  3. Keep the .event-card class name, or rename it in both places. Then tweak colors, sizes and timing to match your design.
  4. Using React or Next.js? Change class to className in the HTML. The CSS works as is, including in Tailwind projects (put it in your global stylesheet).

Building with an AI tool?

“Copy for AI” copies a short prompt for Cursor, Claude Code, Lovable, Bolt or v0. Your AI tool opens the Markdown version of this snippet and reads the HTML, CSS and setup notes there. If your tool can't open links, with the code instead. More ways to use copy CSS with AI.

Feedback