/* Base wrapper */
.kma-related-posts.kma-related-cards {
    margin: 1.25rem 0;
}

/* Title */
.kma-related-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #0b4f84; /* deep blue */
    font-weight: 700;
}

/* Grid: 3 columns on desktop, responsive */
.kma-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

/* Card */
.kma-related-card {
    background: #f3f8fb; /* light blue/grey */
    border-radius: 14px;
    padding: 1.25rem;
    box-sizing: border-box;
    display: flex;
    align-items: stretch;
    min-height: 210px;
}

/* Inner wrapper to flex layout inside card */
.kma-card-inner {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Top area for image (keeps space but image can be omitted) */
.kma-card-top {
    margin-bottom: 0.75rem;
}

/* If post has featured image, ensure it doesn't overflow */
.kma-card-top img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

/* Placeholder image area (if no thumbnail) */
.kma-related-thumb-placeholder {
    background: transparent;
    min-height: 60px; /* keeps card balanced */
}

/* Category pill */
.kma-cat-pill {
    display: inline-block;
    background: #083b61;
    color: #fff;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    margin-bottom: 0.55rem;
}

/* Title */
.kma-card-title {
    margin: 0 0 0.45rem 0;
    font-size: 1.15rem;
    line-height: 1.2;
}
.kma-card-title a {
    color: #0b69b4;
    text-decoration: none;
    font-weight: 700;
}

/* Meta (date) */
.kma-card-meta {
    color: #37607f;
    font-size: 0.95rem;
    margin-bottom: 0.8rem;
}

/* CTA */
.kma-card-cta {
    margin-top: auto; /* pushes button to bottom */
}
.kma-btn {
    display: inline-block;
    background: #0b69b4;
    color: #fff;
    padding: 8px 14px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 980px) {
    .kma-related-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
    .kma-related-grid { grid-template-columns: 1fr; }
}
