/* ══════════════════════════════════════════════════════════════════════
   Sociétaires Catalogue BuddyPress — Frontend CSS
   ══════════════════════════════════════════════════════════════════════ */

/* ── Catalogue wrapper ────────────────────────────────────────────── */
.scbp-catalogue-wrap {
    width: 100%;
}

/* ── Barre de recherche ───────────────────────────────────────────── */
.scbp-search-row {
    margin-bottom: 16px;
}

.scbp-search-input {
    width: 100%;
    max-width: 400px;
    padding: 10px 16px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    outline: none;
    transition: border-color .2s;
}

.scbp-search-input:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 2px rgba(34, 113, 177, .15);
}

/* ── Barre de filtre ──────────────────────────────────────────────── */
.scbp-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.scbp-filter-btn {
    background: #f1f1f1;
    border: 1px solid #ddd;
    border-radius: 30px;
    padding: 6px 18px;
    font-size: 14px;
    cursor: pointer;
    transition: background .2s, color .2s, border-color .2s;
    font-family: inherit;
    line-height: 1.4;
}

.scbp-filter-btn:hover {
    background: #e0e0e0;
}

.scbp-filter-btn.scbp-active {
    background: #2271b1;
    color: #fff;
    border-color: #2271b1;
}

/* ── Grille ───────────────────────────────────────────────────────── */
.scbp-grid {
    display: grid;
    gap: 24px;
}

.scbp-cols-1 { grid-template-columns: 1fr; }
.scbp-cols-2 { grid-template-columns: repeat(2, 1fr); }
.scbp-cols-3 { grid-template-columns: repeat(3, 1fr); }
.scbp-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
    .scbp-cols-4 { grid-template-columns: repeat(2, 1fr); }
    .scbp-cols-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .scbp-cols-1,
    .scbp-cols-2,
    .scbp-cols-3,
    .scbp-cols-4 { grid-template-columns: 1fr; }
}

/* ── Carte ────────────────────────────────────────────────────────── */
.scbp-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    transition: box-shadow .2s, transform .2s;
}

.scbp-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,.12);
    transform: translateY(-2px);
}

/* Image */
.scbp-card-img-link {
    display: block;
    overflow: hidden;
}

.scbp-card-img {
    display: block;
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform .3s;
}

.scbp-card-img-link:hover .scbp-card-img {
    transform: scale(1.04);
}

.scbp-no-img {
    width: 100%;
    height: 200px;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #aaa;
}

.scbp-no-img .dashicons {
    font-size: 56px;
    width: 56px;
    height: 56px;
}

/* Corps */
.scbp-card-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 6px;
}

.scbp-card-title {
    font-size: 1.1em;
    font-weight: 700;
    margin: 0 0 4px;
    line-height: 1.3;
}

.scbp-card-title a {
    color: inherit;
    text-decoration: none;
    transition: color .2s;
}

.scbp-card-title a:hover {
    color: #2271b1;
}

.scbp-card-type {
    font-size: .8em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #2271b1;
    background: rgba(34,113,177,.1);
    display: inline-block;
    padding: 2px 8px;
    border-radius: 20px;
}

.scbp-card-sous-cat {
    font-size: .85em;
    color: #666;
    font-style: italic;
}

.scbp-card-desc {
    font-size: .9em;
    color: #444;
    line-height: 1.55;
    flex: 1;
}

.scbp-card-meta {
    font-size: .85em;
    color: #555;
    display: flex;
    align-items: flex-start;
    gap: 6px;
    text-decoration: none;
}

.scbp-card-meta .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-top: 1px;
    color: #888;
}

.scbp-card-meta a {
    color: inherit;
    text-decoration: none;
    word-break: break-all;
}

.scbp-card-meta a:hover {
    color: #2271b1;
    text-decoration: underline;
}

/* Bouton */
.scbp-card-btn {
    display: inline-block;
    margin-top: auto;
    padding: 9px 20px;
    background: #2271b1;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-size: .9em;
    font-weight: 600;
    text-align: center;
    transition: background .2s, transform .15s;
}

.scbp-card-btn:hover {
    background: #135e96;
    transform: translateY(-1px);
    color: #fff;
}

/* ── Aucun résultat ───────────────────────────────────────────────── */
.scbp-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-size: 1.05em;
}

/* ── Widgets de champ individuel ──────────────────────────────────── */
.scbp-field-wrap {
    display: flex;
    align-items: center;
}

.scbp-field-content {
    width: 100%;
}

/* Description */
.scbp-description p {
    margin-bottom: .8em;
    line-height: 1.65;
}

.scbp-references {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    font-size: .9em;
    color: #555;
}

/* Type de membre */
.scbp-type-membre {
    font-weight: 700;
    text-transform: uppercase;
    font-size: .85em;
    letter-spacing: .06em;
    color: #2271b1;
}

.scbp-sous-categorie {
    font-size: .9em;
    color: #666;
    font-style: italic;
    margin-top: 4px;
}

/* Contact */
.scbp-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.scbp-contact-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: .95em;
}

.scbp-contact-row .dashicons {
    flex-shrink: 0;
    color: #2271b1;
    margin-top: 1px;
}

.scbp-contact-label {
    font-weight: 600;
    white-space: nowrap;
    color: #333;
}

.scbp-contact-value a {
    color: inherit;
    text-decoration: none;
    word-break: break-all;
}

.scbp-contact-value a:hover {
    text-decoration: underline;
    color: #2271b1;
}
