.fore-life-events-grid__header {
  align-items: end;
  display: flex;
  justify-content: space-between;
  margin-bottom: 24px;
}

.fore-life-events-grid__heading {
  margin: 0;
}

.fore-life-events-grid__cards {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.fore-life-events-grid__cards--columns-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fore-life-event-card {
  background: #fff;
  border: 1px solid #dfe3dc;
  border-radius: 8px;
  box-shadow: 0 3px 12px rgba(19, 49, 35, 0.08);
  color: #17221b;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  overflow: hidden;
}

.fore-life-event-card__media {
  aspect-ratio: 16 / 9;
  background: #e8ede7;
  overflow: hidden;
  position: relative;
}

.fore-life-event-card__image {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.fore-life-event-card__date-badge {
  background: #153f2a;
  border: 2px solid #fff;
  border-radius: 7px;
  color: #fff;
  left: 12px;
  line-height: 1;
  min-width: 52px;
  padding: 8px 7px;
  position: absolute;
  text-align: center;
  top: 12px;
}

.fore-life-event-card__month {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.fore-life-event-card__day {
  display: block;
  font-size: 23px;
  font-weight: 800;
  margin-top: 3px;
}

.fore-life-event-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 18px 20px 16px;
}

.fore-life-event-card__title {
  font-size: 20px;
  line-height: 1.2;
  margin: 0 0 10px;
}

.fore-life-event-card__title a {
  color: inherit;
  text-decoration: none;
}

.fore-life-event-card__meta {
  align-items: flex-start;
  color: #526057;
  display: flex;
  font-size: 14px;
  gap: 8px;
  line-height: 1.45;
  margin: 0;
  padding: 0;
}

.fore-life-event-card__icon {
  display: block;
  flex: 0 0 auto;
  fill: none;
  height: 17px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  width: 17px;
}

.fore-life-event-card__excerpt {
  color: #39463e;
  font-size: 15px;
  line-height: 1.45;
  margin: 0;
  padding: 0;
}

.fore-life-event-card__details {
  display: flex;
  flex-direction: column;
  margin-bottom: 16px;
}

.fore-life-events-grid .fore-life-event-card__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}

.fore-life-events-grid .fore-life-event-card__chip {
  background: #eceeeb;
  border-radius: 6px;
  color: #273129;
  font-size: 12px;
  line-height: 1;
  padding: 7px 12px;
}

/* Categories = the event type (lime). Tags = attributes like skill/fee (gray). */
.fore-life-events-grid .fore-life-event-card__chip--category {
  background: #d9ee8e;
}

.fore-life-events-grid .fore-life-event-card__chip--tag {
  background: #eceeeb;
}

/* Back-compat: legacy first-chip accent still styles if present. */
.fore-life-events-grid .fore-life-event-card__chip--primary {
  background: #d9ee8e;
}

.fore-life-events-grid .fore-life-event-card__actions {
  align-items: center;
  border-top: 1px solid #edf0eb;
  display: flex;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
}

.fore-life-events-grid .fore-life-event-card__quick-view,
.fore-life-events-grid .fore-life-event-card__link {
  align-items: center;
  color: #17221b;
  display: inline-flex;
  font-size: 14px;
  font-weight: 700;
  gap: 7px;
  text-decoration: none;
}

.fore-life-events-grid .fore-life-event-card__link {
  color: #174e32;
}

.fore-life-events-grid .fore-life-event-card__quick-view:hover,
.fore-life-events-grid .fore-life-event-card__link:hover {
  opacity: 0.72;
}

.fore-life-events-grid__footer {
  margin-top: 28px;
  text-align: center;
}

.fore-life-events-grid__view-all {
  background: #153f2a;
  border-radius: 999px;
  color: #fff;
  display: inline-block;
  font-size: 15px;
  font-weight: 700;
  padding: 12px 22px;
  text-decoration: none;
}

.fore-life-events-grid__status {
  background: #f3f5ef;
  border-radius: 6px;
  padding: 24px;
  text-align: center;
}

@media (max-width: 980px) {
  .fore-life-events-grid__cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .fore-life-events-grid__cards {
    grid-template-columns: 1fr;
  }

  .fore-life-event-card__actions {
    gap: 16px;
  }
}

/* ---- Results toolbar (count + sort + grid/list view) ---- */
.fore-life-events-grid__toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 0 0 18px; }
.fore-life-events-grid__count { margin: 0; font-size: 18px; font-weight: 800; color: #17221b; }
.fore-life-events-grid__count[hidden] { display: none; }
.fore-life-events-grid__tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.fore-life-events-grid__sort { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: #526057; }
.fore-life-events-grid__sort .fore-life-event-search__select { min-width: 150px; }
.fore-life-events-grid__view { display: inline-flex; border: 1.5px solid #dfe3dc; border-radius: 10px; overflow: hidden; background: #fff; }
.fore-life-events-grid__view-btn { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 40px; padding: 0; background: #fff; border: 0; cursor: pointer; color: #6b7a70; font-size: 16px; line-height: 1; }
.fore-life-events-grid__view-btn + .fore-life-events-grid__view-btn { border-left: 1.5px solid #dfe3dc; }
.fore-life-events-grid__view-btn.is-active { background: #153f2a; color: #fff; }
.fore-life-events-grid__view-icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.fore-life-events-grid__view-icon rect { fill: currentColor; stroke: none; }
.fore-life-events-grid__view-icon circle { fill: currentColor; stroke: none; }

/* ---- List view: cards become horizontal rows ---- */
.fore-life-events-grid__cards.is-list { display: flex; flex-direction: column; }
.fore-life-events-grid__cards.is-list .fore-life-event-card { flex-direction: row; align-items: stretch; }
.fore-life-events-grid__cards.is-list .fore-life-event-card__media { flex: 0 0 36%; max-width: 320px; aspect-ratio: auto; }
.fore-life-events-grid__cards.is-list .fore-life-event-card__body { flex: 1; }
@media (max-width: 640px) {
  .fore-life-events-grid__cards.is-list .fore-life-event-card { flex-direction: column; }
  .fore-life-events-grid__cards.is-list .fore-life-event-card__media { flex-basis: auto; max-width: none; aspect-ratio: 16 / 9; }
}

/* ---- Numbered pagination ---- */
.fore-life-events-grid__pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin-top: 24px; }
.fore-life-events-grid__page {
  display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px;
  padding: 0 10px; font-size: 14px; font-weight: 600; color: #17221b; background: #fff;
  border: 1.5px solid #dfe3dc; border-radius: 9px; cursor: pointer; transition: background .12s ease, border-color .12s ease;
}
.fore-life-events-grid__page:hover { background: #eef2eb; }
.fore-life-events-grid__page.is-active { background: #153f2a; border-color: #153f2a; color: #fff; }
.fore-life-events-grid__page.is-disabled { opacity: .4; cursor: default; }
.fore-life-events-grid__ellipsis { padding: 0 4px; color: #9ca3af; }
