/* DP – Équipe et KOL
   Chaîne à 3 niveaux : variable locale → charte → repli. */

.dp-team {
    --dp-team-text: var(--dp-color-text, #3c3c3b);
    --dp-team-text-muted: var(--dp-color-text-muted, #6b7280);
    --dp-team-accent: var(--dp-color-primary, #1a86a2);
    --dp-team-accent-dark: var(--dp-color-primary-dark, #0d5e76);
    --dp-team-accent-soft: var(--dp-color-primary-soft, #eef6f9);
    --dp-team-border: var(--dp-color-border, #e5e7eb);
    --dp-team-card-bg: var(--dp-color-surface, #ffffff);
    --dp-team-card-min: 280px;
    --dp-team-photo-size: 128px;

    font-family: var(--dp-font-base, inherit);
    font-weight: var(--dp-font-base-weight, 400);
    color: var(--dp-team-text);
}

/* ── En-tête ─────────────────────────────────────────────────────── */

.dp-team__header {
    margin-bottom: 36px;
    text-align: center;
}

.dp-team__title {
    margin: 0 0 10px;
    font-family: var(--dp-font-heading, inherit);
    font-weight: var(--dp-font-heading-weight, 700);
    font-size: clamp(26px, 4vw, 40px);
    line-height: 1.2;
    color: var(--dp-team-text);
}

.dp-team__description {
    margin: 0 auto;
    max-width: 68ch;
    font-size: 16px;
    line-height: 1.65;
    color: var(--dp-team-text-muted);
}

/* ── Groupes ─────────────────────────────────────────────────────── */

.dp-team__group + .dp-team__group {
    margin-top: 52px;
}

.dp-team__group-title {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0 0 24px;
    font-family: var(--dp-font-heading, inherit);
    font-weight: var(--dp-font-heading-weight, 700);
    font-size: 13px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--dp-team-accent);
}

.dp-team__group-title::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--dp-team-border);
}

.dp-team__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--dp-team-card-min), 1fr));
    gap: 20px;
    align-items: start;
}

/* ── Carte membre ────────────────────────────────────────────────── */

.dp-team__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 28px 24px 24px;
    text-align: center;
    background: var(--dp-team-card-bg);
    border: 1px solid var(--dp-team-border);
    border-radius: var(--dp-team-card-radius, var(--dp-radius-lg, 20px));
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dp-team__card:hover {
    border-color: var(--dp-team-accent);
    box-shadow: 0 12px 28px rgba(26, 51, 83, 0.1);
}

.dp-team__photo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--dp-team-photo-size);
    height: var(--dp-team-photo-size);
    margin-bottom: 6px;
    overflow: hidden;
    background: var(--dp-team-accent-soft);
}

.dp-team--photo-circle .dp-team__photo  { border-radius: 50%; }
.dp-team--photo-rounded .dp-team__photo { border-radius: var(--dp-radius-lg, 20px); }
.dp-team--photo-square .dp-team__photo  { border-radius: 0; }

.dp-team__photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.dp-team__photo-initials {
    font-family: var(--dp-font-heading, inherit);
    font-size: calc(var(--dp-team-photo-size) / 3);
    font-weight: 700;
    color: var(--dp-team-accent-dark);
}

.dp-team__name {
    margin: 0;
    font-family: var(--dp-font-heading, inherit);
    font-weight: var(--dp-font-heading-weight, 700);
    font-size: 18px;
    line-height: 1.3;
    color: var(--dp-team-text);
}

.dp-team__credentials {
    display: block;
    margin-top: 2px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--dp-team-accent);
}

.dp-team__role {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--dp-team-text-muted);
}

.dp-team__location {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0;
    font-size: 13px;
    color: var(--dp-team-text-muted);
}

.dp-team__short-bio {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--dp-team-text-muted);
}

/* ── Bio dépliable ───────────────────────────────────────────────── */

.dp-team__toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    padding: 0;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    color: var(--dp-team-accent);
    background: none;
    border: 0;
    cursor: pointer;
}

.dp-team__toggle:hover {
    /* background explicite : le thème repeint tout button:hover en aplat foncé. */
    color: var(--dp-team-accent-dark);
    background: transparent;
}

.dp-team__toggle svg {
    transition: transform 0.2s ease;
}

.dp-team__toggle[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

.dp-team__bio {
    margin-top: 12px;
    padding-top: 14px;
    text-align: left;
    font-size: 14px;
    line-height: 1.65;
    color: var(--dp-team-text-muted);
    border-top: 1px solid var(--dp-team-border);
}

.dp-team__bio[hidden] {
    display: none;
}

.dp-team__bio p {
    margin: 0 0 10px;
}

.dp-team__bio p:last-child {
    margin-bottom: 0;
}

/* ── Liens de contact ────────────────────────────────────────────── */

.dp-team__links {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}

.dp-team__links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: var(--dp-team-accent);
    background: var(--dp-team-accent-soft);
    border-radius: 50%;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.dp-team__links a:hover {
    color: #ffffff;
    background: var(--dp-team-accent);
}

@media (max-width: 600px) {
    .dp-team__card {
        padding: 24px 18px 20px;
    }
}

/* ── État de focus ────────────────────────────────────────────────
   Le bouton « Read bio » est un lien déguisé : il ne doit pas hériter de
   l'aplat foncé que le thème applique à tout <button>:focus. */

.dp-team__toggle:focus {
    color: var(--dp-team-accent-dark);
    background: transparent;
    border-color: transparent;
}

.dp-team__toggle:focus-visible {
    outline: 3px solid var(--dp-team-accent);
    outline-offset: 3px;
    border-radius: var(--dp-radius-sm, 10px);
}
