/* events.css — /events/ directory pages. Loads after global.css and
   style.css; this file only adds what is specific to the events
   listing, filter and detail UI, in the same ink-on-sky vocabulary. An
   event row is a signal with a date where the number would be. */

.events .prose { max-width: none; }
.events .prose > p { max-width: var(--measure); }
.events .filter-bar,
.event-list { max-width: calc(var(--measure) + 8em); }

.events h2 {
  font-size: 1em;
  font-weight: 700;
  color: var(--ink);
  margin: 2.2em 0 0.6em;
}

/* The filter bar: pills, one row that wraps. */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4em;
  margin-top: 1.2em;
}

.pill.filter-pill--active,
.pill.filter-pill--active:hover,
.pill.filter-pill--active:focus-visible {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--sky);
}

/* The count: lighter weight, not lower opacity (opacity on top of the
   muted ink fell under 3:1). */
.filter-pill__count {
  font-weight: 400;
  font-variant-numeric: tabular-nums;
}

/* Listing: month groups, hairline rows, the date in the number column. */
.event-group + .event-group { margin-top: 1.6em; }

/* Specificity beats .prose h3 (style.css), which the month label is. */
.events .event-group__label {
  margin: 0 0 0.3em;
  color: var(--ink-mute);
  font-size: max(var(--font-size-small), 0.8rem);
  font-weight: 700;
}

.event-card {
  display: grid;
  grid-template-columns: 7em minmax(0, 1fr);
  gap: 0.1em 1em;
  padding: 0.7em 0;
  border-top: 1px solid var(--rule);
  color: inherit;
  text-decoration: none;
}

.event-list > .event-card:last-child {
  border-bottom: 1px solid var(--rule);
}

.event-card__date {
  padding-top: 0.2em;
  color: var(--ink-mute);
  font-size: var(--font-size-small);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.event-card .event-card__title {
  margin: 0; /* beats .prose h3's top margin on tag/week/related lists */
  font-size: 1em;
  font-weight: 700;
  line-height: var(--line);
  color: var(--ink);
  letter-spacing: -0.005em;
}
.event-card:hover .event-card__title,
.event-card:focus-visible .event-card__title { text-decoration: underline; }

.event-card__meta,
.event-card__summary {
  font-size: var(--font-size-small);
  max-width: var(--measure);
}
.event-card__meta { color: var(--ink-mute); }
.event-card__summary { margin-top: 0.15em; color: var(--ink-soft); }

/* Price and tag pills: the shared .pill, plus a filled state for "Free". */
.price-pill,
.tag-pill {
  display: inline-block;
  padding: 0.15em 0.6em;
  border: 1px solid var(--rule);
  border-radius: 2em;
  color: var(--ink-mute);
  font-size: max(var(--font-size-small), 0.75rem);
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
}
.price--free { background: var(--ink); border-color: var(--ink); color: var(--sky); }
.price--unknown { border-style: dashed; }
a.tag-pill:hover,
a.tag-pill:focus-visible { color: var(--ink); border-color: var(--ink); }

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3em;
}

/* Event detail page. */
.event-detail-meta {
  margin-top: 0.4em;
  color: var(--ink-mute);
  font-size: var(--font-size-small);
}

.event-detail-facts { margin-top: 1.2em; font-size: var(--font-size-small); }
.event-detail-facts p { margin-top: 0.25em; color: var(--ink-soft); }

.event-detail-summary { margin-top: 1.2em; color: var(--ink); }

.event-detail-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6em 1.2em;
  margin-top: 1.2em;
}
.event-detail-actions a:not(.btn) { font-size: var(--font-size-small); }

/* Phones: one column, and room to breathe between rows and inside them. */
@media (max-width: 640px) {
  .event-card {
    grid-template-columns: 1fr;
    gap: 0.3em;
    padding: 1em 0;
  }
  .event-card__date { padding-top: 0; }
  .event-card__meta { margin-top: 0.25em; }
  .event-card__summary { margin-top: 0.3em; }
}
