/* In Loving Memory (/memory/). Calm on purpose: cream page, quiet cards, no motion.
   Builds on styles.css tokens; the "Share a memory" form uses css/volunteer.css. */

.page-memory main {
  padding: 2rem 0 3rem;
}

.page-memory h1 {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: clamp(2.125rem, 6vw, 2.875rem);
  line-height: 1.15;
  color: var(--heritage-green);
  margin: 0 0 0.75rem;
}

.page-memory main h2 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: clamp(1.5rem, 5vw, 1.875rem);
  line-height: 1.2;
  color: var(--heritage-green);
  margin: 0 0 0.5rem;
}

.lede {
  font-size: 1.3rem;
  margin: 0 0 1.5rem;
}

.cards-wrap {
  max-width: 70rem;
  margin: 2.5rem auto 0;
  padding: 0 var(--gutter);
}

.memory-status {
  min-height: 12rem;  /* room for the first row of cards while the names load */
  margin: 0;
}

.memory-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  gap: 1.25rem;
  align-items: start;
}

.memory-cards li {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0 0 1.1rem;
  text-align: center;
}

.memory-cards .photo {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: var(--line);
  margin-bottom: 0.8rem;
}

.memory-cards li:not([data-id]) .name,
.memory-cards li:not(:has(.photo)) .name {
  padding-top: 1.1rem;
}

.memory-cards .name,
.memory-cards .aka,
.memory-cards .quote {
  padding: 0 0.9rem;
}

.memory-cards .name {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.35rem;
  line-height: 1.25;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.memory-cards .aka {
  font-size: 1.125rem; /* 18px */
  line-height: 1.35;
  color: var(--muted);
}

.memory-cards .quote {
  margin: 0.5rem 0 0;
  font-style: italic;
  font-size: 1.125rem;
  line-height: 1.45;
  color: var(--ink);
}

@media (max-width: 26rem) {
  .memory-cards { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
  .memory-cards .name { font-size: 1.2rem; }
}

.memory-share {
  margin-top: 3rem;
  padding: 1.5rem 1.25rem 1.75rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.memory-share p {
  margin: 0 0 1.25rem;
}

.memory-note {
  margin: 2rem 0 0;
}

/* Nothing moves on this page, not even the buttons' color fade */
.page-memory .button-primary {
  transition: none;
}

/* The form's memory box gets more room than the volunteer note */
#shMemory {
  min-height: 10rem;
}
