/* ====== STYLE INSPIRE DU MODELE V5.0 ====== */
body {
    margin: 0;
    font-family: 'Roboto', 'Open Sans', Arial, sans-serif;
    background: #f5f8fa;
    color: #2d3a4a;
    min-height: 100vh;
}
.login-bg {
    background: linear-gradient(120deg, #1a355c 0%, #2980b9 100%);
    min-height: 100vh;
}
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(90deg, #1a355c 80%, #2980b9 100%);
    color: #fff;
    padding: 1.2em 2em;
    box-shadow: 0 2px 12px #0002;
    position: sticky;
    top: 0;
    z-index: 100;
}
.nav-title {
    font-size: 1.5em;
    font-weight: bold;
    letter-spacing: 1px;
    color: #fff;
    text-shadow: 0 2px 8px #0002;
}
.nav-link {
    color: #fff;
    text-decoration: none;
    margin-left: 2em;
    font-weight: 500;
    padding: 0.5em 1.2em;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
}
.nav-link:hover {
    background: #eaf6fb44;
    color: #2980b9;
}
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2em 1em 1em 1em;
}
.recap-section {
    margin: 2em 0 1em 0;
    padding: 1.5em 1em;
    background: rgba(255,255,255,0.96);
    border-radius: 18px;
    box-shadow: 0 2px 16px #1a355c22;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.recap-section h3 {
    color: #1a355c;
    margin-bottom: 1.2em;
    font-size: 1.3em;
    letter-spacing: 1px;
}
.recap-cards {
    display: flex;
    gap: 2em;
    justify-content: center;
    margin-bottom: 1.5em;
    flex-wrap: wrap;
}
.recap-card {
    background: linear-gradient(120deg, #fafdff 60%, #eaf6fb 100%);
    border-radius: 12px;
    box-shadow: 0 2px 12px #2980b933;
    padding: 1.5em 2.2em;
    min-width: 180px;
    text-align: center;
    font-size: 1.1em;
    font-weight: 500;
    color: #22324a;
    margin-bottom: 1em;
}
.recap-card strong {
    color: #2980b9;
    font-size: 1.15em;
    margin-bottom: 0.5em;
    display: block;
}
.error-msg {
    color: #d32f2f;
    background: #fff5f5;
    border: 1px solid #d32f2f22;
    padding: 0.7em 1em;
    border-radius: 8px;
    margin-bottom: 1em;
}
.map-toolbar {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.8em;
}
#filters-panel.filter-panel-clean {
    position: absolute !important;
    top: 48px !important;
    right: 0 !important;
    min-width: 320px;
    z-index: 1002;
    display: none;
}
#filters-panel.filter-panel-clean.open {
    display: flex !important;
}
#map-btn-filters {
    background: #2980b9;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.5em 1.2em;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 8px #1a355c22;
    transition: background 0.2s;
    margin-left: 0.5em;
}
#map-btn-filters:hover {
    background: #1760a0;
}
.close-list-btn {
    background: none;
    color: #c0392b;
    border: none;
    font-size: 1.45em;
    cursor: pointer;
    margin-left: 0.7em;
    transition: color 0.2s;
}
.close-list-btn:hover {
    color: #e67e22;
}
#map {
    width: 100%;
    height: 70vh;
    margin: 0;
    border-radius: 18px;
    box-shadow: 0 2px 18px #1a355c22;
}
#overlay-search {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(41,128,185,0.07);
    z-index: 200;
    justify-content: center;
    align-items: center;
}
.recap-charts-container {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 2.5em;
    margin-top: 2em;
    margin-bottom: 2em;
    flex-wrap: wrap;
}
.chart-block {
    background: #fafdff;
    border-radius: 12px;
    padding: 1.1em 1.6em 1.2em 1.6em;
    box-shadow: 0 2px 12px #1a355c22;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 200px;
    margin: 0;
}
.chart-block-clic canvas {
    cursor: pointer !important;
    opacity: 1;
    /* Suppression de l'encadré bleu au hover */
    box-shadow: none !important;
    transition: none !important;
}
.chart-block-clic canvas:hover {
    box-shadow: none !important;
}
@media (max-width: 900px) {
    .recap-charts-container {
        flex-direction: column;
        align-items: center;
        gap: 1.2em;
    }
}
.centered-chart-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 50vh;
    width: 100vw;
}
.client-list-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px #1a355c33;
    padding: 2em 2em 1.5em 2em;
    z-index: 1000;
    min-width: 320px;
    max-width: 90vw;
    min-height: 200px;
    max-height: 70vh;
    overflow-y: auto;
}
.client-list-title {
    font-size: 1.1em;
    font-weight: bold;
    color: #2980b9;
    margin-bottom: 1em;
    text-align: center;
}
.search-bar {
    width: 100%;
    padding: 0.7em 1em;
    border-radius: 8px;
    border: 1px solid #2980b9;
    margin-bottom: 1em;
    font-size: 1em;
    background: #fafdff;
}
.client-list-ul {
    list-style: none;
    padding: 0;
    margin: 0 0 1em 0;
}
.client-list-ul li {
    padding: 0.5em 0.2em;
    border-bottom: 1px solid #eaf6fb;
    font-size: 1em;
}
.close-list-btn {
    background: linear-gradient(90deg, #1a355c 60%, #2980b9 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.7em 1.3em;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    margin-top: 0.7em;
    transition: background 0.2s, color 0.2s;
}
.close-list-btn:hover {
    background: #fff;
    color: #2980b9;
    border: 2px solid #2980b9;
}
.login-container {
    max-width: 350px;
    margin: 80px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 16px #1a355c22;
    padding: 2em;
}
.login-container h2 {
    margin-top: 0;
    color: #1a355c;
}
input, button {
    width: 100%;
    padding: 0.8em;
    margin: 0.5em 0;
    border-radius: 6px;
    border: 1px solid #2980b9;
    font-size: 1em;
    box-sizing: border-box;
}
button {
    background: linear-gradient(90deg, #1a355c 60%, #2980b9 100%);
    color: #fff;
    border: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
button:hover {
    background: #fff;
    color: #2980b9;
    border: 2px solid #2980b9;
}
.dashboard-flex {
    display: flex;
    flex-direction: row;
    gap: 2em;
    margin: 2em auto;
    max-width: 1400px;
    min-height: 70vh;
}
.camembert-zone {
    flex: 0 0 340px;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 4px 32px #2463a61a;
    padding: 2em 1.5em 2em 1.5em;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 420px;
    transition: box-shadow 0.3s;
}
.camembert-zone:hover {
    box-shadow: 0 8px 48px #2463a62a;
}
.entreprise-list-zone {
    flex: 1 1 420px;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 4px 32px #2463a61a;
    padding: 2em 1.5em 2em 1.5em;
    min-width: 340px;
    min-height: 420px;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.3s;
    position: relative;
}
.entreprise-list-zone .search-bar-container {
    display: flex;
    gap: 1em;
    margin-bottom: 1.5em;
}
.select-all-btn {
    background: #e5e9ef;
    color: #2463a6;
    border: none;
    border-radius: 8px;
    padding: 0.6em 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.select-all-btn:hover {
    background: #2463a6;
    color: #fff;
}
.entreprise-list {
    list-style: none;
    padding: 0;
    margin: 0;
    overflow-y: auto;
    max-height: 60vh;
}
.entreprise-list li {
    display: flex;
    align-items: center;
    gap: 1em;
    padding: 0.7em 0.2em;
    border-bottom: 1px solid #e5e9ef;
    font-size: 1.08em;
    transition: background 0.2s;
}
.entreprise-list li:hover {
    background: #f0f6fa;
    cursor: pointer;
}
.entreprise-list input[type="checkbox"] {
    accent-color: #2463a6;
    width: 1.2em;
    height: 1.2em;
}
.entreprise-name {
    font-weight: bold;
    color: #2463a6;
    text-decoration: underline;
    cursor: pointer;
}
.adresse {
    font-weight: bold;
    color: #2d3a4a;
    margin-left: 0.5em;
}
.membres-panel {
    flex: 0 0 380px;
    background: #fff;
    border-radius: 18px 0 0 18px;
    box-shadow: 0 4px 32px #2463a61a;
    padding: 2em 1.5em 2em 1.5em;
    min-width: 340px;
    min-height: 420px;
    position: relative;
    display: none;
    flex-direction: column;
    animation: slideInPanel 0.4s cubic-bezier(.4,1.5,.7,1.1);
    z-index: 100;
}
.membres-panel.active {
    display: flex;
}
@keyframes slideInPanel {
    from { transform: translateX(80px); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}
.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2em;
    font-weight: bold;
    color: #2463a6;
    margin-bottom: 1em;
}
#close-panel {
    background: none;
    border: none;
    font-size: 2em;
    color: #2463a6;
    cursor: pointer;
    transition: color 0.2s;
}
#close-panel:hover {
    color: #c0392b;
}
.panel-controls {
    margin-bottom: 1em;
}
#membres-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1em 0;
    max-height: 45vh;
    overflow-y: auto;
}
#membres-list li {
    display: flex;
    align-items: center;
    gap: 1em;
    padding: 0.6em 0.2em;
    border-bottom: 1px solid #e5e9ef;
    font-size: 1em;
    transition: background 0.2s;
}
#membres-list li:hover {
    background: #f0f6fa;
}
#membres-list input[type="checkbox"] {
    accent-color: #2463a6;
    width: 1.1em;
    height: 1.1em;
}
.export-btn {
    background: #2463a6;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.8em 1.5em;
    font-size: 1.1em;
    font-weight: bold;
    cursor: pointer;
    margin-top: 1em;
    transition: background 0.2s, color 0.2s;
    box-shadow: 0 2px 10px #2463a62a;
}
.export-btn:hover {
    background: #fff;
    color: #2463a6;
    border: 2px solid #2463a6;
}
/* Style épuré pour le nouveau panneau de filtres */
.filter-panel-clean {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px #2463a620;
    padding: 1.5em 1.5em 1em 1.5em;
    min-width: 320px;
    max-width: 98vw;
    font-family: 'Segoe UI', 'Roboto', 'Arial', sans-serif;
    color: #22324a;
    border: 1px solid #eaf6fb;
    display: flex;
    flex-direction: column;
    gap: 0.8em;
    position: fixed;
    top: 100px;
    right: 40px;
    z-index: 10001;
}
.filter-panel-clean .panel-header {
    font-size: 1.1em;
    font-weight: 600;
    color: #2463a6;
    margin-bottom: 0.5em;
}
.filter-panel-clean .panel-controls {
    display: flex;
    flex-direction: column;
    gap: 0.7em;
}
.filter-panel-clean label {
    font-weight: 500;
    color: #2980b9;
    font-size: 1em;
    margin-bottom: 0.2em;
}
.filter-panel-clean select {
    font-size: 1em;
    border-radius: 6px;
    border: 1px solid #2980b9;
    padding: 0.4em 0.8em;
    background: #fafdff;
    color: #22324a;
    margin-bottom: 0.3em;
}
.filter-panel-clean select:focus {
    border: 1.5px solid #2463a6;
    outline: none;
}
.apply-filters-btn {
    background: #2980b9;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.7em 0;
    font-size: 1em;
    font-weight: bold;
    width: 100%;
    margin-top: 0.7em;
    box-shadow: 0 2px 8px #1a355c22;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.apply-filters-btn:hover {
    background: #fff;
    color: #2980b9;
    border: 1.5px solid #2980b9;
}
.filters-bar-multi {
    display: flex;
    gap: 1.5em;
    align-items: center;
    margin: 0 0 12px 0;
}
.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.2em;
}
.filters-bar-multi select[multiple] {
    min-width: 120px;
    min-height: 2.5em;
    border-radius: 6px;
    border: 1px solid #2980b9;
    padding: 0.4em 0.8em;
    background: #fafdff;
    color: #22324a;
    font-size: 1em;
}
.filters-bar-multi label {
    font-weight: 500;
    color: #2980b9;
    font-size: 1em;
    margin-bottom: 0.1em;
}
.apply-filters-btn {
    background: #2980b9;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.7em 1.5em;
    font-size: 1em;
    font-weight: bold;
    box-shadow: 0 2px 8px #1a355c22;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    margin-left: 1.2em;
}
.apply-filters-btn:hover {
    background: #fff;
    color: #2980b9;
    border: 1.5px solid #2980b9;
}
@media (max-width: 900px) {
    .filters-bar-multi {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8em;
    }
    .filter-group {
        width: 100%;
    }
    .filters-bar-multi select[multiple] {
        min-width: 90vw;
    }
}
@media (max-width: 1100px) {
    .dashboard-flex { flex-direction: column; gap: 1em; }
    .camembert-zone, .entreprise-list-zone, .membres-panel { min-width: 90vw; }
}
@media (max-width: 700px) {
    .dashboard-flex { flex-direction: column; gap: 0.5em; }
    .camembert-zone, .entreprise-list-zone, .membres-panel { min-width: 98vw; padding: 1em 0.5em; }
}
@media (max-width: 800px) {
    .recap-charts { flex-direction: column; align-items: center; }
    main { padding: 1em 0.3em; }
    #btn-filters { right: 10px; top: 80px; }
}
@media (max-width: 600px) {
    .login-container { margin: 30px auto; padding: 1em; }
    .navbar { flex-direction: column; align-items: flex-start; }
    #map { height: 50vh; }
}
@media (max-width: 700px) {
    .filter-panel-clean {
        min-width: 98vw;
        padding: 1em 0.5em;
        right: 0;
    }
    .filter-panel-clean select {
        min-width: 90px;
    }
    #filters-panel.filter-panel-clean {
        min-width: 98vw;
        right: 0;
        left: 0;
        top: 48px;
    }
}
.filters-bar-epure {
    display: flex;
    gap: 1.5em;
    align-items: center;
    margin: 0 0 12px 0;
    z-index: 9999 !important;
    pointer-events: auto !important;
}
.filter-group-dropdown {
    display: flex;
    flex-direction: column;
    gap: 0.2em;
    position: relative;
}
.dropdown-select {
    position: relative;
}
.dropdown-btn {
    background: #fafdff;
    color: #22324a;
    border: 1px solid #2980b9;
    border-radius: 6px;
    padding: 0.4em 1.4em 0.4em 0.8em;
    font-size: 1em;
    min-width: 120px;
    text-align: left;
    cursor: pointer;
    transition: border 0.2s;
}
.dropdown-btn:after {
    content: '\25BC';
    float: right;
    margin-left: 0.8em;
    font-size: 0.85em;
    color: #2980b9;
}
.dropdown-list {
    position: absolute;
    left: 0;
    top: 110%;
    background: #fff;
    border: 1px solid #2980b9;
    border-radius: 7px;
    box-shadow: 0 2px 12px #1a355c22;
    padding: 0.7em 1.2em 0.7em 0.7em;
    min-width: 160px;
    z-index: 10;
    display: none;
    max-height: 220px;
    overflow-y: auto;
}
.dropdown-list label {
    font-weight: 400;
    color: #22324a;
    cursor: pointer;
    display: block;
    margin-bottom: 0.2em;
    font-size: 1em;
}
.dropdown-list input[type="checkbox"] {
    accent-color: #2980b9;
    margin-right: 0.5em;
}
.dropdown-select.open .dropdown-list {
    display: block;
}
.dropdown-select.open .dropdown-btn {
    border: 1.5px solid #2463a6;
}
@media (max-width: 900px) {
    .filters-bar-epure {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8em;
    }
    .dropdown-btn {
        min-width: 90vw;
    }
    .dropdown-list {
        min-width: 90vw;
    }
}
.filters-toggle-btn {
    background: #2980b9;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 0.45em 1.2em;
    font-size: 1em;
    cursor: pointer;
    margin-bottom: 0.7em;
    box-shadow: 0 2px 8px #1a355c22;
    transition: background 0.2s;
}
.filters-toggle-btn:hover {
    background: #2463a6;
}
#filters-bar-epure {
    display: none;
}
