/* E-Jar point 74 : design system allégé. Les surcharges fortes ne doivent plus verrouiller le layout responsive. */
/* E-Jar Mission 1 : variables de charte centralisées dans assets/css/ejar-base.css. */
/* Point 84 : plus de overflow-x:hidden global sur html/body.
   Le scroll horizontal doit être traité dans les wrappers E-Jar, pas masqué au niveau du site. */
body.ejar-responsive-ready {
    max-width: 100%;
}

body .ejar-dashboard,
body .ejar-card,
body .ejar-form,
body .ejar-section,
body .ejar-stats-grid,
body .ejar-actions-grid,
body .ejar-subtabs,
body .ejar-table,
body .ejar-admin-nav,
body .ejar-parc-summary-grid,
body .ejar-parc-tabs,
body .ejar-parc-two-columns,
body .ejar-parc-alert-grid,
body .ejar-parc-mini-alerts {
    box-sizing: border-box;
}

body .ejar-dashboard,
body .ejar-parc-dashboard {
    width: 100%;
    max-width: 1380px;
    margin-left: auto;
    margin-right: auto;
    color: var(--ejar-text);
}

body .ejar-dashboard-header {
    position: relative;
    overflow: hidden;
    background: var(--ejar-dark-gradient);
    border: 1px solid rgba(212,175,55,.42);
    border-radius: 28px;
    padding: clamp(26px, 4vw, 44px);
    box-shadow: 0 18px 55px rgba(5,5,5,.18);
    color: #ffffff;
}

body .ejar-dashboard-header::after {
    content: "";
    position: absolute;
    left: clamp(24px, 4vw, 44px);
    right: clamp(24px, 4vw, 44px);
    bottom: 0;
    height: 3px;
    background: var(--ejar-gold-gradient);
    opacity: .95;
}

body .ejar-dashboard-header h1,
body .ejar-dashboard-header h2,
body .ejar-dashboard-header p,
body .ejar-dashboard-header .ejar-muted {
    position: relative;
    z-index: 1;
}

body .ejar-dashboard-header h1,
body .ejar-dashboard-header h2 {
    color: #ffffff;
    letter-spacing: -.02em;
    line-height: 1.08;
}

body .ejar-dashboard-header p,
body .ejar-dashboard-header .ejar-muted,
body .ejar-dashboard-header small {
    color: rgba(255,255,255,.82);
}

body .ejar-card,
body .ejar-stat-card,
body .ejar-action-card-light,
body .ejar-subtabs-card,
body .ejar-parc-stat,
body .ejar-parc-alert-box,
body .ejar-parc-tabs-card,
body .ejar-parc-search-card {
    background: linear-gradient(180deg, #ffffff 0%, #fffdf9 100%);
    color: var(--ejar-text);
    border: 1px solid var(--ejar-border);
    border-radius: var(--ejar-radius);
    box-shadow: var(--ejar-shadow-soft);
}

body .ejar-card,
body .ejar-section {
    margin-bottom: 24px;
}

body .ejar-card h1,
body .ejar-card h2,
body .ejar-card h3,
body .ejar-card h4,
body .ejar-card h5,
body .ejar-card h6,
body .ejar-section h1,
body .ejar-section h2,
body .ejar-section h3,
body .ejar-section h4,
body .ejar-form label,
body .ejar-parc-search-label,
body .ejar-parc-stat-number,
body .ejar-parc-stat-label,
body .ejar-parc-alert-box h3 {
    color: var(--ejar-ink);
}

body .ejar-muted,
body .ejar-parc-stat-hint,
body .ejar-parc-table small,
body .ejar-muted-value,
body .ejar-dashboard small,
body .ejar-admin-page-shell small,
body .ejar-agence-page-shell small,
body .ejar-client-page-shell small,
body .ejar-client-page-shell small {
    color: var(--ejar-muted);
}

body .ejar-form input,
body .ejar-form select,
body .ejar-form textarea,
body .ejar-card input,
body .ejar-card select,
body .ejar-card textarea,
body .ejar-parc-search,
body #ejar_facture_vehicule_search {
    width: 100%;
    max-width: 100%;
    min-height: 46px;
    border: 1px solid var(--ejar-border-strong);
    border-radius: var(--ejar-radius-sm);
    background: linear-gradient(180deg, #ffffff, var(--ejar-cream-2));
    color: var(--ejar-ink);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.85);
}

body .ejar-form input::placeholder,
body .ejar-form textarea::placeholder,
body .ejar-card input::placeholder,
body .ejar-card textarea::placeholder,
body .ejar-parc-search::placeholder,
body #ejar_facture_vehicule_search::placeholder {
    color: #807567;
}

body .ejar-form input:focus,
body .ejar-form select:focus,
body .ejar-form textarea:focus,
body .ejar-card input:focus,
body .ejar-card select:focus,
body .ejar-card textarea:focus,
body .ejar-parc-search:focus,
body #ejar_facture_vehicule_search:focus {
    outline: none;
    border-color: var(--ejar-gold);
    box-shadow: 0 0 0 4px rgba(212,175,55,.18);
}

body .ejar-button,
body button.ejar-button,
body a.ejar-button,
body input[type="submit"].ejar-button,
body .ejar-action-card {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    border: 1px solid rgba(212,175,55,.42);
    border-radius: 999px;
    padding: 11px 17px;
    min-height: 42px;
    text-decoration: none;
    font-weight: 800;
    line-height: 1.2;
    box-shadow: 0 10px 24px rgba(5,5,5,.14);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease, color .18s ease;
}

body .ejar-button:hover,
body button.ejar-button:hover,
body a.ejar-button:hover,
body input[type="submit"].ejar-button:hover,
body .ejar-action-card:hover,
body .ejar-button:focus-visible,
body button.ejar-button:focus-visible,
body a.ejar-button:focus-visible {
    background: var(--ejar-gold-gradient);
    color: #111111;
    border-color: var(--ejar-gold-deep, #8c6a19);
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(140,106,25,.24);
    outline: none;
}

body .ejar-button-light,
body a.ejar-button-light,
body button.ejar-button-light,
body .ejar-action-card-light,
body a.ejar-action-card-light {
    background: linear-gradient(180deg, #ffffff, var(--ejar-silver-light));
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.35);
    box-shadow: var(--ejar-shadow-soft);
}

body .ejar-button-light:hover,
body a.ejar-button-light:hover,
body button.ejar-button-light:hover,
body .ejar-action-card-light:hover,
body a.ejar-action-card-light:hover {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    border-color: rgba(212,175,55,.55);
}

body .ejar-admin-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 1380px;
    margin: 0 auto 28px auto;
    padding: 14px;
    background: rgba(255,255,255,.965);
    border: 1px solid rgba(212,175,55,.32);
    border-radius: 24px;
    box-shadow: 0 18px 48px rgba(5,5,5,.10);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

body .ejar-admin-nav-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    align-self: stretch;
    min-height: 46px;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--ejar-dark-gradient);
    border: 1px solid rgba(212,175,55,.50);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.05), 0 10px 22px rgba(5,5,5,.12);
    flex: 0 0 auto;
}

body .ejar-admin-nav-brand img {
    display: block;
    width: 92px;
    max-width: 92px;
    height: 34px;
    object-fit: contain;
    border: 0;
    box-shadow: none;
    background: transparent;
}

body .ejar-admin-nav-brand span {
    color: var(--ejar-gold-light);
    font-size: 12px;
    line-height: 1;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

body .ejar-admin-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 10px 15px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff, #f6f4ef);
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.18);
    text-decoration: none;
    font-weight: 800;
    box-shadow: 0 4px 12px rgba(5,5,5,.04);
}

body .ejar-admin-nav a:hover,
body .ejar-admin-nav a:focus-visible {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    border-color: rgba(212,175,55,.55);
    outline: none;
}

body .ejar-admin-nav a.active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    border-color: rgba(140,106,25,.65);
    box-shadow: 0 10px 24px rgba(140,106,25,.22);
}

body .ejar-admin-nav.ejar-admin-nav-fixed {
    border-radius: 0 0 24px 24px;
    background: rgba(255,255,255,.985);
    box-shadow: 0 20px 55px rgba(5,5,5,.16);
}

body .ejar-subtabs,
body .ejar-parc-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

body .ejar-subtab,
body .ejar-edit-tab,
body .ejar-parc-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 15px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff, var(--ejar-silver-light));
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.26);
    text-decoration: none;
    font-weight: 800;
    box-shadow: none;
}

body .ejar-subtab:hover,
body .ejar-edit-tab:hover,
body .ejar-parc-tab:hover {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    border-color: rgba(212,175,55,.55);
}

body .ejar-subtab.is-active,
body .ejar-edit-tab.is-active,
body .ejar-parc-tab.is-active,
body .ejar-parc-tab.active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    border-color: rgba(140,106,25,.65);
    box-shadow: 0 10px 22px rgba(140,106,25,.18);
}


/* E-Jar v3.1.100 — bloc obsolète supprimé : ancien style global .ejar-table */

body .ejar-table a:not(.ejar-button),
body .ejar-card a:not(.ejar-button):not(.ejar-action-card-light):not(.ejar-subtab):not(.ejar-parc-tab),
body .ejar-section a:not(.ejar-button):not(.ejar-action-card-light):not(.ejar-subtab):not(.ejar-parc-tab) {
    color: #6f5010;
    font-weight: 800;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

body .ejar-table a:not(.ejar-button):hover,
body .ejar-card a:not(.ejar-button):not(.ejar-action-card-light):hover,
body .ejar-section a:not(.ejar-button):not(.ejar-action-card-light):hover {
    color: #111111;
}

body .ejar-alert {
    border-radius: 16px;
    border: 1px solid transparent;
    box-shadow: 0 8px 22px rgba(5,5,5,.045);
    color: var(--ejar-ink);
}

body .ejar-alert-success {
    background: #ecfdf3;
    border-color: #b7efca;
    color: #14532d;
}

body .ejar-alert-error {
    background: #fff1f2;
    border-color: #fecdd3;
    color: #7f1d1d;
}

body .ejar-alert-warning {
    background: #fffbeb;
    border-color: #fde68a;
    color: #78350f;
}

body .ejar-validation-badge,
body .ejar-parc-badge,
body .ejar-badge-v2,
body .ejar-status-success,
body .ejar-status-danger,
body .ejar-status-neutral,
body .ejar-balance-badge,
body .ejar-date-badge,
body .ejar-societe-badge,
body .ejar-phone,
body .ejar-money {
    color: var(--ejar-ink);
    border-radius: 999px;
    font-weight: 900;
}


/* Mission 16 : styles du livre de compte fusionnés depuis ejar-livre-compte-styles.css. */
body .ejar-solde-debiteur,
body .ejar-solde-crediteur,
body .ejar-solde-neutre {
    font-weight: 800;
}

body .ejar-badge-approved,
body .ejar-parc-badge-success,
body .ejar-status-success,
body .ejar-solde-crediteur,
body .ejar-balance-positive {
    background: #dcfce7;
    color: #14532d;
    border: 1px solid #bbf7d0;
}

body .ejar-badge-pending,
body .ejar-parc-badge-warning,
body .ejar-alert-warning,
body .ejar-status-neutral,
body .ejar-solde-neutre,
body .ejar-balance-zero {
    background: #fef3c7;
    color: #78350f;
    border: 1px solid #fde68a;
}

body .ejar-badge-rejected,
body .ejar-parc-badge-danger,
body .ejar-status-danger,
body .ejar-solde-debiteur,
body .ejar-balance-negative {
    background: #fee2e2;
    color: #7f1d1d;
    border: 1px solid #fecaca;
}

body .ejar-parc-badge-neutral,
body .ejar-date-badge,
body .ejar-societe-badge,
body .ejar-phone,
body .ejar-money,
body .ejar-muted-value {
    background: linear-gradient(180deg, #ffffff, var(--ejar-silver-light));
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.26);
}

body .ejar-autocomplete-results {
    background: #ffffff;
    border: 1px solid var(--ejar-border-strong);
    border-radius: 16px;
    box-shadow: 0 18px 45px rgba(5,5,5,.14);
    padding: 7px;
}

body .ejar-autocomplete-option,
body .ejar-autocomplete-empty {
    background: #ffffff;
    color: var(--ejar-ink);
    border-radius: 12px;
}

body .ejar-autocomplete-option:hover,
body .ejar-autocomplete-option:focus,
body .ejar-autocomplete-option.is-active {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    outline: none;
}
body .ejar-autocomplete-option:hover *,
body .ejar-autocomplete-option:focus *,
body .ejar-autocomplete-option.is-active * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

body .ejar-autocomplete-empty {
    color: var(--ejar-muted);
}

body .ejar-stats-grid,
body .ejar-actions-grid,
body .ejar-parc-summary-grid {
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px;
}

body .ejar-parc-two-columns {
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, .75fr);
    gap: 18px;
}

body .ejar-parc-alert-grid,
body .ejar-parc-mini-alerts {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 14px;
}

body .ejar-card [style*="background:#fff"],
body .ejar-card [style*="background: #fff"],
body .ejar-section [style*="background:#fff"],
body .ejar-section [style*="background: #fff"] {
    color: var(--ejar-ink);
}


/* E-Jar v3.1.8 - Logique couleur claire : urgence, succès, lisibilité */
body .ejar-relance-button,
body button.ejar-relance-button,
body a.ejar-relance-button,
body input[type="submit"].ejar-relance-button,
body button[name="ejar_pointage_action"][value="send_relance"],
body .ejar-admin-nav a[href*="relance"],
body .ejar-dashboard a[href*="gestion-relances"],
body .ejar-admin-page-shell a[href*="gestion-relances"],
body .ejar-dashboard a[href*="ejar_finance_view=relances"],
body .ejar-admin-page-shell a[href*="ejar_finance_view=relances"] {
    background: linear-gradient(135deg, #b91c1c 0%, #7f1d1d 100%);
    color: #ffffff;
    border-color: #ef4444;
    box-shadow: 0 12px 26px rgba(185, 28, 28, .26);
}

body .ejar-relance-button:hover,
body button.ejar-relance-button:hover,
body a.ejar-relance-button:hover,
body input[type="submit"].ejar-relance-button:hover,
body button[name="ejar_pointage_action"][value="send_relance"]:hover,
body .ejar-admin-nav a[href*="relance"]:hover,
body .ejar-dashboard a[href*="gestion-relances"]:hover,
body .ejar-admin-page-shell a[href*="gestion-relances"]:hover,
body .ejar-dashboard a[href*="ejar_finance_view=relances"]:hover,
body .ejar-admin-page-shell a[href*="ejar_finance_view=relances"]:hover,
body .ejar-relance-button:focus-visible,
body button.ejar-relance-button:focus-visible,
body a.ejar-relance-button:focus-visible {
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    color: #ffffff;
    border-color: #fecaca;
    box-shadow: 0 16px 34px rgba(185, 28, 28, .34);
}

body .ejar-relance-button *,
body button.ejar-relance-button *,
body a.ejar-relance-button *,
body .ejar-admin-nav a[href*="relance"] *,
body .ejar-dashboard a[href*="gestion-relances"] *,
body .ejar-admin-page-shell a[href*="gestion-relances"] *,
body .ejar-dashboard a[href*="ejar_finance_view=relances"] *,
body .ejar-admin-page-shell a[href*="ejar_finance_view=relances"] * {
    color: #ffffff;
}

body .ejar-urgent,
body .ejar-status-urgent,
body .ejar-status-danger,
body .ejar-badge-rejected,
body .ejar-parc-badge-danger,
body .ejar-badge-v2.status-danger,
body .ejar-dashboard .status-danger,
body .ejar-admin-page-shell .status-danger,
body .ejar-agence-page-shell .status-danger,
body .ejar-client-page-shell .status-danger,
body .ejar-alert-error {
    background: #fee2e2;
    color: #7f1d1d;
    border-color: #fecaca;
}

body .ejar-important,
body .ejar-warning,
body .ejar-badge-pending,
body .ejar-parc-badge-warning,
body .ejar-badge-v2.status-partial,
body .ejar-badge-v2.status-muted,
body .ejar-dashboard .status-partial,
body .ejar-admin-page-shell .status-partial,
body .ejar-agence-page-shell .status-partial,
body .ejar-client-page-shell .status-partial,
body .ejar-dashboard .status-muted,
body .ejar-admin-page-shell .status-muted,
body .ejar-agence-page-shell .status-muted,
body .ejar-client-page-shell .status-muted,
body .ejar-alert-warning {
    background: #fef3c7;
    color: #78350f;
    border-color: #fde68a;
}

body .ejar-done,
body .ejar-paid,
body .ejar-positive,
body .ejar-badge-approved,
body .ejar-parc-badge-success,
body .ejar-badge-v2.status-paid,
body .ejar-badge-v2.status-success,
body .ejar-dashboard .status-paid,
body .ejar-admin-page-shell .status-paid,
body .ejar-agence-page-shell .status-paid,
body .ejar-client-page-shell .status-paid,
body .ejar-dashboard .status-success,
body .ejar-admin-page-shell .status-success,
body .ejar-agence-page-shell .status-success,
body .ejar-client-page-shell .status-success,
body .ejar-alert-success {
    background: #dcfce7;
    color: #14532d;
    border-color: #bbf7d0;
}

body .ejar-neutral,
body .ejar-badge-v2.status-neutral,
body .ejar-dashboard .status-neutral,
body .ejar-admin-page-shell .status-neutral,
body .ejar-agence-page-shell .status-neutral,
body .ejar-client-page-shell .status-neutral,
body .ejar-parc-badge-neutral {
    background: linear-gradient(180deg, #ffffff, var(--ejar-silver-light));
    color: var(--ejar-ink);
    border-color: rgba(141,147,155,.28);
}

body .ejar-action-card:hover,
body .ejar-action-card-light:hover,
body a.ejar-action-card:hover,
body a.ejar-action-card-light:hover,
body .ejar-subtab:hover,
body .ejar-edit-tab:hover,
body .ejar-parc-tab:hover,
body .ejar-admin-nav a:hover,
body .ejar-button-light:hover,
body button.ejar-button-light:hover,
body a.ejar-button-light:hover {
    color: #ffffff;
}

body .ejar-action-card:hover *,
body .ejar-action-card-light:hover *,
body a.ejar-action-card:hover *,
body a.ejar-action-card-light:hover *,
body .ejar-subtab:hover *,
body .ejar-edit-tab:hover *,
body .ejar-parc-tab:hover *,
body .ejar-admin-nav a:hover *,
body .ejar-button-light:hover *,
body button.ejar-button-light:hover *,
body a.ejar-button-light:hover * {
    color: #ffffff;
}

body .ejar-button:hover:not(.ejar-relance-button) *,
body button.ejar-button:hover:not(.ejar-relance-button) *,
body a.ejar-button:hover:not(.ejar-relance-button) * {
    color: #111111;
}

body .ejar-card,
body .ejar-section,
body .ejar-form,
body .ejar-dashboard .filter-bar,
body .ejar-admin-page-shell .filter-bar,
body .ejar-agence-page-shell .filter-bar,
body .ejar-client-page-shell .filter-bar,
body .stat-card-v2,
body .ejar-parc-search-card,
body .ejar-parc-tabs-card {
    color: var(--ejar-text);
}

body .ejar-card p,
body .ejar-section p,
body .ejar-form p,
body .ejar-dashboard .filter-bar p,
body .ejar-admin-page-shell .filter-bar p,
body .ejar-agence-page-shell .filter-bar p,
body .ejar-client-page-shell .filter-bar p,
body .stat-card-v2 p,
body .ejar-card span:not(.ejar-badge-v2):not(.ejar-validation-badge):not(.ejar-parc-badge):not(.ejar-status-danger):not(.ejar-status-success),
body .ejar-section span:not(.ejar-badge-v2):not(.ejar-validation-badge):not(.ejar-parc-badge):not(.ejar-status-danger):not(.ejar-status-success) {
    color: inherit;
}

body .stat-card-v2 {
    background: linear-gradient(180deg, #ffffff 0%, #fffdf9 100%);
    color: var(--ejar-text);
    border: 1px solid var(--ejar-border);
    border-bottom: 4px solid var(--ejar-gold);
    border-radius: var(--ejar-radius);
    box-shadow: var(--ejar-shadow-soft);
}

body .stat-card-v2:hover,
body .clickable-stat:hover {
    background: linear-gradient(180deg, #ffffff 0%, #fff7e5 100%);
    color: var(--ejar-ink);
    border-bottom-color: var(--ejar-gold-deep);
}

body .stat-card-v2:hover *,
body .clickable-stat:hover * {
    color: inherit;
}

body .stat-card-v2 .stat-label,
body .filter-group label {
    color: var(--ejar-muted);
}

body .ejar-dashboard-header,
body .ejar-dashboard-header *,
body .ejar-admin-nav-brand,
body .ejar-admin-nav-brand * {
    color: #ffffff;
}

body .ejar-admin-nav-brand span {
    color: var(--ejar-gold-light);
}

body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#1a1a1a"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #1a1a1a"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#000"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #000"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#111"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #111"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#050505"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #050505"] {
    color: #ffffff;
}

body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#1a1a1a"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #1a1a1a"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#000"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #000"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#111"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #111"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#050505"] *,
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #050505"] * {
    color: #ffffff;
}

body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background:#fff"],
body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [style*="background: #fff"] {
    color: var(--ejar-ink);
}









/* E-Jar v3.1.9 - Correction lisibilité onglets parc + dashboard agence premium */
body .ejar-parc-tabs-card .ejar-parc-tab:hover,
body .ejar-parc-tabs-card .ejar-parc-tab:focus,
body .ejar-parc-tabs .ejar-parc-tab:hover,
body .ejar-parc-tabs .ejar-parc-tab:focus {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    border-color: rgba(212,175,55,.72);
    box-shadow: 0 12px 28px rgba(0,0,0,.22);
}

body .ejar-parc-tabs-card .ejar-parc-tab:hover *,
body .ejar-parc-tabs-card .ejar-parc-tab:focus *,
body .ejar-parc-tabs .ejar-parc-tab:hover *,
body .ejar-parc-tabs .ejar-parc-tab:focus * {
    color: #ffffff;
}

body .ejar-parc-tabs-card .ejar-parc-tab.is-active,
body .ejar-parc-tabs .ejar-parc-tab.is-active,
body .ejar-parc-tabs .ejar-parc-tab.active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    border-color: rgba(140,106,25,.7);
}

body .ejar-parc-tabs-card .ejar-parc-tab.is-active *,
body .ejar-parc-tabs .ejar-parc-tab.is-active *,
body .ejar-parc-tabs .ejar-parc-tab.active * {
    color: #111111;
}

body .ejar-agence-premium-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(240px, 1fr));
    gap: 14px;
    margin: 22px 0;
}

body .ejar-agence-stat {
    position: relative;
    min-height: 148px;
    padding: 22px 22px 20px;
    border-radius: 24px;
    background: linear-gradient(180deg, #ffffff, #f8f6f0);
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.22);
    box-shadow: 0 16px 40px rgba(5,5,5,.07);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
}

body .ejar-agence-stat::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: var(--ejar-silver-gradient);
}

body .ejar-agence-stat-title {
    display: block;
    color: #4b5563;
    font-size: 13px;
    font-weight: 850;
    letter-spacing: .015em;
    margin-bottom: 4px;
    min-height: 34px;
    line-height: 1.25;
}

body .ejar-agence-stat strong {
    display: block;
    color: var(--ejar-ink);
    font-size: clamp(26px, 2.45vw, 38px);
    line-height: 1.05;
    font-weight: 950;
    margin: 0;
    white-space: nowrap;
    letter-spacing: -.035em;
}

body .ejar-agence-stat small {
    color: #64748b;
    font-weight: 700;
    line-height: 1.35;
    min-height: 36px;
    display: block;
}

body .ejar-agence-stat-gold::before { background: var(--ejar-gold-gradient); }
body .ejar-agence-stat-success::before { background: linear-gradient(180deg, #16a34a, #86efac); }
body .ejar-agence-stat-warning::before { background: linear-gradient(180deg, #f59e0b, #fde68a); }
body .ejar-agence-stat-danger::before { background: linear-gradient(180deg, #dc2626, #fca5a5); }

body .ejar-agence-stat-danger {
    border-color: rgba(220,38,38,.28);
    background: linear-gradient(180deg, #fffafa, #fff1f2);
}

body .ejar-agence-stat-success {
    border-color: rgba(22,163,74,.24);
    background: linear-gradient(180deg, #fbfffd, #f0fdf4);
}

body .ejar-agence-stat-warning {
    border-color: rgba(245,158,11,.28);
    background: linear-gradient(180deg, #fffdf7, #fffbeb);
}

body .ejar-agence-quick-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(190px, 1fr));
    gap: 14px;
    margin: 18px 0 24px;
}

body .ejar-agence-quick-card {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 20px;
    border-radius: 22px;
    background: linear-gradient(180deg, #ffffff, var(--ejar-cream, #f7f2e8));
    color: var(--ejar-ink);
    text-decoration: none;
    border: 1px solid rgba(212,175,55,.18);
    box-shadow: 0 14px 34px rgba(5,5,5,.055);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

body .ejar-agence-quick-card strong {
    color: var(--ejar-ink);
    font-size: 16px;
    font-weight: 900;
}

body .ejar-agence-quick-card span {
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
}

body .ejar-agence-quick-card:hover {
    transform: translateY(-2px);
    background: var(--ejar-dark-gradient);
    box-shadow: 0 18px 44px rgba(5,5,5,.18);
    border-color: rgba(212,175,55,.55);
}

body .ejar-agence-quick-card:hover strong,
body .ejar-agence-quick-card:hover span {
    color: #ffffff;
}

body .ejar-agence-quick-card-alert {
    border-color: rgba(220,38,38,.22);
}

body .ejar-agence-priority-panel {
    border-color: rgba(212,175,55,.18);
}

body .ejar-agence-priority-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    gap: 14px;
    margin-top: 14px;
}

body .ejar-agence-priority-box {
    padding: 18px;
    border-radius: 22px;
    background: #ffffff;
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.18);
    box-shadow: 0 12px 30px rgba(5,5,5,.045);
}

body .ejar-agence-priority-box h3 {
    margin: 0 0 12px;
    color: var(--ejar-ink);
    font-size: 17px;
    font-weight: 950;
}

body .ejar-agence-priority-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 10px;
}

body .ejar-agence-priority-box li {
    padding: 12px 12px;
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    border: 1px solid rgba(141,147,155,.14);
    color: var(--ejar-ink);
}

body .ejar-agence-priority-box li strong {
    color: var(--ejar-ink);
}

body .ejar-agence-priority-box li span,
body .ejar-agence-priority-box li small {
    color: #64748b;
}

body .ejar-agence-priority-box .ejar-agence-ok {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #166534;
    font-weight: 800;
}

body .ejar-agence-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 950;
    border: 1px solid transparent;
    white-space: nowrap;
}

body .ejar-agence-pill-danger {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

body .ejar-agence-pill-warning {
    background: #fef3c7;
    color: #92400e;
    border-color: #fde68a;
}

body .ejar-agence-pill-success {
    background: #dcfce7;
    color: #166534;
    border-color: #bbf7d0;
}

body .ejar-agence-pill-neutral {
    background: #f1f5f9;
    color: #334155;
    border-color: #e2e8f0;
}

body .ejar-agence-accounts-table td small {
    color: #64748b;
    font-weight: 650;
}

body .ejar-agence-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}


body .ejar-agence-account-section {
    border-color: rgba(212,175,55,.18);
}

body .ejar-agence-account-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(240px, 1fr));
    gap: 14px;
    margin-top: 16px;
}

body .ejar-agence-account-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 18px;
    border-radius: 22px;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    color: var(--ejar-ink);
    border: 1px solid rgba(141,147,155,.18);
    box-shadow: 0 14px 34px rgba(5,5,5,.055);
}

body .ejar-agence-account-card-danger {
    background: linear-gradient(180deg, #fffafa, #fff1f2);
    border-color: rgba(220,38,38,.24);
}

body .ejar-agence-account-card-warning {
    background: linear-gradient(180deg, #fffdf7, #fffbeb);
    border-color: rgba(245,158,11,.26);
}

body .ejar-agence-account-card-success {
    background: linear-gradient(180deg, #fbfffd, #f0fdf4);
    border-color: rgba(22,163,74,.22);
}

body .ejar-agence-account-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

body .ejar-agence-account-card-top strong {
    color: var(--ejar-ink);
    font-size: 16px;
    font-weight: 950;
    line-height: 1.25;
}

body .ejar-agence-account-meta,
body .ejar-agence-account-card small {
    color: #64748b;
    font-weight: 700;
    line-height: 1.35;
}

body .ejar-agence-account-amount strong {
    font-size: 22px;
    font-weight: 950;
}

body .ejar-agence-account-card .ejar-button {
    margin-top: auto;
    align-self: flex-start;
}

body .ejar-agence-account-card.is-selected {
    border-color: rgba(212,175,55,.72);
    box-shadow: 0 18px 44px rgba(212,175,55,.18), 0 12px 30px rgba(5,5,5,.08);
    transform: translateY(-1px);
}

body .ejar-agence-account-card.is-selected .ejar-button {
    background: linear-gradient(135deg, var(--ejar-gold), var(--ejar-gold-dark));
    color: #111111;
    border-color: rgba(212,175,55,.55);
}

body .ejar-agence-account-empty-state {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 6px;
}

body .ejar-agence-account-empty-state strong {
    color: var(--ejar-ink);
    font-size: 18px;
    font-weight: 950;
}

body .ejar-agence-account-empty-state span {
    color: #64748b;
    font-weight: 750;
}

body .ejar-agence-account-detail-empty {
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    border-style: dashed;
}

body .ejar-agence-account-templates {
    display: none !important;
}

body .ejar-agence-account-detail {
    padding: 18px;
    border-radius: 24px;
    background: linear-gradient(180deg, #ffffff, var(--ejar-cream, #f7f2e8));
    border: 1px solid rgba(212,175,55,.22);
    box-shadow: 0 16px 40px rgba(5,5,5,.06);
    margin: 18px 0 22px;
}

body .ejar-agence-account-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(141,147,155,.18);
}

body .ejar-agence-account-detail-header h3 {
    margin: 0 0 6px;
    color: var(--ejar-ink);
    font-size: 22px;
    font-weight: 950;
}

body .ejar-agence-account-detail-header p {
    margin: 0;
    color: #64748b;
    font-weight: 750;
}

body .ejar-agence-account-detail-status {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}









    

/* E-Jar v3.1.10 - correction définitive lisibilité onglets Parc + bouton Reset */
html body .ejar-parc-tabs-card a.ejar-parc-tab:hover,
html body .ejar-parc-tabs-card a.ejar-parc-tab:focus,
html body .ejar-parc-tabs a.ejar-parc-tab:hover,
html body .ejar-parc-tabs a.ejar-parc-tab:focus {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(140,106,25,.85);
    box-shadow: 0 12px 28px rgba(140,106,25,.22);
}
html body .ejar-parc-tabs-card a.ejar-parc-tab:hover *,
html body .ejar-parc-tabs-card a.ejar-parc-tab:focus *,
html body .ejar-parc-tabs a.ejar-parc-tab:hover *,
html body .ejar-parc-tabs a.ejar-parc-tab:focus * {
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body .ejar-parc-tabs-card a.ejar-parc-tab.is-active,
html body .ejar-parc-tabs a.ejar-parc-tab.is-active,
html body .ejar-parc-tabs a.ejar-parc-tab.active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body .ejar-reset-button,
html body a.ejar-reset-button,
html body button.ejar-reset-button {
    background: #B42318;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: #B42318;
}
html body .ejar-reset-button:hover,
html body a.ejar-reset-button:hover,
html body button.ejar-reset-button:hover {
    background: #7A1810;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: #7A1810;
}


/* E-Jar v3.1.13 - filtres agence structure de location / véhicules personnels */
html body .ejar-agence-quick-grid {
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

html body .ejar-agence-filter-panel {
    border-color: rgba(212,175,55,.22);
    background: linear-gradient(180deg, #ffffff, var(--ejar-cream, #f7f2e8));
}

html body .ejar-agence-filter-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

html body .ejar-agence-filter-heading h2 {
    margin-bottom: 4px;
}

html body .ejar-agence-filter-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 8px 13px;
    border-radius: 999px;
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    font-weight: 950;
    font-size: 13px;
    white-space: nowrap;
    border: 1px solid rgba(140,106,25,.46);
}

html body .ejar-agence-filter-grid {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(220px, 1.35fr) minmax(180px, 1fr) minmax(180px, 1fr) auto;
    gap: 12px;
    align-items: end;
}

html body .ejar-agence-filter-grid label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin: 0;
}

html body .ejar-agence-filter-grid label span {
    color: #334155;
    font-weight: 900;
    font-size: 13px;
}

html body .ejar-agence-filter-grid select,
html body .ejar-agence-filter-grid input[type="search"] {
    width: 100%;
    min-height: 46px;
    border-radius: 14px;
    border: 1px solid rgba(141,147,155,.34);
    background: #ffffff;
    color: #111827;
    -webkit-text-fill-color: #111827;
    font-weight: 750;
    padding: 10px 12px;
    box-shadow: inset 0 1px 2px rgba(5,5,5,.03);
}

html body .ejar-agence-filter-grid select:focus,
html body .ejar-agence-filter-grid input[type="search"]:focus {
    border-color: rgba(212,175,55,.72);
    box-shadow: 0 0 0 4px rgba(212,175,55,.16);
    outline: none;
}

html body .ejar-agence-filter-grid .ejar-button-danger,
html body .ejar-agence-filter-grid button[data-ejar-agence-filter-reset] {
    min-height: 46px;
    background: #B42318;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: #B42318;
    white-space: nowrap;
}

html body .ejar-agence-filter-grid .ejar-button-danger:hover,
html body .ejar-agence-filter-grid button[data-ejar-agence-filter-reset]:hover {
    background: #7A1810;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: #7A1810;
}

html body .ejar-agence-filter-empty {
    margin-top: 14px;
    padding: 14px 16px;
    border-radius: 18px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #9a3412;
    font-weight: 850;
}

html body [data-ejar-agence-filter-item][hidden],
html body .ejar-filter-hidden {
    display: none !important;
}

html body .ejar-agence-account-card[hidden],
html body .ejar-agence-accounts-table tr[hidden] {
    display: none !important;
}







/* E-Jar v3.1.14 - Espace client premium */
html body .ejar-client-dashboard {
    gap: 22px;
}

html body .ejar-client-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

html body .ejar-client-eyebrow {
    color: var(--ejar-gold-2, #d4af37);
    text-transform: uppercase;
    letter-spacing: .16em;
    font-weight: 900;
    font-size: 12px;
    margin: 0 0 10px;
}

html body .ejar-client-hero-badge {
    min-width: 220px;
    padding: 18px 20px;
    border-radius: 22px;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.18);
    color: #ffffff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.12);
}

html body .ejar-client-hero-badge span,
html body .ejar-client-hero-badge small,
html body .ejar-client-hero-badge strong {
    display: block;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

html body .ejar-client-hero-badge span {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .09em;
    opacity: .84;
}

html body .ejar-client-hero-badge strong {
    font-size: 26px;
    line-height: 1.05;
    margin: 8px 0 4px;
}

html body .ejar-client-kpi-grid,
html body .ejar-client-actions,
html body .ejar-client-alert-grid,
html body .ejar-client-véhicules-grid,
html body .ejar-client-finance-grid {
    display: grid;
    gap: 16px;
}

html body .ejar-client-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 22px 0;
}

html body .ejar-client-kpi,
html body .ejar-client-panel,
html body .ejar-client-action-card,
html body .ejar-client-véhicule-card,
html body .ejar-client-account-card,
html body .ejar-client-alert,
html body .ejar-client-empty {
    box-sizing: border-box;
    border-radius: 24px;
    border: 1px solid var(--ejar-border);
    background: linear-gradient(180deg, #ffffff 0%, #fffdf9 100%);
    color: var(--ejar-text);
    box-shadow: var(--ejar-shadow-soft);
}

html body .ejar-client-kpi {
    min-height: 130px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    position: relative;
}

html body .ejar-client-kpi::before,
html body .ejar-client-véhicule-card::before,
html body .ejar-client-account-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: var(--ejar-silver-gradient);
}

html body .ejar-client-kpi.is-gold::before { background: var(--ejar-gold-gradient); }
html body .ejar-client-kpi.is-danger::before,
html body .ejar-client-véhicule-card.is-danger::before,
html body .ejar-client-account-card.is-danger::before { background: #B42318; }
html body .ejar-client-kpi.is-success::before,
html body .ejar-client-véhicule-card.is-success::before,
html body .ejar-client-account-card.is-success::before { background: #1F8F46; }
html body .ejar-client-kpi.is-neutral::before,
html body .ejar-client-véhicule-card.is-neutral::before,
html body .ejar-client-account-card.is-neutral::before { background: var(--ejar-silver-gradient); }

html body .ejar-client-kpi span,
html body .ejar-client-kpi small {
    color: var(--ejar-muted);
    font-weight: 800;
}

html body .ejar-client-kpi strong {
    color: var(--ejar-ink);
    font-size: clamp(24px, 3.2vw, 36px);
    line-height: 1.05;
    letter-spacing: -.03em;
}

html body .ejar-client-kpi.is-danger strong { color: #B42318; }
html body .ejar-client-kpi.is-success strong { color: #1F8F46; }
html body .ejar-client-kpi.is-gold strong { color: var(--ejar-gold-deep, #8c6a19); }

html body .ejar-client-panel {
    padding: clamp(18px, 3vw, 28px);
    margin: 22px 0;
}

html body .ejar-client-section-title {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--ejar-border);
}

html body .ejar-client-section-title h2 {
    margin: 0;
    color: var(--ejar-ink);
}

html body .ejar-client-section-title p {
    margin: 0;
    color: var(--ejar-muted);
    font-weight: 650;
}

html body .ejar-client-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 18px 0 22px;
}

html body .ejar-client-action-card {
    padding: 20px;
    min-height: 148px;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

html body .ejar-client-action-card span {
    font-size: 24px;
}

html body .ejar-client-action-card strong {
    color: var(--ejar-ink);
    font-size: 17px;
}

html body .ejar-client-action-card small {
    color: var(--ejar-muted);
    font-weight: 650;
}

html body .ejar-client-action-card:hover,
html body .ejar-client-action-card:focus-visible {
    transform: translateY(-2px);
    background: var(--ejar-dark-gradient);
    border-color: rgba(212,175,55,.74);
    box-shadow: 0 18px 44px rgba(5,5,5,.18);
}

html body .ejar-client-action-card:hover *,
html body .ejar-client-action-card:focus-visible * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

html body .ejar-client-alert-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

html body .ejar-client-alert,
html body .ejar-client-empty {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

html body .ejar-client-alert strong,
html body .ejar-client-empty strong {
    color: var(--ejar-ink);
    font-size: 16px;
}

html body .ejar-client-alert span,
html body .ejar-client-empty span {
    color: var(--ejar-muted);
    font-weight: 650;
}

html body .ejar-client-alert.is-danger {
    border-color: #FDA29B;
    background: linear-gradient(180deg, #fff7f5 0%, #ffffff 100%);
}

html body .ejar-client-alert.is-danger strong { color: #B42318; }

html body .ejar-client-alert.is-warning,
html body .ejar-client-empty.is-warning {
    border-color: #FED7AA;
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 100%);
}

html body .ejar-client-empty.is-success {
    border-color: #A6F4C5;
    background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 100%);
}
html body .ejar-client-empty.is-success strong { color: #1F8F46; }

html body .ejar-client-véhicules-grid,
html body .ejar-client-finance-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

html body .ejar-client-véhicule-card,
html body .ejar-client-account-card {
    position: relative;
    overflow: hidden;
    padding: 22px;
}

html body .ejar-client-véhicule-top,
html body .ejar-client-account-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 18px;
}

html body .ejar-client-véhicule-top h3,
html body .ejar-client-account-head h3 {
    margin: 0 0 6px;
    color: var(--ejar-ink);
}

html body .ejar-client-véhicule-top p,
html body .ejar-client-account-head span {
    margin: 0;
    color: var(--ejar-muted);
    font-weight: 750;
}

html body .ejar-client-pill {
    flex: 0 0 auto;
    padding: 8px 12px;
    border-radius: 999px;
    background: var(--ejar-silver-light);
    color: var(--ejar-ink);
    font-weight: 900;
    border: 1px solid var(--ejar-border);
}

html body .ejar-client-véhicule-card.is-danger .ejar-client-pill { background: #FEE4E2; color: #B42318; border-color: #FDA29B; }
html body .ejar-client-véhicule-card.is-success .ejar-client-pill { background: #DCFCE7; color: #166534; border-color: #A6F4C5; }

html body .ejar-client-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

html body .ejar-client-info-grid.compact {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

html body .ejar-client-info-grid > div {
    padding: 14px;
    border-radius: 16px;
    background: #fbfaf7;
    border: 1px solid var(--ejar-border);
}

html body .ejar-client-info-grid span {
    display: block;
    color: var(--ejar-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-weight: 900;
    margin-bottom: 6px;
}

html body .ejar-client-info-grid strong {
    display: block;
    color: var(--ejar-ink);
    font-size: 15px;
    line-height: 1.25;
}

html body .ejar-client-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

html body .ejar-button-light,
html body a.ejar-button-light {
    background: linear-gradient(180deg, #ffffff, #fbfaf7);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    border-color: var(--ejar-border-strong);
    box-shadow: var(--ejar-shadow-soft);
}

html body .ejar-button-light:hover,
html body a.ejar-button-light:hover {
    background: var(--ejar-dark-gradient);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

html body .ejar-button-small,
html body a.ejar-button-small {
    min-height: 34px;
    padding: 7px 12px;
    font-size: 13px;
}

html body .ejar-client-account-head > strong {
    color: var(--ejar-ink);
    font-size: clamp(22px, 3vw, 34px);
    letter-spacing: -.03em;
}

html body .ejar-client-account-card.is-danger .ejar-client-account-head > strong,
html body .is-danger-text { color: #B42318; }
html body .ejar-client-account-card.is-success .ejar-client-account-head > strong,
html body .is-success-text { color: #1F8F46; }

html body .ejar-client-mini-history {
    margin: 18px 0;
    padding: 14px;
    border-radius: 18px;
    background: #fbfaf7;
    border: 1px solid var(--ejar-border);
}

html body .ejar-client-mini-history h4 {
    margin: 0 0 10px;
    color: var(--ejar-ink);
}

html body .ejar-client-mini-line {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 9px 0;
    border-top: 1px solid rgba(234,223,202,.72);
}

html body .ejar-client-mini-line span {
    color: var(--ejar-muted);
    font-weight: 700;
}

html body .ejar-client-doc-tools {
    display: grid;
    grid-template-columns: 1.4fr .8fr .8fr;
    gap: 12px;
    margin-bottom: 16px;
}

html body .ejar-client-doc-tools input,
html body .ejar-client-doc-tools select,
html body .ejar-client-compte-selector select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--ejar-border-strong);
    border-radius: 14px;
    background: #ffffff;
    color: var(--ejar-ink);
    padding: 9px 12px;
}

html body .ejar-client-doc-tools input:focus,
html body .ejar-client-doc-tools select:focus,
html body .ejar-client-compte-selector select:focus {
    outline: none;
    border-color: var(--ejar-gold);
    box-shadow: 0 0 0 4px rgba(212,175,55,.16);
}

/* E-Jar point 74 : .ejar-responsive-table-wrap est désormais piloté uniquement par ejar-responsive-optimizations.css. */

html body .ejar-client-compte-context {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 14px 0;
    padding: 14px 16px;
    border-radius: 18px;
    background: #fbfaf7;
    border: 1px solid var(--ejar-border);
}

html body .ejar-client-compte-context strong {
    color: var(--ejar-ink);
}
html body .ejar-client-compte-context span {
    color: var(--ejar-muted);
}

html body [data-ejar-doc-row][hidden] {
    display: none !important;
}


/* E-Jar - Générateur de contrats */
html body .ejar-contrats-dashboard {
    display: block;
}
html body .ejar-contrats-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin: 24px 0;
}
html body .ejar-contrats-stats-grid .ejar-stat-card {
    min-height: 132px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
html body .ejar-contrats-stats-grid .ejar-stat-card strong {
    display: block;
    font-size: clamp(24px, 3vw, 34px);
    line-height: 1.05;
    color: var(--ejar-ink);
}
html body .ejar-contrats-principles {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}
html body .ejar-contrats-principles > div {
    border: 1px solid var(--ejar-border);
    border-radius: 18px;
    padding: 16px;
    background: linear-gradient(180deg,#ffffff,var(--ejar-silver-light));
}
html body .ejar-contrats-principles strong,
html body .ejar-contrats-principles span {
    display: block;
    color: var(--ejar-ink);
}
html body .ejar-contrats-principles span {
    color: var(--ejar-muted);
    font-size: 13px;
    margin-top: 4px;
}
html body .ejar-contrats-form h2 {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--ejar-border);
    color: var(--ejar-ink);
}
html body .ejar-contrats-form h2:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}
html body .ejar-form-grid-2,
html body .ejar-form-grid-3 {
    display: grid;
    gap: 14px;
}
html body .ejar-form-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
html body .ejar-form-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
html body .ejar-contrats-toggle-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 10px 0 16px;
}
html body .ejar-contrats-toggle-row label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 10px 14px;
    border-radius: 999px;
    background: #fffaf1;
    border: 1px solid var(--ejar-border);
    color: var(--ejar-ink);
    font-weight: 800;
    cursor: pointer;
}
html body .ejar-contrats-toggle-row label:hover {
    background: var(--ejar-gold-gradient);
    color: #111111;
}
html body .ejar-contrats-form [hidden],
html body [data-ejar-societe-select][hidden] {
    display: none !important;
}











/* E-Jar v3.1.19 - Générateur de contrats premium + responsive */
html body .ejar-contrats-dashboard .ejar-dashboard-header {
    background: radial-gradient(circle at 15% 0%, rgba(212,175,55,.20), transparent 32%), linear-gradient(135deg, #080808, #171717 58%, #2a2419);
    border: 1px solid rgba(212,175,55,.38);
    color: #ffffff;
    border-radius: 30px;
    padding: clamp(24px, 4vw, 42px);
    box-shadow: 0 22px 70px rgba(0,0,0,.18);
}
html body .ejar-contrats-dashboard .ejar-dashboard-header h1,
html body .ejar-contrats-dashboard .ejar-dashboard-header p {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}
html body .ejar-contrats-dashboard .ejar-dashboard-header p {
    color: rgba(255,255,255,.80);
    -webkit-text-fill-color: rgba(255,255,255,.80);
}
html body .ejar-contrats-form {
    background: linear-gradient(180deg, #ffffff 0%, #fffaf0 100%);
    border: 1px solid rgba(212,175,55,.30);
    box-shadow: 0 18px 55px rgba(25,20,12,.08);
}
html body .ejar-contrats-form > h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-size: clamp(18px, 2vw, 24px);
}
html body .ejar-contrats-form > h2::before {
    content: '';
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: var(--ejar-gold-gradient);
    box-shadow: 0 0 0 5px rgba(212,175,55,.14);
    flex: 0 0 auto;
}
html body .ejar-contrats-form .ejar-field label,
html body .ejar-contrats-form .ejar-checkline,
html body .ejar-contrats-form .ejar-contrats-annexes-grid label {
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
}
html body .ejar-contrats-form input[type="text"],
html body .ejar-contrats-form input[type="email"],
html body .ejar-contrats-form input[type="number"],
html body .ejar-contrats-form input[type="date"],
html body .ejar-contrats-form select,
html body .ejar-contrats-form textarea {
    width: 100%;
    min-height: 46px;
    border: 1px solid rgba(15,23,42,.16);
    background: #ffffff;
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-radius: 16px;
    padding: 11px 13px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
}
html body .ejar-contrats-form textarea {
    min-height: 94px;
}
html body .ejar-contrats-form input:focus,
html body .ejar-contrats-form select:focus,
html body .ejar-contrats-form textarea:focus {
    outline: none;
    border-color: var(--ejar-gold);
    box-shadow: 0 0 0 4px rgba(212,175,55,.18);
}
html body .ejar-contrats-legal-details,
html body .ejar-contrats-societe-new {
    border-radius: 24px;
    padding: clamp(18px, 2.2vw, 24px);
    background: linear-gradient(180deg, #fffef9, #faf4e8);
    border: 1px solid rgba(212,175,55,.34);
    box-shadow: 0 12px 34px rgba(25,20,12,.05);
}
html body .ejar-contrats-legal-details h3,
html body .ejar-contrats-societe-new h3 {
    color: #111111;
    -webkit-text-fill-color: #111111;
    font-size: 18px;
    margin-bottom: 12px;
}
html body .ejar-contrats-commercial-block {
    background: radial-gradient(circle at top left, rgba(192,192,192,.26), transparent 30%), linear-gradient(180deg, #fff, #f3f4f6);
    border-color: rgba(148,163,184,.55);
}
html body .ejar-contrats-annexes-grid label:hover,
html body .ejar-contrats-toggle-row label:hover {
    background: linear-gradient(135deg, #111111, #2a2419);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: rgba(212,175,55,.60);
}
html body .ejar-contrats-annexes-grid label:hover *,
html body .ejar-contrats-toggle-row label:hover * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}
html body .ejar-contrats-form [hidden],
html body .ejar-contrats-annexes-grid [hidden] {
    display: none !important;
}
html body .ejar-contrats-form .ejar-button[type="submit"] {
    width: 100%;
    justify-content: center;
    min-height: 54px;
    font-size: 16px;
    margin-top: 14px;
    background: linear-gradient(135deg, #111111, #2a2419);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border: 1px solid rgba(212,175,55,.55);
}
html body .ejar-contrats-form .ejar-button[type="submit"]:hover {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
}

/* E-Jar point 86+ : les boutons de choix du générateur de contrats restent des contrôles de formulaire,
   pas des onglets de navigation. */
html body .ejar-contrats-toggle-row {
    overflow: visible;
}
html body .ejar-contrats-toggle-row label {
    white-space: normal;
    line-height: 1.25;
    text-align: center;
    justify-content: center;
}






/* E-Jar v3.1.25 - Harmonisation finale Gestion E-Jar */

.ejar-page-hero {
    display: flex;
    align-items: center;
    gap: 18px;
    background: radial-gradient(circle at top left, rgba(212,175,55,.26), transparent 34%), linear-gradient(135deg, #0b0b0d, #151515 55%, #1f1b12);
    border: 1px solid rgba(212,175,55,.36);
    border-radius: 28px;
    padding: clamp(20px, 3vw, 34px);
    box-shadow: 0 20px 48px rgba(0,0,0,.18);
    margin: 0 0 22px;
}
.ejar-page-hero h1,
.ejar-page-hero p { color: #fff; -webkit-text-fill-color: #fff; }
.ejar-page-hero h1 { margin: 0 0 6px; font-size: clamp(26px, 3.4vw, 42px); letter-spacing:-.03em; }
.ejar-page-hero p { margin:0; opacity:.9; max-width:850px; }
.ejar-page-hero-icon {
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:20px;
    background: var(--ejar-gold-gradient);
    color: #111;
    -webkit-text-fill-color: #111;
    font-size:28px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 12px 30px rgba(0,0,0,.22);
}
.ejar-control-center {
    margin: 24px 0 34px;
    padding: clamp(18px, 2.5vw, 28px);
    border-radius: 30px;
    background: linear-gradient(180deg, #ffffff, #f7f3ea);
    border: 1px solid rgba(212,175,55,.28);
    box-shadow: 0 20px 50px rgba(16,24,40,.09);
}
.ejar-control-center-head {
    display:grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
    gap:18px;
    align-items:end;
    margin-bottom: 22px;
}
.ejar-control-center h2 { margin:0 0 6px; color: #111; -webkit-text-fill-color: #111; }
.ejar-control-center p { margin:0; color: #555; -webkit-text-fill-color: #555; }
.ejar-tool-search,
.ejar-table-toolbar input,
.ejar-smart-filter-panel input,
.ejar-smart-filter-panel select {
    width:100%;
    min-height:46px;
    border-radius:16px;
    border:1px solid rgba(17,17,17,.14);
    background: #fff;
    color: #111;
    -webkit-text-fill-color: #111;
    padding: 0 14px;
    outline:none;
    box-shadow: 0 8px 18px rgba(15,23,42,.04);
}
.ejar-tool-search:focus,
.ejar-table-toolbar input:focus,
.ejar-smart-filter-panel input:focus,
.ejar-smart-filter-panel select:focus {
    border-color:var(--ejar-gold-2, #d4af37);
    box-shadow:0 0 0 4px rgba(212,175,55,.16);
}
.ejar-tool-section { margin-top: 20px; }
.ejar-tool-section h3 {
    margin: 0 0 12px;
    color: #111;
    -webkit-text-fill-color: #111;
    font-size: 18px;
}
.ejar-tool-grid {
    display:grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap:14px;
}
.ejar-tool-card {
    display:grid;
    grid-template-columns: 46px minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: 12px;
    min-height: 116px;
    padding: 16px;
    border-radius: 22px;
    text-decoration: none;
    background: linear-gradient(180deg, #ffffff, #fbfaf6);
    border:1px solid rgba(17,17,17,.08);
    box-shadow:0 12px 26px rgba(16,24,40,.06);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.ejar-tool-card .ejar-tool-icon {
    grid-row: 1 / span 2;
    width:46px;
    height:46px;
    border-radius:16px;
    display:flex;
    align-items:center;
    justify-content:center;
    background: linear-gradient(135deg, #111, #2a2419);
    color: #fff;
    -webkit-text-fill-color: #fff;
    font-size:22px;
}
.ejar-tool-card strong {
    align-self:end;
    color: #111;
    -webkit-text-fill-color: #111;
    font-size:15px;
}
.ejar-tool-card small {
    color: #555;
    -webkit-text-fill-color: #555;
    line-height:1.35;
    margin-top: 5px;
}
.ejar-tool-card:hover,
.ejar-tool-card:focus-visible {
    transform: translateY(-3px);
    background: linear-gradient(135deg, #101010, #231f16);
    border-color: rgba(212,175,55,.55);
    box-shadow:0 20px 40px rgba(0,0,0,.18);
}
.ejar-tool-card:hover strong,
.ejar-tool-card:hover small,
.ejar-tool-card:focus-visible strong,
.ejar-tool-card:focus-visible small {
    color: #fff;
    -webkit-text-fill-color: #fff;
}
.ejar-tool-card:hover .ejar-tool-icon,
.ejar-tool-card:focus-visible .ejar-tool-icon {
    background: var(--ejar-gold-gradient);
    color: #111;
    -webkit-text-fill-color: #111;
}
.ejar-smart-filter-panel {
    display:grid;
    grid-template-columns: minmax(220px, 320px) minmax(260px, 1fr);
    gap:14px;
    padding:14px;
    margin: 14px 0 10px;
    border-radius:22px;
    background:linear-gradient(180deg, #fff, #f9fafb);
    border:1px solid rgba(17,17,17,.08);
}
.ejar-smart-filter-field label,
.ejar-table-toolbar label {
    display:block;
    font-size:12px;
    font-weight:800;
    letter-spacing:.04em;
    text-transform:uppercase;
    color: #6b5b25;
    -webkit-text-fill-color: #6b5b25;
    margin-bottom:7px;
}
.ejar-filter-empty::after {
    content:'Aucun véhicule ne correspond à ce filtre';
    grid-column:1 / -1;
    color: #9f1239;
    -webkit-text-fill-color: #9f1239;
    font-weight:700;
    font-size:13px;
}
.ejar-table-toolbar {
    display:grid;
    grid-template-columns: minmax(220px, 1fr) auto;
    gap:10px;
    align-items:end;
    margin: 12px 0;
    padding: 12px;
    border-radius:18px;
    background:#fffaf0;
    border:1px solid rgba(212,175,55,.24);
}
.ejar-table-toolbar label { grid-column:1 / -1; margin-bottom:-2px; }
.ejar-table-count {
    white-space:nowrap;
    align-self:center;
    color: #111;
    -webkit-text-fill-color: #111;
    font-weight:800;
    background:#f1f5f9;
    border-radius:999px;
    padding: 10px 12px;
}

/* E-Jar v3.1.100 — bloc obsolète supprimé : doublon ancien garde-fou tableaux design-system */

/* E-Jar point 72 : les anciens blocs v3.1.26 à v3.1.28 ont été retirés de ce fichier.
   Leur rôle de finition visuelle est désormais intégré directement dans ejar-design-system.css
   et le responsive reste piloté par ejar-responsive-optimizations.css afin d'éviter les contradictions de largeur,
   d'entête, d'onglets actifs, de boutons et de tableaux entre bureau/tablette/mobile. */

/* =========================================================
   E-Jar point 84 — garde-fou visuel consolidé dans le design system
   Ancien fichier : assets/css/ejar-final-visual-guard.css
   ========================================================= */

/* E-Jar point 73 : garde-fou visuel uniquement ; le responsive/layout global reste piloté par ejar-responsive-optimizations.css. */
/*
 * E-Jar - Garde-fou visuel final consolidé.
 * Point 5 / v3.1.53 : fusion des anciennes couches final-visual-guard
 * auparavant chargées en wp_head/wp_footer avec priorités extrêmes.
 * Ordre conservé pour compatibilité visuelle.
 */


/* === Bloc consolidé : ancien garde-fou visuel final intégré au design system === */

/* E-Jar Mission 1 : ancien garde-fou visuel conservé sans redéfinition de variables. */
html body:has(.ejar-admin-nav),
html body:has(.ejar-dashboard),
html body:has(.ejar-home) {
    background: var(--ejar-page-gradient);
}

html body [class*="ejar-"] { box-sizing: border-box !important; }

/* Page d'accueil / landing : clair, premium, léger, pas de noir massif. */
html body .ejar-home,
html body .ejar-landing,
html body .ejar-home-section {
    background: var(--ejar-page-gradient);
    color: var(--ejar-ink);
    -webkit-text-fill-color: initial;
}
html body .ejar-home :is(h1,h2,h3,h4,p,span,strong,li,div),
html body .ejar-landing :is(h1,h2,h3,h4,p,span,strong,li,div) {
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    text-shadow: none;
}
html body .ejar-gold-text,
html body .ejar-home .ejar-gold-text,
html body .ejar-landing .ejar-gold-text {
    background: var(--ejar-gold-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}

/* Conteneurs principaux : fond clair premium et centrage propre. */
html body .ejar-dashboard,
html body .ejar-parc-dashboard,
html body .ejar-sorties-page,
html body .ejar-agence-dashboard,
html body .ejar-client-dashboard,
html body .ejar-admin-page-shell {
    margin-top: 26px;
    margin-bottom: 36px;
    padding: clamp(18px, 2.4vw, 34px);
    border-radius: clamp(24px, 2.5vw, 34px);
    background: var(--ejar-soft-gold-gradient);
    border: 1px solid var(--ejar-line);
    box-shadow: var(--ejar-shadow-strong);
    color: var(--ejar-ink);
    -webkit-text-fill-color: initial;
}
html body .ejar-dashboard .ejar-dashboard,
html body .ejar-dashboard .ejar-agence-dashboard,
html body .ejar-dashboard .ejar-client-dashboard {
    margin: 22px 0;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
}

/* Navigation Gestion E-Jar : centrée, sticky propre, élégante. */
html body .ejar-admin-nav-sticky-holder {
    width: 100%;
    max-width: 1380px;
    margin-left: auto;
    margin-right: auto;
}
html body .ejar-admin-nav {
    width: 100%;
    max-width: 1380px;
    margin: 18px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px;
    border-radius: 26px;
    background: rgba(255,255,255,.94);
    border: 1px solid var(--ejar-line);
    box-shadow: 0 18px 48px rgba(40,30,12,.10);
    backdrop-filter: blur(14px);
}
/* Positionnement du menu flottant volontairement laissé à ejar-responsive-optimizations.css + JS. */
html body .ejar-admin-nav-brand {
    display: inline-flex !important;
    align-items: center;
    gap: 9px !important;
    padding: 10px 16px;
    border-radius: 999px;
    background: linear-gradient(135deg, #050505 0%, #171717 70%, #332405 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border: 1px solid rgba(212,175,55,.45);
    box-shadow: 0 12px 30px rgba(0,0,0,.16);
}
html body .ejar-admin-nav-brand img { height: 28px !important; width: auto; }
html body .ejar-admin-nav-brand * { color: #fff; -webkit-text-fill-color: #fff; }

/* Entêtes : fond clair/or, texte foncé, plus doux. */
html body .ejar-dashboard-header,
html body .ejar-page-hero,
html body .ejar-agence-hero,
html body .ejar-client-hero {
    position: relative;
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 116px;
    margin: 0 0 24px;
    padding: clamp(22px, 3vw, 42px);
    border-radius: 30px;
    background: linear-gradient(135deg, #ffffff 0%, #fffaf0 58%, #f3dfad 100%);
    border: 1px solid rgba(212,175,55,.38);
    box-shadow: var(--ejar-shadow-soft);
    overflow: hidden;
    color: var(--ejar-ink);
    -webkit-text-fill-color: initial;
}
html body .ejar-dashboard-header::before,
html body .ejar-page-hero::before,
html body .ejar-agence-hero::before,
html body .ejar-client-hero::before {
    content: "";
    position: absolute;
    left: 28px;
    right: 28px;
    top: 0;
    height: 5px;
    border-radius: 0 0 999px 999px;
    background: var(--ejar-gold-gradient);
}
html body .ejar-dashboard-header :is(h1,h2,h3,p,span,strong,small,div),
html body .ejar-page-hero :is(h1,h2,h3,p,span,strong,small,div),
html body .ejar-agence-hero :is(h1,h2,h3,p,span,strong,small,div),
html body .ejar-client-hero :is(h1,h2,h3,p,span,strong,small,div) {
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    text-shadow: none;
}
html body .ejar-dashboard-header h1,
html body .ejar-page-hero h1,
html body .ejar-agence-hero h1,
html body .ejar-client-hero h1 {
    margin: 0 0 8px;
    font-size: clamp(28px, 4vw, 50px);
    line-height: 1.04;
    font-weight: 950;
    letter-spacing: -.04em;
}
html body .ejar-dashboard-header p,
html body .ejar-page-hero p,
html body .ejar-agence-hero p,
html body .ejar-client-hero p {
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: clamp(14px, 1.4vw, 18px);
    line-height: 1.55;
    margin: 0;
}
html body .ejar-page-hero-icon {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    display: grid;
    place-items: center;
    border-radius: 22px;
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    box-shadow: 0 16px 34px rgba(212,175,55,.24);
    font-size: 30px;
    font-weight: 900;
}

/* Blocs et cartes. */
html body .ejar-card,
html body .ejar-section,
html body .ejar-form,
html body .ejar-dashboard .filter-bar,
html body .ejar-admin-page-shell .filter-bar,
html body .ejar-agence-page-shell .filter-bar,
html body .ejar-client-page-shell .filter-bar,
html body .ejar-control-center,
html body .ejar-tool-section,
html body .ejar-subtabs-card,
html body .ejar-parc-tabs-card,
html body .ejar-parc-search-card,
html body .ejar-smart-filter-panel,
html body .ejar-sorties-panel,
html body .ejar-agence-filter-panel,
html body .ejar-agence-account-section,
html body .ejar-agence-account-detail,
html body .ejar-client-panel,
html body .ejar-stat-card,
html body .ejar-tool-card,
html body .ejar-agence-stat,
html body .ejar-client-kpi,
html body .ejar-agence-account-card,
html body .ejar-agence-priority-box,
html body .ejar-agence-quick-card,
html body .ejar-client-action-card,
html body .ejar-action-card-light,
html body .ejar-contrats-legal-details,
html body .ejar-contrats-intro {
    background: var(--ejar-panel-gradient);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    border: 1px solid var(--ejar-line);
    border-radius: 24px;
    box-shadow: var(--ejar-shadow-soft);
    text-shadow: none;
}
html body .ejar-card :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,td,th,div),
html body .ejar-section :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,td,th,div),
html body .ejar-form :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,td,th,div),
html body .ejar-stat-card :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,div),
html body .ejar-tool-card :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,div),
html body .ejar-agence-stat :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,div),
html body .ejar-client-kpi :is(h1,h2,h3,h4,h5,h6,p,span,strong,small,label,li,div) {
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    text-shadow: none;
}
html body .ejar-muted,
html body .ejar-card small,
html body .ejar-section small,
html body .ejar-agence-stat-title,
html body .ejar-agence-account-meta,
html body .ejar-client-kpi small,
html body .ejar-tool-card small {
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
}

/* Fonds colorés métier : toujours lisibles. */
html body .ejar-agence-stat-success,
html body .ejar-client-kpi-success,
html body .ejar-agence-account-card-success,
html body .ejar-status-success,
html body .ejar-alert-success {
    background: linear-gradient(180deg, #ffffff 0%, #ecfdf5 100%);
    border-color: rgba(22,163,74,.30);
    border-left: 6px solid var(--ejar-green);
    color: #12301e;
    -webkit-text-fill-color: #12301e;
}
html body .ejar-agence-stat-danger,
html body .ejar-client-kpi-danger,
html body .ejar-agence-account-card-danger,
html body .ejar-status-danger,
html body .ejar-alert-error,
html body .ejar-alert-danger {
    background: linear-gradient(180deg, #ffffff 0%, #fff1f2 100%);
    border-color: rgba(220,38,38,.30);
    border-left: 6px solid var(--ejar-red);
    color: #3b0a0a;
    -webkit-text-fill-color: #3b0a0a;
}
html body .ejar-agence-stat-warning,
html body .ejar-client-kpi-warning,
html body .ejar-agence-account-card-warning,
html body .ejar-status-warning,
html body .ejar-alert-warning {
    background: linear-gradient(180deg, #ffffff 0%, #fffbeb 100%);
    border-color: rgba(245,158,11,.32);
    border-left: 6px solid var(--ejar-orange);
    color: #3d2600;
    -webkit-text-fill-color: #3d2600;
}
html body :is(.ejar-alert-success,.ejar-alert-error,.ejar-alert-danger,.ejar-alert-warning,.ejar-agence-stat-success,.ejar-agence-stat-danger,.ejar-agence-stat-warning) * {
    color: inherit;
    -webkit-text-fill-color: inherit;
}

/* Formulaires. */
html body .ejar-form input,
html body .ejar-form select,
html body .ejar-form textarea,
html body .ejar-card input,
html body .ejar-card select,
html body .ejar-card textarea,
html body .ejar-section input,
html body .ejar-section select,
html body .ejar-section textarea,
html body .ejar-parc-search,
html body #ejar_facture_vehicule_search,
html body [id^="ejar_livre_search_"] {
    width: 100% !important;
    max-width: 100% !important;
    min-height: 46px !important;
    border: 1px solid rgba(185,135,34,.32);
    border-radius: 14px;
    background: #ffffff;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.85);
    text-shadow: none;
}
html body .ejar-form input::placeholder,
html body .ejar-form textarea::placeholder,
html body .ejar-card input::placeholder,
html body .ejar-card textarea::placeholder {
    color: #8a8173;
    -webkit-text-fill-color: #8a8173;
}
html body .ejar-form input:focus,
html body .ejar-form select:focus,
html body .ejar-form textarea:focus,
html body .ejar-card input:focus,
html body .ejar-card select:focus,
html body .ejar-card textarea:focus {
    outline: none;
    border-color: var(--ejar-gold-2);
    box-shadow: 0 0 0 4px rgba(212,175,55,.18);
}

/* Boutons / onglets. */
html body .ejar-admin-nav a,
html body .ejar-subtab,
html body a.ejar-subtab,
html body button.ejar-subtab,
html body .ejar-edit-tab,
html body .ejar-parc-tab,
html body .ejar-button-light,
html body a.ejar-button-light,
html body button.ejar-button-light,
html body .ejar-action-card-light {
    background: linear-gradient(180deg, #ffffff 0%, #f9f2e4 100%);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    border: 1px solid rgba(185,135,34,.34);
    border-radius: 999px;
    text-decoration: none;
    text-shadow: none;
    box-shadow: 0 8px 20px rgba(40,30,12,.05);
}
html body :is(.ejar-admin-nav a,.ejar-subtab,.ejar-edit-tab,.ejar-parc-tab,.ejar-button-light,.ejar-action-card-light) * {
    color: inherit;
    -webkit-text-fill-color: inherit;
}
html body .ejar-admin-nav a:hover,
html body .ejar-subtab:hover,
html body .ejar-edit-tab:hover,
html body .ejar-parc-tab:hover,
html body .ejar-button-light:hover,
html body .ejar-action-card-light:hover,
html body .ejar-agence-quick-card:hover,
html body .ejar-client-action-card:hover {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.70);
    box-shadow: 0 14px 34px rgba(185,135,34,.18);
    transform: translateY(-1px) !important;
}
html body :is(.ejar-admin-nav a:hover,.ejar-subtab:hover,.ejar-edit-tab:hover,.ejar-parc-tab:hover,.ejar-button-light:hover,.ejar-action-card-light:hover,.ejar-agence-quick-card:hover,.ejar-client-action-card:hover) * {
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body .ejar-admin-nav a.active,
html body .ejar-admin-nav a.is-active,
html body .ejar-subtab.is-active,
html body .ejar-subtab.active,
html body a.ejar-subtab.is-active,
html body button.ejar-subtab.is-active,
html body .ejar-edit-tab.is-active,
html body .ejar-edit-tab.active,
html body .ejar-parc-tab.is-active,
html body .ejar-parc-tab.active,
html body .ejar-selected,
html body :where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [aria-selected="true"] {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.78);
    box-shadow: 0 12px 30px rgba(212,175,55,.24), inset 0 1px 0 rgba(255,255,255,.55);
    text-shadow: none;
}
html body :is(.ejar-admin-nav a.active,.ejar-admin-nav a.is-active,.ejar-subtab.is-active,.ejar-subtab.active,.ejar-edit-tab.is-active,.ejar-edit-tab.active,.ejar-parc-tab.is-active,.ejar-parc-tab.active,.ejar-selected,:where(.ejar-dashboard,.ejar-admin-page-shell,.ejar-agence-page-shell,.ejar-client-page-shell,.ejar-client-page-shell) [aria-selected="true"]) * {
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body .ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button),
html body a.ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button),
html body button.ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button),
html body input[type="submit"].ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button),
html body .ejar-form button[type="submit"]:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button) {
    background: linear-gradient(135deg, #111111 0%, #242424 70%, #3a2a06 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border: 1px solid rgba(212,175,55,.48);
    border-radius: 14px;
    font-weight: 850;
    text-decoration: none;
    text-shadow: none;
    box-shadow: 0 12px 28px rgba(0,0,0,.16);
}
html body :is(.ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button),.ejar-form button[type="submit"]:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button)) * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}
html body .ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button):hover,
html body .ejar-form button[type="submit"]:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button):hover {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body :is(.ejar-button:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button):hover,.ejar-form button[type="submit"]:not(.ejar-button-light):not(.ejar-button-danger):not(.ejar-relance-button):not(.ejar-reset-button):hover) * {
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body .ejar-button-danger,
html body .ejar-relance-button,
html body .ejar-reset-button,
html body a.ejar-button-danger,
html body a.ejar-relance-button,
html body a.ejar-reset-button,
html body button.ejar-button-danger,
html body button.ejar-relance-button,
html body button.ejar-reset-button,
html body input.ejar-button-danger,
html body input.ejar-reset-button {
    background: linear-gradient(135deg, var(--ejar-red-dark), var(--ejar-red));
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: #7f1d1d;
}
html body :is(.ejar-button-danger,.ejar-relance-button,.ejar-reset-button) * { color: #fff; -webkit-text-fill-color: #fff; }

/* Contrats : boutons de formulaire propres. */
html body .ejar-contrats-toggle-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding: 12px;
    margin: 10px 0 20px;
    background: rgba(255,250,240,.92);
    border: 1px solid rgba(185,135,34,.26);
    border-radius: 20px;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
}
html body .ejar-contrats-toggle-row > label,
html body .ejar-contrats-annexes-grid label {
    display: inline-flex !important;
    align-items: center;
    gap: 8px !important;
    min-height: 44px;
    padding: 10px 16px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid rgba(185,135,34,.32);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(40,30,12,.05);
}
html body .ejar-contrats-toggle-row > label:hover,
html body .ejar-contrats-annexes-grid label:hover,
html body .ejar-contrats-toggle-row > label:has(input:checked),
html body .ejar-contrats-annexes-grid label:has(input:checked) {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.78);
}
html body .ejar-contrats-toggle-row input[type="radio"],
html body .ejar-contrats-annexes-grid input[type="checkbox"] {
    width: auto;
    min-height: auto;
    accent-color: var(--ejar-gold-2);
}


/* E-Jar v3.1.100 — bloc obsolète supprimé : ancien final visual guard tableaux/couleurs héritées */
@media (min-width: 783px) {
    html body .ejar-finance-col-vehicule,
    html body .ejar-finance-col-client,
    html body .ejar-finance-col-email,
    html body .ejar-finance-col-societe,
    html body .ejar-finance-col-solde { min-width: 140px; }
}

/* Badges. */
html body .ejar-societe-badge,
html body .ejar-phone,
html body .ejar-muted-value,
html body .ejar-status-neutral,
html body .ejar-badge,
html body .ejar-balance-badge {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 6px !important;
    padding: 7px 14px;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid #d8dde5;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-weight: 800;
    line-height: 1.2;
    text-shadow: none;
}

html body .ejar-badge-success {
    background: var(--ejar-success-soft, #dcfce7);
    color: var(--ejar-success-dark, #065f46);
    -webkit-text-fill-color: var(--ejar-success-dark, #065f46);
    border-color: var(--ejar-success-border, #bbf7d0);
}

html body .ejar-badge-danger {
    background: var(--ejar-danger-soft, #fee2e2);
    color: var(--ejar-danger-dark, #7f1d1d);
    -webkit-text-fill-color: var(--ejar-danger-dark, #7f1d1d);
    border-color: var(--ejar-danger-border, #fecaca);
}

html body .ejar-badge-warning {
    background: var(--ejar-warning-soft, #fef3c7);
    color: var(--ejar-warning-dark, #78350f);
    -webkit-text-fill-color: var(--ejar-warning-dark, #78350f);
    border-color: var(--ejar-warning-border, #fde68a);
}

html body .ejar-badge-info {
    background: var(--ejar-info-soft, #e0f2fe);
    color: var(--ejar-info, #005a8d);
    -webkit-text-fill-color: var(--ejar-info, #005a8d);
    border-color: var(--ejar-info-border, #bae6fd);
}

html body .ejar-badge-neutral {
    background: var(--ejar-neutral-soft, #f8fafc);
    color: var(--ejar-muted, #667085);
    -webkit-text-fill-color: var(--ejar-muted, #667085);
    border-color: var(--ejar-neutral-border, #d8dde5);
}

/* Grilles. */
html body .ejar-stats-grid,
html body .ejar-stats-grid-v2,
html body .ejar-tool-grid,
html body .ejar-agence-premium-summary,
html body .ejar-agence-quick-grid,
html body .ejar-agence-account-grid,
html body .ejar-client-kpi-grid,
html body .ejar-client-action-grid,
html body .ejar-contrats-stats-grid,
html body .ejar-contrats-principles,
html body .ejar-form-grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
}
html body .ejar-admin-control-dashboard .ejar-stat-card,
html body .ejar-admin-control-dashboard .ejar-tool-card {
    min-height: 150px !important;
    padding: 22px;
    border-bottom: 5px solid var(--ejar-gold-2);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
html body .ejar-admin-control-dashboard .ejar-stat-card:hover,
html body .ejar-admin-control-dashboard .ejar-tool-card:hover {
    transform: translateY(-2px) !important;
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
}
html body :is(.ejar-admin-control-dashboard .ejar-stat-card:hover,.ejar-admin-control-dashboard .ejar-tool-card:hover) * { color: #111; -webkit-text-fill-color: #111; }

/* Responsive tablette/mobile. */







/* === Source legacy : assets/css/final-visual-guard/final-subtabs-footer-guard-v3134.css === */

/* E-Jar - ejar-subtabs-footer-guard-v3134, extrait du PHP au point 28. */
html body .ejar-subtabs .ejar-subtab,
html body .ejar-subtabs a.ejar-subtab,
html body .ejar-subtabs button.ejar-subtab,
html body .ejar-dashboard .ejar-subtabs .ejar-subtab,
html body .ejar-card .ejar-subtabs .ejar-subtab,
html body .ejar-admin-page-shell .ejar-subtabs .ejar-subtab,
html body .ejar-agence-dashboard .ejar-subtabs .ejar-subtab,
html body .ejar-client-dashboard .ejar-subtabs .ejar-subtab {
    background: linear-gradient(180deg, #ffffff 0%, #f9f2e4 100%);
    color: #171717;
    -webkit-text-fill-color: #171717;
    border: 1px solid rgba(185,135,34,.34);
    text-shadow: none;
}
html body .ejar-subtabs .ejar-subtab *,
html body .ejar-subtabs a.ejar-subtab *,
html body .ejar-subtabs button.ejar-subtab * {
    color: inherit;
    -webkit-text-fill-color: inherit;
    text-shadow: none;
}
html body .ejar-subtabs .ejar-subtab:hover,
html body .ejar-subtabs a.ejar-subtab:hover,
html body .ejar-subtabs button.ejar-subtab:hover,
html body .ejar-subtabs .ejar-subtab:focus,
html body .ejar-subtabs a.ejar-subtab:focus,
html body .ejar-subtabs button.ejar-subtab:focus,
html body .ejar-subtabs .ejar-subtab:focus-visible,
html body .ejar-subtabs a.ejar-subtab:focus-visible,
html body .ejar-subtabs button.ejar-subtab:focus-visible {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.72);
    box-shadow: 0 14px 34px rgba(185,135,34,.20);
    text-shadow: none;
}
html body .ejar-subtabs .ejar-subtab:hover *,
html body .ejar-subtabs a.ejar-subtab:hover *,
html body .ejar-subtabs button.ejar-subtab:hover *,
html body .ejar-subtabs .ejar-subtab:focus *,
html body .ejar-subtabs a.ejar-subtab:focus *,
html body .ejar-subtabs button.ejar-subtab:focus * {
    color: #111111;
    -webkit-text-fill-color: #111111;
    text-shadow: none;
}
html body .ejar-subtabs .ejar-subtab.is-active,
html body .ejar-subtabs a.ejar-subtab.is-active,
html body .ejar-subtabs button.ejar-subtab.is-active,
html body .ejar-subtabs .ejar-subtab.active,
html body .ejar-subtabs a.ejar-subtab.active,
html body .ejar-subtabs button.ejar-subtab.active,
html body .ejar-dashboard .ejar-subtabs .ejar-subtab.is-active,
html body .ejar-card .ejar-subtabs .ejar-subtab.is-active,
html body .ejar-admin-page-shell .ejar-subtabs .ejar-subtab.is-active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.78);
    box-shadow: 0 12px 30px rgba(212,175,55,.24), inset 0 1px 0 rgba(255,255,255,.55);
    text-shadow: none;
}
html body .ejar-subtabs .ejar-subtab.is-active *,
html body .ejar-subtabs a.ejar-subtab.is-active *,
html body .ejar-subtabs button.ejar-subtab.is-active *,
html body .ejar-subtabs .ejar-subtab.active *,
html body .ejar-subtabs a.ejar-subtab.active *,
html body .ejar-subtabs button.ejar-subtab.active * {
    color: #111111;
    -webkit-text-fill-color: #111111;
    text-shadow: none;
}
/* Boutons internes des zones Création & affiliation et Livre de compte qui peuvent hériter d'un ancien style sombre. */
html body .ejar-card .ejar-button.is-active,
html body .ejar-card button.is-active,
html body .ejar-card a.is-active:not(.ejar-admin-nav-brand),
html body .ejar-form .ejar-button.is-active,
html body .ejar-form button.is-active {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    text-shadow: none;
}
html body .ejar-card .ejar-button.is-active *,
html body .ejar-card button.is-active *,
html body .ejar-card a.is-active:not(.ejar-admin-nav-brand) *,
html body .ejar-form .ejar-button.is-active *,
html body .ejar-form button.is-active * {
    color: #111111;
    -webkit-text-fill-color: #111111;
    text-shadow: none;
}


/* v3.1.34 — correction du sous-menu flottant au survol + relances rouges lisibles. */
html body .ejar-admin-nav.ejar-admin-nav-fixed a:hover,
html body .ejar-admin-nav.ejar-admin-nav-fixed a:focus,
html body .ejar-admin-nav.ejar-admin-nav-fixed a:focus-visible,
html body .ejar-admin-nav.is-sticky-floating a:hover,
html body .ejar-admin-nav.is-sticky-floating a:focus,
html body .ejar-admin-nav.is-sticky-floating a:focus-visible,
html body .ejar-admin-nav a:hover,
html body .ejar-admin-nav a:focus,
html body .ejar-admin-nav a:focus-visible {
    background: var(--ejar-gold-gradient);
    color: #111111;
    -webkit-text-fill-color: #111111;
    border-color: rgba(122,86,18,.76);
    text-shadow: none;
}
html body .ejar-admin-nav.ejar-admin-nav-fixed a:hover *,
html body .ejar-admin-nav.ejar-admin-nav-fixed a:focus *,
html body .ejar-admin-nav.ejar-admin-nav-fixed a:focus-visible *,
html body .ejar-admin-nav.is-sticky-floating a:hover *,
html body .ejar-admin-nav.is-sticky-floating a:focus *,
html body .ejar-admin-nav.is-sticky-floating a:focus-visible *,
html body .ejar-admin-nav a:hover *,
html body .ejar-admin-nav a:focus *,
html body .ejar-admin-nav a:focus-visible * {
    color: #111111;
    -webkit-text-fill-color: #111111;
    text-shadow: none;
}

html body .ejar-admin-nav a[href*="relance"],
html body .ejar-admin-nav a[href*="relances"],
html body .ejar-admin-nav .ejar-relance-button,
html body .ejar-relance-button,
html body a.ejar-relance-button,
html body button.ejar-relance-button,
html body .ejar-button-danger,
html body a.ejar-button-danger,
html body button.ejar-button-danger,
html body .ejar-reset-button,
html body a.ejar-reset-button,
html body button.ejar-reset-button {
    background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 48%, #ef4444 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: rgba(127,29,29,.85);
    text-shadow: none;
}
html body .ejar-admin-nav a[href*="relance"] *,
html body .ejar-admin-nav a[href*="relances"] *,
html body .ejar-admin-nav .ejar-relance-button *,
html body .ejar-relance-button *,
html body a.ejar-relance-button *,
html body button.ejar-relance-button *,
html body .ejar-button-danger *,
html body a.ejar-button-danger *,
html body button.ejar-button-danger *,
html body .ejar-reset-button *,
html body a.ejar-reset-button *,
html body button.ejar-reset-button * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    text-shadow: none;
}
html body .ejar-admin-nav a[href*="relance"]:hover,
html body .ejar-admin-nav a[href*="relance"]:focus,
html body .ejar-admin-nav a[href*="relances"]:hover,
html body .ejar-admin-nav a[href*="relances"]:focus,
html body .ejar-relance-button:hover,
html body a.ejar-relance-button:hover,
html body button.ejar-relance-button:hover,
html body .ejar-button-danger:hover,
html body a.ejar-button-danger:hover,
html body button.ejar-button-danger:hover {
    background: linear-gradient(135deg, #450a0a 0%, #991b1b 48%, #dc2626 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border-color: rgba(69,10,10,.92);
}
html body .ejar-admin-nav a[href*="relance"]:hover *,
html body .ejar-admin-nav a[href*="relance"]:focus *,
html body .ejar-admin-nav a[href*="relances"]:hover *,
html body .ejar-admin-nav a[href*="relances"]:focus *,
html body .ejar-relance-button:hover *,
html body a.ejar-relance-button:hover *,
html body button.ejar-relance-button:hover *,
html body .ejar-button-danger:hover *,
html body a.ejar-button-danger:hover *,
html body button.ejar-button-danger:hover * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}


/* v3.1.35 — Tableau financier : relances rouges lisibles partout. */
html body .ejar-dashboard .ejar-finance-relance-card,
html body .ejar-dashboard a.ejar-finance-relance-card,
html body .ejar-dashboard a.ejar-finance-relance-card:visited {
    background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 48%, #ef4444 100%);
    border-color: rgba(127,29,29,.85);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    text-shadow: none;
}
html body .ejar-dashboard .ejar-finance-relance-card *,
html body .ejar-dashboard a.ejar-finance-relance-card * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    text-shadow: none;
}
html body .ejar-dashboard .ejar-finance-relance-card:hover,
html body .ejar-dashboard a.ejar-finance-relance-card:hover,
html body .ejar-dashboard .ejar-finance-relance-card:focus,
html body .ejar-dashboard a.ejar-finance-relance-card:focus {
    background: linear-gradient(135deg, #450a0a 0%, #991b1b 48%, #dc2626 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}
html body .ejar-dashboard .ejar-finance-relance-card:hover *,
html body .ejar-dashboard a.ejar-finance-relance-card:hover *,
html body .ejar-dashboard .ejar-finance-relance-card:focus *,
html body .ejar-dashboard a.ejar-finance-relance-card:focus * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 900;
}
html body .ejar-dashboard .ejar-relance-button,
html body .ejar-dashboard button.ejar-relance-button,
html body .ejar-dashboard a.ejar-relance-button,
html body .ejar-dashboard input[type="submit"].ejar-relance-button {
    background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 48%, #ef4444 100%);
    border-color: rgba(127,29,29,.85);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 800;
    text-shadow: none;
}
html body .ejar-dashboard .ejar-relance-button *,
html body .ejar-dashboard button.ejar-relance-button *,
html body .ejar-dashboard a.ejar-relance-button * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    text-shadow: none;
}
html body .ejar-dashboard .ejar-relance-button:hover,
html body .ejar-dashboard button.ejar-relance-button:hover,
html body .ejar-dashboard a.ejar-relance-button:hover,
html body .ejar-dashboard input[type="submit"].ejar-relance-button:hover {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 900;
}
html body .ejar-dashboard .ejar-relance-button:hover *,
html body .ejar-dashboard button.ejar-relance-button:hover *,
html body .ejar-dashboard a.ejar-relance-button:hover * {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 900;
}



/* E-Jar point 65 : ancien bloc responsive contradictoire supprimé.
   La logique mobile/tablette/desktop est centralisée dans ejar-responsive-optimizations.css. */

/* Grilles de cartes : meilleure occupation de la largeur disponible. */
html body .ejar-stats-grid,
html body .ejar-stats-grid-v2,
html body .ejar-dashboard-grid,
html body .ejar-actions-grid,
html body .ejar-tool-grid,
html body .ejar-agence-premium-summary,
html body .ejar-agence-quick-grid,
html body .ejar-agence-account-grid,
html body .ejar-client-véhicules-grid,
html body .ejar-client-finance-grid,
html body .ejar-client-alert-grid {
    width: 100% !important;
    max-width: 100% !important;
}

html body .ejar-client-info-grid,
html body .ejar-client-info-grid.compact {
    width: 100% !important;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)) !important;
    gap: 12px;
}

html body .ejar-client-info-grid > div,
html body .ejar-agence-account-card,
html body .ejar-client-véhicule-card,
html body .ejar-client-account-card,
html body .ejar-stat-card,
html body .ejar-tool-card,
html body .ejar-action-card-light {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
}





/* E-Jar point 65 : ancien bloc responsive contradictoire supprimé.
   La logique mobile/tablette/desktop est centralisée dans ejar-responsive-optimizations.css. */

/* === Source legacy : assets/css/final-visual-guard/final-layout-readability-guard-v3137.css === */

/* E-Jar - ejar-layout-readability-guard-v3137, extrait du PHP au point 28. */
/* ==========================================================
   E-Jar v3.1.37 — Lisibilité générale badges / boutons
   ========================================================== */


/* E-Jar v3.1.100 — bloc obsolète supprimé : ancien readability guard badges/statuts */

/* E-Jar point 65 : ancien forçage global des actions supprimé.
   Les boutons/actions sont maintenant pilotés par la couche responsive unique. */

/* ==========================================================
   E-Jar point 63 - Ancien mode carte desktop supprimé.
   Ce bloc transformait les tableaux larges en cartes au-dessus de
   1101px / 1400px. Il est volontairement neutralisé pour que le
   desktop reste toujours un vrai tableau.
   ========================================================== */






/* === Source legacy : assets/css/final-visual-guard/final-status-sorties-width-guard-v3138.css === */

/* E-Jar - ejar-status-sorties-width-guard-v3138, extrait du PHP au point 28. */
/* ==========================================================
   E-Jar v3.1.38 — Statuts positifs différenciés
   ========================================================== */

/* En règle : vert doux, lisible, positif mais pas trop fort. */
html body .ejar-status-neutral,
html body .ejar-dashboard .ejar-status-neutral,
html body .ejar-table .ejar-status-neutral,
html body span.ejar-status-neutral {
    background: #eaf8ef;
    color: #166534;
    -webkit-text-fill-color: #166534;
    border: 1px solid #b7e4c7;
    box-shadow: 0 8px 18px rgba(22, 101, 52, 0.10);
    font-weight: 900;
}

/* Payé : vert plus foncé que “En règle”. */
html body .ejar-dashboard .status-paid,
html body .ejar-admin-page-shell .status-paid,
html body .ejar-agence-page-shell .status-paid,
html body .ejar-client-page-shell .status-paid,
html body .ejar-badge-v2.status-paid,
html body .ejar-dashboard span.status-paid,
html body .ejar-admin-page-shell span.status-paid,
html body .ejar-agence-page-shell span.status-paid,
html body .ejar-client-page-shell span.status-paid,
html body .ejar-dashboard .status-paid,
html body .ejar-table .status-paid {
    background: #d1fae5;
    color: #065f46;
    -webkit-text-fill-color: #065f46;
    border: 1px solid #10b981;
    box-shadow: 0 8px 18px rgba(6, 95, 70, 0.14);
    font-weight: 950;
}

/* Trop-perçu / En avance : vert premium encore plus foncé. */
html body .ejar-dashboard .status-success,
html body .ejar-admin-page-shell .status-success,
html body .ejar-agence-page-shell .status-success,
html body .ejar-client-page-shell .status-success,
html body .ejar-badge-v2.status-success,
html body .ejar-status-success,
html body .ejar-dashboard span.status-success,
html body .ejar-admin-page-shell span.status-success,
html body .ejar-agence-page-shell span.status-success,
html body .ejar-client-page-shell span.status-success,
html body span.ejar-status-success,
html body .ejar-dashboard .status-success,
html body .ejar-dashboard .ejar-status-success,
html body .ejar-table .status-success,
html body .ejar-table .ejar-status-success {
    background: #064e3b;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    border: 1px solid #047857;
    box-shadow: 0 10px 22px rgba(6, 78, 59, 0.22);
    font-weight: 950;
}

html body .ejar-dashboard .status-success:hover,
html body .ejar-admin-page-shell .status-success:hover,
html body .ejar-agence-page-shell .status-success:hover,
html body .ejar-client-page-shell .status-success:hover,
html body .ejar-status-success:hover,
html body .ejar-badge-v2.status-success:hover {
    background: #022c22;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

/* ==========================================================
   E-Jar v3.1.92 — Dépenses véhicules & fiscalité : nettoyage des anciennes largeurs
   Les largeurs précises des tableaux Sorties sont maintenant centralisées dans
   assets/css/ejar-responsive-optimizations.css pour éviter les conflits.
   ========================================================== */

html body .ejar-sorties-wrap,
html body .ejar-sorties-panel,
html body .ejar-sorties-scroll {
    width: 100% !important;
    max-width: 100% !important;
}


/* E-Jar v3.1.100 — bloc obsolète supprimé : ancien message scroll horizontal sorties */

/* E-Jar point 65 : ancien bloc responsive contradictoire supprimé.
   La logique mobile/tablette/desktop est centralisée dans ejar-responsive-optimizations.css. */


/* E-Jar point 65 : garde-fou desktop point 63 supprimé et remplacé par la couche responsive unique. */

/* ==========================================================
   Mission 14 — Navigation admin front structurée par groupes
   ========================================================== */
html body .ejar-admin-nav.ejar-admin-nav-grouped {
    align-items: stretch;
    justify-content: flex-start;
    gap: 12px;
    padding: 12px;
}

html body .ejar-admin-nav-grouped .ejar-admin-nav-brand {
    align-self: stretch;
    min-height: 48px;
}

html body .ejar-admin-nav-groups {
    display: flex;
    flex: 1 1 720px;
    flex-wrap: wrap;
    align-items: stretch;
    justify-content: center;
    gap: 10px;
    min-width: 0;
}

html body .ejar-admin-nav-group {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 6px;
    border: 1px solid rgba(185,135,34,.22);
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(255,255,255,.94) 0%, rgba(249,242,228,.72) 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.70), 0 8px 20px rgba(40,30,12,.045);
}

html body .ejar-admin-nav-group.is-active-group {
    border-color: rgba(185,135,34,.48);
    background: linear-gradient(180deg, #ffffff 0%, #fff3d0 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.82), 0 12px 28px rgba(185,135,34,.12);
}

html body .ejar-admin-nav-group-title {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 9px;
    border-radius: 999px;
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: 10px;
    font-weight: 950;
    line-height: 1;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
    background: rgba(255,255,255,.70);
    border: 1px solid rgba(141,147,155,.14);
}

html body .ejar-admin-nav-group.is-active-group .ejar-admin-nav-group-title {
    color: #111111;
    -webkit-text-fill-color: #111111;
    background: var(--ejar-gold-gradient);
    border-color: rgba(122,86,18,.38);
}

html body .ejar-admin-nav-group-links {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

html body .ejar-admin-nav.ejar-admin-nav-grouped a.ejar-admin-nav-link {
    min-height: 36px;
    padding: 8px 12px;
    font-size: 12.5px;
    line-height: 1.12;
}

html body .ejar-admin-nav-group-home,
html body .ejar-admin-nav-group-outils {
    flex: 0 0 auto;
}

/* Mission 15 — écritures financières verrouillées */
html body .ejar-inline-edit-grid-locked {
    align-items: center;
    background: linear-gradient(135deg, rgba(247,242,232,.86) 0%, rgba(255,255,255,.96) 100%);
    border: 1px dashed var(--ejar-border);
    border-radius: var(--ejar-radius-sm);
    color: var(--ejar-ink);
}

html body .ejar-inline-edit-grid-locked .ejar-nowrap-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

html body .ejar-inline-edit-grid-locked .ejar-muted-small {
    display: inline-block;
    max-width: 190px;
    color: var(--ejar-muted);
}


/* ==========================================================
   Mission 17C — UX admin : menu sticky compact + Parc propre
   ========================================================== */
html body .ejar-admin-nav.ejar-admin-nav-grouped {
    transition: padding .18s ease, border-radius .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped {
    max-height: 70px;
    min-height: 0;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 999px;
    background: rgba(255,255,255,.94);
    border-color: rgba(201,151,46,.34);
    box-shadow: 0 14px 34px rgba(15,15,15,.14);
    overflow: hidden;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-brand,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-brand {
    min-height: 38px;
    align-self: center;
    padding: 7px 10px;
    gap: 6px;
    flex: 0 0 auto;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-brand img,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-brand img {
    height: 20px !important;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-brand span,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-brand span {
    font-size: 11px;
    letter-spacing: .02em;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-groups,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-groups {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    padding-bottom: 2px;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-group,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-group {
    flex: 0 0 auto;
    gap: 5px;
    padding: 3px;
    border-radius: 999px;
    background: rgba(247,242,232,.62);
    border-color: rgba(201,151,46,.16);
    box-shadow: none;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-group-title,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-group-title {
    min-height: 28px;
    padding: 0 7px;
    font-size: 0;
    letter-spacing: 0;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-group-title::first-letter,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-group-title::first-letter {
    font-size: 11px;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-group-links,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-group-links {
    flex-wrap: nowrap;
    gap: 4px;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped a.ejar-admin-nav-link,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped a.ejar-admin-nav-link {
    min-height: 30px;
    padding: 6px 9px;
    font-size: 11px;
    line-height: 1;
    white-space: nowrap;
    box-shadow: none;
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped a.ejar-admin-nav-link:not(.active):not(.is-active),
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped a.ejar-admin-nav-link:not(.active):not(.is-active) {
    background: rgba(255,255,255,.62);
}

html body .ejar-parc-vehicules-table {
    table-layout: fixed;
    min-width: 1120px;
}

html body .ejar-parc-vehicules-table th,
html body .ejar-parc-vehicules-table td {
    vertical-align: middle;
}

html body .ejar-parc-vehicules-table th:nth-child(1),
html body .ejar-parc-vehicules-table td:nth-child(1) { width: 24%; }
html body .ejar-parc-vehicules-table th:nth-child(2),
html body .ejar-parc-vehicules-table td:nth-child(2) { width: 15%; }
html body .ejar-parc-vehicules-table th:nth-child(3),
html body .ejar-parc-vehicules-table td:nth-child(3) { width: 13%; }
html body .ejar-parc-vehicules-table th:nth-child(4),
html body .ejar-parc-vehicules-table td:nth-child(4) { width: 15%; }
html body .ejar-parc-vehicules-table th:nth-child(5),
html body .ejar-parc-vehicules-table td:nth-child(5) { width: 9%; }
html body .ejar-parc-vehicules-table th:nth-child(6),
html body .ejar-parc-vehicules-table td:nth-child(6),
html body .ejar-parc-vehicules-table th:nth-child(7),
html body .ejar-parc-vehicules-table td:nth-child(7) { width: 7%; text-align: center; }
html body .ejar-parc-vehicules-table th:nth-child(8),
html body .ejar-parc-vehicules-table td:nth-child(8) { width: 14%; }
html body .ejar-parc-vehicules-table th:nth-child(9),
html body .ejar-parc-vehicules-table td:nth-child(9) { width: 12%; }

html body .ejar-parc-vehicule-title {
    display: block;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-weight: 900;
    line-height: 1.25;
}

html body .ejar-parc-vehicule-address,
html body .ejar-structure-detail {
    display: block;
    margin-top: 5px;
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: 12px;
    line-height: 1.35;
}

html body .ejar-structure-chip,
html body .ejar-count-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    border: 1px solid var(--ejar-border);
    background: var(--ejar-neutral-soft);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
}

html body .ejar-structure-chip-societe {
    background: rgba(201,151,46,.14);
    border-color: rgba(201,151,46,.34);
}

html body .ejar-structure-chip-direct {
    background: var(--ejar-info-soft);
    border-color: var(--ejar-info-border);
    color: var(--ejar-info);
    -webkit-text-fill-color: var(--ejar-info);
}

html body .ejar-structure-chip-missing {
    background: var(--ejar-danger-soft);
    border-color: var(--ejar-danger-border);
    color: var(--ejar-danger);
    -webkit-text-fill-color: var(--ejar-danger);
}

html body .ejar-count-pill {
    min-width: 34px;
    background: #fff;
    border-color: rgba(201,151,46,.22);
}

html body .ejar-parc-col-paiement {
    white-space: nowrap;
    font-weight: 900;
}

html body .ejar-actions-stack-compact {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
}

html body .ejar-button.ejar-button-compact {
    min-height: 30px;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 12px;
    line-height: 1;
    white-space: nowrap;
}

@media (max-width: 782px) {
    html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped,
    html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped {
        max-height: 62px;
        border-radius: 20px;
    }

    html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-grouped .ejar-admin-nav-brand span,
    html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-grouped .ejar-admin-nav-brand span {
        display: none;
    }
}



/* ==========================================================
   Mission 17D — Navigation off-canvas + harmonisation sous-pages admin
   ========================================================== */

/* Navigation : test off-canvas choisi pour libérer l'espace vertical. */
html body .ejar-admin-nav.ejar-admin-nav-offcanvas-mode,
html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-offcanvas-mode,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-offcanvas-mode {
    display: block;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
    max-height: none;
    min-height: 0;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 8px;
    border: 1px solid rgba(201,151,46,.28);
    border-radius: 999px;
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: 0 14px 34px rgba(15,15,15,.10), inset 0 1px 0 rgba(255,255,255,.72);
}

html body .ejar-admin-nav.ejar-admin-nav-fixed.ejar-admin-nav-offcanvas-mode .ejar-admin-nav-pill,
html body .ejar-admin-nav.is-sticky-floating.ejar-admin-nav-offcanvas-mode .ejar-admin-nav-pill {
    padding: 6px;
    box-shadow: 0 16px 38px rgba(15,15,15,.14), inset 0 1px 0 rgba(255,255,255,.76);
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 13px;
    gap: 8px;
    flex: 0 0 auto;
    border-radius: 999px;
    color: #fff;
    -webkit-text-fill-color: #fff;
    background: linear-gradient(135deg, #111 0%, #2a2114 55%, #111 100%);
    border: 1px solid rgba(201,151,46,.34);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.10);
    text-decoration: none;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-brand img {
    height: 22px !important;
    width: auto;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-brand span {
    color: #fff;
    -webkit-text-fill-color: #fff;
    font-size: 12px;
    font-weight: 950;
    letter-spacing: .02em;
    white-space: nowrap;
}

html body .ejar-admin-nav-current {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1.1;
}

html body .ejar-admin-nav-current-kicker {
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .10em;
    text-transform: uppercase;
}

html body .ejar-admin-nav-current strong {
    display: block;
    overflow: hidden;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-size: 14px;
    font-weight: 950;
    text-overflow: ellipsis;
    white-space: nowrap;
}

html body .ejar-admin-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 9px 15px;
    border: 0;
    border-radius: 999px;
    color: #15110a;
    -webkit-text-fill-color: #15110a;
    background: var(--ejar-gold-gradient);
    box-shadow: 0 10px 20px rgba(201,151,46,.18);
    cursor: pointer;
    font-size: 13px;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
}

html body .ejar-admin-nav-toggle:hover,
html body .ejar-admin-nav-toggle:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(201,151,46,.24);
    outline: none;
}

html body .ejar-admin-nav-toggle-icon {
    display: inline-flex;
    flex-direction: column;
    gap: 3px;
}

html body .ejar-admin-nav-toggle-icon i {
    display: block;
    width: 16px;
    height: 2px;
    border-radius: 999px;
    background: #15110a;
}

html body .ejar-admin-nav-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9997;
    background: rgba(17,17,17,.28);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .18s ease, visibility .18s ease;
}

html body .ejar-admin-nav-drawer {
    position: fixed;
    z-index: 9998;
    top: 24px;
    right: 24px;
    width: min(420px, calc(100vw - 28px));
    max-height: calc(100vh - 48px);
    overflow: auto;
    padding: 18px;
    border: 1px solid rgba(201,151,46,.26);
    border-radius: 28px;
    background: linear-gradient(180deg, rgba(255,255,255,.98) 0%, rgba(247,242,232,.96) 100%);
    box-shadow: 0 30px 80px rgba(15,15,15,.24);
    transform: translateX(calc(100% + 42px));
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform .22s ease, opacity .18s ease, visibility .18s ease;
}

html body.admin-bar .ejar-admin-nav-drawer {
    top: 56px;
    max-height: calc(100vh - 80px);
}

html body .ejar-admin-nav.is-offcanvas-open .ejar-admin-nav-backdrop {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

html body .ejar-admin-nav.is-offcanvas-open .ejar-admin-nav-drawer {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

html.ejar-admin-nav-open,
html body.ejar-admin-nav-open {
    overflow: hidden;
}

html body .ejar-admin-nav-drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--ejar-border);
}

html body .ejar-admin-nav-drawer-kicker {
    display: block;
    margin-bottom: 3px;
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: 10px;
    font-weight: 950;
    letter-spacing: .12em;
    text-transform: uppercase;
}

html body .ejar-admin-nav-drawer-head strong {
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-size: 20px;
    font-weight: 950;
}

html body .ejar-admin-nav-close {
    width: 42px;
    height: 42px;
    border: 1px solid var(--ejar-border);
    border-radius: 999px;
    background: #fff;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    cursor: pointer;
    font-size: 26px;
    font-weight: 500;
    line-height: 1;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-groups {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    flex: none;
    width: 100%;
    justify-content: stretch;
    align-items: stretch;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-group {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 13px;
    border-radius: 22px;
    background: rgba(255,255,255,.72);
    border: 1px solid rgba(201,151,46,.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.72);
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-group.is-active-group {
    background: linear-gradient(180deg, #fff 0%, #fff5dc 100%);
    border-color: rgba(201,151,46,.42);
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-group-title {
    justify-content: flex-start;
    min-height: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--ejar-muted);
    -webkit-text-fill-color: var(--ejar-muted);
    font-size: 11px;
    font-weight: 950;
    letter-spacing: .10em;
    text-transform: uppercase;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-group.is-active-group .ejar-admin-nav-group-title {
    color: var(--ejar-gold);
    -webkit-text-fill-color: var(--ejar-gold);
    background: transparent;
    border: 0;
}

html body .ejar-admin-nav-offcanvas-mode .ejar-admin-nav-group-links {
    display: grid;
    grid-template-columns: 1fr;
    gap: 7px;
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 42px;
    padding: 10px 12px;
    border-radius: 16px;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    background: rgba(255,255,255,.86);
    border: 1px solid rgba(17,17,17,.06);
    box-shadow: none;
    font-size: 13px;
    font-weight: 850;
    text-decoration: none;
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link:hover,
html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link:focus-visible {
    color: #15110a;
    -webkit-text-fill-color: #15110a;
    background: #fff8e6;
    border-color: rgba(201,151,46,.32);
    outline: none;
    transform: translateX(2px);
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link.active,
html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link.is-active {
    color: #15110a;
    -webkit-text-fill-color: #15110a;
    background: var(--ejar-gold-gradient);
    border-color: rgba(122,86,18,.30);
    box-shadow: 0 10px 20px rgba(201,151,46,.15);
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link-relances,
html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link-relances *,
html body .ejar-admin-nav-offcanvas-mode a[href*="relance"],
html body .ejar-admin-nav-offcanvas-mode a[href*="relance"] * {
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link-relances,
html body .ejar-admin-nav-offcanvas-mode a[href*="relance"] {
    background: linear-gradient(135deg, #b32d2e 0%, #8f1f24 100%) !important;
    border-color: rgba(143,31,36,.36) !important;
    box-shadow: 0 10px 22px rgba(179,45,46,.18) !important;
}

html body .ejar-admin-nav-offcanvas-mode a.ejar-admin-nav-link-relances:hover,
html body .ejar-admin-nav-offcanvas-mode a[href*="relance"]:hover {
    background: linear-gradient(135deg, #c93a3b 0%, #9f2328 100%) !important;
}

/* Harmonisation pages et sous-pages de Gestion E-Jar */
html body :where(.ejar-admin-page-shell, .ejar-admin-control-dashboard, .ejar-parc-dashboard, .ejar-financial-dashboard, .ejar-factures-dashboard, .ejar-pointage-dashboard, .ejar-contrats-dashboard, .ejar-edl-dashboard, .ejar-livre-compte-dashboard, .ejar-livre-compte-premium-dashboard) .ejar-card {
    border: 1px solid rgba(234,223,202,.94);
    border-radius: var(--ejar-radius);
    background: linear-gradient(180deg, #ffffff 0%, rgba(255,252,246,.98) 100%);
    box-shadow: var(--ejar-shadow-soft);
}

html body :where(.ejar-admin-page-shell, .ejar-admin-control-dashboard, .ejar-parc-dashboard) .ejar-card > h2:first-child,
html body :where(.ejar-admin-page-shell, .ejar-admin-control-dashboard, .ejar-parc-dashboard) .ejar-card > h3:first-child {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-weight: 950;
    letter-spacing: -.02em;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-responsive-table-wrap {
    width: 100%;
    border: 1px solid var(--ejar-border);
    border-radius: 22px;
    background: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.80);
    overflow-x: auto;
    overflow-y: hidden;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) table.ejar-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) table.ejar-table thead th {
    position: relative;
    padding: 15px 14px;
    color: #15110a;
    -webkit-text-fill-color: #15110a;
    background: linear-gradient(180deg, #fff8e6 0%, #f3e4c6 100%);
    border-bottom: 1px solid rgba(201,151,46,.28);
    font-size: 12px;
    font-weight: 950;
    letter-spacing: .035em;
    text-transform: uppercase;
    white-space: nowrap;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) table.ejar-table tbody td {
    padding: 14px;
    border-bottom: 1px solid rgba(234,223,202,.82);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    vertical-align: middle;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) table.ejar-table tbody tr:last-child td {
    border-bottom: 0;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) table.ejar-table tbody tr:hover td {
    background: rgba(247,242,232,.42);
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-actions-cell,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-parc-actions {
    min-width: 118px;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-actions-stack {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-actions-stack form {
    margin: 0;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-actions-stack .ejar-button,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-actions-cell .ejar-button {
    width: 100%;
    justify-content: center;
    min-height: 34px;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
    line-height: 1.05;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-table-control,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-table-control-md,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-table-control-sm,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) .ejar-table-control-xs,
html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) textarea.ejar-table-control {
    width: 100%;
    max-width: 100%;
    min-height: 38px;
    border: 1px solid rgba(234,223,202,.98);
    border-radius: 14px;
    background: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.76);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-size: 13px;
}

html body :where(.ejar-admin-page-shell, .ejar-parc-dashboard) textarea.ejar-table-control {
    min-height: 86px;
    resize: vertical;
}

html body .ejar-bulk-toolbar {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto;
    align-items: end;
    gap: 12px;
    margin: 14px 0 18px;
    padding: 14px;
    border: 1px solid var(--ejar-border);
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(247,242,232,.86) 0%, rgba(255,255,255,.96) 100%);
}

/* Parc : sous-menus et tableaux dédiés */
html body .ejar-parc-tabs-card {
    position: sticky;
    top: 12px;
    z-index: 15;
    padding: 10px;
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

html body.admin-bar .ejar-parc-tabs-card {
    top: 46px;
}

html body .ejar-parc-tabs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

html body .ejar-parc-tab {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(247,242,232,.72);
    border: 1px solid rgba(234,223,202,.88);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    font-weight: 850;
    text-decoration: none;
}

html body .ejar-parc-tab:hover,
html body .ejar-parc-tab:focus-visible {
    background: #fff8e6;
    border-color: rgba(201,151,46,.34);
    transform: translateY(-1px);
    outline: none;
}

html body .ejar-parc-tab.is-active,
html body .ejar-parc-tab.active {
    color: #15110a;
    -webkit-text-fill-color: #15110a;
    background: var(--ejar-gold-gradient);
    border-color: rgba(122,86,18,.30);
    box-shadow: 0 10px 20px rgba(201,151,46,.16);
}

html body .ejar-parc-table-wrap {
    margin-top: 12px;
}

html body .ejar-parc-table,
html body .ejar-documents-bulk-table {
    min-width: 980px;
}

html body .ejar-parc-vehicules-table {
    table-layout: fixed;
    min-width: 1160px;
}

html body .ejar-parc-vehicules-table th:nth-child(1),
html body .ejar-parc-vehicules-table td:nth-child(1) { width: 23%; }
html body .ejar-parc-vehicules-table th:nth-child(2),
html body .ejar-parc-vehicules-table td:nth-child(2) { width: 15%; }
html body .ejar-parc-vehicules-table th:nth-child(3),
html body .ejar-parc-vehicules-table td:nth-child(3) { width: 13%; }
html body .ejar-parc-vehicules-table th:nth-child(4),
html body .ejar-parc-vehicules-table td:nth-child(4) { width: 14%; }
html body .ejar-parc-vehicules-table th:nth-child(5),
html body .ejar-parc-vehicules-table td:nth-child(5) { width: 8%; }
html body .ejar-parc-vehicules-table th:nth-child(6),
html body .ejar-parc-vehicules-table td:nth-child(6),
html body .ejar-parc-vehicules-table th:nth-child(7),
html body .ejar-parc-vehicules-table td:nth-child(7) { width: 6%; text-align: center; }
html body .ejar-parc-vehicules-table th:nth-child(8),
html body .ejar-parc-vehicules-table td:nth-child(8) { width: 15%; }
html body .ejar-parc-vehicules-table th:nth-child(9),
html body .ejar-parc-vehicules-table td:nth-child(9) { width: 14%; }

html body .ejar-parc-col-vehicule,
html body .ejar-parc-col-structure,
html body .ejar-parc-col-client {
    overflow-wrap: anywhere;
}

html body .ejar-parc-col-statut {
    min-width: 150px;
}

html body .ejar-status-preview {
    margin-top: 8px;
}

html body .ejar-delete-button {
    background: linear-gradient(135deg, #b32d2e 0%, #8f1f24 100%) !important;
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
    border-color: rgba(143,31,36,.30) !important;
}

html body .ejar-delete-button * {
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
}

@media (max-width: 782px) {
    html body .ejar-admin-nav-current strong {
        font-size: 12px;
    }

    html body .ejar-admin-nav-current-kicker {
        font-size: 9px;
    }

    html body .ejar-admin-nav-toggle {
        min-height: 38px;
        padding: 8px 12px;
    }

    html body .ejar-admin-nav-toggle span:last-child {
        display: none;
    }

    html body .ejar-admin-nav-drawer {
        top: 12px;
        right: 12px;
        left: 12px;
        width: auto;
        max-height: calc(100vh - 24px);
        border-radius: 24px;
    }

    html body.admin-bar .ejar-admin-nav-drawer {
        top: 58px;
        max-height: calc(100vh - 70px);
    }

    html body .ejar-bulk-toolbar {
        grid-template-columns: 1fr;
    }

    html body .ejar-parc-tabs-card {
        position: relative;
        top: auto;
    }

    html body .ejar-parc-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    html body .ejar-parc-tab {
        white-space: nowrap;
    }
}

/* ==========================================================
   Mission 17E — correction mobile du menu off-canvas
   ========================================================== */
html body .ejar-admin-nav-backdrop[data-ejar-nav-portal="backdrop"] {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483000 !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

html body .ejar-admin-nav-backdrop[data-ejar-nav-portal="backdrop"].is-open {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] {
    position: fixed !important;
    z-index: 2147483001 !important;
    display: block !important;
    visibility: hidden;
    pointer-events: none;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"].is-open {
    transform: translate3d(0, 0, 0) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] .ejar-admin-nav-groups {
    display: grid !important;
    grid-template-columns: 1fr !important;
    width: 100% !important;
    gap: 12px !important;
    overflow: visible !important;
}

html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] .ejar-admin-nav-group,
html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] .ejar-admin-nav-group-links {
    display: grid !important;
    grid-template-columns: 1fr !important;
    width: 100% !important;
    overflow: visible !important;
}

html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] a.ejar-admin-nav-link {
    display: flex !important;
    width: 100% !important;
    white-space: normal !important;
}

@media (max-width: 782px) {
    html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] {
        top: max(10px, env(safe-area-inset-top)) !important;
        right: max(10px, env(safe-area-inset-right)) !important;
        bottom: max(10px, env(safe-area-inset-bottom)) !important;
        left: max(10px, env(safe-area-inset-left)) !important;
        width: auto !important;
        max-width: none !important;
        height: auto !important;
        max-height: none !important;
        padding: 14px !important;
        border-radius: 22px !important;
        transform: translate3d(0, 18px, 0) scale(.985) !important;
    }

    html body.admin-bar .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] {
        top: max(58px, calc(env(safe-area-inset-top) + 48px)) !important;
    }

    html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] .ejar-admin-nav-drawer-head {
        position: sticky;
        top: -14px;
        z-index: 2;
        margin: -14px -14px 14px;
        padding: 14px;
        background: rgba(255,255,255,.96);
        backdrop-filter: blur(14px);
        -webkit-backdrop-filter: blur(14px);
        border-radius: 22px 22px 0 0;
    }

    html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] .ejar-admin-nav-group {
        padding: 12px !important;
        border-radius: 20px !important;
    }

    html body .ejar-admin-nav-drawer[data-ejar-nav-portal="drawer"] a.ejar-admin-nav-link {
        min-height: 44px !important;
        padding: 11px 12px !important;
        font-size: 13px !important;
    }
}

/* E-Jar Mission 17F — respiration visuelle globale.
 * Objectif : éviter les titres, textes, tableaux, menus et sous-menus collés aux bords
 * sur toutes les pages et sous-pages Gestion E-Jar, Agence et Client.
 */
html body.ejar-responsive-ready :where(
    .ejar-card,
    .ejar-section,
    .ejar-form,
    .ejar-control-center,
    .ejar-tool-section,
    .ejar-tool-card,
    .ejar-subtabs-card,
    .ejar-parc-tabs-card,
    .ejar-parc-search-card,
    .ejar-smart-filter-panel,
    .ejar-sorties-panel,
    .ejar-agence-filter-panel,
    .ejar-agence-account-section,
    .ejar-agence-account-detail,
    .ejar-client-panel,
    .ejar-edit-panel-card,
    .ejar-contrats-intro,
    .ejar-contrats-legal-details,
    .ejar-dashboard .filter-bar,
    .ejar-admin-page-shell .filter-bar,
    .ejar-agence-page-shell .filter-bar,
    .ejar-client-page-shell .filter-bar
) {
    padding: var(--ejar-card-padding);
}

html body.ejar-responsive-ready :where(
    .ejar-alert,
    .ejar-help-text-block,
    .ejar-admin-help-text,
    .ejar-sorties-note,
    .ejar-client-empty,
    .ejar-admin-cleanup-card,
    .ejar-diagnostic-actions-intro,
    .ejar-agence-priority-box,
    .ejar-agence-quick-card,
    .ejar-client-action-card,
    .ejar-action-card-light,
    .ejar-print-summary-card
) {
    padding: var(--ejar-card-padding-sm);
}

html body.ejar-responsive-ready :where(
    .ejar-stat-card,
    .stat-card-v2,
    .ejar-parc-stat,
    .ejar-sorties-stat,
    .ejar-agence-stat,
    .ejar-client-kpi,
    .ejar-diagnostic-kpi,
    .ejar-agence-account-card
) {
    padding: clamp(18px, 2vw, 26px);
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-control-center, .ejar-tool-section, .ejar-tool-card) > :first-child,
html body.ejar-responsive-ready :where(.ejar-parc-tabs-card, .ejar-parc-search-card, .ejar-subtabs-card, .ejar-smart-filter-panel, .ejar-sorties-panel, .ejar-client-panel) > :first-child {
    margin-top: 0;
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-control-center, .ejar-tool-section, .ejar-tool-card) > :last-child,
html body.ejar-responsive-ready :where(.ejar-parc-tabs-card, .ejar-parc-search-card, .ejar-subtabs-card, .ejar-smart-filter-panel, .ejar-sorties-panel, .ejar-client-panel) > :last-child {
    margin-bottom: 0;
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-control-center, .ejar-tool-section, .ejar-tool-card) > * + *,
html body.ejar-responsive-ready :where(.ejar-parc-tabs-card, .ejar-parc-search-card, .ejar-subtabs-card, .ejar-smart-filter-panel, .ejar-sorties-panel, .ejar-client-panel) > * + * {
    margin-top: var(--ejar-content-gap);
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-tool-section, .ejar-control-center) :where(h1, h2, h3, h4) {
    margin: 0 0 10px;
    line-height: 1.18;
    letter-spacing: -.015em;
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-tool-section, .ejar-control-center) :where(p, .ejar-muted, .ejar-help-text, .ejar-admin-help-text, small) {
    line-height: 1.62;
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-tool-section, .ejar-control-center) :where(ul, ol) {
    margin-top: 12px;
    margin-bottom: 0;
    padding-left: 1.25rem;
}

html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form, .ejar-tool-section, .ejar-control-center) :where(li + li) {
    margin-top: 8px;
}

html body.ejar-responsive-ready :where(
    .ejar-dashboard-header,
    .ejar-page-hero,
    .ejar-agence-hero,
    .ejar-client-home,
    .ejar-auth-alert-page
) {
    padding: clamp(26px, 4vw, 46px);
}

html body.ejar-responsive-ready :where(.ejar-dashboard-header, .ejar-page-hero, .ejar-agence-hero) > :first-child {
    margin-top: 0;
}

html body.ejar-responsive-ready :where(.ejar-dashboard-header, .ejar-page-hero, .ejar-agence-hero) > :last-child {
    margin-bottom: 0;
}

/* Menus, sous-menus et sous-sous-menus. */
html body.ejar-responsive-ready :where(.ejar-subtabs-card, .ejar-parc-tabs-card) {
    display: block;
}

html body.ejar-responsive-ready :where(.ejar-subtabs, .ejar-parc-tabs, .ejar-edit-tabs, .ejar-client-actions, .ejar-parc-shortcuts) {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

html body.ejar-responsive-ready :where(.ejar-subtab, .ejar-parc-tab, .ejar-edit-tab, .ejar-admin-nav-link, .ejar-button, .ejar-button-light) {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

html body.ejar-responsive-ready :where(.ejar-admin-nav-toggle-pill, .ejar-admin-nav-drawer, .ejar-admin-nav-group, .ejar-admin-nav-group-links) {
    box-sizing: border-box;
}

html body.ejar-responsive-ready :where(.ejar-admin-nav-drawer) {
    padding: clamp(18px, 2.4vw, 28px);
}

html body.ejar-responsive-ready :where(.ejar-admin-nav-group) {
    padding: clamp(14px, 1.8vw, 20px);
}

html body.ejar-responsive-ready :where(.ejar-admin-nav-group-links) {
    gap: 8px;
}

/* Tableaux et listes : respiration dans les cartes sans casser le scroll responsive. */
html body.ejar-responsive-ready :where(
    .ejar-responsive-table-wrap,
    .ejar-table-responsive,
    .ejar-parc-table-wrap,
    .ejar-search-results-table-wrap,
    .ejar-finance-table-wrap,
    .ejar-livre-compte-table-wrap,
    .ejar-sorties-scroll
) {
    margin-top: var(--ejar-content-gap);
    border-radius: calc(var(--ejar-radius) - 6px);
    overflow: auto;
}

html body.ejar-responsive-ready :where(.ejar-table, .ejar-parc-table, .ejar-finance-table, .ejar-livre-compte-table, .ejar-responsive-table) {
    margin: 0;
}

html body.ejar-responsive-ready :where(.ejar-table th, .ejar-table td, .ejar-parc-table th, .ejar-parc-table td, .ejar-finance-table th, .ejar-finance-table td, .ejar-responsive-table th, .ejar-responsive-table td) {
    vertical-align: middle;
}

/* Formulaires et actions. */
html body.ejar-responsive-ready :where(.ejar-field, .ejar-registration-field, .ejar-sorties-field, .ejar-smart-filter-field, .ejar-agence-smart-search-field) {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

html body.ejar-responsive-ready :where(.ejar-form-grid-2, .ejar-form-grid-3, .ejar-edit-panels-grid, .ejar-client-info-grid, .ejar-agence-filter-grid, .ejar-contrats-annexes-grid) {
    gap: var(--ejar-content-gap);
}

html body.ejar-responsive-ready :where(.ejar-actions-stack, .ejar-inline-actions, .ejar-sorties-actions, .ejar-parc-actions, .ejar-agence-actions, .ejar-client-card-actions, .ejar-nowrap-actions) {
    gap: 8px;
    align-items: center;
}

html body.ejar-responsive-ready :where(.ejar-bulk-toolbar, .ejar-inline-form, .ejar-inline-form-spaced) {
    gap: var(--ejar-content-gap);
    align-items: end;
}

/* Parc : blocs d’attention, logique de pilotage et sous-pages. */
html body.ejar-responsive-ready :where(.ejar-parc-two-columns, .ejar-parc-summary-grid, .ejar-parc-alert-grid, .ejar-parc-mini-alerts) {
    gap: var(--ejar-section-gap);
}

html body.ejar-responsive-ready :where(.ejar-parc-alert-box) {
    padding: var(--ejar-card-padding-sm);
}

html body.ejar-responsive-ready :where(.ejar-parc-mini-alerts ul) {
    margin: 10px 0 0;
    padding-left: 1.1rem;
}

html body.ejar-responsive-ready :where(.ejar-parc-mini-alerts li) {
    padding: 10px 0;
}

html body.ejar-responsive-ready :where(.ejar-parc-mini-alerts li + li) {
    border-top: 1px solid rgba(185, 135, 34, .14);
}

html body.ejar-responsive-ready :where(.ejar-parc-vehicule-title, .ejar-agence-account-amount, .ejar-stat-card strong) {
    line-height: 1.22;
}

/* Évite les contenus directement collés lorsqu’un module ancien injecte un bloc simple. */
html body.ejar-responsive-ready :where(.ejar-card, .ejar-section, .ejar-form) > :where(div:not([class]), p:not([class]), h2:not([class]), h3:not([class])) {
    max-width: 100%;
}


/* ==========================================================
   E-Jar v3.1.108 — Mission 17G : espaces agence/client
   Objectif : tableaux desktop lisibles, soldes colorés et statuts plus visibles.
   ========================================================== */

html body .ejar-client-hero {
    align-items: stretch;
}

html body .ejar-client-hero-badge {
    min-width: min(280px, 100%);
    padding: clamp(18px, 2.2vw, 26px);
    border-radius: 24px;
    border: 1px solid rgba(255,255,255,.28);
    box-shadow: 0 18px 42px rgba(0,0,0,.18);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    background: rgba(255,255,255,.13);
    backdrop-filter: blur(12px);
}

html body .ejar-client-hero-badge.is-danger {
    background: linear-gradient(135deg, rgba(127,29,29,.96), rgba(220,38,38,.78));
    border-color: rgba(254,202,202,.72);
}

html body .ejar-client-hero-badge.is-success {
    background: linear-gradient(135deg, rgba(6,95,70,.96), rgba(22,163,74,.72));
    border-color: rgba(187,247,208,.72);
}

html body .ejar-client-hero-badge.is-credit {
    background: linear-gradient(135deg, rgba(4,120,87,.98), rgba(22,163,74,.86) 56%, rgba(212,175,55,.78));
    border-color: rgba(212,175,55,.72);
    box-shadow: 0 22px 52px rgba(4,120,87,.22);
}

html body .ejar-client-hero-badge strong {
    font-size: clamp(30px, 4vw, 44px);
    letter-spacing: -.04em;
}

html body .ejar-client-hero-badge small {
    font-size: clamp(20px, 2.3vw, 30px);
    font-weight: 950;
    line-height: 1.05;
}

html body .ejar-client-kpi.is-success {
    background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 100%);
    border-color: var(--ejar-success-border);
}

html body .ejar-client-kpi.is-credit {
    background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 55%, #fff8df 100%);
    border-color: rgba(22,163,74,.38);
}

html body .ejar-client-kpi.is-credit::before,
html body .ejar-client-table-row.is-credit td:first-child::before {
    background: linear-gradient(180deg, #047857, #16a34a 54%, #d4af37);
}

html body .ejar-client-kpi.is-credit strong {
    color: #047857;
}

html body .ejar-client-table-wrap {
    border: 1px solid var(--ejar-border);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--ejar-shadow-soft);
    overflow: auto;
}

html body .ejar-client-véhicule-table,
html body .ejar-client-finance-table {
    margin: 0;
    min-width: 1060px;
}

html body .ejar-client-véhicule-table th,
html body .ejar-client-finance-table th {
    background: linear-gradient(180deg, #fff8e6 0%, #f7f2e8 100%);
    color: var(--ejar-gold-dark);
    font-weight: 950;
    letter-spacing: .025em;
    text-transform: uppercase;
    font-size: 12px;
}

html body .ejar-client-véhicule-table td,
html body .ejar-client-finance-table td {
    vertical-align: middle;
}

html body .ejar-client-table-row {
    position: relative;
}

html body .ejar-client-table-row td:first-child {
    position: relative;
    padding-left: 22px;
}

html body .ejar-client-table-row td:first-child::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 14px;
    bottom: 14px;
    width: 4px;
    border-radius: 999px;
    background: var(--ejar-silver-gradient);
}

html body .ejar-client-table-row.is-danger td:first-child::before {
    background: linear-gradient(180deg, #991b1b, #dc2626);
}

html body .ejar-client-table-row.is-success td:first-child::before {
    background: linear-gradient(180deg, #065f46, #22c55e);
}

html body .ejar-client-main-cell strong {
    display: block;
    color: var(--ejar-ink);
    font-weight: 950;
    line-height: 1.25;
}

html body .ejar-client-main-cell small {
    display: block;
    margin-top: 4px;
    color: var(--ejar-muted);
    font-weight: 700;
    line-height: 1.35;
}

html body .ejar-client-balance-badge,
html body .ejar-client-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 999px;
    border: 1px solid var(--ejar-neutral-border);
    background: var(--ejar-neutral-soft);
    color: var(--ejar-ink);
    font-weight: 950;
    white-space: nowrap;
}

html body .ejar-client-status-badge {
    min-height: 34px;
    padding: 7px 12px;
    font-size: 13px;
}

html body .ejar-client-balance-badge {
    flex-direction: column;
    align-items: flex-start;
    min-width: 128px;
    padding: 9px 12px;
    line-height: 1.05;
}

html body .ejar-client-balance-badge small {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .06em;
    opacity: .78;
}

html body .ejar-client-balance-badge strong {
    font-size: 18px;
    letter-spacing: -.02em;
}

html body .ejar-client-balance-badge.is-danger,
html body .ejar-client-status-badge.is-danger {
    background: var(--ejar-danger-soft);
    border-color: var(--ejar-danger-border);
    color: var(--ejar-danger-dark);
}

html body .ejar-client-balance-badge.is-success,
html body .ejar-client-status-badge.is-success {
    background: var(--ejar-success-soft);
    border-color: var(--ejar-success-border);
    color: var(--ejar-success-dark);
}

html body .ejar-client-balance-badge.is-credit,
html body .ejar-client-status-badge.is-credit {
    background: linear-gradient(135deg, #dcfce7 0%, #ecfdf5 55%, #fff7d6 100%);
    border-color: rgba(22,163,74,.34);
    color: #047857;
    box-shadow: inset 0 0 0 1px rgba(212,175,55,.16);
}

html body .ejar-client-mini-history-table {
    margin: 0;
    padding: 10px 12px;
    max-width: 360px;
}

html body .ejar-client-mini-history-table .ejar-client-mini-line:first-child {
    border-top: 0;
}

html body .ejar-client-table-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

html body .ejar-agence-dashboard .ejar-balance-badge,
html body .ejar-agence-dashboard .ejar-money-positive,
html body .ejar-agence-dashboard .ejar-money-negative,
html body .ejar-agence-dashboard .ejar-money-neutral,
html body .ejar-client-home .ejar-balance-badge,
html body .ejar-client-home .ejar-money-positive,
html body .ejar-client-home .ejar-money-negative,
html body .ejar-client-home .ejar-money-neutral {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    min-height: 34px;
    padding: 7px 12px;
    border: 1px solid var(--ejar-neutral-border);
    background: var(--ejar-neutral-soft);
    color: var(--ejar-ink);
    font-weight: 950;
    white-space: nowrap;
}

html body .ejar-agence-dashboard .ejar-money-negative,
html body .ejar-client-home .ejar-money-negative {
    background: var(--ejar-danger-soft);
    border-color: var(--ejar-danger-border);
    color: var(--ejar-danger-dark);
}

html body .ejar-agence-dashboard .ejar-money-positive,
html body .ejar-client-home .ejar-money-positive {
    background: linear-gradient(135deg, #dcfce7 0%, #ecfdf5 58%, #fff7d6 100%);
    border-color: rgba(22,163,74,.34);
    color: #047857;
}

html body .ejar-agence-dashboard .ejar-money-neutral,
html body .ejar-client-home .ejar-money-neutral {
    background: var(--ejar-success-soft);
    border-color: var(--ejar-success-border);
    color: var(--ejar-success-dark);
}

@media (max-width: 1180px) {
    html body .ejar-client-véhicule-table,
    html body .ejar-client-finance-table {
        min-width: 0;
    }

    html body .ejar-client-table-wrap {
        overflow-x: visible;
        border: 0;
        box-shadow: none;
        background: transparent;
    }

    html body .ejar-client-balance-badge {
        min-width: 0;
        width: fit-content;
    }
}


/* ==========================================================
   E-Jar v3.1.109 — Mission 17H : états visuels vifs
   Objectif : rendre les rouges/verts plus forts, lisibles et cohérents.
   ========================================================== */

/* Rouge : alertes, impayés, soldes débiteurs, relances. */
html body :where(
    .ejar-alert-error,
    .ejar-badge-danger,
    .ejar-badge-rejected,
    .ejar-parc-badge-danger,
    .ejar-status-danger,
    .ejar-solde-debiteur,
    .ejar-balance-negative,
    .ejar-money-negative,
    .ejar-balance-badge.is-danger,
    .ejar-relance-button
) {
    background: var(--ejar-danger-gradient-strong, linear-gradient(135deg, #6f000c 0%, #b91c1c 38%, #ef233c 72%, #ff4d4d 100%));
    border-color: rgba(255, 255, 255, .22);
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
    box-shadow: var(--ejar-danger-shadow, 0 14px 34px rgba(239, 35, 60, .28));
    text-shadow: 0 1px 1px rgba(0,0,0,.18);
}

html body :where(
    .ejar-alert-error,
    .ejar-badge-danger,
    .ejar-badge-rejected,
    .ejar-parc-badge-danger,
    .ejar-status-danger,
    .ejar-solde-debiteur,
    .ejar-balance-negative,
    .ejar-money-negative,
    .ejar-balance-badge.is-danger,
    .ejar-relance-button
) :where(span, strong, small, em, b, i) {
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
}

/* Vert : comptes à jour, soldes neutres, statuts payés/validés. */
html body :where(
    .ejar-alert-success,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-parc-badge-success,
    .ejar-status-success,
    .ejar-solde-neutre,
    .ejar-balance-zero,
    .ejar-money-neutral,
    .ejar-balance-badge.is-success
) {
    background: var(--ejar-success-gradient, linear-gradient(135deg, #006b3c 0%, #00a86b 48%, #22c55e 100%));
    border-color: rgba(255, 255, 255, .24);
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
    box-shadow: var(--ejar-success-shadow, 0 14px 34px rgba(22, 199, 132, .26));
    text-shadow: 0 1px 1px rgba(0,0,0,.14);
}

html body :where(
    .ejar-alert-success,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-parc-badge-success,
    .ejar-status-success,
    .ejar-solde-neutre,
    .ejar-balance-zero,
    .ejar-money-neutral,
    .ejar-balance-badge.is-success
) :where(span, strong, small, em, b, i) {
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
}

/* Vert renforcé + doré : trop-perçu / solde créditeur. */
html body :where(
    .ejar-solde-crediteur,
    .ejar-balance-positive,
    .ejar-money-positive,
    .ejar-balance-badge.is-credit,
    .ejar-status-credit
) {
    background: var(--ejar-success-gradient-credit, linear-gradient(135deg, #005c37 0%, #00a86b 44%, #22c55e 72%, #d4af37 100%));
    border-color: rgba(212, 175, 55, .46);
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
    box-shadow: 0 16px 38px rgba(22, 199, 132, .25), inset 0 0 0 1px rgba(255,255,255,.16);
    text-shadow: 0 1px 1px rgba(0,0,0,.16);
}

html body :where(
    .ejar-solde-crediteur,
    .ejar-balance-positive,
    .ejar-money-positive,
    .ejar-balance-badge.is-credit,
    .ejar-status-credit
) :where(span, strong, small, em, b, i) {
    color: var(--ejar-status-on-vivid, #ffffff);
    -webkit-text-fill-color: var(--ejar-status-on-vivid, #ffffff);
    font-weight: 950;
}

/* Espace client : carte globale, KPIs, badges et tableaux. */
html body .ejar-client-hero-badge.is-danger {
    background: var(--ejar-danger-gradient-strong, linear-gradient(135deg, #6f000c 0%, #b91c1c 38%, #ef233c 72%, #ff4d4d 100%));
    border-color: rgba(255,255,255,.26);
    box-shadow: 0 24px 58px rgba(239,35,60,.34);
}

html body .ejar-client-hero-badge.is-success {
    background: var(--ejar-success-gradient-strong, linear-gradient(135deg, #005c37 0%, #059669 38%, #16c784 72%, #4ade80 100%));
    border-color: rgba(255,255,255,.28);
    box-shadow: 0 24px 58px rgba(22,199,132,.28);
}

html body .ejar-client-hero-badge.is-credit {
    background: var(--ejar-success-gradient-credit, linear-gradient(135deg, #005c37 0%, #00a86b 44%, #22c55e 72%, #d4af37 100%));
    border-color: rgba(212,175,55,.62);
    box-shadow: 0 26px 62px rgba(22,199,132,.31), inset 0 0 0 1px rgba(255,255,255,.16);
}

html body .ejar-client-hero-badge :where(span, strong, small) {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
    text-shadow: 0 1px 1px rgba(0,0,0,.16);
}

html body .ejar-client-kpi.is-danger {
    background: var(--ejar-danger-gradient-alert, linear-gradient(135deg, #7f0011 0%, #c1121f 48%, #ef233c 100%));
    border-color: rgba(239,35,60,.42);
    box-shadow: var(--ejar-danger-shadow, 0 14px 34px rgba(239,35,60,.28));
}

html body .ejar-client-kpi.is-success {
    background: var(--ejar-success-gradient, linear-gradient(135deg, #006b3c 0%, #00a86b 48%, #22c55e 100%));
    border-color: rgba(22,199,132,.42);
    box-shadow: var(--ejar-success-shadow, 0 14px 34px rgba(22,199,132,.26));
}

html body .ejar-client-kpi.is-credit {
    background: var(--ejar-success-gradient-credit, linear-gradient(135deg, #005c37 0%, #00a86b 44%, #22c55e 72%, #d4af37 100%));
    border-color: rgba(212,175,55,.48);
    box-shadow: 0 16px 38px rgba(22,199,132,.24);
}

html body .ejar-client-kpi:is(.is-danger, .is-success, .is-credit) :where(span, small, strong) {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
    text-shadow: 0 1px 1px rgba(0,0,0,.14);
}

html body .ejar-client-balance-badge.is-danger,
html body .ejar-client-status-badge.is-danger {
    background: var(--ejar-danger-gradient-strong, linear-gradient(135deg, #6f000c 0%, #b91c1c 38%, #ef233c 72%, #ff4d4d 100%));
    border-color: rgba(255,255,255,.24);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    box-shadow: var(--ejar-danger-shadow, 0 14px 34px rgba(239,35,60,.28));
}

html body .ejar-client-balance-badge.is-success,
html body .ejar-client-status-badge.is-success {
    background: var(--ejar-success-gradient, linear-gradient(135deg, #006b3c 0%, #00a86b 48%, #22c55e 100%));
    border-color: rgba(255,255,255,.24);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    box-shadow: var(--ejar-success-shadow, 0 14px 34px rgba(22,199,132,.26));
}

html body .ejar-client-balance-badge.is-credit,
html body .ejar-client-status-badge.is-credit {
    background: var(--ejar-success-gradient-credit, linear-gradient(135deg, #005c37 0%, #00a86b 44%, #22c55e 72%, #d4af37 100%));
    border-color: rgba(212,175,55,.56);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    box-shadow: 0 16px 38px rgba(22,199,132,.25), inset 0 0 0 1px rgba(255,255,255,.16);
}

html body .ejar-client-balance-badge:is(.is-danger, .is-success, .is-credit) :where(small, strong),
html body .ejar-client-status-badge:is(.is-danger, .is-success, .is-credit) {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
}

html body .ejar-client-table-row.is-danger td:first-child::before {
    background: var(--ejar-danger-gradient-strong, linear-gradient(180deg, #6f000c, #ef233c));
}

html body .ejar-client-table-row.is-success td:first-child::before {
    background: var(--ejar-success-gradient-strong, linear-gradient(180deg, #005c37, #16c784));
}

html body .ejar-client-table-row.is-credit td:first-child::before {
    background: var(--ejar-success-gradient-credit, linear-gradient(180deg, #005c37, #22c55e, #d4af37));
}

/* Espaces agence/client : mêmes codes de couleur pour les montants. */
html body .ejar-agence-dashboard .ejar-money-negative,
html body .ejar-client-home .ejar-money-negative,
html body .ejar-agence-dashboard .ejar-balance-negative,
html body .ejar-client-home .ejar-balance-negative {
    background: var(--ejar-danger-gradient-strong, linear-gradient(135deg, #6f000c 0%, #b91c1c 38%, #ef233c 72%, #ff4d4d 100%));
    border-color: rgba(255,255,255,.24);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
}

html body .ejar-agence-dashboard .ejar-money-neutral,
html body .ejar-client-home .ejar-money-neutral,
html body .ejar-agence-dashboard .ejar-balance-zero,
html body .ejar-client-home .ejar-balance-zero {
    background: var(--ejar-success-gradient, linear-gradient(135deg, #006b3c 0%, #00a86b 48%, #22c55e 100%));
    border-color: rgba(255,255,255,.24);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
}

html body .ejar-agence-dashboard .ejar-money-positive,
html body .ejar-client-home .ejar-money-positive,
html body .ejar-agence-dashboard .ejar-balance-positive,
html body .ejar-client-home .ejar-balance-positive {
    background: var(--ejar-success-gradient-credit, linear-gradient(135deg, #005c37 0%, #00a86b 44%, #22c55e 72%, #d4af37 100%));
    border-color: rgba(212,175,55,.52);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
}


/* ==========================================================
   E-Jar v3.1.110 — Mission 17I : contraste réel des états
   Objectif : garantir lisibilité fond/texte sur Situation globale,
   badges Validé/Payé/À jour, impayés, relances et soldes.
   Règle : fonds vifs/foncés => texte blanc gras ; fonds clairs => texte foncé.
   ========================================================== */

/* Situation globale client : priorité sur le header clair qui remet les textes en noir. */
html body .ejar-client-hero .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit),
html body .ejar-page-hero .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit),
html body .ejar-dashboard-header .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

html body .ejar-client-hero .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit) :is(span, strong, small, em, b, i, div),
html body .ejar-page-hero .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit) :is(span, strong, small, em, b, i, div),
html body .ejar-dashboard-header .ejar-client-hero-badge:is(.is-danger, .is-success, .is-credit) :is(span, strong, small, em, b, i, div) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
    text-shadow: 0 1px 2px rgba(0,0,0,.24) !important;
}

/* Rouge lisible : on évite les rouges trop clairs qui rendent le blanc fragile. */
html body :is(
    .ejar-alert-error,
    .ejar-badge-danger,
    .ejar-badge-rejected,
    .ejar-parc-badge-danger,
    .ejar-status-danger,
    .ejar-solde-debiteur,
    .ejar-balance-negative,
    .ejar-money-negative,
    .ejar-balance-badge.is-danger,
    .ejar-client-hero-badge.is-danger,
    .ejar-client-kpi.is-danger,
    .ejar-client-balance-badge.is-danger,
    .ejar-client-status-badge.is-danger,
    .ejar-relance-button
) {
    background: linear-gradient(135deg, #6f000c 0%, #991b1b 38%, #b91c1c 72%, #dc2626 100%) !important;
    border-color: rgba(255,255,255,.26) !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
    text-shadow: 0 1px 2px rgba(0,0,0,.24) !important;
}

html body :is(
    .ejar-alert-error,
    .ejar-badge-danger,
    .ejar-badge-rejected,
    .ejar-parc-badge-danger,
    .ejar-status-danger,
    .ejar-solde-debiteur,
    .ejar-balance-negative,
    .ejar-money-negative,
    .ejar-balance-badge.is-danger,
    .ejar-client-hero-badge.is-danger,
    .ejar-client-kpi.is-danger,
    .ejar-client-balance-badge.is-danger,
    .ejar-client-status-badge.is-danger,
    .ejar-relance-button
) :is(span, strong, small, em, b, i, div) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
}

/* Vert validé/payé/à jour : vert profond et lisible avec texte blanc. */
html body :is(
    .ejar-alert-success,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-parc-badge-success,
    .ejar-status-success,
    .ejar-solde-neutre,
    .ejar-balance-zero,
    .ejar-money-neutral,
    .ejar-balance-badge.is-success,
    .ejar-dashboard .status-success,
    .ejar-admin-page-shell .status-success,
    .ejar-agence-page-shell .status-success,
    .ejar-client-page-shell .status-success,
    .ejar-dashboard .status-paid,
    .ejar-admin-page-shell .status-paid,
    .ejar-agence-page-shell .status-paid,
    .ejar-client-page-shell .status-paid,
    .ejar-client-hero-badge.is-success,
    .ejar-client-kpi.is-success,
    .ejar-client-balance-badge.is-success,
    .ejar-client-status-badge.is-success
) {
    background: linear-gradient(135deg, #064e3b 0%, #065f46 45%, #047857 100%) !important;
    border-color: rgba(255,255,255,.28) !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
    text-shadow: 0 1px 2px rgba(0,0,0,.22) !important;
}

html body :is(
    .ejar-alert-success,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-parc-badge-success,
    .ejar-status-success,
    .ejar-solde-neutre,
    .ejar-balance-zero,
    .ejar-money-neutral,
    .ejar-balance-badge.is-success,
    .ejar-dashboard .status-success,
    .ejar-admin-page-shell .status-success,
    .ejar-agence-page-shell .status-success,
    .ejar-client-page-shell .status-success,
    .ejar-dashboard .status-paid,
    .ejar-admin-page-shell .status-paid,
    .ejar-agence-page-shell .status-paid,
    .ejar-client-page-shell .status-paid,
    .ejar-client-hero-badge.is-success,
    .ejar-client-kpi.is-success,
    .ejar-client-balance-badge.is-success,
    .ejar-client-status-badge.is-success
) :is(span, strong, small, em, b, i, div) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
}

/* Trop-perçu / créditeur : vert profond avec accent doré, blanc lisible. */
html body :is(
    .ejar-solde-crediteur,
    .ejar-balance-positive,
    .ejar-money-positive,
    .ejar-balance-badge.is-credit,
    .ejar-status-credit,
    .ejar-client-hero-badge.is-credit,
    .ejar-client-kpi.is-credit,
    .ejar-client-balance-badge.is-credit,
    .ejar-client-status-badge.is-credit
) {
    background: linear-gradient(135deg, #043927 0%, #065f46 40%, #047857 74%, #9a7119 100%) !important;
    border-color: rgba(212,175,55,.54) !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
    text-shadow: 0 1px 2px rgba(0,0,0,.24) !important;
}

html body :is(
    .ejar-solde-crediteur,
    .ejar-balance-positive,
    .ejar-money-positive,
    .ejar-balance-badge.is-credit,
    .ejar-status-credit,
    .ejar-client-hero-badge.is-credit,
    .ejar-client-kpi.is-credit,
    .ejar-client-balance-badge.is-credit,
    .ejar-client-status-badge.is-credit
) :is(span, strong, small, em, b, i, div) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
}

/* Exception volontaire : les fonds verts très clairs encore utilisés ailleurs gardent un texte foncé. */
html body :is(.ejar-success-soft, .ejar-status-soft-success, .ejar-kpi-soft-success) {
    color: #064e3b !important;
    -webkit-text-fill-color: #064e3b !important;
    font-weight: 950 !important;
}

/* ==========================================================
   E-Jar v3.1.111 — Mission 17J : tableaux client premium
   Objectif : rendre les historiques client/agence plus lisibles,
   notamment la colonne "Derniers mouvements".
   ========================================================== */

html body .ejar-client-finance-table td[data-label="Derniers mouvements"] {
    min-width: 330px;
    vertical-align: top;
}

html body .ejar-client-mini-history-table {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 8px;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(247,242,232,.72));
    border: 1px solid rgba(234,223,202,.92);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.65);
}

html body .ejar-client-movement-item {
    position: relative;
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid rgba(234,223,202,.82);
    box-shadow: 0 8px 22px rgba(17,17,17,.045);
}

html body .ejar-client-movement-item + .ejar-client-movement-item {
    margin-top: 8px;
}

html body .ejar-client-movement-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 18px;
    font-weight: 950;
    background: var(--ejar-neutral-soft);
    color: var(--ejar-ink);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.55);
}

html body .ejar-client-movement-item.is-debit .ejar-client-movement-icon {
    background: linear-gradient(135deg, #7f0011, #dc2626);
    color: #ffffff;
}

html body .ejar-client-movement-item.is-credit .ejar-client-movement-icon {
    background: linear-gradient(135deg, #064e3b, #047857);
    color: #ffffff;
}

html body .ejar-client-movement-body {
    min-width: 0;
    display: grid;
    gap: 3px;
}

html body .ejar-client-movement-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: start;
}

html body .ejar-client-movement-top strong {
    color: var(--ejar-ink);
    font-size: 13.5px;
    line-height: 1.25;
    font-weight: 950;
    overflow-wrap: anywhere;
}

html body .ejar-client-movement-top em {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 4px 8px;
    border-radius: 999px;
    background: var(--ejar-cream);
    color: var(--ejar-muted);
    border: 1px solid var(--ejar-border);
    font-style: normal;
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

html body .ejar-client-movement-body small {
    color: var(--ejar-muted);
    font-weight: 800;
    line-height: 1.25;
}

html body .ejar-client-movement-amount {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 950;
    white-space: nowrap;
    box-shadow: 0 8px 18px rgba(17,17,17,.08);
}

html body .ejar-client-movement-amount.is-debit {
    background: linear-gradient(135deg, #7f0011 0%, #b91c1c 60%, #dc2626 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

html body .ejar-client-movement-amount.is-credit {
    background: linear-gradient(135deg, #064e3b 0%, #047857 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

html body .ejar-client-movement-amount.is-neutral {
    background: var(--ejar-neutral-soft);
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
}

html body .ejar-client-finance-table .ejar-muted-value {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    padding: 9px 12px;
    border-radius: 999px;
    background: var(--ejar-cream);
    border: 1px solid var(--ejar-border);
    color: var(--ejar-muted);
    font-weight: 900;
}

html body .ejar-client-véhicule-table td,
html body .ejar-client-finance-table td,
html body .ejar-agence-accounts-table td {
    vertical-align: middle;
}

html body .ejar-client-main-cell,
html body .ejar-agence-vehicule-cell,
html body .ejar-agence-client-cell {
    min-width: 220px;
}

html body .ejar-client-main-cell strong,
html body .ejar-agence-vehicule-cell strong,
html body .ejar-agence-client-cell strong {
    display: block;
    color: var(--ejar-ink);
    font-size: 14.5px;
    line-height: 1.25;
    font-weight: 950;
}

html body .ejar-client-main-cell small,
html body .ejar-agence-vehicule-cell small,
html body .ejar-agence-client-cell small,
html body .ejar-agence-paiement-cell small {
    display: block;
    margin-top: 5px;
    color: var(--ejar-muted);
    font-weight: 800;
    line-height: 1.35;
}

html body .ejar-agence-structure-cell span {
    display: inline-flex;
    max-width: 240px;
    padding: 7px 10px;
    border-radius: 999px;
    background: var(--ejar-cream);
    border: 1px solid var(--ejar-border);
    color: var(--ejar-ink);
    font-size: 12px;
    font-weight: 950;
    line-height: 1.2;
}

html body .ejar-agence-paiement-cell > strong {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    padding: 7px 11px;
    border-radius: 999px;
    background: linear-gradient(135deg, #111111 0%, #2a2418 62%, #c9972e 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-weight: 950;
    box-shadow: 0 10px 22px rgba(17,17,17,.12);
}

html body .ejar-agence-solde-cell .ejar-balance-badge,
html body .ejar-client-balance-cell .ejar-client-balance-badge {
    min-width: 128px;
}

html body .ejar-agence-accounts-table .ejar-agence-actions,
html body .ejar-client-finance-table .ejar-actions-cell,
html body .ejar-client-véhicule-table .ejar-actions-cell {
    min-width: 150px;
}

html body .ejar-agence-account-detail-content .ejar-livre-compte-table-wrap {
    margin-top: 16px;
    border-radius: 24px;
    border: 1px solid var(--ejar-border);
    box-shadow: var(--ejar-shadow-soft);
    background: #ffffff;
}

html body .ejar-agence-account-detail-content .ejar-livre-compte-table td,
html body .ejar-agence-account-detail-content .ejar-livre-compte-table th {
    padding: 14px 16px;
}

html body .ejar-agence-account-detail-content .ejar-livre-compte-table td:nth-child(2) {
    font-weight: 950;
    color: var(--ejar-ink);
}

html body .ejar-agence-account-card {
    overflow: hidden;
}

html body .ejar-agence-account-card small {
    line-height: 1.35;
}

@media (max-width: 900px) {
    html body .ejar-client-finance-table td[data-label="Derniers mouvements"] {
        min-width: 0;
    }

    html body .ejar-client-movement-item {
        grid-template-columns: 32px minmax(0, 1fr);
    }

    html body .ejar-client-movement-amount {
        grid-column: 2;
        justify-self: start;
        margin-top: 4px;
    }

    html body .ejar-client-movement-top {
        grid-template-columns: minmax(0, 1fr);
    }

    html body .ejar-client-movement-top em {
        justify-self: start;
    }
}


/* ==========================================================
   E-Jar v3.1.116 — Mission 17O : audit global des interfaces
   Admin / Agence / Client
   Objectif : uniformiser les tableaux, les actions et les états
   financiers après contrôle transversal des pages et sous-pages.
   ========================================================== */

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) :where(.ejar-responsive-table-wrap, .ejar-table-responsive, .ejar-sorties-scroll) {
    border-radius: 24px;
    border: 1px solid rgba(234, 223, 202, .92);
    background: linear-gradient(180deg, rgba(255,255,255,.98) 0%, rgba(255,250,240,.82) 100%);
    box-shadow: var(--ejar-shadow-soft);
    padding: 8px;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table {
    border-collapse: separate;
    border-spacing: 0 8px;
    margin: 0;
    width: 100%;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table thead th {
    padding: 14px 16px;
    background: linear-gradient(135deg, #111111 0%, #211b11 68%, #3b2b0c 100%);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
    font-size: 12px;
    font-weight: 950;
    letter-spacing: .045em;
    text-transform: uppercase;
    line-height: 1.2;
    border: 0;
    white-space: nowrap;
    vertical-align: middle;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table thead th:first-child {
    border-radius: 16px 0 0 16px;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table thead th:last-child {
    border-radius: 0 16px 16px 0;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table tbody td {
    padding: 15px 16px;
    background: #ffffff;
    color: var(--ejar-ink);
    -webkit-text-fill-color: var(--ejar-ink);
    border-top: 1px solid rgba(234,223,202,.78);
    border-bottom: 1px solid rgba(234,223,202,.78);
    line-height: 1.42;
    vertical-align: middle;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table tbody tr:nth-child(even) td {
    background: #fffaf0;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table tbody tr:hover td {
    background: #fff1cf;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table tbody td:first-child {
    border-left: 1px solid rgba(234,223,202,.78);
    border-radius: 18px 0 0 18px;
}

html body :where(
    .ejar-admin-page-shell,
    .ejar-agence-page-shell,
    .ejar-client-page-shell,
    .ejar-client-page-shell,
    .ejar-admin-space,
    .ejar-agence-space,
    .ejar-client-space,
    .ejar-client-home,
    .ejar-dashboard,
    .ejar-responsive-scope
) table.ejar-table tbody td:last-child {
    border-right: 1px solid rgba(234,223,202,.78);
    border-radius: 0 18px 18px 0;
}

html body :where(.ejar-actions-cell, .ejar-agence-actions, .ejar-parc-actions, .ejar-nowrap-actions, .ejar-sorties-actions, .ejar-client-table-actions) {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

html body :where(.ejar-actions-cell, .ejar-agence-actions, .ejar-parc-actions, .ejar-nowrap-actions, .ejar-sorties-actions, .ejar-client-table-actions) :where(.ejar-button, a.ejar-button, button.ejar-button, input[type="submit"].ejar-button) {
    min-height: 38px;
    padding: 9px 13px;
    border-radius: 14px;
    font-weight: 950;
    line-height: 1.15;
    white-space: nowrap;
}

html body :where(.ejar-money-cell, .ejar-finance-col-solde, .ejar-agence-solde-cell, .ejar-client-balance-cell, .ejar-sorties-total, .ejar-balance-cell) {
    text-align: right;
    white-space: nowrap;
}

/* Contrastes forts : négatif/positif/crédit, avec héritage interne contrôlé. */
html body :where(
    .is-negative,
    .ejar-money-negative,
    .ejar-balance-negative,
    .ejar-balance-badge.is-danger,
    .ejar-status-danger,
    .ejar-badge-danger,
    .ejar-badge-rejected,
    .ejar-parc-badge-danger,
    .ejar-solde-debiteur,
    .ejar-sorties-amount.is-negative,
    .ejar-client-table-row.is-danger .ejar-client-balance-badge,
    .ejar-agence-account-card-danger .ejar-agence-account-amount,
    .ejar-pointage-status-badge.ejar-badge-danger
) {
    background: var(--ejar-negative-bg, linear-gradient(135deg, #6f000c 0%, #991b1b 36%, #b91c1c 70%, #dc2626 100%));
    border-color: rgba(255,255,255,.26);
    color: var(--ejar-on-dark, #ffffff);
    -webkit-text-fill-color: var(--ejar-on-dark, #ffffff);
    font-weight: 950;
    text-shadow: 0 1px 2px rgba(0,0,0,.24);
}

html body :where(
    .is-positive,
    .ejar-money-neutral,
    .ejar-balance-zero,
    .ejar-balance-badge.is-success,
    .ejar-status-success,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-parc-badge-success,
    .ejar-solde-neutre,
    .ejar-sorties-amount.is-positive,
    .ejar-client-table-row.is-success .ejar-client-balance-badge,
    .ejar-agence-account-card-success .ejar-agence-account-amount,
    .ejar-pointage-status-badge.ejar-badge-success
) {
    background: var(--ejar-positive-bg, linear-gradient(135deg, #064e3b 0%, #065f46 45%, #047857 100%));
    border-color: rgba(255,255,255,.26);
    color: var(--ejar-on-dark, #ffffff);
    -webkit-text-fill-color: var(--ejar-on-dark, #ffffff);
    font-weight: 950;
    text-shadow: 0 1px 2px rgba(0,0,0,.22);
}

html body :where(
    .ejar-money-positive,
    .ejar-balance-positive,
    .ejar-balance-badge.is-credit,
    .ejar-status-credit,
    .ejar-solde-crediteur,
    .ejar-client-table-row.is-credit .ejar-client-balance-badge
) {
    background: var(--ejar-credit-bg, linear-gradient(135deg, #043927 0%, #065f46 40%, #047857 74%, #9a7119 100%));
    border-color: rgba(212,175,55,.54);
    color: var(--ejar-on-dark, #ffffff);
    -webkit-text-fill-color: var(--ejar-on-dark, #ffffff);
    font-weight: 950;
    text-shadow: 0 1px 2px rgba(0,0,0,.24);
}

html body :where(
    .is-negative,
    .is-positive,
    .ejar-money-negative,
    .ejar-money-neutral,
    .ejar-money-positive,
    .ejar-balance-negative,
    .ejar-balance-zero,
    .ejar-balance-positive,
    .ejar-balance-badge.is-danger,
    .ejar-balance-badge.is-success,
    .ejar-balance-badge.is-credit,
    .ejar-status-danger,
    .ejar-status-success,
    .ejar-status-credit,
    .ejar-badge-danger,
    .ejar-badge-success,
    .ejar-badge-approved,
    .ejar-badge-rejected,
    .ejar-sorties-amount.is-negative,
    .ejar-sorties-amount.is-positive
) :where(span, strong, small, em, b, i, div) {
    color: var(--ejar-on-dark, #ffffff);
    -webkit-text-fill-color: var(--ejar-on-dark, #ffffff);
    font-weight: 950;
}

/* États clairs volontairement neutres : texte foncé pour éviter blanc sur fond clair. */
html body :where(
    .is-zero,
    .ejar-money-neutral-light,
    .ejar-balance-badge.is-neutral,
    .ejar-status-neutral,
    .ejar-badge-neutral,
    .ejar-badge-pending,
    .ejar-parc-badge-warning,
    .ejar-parc-badge-neutral,
    .ejar-muted-value,
    .ejar-sorties-amount.is-zero
) {
    background: linear-gradient(180deg, #ffffff 0%, #f7f2e8 100%);
    border-color: var(--ejar-border);
    color: var(--ejar-on-light, #171717);
    -webkit-text-fill-color: var(--ejar-on-light, #171717);
    font-weight: 900;
    text-shadow: none;
}

@media (max-width: 1180px) {
    html body :where(.ejar-responsive-table-wrap, .ejar-table-responsive, .ejar-sorties-scroll) {
        padding: 6px;
        border-radius: 20px;
    }

    html body table.ejar-responsive-table tbody td {
        text-align: left;
    }

    html body table.ejar-responsive-table tbody td[data-label]::before {
        color: var(--ejar-muted);
        -webkit-text-fill-color: var(--ejar-muted);
        font-weight: 950;
    }

    html body :where(.ejar-actions-cell, .ejar-agence-actions, .ejar-parc-actions, .ejar-nowrap-actions, .ejar-sorties-actions, .ejar-client-table-actions) {
        justify-content: flex-start;
    }

    html body :where(.ejar-money-cell, .ejar-finance-col-solde, .ejar-agence-solde-cell, .ejar-client-balance-cell, .ejar-sorties-total, .ejar-balance-cell) {
        text-align: left;
    }
}


/* ==========================================================
   E-Jar v3.1.118 — Mission 17Q : colonnes client desktop stables
   Objectif : supprimer l'effet saccadé dans la colonne
   "Derniers mouvements" côté client et "Paiement mensuel"
   côté agence, sans modifier le rendu mobile validé.
   ========================================================== */

@media (min-width: 901px) {
    html body .ejar-client-table-wrap,
    html body .ejar-agence-space .ejar-table-responsive {
        overflow-x: auto;
    }

    html body .ejar-client-finance-table {
        min-width: 1320px;
        table-layout: auto;
    }

    html body .ejar-client-finance-table th:nth-child(7),
    html body .ejar-client-finance-table td[data-label="Derniers mouvements"] {
        width: 440px;
        min-width: 440px;
        max-width: 520px;
    }

    html body .ejar-client-mini-history-table {
        display: grid;
        gap: 8px;
        min-width: 400px;
        padding: 10px;
    }

    html body .ejar-client-movement-item {
        grid-template-columns: 34px minmax(210px, 1fr) minmax(118px, auto);
        gap: 12px;
        padding: 10px 12px;
    }

    html body .ejar-client-movement-top {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 10px;
    }

    html body .ejar-client-movement-top strong {
        overflow-wrap: normal;
        word-break: normal;
        hyphens: none;
    }

    html body .ejar-client-movement-body small {
        display: block;
        overflow-wrap: normal;
        word-break: normal;
    }

    html body .ejar-client-movement-amount {
        min-width: 112px;
        justify-self: end;
        text-align: center;
    }

    html body .ejar-agence-accounts-table {
        min-width: 1080px;
        table-layout: auto;
    }

    html body .ejar-agence-accounts-table th:nth-child(4),
    html body .ejar-agence-accounts-table td[data-label="Paiement mensuel"] {
        width: 210px;
        min-width: 210px;
    }

    html body .ejar-agence-paiement-cell {
        white-space: normal;
    }

    html body .ejar-agence-paiement-box {
        display: grid;
        gap: 8px;
        align-items: start;
        max-width: 100%;
    }

    html body .ejar-agence-paiement-total {
        display: inline-flex;
        width: max-content;
        min-width: 132px;
        min-height: 36px;
        align-items: center;
        justify-content: center;
        padding: 8px 12px;
        border-radius: 999px;
        background: linear-gradient(135deg, #111111 0%, #2a2418 62%, #c9972e 100%);
        color: #ffffff;
        -webkit-text-fill-color: #ffffff;
        font-weight: 950;
        white-space: nowrap;
        box-shadow: 0 10px 22px rgba(17,17,17,.12);
    }

    html body .ejar-agence-paiement-detail {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        align-items: center;
        color: var(--ejar-muted);
        font-size: 11.5px;
        font-weight: 900;
        line-height: 1.2;
    }

    html body .ejar-agence-paiement-detail span {
        display: inline-flex;
        width: max-content;
        max-width: 100%;
        padding: 5px 8px;
        border-radius: 999px;
        background: var(--ejar-cream);
        border: 1px solid var(--ejar-border);
        color: var(--ejar-muted);
        -webkit-text-fill-color: var(--ejar-muted);
        white-space: nowrap;
    }

    html body .ejar-agence-paiement-cell > strong,
    html body .ejar-agence-paiement-cell > small {
        display: none;
    }
}

@media (max-width: 900px) {
    html body .ejar-client-finance-table,
    html body .ejar-agence-accounts-table {
        min-width: 0;
    }

    html body .ejar-client-mini-history-table {
        min-width: 0;
    }

    html body .ejar-agence-paiement-box {
        display: grid;
        gap: 8px;
    }

    html body .ejar-agence-paiement-total {
        display: inline-flex;
        width: max-content;
        max-width: 100%;
        align-items: center;
        justify-content: center;
        padding: 8px 12px;
        border-radius: 999px;
        background: linear-gradient(135deg, #111111 0%, #2a2418 62%, #c9972e 100%);
        color: #ffffff;
        -webkit-text-fill-color: #ffffff;
        font-weight: 950;
        white-space: nowrap;
    }

    html body .ejar-agence-paiement-detail {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    html body .ejar-agence-paiement-detail span {
        display: inline-flex;
        padding: 5px 8px;
        border-radius: 999px;
        background: var(--ejar-cream);
        border: 1px solid var(--ejar-border);
        color: var(--ejar-muted);
        -webkit-text-fill-color: var(--ejar-muted);
        font-size: 11.5px;
        font-weight: 900;
        white-space: nowrap;
    }
}

/* ==========================================================
   E-Jar v3.1.119 — Mission 17R : contraste du paiement mensuel agence
   Objectif : garantir une écriture blanche, grasse et lisible sur le
   bouton total mensuel or/noir dans l'espace agence.
   ========================================================== */
html body .ejar-agence-space .ejar-agence-paiement-total,
html body .ejar-agence-page-shell .ejar-agence-paiement-total,
html body .ejar-agence-accounts-table td[data-label="Paiement mensuel"] .ejar-agence-paiement-total {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
    text-shadow: 0 1px 2px rgba(0,0,0,.34) !important;
}

html body .ejar-agence-space .ejar-agence-paiement-total :is(span, strong, small, em, b, i, div),
html body .ejar-agence-page-shell .ejar-agence-paiement-total :is(span, strong, small, em, b, i, div),
html body .ejar-agence-accounts-table td[data-label="Paiement mensuel"] .ejar-agence-paiement-total :is(span, strong, small, em, b, i, div) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 950 !important;
}

/* Version 3.1.120 - zones de suppression propre dans Création & affiliation E-Jar */
html body .ejar-entities-dashboard .ejar-delete-zone,
html body .ejar-dashboard .ejar-delete-zone {
    margin-top: 18px;
    padding: 16px;
    border: 1px solid rgba(179, 45, 46, .26);
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(254, 242, 242, .95), rgba(255, 247, 237, .82));
    box-shadow: 0 12px 30px rgba(127, 29, 29, .08);
}

html body .ejar-entities-dashboard .ejar-delete-zone h4,
html body .ejar-dashboard .ejar-delete-zone h4 {
    margin: 0 0 8px;
    font-size: 16px;
    font-weight: 800;
    color: #7f1d1d !important;
    -webkit-text-fill-color: #7f1d1d !important;
}

html body .ejar-entities-dashboard .ejar-delete-warning,
html body .ejar-dashboard .ejar-delete-warning {
    margin: 0 0 12px;
    color: #7f1d1d !important;
    -webkit-text-fill-color: #7f1d1d !important;
    font-weight: 600;
    line-height: 1.45;
}

html body .ejar-entities-dashboard .ejar-delete-confirm-line,
html body .ejar-dashboard .ejar-delete-confirm-line {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    margin: 10px 0 14px;
    color: #7f1d1d !important;
    -webkit-text-fill-color: #7f1d1d !important;
    font-weight: 700;
    line-height: 1.4;
}

html body .ejar-entities-dashboard .ejar-delete-confirm-line input,
html body .ejar-dashboard .ejar-delete-confirm-line input {
    flex: 0 0 auto;
    margin-top: 3px;
}

/* Version 3.1.121 - correction esthétique confirmation suppression + réglage relances */
html body .ejar-entities-dashboard .ejar-delete-confirm-line,
html body .ejar-dashboard .ejar-delete-confirm-line {
    display: grid !important;
    grid-template-columns: 22px minmax(0, 1fr) !important;
    align-items: flex-start !important;
    gap: 10px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    margin: 12px 0 14px !important;
    padding: 12px 14px !important;
    border: 1px solid rgba(185, 28, 28, .22) !important;
    border-radius: 14px !important;
    background: rgba(255,255,255,.78) !important;
    color: #7f1d1d !important;
    -webkit-text-fill-color: #7f1d1d !important;
    font-size: 13px !important;
    line-height: 1.45 !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    text-align: left !important;
    white-space: normal !important;
}

html body .ejar-entities-dashboard .ejar-delete-confirm-line input[type="checkbox"],
html body .ejar-dashboard .ejar-delete-confirm-line input[type="checkbox"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    margin: 1px 0 0 !important;
    accent-color: #991b1b !important;
}

html body .ejar-entities-dashboard .ejar-delete-confirm-line span,
html body .ejar-dashboard .ejar-delete-confirm-line span {
    display: block !important;
    min-width: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    color: #7f1d1d !important;
    -webkit-text-fill-color: #7f1d1d !important;
    overflow-wrap: anywhere !important;
    word-break: normal !important;
    white-space: normal !important;
    text-shadow: none !important;
    background: transparent !important;
}

html body .ejar-relance-settings-card {
    display: flex !important;
    justify-content: space-between !important;
    gap: 18px !important;
    align-items: center !important;
    margin: 16px 0 !important;
    padding: 18px !important;
    border: 1px solid rgba(183, 137, 50, .26) !important;
    background: linear-gradient(135deg, rgba(255,255,255,.96), rgba(255,248,235,.92)) !important;
    box-shadow: 0 12px 28px rgba(17,24,39,.08) !important;
}

html body .ejar-relance-settings-copy h3 {
    margin: 0 0 6px !important;
    color: #111827 !important;
    -webkit-text-fill-color: #111827 !important;
    font-size: 18px !important;
    font-weight: 900 !important;
}

html body .ejar-relance-settings-copy p {
    margin: 0 !important;
    color: #4b5563 !important;
    -webkit-text-fill-color: #4b5563 !important;
    line-height: 1.45 !important;
}

html body .ejar-relance-settings-form {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    margin: 0 !important;
}

html body .ejar-relance-toggle-line {
    display: inline-flex !important;
    align-items: center !important;
    gap: 9px !important;
    margin: 0 !important;
    padding: 10px 12px !important;
    border-radius: 999px !important;
    background: #111827 !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-size: 13px !important;
    font-weight: 850 !important;
    line-height: 1.25 !important;
    cursor: pointer !important;
}

html body .ejar-relance-toggle-line input[type="checkbox"] {
    width: 17px !important;
    height: 17px !important;
    min-width: 17px !important;
    margin: 0 !important;
    accent-color: #d6b46d !important;
}

html body .ejar-relance-toggle-line span {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    white-space: normal !important;
}

@media (max-width: 760px) {
    html body .ejar-relance-settings-card {
        display: block !important;
    }
    html body .ejar-relance-settings-form {
        justify-content: flex-start !important;
        margin-top: 14px !important;
    }
    html body .ejar-relance-toggle-line {
        border-radius: 14px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* E-Jar v3.1.129 — guide clair de création / affiliation */
.ejar-affiliation-guide-card {
    border: 1px solid rgba(212, 175, 55, 0.22);
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(250,246,236,0.94));
}
.ejar-affiliation-flow {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 14px 0;
    align-items: center;
}
.ejar-affiliation-flow span {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 10px 14px;
    border-radius: 999px;
    background: #0f172a;
    color: #fff;
    font-weight: 800;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
    position: relative;
}
.ejar-affiliation-flow span:not(:last-child)::after {
    content: '→';
    color: #c99a2e;
    font-weight: 900;
    margin-left: 12px;
}
@media (max-width: 720px) {
    .ejar-affiliation-flow {
        display: grid;
        grid-template-columns: 1fr;
    }
    .ejar-affiliation-flow span {
        justify-content: center;
        border-radius: 18px;
        text-align: center;
    }
    .ejar-affiliation-flow span:not(:last-child)::after {
        content: '↓';
        margin-left: 10px;
    }
}

/* E-Jar v3.1.130 — lisibilité guide affiliation + création/ conversion gestionnaire */
html body .ejar-affiliation-guide-card .ejar-affiliation-flow > span {
    background: linear-gradient(135deg, #0f172a 0%, #172033 64%, #2a210b 100%) !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    border: 1px solid rgba(212, 175, 55, 0.38) !important;
    text-shadow: none !important;
}
html body .ejar-affiliation-guide-card .ejar-affiliation-flow > span * {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
html body .ejar-affiliation-guide-card .ejar-affiliation-flow > span::after {
    color: #d4af37 !important;
    -webkit-text-fill-color: #d4af37 !important;
}
html body .ejar-gestionnaire-create-card .ejar-manager-mode-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 18px;
    align-items: start;
    margin-top: 18px;
}
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card {
    padding: 20px;
    border-radius: 22px;
    border: 1px solid rgba(185, 135, 34, 0.24);
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(250,246,236,0.86));
    box-shadow: 0 14px 34px rgba(40, 30, 12, 0.06);
}
html body .ejar-gestionnaire-create-card .ejar-manager-convert-card {
    border-color: rgba(212, 175, 55, 0.42);
    background: linear-gradient(135deg, #ffffff 0%, #fffaf0 100%);
}
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card h3 {
    margin-top: 0;
    color: #111827 !important;
    -webkit-text-fill-color: #111827 !important;
}
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card .ejar-button,
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card button[type="submit"] {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-weight: 900 !important;
}
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card .ejar-button:hover,
html body .ejar-gestionnaire-create-card .ejar-manager-mode-card button[type="submit"]:hover {
    color: #111111 !important;
    -webkit-text-fill-color: #111111 !important;
}
@media (max-width: 720px) {
    html body .ejar-gestionnaire-create-card .ejar-manager-mode-grid {
        grid-template-columns: 1fr;
    }
}
