Card

Cards are used to display project previews and content in a structured layout.

Example

Project Role

Project Title

Code
<div class="demo-card">
  <div class="card-image">
    <img src="your-image.jpg" alt="Project preview" />
  </div>
  <div class="card-body">
    <div class="card-body-left">
      <p class="card-role">Project Role</p>
      <p class="card-title">Project Title</p>
    </div>
    <div class="card-body-right">
      <svg class="card-arrow" ...>...</svg>
    </div>
  </div>
</div>

/* CSS */
.demo-card {
  width: 280px;
  border: 1px solid #ddd;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.demo-card .card-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.demo-card .card-body {
  background-color: transparent;
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #eee;
}

.demo-card .card-role {
  font-family: 'Poppins', sans-serif;
  font-size: 0.75rem;
  font-weight: 300;
  color: #000000;
}

.demo-card .card-title {
  font-family: 'Libre Baskerville', serif;
  font-size: 0.95rem;
  font-weight: 400;
  font-style: italic;
  color: #000000;
}

.demo-card .card-arrow {
  width: 20px;
  height: 20px;
}
      
Usage

Cards are used to display project previews on the homepage and portfolio pages.

Each card contains an image area on top and a label area on the bottom.

Cards should maintain consistent sizing across the layout.

Accessibility Considerations

All card images should include descriptive alt text for screen readers. The card body uses high contrast black text on a white background for readability.