.grid.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 300px));
  gap: 1rem;
  margin: 0 auto;
}

.grid.cards > ul {
  display: contents;
}

.grid.cards > ul > li {
  list-style-type: none;
}

.grid.cards > ul > li > a {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 5px;
  padding: 1rem;
  transition: box-shadow 0.3s ease-in-out, transform 0.3s ease-in-out;
  background-color: var(--md-default-bg-color);
  height: 300px;
  width: 100%;
  box-sizing: border-box;
}

.grid.cards > ul > li > a:hover {
  box-shadow: 0 4px 8px var(--md-default-fg-color--lightest);
  transform: translateY(-2px);
}

.grid.cards > ul > li img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  margin-bottom: 0.5rem;
}

.grid.cards > ul > li strong {
  display: block;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 600px) {
  .grid.cards {
    grid-template-columns: 1fr;
  }

  .grid.cards > ul > li > a {
    height: auto;
  }
}

.doc-contents .field-body p {
  margin: 0;
}

.doc-contents .field-list p {
  margin: 0;
}
