/* assets/css/admin.css */
body { font-family: Arial, sans-serif; background: #f6f8fa; }
#app { max-width: 900px; margin: 30px auto; background: #fff; padding: 24px; border-radius: 8px; box-shadow: 0 4px 16px #0001; }
h1 { color: #2a3a4a; }
section { margin-bottom: 32px; }
#totaux { font-weight: bold; margin: 12px 0; }
button { margin: 4px 8px 4px 0; padding: 6px 16px; border-radius: 4px; border: none; background: #2a3a4a; color: #fff; cursor: pointer; }
button:hover { background: #3d4e5e; }
input, select { margin: 4px 0 10px 0; padding: 6px; border-radius: 4px; border: 1px solid #aaa; width: 100%; }

/* Notifications visuelles */
.notif {position:fixed;top:30px;right:30px;z-index:9999;padding:14px 24px;border-radius:6px;font-size:1.1em;box-shadow:0 2px 8px #0002;animation:fadeNotif 3.5s both;}
.notif-success {background:#2ecc40;color:#fff;}
.notif-error {background:#ff4136;color:#fff;}
@keyframes fadeNotif {0%{opacity:0;}10%{opacity:1;}90%{opacity:1;}100%{opacity:0;}}
/* Historique recherche/tri/export */
#historique input[type="text"] {width:180px;display:inline-block;}
#historique button {display:inline-block;}

/* Responsive design et dark mode */
@media (max-width: 700px) {
  #app, #client-popup-content {padding:10px !important;}
  #facture-form, #historique, #dashboard {padding:0 !important;}
  h1, h2, h3 {font-size:1.2em !important;}
  table, thead, tbody, th, td, tr {font-size:0.97em;}
  .notif {right:10px;left:10px;max-width:95vw;}
}
#darkmode-toggle {position:fixed;top:16px;left:16px;z-index:10001;background:#222;color:#fff;border:none;padding:7px 16px;border-radius:6px;cursor:pointer;}
body.dark, .dark #app, .dark #client-popup-content {background:#23272f !important;color:#eee !important;}
.dark input, .dark select, .dark textarea {background:#23272f;color:#eee;border-color:#444;}
.dark table {background:#23272f;color:#eee;}
.dark .notif-success {background:#27ae60 !important;}
.dark .notif-error {background:#e74c3c !important;}
.dark a {color:#8ecfff !important;}
