/* =============================================
   CETAF BUDDYPRESS — groups directory card refresh
   Overrides (deltas only) on top of the existing
   .cetaf-buddypress-listing rules in style.css.
   Loads after style.css via cetaf_enqueue_split_css,
   so equal-specificity rules win on source order.
   Goal: turn the bland, grey-gravatar cards into a
   modern branded card with a navy header band and an
   overlapping avatar. Scoped to .cetaf-buddypress-listing.
   ============================================= */

/* Remove the grey top border so the navy band sits flush */
.cetaf-buddypress-listing .list-wrap {
    border-top: none !important;
}

/* ── Header band ── */
.cetaf-buddypress-listing .item-avatar {
    background: linear-gradient(135deg, #003254, #0a4d7a) !important;
    padding: 20px 0 0 !important;            /* full-width band */
    text-align: center !important;
    position: relative !important;
    overflow: visible !important;
}

/* ── Avatar — overlaps the band into the white body ── */
.cetaf-buddypress-listing .item-avatar img {
    width: 72px !important;
    height: 72px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid #ffffff !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18) !important;
    background: #ffffff !important;
    display: block !important;
    margin: 0 auto -28px !important;         /* pull down to overlap */
    position: relative !important;
    z-index: 2 !important;
    transition: border-color 0.25s ease !important;
}

.cetaf-buddypress-listing .item-entry:hover .item-avatar img {
    border-color: #f96c31 !important;
}

/* ── "Private" badge — top-right corner pill on the band ── */
.cetaf-buddypress-listing .item-entry.private .item-avatar::after {
    content: 'Private' !important;
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    margin: 0 !important;
    padding: 3px 9px !important;
    font-size: 0.58rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.07em !important;
    color: #ffffff !important;
    background: rgba(249, 108, 49, 0.95) !important;
    border-radius: 20px !important;
    line-height: 1.4 !important;
    z-index: 3 !important;
    display: inline-block !important;
}

/* ── Body — clear the overlapping avatar ── */
.cetaf-buddypress-listing .item {
    padding: 40px 22px 22px !important;
}

/* ── Meta — slightly stronger members line, muted activity ── */
.cetaf-buddypress-listing .group-details {
    color: #003254 !important;
    font-weight: 600 !important;
    font-size: 0.8rem !important;
}

.cetaf-buddypress-listing .last-activity {
    font-size: 0.72rem !important;
    color: #aab0ba !important;
    margin-bottom: 0 !important;
}

/* ── Description — lighter divider ── */
.cetaf-buddypress-listing .group-desc {
    border-top: 1px solid #eef1f4 !important;
    margin-top: 14px !important;
    padding-top: 14px !important;
}

/* ── Mobile — scale band + avatar down ── */
@media (max-width: 600px) {
    .cetaf-buddypress-listing .item-avatar img {
        width: 64px !important;
        height: 64px !important;
        margin-bottom: -24px !important;
    }

    .cetaf-buddypress-listing .item {
        padding-top: 34px !important;
    }
}
