/* ═══════════════════════════════════════════════════════════
   Prestij v2 — Design System
   Prestij · Abidjan, Côte d'Ivoire
   ═══════════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=DM+Mono:wght@400;500&display=swap');

:root {
  --navy:   #1A2B4A;
  --navy-h: #1e3255;
  --blue:   #2E5FA3;
  --teal:   #0E6655;
  --gold:   #E6A817;
  --gold-l: #F0BC47;
  --gold-d: rgba(230,168,23,.12);
  --orange: #C0620A;
  --green:  #1E6F3E;
  --red:    #B03030;
  --purple: #5B2C6F;
  --bg:     #EEF2F9;
  --card:   #FFFFFF;
  --border: #E2E8F0;
  --border-lt: #F1F5F9;
  --text:   #1A2B4A;
  --sub:    #64748B;
  --sub2:   #94A3B8;
  --mono:   'DM Mono', monospace;
  --sans:   'DM Sans', sans-serif;
  --radius: 10px;
  --shadow: 0 1px 4px rgba(26,43,74,.08);
  --shadow-md: 0 4px 16px rgba(26,43,74,.10);
  --shadow-lg: 0 8px 28px rgba(26,43,74,.14);
  --topbar-h:  60px;
  --sidebar-w: 215px;
}

*,*::before,*::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body { font-family: var(--sans); background: var(--bg); color: var(--text); line-height: 1.5; }
a { text-decoration: none; color: inherit; cursor: pointer; }
input,select,textarea,button { font-family: inherit; }

/* ── TOPBAR ───────────────────────────────────────────────── */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; height: var(--topbar-h);
  background: var(--navy); display: flex; align-items: center;
  padding: 0 20px; z-index: 100; gap: 14px;
  box-shadow: 0 2px 16px rgba(26,43,74,.35);
}
.topbar-left  { display: flex; align-items: center; gap: 12px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.logo {
  width: 34px; height: 34px; background: var(--gold); border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 13px; color: var(--navy); letter-spacing: -1px; flex-shrink: 0;
}
.app-name { font-size: 14px; font-weight: 700; color: #fff; line-height: 1; }
.app-sub  { font-size: 10px; color: rgba(255,255,255,.4); font-family: var(--mono); }
.topbar-sep { width: 1px; height: 22px; background: rgba(255,255,255,.15); }

.user-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 5px 10px 5px 5px; border-radius: var(--radius);
  cursor: pointer; transition: background .15s;
}
.user-chip:hover { background: rgba(255,255,255,.1); }
.user-avatar {
  width: 28px; height: 28px; background: var(--gold); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 11px; color: var(--navy); flex-shrink: 0;
}
.user-info { text-align: right; }
.user-info .u-nom  { font-size: 13px; font-weight: 600; color: #fff; line-height: 1.2; }
.user-info .u-role { font-size: 10px; color: rgba(255,255,255,.5); }

/* ── LAYOUT ─────────────────────────────────────────────── */
.layout {
  display: grid; grid-template-columns: var(--sidebar-w) 1fr;
  min-height: calc(100vh - var(--topbar-h)); margin-top: var(--topbar-h);
}

/* ── SIDEBAR ─────────────────────────────────────────────── */
.sidebar {
  background: var(--navy); padding: 10px 0 24px; overflow-y: auto;
  position: sticky; top: var(--topbar-h); height: calc(100vh - var(--topbar-h));
  border-right: 1px solid rgba(255,255,255,.07);
}
.nav-group-label {
  padding: 12px 16px 4px; font-size: 9px; font-weight: 700;
  color: rgba(255,255,255,.28); letter-spacing: 1.5px; text-transform: uppercase;
}
.nav-item {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 16px; margin: 1px 8px; border-radius: var(--radius);
  font-size: 13px; font-weight: 500; color: rgba(255,255,255,.58);
  transition: all .15s; white-space: nowrap; overflow: hidden; cursor: pointer;
  position: relative;
}
.nav-item svg { flex-shrink: 0; opacity: .75; }
.nav-item:hover { color: rgba(255,255,255,.92); background: rgba(255,255,255,.07); }
.nav-item.active {
  color: var(--gold); background: rgba(230,168,23,.12); font-weight: 600;
}
.nav-item.active::before {
  content: ''; position: absolute; left: -8px; top: 50%; transform: translateY(-50%);
  width: 3px; height: 18px; background: var(--gold); border-radius: 0 3px 3px 0;
}
.nav-item.active svg { opacity: 1; }
.nav-badge {
  background: var(--gold); color: var(--navy); font-size: 9px; font-weight: 700;
  padding: 1px 6px; border-radius: 10px; margin-left: auto;
}

/* ── MAIN ─────────────────────────────────────────────────── */
main { padding: 24px; overflow-y: auto; min-height: calc(100vh - var(--topbar-h)); }
.page-title { font-size: 1.429rem; font-weight: 700; margin-bottom: 4px; }
.page-sub   { font-size: 13px; color: var(--sub); margin-bottom: 20px; }

/* ── BUTTONS ─────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px;
  border-radius: 8px; border: 1.5px solid transparent;
  font-family: var(--sans); font-size: 13px; font-weight: 600;
  cursor: pointer; transition: all .15s; white-space: nowrap; line-height: 1;
}
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-navy   { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-navy:hover:not(:disabled)   { background: var(--navy-h); }
.btn-blue   { background: var(--blue); color: #fff; border-color: var(--blue); }
.btn-blue:hover:not(:disabled)   { background: #2451891; filter: brightness(1.1); }
.btn-gold   { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.btn-gold:hover:not(:disabled)   { background: var(--gold-l); }
.btn-green  { background: var(--green); color: #fff; border-color: var(--green); }
.btn-green:hover:not(:disabled)  { background: #165931; }
.btn-red    { background: var(--red); color: #fff; border-color: var(--red); }
.btn-red:hover:not(:disabled)    { background: #8f2323; }
.btn-orange { background: var(--orange); color: #fff; border-color: var(--orange); }
.btn-orange:hover:not(:disabled) { background: #9e4f08; }
.btn-outline {
  background: transparent; color: var(--navy);
  border-color: var(--border);
}
.btn-outline:hover:not(:disabled) { border-color: var(--navy); background: var(--navy); color: #fff; }
.btn-ghost-sm {
  background: rgba(255,255,255,.1); color: rgba(255,255,255,.85);
  border: 1px solid rgba(255,255,255,.2); padding: 6px 12px; font-size: 12px; border-radius: 7px;
}
.btn-ghost-sm:hover { background: rgba(255,255,255,.2); }
.btn-sm   { padding: 5px 10px; font-size: 12px; }
.btn-icon { padding: 6px 8px; }
.btn-danger { background: var(--red); color: #fff; border-color: var(--red); }

/* ── CARD ─────────────────────────────────────────────────── */
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.card-header {
  padding: 14px 20px; border-bottom: 1px solid var(--border-lt);
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.card-header h3 { font-size: 14px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.card-body   { padding: 20px; }
.card-footer {
  padding: 14px 20px; border-top: 1px solid var(--border-lt);
  background: #FAFBFD; display: flex; align-items: center;
  justify-content: space-between; gap: 10px;
}

/* ── KPI GRID ─────────────────────────────────────────────── */
.kpi-grid   { display: grid; gap: 14px; margin-bottom: 22px; }
.kpi-grid-4 { grid-template-columns: repeat(4,1fr); }
.kpi-grid-3 { grid-template-columns: repeat(3,1fr); }
.kpi-grid-2 { grid-template-columns: repeat(2,1fr); }

.kpi-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; position: relative;
  box-shadow: var(--shadow);
}
.kpi-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: var(--kpi-color, var(--blue));
}
.kpi-card > div { padding: 16px 20px 18px; }
.kpi-label {
  font-size: 10.5px; font-weight: 700; color: var(--sub);
  letter-spacing: .5px; text-transform: uppercase; margin-bottom: 8px;
}
.kpi-value {
  font-size: 1.571rem; font-weight: 700; font-family: var(--mono);
  color: var(--navy); line-height: 1.1;
}
.kpi-sub { font-size: 11px; color: var(--sub2); margin-top: 5px; }

/* ── FORM ─────────────────────────────────────────────────── */
.form-grid { display: grid; gap: 14px; }
.g1 { grid-template-columns: 1fr; }
.g2 { grid-template-columns: 1fr 1fr; }
.g3 { grid-template-columns: 1fr 1fr 1fr; }
.g4 { grid-template-columns: 1fr 1fr 1fr 1fr; }
.g5 { grid-template-columns: repeat(5,1fr); }

.field { display: flex; flex-direction: column; gap: 5px; }
.field label {
  font-size: 10.5px; font-weight: 700; color: var(--sub);
  letter-spacing: .5px; text-transform: uppercase; display: flex; align-items: center; gap: 5px;
}
.field input,.field select,.field textarea {
  padding: 9px 12px; border-radius: var(--radius);
  border: 1.5px solid var(--border); font-family: var(--sans); font-size: 13.5px;
  color: var(--text); background: var(--bg); transition: border .14s, box-shadow .14s;
  outline: none; width: 100%;
}
.field input:focus,.field select:focus,.field textarea:focus {
  border-color: var(--navy); box-shadow: 0 0 0 3px rgba(26,43,74,.1); background: #fff;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='%2364748B'%3E%3Cpath d='M5 6L0 0h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center;
  padding-right: 30px; appearance: none; cursor: pointer;
}
.field textarea { resize: vertical; min-height: 68px; }
.field input[readonly] { background: #f0f2f8; cursor: default; color: var(--sub); }

.field-auto {
  padding: 9px 12px; border-radius: var(--radius);
  border: 1.5px solid #A9DFBF; background: #EAFAF1;
  font-size: 13px; font-weight: 700; color: var(--green); font-family: var(--mono);
}
.field-tva {
  padding: 9px 12px; border-radius: var(--radius);
  border: 1.5px solid #fcd9a0; background: #FEF9EC;
  font-size: 13px; font-weight: 700; color: var(--orange); font-family: var(--mono);
}

/* ── TAGS ─────────────────────────────────────────────────── */
.tag {
  display: inline-block; font-size: 9px; font-weight: 700;
  padding: 2px 6px; border-radius: 4px; vertical-align: middle;
}
.tag-req  { background: #FADBD8; color: var(--red); }
.tag-auto { background: #D5EDDA; color: var(--green); }
.tag-opt  { background: #FFF3CD; color: #7D6608; }
.tag-tva  { background: #FEF9EC; color: var(--orange); }

/* ── SECTION DIVIDER ───────────────────────────────────────── */
.div {
  display: flex; align-items: center; gap: 10px;
  margin: 14px 0 6px; font-size: 10px; font-weight: 700;
  color: var(--sub); letter-spacing: .8px; text-transform: uppercase;
}
.div::before,.div::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ── CALC RECAP BOX ─────────────────────────────────────────── */
.calc-box {
  background: linear-gradient(135deg, #f8fafc, #f1f5ff);
  border: 1.5px solid var(--border); border-radius: 12px; padding: 14px 16px;
}
.calc-box .calc-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6px 0; border-bottom: 1px solid var(--border-lt); font-size: 13px;
}
.calc-box .calc-row:last-child {
  border-bottom: none; font-weight: 700; font-size: 14px;
  color: var(--navy); padding-top: 10px; margin-top: 4px;
}
.calc-box .calc-label { color: var(--sub); }
.calc-box .calc-val   { font-family: var(--mono); font-weight: 600; }
.calc-box .calc-row.tva-row .calc-val { color: var(--orange); }
.calc-box .calc-row.total-row {
  background: #fff; border-radius: 8px; padding: 8px 10px; margin-top: 6px;
}

/* ── CARTE SELECTOR (cartes physiques cliquables) ─────────────── */
.carte-grid {
  display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px;
}
.carte-opt {
  width: 185px; min-height: 112px; border-radius: 12px; padding: 14px;
  cursor: pointer; background: var(--col, var(--navy));
  border: 2.5px solid transparent; display: flex; flex-direction: column;
  justify-content: space-between; transition: all .2s;
  box-shadow: 0 4px 14px rgba(0,0,0,.2); position: relative;
  overflow: hidden; flex-shrink: 0;
}
.carte-opt::before {
  content: ''; position: absolute; top: -18px; right: -18px;
  width: 72px; height: 72px; border-radius: 50%;
  background: rgba(255,255,255,.12); pointer-events: none;
}
.carte-opt::after {
  content: ''; position: absolute; bottom: -24px; left: 14px;
  width: 84px; height: 84px; border-radius: 50%;
  background: rgba(255,255,255,.07); pointer-events: none;
}
.carte-opt:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.28); }
.carte-opt.selected {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(230,168,23,.2), 0 4px 14px rgba(0,0,0,.2);
}
.carte-nom  { font-size: .857rem; font-weight: 700; color: #fff; position: relative; z-index: 1; }
.carte-taux { font-size: 1.143rem; font-weight: 700; font-family: var(--mono); color: #fff; position: relative; z-index: 1; }
.carte-unit { font-size: .714rem; color: rgba(255,255,255,.7); position: relative; z-index: 1; }

/* ── PAGE PILLS (sélecteur page) ───────────────────────────── */
.page-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 4px; }
.page-pill  {
  padding: 6px 14px; border-radius: 20px; border: 2px solid var(--border);
  cursor: pointer; font-size: 13px; font-weight: 600; transition: all .14s; background: #fff;
}
.page-pill.selected { color: #fff; }
.page-pill:hover    { transform: translateY(-1px); }

/* ── TABLE ─────────────────────────────────────────────────── */
.tbl-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  padding: 9px 14px; text-align: left; font-size: 10.5px; font-weight: 700;
  color: var(--sub); letter-spacing: .4px; text-transform: uppercase;
  background: var(--bg); border-bottom: 1.5px solid var(--border); white-space: nowrap;
}
td { padding: 10px 14px; border-bottom: 1px solid var(--border-lt); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #F4F7FD; }
.tbl-empty { text-align: center; padding: 36px; color: var(--sub); font-size: 13px; }
.row-acts { display: flex; gap: 4px; }

/* ── BADGES & PILLS ─────────────────────────────────────────── */
.pill {
  display: inline-flex; align-items: center; padding: 3px 9px;
  border-radius: 20px; font-size: 11px; font-weight: 700; white-space: nowrap;
}
.pill-green  { background: #D5EDDA; color: var(--green); }
.pill-blue   { background: #D6EAF8; color: #154360; }
.pill-orange { background: #FDEBD0; color: var(--orange); }
.pill-red    { background: #FADBD8; color: var(--red); }
.pill-purple { background: #E8DAEF; color: var(--purple); }
.pill-grey   { background: #EAECEF; color: var(--sub); }
.pill-gold   { background: #FEF9EC; color: #7D6608; }

/* Page color dot */
.page-dot {
  display: inline-block; width: 10px; height: 10px;
  border-radius: 50%; margin-right: 6px; vertical-align: middle; flex-shrink: 0;
}

/* ── MODAL ─────────────────────────────────────────────────── */
.modal-bg {
  position: fixed; inset: 0; background: rgba(26,43,74,.55);
  display: flex; align-items: center; justify-content: center;
  z-index: 500; backdrop-filter: blur(3px); animation: fadeIn .18s;
}
.modal {
  background: #fff; border-radius: 18px; padding: 28px;
  width: 420px; max-width: 94vw; box-shadow: var(--shadow-lg); animation: popIn .2s;
}
.modal h3 { font-size: 17px; margin-bottom: 8px; }
.modal p  { color: var(--sub); font-size: 13px; line-height: 1.5; margin-bottom: 22px; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }

/* ── TOAST ─────────────────────────────────────────────────── */
#toast-container {
  position: fixed; top: 74px; right: 20px;
  display: flex; flex-direction: column; gap: 8px; z-index: 999;
}
.toast {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  border-radius: 10px; min-width: 260px; font-size: 13px; font-weight: 500;
  box-shadow: var(--shadow-md); border: 1px solid;
  animation: slideIn .22s;
}
.toast-ok   { background: #fff; border-color: #A9DFBF; color: var(--green); }
.toast-err  { background: #fff; border-color: #FADBD8; color: var(--red); }
.toast-info { background: #fff; border-color: #AED6F1; color: var(--blue); }

/* ── LOGIN ─────────────────────────────────────────────────── */
#login-screen {
  position: fixed; inset: 0; background: var(--navy);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 20px; z-index: 9999; overflow: hidden;
}
#login-screen::before {
  content: ''; position: absolute; top: -100px; right: -100px;
  width: 400px; height: 400px; border-radius: 50%;
  background: rgba(230,168,23,.06); pointer-events: none;
}
#login-screen::after {
  content: ''; position: absolute; bottom: -150px; left: -150px;
  width: 500px; height: 500px; border-radius: 50%;
  background: rgba(255,255,255,.03); pointer-events: none;
}
.login-box {
  background: #fff; border-radius: 20px; padding: 40px;
  width: 400px; max-width: 95vw; box-shadow: 0 32px 80px rgba(0,0,0,.4);
  animation: popIn .3s; position: relative; z-index: 1;
}
.login-logo {
  width: 56px; height: 56px; border-radius: 14px; background: var(--navy);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.143rem; font-weight: 800; color: var(--gold);
  margin: 0 auto 16px; letter-spacing: -.02em;
}
.login-box h2 {
  font-size: 1.286rem; font-weight: 700; text-align: center;
  color: var(--navy); margin-bottom: 4px;
}
.login-box p { font-size: 13px; color: var(--sub); text-align: center; margin-bottom: 28px; }
.login-divider { height: 1px; background: var(--border); margin-bottom: 24px; }
.login-error {
  color: var(--red); font-size: 13px; text-align: center;
  margin-top: 12px; min-height: 18px; font-weight: 500;
}

/* ── LOADING ─────────────────────────────────────────────────── */
#loading-overlay {
  position: fixed; inset: 0; background: rgba(26,43,74,.4);
  display: flex; align-items: center; justify-content: center;
  z-index: 800; backdrop-filter: blur(3px);
}
.loading-box {
  background: #fff; border-radius: 16px; padding: 28px 36px;
  text-align: center; box-shadow: var(--shadow-lg);
}
.loading-box div:last-child { font-size: 14px; color: var(--navy); font-weight: 600; margin-top: 12px; }
.loading-state { padding: 40px; text-align: center; color: var(--sub); }
.spinner {
  width: 32px; height: 32px; border: 3px solid rgba(26,43,74,.12);
  border-top-color: var(--navy); border-radius: 50%;
  animation: spin .7s linear infinite; margin: 0 auto;
}

/* ── EDIT BANNER ─────────────────────────────────────────────── */
.edit-banner {
  background: var(--gold-d); border: 1.5px solid rgba(230,168,23,.35);
  border-radius: var(--radius); padding: 10px 16px; margin-bottom: 16px;
  font-size: 13px; color: #9a6f0a;
  display: flex; align-items: center; justify-content: space-between;
}

/* ── SEMAINES BADGE ─────────────────────────────────────────── */
.semaines-badge {
  background: #EAFAF1; border: 1.5px solid #A9DFBF; border-radius: 8px;
  padding: 8px 12px; font-size: 13px; color: var(--green); font-weight: 600;
  display: flex; align-items: center; gap: 8px;
}

/* ── CALLOUT ─────────────────────────────────────────────────── */
.callout { border-radius: var(--radius); padding: 11px 15px; font-size: 12.5px; margin-bottom: 14px; }
.callout-info  { background: #D6E4F7; border: 1px solid #AED6F1; color: #1A5276; }
.callout-warn  { background: #FDE8D0; border: 1px solid #E59866; color: #7D3A0E; }
.callout-green { background: #D5EDDA; border: 1px solid #A9DFBF; color: #1E5631; }

/* ── MISC UTILITIES ─────────────────────────────────────────── */
.mono       { font-family: var(--mono); }
.text-green { color: var(--green); }
.text-red   { color: var(--red); }
.text-orange{ color: var(--orange); }
.text-sub   { color: var(--sub); }
.text-bold  { font-weight: 700; }
.mt-4  { margin-top: 16px; }
.mb-4  { margin-bottom: 16px; }
.gap-2 { gap: 8px; }
.flex  { display: flex; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }

/* ── IA / CLAUDE ANALYSE ─────────────────────────────────────── */
.ia-card { border: 1.5px solid #2e5fa3; overflow: hidden; }
.ia-card .card-header { padding: 12px 20px; }

.ia-analyse-content {
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--text);
  padding: 4px 0 8px;
}
.ia-analyse-content p { margin-bottom: 10px; }
.ia-analyse-content .ia-section-title {
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .4px;
  color: var(--navy);
  margin: 14px 0 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border);
}
.ia-analyse-content .ia-bullet {
  padding-left: 16px;
  position: relative;
  margin-bottom: 4px;
}
.ia-analyse-content .ia-bullet::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--blue);
  font-weight: 700;
}

.ia-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  gap: 10px;
  flex-wrap: wrap;
}

.ia-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .4px;
  text-transform: uppercase;
}
.ia-badge-done { background: #dbeafe; color: #1e40af; }
.ia-badge-none { background: var(--border); color: var(--sub); }

.ia-loading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 0;
  color: var(--sub);
  font-size: 13px;
}

/* ── ANIMATIONS ─────────────────────────────────────────────── */
@keyframes fadeIn { from { opacity: 0; }    to { opacity: 1; } }
@keyframes popIn  { from { transform: scale(.92); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes slideIn{ from { transform: translateX(110px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes spin   { to { transform: rotate(360deg); } }

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .kpi-grid-4 { grid-template-columns: repeat(2,1fr); }
  .g3,.g4 { grid-template-columns: 1fr 1fr; }
  .carte-grid { flex-direction: column; }
  .carte-opt { width: 100%; }
  .g5 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .kpi-grid-4,.kpi-grid-3,.g2,.g3,.g4 { grid-template-columns: 1fr; }
}
