/* Contact hub — thème vert (réutilise les composants support-hub .sh-*) */

body:has(.ch-hub-page) .container,
body:has(.ch-hub-page) #content,
body:has(.ch-hub-page).has-navbar > .content,
body:has(.ch-hub-page)[data-navbar="side"].minimized #content,
body:has(.ch-hub-page)[data-navbar="side"].has-navbar > .content {
    max-width: none !important;
    width: 100%;
}

.ch-hub-page.sh-hub-page,
.ch-hub-page .sh-hub {
    --sh-accent: #0db103;
    --sh-accent-2: #059669;
    --sh-accent-dark: #047857;
    --sh-accent-soft: #ecfdf5;
    --sh-accent-ring: rgba(13, 177, 3, .2);
    --sh-info: #0f766e;
    --sh-info-bg: #f0fdfa;
    --sh-info-dot: #14b8a6;
}

.ch-hub-page .sh-header {
    background:
        radial-gradient(1200px 300px at 85% -60%, rgba(255, 255, 255, .16), transparent 60%),
        radial-gradient(600px 220px at 10% 140%, rgba(5, 150, 105, .45), transparent 60%),
        linear-gradient(120deg, #064e3b 0%, #047857 45%, #0db103 100%);
}

.ch-hub-page .sh-kpi-total .sh-kpi-icon {
    box-shadow: 0 6px 16px -4px rgba(13, 177, 3, .45);
}

/* Boutons texte dans le bandeau (Support force 38×38 pour icônes) */
.ch-hub-page .sh-header .sh-header-btn {
    width: auto;
    height: auto;
    min-height: 38px;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    gap: 8px;
    display: inline-flex;
    align-items: center;
    color: #fff;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .28);
}

.ch-hub-page .sh-header .sh-header-btn:hover {
    background: rgba(255, 255, 255, .24);
    color: #fff;
}

.ch-hub-page .sh-header .sh-btn:not(.sh-btn-ghost) {
    background: #fff;
    color: var(--sh-accent-dark);
    border-color: #fff;
}

.ch-hub-page .sh-header .sh-btn:not(.sh-btn-ghost):hover {
    background: #ecfdf5;
    color: var(--sh-accent-dark);
}

.ch-hub-page .sh-kpis {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.ch-hub-page .sh-kpi-split .sh-kpi-body {
    min-width: 0;
}

.ch-hub-page .sh-kpi-split-line {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 6px;
    margin-top: 6px;
    font-size: 11px;
    line-height: 1.25;
    color: #64748b;
    font-weight: 500;
}

.ch-hub-page .sh-kpi-split-item {
    white-space: nowrap;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 6px;
    border: 1px solid transparent;
    background: #f8fafc;
    transition: background .15s, border-color .15s, color .15s;
}

.ch-hub-page .sh-kpi-split-item:hover {
    background: #e0f2fe;
    border-color: #bae6fd;
    color: #0369a1;
}

.ch-hub-page .sh-kpi-split-item b {
    color: #0f172a;
    font-weight: 700;
}

.ch-hub-page .sh-kpi-split-item.is-on {
    background: #e0f2fe;
    border-color: #7dd3fc;
    color: #0369a1;
}

.ch-hub-page .sh-kpi-split-item.is-on b {
    color: #0369a1;
}

.ch-hub-page .sh-badge.b-portage {
    color: #0369a1;
    background: #e0f2fe;
}

.ch-hub-page .sh-badge.b-portage::before {
    background: #0ea5e9;
}

.ch-hub-page .sh-badge.b-ic {
    color: #047857;
    background: #ecfdf5;
}

.ch-hub-page .sh-badge.b-ic::before {
    background: #10b981;
}

.ch-hub-page .sh-badge.b-mission {
    color: #1d4ed8;
    background: #eff6ff;
}

.ch-hub-page .sh-badge.b-mission::before {
    background: #3b82f6;
}

.ch-hub-page .sh-badge.b-sortant {
    color: #b91c1c;
    background: #fef2f2;
}

.ch-hub-page .sh-badge.b-sortant::before {
    background: #ef4444;
}

.ch-hub-page .sh-row {
    cursor: default;
}

.ch-hub-page .sh-row:hover,
.ch-hub-page .sh-row:focus {
    background: #f8fafc;
}

.ch-hub-page .sh-row.sh-row-selected,
.ch-hub-page .sh-row.sh-row-selected:hover {
    background: #ecfdf5;
}

.ch-hub-page .sh-row td:first-child {
    box-shadow: none;
}

.ch-hub-page .ch-col-name {
    font-weight: 600;
}

.ch-hub-page .ch-name-link {
    color: var(--sh-accent-dark, #047857);
    text-decoration: none;
    cursor: pointer;
    border-bottom: 1px solid transparent;
}

.ch-hub-page .ch-name-link:hover {
    color: var(--sh-accent, #0db103);
    border-bottom-color: currentColor;
}

.ch-hub-page .ch-muted {
    color: var(--sh-muted);
    font-size: 12px;
}

.ch-hub-page .ch-empty {
    padding: 48px 24px;
    text-align: center;
    color: var(--sh-muted);
}

.ch-hub-page .ch-empty .fas {
    font-size: 28px;
    margin-bottom: 10px;
    opacity: .45;
}

.ch-hub-page .ch-col-actions {
    width: 1%;
    white-space: nowrap;
    text-align: right;
}

.ch-hub-page .ch-propose-btn {
    height: 30px;
    padding: 0 10px;
    font-size: 12px;
    color: #fff;
    background: linear-gradient(135deg, var(--sh-accent), var(--sh-accent-2));
    border-color: transparent;
    box-shadow: 0 4px 12px -4px rgba(13, 177, 3, .45);
}

.ch-hub-page .ch-propose-btn:hover {
    color: #fff;
    background: linear-gradient(135deg, var(--sh-accent-dark), var(--sh-accent));
    border-color: transparent;
}

/* Modals sélection IC / besoins — pills actives */
.ch-ic-sx-dialog .cvt-sx-pill.is-on,
.ch-besoin-sx-dialog .cvt-sx-pill.is-on {
    background: #ecfdf5;
    color: #047857;
    border-color: #a7f3d0;
    box-shadow: 0 0 0 1px rgba(16, 185, 129, .15);
}

.ch-ic-sx-dialog .cvt-sx-icon,
.ch-besoin-sx-dialog .cvt-sx-icon {
    background: #ecfdf5 !important;
    color: #047857 !important;
}

.ch-besoin-sx-dialog .cvt-sx-av {
    border-radius: 10px;
    letter-spacing: -.02em;
}

.ch-besoin-sx-dialog .cvt-sx-pills {
    flex-wrap: wrap;
    max-width: 100%;
    gap: 6px;
}

.ch-besoin-sx-dialog .cvt-sx-pill {
    font-size: 12px;
    white-space: nowrap;
}

@media (max-width: 1200px) {
    .ch-hub-page .sh-kpis {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .ch-hub-page .sh-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
