/* Layout grid for latest posts v1 */
.sb-latest-1 .wp-block-post-template {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  gap: clamp(18px, 3vw, 32px);
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Card appearance */
.sb-latest-1 .sb-post-card {
  background: var(--sb-surface);
  border-radius: var(--sb-radius-m, 20px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: 0 18px 40px rgba(8, 10, 22, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.sb-latest-1 .sb-post-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 54px rgba(8, 10, 22, 0.26);
}
.sb-latest-1 .sb-post-card .wp-block-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sb-latest-1 .sb-post-card .wp-block-post-excerpt {
  margin: 0;
  color: var(--sb-muted);
  line-height: 1.55;
}

/* Featured image */
.sb-latest-1 .wp-block-post-featured-image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
}
.sb-latest-1 .wp-block-post-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Emphasise lead story */
.sb-latest-1 .wp-block-post-template > *:first-child {
  grid-column: 1 / span 2;
  grid-row: 1 / span 2;
}
.sb-latest-1 .wp-block-post-template > *:first-child .sb-post-card {
  flex-direction: column;
}
.sb-latest-1 .wp-block-post-template > *:first-child .wp-block-group {
  gap: 14px;
}
.sb-latest-1 .wp-block-post-template > *:first-child .wp-block-post-title {
  font-size: clamp(1.6rem, 2.8vw, 2.2rem);
}

/* Compact supporting stories */
.sb-latest-1 .wp-block-post-template > *:not(:first-child) .wp-block-post-title {
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  margin-bottom: 4px;
}
.sb-latest-1 .wp-block-post-template > *:not(:first-child) .wp-block-post-excerpt {
  display: none;
}

/* Date styling */
.sb-latest-1 .wp-block-post-date {
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sb-muted);
}

/* Responsive tweaks */
@media (max-width: 1024px) {
  .sb-latest-1 .wp-block-post-template {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-latest-1 .wp-block-post-template > *:first-child {
    grid-column: 1 / -1;
    grid-row: auto;
  }
}

@media (max-width: 600px) {
  .sb-latest-1 .wp-block-post-template {
    grid-template-columns: minmax(0, 1fr);
  }
  .sb-latest-1 .sb-post-card {
    box-shadow: 0 10px 24px rgba(8, 10, 22, 0.18);
  }
}
