/* Isolated from the old snippets' generic selectors. */
.kdc-category-grid {
    display: grid;
    grid-template-columns: repeat(var(--kdc-columns, 4), minmax(0, 1fr));
    gap: 20px;
    margin-block: 20px;
    width: 100%;
}
.kdc-category-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 160px;
    padding: 24px 18px;
    overflow: hidden;
    border-radius: 8px;
    background: #075536;
    text-decoration: none;
    isolation: isolate;
}
.kdc-category-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .66);
    z-index: -1;
}
.kdc-category-card .kdc-category-image,
.kdc-category-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
}
.kdc-category-placeholder { background: linear-gradient(135deg, #087749, #134b39); }
.kdc-category-card h3 {
    margin: 0;
    color: #fff;
    font-family: inherit;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    text-align: center;
    overflow-wrap: anywhere;
}
.kdc-category-card:hover { box-shadow: 0 5px 18px rgba(0, 0, 0, .18); }
.kdc-category-card:focus-visible,
.kdc-courses-button:focus-visible { outline: 3px solid #d99e26; outline-offset: 4px; }
.kdc-courses-button {
    display: inline-block;
    padding: 14px 24px;
    background: #00723f;
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
}
.kdc-recent-clients {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
    gap: 16px;
    list-style: none;
    padding: 0;
    margin: 28px 0;
}
.kdc-recent-clients li {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 110px;
    padding: 20px;
    border: 1px solid #dce9e2;
    border-radius: 8px;
    color: #075536;
    background: #fff;
    text-align: center;
    font-weight: 600;
    line-height: 1.5;
}
.kdc-client-slide .eael-lc-logo,
.kdc-recent-clients li {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 150px;
}
.kdc-client-slide img.kdc-client-logo,
.kdc-recent-clients img.kdc-client-logo {
    width: 100%;
    max-width: 200px;
    height: 130px;
    object-fit: contain;
}
/* One shared frame for every client, including the original Elementor slides. */
.elementor-element.elementor-element-ccaed1a .eael-logo-carousel-wrap {
    position: relative;
    padding: 0 56px;
    background: #fff;
}
.elementor-element.elementor-element-ccaed1a .eael-logo-carousel {
    width: 100%;
    background: #fff;
}
.elementor-element.elementor-element-ccaed1a .swiper-slide,
.elementor-element.elementor-element-ccaed1a .eael-lc-logo-wrap,
.elementor-element.elementor-element-ccaed1a .eael-lc-logo {
    height: 160px;
    box-sizing: border-box;
    background: #fff;
}
.elementor-element.elementor-element-ccaed1a .eael-lc-logo-wrap {
    width: 100%;
    margin: 0;
    padding: 12px;
}
.elementor-element.elementor-element-ccaed1a .swiper-slide { padding: 0; }
.elementor-element.elementor-element-ccaed1a .eael-lc-logo,
.elementor-element.elementor-element-ccaed1a .eael-lc-logo a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}
.elementor-element.elementor-element-ccaed1a img.eael-lc-img-src {
    display: block;
    width: 200px;
    max-width: 100%;
    height: 120px;
    max-height: 120px;
    margin: 0;
    padding: 0;
    object-fit: contain;
    object-position: center;
    background: #fff;
}
.elementor-element.elementor-element-ccaed1a .swiper-button-prev,
.elementor-element.elementor-element-ccaed1a .swiper-button-next {
    top: 80px !important; /* Override the saved Elementor arrow offset. */
    width: 40px;
    height: 40px;
    margin: 0;
    padding: 10px;
    transform: translateY(-50%);
    border: 1px solid #e1e8e4;
    border-radius: 50%;
    color: #075536;
    background: #fff;
}
.elementor-element.elementor-element-ccaed1a .swiper-button-prev { left: 0; }
.elementor-element.elementor-element-ccaed1a .swiper-button-next { right: 0; }
/* The official CBK bitmap has a near-white matte; blend it into the white frame. */
.elementor-element.elementor-element-ccaed1a img[alt="Central Bank of Kenya"] { filter: contrast(1.12); }
.elementor-element.elementor-element-ccaed1a .swiper-button-prev:hover,
.elementor-element.elementor-element-ccaed1a .swiper-button-next:hover { background: #f1f7f3; }
.elementor-element.elementor-element-ccaed1a .swiper-button-prev:focus-visible,
.elementor-element.elementor-element-ccaed1a .swiper-button-next:focus-visible {
    outline: 2px solid #075536;
    outline-offset: 3px;
}
.elementor-element.elementor-element-ccaed1a .swiper-pagination {
    position: static;
    margin-top: 20px;
    padding: 0;
    line-height: 20px;
}
@media (max-width: 600px) {
    .elementor-element.elementor-element-ccaed1a .eael-logo-carousel-wrap { padding-inline: 46px; }
    .elementor-element.elementor-element-ccaed1a .eael-lc-logo-wrap { padding-inline: 4px; }
}
@media (max-width: 1199px) {
    .kdc-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
    .kdc-category-grid { grid-template-columns: minmax(0, 1fr); }
    .kdc-category-card { min-height: 130px; }
}
