/* ==============================================================
   Taxonomy-term card grid
   Responsive: 1 col (mobile) → 2 col (≥640px) → 3 col (≥1024px) → 4 col (≥1280px)
   ============================================================== */

.view-taxonomy-term .view-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  padding: 1rem 0;
  align-items: stretch;
}

@media (min-width: 640px) {
  .view-taxonomy-term .view-content {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1024px) {
  .view-taxonomy-term .view-content {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 1280px) {
  .view-taxonomy-term .view-content {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* The card */
.view-taxonomy-term .view-content > .tax-term.views-row {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 0.8px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
  overflow: hidden;
  transition: transform 0.18s, box-shadow 0.18s;
  font-family: Outfit, "Helvetica Neue", Arial, Helvetica, sans-serif;
  color: oklch(0.502 0.038 189);
  padding: 0;
  margin: 0;
  width: 100%;
  min-width: 0;
}

.view-taxonomy-term .view-content > .tax-term.views-row:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.10);
}

/* Hide empty views-fields */
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:not(:has(img)):not(:has(a)):not(:has(.field-content > *)) {
  display: none;
}
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:not(:has(img)):has(> .field-content:empty) {
  display: none;
}

/* Order: hero image first, everything else after */
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field {
  order: 2;
}
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field-field-cf-hero-image,
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field-field-hero-image,
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field-field-event-hero-image {
  order: 1;
}

/* Hero image: flush top, 16:9 ratio */
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-cf-hero-image,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-hero-image,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-event-hero-image {
  margin: 0;
  padding: 0;
  line-height: 0;
}
.view-taxonomy-term .view-content > .tax-term.views-row img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  object-fit: cover;
  border-radius: 0;
  margin: 0;
}

/* Body: horizontal padding around non-image fields */
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:not(.views-field-field-cf-hero-image):not(.views-field-field-hero-image):not(.views-field-field-event-hero-image) {
  padding: 0 16px;
  margin: 0;
}

/* Vertical breathing room */
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:not(.views-field-field-cf-hero-image):not(.views-field-field-hero-image):not(.views-field-field-event-hero-image):first-of-type {
  margin-top: 20px;
}
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:last-child {
  margin-bottom: 20px;
}

/* Gap between stacked text fields */
.view-taxonomy-term .view-content > .tax-term.views-row > .views-field:not(.views-field-field-cf-hero-image):not(.views-field-field-hero-image):not(.views-field-field-event-hero-image) + .views-field:not(.views-field-field-cf-hero-image):not(.views-field-field-hero-image):not(.views-field-field-event-hero-image) {
  margin-top: 8px;
}

/* Title fields — bold, teal */
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-name,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-title,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-cf-subtitle,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-job-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  color: oklch(0.502 0.038 189);
}

/* Body / summary / intro text */
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-field-intro-text,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-body,
.view-taxonomy-term .view-content > .tax-term.views-row .views-field-description {
  font-size: 13.5px;
  line-height: 1.45;
  color: #555;
  font-weight: 400;
}

/* Links */
.view-taxonomy-term .view-content > .tax-term.views-row a {
  color: inherit;
  text-decoration: none;
}
.view-taxonomy-term .view-content > .tax-term.views-row a:hover {
  text-decoration: underline;
}