/* Poetry page: photo grid of published poems, grouped by year. */

.poem-years {
  max-width: 1100px;
  margin: 0;
  padding: 0;
}

.poem-year + .poem-year {
  margin-top: 2.5rem;
}

.poem-year-heading {
  border-bottom: none;
  margin-bottom: 1rem;
}

.poem-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2rem 1.75rem;
}

@media (max-width: 767px) {
  .poem-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 1rem; }
}

@media (max-width: 420px) {
  .poem-grid { grid-template-columns: minmax(0, 1fr); }
}

.poem-card {
  text-align: center;
}

.poem-card-link,
.poem-card-link:hover {
  color: inherit;
  text-decoration: none;
}

.poem-card-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--bs-secondary-bg, #eee);
  margin-bottom: 0.75rem;
}

.poem-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.poem-card-link:hover .poem-card-image img {
  transform: scale(1.03);
  opacity: 0.9;
}

.poem-card-title {
  font-size: 1.05rem;
  font-weight: 500;
  line-height: 1.3;
}

.poem-card-link:hover .poem-card-title {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.poem-card-meta {
  font-size: 0.875rem;
  color: var(--bs-secondary-color, #6c757d);
  margin-top: 0.2rem;
}

.poem-card-award {
  font-size: 0.8rem;
  font-style: italic;
  color: var(--bs-secondary-color, #6c757d);
  margin-top: 0.15rem;
}

/* Forthcoming list: hidden when no poems in poems.yaml are "Forthcoming". */
.forthcoming-section {
  max-width: 1100px;
  margin: 3rem 0 0;
}

.forthcoming-section:not(:has(.list li)) {
  display: none;
}

.btn-xs {
  padding: 1px 5px;
  font-size: 15px;
}
