.team-page {
    --team-navy: #003c64;
    --team-blue: #1476b8;
    --team-cyan: #24a9df;
    --team-ink: #17324a;
    --team-muted: #66798a;
    --team-line: rgba(0, 60, 100, .28);
    --team-surface: rgba(255, 255, 255, .96);
    max-width: 1320px;
    margin: 0 auto;
    padding: 72px 24px 96px;
    color: var(--team-ink);
}

.team-profile-modal {
    --team-navy: #003c64;
    --team-blue: #1476b8;
    --team-cyan: #24a9df;
    --team-ink: #17324a;
    --team-muted: #66798a;
}

.team-page,
.team-page *,
.team-page *::before,
.team-page *::after {
    box-sizing: border-box;
}

.team-hero {
    max-width: 820px;
    margin: 0 auto 64px;
}

.team-eyebrow,
.team-profile__eyebrow {
    color: var(--team-blue);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .2em;
}

.team-hero h1 {
    margin: 12px 0 16px;
    color: var(--team-navy);
    font-size: clamp(2rem, 4vw, 3.35rem);
    line-height: 1.08;
}

.team-hero > p {
    margin: 0 auto;
    color: var(--team-muted);
    font-size: 1.05rem;
}

.team-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 28px;
    width: fit-content;
    max-width: 100%;
    margin: 36px auto 0;
    padding: 14px 22px;
    color: var(--team-muted);
    background: rgba(255, 255, 255, .9);
    border: 1px solid rgba(0, 60, 100, .16);
    border-radius: 14px;
    font-size: .82rem;
    box-shadow: 0 10px 28px rgba(0, 43, 75, .07);
}

.team-legend span {
    display: inline-flex;
    align-items: center;
    gap: 9px;
}

.team-legend__line {
    display: inline-block;
    width: 34px;
    border-top: 2px solid var(--team-blue);
}

.team-legend__line--external {
    border-top-style: dashed;
}

.team-org {
    position: relative;
}

.team-org__connections {
    position: absolute;
    z-index: 0;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    pointer-events: none;
}

.team-org__connections path {
    fill: none;
    stroke: var(--team-line);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

.team-org__connections .team-org__connection--primary {
    stroke: var(--team-blue);
}

.team-org__connections .team-org__connection--external {
    stroke: var(--team-blue);
    stroke-dasharray: 7 7;
}

.team-org.has-dynamic-connections > :not(.team-org__connections) {
    position: relative;
    z-index: 1;
}

.team-org.has-dynamic-connections .team-org__leader::after,
.team-org.has-dynamic-connections .team-org__executives::before,
.team-org.has-dynamic-connections .team-org__executive::before,
.team-org.has-dynamic-connections .team-org__departments::before,
.team-org.has-dynamic-connections .team-org__departments::after,
.team-org.has-dynamic-connections .team-group::before,
.team-org.has-dynamic-connections .team-org__executive::after,
.team-org.has-dynamic-connections .team-collaborators__connector {
    display: none !important;
}

.team-org__leader {
    position: relative;
    display: flex;
    justify-content: center;
    padding-bottom: 72px;
}

.team-org__leader::after {
    position: absolute;
    bottom: -1px;
    left: 50%;
    width: 2px;
    height: 73px;
    content: "";
    background: linear-gradient(var(--team-blue), var(--team-line));
    transform: translateX(-50%) scaleY(1);
    transform-origin: top;
    animation: team-line-grow .8s ease both;
}

.team-org__executives {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(32px, 8vw, 120px);
    max-width: 980px;
    margin: 0 auto;
    padding-top: 38px;
}

.team-org__executives::before {
    position: absolute;
    top: 0;
    right: 25%;
    left: 25%;
    height: 2px;
    content: "";
    background: var(--team-line);
}

.team-org__executive {
    position: relative;
    display: flex;
    justify-content: center;
}

.team-org__executive::before {
    position: absolute;
    top: -39px;
    left: 50%;
    width: 2px;
    height: 40px;
    content: "";
    background: var(--team-line);
}

@keyframes team-line-grow {
    from { transform: translateX(-50%) scaleY(0); }
    to { transform: translateX(-50%) scaleY(1); }
}

.team-person-card,
.team-member {
    appearance: none;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.team-person-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 22px;
    width: 100%;
    max-width: 430px;
    padding: 22px;
    overflow: hidden;
    color: var(--team-ink);
    background: var(--team-surface);
    border: 1px solid rgba(0, 60, 100, .12);
    border-radius: 24px;
    box-shadow: 0 18px 46px rgba(0, 43, 75, .1);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.team-person-card::before {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 5px;
    content: "";
    background: linear-gradient(var(--team-cyan), var(--team-blue));
}

.team-person-card:hover,
.team-person-card:focus-visible {
    color: var(--team-ink);
    border-color: rgba(20, 118, 184, .42);
    outline: 0;
    box-shadow: 0 24px 54px rgba(0, 43, 75, .16), 0 0 0 4px rgba(36, 169, 223, .12);
    transform: translateY(-5px);
}

.team-person-card--director {
    max-width: 520px;
    padding: 28px;
    color: #fff;
    background: linear-gradient(135deg, #002e50, var(--team-navy) 62%, #075e8f);
    border-color: rgba(255, 255, 255, .22);
    box-shadow: 0 26px 60px rgba(0, 43, 75, .28);
}

.team-person-card--director:hover,
.team-person-card--director:focus-visible {
    color: #fff;
    border-color: rgba(255, 255, 255, .4);
}

.team-person-card__photo {
    flex: 0 0 auto;
    padding: 4px;
    background: linear-gradient(145deg, var(--team-cyan), #fff);
    border-radius: 50%;
}

.team-person-card__photo img,
.team-member img,
.team-profile__header img {
    display: block;
    object-fit: cover;
    border-radius: 50%;
    transition: transform .35s ease;
}

.team-person-card:hover img,
.team-person-card:focus-visible img,
.team-member:hover img,
.team-member:focus-visible img {
    transform: scale(1.045);
}

.team-person-card__content {
    display: flex;
    min-width: 0;
    flex-direction: column;
    align-items: flex-start;
}

.team-person-card__name {
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 1.25;
}

.team-person-card--director .team-person-card__name {
    font-size: clamp(1.35rem, 2vw, 1.75rem);
}

.team-person-card__function {
    margin-top: 5px;
    color: var(--team-muted);
    font-size: .9rem;
    line-height: 1.45;
}

.team-person-card--director .team-person-card__function,
.team-person-card--director .team-person-card__action {
    color: rgba(255, 255, 255, .8);
}

.team-person-card__action {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 13px;
    color: var(--team-blue);
    font-size: .78rem;
    font-weight: 700;
}

.team-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 9px;
    padding: 5px 9px;
    color: #07547e;
    background: #e5f5fc;
    border: 1px solid rgba(36, 169, 223, .25);
    border-radius: 999px;
    font-size: .68rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: .03em;
}

.team-badge--direction,
.team-badge--interne {
    color: #fff;
    background: var(--team-blue);
}

.team-profile-modal .team-badge--direction {
    color: #07547e;
    background: #e5f5fc;
    border-color: rgba(36, 169, 223, .25);
}

.team-badge--externe {
    color: #805710;
    background: #fff6df;
    border-color: #e8c56f;
}

.team-badge--jury,
.team-badge--formateur {
    color: #335a7c;
    background: #eef4f8;
}

.team-org__departments {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
    max-width: 980px;
    margin: 72px auto 0;
}

.team-org__departments::before {
    position: absolute;
    top: -73px;
    left: 0;
    width: 100%;
    height: 38px;
    content: "";
    background:
        linear-gradient(var(--team-line), var(--team-line)) 25% 0 / 2px 38px no-repeat,
        linear-gradient(var(--team-line), var(--team-line)) 75% 0 / 2px 38px no-repeat;
}

.team-org__departments::after {
    position: absolute;
    top: -36px;
    right: 25%;
    left: 25%;
    height: 2px;
    content: "";
    background: var(--team-line);
}

.team-group,
.team-collaborators {
    overflow: visible;
    background: rgba(255, 255, 255, .9);
    border: 1px solid rgba(0, 60, 100, .11);
    border-radius: 22px;
    box-shadow: 0 14px 38px rgba(0, 43, 75, .08);
}

.team-group {
    position: relative;
}

.team-group::before {
    position: absolute;
    top: -37px;
    left: 50%;
    width: 2px;
    height: 38px;
    content: "";
    background: var(--team-line);
}

.team-group__summary {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    min-height: 112px;
    padding: 22px 24px;
}

.team-group__summary h2 {
    margin: 0;
    color: var(--team-navy);
    font-size: 1.15rem;
}

.team-group__summary p {
    margin: 4px 0 0;
    color: var(--team-muted);
    font-size: .82rem;
}

.team-group__icon {
    display: grid;
    width: 52px;
    height: 52px;
    color: #fff;
    background: linear-gradient(135deg, var(--team-blue), var(--team-cyan));
    border-radius: 15px;
    place-items: center;
    box-shadow: 0 9px 20px rgba(20, 118, 184, .24);
}

.team-group__icon i {
    font-size: 1.55rem;
}

.team-group__icon--external {
    color: var(--team-navy);
    background: #edf4f8;
    box-shadow: none;
}

.team-group__toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 10px 15px;
    color: var(--team-navy);
    background: transparent;
    border: 1px solid rgba(0, 60, 100, .22);
    border-radius: 999px;
    font-size: .76rem;
    font-weight: 800;
    transition: color .2s ease, background .2s ease, box-shadow .2s ease;
}

.team-group__toggle:hover,
.team-group__toggle:focus-visible {
    color: #fff;
    background: var(--team-navy);
    outline: 0;
    box-shadow: 0 0 0 4px rgba(36, 169, 223, .14);
}

.team-group__toggle i {
    font-size: 1.1rem;
    transition: transform .25s ease;
}

.team-group__toggle:not(.collapsed) i {
    transform: rotate(180deg);
}

.team-group__toggle-close,
.team-group__toggle:not(.collapsed) .team-group__toggle-open {
    display: none;
}

.team-group__toggle:not(.collapsed) .team-group__toggle-close {
    display: inline;
}

.team-group__members {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 0 20px 22px;
}

.team-member {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 13px;
    min-width: 0;
    padding: 14px;
    color: var(--team-ink);
    background: #f7fafc;
    border: 1px solid transparent;
    border-radius: 16px;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.team-member:hover,
.team-member:focus-visible {
    color: var(--team-ink);
    background: #fff;
    border-color: rgba(36, 169, 223, .42);
    outline: 0;
    transform: translateY(-2px);
}

.team-member--external {
    border-left: 3px solid #d5a53b;
}

.team-member--internal {
    border-left: 3px solid var(--team-cyan);
}

.team-member__body {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.team-member__body strong {
    overflow: hidden;
    font-size: .9rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.team-member__body small {
    display: block;
    max-width: 100%;
    color: var(--team-muted);
    font-size: .72rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.team-member__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.team-member__badges .team-badge {
    margin-top: 6px;
}

.team-member__more {
    color: var(--team-blue);
    font-size: 1.15rem;
}

.team-collaborators {
    position: relative;
    max-width: 960px;
    margin: 94px auto 0;
    border-style: dashed;
}

.team-collaborators__connector {
    position: absolute;
    top: -95px;
    left: 50%;
    height: 96px;
    border-left: 2px dashed var(--team-line);
}

.team-collaborators__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    padding: 0 22px 24px;
}

.team-collaborator {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 58px;
    padding: 12px 14px;
    color: var(--team-ink);
    background: #f5f8fa;
    border-radius: 13px;
    font-size: .82rem;
    font-weight: 700;
}

.team-collaborator img {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    object-fit: cover;
    background: #fff;
    border: 2px solid rgba(20, 118, 184, .3);
    border-radius: 50%;
}

.team-empty {
    grid-column: 1 / -1;
    margin: 0;
    padding: 18px;
    color: var(--team-muted);
    text-align: center;
}

.team-profile-modal .modal-dialog {
    max-width: 780px;
}

.team-profile-modal .modal-content {
    overflow: hidden;
    color: var(--team-ink);
    background: #f8fbfd;
    border: 0;
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(0, 35, 62, .3);
}

.team-profile-modal .modal-header {
    position: absolute;
    top: 13px;
    right: 13px;
    z-index: 3;
    padding: 0;
    border: 0;
}

.team-profile-modal .btn-close {
    padding: 10px;
    background-color: rgba(255, 255, 255, .9);
    border-radius: 50%;
    box-shadow: 0 5px 14px rgba(0, 35, 62, .15);
}

.team-profile-modal .modal-body {
    padding: 0;
    color: var(--team-ink);
    background: #f8fbfd;
}

.team-profile-modal .team-profile,
.team-profile-modal .team-profile__section,
.team-profile-modal .team-profile__section p,
.team-profile-modal .team-profile__section li,
.team-profile-modal .team-profile__section td,
.team-profile-modal .team-profile__empty {
    color: var(--team-ink);
}

.team-profile__header {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 26px;
    padding: 36px;
    color: var(--team-ink);
    background: linear-gradient(135deg, #f8fcfe, #e8f4fa);
    border-bottom: 1px solid rgba(20, 118, 184, .16);
}

.team-profile__header img {
    border: 4px solid rgba(20, 118, 184, .28);
    box-shadow: 0 14px 28px rgba(0, 60, 100, .16);
}

.team-profile__header h2 {
    margin: 5px 0 4px;
    color: var(--team-navy);
    font-size: clamp(1.45rem, 3vw, 2rem);
}

.team-profile__eyebrow {
    margin: 0;
    color: var(--team-blue);
}

.team-profile__function {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    max-width: 100%;
    margin: 0;
    color: var(--team-muted);
    overflow-wrap: anywhere;
    text-decoration: none;
    transition: color .2s ease;
}

.team-profile__function:hover,
.team-profile__function:focus-visible {
    color: var(--team-blue);
    text-decoration: underline;
}

.team-profile__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.team-profile__section {
    margin: 26px 30px 0;
    padding: 22px;
    background: #fff;
    border: 1px solid rgba(0, 60, 100, .09);
    border-radius: 17px;
}

.team-profile__section h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px;
    color: var(--team-navy);
    font-size: 1rem;
}

.team-profile__specialties {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.team-profile__specialties span {
    padding: 7px 10px;
    color: #315b78;
    background: #edf5f9;
    border-radius: 999px;
    font-size: .76rem;
}

.team-profile__biography {
    line-height: 1.75;
}

.team-profile__biography > :last-child {
    margin-bottom: 0;
}

.team-profile__empty {
    margin: 28px;
    color: var(--team-muted);
    text-align: center;
}

.team-profile__cv {
    margin: 22px 30px 30px;
    color: #fff !important;
    background-color: #1476b8 !important;
    background-image: none !important;
    border-color: #1476b8 !important;
}

.team-profile__cv:hover,
.team-profile__cv:focus-visible {
    color: #fff !important;
    background-color: #003c64 !important;
    background-image: none !important;
    border-color: #003c64 !important;
}

@media (max-width: 991.98px) {
    .team-page {
        padding: 56px 18px 72px;
    }

    .team-org__executives {
        gap: 26px;
    }

    .team-person-card--executive {
        align-items: flex-start;
        flex-direction: column;
    }

    .team-org__departments {
        gap: 20px;
    }

    .team-group__summary {
        grid-template-columns: auto 1fr;
    }

    .team-group__toggle {
        grid-column: 1 / -1;
        justify-content: center;
    }

    .team-group__members,
    .team-collaborators__grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767.98px) {
    .team-hero {
        margin-bottom: 44px;
    }

    .team-legend {
        align-items: flex-start;
        flex-direction: column;
    }

    .team-org__leader {
        padding-bottom: 46px;
    }

    .team-org__leader::after {
        height: 46px;
    }

    .team-org__executives,
    .team-org__departments {
        display: flex;
        flex-direction: column;
        gap: 18px;
        padding-top: 0;
        margin-top: 0;
    }

    .team-org__executives::before,
    .team-org__executive::before,
    .team-org__departments::before,
    .team-org__departments::after {
        display: none;
    }

    .team-org__executive,
    .team-group {
        position: relative;
        padding-top: 26px;
    }

    .team-org__executive::after,
    .team-group::before {
        position: absolute;
        top: 0;
        left: 50%;
        width: 2px;
        height: 26px;
        content: "";
        background: var(--team-line);
    }

    .team-person-card--director,
    .team-person-card--executive {
        align-items: center;
        flex-direction: row;
        padding: 18px;
        border-radius: 19px;
    }

    .team-person-card--director .team-person-card__photo img {
        width: 94px;
        height: 94px;
    }

    .team-person-card--executive .team-person-card__photo img {
        width: 78px;
        height: 78px;
    }

    .team-org__departments {
        margin-top: 18px;
    }

    .team-group__summary {
        min-height: auto;
        padding: 18px;
    }

    .team-collaborators {
        margin-top: 72px;
    }

    .team-collaborators__connector {
        top: -72px;
        height: 73px;
    }

    .team-profile__header {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 32px 24px 26px;
        text-align: center;
    }

    .team-profile__header img {
        width: 116px;
        height: 116px;
        margin: 0 auto;
    }

    .team-profile__badges {
        justify-content: center;
    }

    .team-profile__section {
        margin: 18px 16px 0;
        padding: 18px;
    }

    .team-profile__cv {
        margin: 18px 16px 24px;
    }
}

@media (max-width: 479.98px) {
    .team-page {
        padding-right: 12px;
        padding-left: 12px;
    }

    .team-person-card--director,
    .team-person-card--executive {
        align-items: center;
        flex-direction: column;
        text-align: center;
    }

    .team-person-card__content {
        align-items: center;
    }

    .team-member {
        grid-template-columns: auto 1fr;
    }

    .team-member__more {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .team-page *,
    .team-page *::before,
    .team-page *::after {
        scroll-behavior: auto !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}
