/* =========================================================
   ACTIA — STYLE « PRO » (TEST)
   ---------------------------------------------------------
   Chargé APRÈS style.css. Ne modifie pas style.css :
   - pour revenir à l'ancien style : Paramètres → Style de
     l'interface → Classique (ou retirer la ligne pro.css
     dans index.html).
   - Le thème de Noël (noel.css) reste prioritaire.
   - La couleur d'accent des Paramètres est conservée.
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ---------- 1. Couleurs & mesures ---------- */
:root {
  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;

  --bg: #0b0d12;
  --bg2: #11141b;
  --surface: #151923;
  --surface-2: #1c2130;
  --input: #0f1219;
  --card: var(--surface);
  --border: #242a38;
  --border-strong: #343c4f;
  --text: #e8eaf0;
  --muted: #8a92a6;
  --tag-text: var(--text);

  --green: #22c55e;
  --orange: #f59e0b;
  --red: #ef4444;
  --blue: #60a5fa;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .35);
  --shadow: 0 8px 24px rgba(0, 0, 0, .35);
  --shadow-lg: 0 24px 64px rgba(0, 0, 0, .5);

  --accent-soft: color-mix(in srgb, var(--accent) 14%, transparent);
  --accent-ring: color-mix(in srgb, var(--accent) 30%, transparent);
  --accent-hover: color-mix(in srgb, var(--accent) 86%, #000);
}

body.light {
  --bg: #f5f6f8;
  --bg2: #ffffff;
  --surface: #ffffff;
  --surface-2: #f2f4f7;
  --input: #ffffff;
  --card: var(--surface);
  --border: #e4e7ec;
  --border-strong: #cfd4dc;
  --text: #101828;
  --muted: #667085;
  --tag-text: var(--text);

  --green: #16a34a;
  --orange: #d97706;
  --red: #dc2626;
  --blue: #2563eb;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow: 0 6px 16px rgba(16, 24, 40, .08);
  --shadow-lg: 0 24px 48px rgba(16, 24, 40, .18);
}

/* ---------- 2. Base ---------- */
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.45;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 { letter-spacing: -0.015em; }

/* Pas de halo coloré en fond (sauf thèmes de fête) */
body:not(.noel) .bg-glow { display: none; }

::selection { background: var(--accent-soft); }

* { scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 999px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
*::-webkit-scrollbar-track { background: transparent; }

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-ring);
}

/* ---------- 3. Connexion ---------- */
.auth-box {
  background: var(--surface);
  border-radius: 16px;
  padding: 36px 30px 30px;
  gap: 14px;
  box-shadow: var(--shadow-lg);
}
.auth-box h2 { font-size: 22px; }

/* ---------- 4. Barre latérale ---------- */
.sidebar {
  width: 240px;
  padding: 18px 12px;
  gap: 18px;
  background: var(--bg2);
  border-right: 1px solid var(--border);
}

.brand {
  padding: 2px 8px 16px;
  border-bottom: 1px solid var(--border);
}
.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--surface-2);
  box-shadow: none;
  overflow: hidden;
}
.brand-logo img { width: 100%; height: 100%; object-fit: contain; }
.brand h1 { font-size: 15px; font-weight: 700; }
.brand span { font-size: 12px; }

.nav { gap: 2px; }

.nav-btn {
  height: 38px;
  padding: 0 10px;
  gap: 10px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  transition: background .15s, color .15s;
}
.nav-btn:hover { background: var(--surface-2); color: var(--text); }
.nav-btn.active {
  background: var(--accent-soft);
  color: var(--text);
  font-weight: 600;
  box-shadow: inset 3px 0 0 var(--accent);
}

/* Icônes du menu (dessinées en CSS, couleur du texte) */
.nav-btn > span {
  flex: none;
  width: 18px;
  height: 18px;
  background: currentColor;
  -webkit-mask: var(--icon, none) center / contain no-repeat;
  mask: var(--icon, none) center / contain no-repeat;
}
.nav-btn.active > span { background: var(--accent); }

.nav-btn[data-view="dashboard"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='9' rx='1.5'/%3E%3Crect x='14' y='3' width='7' height='5' rx='1.5'/%3E%3Crect x='14' y='12' width='7' height='9' rx='1.5'/%3E%3Crect x='3' y='16' width='7' height='5' rx='1.5'/%3E%3C/svg%3E");
}
.nav-btn[data-view="receptions"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 6h12v10H2z'/%3E%3Cpath d='M14 9h4.5l3.5 3.5V16h-8'/%3E%3Ccircle cx='6.5' cy='17.5' r='2'/%3E%3Ccircle cx='17.5' cy='17.5' r='2'/%3E%3C/svg%3E");
}
.nav-btn[data-view="nc"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.3 3.9 1.8 18a2 2 0 0 0 1.7 3h17a2 2 0 0 0 1.7-3L13.7 3.9a2 2 0 0 0-3.4 0z'/%3E%3Cpath d='M12 9v4M12 17h.01'/%3E%3C/svg%3E");
}
.nav-btn[data-view="stats"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3v18h18'/%3E%3Cpath d='M8 17v-5M13 17V8M18 17v-9'/%3E%3C/svg%3E");
}
.nav-btn[data-view="notes"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z'/%3E%3Cpath d='M14 3v6h6M8 13h8M8 17h5'/%3E%3C/svg%3E");
}
.nav-btn[data-view="plans"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20V4l16 16z'/%3E%3Cpath d='M8 16v-4l4 4z'/%3E%3C/svg%3E");
}
.nav-btn[data-view="contacts"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2'/%3E%3Ccircle cx='9' cy='7' r='4'/%3E%3Cpath d='M22 21v-2a4 4 0 0 0-3-3.87M16 3.13a4 4 0 0 1 0 7.75'/%3E%3C/svg%3E");
}
.nav-btn[data-view="settings"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 21v-7M4 10V3M12 21v-9M12 8V3M20 21v-5M20 12V3M1 14h6M9 8h6M17 16h6'/%3E%3C/svg%3E");
}
.nav-btn[data-view="faire-suggestion"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 22h4'/%3E%3Cpath d='M12 2a7 7 0 0 0-4 12.7V17h8v-2.3A7 7 0 0 0 12 2z'/%3E%3C/svg%3E");
}
.nav-btn[data-view="suggestions"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 12h-6l-2 3h-4l-2-3H2'/%3E%3Cpath d='M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z'/%3E%3C/svg%3E");
}
.nav-btn[data-view="other-documents"] {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 7a2 2 0 0 1 2-2h4l2 2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3C/svg%3E");
}

.logout {
  height: 38px;
  justify-content: flex-start;
  padding: 0 12px;
  font-weight: 500;
  color: var(--muted);
}
.logout:hover { color: var(--red); border-color: color-mix(in srgb, var(--red) 40%, transparent); }

/* ---------- 5. Zone principale & barre du haut ---------- */
.main { padding: 0 32px 48px; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  margin: 0 -32px 24px;
  padding: 14px 32px;
  gap: 10px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.search {
  height: 40px;
  max-width: 560px;
  padding: 0 12px;
  gap: 8px;
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s;
}
.search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-ring);
}
.search > span { opacity: .6; font-size: 14px; }

/* Les boutons du haut se rangent à droite */
.topbar .theme-switch { margin-left: auto; }

.btn-icon,
.burger {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  font-size: 16px;
  transition: background .15s, border-color .15s;
}
.btn-icon:hover,
.burger:hover { background: var(--surface-2); border-color: var(--border-strong); }

/* ---------- 6. En-têtes de page ---------- */
.view { animation: proFade .2s ease; }
@keyframes proFade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.view-head { margin-bottom: 20px; align-items: center; }
.view-head h2 { font-size: 22px; font-weight: 700; }
.view-head .muted { margin-top: 2px; }
.muted { color: var(--muted); }

/* ---------- 7. Boutons ---------- */
.btn {
  height: 38px;
  padding: 0 16px;
  gap: 8px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: background .15s, border-color .15s, box-shadow .15s, transform .05s;
}
.btn:active:not(:disabled) { transform: translateY(1px); }

.btn.primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid color-mix(in srgb, var(--accent) 80%, #000);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, .12);
}
.btn.primary:hover { background: var(--accent-hover); transform: none; }

.btn.ghost,
.btn:not(.primary):not(.danger):not(.ghost) {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.btn.ghost:hover,
.btn:not(.primary):not(.danger):not(.ghost):hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
}

.btn.danger {
  background: color-mix(in srgb, var(--red) 10%, transparent);
  color: var(--red);
  border: 1px solid color-mix(in srgb, var(--red) 30%, transparent);
}
.btn.danger:hover { background: color-mix(in srgb, var(--red) 18%, transparent); }

/* ---------- 8. Cartes & indicateurs ---------- */
.stats {
  grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}

.stat-card,
.card,
.note,
.plan-folder,
.contact-card,
.monthly-bars-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  backdrop-filter: none;
  transition: border-color .15s, box-shadow .15s;
}

.stat-card { padding: 16px 18px; gap: 14px; }
.stat-card:hover,
.note:hover,
.plan-folder:hover,
.contact-card:hover {
  transform: none;
  border-color: var(--border-strong);
  box-shadow: var(--shadow);
}

.stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  font-size: 18px;
}
.stat-icon.blue { background: color-mix(in srgb, var(--blue) 14%, transparent); }
.stat-icon.green { background: color-mix(in srgb, var(--green) 14%, transparent); }
.stat-icon.orange { background: color-mix(in srgb, var(--orange) 16%, transparent); }
.stat-icon.purple { background: color-mix(in srgb, #8b5cf6 16%, transparent); }

.stat-card h3 {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.stat-card p { font-size: 13px; margin-top: 2px; }

.grid-2 { gap: 14px; }

.card { padding: 18px 20px; }
.card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
}

.list { gap: 0; }
.list-item {
  padding: 10px 4px;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  font-size: 14px;
  font-weight: 500;
}
.list-item:last-child { border-bottom: none; }
.list-item small { font-weight: 400; font-size: 12.5px; }

.empty { font-size: 13.5px; padding: 18px 0; }

/* ---------- 9. Filtres (contrôle segmenté) ---------- */
.filters {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  margin-bottom: 16px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
}
.chip {
  padding: 6px 12px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  transition: background .15s, color .15s;
}
.chip:hover { color: var(--text); }
.chip.active {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}
body.light .chip.active { background: #fff; }

/* ---------- 10. Tableau des réceptions ---------- */
.table-card { padding: 0; overflow: auto; }
.table th {
  padding: 10px 14px;
  background: var(--surface-2);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--muted);
  position: sticky;
  top: 0;
  z-index: 1;
}
.table td {
  padding: 12px 14px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
}
.table tr:hover td { background: color-mix(in srgb, var(--accent) 5%, transparent); }

/* Une réception = une ligne : pas de retour à la ligne dans les codes */
#recBody .rec-row td { white-space: nowrap; }
#recBody .rec-row td:nth-child(2) { white-space: normal; min-width: 120px; font-weight: 600; }
#recBody .rec-row td:last-child { width: 1%; }
#recBody .rec-row td:last-child .act + .act { margin-left: 4px; }
#recBody .rec-row td:nth-child(3),
#recBody .rec-row td:nth-child(4),
#recBody .rec-row td:nth-child(5) { font-size: 13.5px; color: color-mix(in srgb, var(--text) 85%, var(--muted)); }
#recBody .file-chips .file-link { white-space: nowrap; font-size: 12.5px; }
#recBody .rec-detail td { background: var(--surface-2); font-size: 13.5px; }

/* Badges de statut : pastille + point */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid transparent;
}
.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.badge.Attendue {
  color: var(--blue);
  background: color-mix(in srgb, var(--blue) 12%, transparent);
  border-color: color-mix(in srgb, var(--blue) 25%, transparent);
}
.badge.En-contrôle {
  color: var(--orange);
  background: color-mix(in srgb, var(--orange) 12%, transparent);
  border-color: color-mix(in srgb, var(--orange) 28%, transparent);
}
.badge.Litige {
  color: var(--red);
  background: color-mix(in srgb, var(--red) 12%, transparent);
  border-color: color-mix(in srgb, var(--red) 28%, transparent);
}
.badge.En-stock {
  color: var(--green);
  background: color-mix(in srgb, var(--green) 12%, transparent);
  border-color: color-mix(in srgb, var(--green) 28%, transparent);
}

/* ---------- 11. Notes, plans, contacts ---------- */
.note,
.plan-folder,
.contact-card { padding: 16px 18px; gap: 10px; border-left-width: 3px; }
.plan-folder { border-left-color: var(--blue); }
.contact-card { border-left-color: var(--accent); }

.note h4,
.plan-head h4,
.contact-card h4 { font-size: 15px; font-weight: 600; }

.tag {
  padding: 2px 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text);
}

.act {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: background .15s, border-color .15s;
}
.act:hover { background: var(--surface-2); border-color: var(--border-strong); }

.plan-file,
.contact-line {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
a.contact-line:hover { border-color: var(--accent); color: var(--text); }

.file-link { color: var(--blue); font-weight: 500; }

/* ---------- 12. Formulaires ---------- */
.field,
#modalForm label {
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

.field input,
.field select,
#modalForm input:not([type="file"]):not([type="checkbox"]):not([type="radio"]),
#modalForm select,
#modalForm textarea,
.inline-form input {
  min-height: 40px;
  padding: 9px 12px;
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 400;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus,
.field select:focus,
#modalForm input:focus,
#modalForm select:focus,
#modalForm textarea:focus,
.inline-form input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-ring);
}
#modalForm input::placeholder,
#modalForm textarea::placeholder,
.field input::placeholder { color: color-mix(in srgb, var(--muted) 80%, transparent); }

#modalForm input[type="file"] {
  padding: 8px;
  background: var(--surface-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  font-size: 13px;
}
#modalForm input[type="file"]::file-selector-button {
  margin-right: 10px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--text);
  font: 600 13px var(--font);
  cursor: pointer;
}

/* ---------- 13. Fenêtres (modales) ---------- */
.modal {
  background: rgba(6, 8, 12, .62);
  backdrop-filter: blur(4px);
}
body.light .modal { background: rgba(16, 24, 40, .35); }

.modal-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: var(--shadow-lg);
}
.modal-head {
  margin: -2px 0 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.modal-head h3 { font-size: 17px; font-weight: 700; }
.modal-head .btn-icon { width: 34px; height: 34px; box-shadow: none; }

.modal-box.wide #modalForm > .row:last-of-type,
.modal-box.wide .rec-actions { background: var(--bg2); }

/* Boutons « Enregistrer » / « Enregistrer et suivante » */
.rec-actions .btn:not(.primary) {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}
.rec-actions .btn:not(.primary):hover { background: var(--surface-2); }

/* Sélecteur de fournisseurs */
.supplier-search-box {
  min-height: 40px;
  background: var(--input);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}
.supplier-search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-ring);
}
.supplier-search-box input { min-height: 0 !important; box-shadow: none !important; border: none !important; background: transparent !important; }

.supplier-item {
  min-height: 32px;
  border-radius: 8px;
  background: var(--surface);
}
.supplier-item:hover { border-color: var(--border-strong); }
.supplier-item.selected {
  background: var(--accent-soft);
  border-color: var(--accent);
}
.supplier-select-btn { font-size: 12.5px; font-weight: 500; color: var(--text); }
.supplier-item.selected .supplier-select-btn,
.supplier-item.selected .supplier-remove-btn { color: var(--text); }
.supplier-remove-btn { width: 22px; height: 22px; border-radius: 6px; font-size: 15px; }
.supplier-new-btn {
  border: 1px dashed var(--border-strong);
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font-weight: 500;
}
.supplier-new-btn:hover { background: var(--surface-2); border-color: var(--accent); }

/* Cases photo */
.modal-box .photo-slot {
  background: var(--surface-2);
  border: 1px dashed var(--border-strong);
  border-radius: 10px;
}
.modal-box .photo-slot.filled {
  background: var(--surface);
  border: 1px solid var(--accent);
}
.modal-box .photo-slot .photo-btn {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}
.modal-box .photo-slot .photo-btn:hover { background: var(--surface-2); }
.modal-box .photo-slot .photo-add-page { border-color: var(--border-strong); }

/* ---------- 14. Notifications ---------- */
.toast {
  border-radius: 10px;
  padding: 11px 18px;
  font-weight: 500;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
}

/* ---------- 15. Graphique des stats ---------- */
.monthly-bars-card { padding: 22px 24px; }
.monthly-bars-header h3 { font-size: 17px; font-weight: 700; }

/* ---------- 16. Mobile ---------- */
@media (max-width: 860px) {
  .main { padding: 0 16px 32px; }
  .topbar { margin: 0 -16px 16px; padding: 10px 16px; }
  .topbar .theme-switch { margin-left: 0; }
  .sidebar { box-shadow: var(--shadow-lg); }
  .filters { display: flex; flex-wrap: wrap; }
}

@media (max-width: 700px) {
  .modal-box { border-radius: 16px 16px 0 0; padding: 18px 16px 24px; }
  .view-head h2 { font-size: 20px; }

  /* Chiffres clés : 2 par ligne, plus compacts */
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stat-card { padding: 12px; gap: 10px; align-items: flex-start; flex-direction: column; }
  .stat-icon { width: 32px; height: 32px; font-size: 15px; border-radius: 8px; }
  .stat-card h3 { font-size: 20px; }
  .stat-card p { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .view { animation: none; }
}
