/* TCLAS Groups & Events — orgs map + upcoming-events sidebar
 * Shares split-layout/list/popup chrome with tclas-ancestor-map.css
 * (dependency); this sheet adds the map element and the events sidebar.
 * Self-contained: no dependency on the places-map feature. */

.tclas-orgs-map {
  width: 100%;
  height: 600px;
  background: var(--c-or-pale, #FAF9F6);
  border: 1px solid var(--c-border, #ddd);
  border-radius: var(--radius, 8px);
}

.tclas-orgs-map.leaflet-container {
  font-family: inherit;
  background: var(--c-or-pale, #FAF9F6);
}

@media (max-width: 640px) {
  .tclas-orgs-map {
    height: 340px;
  }
}

/* The shared table styles right-align the last column (a count elsewhere);
 * here it's the location — align left like the rest. */
.tclas-orgs-wrapper .tclas-map-list__table th:last-child,
.tclas-orgs-wrapper .tclas-map-list__table td:last-child {
  text-align: left;
}

/* ── Layout: map/list + self-hiding events sidebar ────────────────────── */

.tclas-groups-layout--has-events {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 1100px) {
  .tclas-groups-layout--has-events {
    grid-template-columns: 1fr;
  }
}
/* With the sidebar present, the map/list split stacks to keep both readable */
.tclas-groups-layout--has-events .tclas-map-split {
  grid-template-columns: 1fr;
}

/* ── Events sidebar ───────────────────────────────────────────────────── */

.tclas-groups-events {
  border: 1px solid var(--c-border, #ddd);
  border-radius: var(--radius, 8px);
  background: var(--c-or-pale, #FAF9F6);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
}
.tclas-groups-events__title {
  margin: 0 0 1rem;
}
.tclas-groups-events__list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.tclas-groups-events__item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--c-border, #ddd);
}
.tclas-groups-events__item:last-child {
  border-bottom: none;
}
.tclas-groups-events__date {
  font-weight: 700;
  color: var(--c-crimson, #8B3A3A);
}
.tclas-groups-events__name {
  font-weight: 600;
  color: var(--c-ardoise, #2B6282);
  text-decoration: none;
}
.tclas-groups-events__name:hover {
  text-decoration: underline;
}
.tclas-groups-events__meta {
  color: var(--c-muted, #626D78);
}
.tclas-groups-events__note {
  margin: 1rem 0 0;
  color: var(--c-muted, #626D78);
}
