:root {
  --gap: 16px;
}

body {
  font-family: 'Comfortaa', sans-serif;
  margin: 0;
  background: #f9f9f9;
  padding: 2rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--gap);
}

.card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 50px rgba(0, 0, 0, 0.08);
  cursor: pointer; /* Show pointer on hover */
  transition: box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  border-radius: 5%;
  margin: 12px 0; /* space above and below the image */
}

.card .title {
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  margin: 12px 12px 8px; /* space above and below title */
  font-family: 'Comfortaa', sans-serif;
}

.card .meta {
  color: #666;
  margin: 8px 12px 12px; /* space above and below description */
  font-size: 0.9rem;
  font-family: 'Comfortaa', sans-serif;
  line-height: 1.4;
}

.card:focus-within,
.card:hover {
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}