/* Compact card layout matching the news cards on the home page. */
.mechanical-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid #d8e0e6;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(18, 34, 48, .07);
  isolation: isolate;
}

.mechanical-card::after { content: none; }

.mechanical-card img {
  width: 100%;
  height: 245px;
  flex: 0 0 auto;
  object-fit: cover;
  position: relative;
  z-index: 0;
  filter:none;
  image-rendering: auto;
}

.mechanical-card figcaption,
.mechanical-equipment .mechanical-card figcaption {
  position: relative;
  z-index: 2;
  right: auto;
  bottom: auto;
  left: auto;
  flex: 1;
  padding: 17px 19px 19px;
  color: var(--mg-ink);
  background: #fff;
}

.mechanical-card figcaption strong,
.mechanical-equipment .mechanical-card figcaption strong {
  margin: 0 0 6px;
  font-size: clamp(18px, 1.5vw, 22px);
  line-height: 1.18;
}

.mechanical-card figcaption span {
  color: var(--mg-muted);
  font-size: 13px;
  line-height: 1.45;
}

.mechanical-card--people { aspect-ratio: auto; }
.mechanical-card--people img { height: 325px; }
.mechanical-card:hover img,
.mechanical-card--people:hover img {
  transform: none;
  filter:none;
}

.mechanical-equipment {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: auto;
  gap: 16px;
}

.mechanical-equipment .mechanical-card:nth-child(n) {
  grid-column: span 1;
  grid-row: span 1;
}
.mechanical-equipment .mechanical-card figcaption {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 68px;
  padding: 13px 16px 15px;
  text-align: center;
}

.mechanical-equipment .mechanical-card figcaption strong {
  margin: 0;
  font-size: clamp(15px, 1.15vw, 17px);
  line-height: 1.25;
}

@media (max-width: 960px) {
  .mechanical-card--people img { height: 280px; }
  .mechanical-equipment { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mechanical-equipment .mechanical-card:first-child { grid-column: span 1; }
}

@media (max-width: 700px) {
  .mechanical-people,
  .mechanical-equipment { grid-template-columns: 1fr; }
  .mechanical-card--people img,
  .mechanical-equipment .mechanical-card img { height: 230px; }
  .mechanical-card figcaption,
  .mechanical-equipment .mechanical-card figcaption { padding: 15px 16px 17px; }
  .mechanical-card figcaption span { display: block; }
}
