/* For latest updates block */
/* ===== GLOBAL LAYOUT (3 COL GRID) ===== */
.latest-update-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  padding: 20px;
}

@media (min-width: 900px) {
  .latest-update-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
  }
}

/* Column wrapper as flex so button can sit at bottom */
.latest-col {
  display: flex;
}

.news-column,
.events-column,
.trainings-column {
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* ===== COLUMN TITLES ===== */
.column-title {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 20px;
  text-transform: uppercase;
}

/* ===== FEATURED IMAGE (TOP OF EACH COLUMN) ===== */
.featured-image img {
  width: 100%;
  height: 220px; /* adjust if you want taller/shorter */
  object-fit: cover;
  margin-bottom: 15px;
}

/* ===== UNIFIED ITEM CONTAINER (FIXED HEIGHT) ===== */
/* Each item = two vertical parts:
   - top: title + date
   - bottom: excerpt + Lue lisää
*/
.item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 0;
  border-top: 1px solid #e0e0e0;

  height: 90px; /* all rows same height */
  box-sizing: border-box;
}

/* First item in list has no top border */
.item-list .item:first-child {
  border-top: none;
}

/* Remove default link styling */
.item,
.item:visited {
  color: inherit;
  text-decoration: none;
}

/* LEFT = 80% */
.item-left {
  width: 80%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* RIGHT = 20% */
.item-right {
  width: 20%;
  text-align: right;

  display: flex;
  flex-direction: column;
  justify-content: space-between; /* date at top, CTA at bottom */
}

/* External resources: no date, only CTA → push CTA down */
.item--no-date .item-right {
  justify-content: flex-end;
}

/* ===== TITLES ===== */
.item-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ===== EXCERPT (MAX 2 LINES) ===== */
.item-excerpt {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.35em;

  max-height: 2.7em; /* max 2 lines */
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ===== DATE ===== */
.item-date {
  font-size: 13px;
  margin-bottom: 4px;
}

/* ===== CTA ===== */
.item-cta {
  font-size: 13px;
  color: #e84751;
  font-weight: 400;
}

.item:hover .item-cta {
  text-decoration: underline;
}

/* ===== EVENT FILTER (SAME HEIGHT AS ITEM, CENTERED SELECT) ===== */
.filter-block {
  padding: 14px 0;
  border-top: 1px solid #e0e0e0;
  margin-bottom: 0;

  height: 90px; /* same as .item */
  box-sizing: border-box;
  display: flex;
  align-items: center; /* vertically center the select */
}

.filter-select {
  width: 100%;
  padding: 6px 8px;
  border: 1px solid #cccccc;
  background: #ffffff;
  font-size: 14px;
}

/* ===== LOAD MORE BUTTON (BOTTOM ALIGNED) ===== */
.load-more {
  width: 100%;
  background: #e84751;
  color: white;
  padding: 12px 0;
  border: none;
  margin-top: auto; /* push to bottom of flex column */
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
}

/* ===== MOBILE TWEAKS ===== */
@media (max-width: 600px) {
  .latest-update-grid {
    padding: 16px;
    gap: 32px;
  }

  .featured-image img {
    height: 180px;
  }

  .item,
  .filter-block {
    height: 80px;
  }

  .column-title {
    font-size: 22px;
    margin-bottom: 12px;
  }
}