/**
 * Kynd Hub Home — styles
 */

.khh {
    display: flex;
    flex-direction: column;
    gap: 16px;
    font-family: inherit;
    color: #111;
}

.khh-row {
    display: grid;
    gap: 16px;
}
.khh-row.full        { grid-template-columns: 1fr; }
.khh-row.tt          { grid-template-columns: 2fr 1fr; }
.khh-row.tt-rev      { grid-template-columns: 1fr 2fr; }
.khh-row.halves      { grid-template-columns: 1fr 1fr; }
.khh-row.thirds      { grid-template-columns: 1fr 1fr 1fr; }

@media (max-width: 768px) {
    .khh-row.tt,
    .khh-row.tt-rev,
    .khh-row.halves,
    .khh-row.thirds {
        grid-template-columns: 1fr;
    }
}

/* ----- Stack — two cards stacked vertically that share the grid cell's height equally ----- */
.khh-stack {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 16px;
    min-width: 0;
    min-height: 0;
}
.khh-stack > .khh-card {
    min-height: 0;
}

/* ----- Cards ----- */
.khh-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

/* The card head can be either a <div> (non-collapsible) or a <button> (collapsible).
   We override BuddyBoss button defaults aggressively for the collapsible variant. */
.khh-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
button.khh-card-head {
    /* Strip BuddyBoss / browser button defaults. */
    width: 100% !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    color: inherit !important;
    font: inherit !important;
    text-align: left !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    cursor: pointer !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    line-height: 1.4 !important;
    min-height: 32px !important;
    /* Reserve space for the absolutely-positioned chevron in the top-right.
       40px = 32px chevron + 8px gap. */
    padding-right: 40px !important;
    position: relative !important;
}
button.khh-card-head:hover,
button.khh-card-head:focus {
    background: transparent !important;
    color: inherit !important;
    outline: none;
    box-shadow: none !important;
}
button.khh-card-head:focus-visible {
    outline: 2px solid rgba(124, 58, 237, 0.4);
    outline-offset: 2px;
    border-radius: 4px;
}

.khh-title-group {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
    flex: 1 1 auto;
}
.khh-card-title {
    font-size: 16px;
    font-weight: 600;
    color: #111;
    letter-spacing: -0.01em;
}
.khh-card-body {
    min-width: 0;
}

/* ----- Card chevron (collapsible cards) ----- */
/* Absolutely positioned in the top-right of the card head so it never wraps to
   a new line on narrow viewports or when BuddyBoss CSS interferes with flex layout. */
.khh-card-chevron {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    border-radius: 50% !important;
    background: rgba(124, 58, 237, 0.08) !important;
    color: #7c3aed !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0;
    transition: background 0.15s ease, transform 0.25s ease;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    box-shadow: none !important;
}
.khh-card-chevron svg {
    display: block;
    width: 14px;
    height: 14px;
}
button.khh-card-head:hover .khh-card-chevron {
    background: rgba(124, 58, 237, 0.16) !important;
}
.khh-card.collapsed .khh-card-chevron {
    transform: rotate(-90deg);
}

/* ----- Card content (the collapsible region) ----- */
.khh-card-content {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.2s ease, margin-top 0.3s ease;
    /* In the expanded state we let max-height be unconstrained — large enough to
       always fit. We use a high pixel value rather than 'none' because 'none' can't
       be transitioned. */
    max-height: 5000px;
    opacity: 1;
}
.khh-card.collapsed .khh-card-content {
    max-height: 0;
    opacity: 0;
    margin-top: -14px; /* collapse the card's gap to avoid visible empty space */
    pointer-events: none;
}

/* When inside a stack (Groups + Forums column), shrink the card to its head only
   when collapsed so the row doesn't carry empty space. */
.khh-stack > .khh-card.collapsed {
    gap: 0;
}

/* ----- Open All / Close All toolbar ----- */
.khh-collapse-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    padding: 0 4px;
    margin: -4px 0 -8px; /* tighten the spacing — sits between Phoebee row and the next row */
    font-size: 13px;
}
.khh-toolbar-link {
    color: #7c3aed !important;
    text-decoration: none !important;
    font-weight: 500;
    cursor: pointer;
    background: transparent !important;
    border: none !important;
    padding: 4px 2px !important;
}
.khh-toolbar-link:hover {
    text-decoration: underline !important;
}
.khh-toolbar-sep {
    color: rgba(0, 0, 0, 0.3);
    user-select: none;
}

/* ----- Help icon ----- */
/* !important overrides on every property because BuddyBoss profile pages aggressively
   style all <button> elements as teal pill-shaped buttons. Without these, help icons
   render as oversized teal pills instead of tiny gray circles. */
.khh .khh-help-icon,
button.khh-help-icon {
    width: 13px !important;
    height: 13px !important;
    min-width: 13px !important;
    min-height: 13px !important;
    max-width: 13px !important;
    max-height: 13px !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, 0.05) !important;
    border: none !important;
    color: #b0b0b0 !important;
    font-size: 9px !important;
    font-weight: 500 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    line-height: 1 !important;
    padding: 0 !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
    position: relative !important;
    top: -1px !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    box-shadow: none !important;
    text-decoration: none !important;
}
.khh .khh-help-icon:hover,
button.khh-help-icon:hover {
    background: rgba(124, 58, 237, 0.15) !important;
    color: #7c3aed !important;
}

/* ----- Welcome header ----- */
.khh-welcome {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 24px 26px;
}
.khh-welcome-text {
    font-size: 22px;
    font-weight: 600;
    color: #111;
    letter-spacing: -0.01em;
}
.khh-welcome-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 8px;
    flex-wrap: wrap;
}
.khh-welcome-link {
    font-size: 13px;
    color: #7c3aed;
    font-weight: 500;
    text-decoration: none;
}
.khh-welcome-link:hover {
    text-decoration: underline;
}

/* ----- Control Center callout (full-width, branded purple, last block on every home) ----- */
.khh-control-center {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    color: #ffffff;
    border-radius: 12px;
    padding: 28px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    box-shadow: 0 4px 14px rgba(124, 58, 237, 0.18);
}
.khh-cc-text {
    flex: 1;
    min-width: 280px;
}
.khh-cc-title {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 6px;
    color: #ffffff;
    letter-spacing: -0.01em;
}
.khh-cc-body {
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
}
.khh-cc-cta {
    display: inline-flex;
    align-items: center;
    background: #ffffff;
    color: #7c3aed;
    font-weight: 600;
    font-size: 14px;
    padding: 12px 22px;
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.15s ease, transform 0.15s ease;
    flex-shrink: 0;
}
.khh-cc-cta:hover {
    background: #f3eafd;
    color: #6d28d9;
    transform: translateX(2px);
}
@media (max-width: 600px) {
    .khh-control-center {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .khh-cc-cta {
        justify-content: center;
    }
}

/* ----- Buttons ----- */
.khh-cta-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding-top: 4px;
}
.khh-btn-primary,
.khh-btn-secondary {
    font-size: 12px;
    border-radius: 6px;
    padding: 8px 14px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    line-height: 1.2;
}
.khh-btn-primary {
    background: #7c3aed;
    color: #ffffff;
    border: 1px solid #7c3aed;
}
.khh-btn-primary:hover {
    background: #6d28d9;
    border-color: #6d28d9;
    color: #ffffff;
}
.khh-btn-primary::after {
    content: " →";
    opacity: 0.85;
    margin-left: 4px;
}
.khh-btn-secondary {
    background: transparent;
    color: #555;
    border: 1px solid rgba(0, 0, 0, 0.12);
}
.khh-btn-secondary:hover {
    background: #fafafa;
    color: #111;
}
.khh-btn-secondary::after {
    content: " →";
    opacity: 0.6;
    margin-left: 4px;
}
.khh-btn-block {
    width: 100%;
    text-align: left;
    justify-content: space-between;
}
.khh-btn-disabled {
    opacity: 0.4;
    pointer-events: none;
    cursor: not-allowed;
}

/* ----- Empty state ----- */
.khh-empty {
    font-size: 13px;
    color: #888;
    padding: 20px 12px;
    text-align: center;
    background: #fafafa;
    border-radius: 8px;
}

/* ----- Lists (events, orgs, needs, messages) ----- */
.khh-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.khh-org-row,
.khh-event-row {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    padding: 6px;
    border-radius: 8px;
}
.khh-org-row:hover,
.khh-event-row:hover {
    background: #fafafa;
}
.khh-org-thumb img,
.khh-event-thumb img {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
}
.khh-org-text {
    flex: 1;
    min-width: 0;
}
.khh-org-name {
    font-size: 14px;
    font-weight: 500;
    color: #111;
}

/* ----- Needs ----- */
.khh-need-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
}
.khh-need-row:hover {
    background: #fafafa;
}
.khh-need-cat {
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 999px;
    background: #f3eafd;
    color: #7c3aed;
    font-weight: 500;
    flex-shrink: 0;
}
.khh-need-title {
    font-size: 13px;
    color: #333;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ----- Listing rows (Needs, Jobs, Social Impact Catalog — 2-line) ----- */
.khh-listing-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}
.khh-listing-row:hover {
    background: rgba(124, 58, 237, 0.04);
    border-color: rgba(124, 58, 237, 0.18);
}
.khh-listing-row:active {
    transform: translateY(0.5px);
}
.khh-listing-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.khh-listing-top {
    display: flex;
    align-items: center;
    gap: 6px;
}
.khh-listing-chip {
    display: inline-block;
    font-size: 10px;
    font-weight: 500;
    padding: 3px 8px;
    border-radius: 999px;
    background: #eef0f3;
    color: #555;
    line-height: 1.4;
    letter-spacing: 0.02em;
    white-space: nowrap;
}
.khh-listing-title {
    font-size: 14px;
    font-weight: 600;
    color: #111;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-break: break-word;
}
.khh-listing-meta {
    font-size: 12px;
    color: #666;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    line-height: 1.4;
}
.khh-listing-meta > span {
    /* Each meta item; the dot separator span uses .khh-listing-dot for color */
}
.khh-listing-dot {
    color: rgba(0, 0, 0, 0.25);
    user-select: none;
}
.khh-listing-arrow {
    color: #7c3aed;
    font-size: 16px;
    font-weight: 500;
    align-self: center;
    flex-shrink: 0;
    transition: transform 0.15s ease;
}
.khh-listing-row:hover .khh-listing-arrow {
    transform: translateX(2px);
}

/* ----- Corporate pill ----- */
.khh-corp-pill {
    font-size: 9px;
    padding: 2px 7px;
    border-radius: 999px;
    background: #ddf4eb;
    color: #0f6e56;
    font-weight: 500;
    flex-shrink: 0;
}

/* ----- Messages (Consultant inbox) ----- */
.khh-msg-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
}
.khh-msg-row:hover {
    background: #fafafa;
}
.khh-msg-row .khh-avatar,
.khh-msg-row img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
}
.khh-msg-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}
.khh-msg-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
}
.khh-sender {
    font-size: 13px;
    font-weight: 600;
    color: #111;
}
.khh-time {
    font-size: 11px;
    color: #999;
    flex-shrink: 0;
}
.khh-msg-excerpt {
    font-size: 12px;
    color: #666;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.khh-unread-dot {
    width: 8px;
    height: 8px;
    background: #7c3aed;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ----- Tabs (Nonprofit Volunteers block) -----
   Uses divs (not buttons) to avoid theme button styles entirely. */
.khh-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    margin: 0 0 12px;
    padding: 0;
}
.khh-tab {
    display: inline-block;
    font-size: 13px;
    padding: 10px 16px;
    margin: 0 0 -1px 0;
    color: #888;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    user-select: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}
.khh-tab:hover {
    color: #555;
}
.khh-tab.active {
    color: #7c3aed;
    border-bottom-color: #7c3aed;
}
.khh-tab:focus-visible {
    outline: 2px solid #7c3aed;
    outline-offset: -2px;
}
.khh-tab-panels {
    margin-top: 8px;
}
.khh-tab-panel {
    display: none;
}
.khh-tab-panel.active {
    display: block;
}
.khh-volunteer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}
@media (max-width: 600px) {
    .khh-volunteer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
.khh-volunteer-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 14px 10px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    text-align: center;
}
.khh-volunteer-card:hover {
    background: #fafafa;
}
.khh-volunteer-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}
.khh-volunteer-name {
    font-size: 12px;
    font-weight: 500;
    color: #111;
}
.khh-volunteer-loc {
    font-size: 10px;
    color: #999;
}

/* Per-tab CTA row inside tab panels (Volunteers block on Nonprofit Home) */
.khh-tab-panel .khh-panel-cta {
    margin-top: 14px;
    padding-top: 0;
}

/* ----- CTA stack (Kynd Kits) ----- */
.khh-cta-stack {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* ----- No-profile fallback ----- */
.khh-no-profile {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    max-width: 600px;
    margin: 40px auto;
}
.khh-no-profile-title {
    font-size: 22px;
    font-weight: 600;
    color: #111;
    margin: 0 0 12px;
}
.khh-no-profile-text {
    font-size: 14px;
    color: #555;
    margin: 0 0 20px;
    line-height: 1.5;
}

/* ----- Wrappers for embedded plugin output ----- */
.khh-bb-wrap,
.khh-eventon-wrap,
.khh-gamipress {
    /* Constrain plugin output. Specific overrides may be needed once we see real output. */
}

/* ----- EventON wrap — keep events compact inside cards ----- */
.khh-eventon-wrap {
    max-width: 100%;
    overflow: hidden;
}
.khh-eventon-wrap .eventon_events_list,
.khh-eventon-wrap .evo_eventcard,
.khh-eventon-wrap > div {
    max-width: 100% !important;
}
.khh-eventon-wrap .evo_top_secn,
.khh-eventon-wrap .evo_bot_secn {
    margin: 0 !important;
}
/* Hide Events Manager intro (h1 + welcome paragraph) — we already have a Card title. */
.khh-eventon-wrap > h1,
.khh-eventon-wrap h1:first-of-type,
.khh-eventon-wrap > h1 + p,
.khh-eventon-wrap h1:first-of-type + p {
    display: none !important;
}

/* ----- Activity feed (BuddyBoss template-tag rendered) ----- */
.khh-feed-list {
    display: flex;
    flex-direction: column;
}
.khh-feed-item {
    display: flex !important;
    gap: 12px;
    padding: 14px 0 !important;
    border: 0 !important;
    border-bottom: 1px solid #eee !important;
    background: transparent !important;
}
.khh-feed-item:first-child {
    padding-top: 0 !important;
}
.khh-feed-item:last-child {
    border-bottom: 0 !important;
    padding-bottom: 0 !important;
}
.khh-feed-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    flex-shrink: 0;
    display: block;
}
.khh-feed-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.khh-feed-action {
    font-size: 13px;
    color: #333;
    line-height: 1.4;
}
.khh-feed-action a {
    color: #111;
    font-weight: 600;
    text-decoration: none;
}
.khh-feed-action a:hover {
    color: #7c3aed;
}
.khh-feed-content {
    font-size: 13px;
    color: #555;
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.khh-feed-time {
    font-size: 11px;
    color: #999;
}

/* ----- Group / event row avatar wrapper ----- */
.khh-avatar-wrap img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: block;
    flex-shrink: 0;
}
/* ----- Forum icon (Forums block) ----- */
.khh-forum-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f3eafd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

/* ----- GamiPress shortcode wrap — thumbnails + JS applies grid at runtime ----- */
.khh-gamipress-wrap {
    max-width: 100%;
    overflow: hidden;
}
.khh-gamipress-wrap img {
    height: auto !important;
    max-width: 100%;
}
/* When JS finds the achievements' parent, it adds .khh-gp-grid to it. */
.khh-gamipress-wrap .khh-gp-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 16px !important;
}
@media (max-width: 768px) {
    .khh-gamipress-wrap .khh-gp-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}
@media (max-width: 480px) {
    .khh-gamipress-wrap .khh-gp-grid {
        grid-template-columns: 1fr !important;
    }
}
.khh-gamipress-wrap .gamipress-achievement {
    width: auto !important;
    max-width: 100% !important;
    float: none !important;
    margin: 0 !important;
    box-sizing: border-box;
    text-align: center;
}
.khh-gamipress-wrap .gamipress-achievement-image {
    width: auto !important;
    text-align: center !important;
    margin-bottom: 8px !important;
}
.khh-gamipress-wrap .gamipress-achievement-image img,
.khh-gamipress-wrap img.gamipress-achievement-thumbnail {
    width: 80px !important;
    height: 80px !important;
    max-width: 80px !important;
    display: inline-block !important;
}
.khh-gamipress-wrap .gamipress-achievement-description {
    text-align: center;
}
/* Hide the "Load More" button — users click "View all badges" to see more. */
.khh-gamipress-wrap .gamipress-load-more-button,
.khh-gamipress-wrap [class*="load-more"] {
    display: none !important;
}

/* ----- Academy LMS course wrap — let Academy's flex grid do its thing.
   Critical: do NOT apply max-width to descendants — Academy uses
   max-width: 33.3333% on its column divs to make 3-column rows. ----- */
.khh-academy-wrap {
    max-width: 100%;
    overflow: hidden;
}
.khh-academy-wrap img {
    height: auto !important;
    max-width: 100%;
}
/* Hide pagination — users click "Browse all courses" to see more. */
.khh-academy-wrap .academy-courses__pagination,
.khh-academy-wrap [class*="pagination"] {
    display: none !important;
}
/* Force 3-column layout regardless of viewport breakpoint —
   inside our card the LG breakpoint may not trigger. */
.khh-academy-wrap .academy-row {
    display: flex !important;
    flex-wrap: wrap !important;
    margin: 0 -8px !important;
}
.khh-academy-wrap .academy-row > [class*="academy-col"] {
    flex: 0 0 33.3333% !important;
    max-width: 33.3333% !important;
    padding: 0 8px !important;
    margin-bottom: 16px !important;
}
@media (max-width: 768px) {
    .khh-academy-wrap .academy-row > [class*="academy-col"] {
        flex: 0 0 50% !important;
        max-width: 50% !important;
    }
}
@media (max-width: 480px) {
    .khh-academy-wrap .academy-row > [class*="academy-col"] {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }
}
/* Card-style borders on each course card so they look distinct (matches All Courses page). */
.khh-academy-wrap .academy-course {
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.khh-academy-wrap .academy-course:hover {
    border-color: rgba(124, 58, 237, 0.3) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
}
/* Inner padding — image (.academy-course__header) stays edge-to-edge,
   body and footer get 14px padding. */
.khh-academy-wrap .academy-course__body {
    padding: 14px !important;
}
.khh-academy-wrap .academy-course__footer {
    padding: 0 14px 14px !important;
}
