/* ==========================================================================
   Trésorerie Amicale CS SGDB — design system du module
   Cohérent avec cs_ui.css (--cs-primary #0f4c81, accent #e63946, rayon 16 px)
   ========================================================================== */
:root {
  --t-navy: #0b2f52;
  --t-navy-2: #0f3d68;
  --t-primary: #0f4c81;
  --t-primary-50: #eaf2fb;
  --t-accent: #e63946;
  --t-bg: #f3f5f9;
  --t-card: #ffffff;
  --t-text: #1c2735;
  --t-muted: #687587;
  --t-border: #e4e8ef;
  --t-in: #0e9f6e;
  --t-in-50: #e7f7f0;
  --t-out: #d63b3b;
  --t-out-50: #fdecec;
  --t-warn: #d97706;
  --t-radius: 16px;
  --t-radius-sm: 10px;
  --t-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 6px 20px rgba(16, 24, 40, .05);
  --t-shadow-lg: 0 12px 40px rgba(11, 47, 82, .16);
  --t-side: 256px;
  --t-tabbar: 64px;
  --bs-primary: #0f4c81;
  --bs-primary-rgb: 15, 76, 129;
  --bs-body-font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --bs-body-color: var(--t-text);
  --bs-body-bg: var(--t-bg);
  --bs-border-color: var(--t-border);
  --bs-link-color: var(--t-primary);
  --bs-link-color-rgb: 15, 76, 129;
}

.treso { background: var(--t-bg); color: var(--t-text); -webkit-font-smoothing: antialiased; }
.treso .num, .treso .t-amount, .treso td.t-right { font-variant-numeric: tabular-nums; }
.treso-skip { position: absolute; z-index: 2000; top: 8px; left: 8px; background: #fff; padding: 8px 12px; border-radius: 8px; }

/* Boutons Bootstrap aux couleurs du site */
.treso .btn-primary { --bs-btn-bg: var(--t-primary); --bs-btn-border-color: var(--t-primary); --bs-btn-hover-bg: #0a3a63; --bs-btn-hover-border-color: #0a3a63; --bs-btn-active-bg: #082f51; --bs-btn-disabled-bg: var(--t-primary); --bs-btn-disabled-border-color: var(--t-primary); }
.treso .btn-outline-primary { --bs-btn-color: var(--t-primary); --bs-btn-border-color: rgba(15,76,129,.45); --bs-btn-hover-bg: var(--t-primary); --bs-btn-hover-border-color: var(--t-primary); --bs-btn-active-bg: var(--t-primary); }
.treso .btn { border-radius: 10px; font-weight: 500; }
.treso .form-control, .treso .form-select { border-radius: 10px; border-color: #d9dfe8; min-height: 44px; }
.treso .form-control:focus, .treso .form-select:focus { border-color: #5b8fc4; box-shadow: 0 0 0 .2rem rgba(15,76,129,.14); }
.treso .form-label { font-size: .82rem; font-weight: 600; color: #3b4859; margin-bottom: .35rem; }

/* ---------------------------------------------------------------- Shell */
.treso-shell { min-height: 100vh; }
.treso-side {
  position: fixed; inset: 0 auto 0 0; width: var(--t-side); z-index: 1030;
  background: linear-gradient(180deg, var(--t-navy) 0%, #0a2744 100%);
  color: #dbe6f3; display: flex; flex-direction: column; padding: 20px 14px;
}
.treso-brand { display: flex; align-items: center; gap: 12px; padding: 4px 10px 22px; }
.treso-brand strong { display: block; color: #fff; font-size: 1.05rem; letter-spacing: .2px; }
.treso-brand small { display: block; color: #8fb0d3; font-size: .75rem; }
.treso-brand-logo {
  width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #e63946, #f0776f); box-shadow: 0 6px 16px rgba(230,57,70,.35);
}
.treso-nav { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; }
.treso-nav a {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px;
  color: #c4d4e6; text-decoration: none; font-weight: 500; font-size: .93rem; transition: background .15s, color .15s;
}
.treso-nav a i { width: 20px; text-align: center; color: #7fa2c8; transition: color .15s; }
.treso-nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.treso-nav a.active { background: rgba(255,255,255,.12); color: #fff; box-shadow: inset 3px 0 0 #e63946; }
.treso-nav a.active i, .treso-nav a:hover i { color: #fff; }
.treso-side-foot { margin-top: auto; border-top: 1px solid rgba(255,255,255,.08); padding-top: 14px; }
.treso-user { display: flex; align-items: center; gap: 10px; padding: 0 8px 12px; }
.treso-user strong { display: block; color: #fff; font-size: .88rem; }
.treso-user small { display: block; color: #8fb0d3; font-size: .75rem; }
.treso-avatar {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: #1d5a92; color: #fff; font-weight: 700; font-size: .82rem; text-transform: uppercase;
}
.treso-back { display: block; padding: 9px 12px; border-radius: 10px; color: #c4d4e6; text-decoration: none; font-size: .88rem; }
.treso-back:hover { background: rgba(255,255,255,.06); color: #fff; }

.treso-main { margin-left: var(--t-side); min-height: 100vh; display: flex; flex-direction: column; }
.treso-top {
  position: sticky; top: 0; z-index: 1020; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 28px; background: rgba(243,245,249,.86); backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid rgba(228,232,239,.8);
}
.treso-top-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.treso-top h1 { font-size: 1.35rem; font-weight: 700; margin: 0; letter-spacing: -.2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.treso-top-brand { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #e63946, #f0776f); flex: none; }
.treso-top-actions { display: flex; align-items: center; gap: 10px; }
.treso-ex-btn { background: #fff; border: 1px solid var(--t-border); min-height: 40px; display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; }
.treso-ex-btn:hover { border-color: #c9d3e0; background: #fff; }
.treso-btn-new { min-height: 40px; box-shadow: 0 6px 16px rgba(15,76,129,.22); }
.treso-banner { margin: 16px 28px 0; padding: 10px 14px; border-radius: 12px; background: #fff7e6; color: #8a5300; border: 1px solid #fde3b0; font-size: .9rem; }
.treso-content { padding: 24px 28px 48px; flex: 1; width: 100%; max-width: 1480px; }

/* Barre d'onglets mobile */
.treso-tabbar { display: none; }
.treso-sheet { border-radius: 20px 20px 0 0; height: auto !important; max-height: 80vh; }
.treso-sheet-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.treso-sheet-grid a {
  display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 6px; border-radius: 14px;
  background: var(--t-bg); color: var(--t-text); text-decoration: none; font-size: .8rem; text-align: center; font-weight: 500;
}
.treso-sheet-grid a i { font-size: 1.25rem; color: var(--t-primary); }
.treso-sheet-grid a.active { background: var(--t-primary-50); color: var(--t-primary); }

/* ---------------------------------------------------------------- Cartes */
.t-card { background: var(--t-card); border: 1px solid var(--t-border); border-radius: var(--t-radius); box-shadow: var(--t-shadow); }
.t-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px 0; }
.t-card-head h2 { font-size: 1rem; font-weight: 700; margin: 0; }
.t-card-head .t-sub { color: var(--t-muted); font-size: .8rem; }
.t-card-body { padding: 16px 20px 20px; }
.t-section-title { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--t-muted); margin: 28px 0 12px; }

.t-hero {
  position: relative; overflow: hidden; border-radius: 20px; color: #fff; padding: 26px 28px;
  background: radial-gradient(1200px 300px at 100% 0%, rgba(230,57,70,.28), transparent 60%), linear-gradient(135deg, #0b2f52, #12528c);
  box-shadow: var(--t-shadow-lg);
}
.t-hero-label { font-size: .85rem; color: #b8cde4; font-weight: 500; }
.t-hero-value { font-size: clamp(2rem, 5vw, 2.8rem); font-weight: 750; letter-spacing: -1px; line-height: 1.1; margin: 6px 0 4px; font-variant-numeric: tabular-nums; }
.t-hero-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 14px; font-size: .86rem; color: #d4e2f1; }
.t-hero-meta strong { color: #fff; font-variant-numeric: tabular-nums; }
.t-hero-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.12); font-size: .78rem; }

.t-kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(235px, 1fr)); gap: 14px; }
.t-kpi { padding: 16px 18px; display: flex; gap: 14px; align-items: flex-start; transition: transform .15s, box-shadow .15s; text-decoration: none; color: inherit; }
a.t-kpi:hover { transform: translateY(-2px); box-shadow: var(--t-shadow-lg); color: inherit; }
.t-kpi-ico { width: 40px; height: 40px; border-radius: 12px; flex: none; display: grid; place-items: center; font-size: 1rem; }
.t-kpi-label { font-size: .78rem; color: var(--t-muted); font-weight: 600; }
.t-kpi-value { font-size: 1.3rem; font-weight: 700; letter-spacing: -.3px; font-variant-numeric: tabular-nums; line-height: 1.25; margin-top: 2px; }
.t-kpi-sub { font-size: .75rem; color: var(--t-muted); margin-top: 2px; }
.ico-blue { background: var(--t-primary-50); color: var(--t-primary); }
.ico-green { background: var(--t-in-50); color: var(--t-in); }
.ico-red { background: var(--t-out-50); color: var(--t-out); }
.ico-amber { background: #fff4e0; color: var(--t-warn); }
.ico-violet { background: #f1ecff; color: #6d4bd8; }
.ico-slate { background: #eef1f5; color: #475569; }

.t-in { color: var(--t-in) !important; }
.t-out { color: var(--t-out) !important; }

/* Bloc d'attention */
.t-attention { list-style: none; margin: 0; padding: 0; }
.t-attention li + li { border-top: 1px solid var(--t-border); }
.t-attention a, .t-attention span.t-att {
  display: flex; align-items: center; gap: 12px; padding: 12px 4px; color: var(--t-text); text-decoration: none; font-size: .9rem;
}
.t-attention a:hover { color: var(--t-primary); }
.t-att-ico { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; font-size: .85rem; }
.t-att-warning .t-att-ico { background: #fff4e0; color: var(--t-warn); }
.t-att-danger .t-att-ico { background: var(--t-out-50); color: var(--t-out); }
.t-att-info .t-att-ico { background: var(--t-primary-50); color: var(--t-primary); }
.t-att-secondary .t-att-ico { background: #eef1f5; color: #475569; }
.t-all-good { display: flex; align-items: center; gap: 12px; color: var(--t-in); font-weight: 500; padding: 8px 0; }

/* Graphiques */
.t-chart { position: relative; height: 280px; }
.t-chart.sm { height: 240px; }
.t-legend { display: flex; flex-direction: column; gap: 8px; font-size: .84rem; }
.t-legend-row { display: flex; align-items: center; gap: 8px; }
.t-legend-dot { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.t-legend-row .num { margin-left: auto; font-weight: 600; }
.t-seg { display: inline-flex; background: var(--t-bg); border-radius: 10px; padding: 3px; gap: 2px; }
.t-seg button { border: 0; background: transparent; padding: 5px 12px; border-radius: 8px; font-size: .8rem; font-weight: 600; color: var(--t-muted); }
.t-seg button.active { background: #fff; color: var(--t-text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }

/* Enveloppes */
.t-env { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 10px 0; border-bottom: 1px solid var(--t-border); }
.t-env:last-child { border-bottom: 0; }
.t-env-name { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: .9rem; min-width: 0; }
.t-env-name span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-env-val { font-weight: 700; font-variant-numeric: tabular-nums; font-size: .9rem; text-align: right; }
.t-env-bar { grid-column: 1 / -1; height: 6px; background: #edf1f6; border-radius: 99px; overflow: hidden; }
.t-env-bar > span { display: block; height: 100%; border-radius: 99px; transition: width .6s ease; }
.t-env-meta { grid-column: 1 / -1; font-size: .74rem; color: var(--t-muted); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- Opérations */
.t-cat { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.t-cat-dot { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; flex: none; font-size: .78rem; color: #fff; }
.t-cat-name { font-size: .84rem; color: #3b4859; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-amount { font-weight: 700; white-space: nowrap; }
.t-amount.in { color: var(--t-in); }
.t-amount.out { color: var(--t-out); }
.t-amount.neutral { color: #475569; }
.t-annulee { opacity: .55; }
.t-annulee .t-amount, .t-annulee .t-lib { text-decoration: line-through; }

.t-badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; white-space: nowrap; }
.t-badge.brouillon { background: #fff4e0; color: #9a5b00; }
.t-badge.validee { background: var(--t-in-50); color: #0b7a55; }
.t-badge.annulee { background: #eef1f5; color: #64748b; }
.t-badge.rapprochee { background: var(--t-primary-50); color: var(--t-primary); }
.t-badge.anomalie { background: var(--t-out-50); color: var(--t-out); }
.t-badge.transfert { background: #f1ecff; color: #6d4bd8; }
.t-badge.cp { background: #eef1f5; color: #475569; }

.t-filters { padding: 14px; }
.t-filters .form-control, .t-filters .form-select { min-height: 40px; font-size: .9rem; }
.t-search { position: relative; }
.t-search i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--t-muted); }
.t-search input { padding-left: 40px; }
.t-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.t-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 6px 4px 10px; border-radius: 999px; background: var(--t-primary-50); color: var(--t-primary); font-size: .78rem; font-weight: 600; text-decoration: none; }
.t-chip i { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; }
.t-chip:hover i { background: rgba(15,76,129,.15); }

.t-summary { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; padding: 12px 18px; font-size: .86rem; color: var(--t-muted); border-bottom: 1px solid var(--t-border); }
.t-summary strong { color: var(--t-text); font-variant-numeric: tabular-nums; }

.t-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .9rem; }
.t-table thead th {
  position: sticky; top: 69px; z-index: 2; background: #f8fafc; color: var(--t-muted); font-size: .74rem; text-transform: uppercase;
  letter-spacing: .5px; font-weight: 700; padding: 11px 14px; border-bottom: 1px solid var(--t-border); white-space: nowrap;
}
.t-table thead th a { color: inherit; text-decoration: none; }
.t-table thead th a:hover, .t-table thead th a.sorted { color: var(--t-primary); }
.t-table tbody td { padding: 12px 14px; border-bottom: 1px solid #eef1f5; vertical-align: middle; }
.t-table tbody tr { cursor: pointer; transition: background .12s; }
.t-table tbody tr:hover { background: #f7f9fc; }
.t-table tbody tr:focus-visible { outline: 2px solid var(--t-primary); outline-offset: -2px; }
.t-table .t-right { text-align: right; }
.t-lib { font-weight: 600; color: var(--t-text); }
.t-lib-sub { font-size: .76rem; color: var(--t-muted); }
.t-icons { color: #94a3b8; font-size: .8rem; display: inline-flex; gap: 6px; }

.t-op-cards { list-style: none; margin: 0; padding: 0; }
.t-op-card { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-bottom: 1px solid #eef1f5; cursor: pointer; }
.t-op-card:active { background: #f3f6fa; }
.t-op-card .t-cat-dot { width: 40px; height: 40px; border-radius: 12px; font-size: .95rem; }
.t-op-card-main { flex: 1; min-width: 0; }
.t-op-card-main .t-lib { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.t-op-card-meta { font-size: .76rem; color: var(--t-muted); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; margin-top: 2px; }
.t-op-card-right { text-align: right; flex: none; }

.t-pagination { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 18px; font-size: .86rem; color: var(--t-muted); }
.t-pagination .pagination { margin: 0; }
.t-pagination .page-link { border-radius: 8px !important; margin: 0 2px; border: 1px solid var(--t-border); color: var(--t-text); min-width: 36px; text-align: center; }
.t-pagination .active > .page-link { background: var(--t-primary); border-color: var(--t-primary); color: #fff; }

.t-empty { text-align: center; padding: 56px 20px; color: var(--t-muted); }
.t-empty i { font-size: 2.2rem; color: #c3cdd9; margin-bottom: 12px; }
.t-empty h3 { font-size: 1.05rem; color: var(--t-text); margin-bottom: 6px; }

/* ---------------------------------------------------------------- Modales */
.treso-modal .modal-content { border: 0; border-radius: 20px; box-shadow: var(--t-shadow-lg); }
.treso-modal .modal-header { border-bottom: 1px solid var(--t-border); padding: 16px 22px; }
.treso-modal .modal-body { padding: 20px 22px; }
.treso-modal .modal-footer { border-top: 1px solid var(--t-border); padding: 12px 22px; gap: 8px; }
.treso-modal-foot { position: sticky; bottom: 0; background: #fff; border-radius: 0 0 20px 20px; padding-bottom: max(12px, env(safe-area-inset-bottom)) !important; }
.treso-modal-foot .btn { min-height: 44px; }

.treso-sens { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; background: var(--t-bg); padding: 4px; border-radius: 14px; margin-bottom: 16px; }
.treso-sens-btn { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px; border-radius: 11px; font-weight: 600; color: var(--t-muted); cursor: pointer; transition: all .15s; margin: 0; }
.btn-check:checked + .treso-sens-btn.depense { background: #fff; color: var(--t-out); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.btn-check:checked + .treso-sens-btn.recette { background: #fff; color: var(--t-in); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.btn-check:disabled + .treso-sens-btn { cursor: not-allowed; }
.btn-check:focus-visible + .treso-sens-btn { outline: 2px solid var(--t-primary); }

.treso-amount { position: relative; margin-bottom: 18px; }
.treso-amount input {
  font-size: 2rem; font-weight: 700; text-align: center; height: 68px; border-radius: 14px; padding-right: 44px; padding-left: 44px;
  font-variant-numeric: tabular-nums; letter-spacing: -.5px;
}
.treso-amount-cur { position: absolute; right: 18px; top: 34px; transform: translateY(-50%); font-size: 1.4rem; color: var(--t-muted); font-weight: 600; pointer-events: none; }
.treso-amount.depense input { color: var(--t-out); }
.treso-amount.recette input { color: var(--t-in); }

.treso-fieldset { border: 1px solid var(--t-border); border-radius: 14px; padding: 14px 16px 16px; margin-bottom: 14px; }
.treso-fieldset legend { float: none; width: auto; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--t-muted); padding: 0 6px; margin: 0 0 6px -6px; }
.treso-fieldset legend i { color: var(--t-primary); margin-right: 4px; }
.treso-upload { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.treso-pending-files { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-direction: column; gap: 6px; }
.treso-pending-files li { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 10px; background: var(--t-bg); font-size: .84rem; }
.treso-pending-files li span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.treso-motif { background: #fff8eb; border: 1px solid #fde3b0; border-radius: 12px; padding: 12px 14px; }

/* Fiche détaillée */
.t-detail-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.t-detail-head .t-cat-dot { width: 52px; height: 52px; border-radius: 16px; font-size: 1.25rem; }
.t-detail-amount { font-size: 1.9rem; font-weight: 750; letter-spacing: -.6px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.t-detail-lib { font-weight: 600; font-size: 1.02rem; }
.t-dl { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border: 1px solid var(--t-border); border-radius: 14px; overflow: hidden; margin-bottom: 16px; }
.t-dl > div { padding: 10px 14px; border-bottom: 1px solid var(--t-border); min-width: 0; }
.t-dl > div:nth-child(odd) { border-right: 1px solid var(--t-border); }
.t-dl dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .4px; color: var(--t-muted); font-weight: 700; }
.t-dl dd { margin: 2px 0 0; font-size: .9rem; overflow-wrap: anywhere; }
.t-dl > div.full { grid-column: 1 / -1; border-right: 0; }
.t-files { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 12px; }
.t-file { position: relative; border: 1px solid var(--t-border); border-radius: 12px; padding: 10px; display: flex; gap: 8px; align-items: center; cursor: pointer; background: #fff; text-align: left; width: 100%; }
.t-file:hover { border-color: #b8c7d9; }
.t-file i.ft { font-size: 1.3rem; color: var(--t-out); }
.t-file i.ft.img { color: var(--t-primary); }
.t-file span { font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; }
.t-file-del { position: absolute; top: -8px; right: -8px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 1px 4px rgba(0,0,0,.2); color: var(--t-out); font-size: .7rem; }
.t-timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.t-timeline::before { content: ""; position: absolute; left: 11px; top: 4px; bottom: 4px; width: 2px; background: var(--t-border); }
.t-timeline li { position: relative; padding: 0 0 14px 34px; font-size: .84rem; }
.t-timeline li::before { content: ""; position: absolute; left: 6px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 3px solid var(--t-primary); }
.t-timeline li.creation::before, .t-timeline li.import::before { border-color: var(--t-in); }
.t-timeline li.annulation::before, .t-timeline li.contre_passation::before { border-color: var(--t-out); }
.t-timeline .when { color: var(--t-muted); font-size: .76rem; }
.t-diff { display: inline-flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.t-diff del { color: var(--t-out); background: var(--t-out-50); padding: 0 4px; border-radius: 4px; text-decoration: line-through; }
.t-diff ins { color: #0b7a55; background: var(--t-in-50); padding: 0 4px; border-radius: 4px; text-decoration: none; }
.treso-viewer { min-height: 60vh; display: grid; place-items: center; background: #1f2937; padding: 0; border-radius: 0 0 20px 20px; }
.treso-viewer img { max-width: 100%; max-height: 80vh; object-fit: contain; }
.treso-viewer iframe { width: 100%; height: 80vh; border: 0; background: #fff; }
.treso-loading { display: grid; place-items: center; padding: 48px; }

.treso-toasts { right: 16px; bottom: 16px; z-index: 1090; }
.treso-toasts .toast { border: 0; border-radius: 14px; box-shadow: var(--t-shadow-lg); }

@media (prefers-reduced-motion: no-preference) {
  .t-fade { animation: tFade .35s ease both; }
  @keyframes tFade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
}

/* ---------------------------------------------------------------- Responsive */
@media (max-width: 991.98px) {
  .treso-side { display: none; }
  .treso-main { margin-left: 0; }
  .treso-top { padding: 10px 14px; padding-top: max(10px, env(safe-area-inset-top)); }
  .treso-top h1 { font-size: 1.1rem; }
  .treso-content { padding: 14px 14px calc(var(--t-tabbar) + 28px + env(safe-area-inset-bottom)); }
  .treso-banner { margin: 10px 14px 0; }
  .treso-tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 1035;
    height: calc(var(--t-tabbar) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: rgba(255,255,255,.96); backdrop-filter: blur(12px); border-top: 1px solid var(--t-border);
  }
  .treso-tabbar a, .treso-tabbar button {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 0; background: none;
    color: #7a8799; text-decoration: none; font-size: .68rem; font-weight: 600;
  }
  .treso-tabbar i { font-size: 1.15rem; }
  .treso-tabbar a.active { color: var(--t-primary); }
  .treso-toasts { bottom: calc(var(--t-tabbar) + 84px + env(safe-area-inset-bottom)); left: 12px; right: 12px; }
  .treso-toasts .toast { width: 100%; }
  .t-table thead th { top: 57px; }
  .treso-fab { position: fixed; right: 16px; bottom: calc(var(--t-tabbar) + 16px + env(safe-area-inset-bottom)); z-index: 1036; width: 56px; height: 56px; border-radius: 18px; padding: 0; font-size: 1.3rem; box-shadow: 0 10px 24px rgba(15,76,129,.35); }
  .treso-ex-btn span { font-size: .82rem; }
}
@media (max-width: 575.98px) {
  .t-hero { padding: 20px; border-radius: 18px; }
  .t-kpis { grid-template-columns: 1fr 1fr; gap: 10px; }
  .t-kpi { flex-direction: column; gap: 10px; padding: 14px; }
  .t-kpi-value { font-size: 1.08rem; }
  .t-dl > div { padding: 8px 12px; }
  .treso-modal .modal-content { border-radius: 0; }
  .treso-modal-foot { border-radius: 0; }
  .treso-modal-foot .btn { flex: 1; }
  .treso-modal .modal-body { padding: 16px; }
  .treso-ex-btn .fa-calendar { display: none; }
  .t-chart { height: 240px; }
}
@media print {
  .treso-side, .treso-top, .treso-tabbar, .treso-fab { display: none !important; }
  .treso-main { margin: 0; }
}
.min-w-0 { min-width: 0; }
.t-hero-eq { margin: auto 0 0; padding-top: 22px; font-size: .9rem; }
.t-hero-eq > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed rgba(255,255,255,.14); }
.t-hero-eq dt { font-weight: 500; color: #b8cde4; }
.t-hero-eq dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.t-hero-eq .res { border-bottom: 0; border-top: 1px solid rgba(255,255,255,.35); margin-top: 2px; padding-top: 9px; }
.t-hero-eq .res dt, .t-hero-eq .res dd { color: #fff; font-weight: 700; }
@media (max-width: 575.98px) { .treso-modal-foot > .btn-light[data-bs-dismiss] { display: none; } }
/* Modales empilées (confirmation / visionneuse au-dessus de la fiche) */
#treso-confirm-modal, #treso-viewer-modal { z-index: 1065; }
.modal-backdrop ~ .modal-backdrop { z-index: 1060; }
.treso-banner-test { background: #f1ecff; color: #4c2a9e; border-color: #ddd1ff; }
/* Phase 5 : relevés, tableaux statiques, onglets */
.t-statement { margin: 0; font-size: .92rem; }
.t-statement > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--t-border); }
.t-statement dt { font-weight: 500; color: #3b4859; }
.t-statement dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.t-statement .tot { border-bottom: 1px solid var(--t-border); border-top: 1px solid var(--t-border); font-weight: 700; }
.t-statement .tot dt, .t-statement .tot dd { font-weight: 700; }
.t-table-static tbody tr { cursor: default; }
.t-table-static tbody tr:hover { background: transparent; }
.t-table thead th.t-right { text-align: right; }
.t-table .t-total td { font-weight: 700; background: #f8fafc; border-top: 2px solid var(--t-border); padding: 12px 14px; font-variant-numeric: tabular-nums; }
.t-budget-input { max-width: 130px; margin-left: auto; font-variant-numeric: tabular-nums; min-height: 36px !important; }
.t-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--t-border); margin-bottom: 16px; overflow-x: auto; scrollbar-width: none; }
.t-tabs a { padding: 10px 14px; color: var(--t-muted); font-weight: 600; text-decoration: none; border-bottom: 2px solid transparent; white-space: nowrap; font-size: .92rem; }
.t-tabs a.active { color: var(--t-primary); border-bottom-color: var(--t-primary); }
.t-tabs a:hover { color: var(--t-text); }
.t-stat-big { font-size: 1.6rem; font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: -.4px; }
.t-stat-label { font-size: .76rem; text-transform: uppercase; letter-spacing: .5px; color: var(--t-muted); font-weight: 700; }
.t-check-row { display: flex; gap: 12px; align-items: center; padding: 10px 14px; border-bottom: 1px solid #eef1f5; cursor: pointer; }
.t-check-row:hover { background: #f7f9fc; }
.t-check-row input { width: 20px; height: 20px; flex: none; }
.t-sticky-bar { position: sticky; bottom: 0; z-index: 5; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-top: 1px solid var(--t-border); padding: 12px 16px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; border-radius: 0 0 var(--t-radius) var(--t-radius); }
.t-ecart-ok { color: var(--t-in); }
.t-ecart-ko { color: var(--t-out); }
.t-account { padding: 18px 20px; }
.t-account-type { font-size: .72rem; text-transform: uppercase; letter-spacing: .5px; font-weight: 700; color: var(--t-muted); }
.t-account-name { font-weight: 700; font-size: 1.05rem; }
.t-account-solde { font-size: 1.7rem; font-weight: 750; letter-spacing: -.5px; font-variant-numeric: tabular-nums; margin: 6px 0; }
.t-step { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--t-border); }
.t-step:last-child { border-bottom: 0; }
.t-step-num { width: 30px; height: 30px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 700; font-size: .85rem; background: var(--t-primary-50); color: var(--t-primary); }
.t-step.ok .t-step-num { background: var(--t-in-50); color: var(--t-in); }
.t-step.ko .t-step-num { background: var(--t-out-50); color: var(--t-out); }
.t-json { font-size: .76rem; background: #f8fafc; border-radius: 8px; padding: 8px 10px; white-space: pre-wrap; word-break: break-word; max-height: 220px; overflow: auto; margin: 6px 0 0; }
@media (max-width: 575.98px) { .t-budget-input { max-width: 100px; } .t-table tbody td, .t-table thead th { padding: 10px 8px; } }
.t-table-static thead th { position: static; }
@media (max-width: 575.98px) {
  .t-budget-table .t-cat-dot { display: none; }
  .t-budget-table .t-budget-input { max-width: 86px; font-size: .85rem; padding: 4px 6px; }
  .t-budget-table td, .t-budget-table th { padding: 10px 6px; }
  .t-budget-table .t-lib { font-size: .85rem; white-space: normal; }
}
/* Phase 6 : assistant d'étapes */
.t-stepper { list-style: none; display: flex; gap: 8px; padding: 0; margin: 0 0 18px; counter-reset: s; flex-wrap: wrap; }
.t-stepper li { display: flex; align-items: center; gap: 8px; padding: 8px 14px 8px 8px; border-radius: 999px; background: #fff; border: 1px solid var(--t-border); font-weight: 600; font-size: .88rem; color: var(--t-muted); }
.t-stepper li span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--t-bg); font-size: .8rem; }
.t-stepper li.current { border-color: var(--t-primary); color: var(--t-primary); }
.t-stepper li.current span { background: var(--t-primary); color: #fff; }
.t-stepper li.done { color: var(--t-in); }
.t-stepper li.done span { background: var(--t-in-50); color: var(--t-in); }

/* ==========================================================================
   Demandes de remboursement — espace agent et trésorerie
   ========================================================================== */
.treso-nav-badge { margin-left: auto; background: var(--t-accent); color: #fff; border-radius: 999px; font-size: .72rem; font-weight: 700; padding: 1px 8px; min-width: 22px; text-align: center; }
.treso-agent { background: var(--t-bg); min-height: 100vh; }
.agent-top { background: linear-gradient(135deg, var(--t-navy), var(--t-navy-2)); color: #fff; border-bottom: 3px solid var(--t-accent); position: sticky; top: 0; z-index: 10; }
.agent-top-inner { max-width: 880px; margin: 0 auto; padding: 12px 16px; display: flex; align-items: center; gap: 12px; }
.agent-back { color: #fff; opacity: .85; font-size: 1.1rem; padding: 6px; }
.agent-back:hover { opacity: 1; color: #fff; }
.agent-kicker { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; opacity: .8; font-weight: 600; }
.agent-title { font-weight: 700; font-size: 1.05rem; }
.agent-main { max-width: 880px; margin: 0 auto; padding: 20px 16px 48px; }
.agent-card { padding: 22px; }
.agent-hero { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.agent-liste { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.agent-item { display: flex; gap: 14px; align-items: center; padding: 14px 16px; text-decoration: none; color: inherit; transition: transform .12s, box-shadow .12s; }
.agent-item:hover { transform: translateY(-1px); box-shadow: var(--t-shadow-lg); color: inherit; }
.agent-item-ico { flex: 0 0 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--t-primary-50); color: var(--t-primary); font-size: 1.1rem; }
.agent-item-ico.noel { background: #fdecec; color: #c0262f; }
.agent-item-ico.lg { flex-basis: 52px; height: 52px; font-size: 1.35rem; }
.agent-statut { --c: #64748b; display: inline-block; padding: 5px 12px; border-radius: 999px; font-weight: 700; font-size: .8rem; color: var(--c); background: color-mix(in srgb, var(--c) 12%, #fff); border: 1px solid color-mix(in srgb, var(--c) 30%, #fff); white-space: nowrap; }
.agent-statut.sm { padding: 2px 9px; font-size: .72rem; margin-top: 3px; }
.agent-montants { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 18px 0; }
.agent-montants > div { background: var(--t-bg); border-radius: 12px; padding: 12px 14px; }
.agent-montants span { display: block; font-size: .75rem; color: var(--t-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.agent-montants strong { font-size: 1.25rem; }
.agent-montants .ok { background: var(--t-in-50); }
.agent-montants .ok strong { color: var(--t-in); }
.agent-refus { background: var(--t-out-50); border-left: 4px solid var(--t-out); border-radius: 10px; padding: 12px 14px; margin: 12px 0; font-size: .9rem; }
.agent-refus small { display: block; color: var(--t-muted); margin-top: 6px; }
.agent-enfants { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.agent-enfant { display: flex; gap: 10px; align-items: flex-start; border-radius: 12px; padding: 12px; border: 1px solid; }
.agent-enfant > i { font-size: 1.2rem; margin-top: 2px; }
.agent-enfant.ok { background: var(--t-in-50); border-color: #bfe9d6; }
.agent-enfant.ok > i, .agent-enfant.ok .fw-semibold { color: var(--t-in); }
.agent-enfant.ko { background: var(--t-out-50); border-color: #f6caca; }
.agent-enfant.ko > i, .agent-enfant.ko .fw-semibold { color: var(--t-out); }
.agent-bulle { background: var(--t-bg); border-radius: 4px 12px 12px 12px; padding: 8px 12px; margin-top: 6px; white-space: normal; }
.agent-bulle.moi { background: var(--t-primary-50); }
.agent-reponse { border-top: 1px solid var(--t-border); margin-top: 8px; padding-top: 16px; }
.agent-success { display: flex; gap: 12px; align-items: flex-start; background: var(--t-in-50); border: 1px solid #bfe9d6; color: #0b6b4b; border-radius: 12px; padding: 14px 16px; }
.agent-success > i { font-size: 1.4rem; }
.agent-rappel { display: flex; gap: 12px; align-items: flex-start; background: #fff7e6; border: 1px solid #fbd99a; border-radius: 12px; padding: 12px 14px; margin-bottom: 14px; font-size: .9rem; }
.agent-rappel > i { color: #c0262f; font-size: 1.3rem; margin-top: 2px; }
.agent-noel { margin-bottom: 6px; }
.agent-enfant-saisie { display: grid; grid-template-columns: 1fr 170px 44px; gap: 8px; margin-bottom: 8px; }
.agent-upload { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.agent-upload-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 18px 10px; border: 2px dashed #b9c6d8; border-radius: 14px; background: #fafcff; color: var(--t-primary); font-weight: 600; cursor: pointer; text-align: center; font-size: .9rem; margin: 0; transition: background .15s, border-color .15s; }
.agent-upload-btn i { font-size: 1.5rem; }
.agent-upload-btn:hover { background: var(--t-primary-50); border-color: var(--t-primary); }
.btn-check:checked + .treso-sens-btn:not(.depense):not(.recette) { background: #fff; color: var(--t-primary); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.remb-kpi { display: flex; align-items: center; gap: 14px; padding: 16px 18px; text-decoration: none; color: inherit; border-left: 4px solid var(--c); }
.remb-kpi i { font-size: 1.4rem; color: var(--c); }
.remb-kpi strong { display: block; font-size: 1.5rem; line-height: 1.1; }
.remb-kpi span { color: var(--t-muted); font-size: .85rem; }
.remb-fichiers { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.remb-fichier { display: flex; flex-direction: column; border: 1px solid var(--t-border); border-radius: 12px; overflow: hidden; text-decoration: none; color: inherit; background: #fff; }
.remb-fichier:hover { box-shadow: var(--t-shadow-lg); }
.remb-fichier img { width: 100%; height: 130px; object-fit: cover; background: var(--t-bg); }
.remb-fichier-ico { height: 130px; display: grid; place-items: center; background: var(--t-out-50); color: var(--t-out); font-size: 2.4rem; }
.remb-fichier-nom { font-size: .75rem; padding: 6px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-remb-lien { display: flex; gap: 10px; align-items: center; border: 1px solid var(--t-border); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
@media (max-width: 575.98px) {
  .agent-card { padding: 16px; }
  .agent-upload { grid-template-columns: 1fr; }
  .agent-enfant-saisie { grid-template-columns: 1fr 140px 40px; }
  .agent-item { padding: 12px; gap: 10px; }
}
.agent-item > .flex-grow-1 { min-width: 0; flex: 1 1 0; }
.agent-item > .text-end { flex: 0 0 auto; }
.agent-liste, .agent-main { min-width: 0; }
@media (max-width: 767.98px) {
  .remb-kpi { padding: 10px 12px; gap: 10px; }
  .remb-kpi strong { font-size: 1.2rem; }
}
@media (max-width: 575.98px) {
  .remb-kpi { flex-direction: column; align-items: flex-start; gap: 4px; }
  .remb-kpi i { font-size: 1.1rem; }
  .remb-kpi span { font-size: .75rem; }
}
.treso-remb-choix { background: var(--t-primary-50); border: 1px solid #cfe0f3; border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; }
@media (max-width: 575.98px) {
  .agent-btn-envoyer, .agent-btn-annuler { width: 100%; margin-left: 0 !important; }
}

/* Messagerie */
.msg-dossiers .list-group-item { border: 0; border-radius: 8px; font-size: .9rem; padding-top: 7px; padding-bottom: 7px; }
.msg-dossiers .list-group-item.active { background: var(--t-primary-50); color: var(--t-primary); font-weight: 600; }
.msg-ligne { display: grid; grid-template-columns: minmax(140px, 220px) 1fr auto; gap: 12px; align-items: center; font-size: .9rem; color: var(--t-muted); }
.msg-ligne .msg-sujet { color: var(--t-text); }
.msg-ligne.non-lu { background: #f8fbff; }
.msg-ligne.non-lu .msg-de, .msg-ligne.non-lu .msg-sujet { font-weight: 700; color: var(--t-text); }
.msg-meta { font-size: .8rem; }
@media (max-width: 767.98px) {
  .msg-ligne { grid-template-columns: 1fr auto; gap: 2px 10px; }
  .msg-ligne .msg-sujet { grid-column: 1 / -1; grid-row: 2; }
}
.msg-entetes dt { color: var(--t-muted); font-weight: 600; }
.msg-entetes dd { margin-bottom: 4px; word-break: break-word; }
.msg-piece { padding: 8px 10px; border: 1px solid var(--t-border); border-radius: 10px; }
.msg-corps { display: block; width: 100%; min-height: 420px; border: 0; border-radius: 0 0 16px 16px; background: #fff; }
.msg-agents { max-height: 380px; overflow-y: auto; }
.msg-agent { display: flex; gap: 10px; align-items: flex-start; padding: 8px 12px; border-bottom: 1px solid #eef1f5; cursor: pointer; margin: 0; }
.msg-agent:last-child { border-bottom: 0; }
.msg-agent:hover { background: var(--t-bg); }
.msg-agent.sans { opacity: .6; cursor: not-allowed; }
.msg-agent .form-check-input { margin-top: 4px; flex-shrink: 0; }
.msg-barre { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 16px; border-bottom: 1px solid var(--t-border); background: #fafbfd; }
.msg-ligne-wrap { display: flex; align-items: center; gap: 10px; padding: 0 0 0 16px; }
.msg-ligne-wrap.non-lu { background: #f8fbff; }
.msg-ligne-wrap.selectionne { background: var(--t-primary-50); }
.msg-ligne-wrap .msg-sel { flex-shrink: 0; margin: 0; }
.msg-ligne-wrap .msg-etoile { font-size: .8rem; flex-shrink: 0; }
.msg-ligne-wrap .msg-ligne { flex-grow: 1; min-width: 0; padding: 10px 16px 10px 4px; text-decoration: none; }
.msg-ligne-wrap:hover { background: var(--t-bg); }
.mj-op { display: grid; grid-template-columns: 92px 1fr auto; gap: 12px; align-items: center; text-align: left; }
.mj-op small { display: block; color: var(--t-muted); font-size: .76rem; }
.mj-op-date { font-size: .82rem; font-variant-numeric: tabular-nums; }
.mj-op-lib { min-width: 0; }
.mj-op-lib strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.mj-op-droite { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.mj-op.active { background: var(--t-primary-50); color: var(--t-text); border-color: var(--t-primary); box-shadow: inset 3px 0 0 var(--t-primary); z-index: 2; }
.mj-op.active small { color: var(--t-muted); }
.mj-raisons { color: #0b7a55 !important; }
#mj-sugg-liste .mj-op { background: #f6fbf8; }
#mj-sugg-liste .mj-op.active { background: var(--t-primary-50); }
@media (max-width: 575.98px) { .mj-op { grid-template-columns: 1fr auto; } .mj-op-date { grid-column: 1 / -1; } }
.msg-suivi { display: inline-flex; align-items: center; gap: 6px; margin-left: 8px; vertical-align: middle; }
.msg-suivi .t-badge { font-size: .66rem; padding: 2px 7px; }
.msg-avatar { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--t-primary); color: #fff; font-size: .62rem; font-weight: 700; letter-spacing: .02em; }
.msg-suivi-panneau { background: #fbfcfe; }
.msg-suivi-ligne { display: flex; align-items: center; gap: 12px; text-align: left; }

/* Calendriers */
.cal-total { background: linear-gradient(135deg, #0b2f52, #12528c); color: #fff; }
.cal-total .t-stat-label, .cal-total .text-secondary { color: #c7d6e8 !important; }
.cal-total-valeur { font-size: 2.1rem; font-weight: 800; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.cal-billetage { font-variant-numeric: tabular-nums; }
.cal-groupe { border-top: 4px solid var(--g); overflow: hidden; }
.cal-groupe-tete { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--t-border); }
.cal-pastille { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--g); margin-right: 8px; vertical-align: 1px; }
.cal-table td, .cal-table th { font-variant-numeric: tabular-nums; }
.cal-table tfoot th, .cal-table tfoot td { background: #f8fafc; border-top: 2px solid var(--t-border); }
.cal-actions { width: 1%; }
.cal-recap .cal-total-ligne th, .cal-recap .cal-total-ligne td { background: var(--t-primary-50); font-weight: 800; color: var(--t-primary); border-top: 2px solid var(--t-primary); }
.cal-saisie { display: grid; gap: 8px; }
.cal-ligne { display: grid; grid-template-columns: 150px 1fr 90px; gap: 10px; align-items: center; }
.cal-ligne > label { font-weight: 600; font-size: .9rem; margin: 0; }
.cal-ligne > label i { width: 18px; color: var(--t-muted); }
.cal-sous { text-align: right; font-size: .85rem; color: var(--t-muted); font-variant-numeric: tabular-nums; }
.cal-separateur { font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--t-muted); margin-top: 6px; padding-top: 8px; border-top: 1px dashed var(--t-border); }
.cal-coupure { display: inline-block; min-width: 64px; text-align: center; padding: 4px 8px; border-radius: 6px; font-weight: 800; font-size: .85rem; color: #1e293b; border: 1px solid rgba(0,0,0,.08); }
.cal-coupure.c5 { background: #d8dde3; } .cal-coupure.c10 { background: #f5c9b8; } .cal-coupure.c20 { background: #bcd3ee; }
.cal-coupure.c50 { background: #f7d9a8; } .cal-coupure.c100 { background: #c9e4c5; }
.cal-billet .input-group input { font-weight: 700; }
.cal-recap-saisie { display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: 8px; margin-top: 14px; }
.cal-recap-saisie > div { background: var(--t-bg); border-radius: 10px; padding: 8px 12px; }
.cal-recap-saisie span { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--t-muted); font-weight: 700; }
.cal-recap-saisie strong { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.cal-recap-saisie .cal-grand { background: var(--t-primary); color: #fff; }
.cal-recap-saisie .cal-grand span { color: #c7d6e8; }
.cal-recap-saisie .cal-grand strong { font-size: 1.3rem; }
.cal-mini { background: var(--t-bg); border-radius: 10px; padding: 8px; }
.cal-mini span { display: block; font-size: .72rem; text-transform: uppercase; color: var(--t-muted); font-weight: 700; }
.cal-mini strong { font-variant-numeric: tabular-nums; }
.cal-mini-total { background: var(--t-primary-50); color: var(--t-primary); }
.cal-annule { background: #fafafa; }
.cal-couleur input { position: absolute; opacity: 0; }
.cal-couleur span { display: block; width: 30px; height: 30px; border-radius: 50%; cursor: pointer; border: 3px solid #fff; box-shadow: 0 0 0 1px var(--t-border); }
.cal-couleur input:checked + span { box-shadow: 0 0 0 2px var(--t-text); }
.cal-couleur input:focus-visible + span { outline: 2px solid var(--t-primary); outline-offset: 2px; }
@media (max-width: 575.98px) { .cal-ligne { grid-template-columns: 1fr; gap: 4px; } .cal-sous { text-align: left; } .cal-recap-saisie { grid-template-columns: 1fr; } }
@media print {
  .treso-side, .treso-top, .treso-tabbar, .cal-actions, .dropdown, form, .btn, .treso-banner-test { display: none !important; }
  .treso-main { margin: 0 !important; } .t-card { box-shadow: none !important; break-inside: avoid; }
  .cal-total { background: #fff !important; color: #000 !important; border: 2px solid #000; }
}
.cal-agent { min-width: 200px; }
.cal-table tfoot > tr > *, .cal-recap tfoot > tr > * { padding: 12px 14px; vertical-align: middle; font-variant-numeric: tabular-nums; }
.cal-secteurs { display: flex; flex-wrap: wrap; gap: 4px; }
.cal-secteur { display: inline-block; padding: 1px 8px; border-radius: 999px; background: color-mix(in srgb, var(--g) 14%, #fff); color: var(--t-text); border: 1px solid color-mix(in srgb, var(--g) 35%, #fff); font-size: .74rem; font-weight: 700; }
.cal-grille-secteurs { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 6px; }
.cal-sect { display: flex; flex-direction: column; align-items: flex-start; gap: 0; text-align: left; padding: 6px 9px; border-radius: 9px; border: 1px solid var(--t-border); border-left: 4px solid var(--g); background: #fff; line-height: 1.2; min-width: 0; }
.cal-sect strong { font-size: .84rem; }
.cal-sect small { font-size: .7rem; color: var(--t-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.cal-sect:not(:disabled):hover { background: var(--t-bg); }
.cal-sect:disabled { opacity: 1; cursor: default; }
.cal-sect.libre { background: #fff4f4; border-color: #f5c2c2; border-left-color: var(--t-out); }
.cal-sect.libre small { color: var(--t-out); font-weight: 600; }
.cal-grille-secteurs.seulement-libres .cal-sect:not(.libre) { display: none; }
.cal-aucun-libre { display: none; grid-column: 1 / -1; }
.cal-grille-secteurs.seulement-libres:not(:has(.cal-sect.libre)) .cal-aucun-libre { display: block; }
.cal-choix-secteurs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 5px; max-height: 300px; overflow-y: auto; padding: 2px; }
.cal-choix { position: relative; margin: 0; cursor: pointer; }
.cal-choix input { position: absolute; opacity: 0; }
.cal-choix span { display: block; padding: 5px 8px; border: 1px solid var(--t-border); border-radius: 8px; font-size: .82rem; font-weight: 600; line-height: 1.2; }
.cal-choix span small { display: block; font-weight: 400; font-size: .68rem; color: var(--t-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-choix input:checked + span { background: var(--t-primary); border-color: var(--t-primary); color: #fff; }
.cal-choix input:focus-visible + span { outline: 2px solid var(--t-primary); outline-offset: 1px; }
.cal-choix.pris { cursor: not-allowed; }
.cal-choix.pris span { background: #f1f5f9; color: #94a3b8; }
@media print { .cal-carte-secteurs .cal-grille-secteurs.seulement-libres .cal-sect:not(.libre) { display: flex; } }
.cal-alerte { display: inline-flex; gap: 5px; align-items: center; padding: 2px 9px; border-radius: 999px; background: rgba(255,255,255,.16); }
.cal-dep-type.ok { border-top: 3px solid var(--t-in); }
.cal-dep-type.neg { border-top: 3px solid var(--t-out); }
.cal-dep-lignes > div { display: flex; justify-content: space-between; gap: 8px; font-variant-numeric: tabular-nums; }
.cal-dep-types { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.cal-dep-types .btn { font-size: .82rem; font-weight: 600; padding: 8px 4px; }
@media (max-width: 575.98px) { .cal-dep-types { grid-template-columns: repeat(2, 1fr); } }
.cal-dep-env { border-top: 3px solid #d97706; }
.cal-dep-types { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 767.98px) { .cal-dep-types { grid-template-columns: repeat(3, 1fr); } }
.cal-ast-date { width: 46px; flex-shrink: 0; line-height: 1.1; }
.cal-ast-date small { display: block; text-transform: uppercase; font-size: .68rem; font-weight: 700; color: var(--t-muted); }
.cal-ast-date strong { font-size: 1.35rem; color: var(--t-primary); }
.cal-ast-table td { min-width: 110px; }
.cal-ast-table td:nth-child(4), .cal-ast-table td:nth-child(5) { min-width: 180px; }
.cal-ast-apercu { background: #eef2f7; border-radius: 10px; overflow: hidden; border: 1px solid var(--t-border); }
.ae-editeur { border-top: 1px solid var(--t-border); padding-top: 12px; }
@media (min-width: 992px) { .ae-apercu-col { position: sticky; top: 0; } }

/* Listes d'émargement */
.em-choix { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.em-option { --c: var(--t-primary); margin: 0; cursor: pointer; }
.em-option input { position: absolute; opacity: 0; pointer-events: none; }
.em-option span { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 14px 8px; border: 2px solid var(--t-border); border-radius: 14px; background: #fff; transition: border-color .15s, background .15s, box-shadow .15s; height: 100%; }
.em-option i { font-size: 1.3rem; color: var(--c); }
.em-option small { color: var(--t-muted, #64748b); }
.em-option input:checked + span { border-color: var(--c); background: color-mix(in srgb, var(--c) 8%, #fff); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 18%, transparent); }
.em-option input:focus-visible + span { outline: 2px solid var(--c); outline-offset: 2px; }
.em-item { cursor: default; }
@media (max-width: 575.98px) { .em-choix { grid-template-columns: 1fr; } .em-option span { flex-direction: row; justify-content: flex-start; gap: 10px; text-align: left; } .em-option small { margin-left: auto; } }

/* Cotisations */
.co-etat { --c: #64748b; display: inline-block; padding: 2px 9px; border-radius: 999px; font-weight: 600; font-size: .75rem; color: var(--c); background: color-mix(in srgb, var(--c) 12%, #fff); border: 1px solid color-mix(in srgb, var(--c) 28%, #fff); white-space: nowrap; }
.co-qualite { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.co-qualite.collecteur { color: #0e9f6e; }
.co-qualite.non_collecteur { color: #12528c; }
.co-motif { font-size: .78rem; color: var(--t-muted, #64748b); font-style: italic; }
.co-filtres .btn.active { background: var(--t-primary); color: #fff; border-color: var(--t-primary); }
.co-ligne-inactive td { opacity: .65; }
.co-equipe { display: inline-block; font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 6px; white-space: nowrap; background: #eef2f7; color: #475569; }
.co-equipe.equipe_a { background: #fde8ea; color: #b4232f; }
.co-equipe.equipe_b { background: #e3eef9; color: #12528c; }
.co-equipe.spv { background: #e2f6ee; color: #0b7a55; }

/* Carte des secteurs */
.ca-outils { position: absolute; left: 56px; top: 10px; z-index: 500; display: flex; flex-wrap: wrap; gap: 12px; background: rgba(255,255,255,.94); border-radius: 10px; padding: 6px 12px; box-shadow: 0 2px 10px rgba(15,23,42,.15); font-size: .8rem; }
.ca-dessin { position: absolute; right: 10px; bottom: 28px; z-index: 600; width: 280px; background: #fff; border-radius: 12px; padding: 12px 14px; box-shadow: 0 6px 24px rgba(15,23,42,.25); border-left: 4px solid var(--t-primary); }
.ca-compteur { font-size: 1.6rem; font-weight: 800; color: var(--t-primary); margin-top: 6px; line-height: 1.1; }
.ca-compteur span { font-variant-numeric: tabular-nums; }
.ca-chip { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; background: #eef2f7; color: #334155; font-weight: 600; }
.ca-chip.rouge { background: #fee2e2; color: #b91c1c; }
.ca-chip.vert { background: #dcfce7; color: #15803d; }
.ca-chip.orange { background: #ffedd5; color: #c2410c; }
.leaflet-tooltip.ca-label { background: rgba(255,255,255,.88); border: 0; box-shadow: 0 1px 4px rgba(0,0,0,.2); font-weight: 700; font-size: 11px; padding: 1px 6px; text-align: center; line-height: 1.15; color: #0f172a; }
.leaflet-tooltip.ca-label::before { display: none; }
.leaflet-tooltip.ca-label small { display: block; font-weight: 500; font-size: 10px; color: #475569; }
.ca-liste { max-height: calc(100vh - 330px); min-height: 200px; overflow: auto; }
.ca-sect { display: flex; align-items: center; gap: 10px; padding: 8px 14px; border-top: 1px solid var(--t-border); cursor: pointer; }
.ca-sect:hover { background: #f8fafc; }
.ca-sect.actif { background: var(--t-primary-50, #eaf2fb); }
.ca-pastille { flex: 0 0 12px; width: 12px; height: 12px; border-radius: 4px; }
.ca-nb { font-weight: 700; font-variant-numeric: tabular-nums; min-width: 44px; text-align: right; }
.ca-nb.vide { color: #94a3b8; font-weight: 400; }
.ca-gros { font-size: 1.8rem; font-weight: 800; color: var(--t-primary); line-height: 1.1; margin-bottom: 8px; }
.ca-gros small { font-size: .9rem; font-weight: 500; color: #64748b; }
#ca-rues { max-height: 360px; overflow: auto; }
.ca-rue summary { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 1px dashed var(--t-border); cursor: pointer; }
.ca-rue div { padding: 4px 0 8px; color: #475569; }
.ca-canevas { position: absolute; pointer-events: none; opacity: .9; }
.ca-outils .form-select { font-size: .78rem; padding-top: 1px; padding-bottom: 1px; }
.ca-couleur { position: relative; width: 22px; height: 22px; margin: 0; cursor: pointer; flex: 0 0 22px; }
.ca-couleur input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.ca-couleur span { display: block; width: 22px; height: 22px; border-radius: 6px; box-shadow: inset 0 0 0 2px rgba(255,255,255,.6), 0 0 0 1px rgba(15,23,42,.2); }
.ca-visibilite { border-radius: 10px; padding: 8px 12px; }
.ca-visibilite.ouvert { background: #ecfdf5; color: #065f46; }
.ca-visibilite.ferme { background: #f1f5f9; color: #334155; }
.ca-av { width: 30px; height: 30px; font-size: .72rem; flex: 0 0 30px; }
.ca-agents .list-group-item { background: transparent; }
.ca-choix-agents { max-height: 320px; overflow: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 2px 12px; }
.ca-choix-agent { display: flex; gap: 8px; align-items: flex-start; padding: 4px 2px; margin: 0; cursor: pointer; }
.ca-choix-agent small { display: block; }
#ca-detail { max-height: calc(100vh - 140px); overflow: auto; }

/* Carte des secteurs : plein écran */
.ca-si-plein { display: none; }
.ca-zone-plein { position: fixed; inset: 0; z-index: 1040; margin: 0 !important; padding: 8px 8px 8px 0; background: var(--t-bg, #f3f6fa); overflow: hidden; }
.ca-zone-plein .ca-si-plein { display: inline-block; }
.ca-zone-plein > [class*="col-"] { height: calc(100vh - 16px); }
.ca-zone-plein #ca-carte { height: calc(100vh - 16px) !important; min-height: 0 !important; }
.ca-zone-plein .ca-legende { display: none; }
.ca-zone-plein #ca-col-carte + div { display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.ca-zone-plein #ca-col-carte + div > section { margin: 0 !important; }
.ca-zone-plein #ca-detail { max-height: 58vh; flex: 0 0 auto; }
.ca-zone-plein .ca-liste { max-height: none; flex: 1 1 auto; min-height: 120px; }
.ca-zone-plein #ca-col-carte + div > section:last-child { display: flex; flex-direction: column; min-height: 0; flex: 1 1 auto; }
body.ca-body-plein { overflow: hidden; }
@media (max-width: 1199.98px) {
  .ca-zone-plein { padding: 0; }
  .ca-zone-plein #ca-col-carte { height: 100vh; padding: 0; }
  .ca-zone-plein #ca-carte { height: 100vh !important; }
  .ca-zone-plein #ca-col-carte + div { display: none; }
}

/* Espace Calendriers : en-tête et onglets */
.cal-entete { margin-bottom: 18px; }
.cal-entete-haut { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.cal-campagne { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--t-border); border-radius: 14px; padding: 6px 14px 6px 6px; box-shadow: 0 1px 2px rgba(15,23,42,.04); }
.cal-campagne:hover { border-color: #b9c6d8; }
.cal-campagne-ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: linear-gradient(135deg, var(--t-navy, #0b2f52), var(--t-primary, #12528c)); color: #fff; }
.cal-campagne-kicker { display: block; font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--t-muted, #64748b); font-weight: 600; line-height: 1.1; }
.cal-campagne-nom { display: block; font-weight: 700; font-size: 1.02rem; line-height: 1.25; }
.cal-onglets { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; background: #fff; border: 1px solid var(--t-border); border-radius: 14px; padding: 5px; }
.cal-onglets a { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border-radius: 10px; color: #475569; font-weight: 600; font-size: .88rem; text-decoration: none; white-space: nowrap; transition: background .15s, color .15s; }
.cal-onglets a:hover { background: #f1f5f9; color: var(--t-primary, #12528c); }
.cal-onglets a.active { background: var(--t-primary, #12528c); color: #fff; box-shadow: 0 4px 12px rgba(18,82,140,.25); }
.cal-onglets a .badge { font-size: .68rem; }
@media (max-width: 767.98px) { .cal-onglets a span:not(.badge) { display: none; } .cal-onglets a.active span:not(.badge) { display: inline; } }

/* Tableau de bord des calendriers */
.cal-tb-astuce { display: flex; gap: 12px; align-items: flex-start; background: #eef6ff; border: 1px solid #c9defa; color: #1e3a5f; border-radius: 12px; padding: 12px 16px; font-size: .9rem; }
.cal-tb-astuce > i { color: #f59e0b; font-size: 1.2rem; margin-top: 2px; }
.cal-tb-montant { font-size: 2.3rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; margin-top: 4px; }
.cal-tb-barre { height: 8px; border-radius: 99px; background: #e2e8f0; }
.cal-tb-barre .progress-bar { background: linear-gradient(90deg, #6366f1, #818cf8); border-radius: 99px; }
.cal-tb-barre.obj .progress-bar { background: linear-gradient(90deg, #10b981, #34d399); }
.cal-tb-periode { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 8px; font-size: .88rem; }
.cal-tb-periode > span { font-weight: 600; }
.cal-tb-plus { display: inline-flex; align-items: center; gap: 4px; color: #047857; background: #ecfdf5; border-radius: 99px; padding: 2px 9px; font-weight: 600; font-size: .8rem; white-space: nowrap; }
.cal-tb-graphe { position: relative; height: 290px; border-radius: 14px; background: linear-gradient(180deg, #f0fdf8, #fff); padding: 10px; }
.cal-tb-graphe.sm { height: 260px; background: none; padding: 0; }
.cal-tb-anneau { position: relative; height: 190px; }
.cal-tb-anneau-centre { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }
.cal-tb-anneau-centre strong { font-size: 2rem; line-height: 1; }
.cal-tb-anneau-centre span { font-size: .8rem; color: #64748b; }
.cal-tb-legende, .cal-tb-sect-lignes { list-style: none; padding: 0; margin: 12px 0 0; font-size: .82rem; }
.cal-tb-legende li, .cal-tb-sect-lignes li { display: flex; align-items: center; gap: 8px; padding: 2px 0; }
.cal-tb-legende li span, .cal-tb-sect-lignes li span { width: 18px; height: 7px; border-radius: 99px; flex: 0 0 18px; }
.cal-tb-legende li strong, .cal-tb-sect-lignes li strong { margin-left: auto; font-variant-numeric: tabular-nums; }
.cal-tb-kpi { position: relative; padding-right: 64px !important; }
.cal-tb-kpi-val { font-size: 1.8rem; font-weight: 700; line-height: 1.2; margin: 4px 0 2px; font-variant-numeric: tabular-nums; }
.cal-tb-kpi-ico { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 18%, #fff); color: var(--c); font-size: 1.1rem; }
.cal-tb-cartes { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 16px; }
.cal-tb-sect { display: block; padding: 18px 20px; color: inherit; text-decoration: none; transition: transform .12s, box-shadow .12s; }
.cal-tb-sect:hover { transform: translateY(-2px); box-shadow: var(--t-shadow-lg, 0 10px 24px rgba(15,23,42,.12)); color: inherit; }
.cal-tb-point { width: 11px; height: 11px; border-radius: 50%; flex: 0 0 11px; }
.cal-tb-avatars { display: flex; align-items: center; }
.cal-tb-avatars span { width: 26px; height: 26px; border-radius: 50%; background: #eef2f7; border: 2px solid #fff; display: grid; place-items: center; font-size: .62rem; font-weight: 700; color: #475569; margin-left: -6px; }
.cal-tb-avatars em { font-style: normal; font-size: .72rem; color: #64748b; margin-left: 4px; }
.cal-tb-sect-montant { font-size: 1.7rem; font-weight: 700; line-height: 1.2; }
.cal-tb-pile { display: flex; height: 10px; border-radius: 99px; background: #e2e8f0; overflow: hidden; }
.cal-tb-pile span { height: 100%; }
.cal-tb-sect-kpi { display: flex; justify-content: space-between; font-size: .84rem; padding: 2px 0; }
.cal-tb-sect-kpi i { width: 18px; }
.cal-resume td, .cal-resume th { white-space: nowrap; }
.cal-triable { cursor: pointer; user-select: none; }
.cal-triable[data-sens="asc"]::after { content: " ▲"; font-size: .65em; }
.cal-triable[data-sens="desc"]::after { content: " ▼"; font-size: .65em; }
@media print { .cal-tb-sect { break-inside: avoid; } }

/* Distributions à l'adresse */
.dist-liste { border-top: 1px solid var(--t-border); }
.dist-ligne { display: grid; grid-template-columns: minmax(130px, 1.1fr) minmax(220px, 2.6fr) auto auto auto auto 40px; align-items: center; gap: 10px; padding: 9px 16px; border-bottom: 1px solid var(--t-border); }
.dist-ligne:hover { background: #fafcff; }
.dist-ligne.annule { opacity: .55; }
.dist-ligne.annule .dist-pastille { text-decoration: line-through; }
.dist-agent { font-weight: 600; }
.dist-adresse { color: #475569; min-width: 0; }
.dist-secteur { display: inline-block; font-size: .7rem; font-weight: 700; background: #eef2f7; color: #475569; border-radius: 6px; padding: 1px 6px; margin-left: 4px; }
.dist-pastille { display: inline-block; white-space: nowrap; font-size: .76rem; font-weight: 600; padding: 3px 10px; border-radius: 99px; background: #eef2f7; color: #64748b; }
.dist-pastille.statut { --c: #64748b; background: color-mix(in srgb, var(--c) 16%, #fff); color: color-mix(in srgb, var(--c) 70%, #0f172a); }
.dist-pastille.don.plus { background: #dcfce7; color: #15803d; }
@media (max-width: 1199.98px) {
  .dist-ligne { grid-template-columns: 1fr auto; }
  .dist-agent { grid-column: 1; } .dist-actions { grid-column: 2; grid-row: 1; }
  .dist-adresse { grid-column: 1 / -1; }
  .dist-ligne .dist-pastille { justify-self: start; }
  .dist-ligne > .dist-pastille { grid-column: auto; }
}
.pas-statuts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; }
.pas-statut { --c: #64748b; display: flex; align-items: center; gap: 8px; justify-content: center; padding: 10px 8px; border: 2px solid color-mix(in srgb, var(--c) 35%, #fff); border-radius: 12px; cursor: pointer; font-weight: 600; font-size: .86rem; margin: 0; color: color-mix(in srgb, var(--c) 75%, #0f172a); background: #fff; }
.pas-statut i { color: var(--c); }
.btn-check:checked + .pas-statut { background: var(--c); border-color: var(--c); color: #fff; box-shadow: 0 4px 12px color-mix(in srgb, var(--c) 35%, transparent); }
.btn-check:checked + .pas-statut i { color: #fff; }
.btn-check:focus-visible + .pas-statut { outline: 2px solid var(--c); outline-offset: 2px; }
.pas-don { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 12px; padding: 12px; margin-bottom: 16px; }
.pas-suggestions { position: absolute; z-index: 20; left: 0; right: 0; max-height: 300px; overflow: auto; box-shadow: 0 10px 24px rgba(15,23,42,.15); }
.pas-adresse-choisie { display: flex; align-items: center; gap: 10px; border: 1px solid var(--t-border); border-radius: 10px; padding: 8px 10px; background: #f8fafc; }
.pas-badge { --c: #64748b; display: inline-block; font-size: .68rem; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: color-mix(in srgb, var(--c) 16%, #fff); color: color-mix(in srgb, var(--c) 70%, #0f172a); white-space: nowrap; }
.pas-badge.a-faire { background: #eef2f7; color: #64748b; }
.ca-legende-etats { position: absolute; left: 56px; bottom: 28px; z-index: 500; display: flex; flex-wrap: wrap; gap: 6px 12px; max-width: calc(100% - 380px); background: rgba(255,255,255,.95); border-radius: 10px; padding: 6px 12px; box-shadow: 0 2px 10px rgba(15,23,42,.15); font-size: .76rem; }
.ca-legende-etats span { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.ca-legende-etats i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
@media (max-width: 991.98px) { .ca-legende-etats { max-width: calc(100% - 70px); } }
.cp-lignes .cp-ligne { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: center; padding: 14px 20px; border-top: 1px solid var(--t-border); }
@media (max-width: 767.98px) { .cp-lignes .cp-ligne { grid-template-columns: 1fr; gap: 6px; } }
.cp-nouvelle { border-top: 4px solid #facc15; }

/* Comptage : détail des chèques */
.cal-cheques { background: #f8fafc; border: 1px solid var(--t-border); border-radius: 12px; padding: 10px 12px; margin: 6px 0 10px; }
.cal-cheques-tete { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; font-weight: 600; margin-bottom: 8px; }
.cal-cheques-tete i { color: var(--t-primary, #12528c); }
.cal-cheques-total { font-weight: 400; font-size: .88rem; color: #334155; }
.cal-cheque { display: grid; grid-template-columns: 34px minmax(110px, 140px) minmax(0, 1fr) 34px; gap: 6px; align-items: center; margin-bottom: 6px; }
.cal-cheque-n { font-size: .74rem; color: #64748b; font-weight: 600; }
@media (max-width: 575.98px) { .cal-cheque { grid-template-columns: 30px 1fr 34px; } .cal-cheque > input { grid-column: 2 / 4; grid-row: 2; } }
.t-statement > div.t-ouverture-edit { display: block; }
.t-ouverture-edit summary { color: var(--t-primary, #12528c); cursor: pointer; font-weight: 600; }
.t-sous-env td { background: #fafcff; }
.t-sous-cat { padding-left: 22px; gap: 8px; align-items: center; }
.t-sous-libre td { color: #475569; padding-top: 6px !important; padding-bottom: 10px !important; }
