/* Change feed and per-game timeline.
   Ported from XPA Watch's card grid and .timeline so the history sections on
   both sites are recognisably the same component. */

.changes {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px 8px;
}

.changes-head h2 {
  font-size: 16px;
  margin: 28px 0 4px;
}

.changes-head p {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 14px;
}

.change-feed {
  margin-bottom: 30px;
}

.change-feed h3 {
  font-size: 14px;
  margin: 0 0 12px;
}

.change-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(184px, 1fr));
  gap: 14px;
}

.change-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}

.change-card:hover { border-color: var(--s1); }

.change-art {
  aspect-ratio: 1 / 1;
  width: 100%;
  object-fit: cover;
  background: var(--grid);
  display: block;
}

.change-art.is-empty { background: var(--grid); }

.change-body { padding: 10px 11px 12px; }

.change-name {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.change-pub {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.change-pills {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.pill {
  font-size: 10px;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  color: var(--ink2);
  white-space: nowrap;
}

.pill.is-in { border-color: var(--good); color: var(--good); }
.pill.is-back { border-color: var(--s1); color: var(--s1); }
.pill.is-out { border-color: var(--crit); color: var(--crit); }
.pill.is-soon { border-color: var(--warn); color: var(--warn); }

/* Boxed, the way XPA Watch boxes "Tracked at": this is our observation, not
   something the store published, and it should not read as catalog metadata. */
.change-seen {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 7px;
  font-size: 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--page);
  color: var(--ink2);
  font-variant-numeric: tabular-nums;
}

/* The date attached to a warning - "Leaves 2026-09-01". A store fact, so it is
   a plain line, unlike the boxed "Seen" stamp which is our own observation. */
.change-note {
  font-size: 11px;
  color: var(--ink2);
  margin-top: 6px;
}

.change-empty {
  color: var(--muted);
  font-size: 13px;
  padding: 26px 8px;
  text-align: center;
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
}

/* ---------- per-game timeline ---------- */

.detail-section-sub {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 14px;
}

.timeline {
  border-left: 2px solid var(--border);
  margin-left: 6px;
  padding-left: 20px;
}

.timeline-row {
  position: relative;
  padding-bottom: 20px;
}

.timeline-row:last-child { padding-bottom: 0; }

.timeline-row::before {
  content: "";
  position: absolute;
  left: -27px;
  top: 5px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--s1);
  border: 2px solid var(--surface);
}

.timeline-row.is-in::before { background: var(--good); }
.timeline-row.is-out::before { background: var(--crit); }
/* Announced, not yet arrived - a warning colour rather than an outcome. */
.timeline-row.is-soon::before { background: var(--warn); }
/* Hollow marker for reconstructed rows — visibly a weaker claim than a sighting. */
.timeline-row.is-backfill::before {
  background: var(--page);
  border-color: var(--axis);
}

.timeline-when {
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
}

.timeline-what {
  font-size: 14px;
  margin-top: 2px;
}

.timeline-note {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}

@media (max-width: 640px) {
  .changes { padding: 0 16px 8px; }
  .change-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}
