/* http://meyerweb.com/eric/tools/css/reset/ 
   v2.0 | 20110126
   License: none (public domain)
*/

html,
body,
div,
span,
applet,
object,
iframe,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
a,
abbr,
acronym,
address,
big,
cite,
code,
del,
dfn,
em,
img,
ins,
kbd,
q,
s,
samp,
small,
strike,
strong,
sub,
sup,
tt,
var,
b,
u,
i,
center,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
legend,
table,
caption,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
embed,
figure,
figcaption,
footer,
header,
hgroup,
menu,
nav,
output,
ruby,
section,
summary,
time,
mark,
audio,
video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
  display: block;
}
body {
  line-height: 1;
}
ol,
ul {
  list-style: none;
}
blockquote,
q {
  quotes: none;
}
blockquote:before,
blockquote:after,
q:before,
q:after {
  content: "";
  content: none;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* ============================================================================ 
   STOP RESET 
   ============================================================================ */

/* ============================================================================ 
   BASE STYLES - QC TOOLS
   ============================================================================ */

:root {
  --bg-primary: #0f0f1a;
  --bg-secondary: #1a1a2e;
  --bg-tertiary: #252540;
  --text-primary: #eeeeee;
  --text-secondary: #aaaaaa;
  --text-muted: #666666;
  --accent: #4da6ff;
  --accent-hover: #3d8bd9;
  --border: #333333;
  --success: #4ade80;
  --warning: #fbbf24;
  --danger: #ff6b6b;

  /* Variables pour le layout mobile */
  --sidebar-toggle-size: 44px;
  --sidebar-toggle-margin: 10px;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 12px;
}

body {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background: #0f0f1a;
  background: var(--bg-primary);
  color: #eeeeee;
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: #4da6ff;
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #3d8bd9;
  color: var(--accent-hover);
}

button {
  font-family: inherit;
  cursor: pointer;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

/* ============================================================================ 
   LAYOUT
   ============================================================================ */

.app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh; /* Dynamic viewport height pour mobile */
}

.app-body {
  display: flex;
  flex: 1 1;
  height: 94vh;
  position: relative; /* Pour le positionnement de la sidebar mobile */
}

.main-content {
  flex: 1 1;
  padding: 16x;
  overflow-y: auto;
  background: #0f0f1a;
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  min-width: 0; /* Permet au contenu de rétrécir correctement */
  margin-top: 10px;
}

.container {
  flex: 1 1;
  padding: 16px;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
}

/* ============================================================================ 
   LAYOUT - RESPONSIVE MOBILE (Sidebar collapsible)
   ============================================================================ */

@media (max-width: 768px) {
  .app-body {
    /* La sidebar est en position fixed/overlay, donc le body prend 100% */
    flex-direction: column;
    height: auto;
    min-height: calc(100vh - 6vh); /* Ajuster si vous avez un header */
    min-height: calc(100dvh - 6vh);
  }

  .main-content {
    /* Contenu prend toute la largeur */
    width: 100%;
    /* Padding top pour le bouton hamburger */
    padding-top: calc(
      44px + 10px + 16px
    );
    padding-top: calc(
      var(--sidebar-toggle-size) + var(--sidebar-toggle-margin) + 16px
    );
    padding-left: 12px;
    padding-right: 12px;
    /* Hauteur automatique */
    min-height: calc(100vh - 6vh);
    min-height: calc(100dvh - 6vh);
  }

  .container {
    padding: 12px;
  }
}

/* ============================================================================ 
   LAYOUT - TRÈS PETIT ÉCRAN (scanners)
   ============================================================================ */

@media (max-width: 480px) {
  :root {
    --sidebar-toggle-size: 40px;
    --sidebar-toggle-margin: 8px;
  }

  .main-content {
    padding: 8px;
    padding-top: calc(
      44px + 10px + 12px
    );
    padding-top: calc(
      var(--sidebar-toggle-size) + var(--sidebar-toggle-margin) + 12px
    );
  }

  .container {
    padding: 7px;
  }

  /* Réduire la taille de police sur très petit écran */
  html {
    font-size: 11px;
  }
}

/* ============================================================================ 
   UTILITIES
   ============================================================================ */

.text-muted {
  color: #666666;
  color: var(--text-muted);
}

.text-accent {
  color: #4da6ff;
  color: var(--accent);
}

.text-success {
  color: #4ade80;
  color: var(--success);
}

.text-warning {
  color: #fbbf24;
  color: var(--warning);
}

.text-danger {
  color: #ff6b6b;
  color: var(--danger);
}

/* Classe utilitaire pour masquer sur mobile */
.hide-mobile {
  display: block;
}

@media (max-width: 768px) {
  .hide-mobile {
    display: none !important;
  }
}

/* Classe utilitaire pour afficher uniquement sur mobile */
.show-mobile {
  display: none;
}

@media (max-width: 768px) {
  .show-mobile {
    display: block !important;
  }
}

/* ============================================================================ 
   SCROLLBAR (optionnel, style pro)
   ============================================================================ */

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #0f0f1a;
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: #333333;
  background: var(--border);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #666666;
  background: var(--text-muted);
}

/* ============================================================================ 
   FORMULAIRES - Optimisation tactile mobile
   ============================================================================ */

@media (max-width: 768px) {
  /* Taille minimum pour les éléments tactiles (44px recommandé par Apple) */
  button,
  .btn,
  input[type="submit"],
  input[type="button"] {
    min-height: 44px;
    min-width: 44px;
  }

  /* Inputs plus grands sur mobile pour éviter le zoom iOS */
  input[type="text"],
  input[type="email"],
  input[type="password"],
  input[type="number"],
  input[type="tel"],
  input[type="url"],
  input[type="search"],
  textarea,
  select {
    font-size: 16px; /* Empêche le zoom auto sur iOS */
    min-height: 44px;
    padding: 12px;
  }
}

/* ============================================================================ 
   SAFE AREA (pour les téléphones avec encoche)
   ============================================================================ */

@supports (padding: max(0px)) {
  .main-content {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }
}

/* src/components/Global/Header/Header.css */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  height: 3vh;
  min-height: 36px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  font-size: 11px;
 
}

/* ===== Header Left (hamburger + logo) ===== */
.header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-logo a {
  font-weight: 700;
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
}

/* ===== Bouton Hamburger ===== */
.header-hamburger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background-color: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 20px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.header-hamburger:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent);
  color: var(--accent);
}

.header-hamburger:active {
  transform: scale(0.95);
}

/* État quand la sidebar est collapsed */
.header-hamburger.collapsed {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.header-hamburger.collapsed:hover {
  background: #3b8eea;
  background: var(--accent-hover, #3b8eea);
}

/* ===== Header Right ===== */
.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-profile {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 4px;
  text-decoration: none;
  transition: background 0.2s;
}

.header-profile:hover {
  background: var(--bg-tertiary);
}

.header-avatar {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: var(--bg-primary);
  font-size: 9px;
  font-weight: 600;
  border-radius: 50%;
  flex-shrink: 0;
}

.header-user-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.header-username {
  color: var(--text-primary);
  font-weight: 500;
  font-size: 11px;
  white-space: nowrap;
}

.header-role {
  font-size: 9px;
  text-transform: uppercase;
  font-weight: 600;
}

.header-role.role-admin {
  color: var(--danger);
}

.header-role.role-user {
  color: var(--accent);
}

.btn-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  transition: all 0.2s;
  flex-shrink: 0;
}

.btn-logout svg {
  width: 14px;
  height: 14px;
}

.btn-logout:hover {
  background: rgba(255, 107, 107, 0.15);
  border-color: var(--danger);
  color: var(--danger);
}

.btn-logout:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== Responsive Tablette ===== */
@media (max-width: 768px) {
  .header {
    padding: 0 12px;
    min-height: 44px;
    height: auto;
  }

  .header-left {
    gap: 10px;
  }

  .header-logo a {
    font-size: 14px;
  }

  .header-hamburger {
    width: 36px;
    height: 36px;
    font-size: 22px;
  }
}

/* ===== Responsive Mobile ===== */
@media (max-width: 600px) {
  .header-user-info {
    display: none;
  }

  .header-profile {
    padding: 4px;
  }

  .header-right {
    gap: 8px;
  }
}

/* ===== Très petit écran (scanners) ===== */
@media (max-width: 400px) {
  .header {
    padding: 0 8px;
  }

  .header-left {
    gap: 8px;
  }

  .header-hamburger {
    width: 36px;
    height: 36px;
    font-size: 22px;
  }

  .header-logo a {
    font-size: 13px;
  }

  .header-avatar {
    width: 28px;
    height: 28px;
    font-size: 10px;
  }

  .btn-logout {
    width: 32px;
    height: 32px;
  }

  .btn-logout svg {
    width: 16px;
    height: 16px;
  }
}

/* src/components/Global/Footer/Footer.css */
.footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 3vh;
  min-height: 24px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  font-size: 9px;
  color: var(--text-muted);
}

.footer-separator {
  color: var(--border);
}

/* src/components/Global/Sidebar/Sidebar.css */

/* =============================================
   VARIABLES
   ============================================= */
:root {
  --sidebar-width: 240px;
  --sidebar-collapsed-width: 60px;
  --sidebar-transition: 0.25s ease;
}

/* =============================================
   SIDEBAR - Desktop
   ============================================= */
.sidebar {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 240px;
  width: var(--sidebar-width);
  height: 150vh;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  padding: 8px;
  transition: width 0.25s ease;
  transition: width var(--sidebar-transition);
  overflow-y: auto;
  overflow-x: hidden;
  flex-shrink: 0;

  
}

/* =============================================
   SIDEBAR COLLAPSED (Desktop)
   ============================================= */
.sidebar.collapsed {
  width: 60px;
  width: var(--sidebar-collapsed-width);
}

.sidebar.collapsed .sidebar-label,
.sidebar.collapsed .separator-text,
.sidebar.collapsed .separator-arrow,
.sidebar.collapsed .sidebar-version,
.sidebar.collapsed .subgroup-label,
.sidebar.collapsed .subgroup-arrow {
  opacity: 0;
  visibility: hidden;
  width: 0;
  overflow: hidden;
}

.sidebar.collapsed .sidebar-link {
  justify-content: center;
  padding: 12px 8px;
}

.sidebar.collapsed .sidebar-separator {
  justify-content: center;
  padding: 8px 0;
}

.sidebar.collapsed .sidebar-separator.clickable {
  pointer-events: none;
}

.sidebar.collapsed .sidebar-subgroup-header {
  justify-content: center;
  padding: 10px 8px;
  pointer-events: none;
}

.sidebar.collapsed .sidebar-subgroup-items {
  padding-left: 0;
}

/* Tooltip on hover when collapsed */
.sidebar.collapsed .sidebar-link,
.sidebar.collapsed .sidebar-subgroup-header {
  position: relative;
}

.sidebar.collapsed .sidebar-link::after {
  content: attr(title);
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  margin-left: 12px;
  padding: 8px 12px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 500;
  border-radius: 6px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  z-index: 1000;
  border: 1px solid var(--border);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  pointer-events: none;
}

.sidebar.collapsed .sidebar-link:hover::after {
  opacity: 1;
  visibility: visible;
}

/* =============================================
   NAVIGATION
   ============================================= */
.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 24px;
}

/* =============================================
   SECTIONS PRINCIPALES
   ============================================= */
.sidebar-section {
  display: flex;
  flex-direction: column;
  margin-bottom: 8px;
}

.sidebar-separator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 12px 6px 12px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.8px;
  background: none;
  border: none;
  cursor: default;
  transition: all 0.25s ease;
  transition: all var(--sidebar-transition);
}

.sidebar-separator.clickable {
  cursor: pointer;
  border-radius: 6px;
  margin: 4px 0;
  padding: 10px 12px;
  background: var(--bg-tertiary);
}

.sidebar-separator.clickable:hover {
  background: var(--border);
  color: var(--text-secondary);
}

.separator-text {
  transition:
    opacity 0.25s ease,
    width 0.25s ease;
  transition:
    opacity var(--sidebar-transition),
    width var(--sidebar-transition);
  white-space: nowrap;
}

.separator-arrow {
  display: flex;
  align-items: center;
  font-size: 14px;
  transition:
    transform 0.2s ease,
    opacity 0.25s ease;
  transition:
    transform 0.2s ease,
    opacity var(--sidebar-transition);
}

/* =============================================
   SECTION ITEMS (COLLAPSIBLE)
   ============================================= */
.sidebar-section-items {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
  max-height: 1000px;
  transition:
    max-height 0.3s ease,
    opacity 0.2s ease;
}

.sidebar-section-items.collapsed {
  max-height: 0;
  opacity: 0;
  pointer-events: none;
}

/* =============================================
   SOUS-GROUPES
   ============================================= */
.sidebar-subgroup {
  display: flex;
  flex-direction: column;
  margin: 2px 0;
}

.sidebar-subgroup-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: transparent;
  border: none;
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
}

.sidebar-subgroup-header:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.sidebar-subgroup-header.collapsed {
  color: var(--text-muted);
}

.subgroup-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  font-size: 16px;
  color: var(--accent);
}

.subgroup-label {
  flex: 1 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition:
    opacity 0.25s ease,
    width 0.25s ease;
  transition:
    opacity var(--sidebar-transition),
    width var(--sidebar-transition);
}

.subgroup-arrow {
  display: flex;
  align-items: center;
  font-size: 12px;
  color: var(--text-muted);
  transition:
    transform 0.2s ease,
    opacity 0.25s ease;
  transition:
    transform 0.2s ease,
    opacity var(--sidebar-transition);
}

/* Items du sous-groupe */
.sidebar-subgroup-items {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding-left: 12px;
  margin-left: 8px;
  border-left: 1px solid var(--border);
  overflow: hidden;
  max-height: 500px;
  transition:
    max-height 0.25s ease,
    opacity 0.2s ease,
    padding 0.25s ease;
}

.sidebar-subgroup-items.collapsed {
  max-height: 0;
  opacity: 0;
  padding-left: 0;
  pointer-events: none;
}

.sidebar-subgroup-items .sidebar-link {
  padding: 8px 12px;
  font-size: 12px;
}

.sidebar-subgroup-items .sidebar-icon {
  width: 18px;
  height: 18px;
  font-size: 14px;
}

/* =============================================
   LIENS
   ============================================= */
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 6px;
  font-size: 13px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.sidebar-link:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.sidebar-link.active {
  color: var(--accent);
  background: rgba(77, 166, 255, 0.15);
}

.sidebar-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  font-size: 18px;
}

.sidebar-label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition:
    opacity 0.25s ease,
    width 0.25s ease;
  transition:
    opacity var(--sidebar-transition),
    width var(--sidebar-transition);
}

/* =============================================
   FOOTER
   ============================================= */
.sidebar-footer {
  padding: 8px 12px;
  border-top: 1px solid var(--border);
  margin-top: 8px;
}

.sidebar-version {
  font-size: 10px;
  color: var(--text-muted);
  transition: opacity 0.25s ease;
  transition: opacity var(--sidebar-transition);
}

/* Header mobile - caché sur desktop */
.sidebar-mobile-header {
  display: none;
}

/* Overlay - caché sur desktop */
.sidebar-overlay {
  display: none;
}

/* =============================================
   RESPONSIVE - Tablette
   ============================================= */
@media (max-width: 1024px) and (min-width: 769px) {
  .sidebar {
    width: 60px;
    width: var(--sidebar-collapsed-width);
  }

  .sidebar .sidebar-label,
  .sidebar .separator-text,
  .sidebar .separator-arrow,
  .sidebar .sidebar-version,
  .sidebar .subgroup-label,
  .sidebar .subgroup-arrow {
    opacity: 0;
    visibility: hidden;
    width: 0;
  }

  .sidebar .sidebar-link {
    justify-content: center;
    padding: 12px 8px;
  }

  .sidebar .sidebar-separator {
    justify-content: center;
  }

  .sidebar .sidebar-subgroup-header {
    justify-content: center;
    pointer-events: none;
  }

  .sidebar .sidebar-subgroup-items {
    padding-left: 0;
    margin-left: 0;
    border-left: none;
  }

  /* Tooltip */
  .sidebar .sidebar-link::after {
    content: attr(title);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 12px;
    padding: 8px 12px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 12px;
    border-radius: 6px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.15s;
    z-index: 1000;
    border: 1px solid var(--border);
    pointer-events: none;
  }

  .sidebar .sidebar-link {
    position: relative;
  }

  .sidebar .sidebar-link:hover::after {
    opacity: 1;
    visibility: visible;
  }
}

/* =============================================
   RESPONSIVE - Mobile (sidebar cachée par défaut)
   ============================================= */
@media (max-width: 768px) {
  /* Overlay sombre */
  .sidebar-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 999;
    animation: fadeIn 0.2s ease;
  }

  @keyframes fadeIn {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  /* Sidebar mobile - cachée par défaut */
  .sidebar.mobile {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100vh;
    height: 100dvh;
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    padding: 0;
    box-shadow: none;
  }

  /* Sidebar ouverte */
  .sidebar.mobile.open {
    transform: translateX(0);
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
  }

  /* Reset collapsed state on mobile */
  .sidebar.mobile.collapsed {
    width: 300px;
  }

  .sidebar.mobile .sidebar-label,
  .sidebar.mobile .separator-text,
  .sidebar.mobile .separator-arrow,
  .sidebar.mobile .sidebar-version,
  .sidebar.mobile .subgroup-label,
  .sidebar.mobile .subgroup-arrow {
    opacity: 1;
    visibility: visible;
    width: auto;
  }

  .sidebar.mobile .sidebar-link {
    justify-content: flex-start;
  }

  .sidebar.mobile .sidebar-subgroup-header {
    justify-content: flex-start;
    pointer-events: auto;
  }

  .sidebar.mobile .sidebar-subgroup-items {
    padding-left: 12px;
    margin-left: 8px;
    border-left: 1px solid var(--border);
  }

  /* Header mobile */
  .sidebar-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border);
    min-height: 44px;
  }

  .sidebar-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
  }

  .sidebar-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s;
  }

  .sidebar-close:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: #fff;
  }

  /* Navigation mobile */
  .sidebar.mobile .sidebar-nav {
    padding: 12px;
    gap: 4px;
    flex: 1 1;
    overflow-y: auto;
    margin-top: 0;
  }

  .sidebar.mobile .sidebar-link {
    padding: 14px 16px;
    font-size: 14px;
    border-radius: 8px;
  }

  .sidebar.mobile .sidebar-icon {
    font-size: 20px;
    width: 24px;
    height: 24px;
  }

  .sidebar.mobile .sidebar-separator {
    padding: 16px 16px 8px 16px;
    font-size: 11px;
  }

  .sidebar.mobile .sidebar-separator.clickable {
    padding: 12px 16px;
    margin: 8px 0 4px 0;
  }

  .sidebar.mobile .sidebar-subgroup-header {
    padding: 12px 16px;
    font-size: 13px;
  }

  .sidebar.mobile .sidebar-subgroup-items .sidebar-link {
    padding: 12px 16px;
    font-size: 13px;
  }

  /* Footer mobile */
  .sidebar.mobile .sidebar-footer {
    padding: 12px 16px;
    margin-top: auto;
  }

  .sidebar.mobile .sidebar-version {
    display: block;
    text-align: center;
  }
}

/* =============================================
   TRÈS PETIT ÉCRAN (scanners)
   ============================================= */
@media (max-width: 480px) {
  .sidebar.mobile {
    width: 100%;
    max-width: 320px;
  }

  .sidebar.mobile .sidebar-link {
    padding: 16px;
    font-size: 15px;
  }

  .sidebar.mobile .sidebar-icon {
    font-size: 22px;
  }
}

/* =============================================
   Scrollbar
   ============================================= */
.sidebar::-webkit-scrollbar {
  width: 4px;
}

.sidebar::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.sidebar-subgroup-items:not(.collapsed) .sidebar-link {
  animation: slideIn 0.15s ease forwards;
}

.sidebar-subgroup-items:not(.collapsed) .sidebar-link:nth-child(1) {
  animation-delay: 0.02s;
}
.sidebar-subgroup-items:not(.collapsed) .sidebar-link:nth-child(2) {
  animation-delay: 0.04s;
}
.sidebar-subgroup-items:not(.collapsed) .sidebar-link:nth-child(3) {
  animation-delay: 0.06s;
}
.sidebar-subgroup-items:not(.collapsed) .sidebar-link:nth-child(4) {
  animation-delay: 0.08s;
}
.sidebar-subgroup-items:not(.collapsed) .sidebar-link:nth-child(5) {
  animation-delay: 0.1s;
}

/* Highlight subgroup when child is active */
.sidebar-subgroup:has(.sidebar-link.active) .sidebar-subgroup-header {
  color: var(--text-primary);
}

.sidebar-subgroup:has(.sidebar-link.active) .subgroup-icon {
  color: var(--accent);
}

/* src/screens/Login.css */
.login-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: #0f0f1a;
}

.login-box {
  width: 100%;
  max-width: 320px;
  padding: 24px;
  background: #1a1a2e;
  border: 1px solid #f7dd6d;
  border-radius: 10px;
}

.login-header {
  text-align: center;
  margin-bottom: 20px;
}

.login-header h1 {
  font-size: 18px;
  color: #f7dd6d;
  margin-bottom: 4px;
}

.login-header span {
  font-size: 11px;
  color: #b3b0b0;
}

.login-error {
  padding: 8px;
  margin-bottom: 12px;
  background: #3d1a1a;
  border: 1px solid #5c2a2a;
  border-radius: 3px;
  color: #ff6b6b;
  font-size: 11px;
  text-align: center;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-group label {
  font-size: 11px;
  color: #888;
}

.form-group input {
  padding: 8px 10px;
  font-size: 12px;
  background: #0f0f1a;
  border: 1px solid #333;
  border-radius: 3px;
  color: #eee;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: #d4e95b;
}

.form-group input::placeholder {
  color: #808080;
}

.btn-login {
  margin-top: 8px;
  padding: 10px;
  font-size: 12px;
  font-weight: 600;
  background: #4da6ff;
  border: none;
  border-radius: 3px;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-login:hover {
  background: #3d8bd9;
}

.login-footer {
  margin-top: 16px;
  text-align: center;
}

.login-footer a {
  font-size: 10px;
  color: #666;
  text-decoration: none;
}

.login-footer a:hover {
  color: #4da6ff;
}

/* Ajouter dans Login.css */
.btn-login:disabled {
  background: #3a5a7a;
  cursor: not-allowed;
}

.login-footer span {
  font-size: 15px;
  color: #dd3b3b;
}

/* src/components/admin/UserModal.css */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlide 0.2s ease;
}

@keyframes modalSlide {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 10;
}

.modal-header h2 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.btn-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.2s;
}

.btn-close:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.modal-form {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-error {
  padding: 10px 12px;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid var(--danger);
  border-radius: 4px;
  color: var(--danger);
  font-size: 12px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 12px;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group-checkbox {
  justify-content: flex-end;
}

.form-group label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
}

.label-hint {
  font-weight: 400;
  color: var(--text-muted);
}

.form-group input,
.form-group select {
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 12px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--accent);
}

.form-group select {
  cursor: pointer;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-primary);
}

.checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
}

/* Permissions */
.permissions-section {
  border-top: 1px solid var(--border);
  padding-top: 14px;
  margin-top: 4px;
}

.permissions-section h3 {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.global-permissions {
  display: flex;
  gap: 20px;
  margin-bottom: 14px;
  padding: 10px 12px;
  background: var(--bg-tertiary);
  border-radius: 4px;
}

.modules-permissions {
  overflow-x: auto;
}

.permissions-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.permissions-table th,
.permissions-table td {
  padding: 10px 8px;
  text-align: center;
  border: 1px solid var(--border);
}

.permissions-table th {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 10px;
}

.permissions-table .module-name {
  text-align: left;
  font-weight: 500;
  color: var(--text-primary);
  padding-left: 12px;
}

.permissions-table input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
}

/* Footer */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  margin-top: 6px;
}

.btn-cancel,
.btn-submit {
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.btn-cancel:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn-submit {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #fff;
}

.btn-submit:hover {
  background: var(--accent-hover);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Scrollbar modal */
.modal::-webkit-scrollbar {
  width: 6px;
}

.modal::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

.modal::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

/* Responsive */
@media (max-width: 500px) {
  .modal {
    max-height: 100vh;
    border-radius: 0;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .global-permissions {
    flex-direction: column;
    gap: 10px;
  }
}

/* Ajouter à src/components/admin/UserModal.css */

.modal-large {
  max-width: 550px;
}

/* Multi-select dropdown */
.multi-select {
  position: relative;
}

.multi-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 4px;
  cursor: pointer;
  transition: border-color 0.2s;
}

.multi-select-trigger:hover {
  border-color: var(--accent);
}

.multi-select-text {
  font-size: 12px;
  color: var(--text-primary);
}

.multi-select-icon {
  font-size: 16px;
  color: var(--text-muted);
  transition: transform 0.2s;
}

.multi-select-icon.open {
  transform: rotate(180deg);
}

.multi-select-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  animation: dropdownFade 0.15s ease;
}

@keyframes dropdownFade {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.multi-select-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}

.btn-select-all {
  padding: 4px 10px;
  font-size: 10px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-select-all:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.selected-count {
  font-size: 10px;
  color: var(--text-muted);
}

.multi-select-options {
  max-height: 200px;
  overflow-y: auto;
}

.multi-select-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  cursor: pointer;
  transition: background 0.2s;
}

.multi-select-option:hover {
  background: var(--bg-tertiary);
}

.multi-select-option.selected {
  background: rgba(77, 166, 255, 0.1);
}

.option-checkbox {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
}

.multi-select-option.selected .option-checkbox {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.option-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

.option-trigramme {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
}

.option-name {
  font-size: 11px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.no-options {
  padding: 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
}

/* Scrollbar dropdown */
.multi-select-options::-webkit-scrollbar {
  width: 4px;
}

.multi-select-options::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

.multi-select-options::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}

/* Modules section label */
.modules-permissions > label {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* États Commande tab */
.tab-description-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.btn-reset-etats {
  background: none;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  font-size: 0.8rem;
  color: #6b7280;
  cursor: pointer;
  white-space: nowrap;
}

.btn-reset-etats:hover {
  background: #f3f4f6;
  color: #374151;
}

.etats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.75rem 1.5rem;
  gap: 0.75rem 1.5rem;
}

.etat-field label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.etat-key {
  font-weight: 600;
  color: #374151;
}

.etat-default {
  font-size: 0.75rem;
  color: #9ca3af;
  font-weight: 400;
}
/* src/screens/admin/AdminUsers.css */
.admin-users {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-users-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-users-header h1 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-users-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Stats */
.admin-users-stats {
  display: flex;
  gap: 12px;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 100px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
}

/* Search */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent);
}

.search-box svg {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 12px;
  width: 150px;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

/* Buttons */
.btn-primary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Table container */
.admin-users-table-container {
  overflow: auto;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

/* Table */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.admin-table th,
.admin-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.admin-table th {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.admin-table tbody tr {
  transition: background 0.2s;
}

.admin-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.admin-table tbody tr:last-child td {
  border-bottom: none;
}

/* User info */
.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-avatar {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  border-radius: 50%;
  flex-shrink: 0;
}

.user-name {
  font-weight: 500;
  color: var(--text-primary);
}

/* Badges */
.badge {
  padding: 4px 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

.badge-admin {
  background: rgba(255, 107, 107, 0.15);
  color: var(--danger);
}

.badge-user {
  background: rgba(77, 166, 255, 0.15);
  color: var(--accent);
}

/* Status */
.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.status.active {
  color: var(--success);
}

.status.active::before {
  background: var(--success);
}

.status.inactive {
  color: var(--text-muted);
}

.status.inactive::before {
  background: var(--text-muted);
}

/* Date cell */
.date-cell {
  color: var(--text-secondary);
  font-size: 11px;
}

/* Table actions */
.table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  transition: all 0.2s;
}

.btn-action:hover {
  background: var(--bg-primary);
}

.btn-action.btn-edit:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-action.btn-delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-action.btn-toggle:hover {
  border-color: var(--warning);
  color: var(--warning);
}

.btn-action:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* No data */
.no-data {
  text-align: center;
  color: var(--text-muted);
  padding: 40px !important;
}

/* Loading / Error */
.admin-loading,
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 1 1;
  color: var(--text-muted);
  font-size: 14px;
}

.admin-error {
  color: var(--danger);
}

/* Responsive */
@media (max-width: 900px) {
  .admin-users-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-users-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }

  .admin-users-stats {
    width: 100%;
    justify-content: space-between;
  }

  .stat-card {
    flex: 1 1;
    min-width: auto;
  }
}

@media (max-width: 600px) {
  .btn-primary span {
    display: none;
  }

  .admin-table th:nth-child(5),
  .admin-table td:nth-child(5) {
    display: none;
  }
}

/* src/components/shared/Loader/Loader.css */

/* =============================================
   LOADER CONTAINER
   ============================================= */
.loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 20px;
}

.loader-fullscreen {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 17, 23, 0.9);
  background: rgba(var(--bg-primary-rgb, 13, 17, 23), 0.9);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  z-index: 9999;
}

/* =============================================
   SPINNER
   ============================================= */
.loader-spinner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loader-ring {
  position: absolute;
  border-radius: 50%;
  border: 3px solid transparent;
  border-top-color: var(--accent);
  animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.loader-ring:nth-child(1) {
  width: 40px;
  height: 40px;
  animation-delay: -0.45s;
}

.loader-ring:nth-child(2) {
  width: 32px;
  height: 32px;
  border-top-color: var(--accent);
  opacity: 0.8;
  animation-delay: -0.3s;
}

.loader-ring:nth-child(3) {
  width: 24px;
  height: 24px;
  border-top-color: var(--accent);
  opacity: 0.6;
  animation-delay: -0.15s;
}

/* =============================================
   SIZES
   ============================================= */
/* Small */
.loader-small .loader-ring:nth-child(1) {
  width: 24px;
  height: 24px;
  border-width: 2px;
}

.loader-small .loader-ring:nth-child(2) {
  width: 18px;
  height: 18px;
  border-width: 2px;
}

.loader-small .loader-ring:nth-child(3) {
  width: 12px;
  height: 12px;
  border-width: 2px;
}

.loader-small .loader-text {
  font-size: 11px;
}

/* Large */
.loader-large .loader-ring:nth-child(1) {
  width: 56px;
  height: 56px;
  border-width: 4px;
}

.loader-large .loader-ring:nth-child(2) {
  width: 44px;
  height: 44px;
  border-width: 4px;
}

.loader-large .loader-ring:nth-child(3) {
  width: 32px;
  height: 32px;
  border-width: 4px;
}

.loader-large .loader-text {
  font-size: 14px;
}

/* =============================================
   TEXT
   ============================================= */
.loader-text {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin: 0;
  margin-top: 8px;
}

/* =============================================
   ANIMATION
   ============================================= */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* =============================================
   INLINE LOADER (pour boutons)
   ============================================= */
.loader-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.loader-inline .loader-spinner {
  width: 16px;
  height: 16px;
}

.loader-inline .loader-ring {
  border-width: 2px;
}

.loader-inline .loader-ring:nth-child(1) {
  width: 16px;
  height: 16px;
}

.loader-inline .loader-ring:nth-child(2) {
  width: 12px;
  height: 12px;
}

.loader-inline .loader-ring:nth-child(3) {
  width: 8px;
  height: 8px;
}

/* =============================================
   ALTERNATIVE: DOTS LOADER
   ============================================= */
.loader-dots {
  display: flex;
  align-items: center;
  gap: 6px;
}

.loader-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  animation: bounce 1.4s ease-in-out infinite both;
}

.loader-dot:nth-child(1) {
  animation-delay: -0.32s;
}

.loader-dot:nth-child(2) {
  animation-delay: -0.16s;
}

.loader-dot:nth-child(3) {
  animation-delay: 0s;
}

@keyframes bounce {
  0%,
  80%,
  100% {
    transform: scale(0);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}

/* =============================================
   ALTERNATIVE: PULSE LOADER
   ============================================= */
.loader-pulse {
  width: 40px;
  height: 40px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  50% {
    transform: scale(1);
    opacity: 0.5;
  }
  100% {
    transform: scale(0.8);
    opacity: 1;
  }
}

/* src/screens/ForgotPasswordScreen/ForgotPasswordScreen.css */
.forgot-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: #0f0f1a;
}

.forgot-box {
  width: 100%;
  max-width: 320px;
  padding: 24px;
  background: #1a1a2e;
  border: 1px solid #f7dd6d;
  border-radius: 10px;
}

/* ── Header ── */
.forgot-header {
  text-align: center;
  margin-bottom: 16px;
}

.forgot-icon {
  font-size: 28px;
  margin-bottom: 8px;
}

.forgot-header h1 {
  font-size: 18px;
  color: #f7dd6d;
  margin-bottom: 4px;
}

.forgot-header span {
  font-size: 11px;
  color: #b3b0b0;
}

/* ── Description ── */
.forgot-desc {
  font-size: 11px;
  color: #888;
  line-height: 1.6;
  text-align: center;
  margin-bottom: 16px;
}

/* ── Error ── */
.forgot-error {
  padding: 8px;
  margin-bottom: 12px;
  background: #3d1a1a;
  border: 1px solid #5c2a2a;
  border-radius: 3px;
  color: #ff6b6b;
  font-size: 11px;
  text-align: center;
}

/* ── Form ── */
.forgot-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-group label {
  font-size: 11px;
  color: #888;
}

.form-group input {
  padding: 8px 10px;
  font-size: 12px;
  background: #0f0f1a;
  border: 1px solid #333;
  border-radius: 3px;
  color: #eee;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: #d4e95b;
}

.form-group input::placeholder {
  color: #808080;
}

/* ── Submit button ── */
.btn-submit {
  margin-top: 4px;
  padding: 10px;
  font-size: 12px;
  font-weight: 600;
  background: #4da6ff;
  border: none;
  border-radius: 3px;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: #3d8bd9;
}

.btn-submit:disabled {
  background: #3a5a7a;
  cursor: not-allowed;
}

/* ── Footer ── */
.forgot-footer {
  margin-top: 16px;
  text-align: center;
}

.back-link {
  font-size: 11px;
  color: #555;
  text-decoration: none;
  transition: color 0.2s;
}

.back-link:hover {
  color: #4da6ff;
}

/* ── Succès ── */
.forgot-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 20px 16px;
  background: #0d2d1a;
  border: 1px solid #1a5c35;
  border-radius: 8px;
  text-align: center;
}

.forgot-success-icon {
  font-size: 30px;
}

.forgot-success p {
  font-size: 12px;
  color: #68d391;
  line-height: 1.6;
}

.forgot-success-sub {
  font-size: 10px !important;
  color: #4a7c59 !important;
}

.btn-back {
  margin-top: 6px;
  padding: 8px 20px;
  font-size: 11px;
  font-weight: 600;
  background: #1a4a2e;
  border: 1px solid #2d7a4a;
  border-radius: 3px;
  color: #68d391;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-back:hover {
  background: #1f5c38;
}
/* src/screens/ResetPasswordScreen/ResetPasswordScreen.css */
.reset-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: #0f0f1a;
}

.reset-box {
  width: 100%;
  max-width: 320px;
  padding: 24px;
  background: #1a1a2e;
  border: 1px solid #f7dd6d;
  border-radius: 10px;
}

/* ── Header ── */
.reset-header {
  text-align: center;
  margin-bottom: 20px;
}

.reset-icon {
  font-size: 28px;
  margin-bottom: 8px;
}

.reset-header h1 {
  font-size: 18px;
  color: #f7dd6d;
  margin-bottom: 4px;
}

.reset-header span {
  font-size: 11px;
  color: #b3b0b0;
}

/* ── Error ── */
.reset-error {
  padding: 8px;
  margin-bottom: 12px;
  background: #3d1a1a;
  border: 1px solid #5c2a2a;
  border-radius: 3px;
  color: #ff6b6b;
  font-size: 11px;
  text-align: center;
}

/* ── Form ── */
.reset-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-group label {
  font-size: 11px;
  color: #888;
}

.form-group input {
  padding: 8px 10px;
  font-size: 12px;
  background: #0f0f1a;
  border: 1px solid #333;
  border-radius: 3px;
  color: #eee;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: #d4e95b;
}

.form-group input::placeholder {
  color: #808080;
}

/* ── Password rules ── */
.password-rules {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: -4px;
}

.rule {
  font-size: 10px;
  color: #555;
  transition: color 0.2s;
}

.rule.valid {
  color: #68d391;
}

/* ── Submit ── */
.btn-submit {
  margin-top: 4px;
  padding: 10px;
  font-size: 12px;
  font-weight: 600;
  background: #4da6ff;
  border: none;
  border-radius: 3px;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: #3d8bd9;
}

.btn-submit:disabled {
  background: #3a5a7a;
  cursor: not-allowed;
}

/* ── Footer ── */
.reset-footer {
  margin-top: 16px;
  text-align: center;
}

.back-link {
  font-size: 11px;
  color: #555;
  text-decoration: none;
  transition: color 0.2s;
}

.back-link:hover {
  color: #4da6ff;
}

/* ── Succès ── */
.reset-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 20px 16px;
  background: #0d2d1a;
  border: 1px solid #1a5c35;
  border-radius: 8px;
  text-align: center;
}

.reset-success-icon {
  font-size: 30px;
}

.reset-success p {
  font-size: 12px;
  color: #68d391;
  line-height: 1.6;
}

.reset-redirect {
  font-size: 10px !important;
  color: #4a7c59 !important;
}
/* src/screens/NotFoundScreen.css */

/* Version dans le dashboard (connecté) */
.notfound-container.in-dashboard {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  flex: 1 1;
}

/* Version plein écran (non connecté) */
.notfound-container.fullscreen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--bg-primary);
}

.notfound-box {
  text-align: center;
  padding: 32px;
}

.notfound-code {
  font-size: 80px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 8px;
}

.in-dashboard .notfound-code {
  font-size: 64px;
}

.notfound-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--danger);
  margin-bottom: 8px;
}

.in-dashboard .notfound-title {
  font-size: 18px;
}

.notfound-message {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.in-dashboard .notfound-message {
  font-size: 12px;
}

.notfound-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  font-size: 12px;
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 4px;
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-back:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.btn-back.btn-secondary {
  background: transparent;
  border-color: var(--border);
  color: var(--text-secondary);
}

.btn-back.btn-secondary:hover {
  background: var(--bg-tertiary);
  border-color: var(--text-muted);
  color: var(--text-primary);
}

/* src/components/Admin/TacheCronDocumentationModal.css */

.doc-modal {
  max-width: 700px;
  max-height: 85vh;
}

/* Doc List */
.doc-list {
  margin-bottom: 20px;
}

.doc-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.doc-list-header span {
  font-size: 13px;
  color: var(--text-secondary);
}

.btn-add-doc {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-add-doc:hover {
  background: var(--accent-hover);
}

/* No docs */
.no-docs {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: var(--bg-tertiary);
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--text-muted);
}

.no-docs svg {
  font-size: 48px;
  opacity: 0.3;
  margin-bottom: 12px;
}

.no-docs p {
  font-size: 14px;
  margin-bottom: 16px;
}

.btn-add-first {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-add-first:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Doc Items */
.doc-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.doc-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: all 0.2s;
}

.doc-item:hover {
  border-color: var(--accent);
}

.doc-item-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--accent);
  font-size: 18px;
  flex-shrink: 0;
}

.doc-item-info {
  flex: 1 1;
  min-width: 0;
}

.doc-item-title {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.doc-item-meta {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.doc-item-actions {
  display: flex;
  gap: 6px;
}

.btn-doc-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-doc-action:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-doc-action.delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-doc-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Doc Form */
.doc-form {
  padding: 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-top: 16px;
}

.doc-form-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.doc-form-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.btn-cancel-form {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel-form:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

/* File Upload Zone */
.file-upload-zone {
  position: relative;
}

.file-input {
  display: none;
}

.file-upload-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px;
  background: var(--bg-primary);
  border: 2px dashed var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.file-upload-btn:hover {
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.05);
}

.file-upload-btn svg {
  font-size: 20px;
  color: var(--accent);
}

.file-upload-btn span {
  font-size: 12px;
  color: var(--text-secondary);
}

/* Form Actions */
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* Flex helpers for form-row */
.flex-1 {
  flex: 1 1;
}

.flex-2 {
  flex: 2 1;
}

/* Responsive */
@media (max-width: 600px) {
  .doc-modal {
    max-height: 100vh;
    border-radius: 0;
  }

  .doc-item {
    flex-wrap: wrap;
  }

  .doc-item-info {
    width: calc(100% - 52px);
  }

  .doc-item-actions {
    width: 100%;
    justify-content: flex-end;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
  }

  .form-row {
    flex-direction: column;
  }
}
/* src/screens/admin/AdminTachesCronScreen.css */

/* ==========================================
   LAYOUT PRINCIPAL
   ========================================== */
.admin-taches-cron {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}

.admin-taches-cron-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-taches-cron-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-taches-cron-header h1 svg {
  color: var(--accent);
}

.admin-taches-cron-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* ==========================================
   STATS
   ========================================== */
.admin-taches-cron-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stat-card.en-cours {
  border-color: var(--warning);
}

.stat-card.en-cours .stat-value {
  color: var(--warning);
}

.stat-card.erreur {
  border-color: var(--danger);
}

.stat-card.erreur .stat-value {
  color: var(--danger);
}

.stat-card.succes .stat-value {
  color: var(--success);
}

/* ==========================================
   GRILLE DES TÂCHES
   ========================================== */
.admin-taches-cron-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  grid-gap: 16px;
  gap: 16px;
  flex: 1 1;
  overflow-y: auto;
  padding-bottom: 16px;
}

/* ==========================================
   CARTE TÂCHE CRON
   ========================================== */
.tache-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.2s;
}

.tache-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.tache-card.inactive {
  opacity: 0.6;
}

.tache-card.inactive:hover {
  opacity: 0.8;
}

.tache-card.en-cours {
  border-color: var(--warning);
  box-shadow:
    0 0 0 1px var(--warning),
    0 4px 12px rgba(234, 179, 8, 0.15);
}

.tache-card.en-erreur {
  border-color: var(--danger);
}

/* Header */
.tache-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
}

.tache-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--accent);
}

.tache-header-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

/* Statut badges */
.statut-badge {
  padding: 4px 8px;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.statut-badge.active {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}

.statut-badge.inactive {
  background: rgba(102, 102, 102, 0.15);
  color: var(--text-muted);
}

.statut-badge.en_cours {
  background: rgba(234, 179, 8, 0.15);
  color: var(--warning);
}

.statut-badge.erreur {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
}

/* Indicateur pulsation en cours */
.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--warning);
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.7);
  }
}

/* Body */
.tache-card-body {
  padding: 16px;
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tache-titre {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tache-description {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

/* Commande affichée */
.tache-commande {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: var(--bg-tertiary);
  border-radius: 6px;
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 11px;
  color: var(--accent);
  overflow: hidden;
}

.tache-commande svg {
  flex-shrink: 0;
  font-size: 14px;
  color: var(--text-muted);
}

.tache-commande code {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Meta infos */
.tache-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.meta-item svg {
  font-size: 14px;
  color: var(--accent);
}

/* Fréquence */
.tache-frequence {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(var(--accent-rgb), 0.08);
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  border-radius: 6px;
  font-size: 11px;
  color: var(--text-secondary);
}

.tache-frequence svg {
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
}

.tache-frequence code {
  font-family: "JetBrains Mono", "Fira Code", monospace;
  color: var(--text-muted);
  font-size: 10px;
}

/* Dernière exécution */
.tache-derniere-exec {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  margin-top: auto;
  font-size: 11px;
  color: var(--text-muted);
}

.tache-derniere-exec svg {
  color: var(--accent);
}

.derniere-exec-statut {
  font-weight: 600;
}

.derniere-exec-statut.succes {
  color: var(--success);
}

.derniere-exec-statut.erreur {
  color: var(--danger);
}

.derniere-exec-statut.timeout {
  color: var(--warning);
}

.derniere-exec-statut.annule {
  color: var(--text-muted);
}

/* Stats exécutions */
.tache-exec-stats {
  display: flex;
  gap: 12px;
  font-size: 10px;
  color: var(--text-muted);
}

.exec-stat {
  display: flex;
  align-items: center;
  gap: 3px;
}

.exec-stat.succes {
  color: var(--success);
}

.exec-stat.erreur {
  color: var(--danger);
}

/* Footer */
.tache-card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tache-card-footer .card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Bouton exécuter */
.btn-executer {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-executer:hover {
  background: var(--accent-hover);
  transform: scale(1.03);
}

.btn-executer:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-executer.running {
  background: var(--warning);
  cursor: pointer;
  opacity: 1;
}

.btn-executer.running:hover {
  background: #d97706;
}

/* Spinner */
.spinner-sm {
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* btn-action override spécifique */
.btn-action.btn-history:hover {
  border-color: #6366f1;
  color: #6366f1;
}

.btn-action.btn-logs:hover {
  border-color: #10b981;
  color: #10b981;
}

/* ==========================================
   MODAL
   ========================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.modal-content.large {
  max-width: 800px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-tertiary);
}

.modal-header h2 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-header h2 svg {
  color: var(--accent);
}

.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.modal-close:hover {
  color: var(--danger);
  border-color: var(--danger);
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-tertiary);
}

/* ==========================================
   FORMULAIRE
   ========================================== */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 12px;
  gap: 12px;
}

.form-group label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-group label .required {
  color: var(--danger);
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 8px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}

.form-group textarea {
  resize: vertical;
  min-height: 60px;
  font-family: inherit;
}

.form-group input.mono,
.form-group textarea.mono {
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 12px;
}

.form-hint {
  font-size: 10px;
  color: var(--text-muted);
  font-style: italic;
}

/* Boutons du modal */
.btn-secondary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn-danger {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--danger);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-danger:hover {
  background: #dc2626;
}

.btn-primary:disabled,
.btn-danger:disabled,
.btn-secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.executions-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.execution-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.execution-item:hover {
  border-color: var(--accent);
  background: var(--bg-tertiary);
}

.execution-statut-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.execution-statut-dot.succes {
  background: var(--success);
}

.execution-statut-dot.erreur {
  background: var(--danger);
}

.execution-statut-dot.timeout {
  background: var(--warning);
}

.execution-statut-dot.annule {
  background: var(--text-muted);
}

.execution-statut-dot.en_cours {
  background: var(--warning);
  animation: pulse 1.5s ease-in-out infinite;
}

.execution-info {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.execution-info-top {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}

.execution-info-top .statut-text {
  font-weight: 600;
  text-transform: capitalize;
}

.execution-info-top .statut-text.succes {
  color: var(--success);
}
.execution-info-top .statut-text.erreur {
  color: var(--danger);
}
.execution-info-top .statut-text.timeout {
  color: var(--warning);
}
.execution-info-top .statut-text.annule {
  color: var(--text-muted);
}
.execution-info-top .statut-text.en_cours {
  color: var(--warning);
}

.execution-info-bottom {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 10px;
  color: var(--text-muted);
}

.execution-duree {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--text-secondary);
}

/* Détail log */
.execution-detail {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.execution-detail-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 8px;
  gap: 8px;
}

.detail-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px;
  background: var(--bg-primary);
  border-radius: 6px;
}

.detail-field .label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.detail-field .value {
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
}

.log-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.log-section-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.log-section-title svg {
  font-size: 14px;
}

.log-section-title.stdout svg {
  color: var(--success);
}
.log-section-title.stderr svg {
  color: var(--danger);
}

.log-output {
  padding: 12px;
  background: #0d1117;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 11px;
  line-height: 1.6;
  color: #c9d1d9;
  max-height: 250px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-all;
}

.log-output.stderr {
  color: #f87171;
}

.log-empty {
  padding: 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
  font-style: italic;
}

/* Pagination modal */
.modal-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.modal-pagination button {
  padding: 4px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 11px;
  cursor: pointer;
}

.modal-pagination button:hover {
  border-color: var(--accent);
}

.modal-pagination button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.modal-pagination span {
  font-size: 11px;
  color: var(--text-muted);
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1024px) {
  .admin-taches-cron-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-taches-cron-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .admin-taches-cron-stats {
    width: 100%;
  }

  .stat-card {
    flex: 1 1;
    min-width: 70px;
    padding: 10px 12px;
  }

  .stat-value {
    font-size: 18px;
  }

  .admin-taches-cron-grid {
    grid-template-columns: 1fr;
  }

  .filter-select {
    flex: 1 1;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .execution-detail-header {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .btn-primary span {
    display: none;
  }

  .btn-executer span {
    display: none;
  }

  .admin-taches-cron-actions {
    flex-wrap: wrap;
  }

  .checkbox-label span {
    display: none;
  }
}

.admin-taches-cron {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}
.admin-taches-cron-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.admin-taches-cron-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}
.admin-taches-cron-header h1 svg {
  color: var(--accent);
}
.admin-taches-cron-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.admin-taches-cron-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.stat-card.en-cours {
  border-color: var(--warning);
}
.stat-card.en-cours .stat-value {
  color: var(--warning);
}
.stat-card.erreur {
  border-color: var(--danger);
}
.stat-card.erreur .stat-value {
  color: var(--danger);
}
.admin-taches-cron-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  grid-gap: 16px;
  gap: 16px;
  flex: 1 1;
  overflow-y: auto;
  padding-bottom: 16px;
}
.tache-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.2s;
  max-height: 390px;
}
.tache-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.tache-card.inactive {
  opacity: 0.6;
}
.tache-card.inactive:hover {
  opacity: 0.8;
}
.tache-card.en-cours {
  border-color: var(--warning);
  box-shadow:
    0 0 0 1px var(--warning),
    0 4px 12px rgba(234, 179, 8, 0.15);
}
.tache-card.en-erreur {
  border-color: var(--danger);
}
.tache-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
}
.tache-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--accent);
}
.tache-header-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.statut-badge {
  padding: 4px 8px;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.statut-badge.active {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}
.statut-badge.inactive {
  background: rgba(102, 102, 102, 0.15);
  color: var(--text-muted);
}
.statut-badge.en_cours {
  background: rgba(234, 179, 8, 0.15);
  color: var(--warning);
}
.statut-badge.erreur {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
}
.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--warning);
  animation: pulse 1.5s ease-in-out infinite;
}
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.7);
  }
}
.tache-card-body {
  padding: 16px;
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.tache-titre {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}
.tache-description {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}
.tache-commande {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: var(--bg-tertiary);
  border-radius: 6px;
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 11px;
  color: var(--accent);
  overflow: hidden;
}
.tache-commande svg {
  flex-shrink: 0;
  font-size: 14px;
  color: var(--text-muted);
}
.tache-commande code {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tache-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}
.meta-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--text-muted);
}
.meta-item svg {
  font-size: 12px;
}
.tache-frequence {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(var(--accent-rgb), 0.08);
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  border-radius: 6px;
  font-size: 11px;
  color: var(--text-secondary);
}
.tache-frequence svg {
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
}
.tache-frequence code {
  font-family: "JetBrains Mono", monospace;
  color: var(--text-muted);
  font-size: 10px;
}
.tache-derniere-exec {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  margin-top: auto;
  font-size: 11px;
  color: var(--text-muted);
}
.tache-derniere-exec svg {
  color: var(--accent);
}
.derniere-exec-statut {
  font-weight: 600;
}
.derniere-exec-statut.succes {
  color: var(--success);
}
.derniere-exec-statut.erreur {
  color: var(--danger);
}
.derniere-exec-statut.timeout {
  color: var(--warning);
}
.derniere-exec-statut.annule {
  color: var(--text-muted);
}
.tache-exec-stats {
  display: flex;
  gap: 12px;
  font-size: 10px;
  color: var(--text-muted);
}
.exec-stat {
  display: flex;
  align-items: center;
  gap: 3px;
}
.exec-stat.succes {
  color: var(--success);
}
.exec-stat.erreur {
  color: var(--danger);
}
.outil-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.tag {
  padding: 2px 8px;
  font-size: 10px;
  border-radius: 4px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  background: var(--bg-primary);
}
.tag.more {
  color: var(--text-muted);
  font-style: italic;
}
.tache-card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.tache-card-footer .card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}
.btn-executer {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-executer:hover {
  background: var(--accent-hover);
  transform: scale(1.03);
}
.btn-executer:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}
.btn-executer.running {
  background: var(--warning);
  cursor: pointer;
  opacity: 1;
}
.btn-executer.running:hover {
  background: #d97706;
}
.spinner-sm {
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.btn-action.btn-history:hover {
  border-color: #6366f1;
  color: #6366f1;
}
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
.modal-content.large {
  max-width: 800px;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-tertiary);
}
.modal-header h2 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.modal-header h2 svg {
  color: var(--accent);
}
.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}
.modal-close:hover {
  color: var(--danger);
  border-color: var(--danger);
}
.modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-tertiary);
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 12px;
  gap: 12px;
}
.form-group label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}
.form-group label .required {
  color: var(--danger);
}
.form-group input,
.form-group select,
.form-group textarea {
  padding: 8px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}
.form-group textarea {
  resize: vertical;
  min-height: 60px;
  font-family: inherit;
}
.form-group input.mono,
.form-group textarea.mono {
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 12px;
}
.form-hint {
  font-size: 10px;
  color: var(--text-muted);
  font-style: italic;
}
.arg-row {
  padding: 10px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-top: 6px;
}
.arg-fields {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.arg-input {
  padding: 6px 10px !important;
  font-size: 12px !important;
  border: 1px solid var(--border) !important;
  border-radius: 4px !important;
  background: var(--bg-secondary) !important;
  flex: 1 1;
  min-width: 100px;
}
.arg-input.arg-desc {
  flex: 2 1;
  min-width: 150px;
}
.arg-default-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
}
.arg-default-toggle input {
  accent-color: var(--accent);
}
.args-selector {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.arg-chip {
  padding: 12px;
  background: var(--bg-primary);
  border: 2px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}
.arg-chip:hover {
  border-color: var(--accent);
  background: var(--bg-tertiary);
}
.arg-chip.selected {
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.08);
}
.arg-chip-header {
  display: flex;
  align-items: center;
  gap: 10px;
}
.arg-chip-header input[type="checkbox"] {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
  cursor: pointer;
}
.arg-chip-nom {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}
.arg-chip-valeur {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.1);
  padding: 2px 6px;
  border-radius: 4px;
}
.arg-chip-desc {
  margin: 6px 0 0 26px;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
}
.btn-secondary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-secondary:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}
.btn-primary:disabled,
.btn-secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.executions-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.execution-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}
.execution-item:hover {
  border-color: var(--accent);
  background: var(--bg-tertiary);
}
.execution-statut-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.execution-statut-dot.succes {
  background: var(--success);
}
.execution-statut-dot.erreur {
  background: var(--danger);
}
.execution-statut-dot.timeout {
  background: var(--warning);
}
.execution-statut-dot.annule {
  background: var(--text-muted);
}
.execution-statut-dot.en_cours {
  background: var(--warning);
  animation: pulse 1.5s ease-in-out infinite;
}
.execution-info {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.execution-info-top {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}
.execution-info-top .statut-text {
  font-weight: 600;
  text-transform: capitalize;
}
.execution-info-top .statut-text.succes {
  color: var(--success);
}
.execution-info-top .statut-text.erreur {
  color: var(--danger);
}
.execution-info-top .statut-text.timeout {
  color: var(--warning);
}
.execution-info-top .statut-text.annule {
  color: var(--text-muted);
}
.execution-info-top .statut-text.en_cours {
  color: var(--warning);
}
.execution-info-bottom {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 10px;
  color: var(--text-muted);
}
.execution-duree {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--text-secondary);
}
.execution-detail {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.execution-detail-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 8px;
  gap: 8px;
}
.detail-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px;
  background: var(--bg-primary);
  border-radius: 6px;
}
.detail-field .label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
}
.detail-field .value {
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
}
.log-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.log-section-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}
.log-section-title svg {
  font-size: 14px;
}
.log-section-title.stdout svg {
  color: var(--success);
}
.log-section-title.stderr svg {
  color: var(--danger);
}
.log-output {
  padding: 12px;
  background: #0d1117;
  border: 1px solid #30363d;
  border-radius: 8px;
  font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
  font-size: 11px;
  line-height: 1.6;
  color: #c9d1d9;
  max-height: 300px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-all;
  margin: 0;
}
.log-output.stderr {
  color: #f87171;
  background: #1a0a0a;
  border-color: #7f1d1d;
}
.log-empty {
  padding: 16px;
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
  background: var(--bg-primary);
  border-radius: 8px;
  border: 1px dashed var(--border);
}
.fichiers-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fichier-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: all 0.2s;
}
.fichier-item:hover {
  border-color: var(--accent);
}
.fichier-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(var(--accent-rgb), 0.1);
  border-radius: 6px;
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
}
.fichier-info {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.fichier-nom {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fichier-meta {
  font-size: 10px;
  color: var(--text-muted);
}
.fichier-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.modal-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-top: 12px;
}
.modal-pagination button {
  padding: 4px 10px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
}
.modal-pagination button:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.modal-pagination button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.modal-pagination span {
  font-size: 12px;
  color: var(--text-muted);
}
.no-data {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 40px;
  color: var(--text-muted);
  grid-column-start: 1;
  grid-column-end: -1;
}
.no-data svg {
  font-size: 32px;
}
.admin-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: var(--text-muted);
  font-size: 14px;
}
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: var(--danger);
  font-size: 14px;
}
@media (max-width: 768px) {
  .admin-taches-cron-grid {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .execution-detail-header {
    grid-template-columns: 1fr;
  }
  .admin-taches-cron-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .admin-taches-cron-actions {
    width: 100%;
  }
}

/* ==========================================
   AJOUTS POUR DOCUMENTATION
   À ajouter à la fin de AdminTachesCronScreen.css
   ========================================== */

/* Badge compteur documentation dans le header de la carte */
.doc-count-badge {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 7px;
  font-size: 9px;
  font-weight: 600;
  border-radius: 4px;
  background: rgba(99, 102, 241, 0.12);
  color: #6366f1;
}

.doc-count-badge svg {
  font-size: 11px;
}

/* Bouton documentation dans le footer */
.btn-action.btn-doc:hover {
  border-color: #6366f1;
  color: #6366f1;
}

/* src/components/Admin/OutilModal.css */

/* Modal Overlay */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
  overflow-y: auto;
}

/* Modal Content */
.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-content.outil-modal {
  max-width: 700px;
}

/* Modal Header */
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-tertiary);
}

.modal-header h2 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.modal-close:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

/* Modal Body */
.modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1 1;
}

/* Form Groups */
.form-group {
  margin-bottom: 16px;
}

.form-row {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.form-row .form-group {
  margin-bottom: 0;
}

.flex-1 {
  flex: 1 1;
}

.flex-2 {
  flex: 2 1;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-group label svg {
  font-size: 14px;
  color: var(--accent);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

/* Form Section */
.form-section {
  margin-bottom: 20px;
  padding: 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.form-section h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 12px 0;
}

.form-section h3 svg {
  color: var(--accent);
}

/* File Upload */
.file-upload-area {
  position: relative;
}

.file-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
}

.file-upload-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  background: var(--bg-primary);
  border: 2px dashed var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.file-upload-label:hover {
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.05);
}

.file-upload-label svg {
  font-size: 32px;
  color: var(--accent);
}

.file-upload-label span {
  font-size: 12px;
  color: var(--text-secondary);
  text-align: center;
}

.file-upload-label .file-size {
  font-size: 11px;
  color: var(--text-muted);
}

.file-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 8px;
}

/* Image Upload */
.image-upload-area {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.image-preview {
  width: 120px;
  height: 120px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.image-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text-muted);
}

.image-placeholder svg {
  font-size: 32px;
  opacity: 0.3;
}

.image-placeholder span {
  font-size: 10px;
}

.image-upload-controls {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-upload {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-upload:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Checkbox */
.checkbox-group {
  margin-top: 16px;
}

.checkbox-container {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-secondary);
}

.checkbox-container input {
  width: auto;
  accent-color: var(--accent);
}

.checkbox-text {
  flex: 1 1;
}

/* Modal Footer */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  margin-top: 20px;
}

.btn-cancel {
  padding: 10px 20px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn-submit {
  padding: 10px 24px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: var(--accent-hover);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Responsive */
@media (max-width: 600px) {
  .modal-content {
    max-height: 100vh;
    border-radius: 0;
  }

  .form-row {
    flex-direction: column;
    gap: 0;
  }

  .form-row .form-group {
    margin-bottom: 16px;
  }

  .image-upload-area {
    flex-direction: column;
    align-items: center;
  }

  .image-preview {
    width: 100px;
    height: 100px;
  }

  .image-upload-controls {
    align-items: center;
    text-align: center;
  }
}

/* src/components/Admin/OutilAccesModal.css */

.acces-modal {
  max-width: 650px;
  max-height: 85vh;
}

/* Public access section */
.acces-public-section {
  padding: 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 20px;
}

.toggle-container {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.toggle-container input {
  display: none;
}

.toggle-slider {
  position: relative;
  width: 44px;
  height: 24px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: all 0.3s;
}

.toggle-slider::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  background: var(--text-muted);
  border-radius: 50%;
  transition: all 0.3s;
}

.toggle-container input:checked + .toggle-slider {
  background: var(--accent);
  border-color: var(--accent);
}

.toggle-container input:checked + .toggle-slider::before {
  transform: translateX(20px);
  background: #fff;
}

.toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.toggle-label svg {
  font-size: 18px;
  color: var(--accent);
}

.info-text {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 10px;
  padding-left: 56px;
}

/* Tabs */
.acces-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.tab-btn:hover {
  border-color: var(--accent);
  color: var(--text-primary);
}

.tab-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.tab-btn svg {
  font-size: 16px;
}

/* Tab Content */
.tab-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* List Header */
.list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.list-header .search-box {
  flex: 1 1;
  min-width: 200px;
}

.list-actions {
  display: flex;
  gap: 8px;
}

.btn-small {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-small:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-small svg {
  font-size: 12px;
}

/* Selected Items */
.selected-items {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  background: rgba(var(--accent-rgb), 0.1);
  border: 1px solid var(--accent);
  border-radius: 6px;
  flex-wrap: wrap;
}

.selected-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--accent);
}

.selected-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  background: var(--accent);
  border-radius: 4px;
  color: #fff;
  font-size: 11px;
}

.chip button {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  padding: 0;
  margin-left: 2px;
}

.chip button:hover {
  color: #fff;
}

.chip.more {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

/* Items List */
.items-list {
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.items-list .loading,
.items-list .no-items {
  padding: 40px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}

.item-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background 0.2s;
}

.item-row:last-child {
  border-bottom: none;
}

.item-row:hover {
  background: var(--bg-tertiary);
}

.item-row.selected {
  background: rgba(var(--accent-rgb), 0.1);
}

.item-checkbox {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--accent);
  font-size: 14px;
}

.item-row.selected .item-checkbox {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.item-avatar {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.item-avatar.entreprise {
  border-radius: 6px;
  font-size: 10px;
  color: var(--accent);
}

.item-info {
  flex: 1 1;
  min-width: 0;
}

.item-name {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.item-detail {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.item-badge {
  padding: 3px 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  white-space: nowrap;
}

.item-badge.admin {
  background: rgba(139, 92, 246, 0.15);
  color: #8b5cf6;
}

.item-badge.user {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

.item-badge.active {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}

.item-badge.inactive {
  background: rgba(102, 102, 102, 0.15);
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 600px) {
  .acces-modal {
    max-height: 100vh;
    border-radius: 0;
  }

  .list-header {
    flex-direction: column;
    align-items: stretch;
  }

  .list-actions {
    justify-content: space-between;
  }

  .btn-small span {
    display: none;
  }

  .acces-tabs {
    flex-direction: column;
  }

  .tab-btn {
    justify-content: center;
  }
}

/* src/components/Admin/OutilDocumentationModal.css */

.doc-modal {
  max-width: 700px;
  max-height: 85vh;
}

/* Doc List */
.doc-list {
  margin-bottom: 20px;
}

.doc-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.doc-list-header span {
  font-size: 13px;
  color: var(--text-secondary);
}

.btn-add-doc {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-add-doc:hover {
  background: var(--accent-hover);
}

/* No docs */
.no-docs {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: var(--bg-tertiary);
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--text-muted);
}

.no-docs svg {
  font-size: 48px;
  opacity: 0.3;
  margin-bottom: 12px;
}

.no-docs p {
  font-size: 14px;
  margin-bottom: 16px;
}

.btn-add-first {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-add-first:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Doc Items */
.doc-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.doc-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: all 0.2s;
}

.doc-item:hover {
  border-color: var(--accent);
}

.doc-item-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--accent);
  font-size: 18px;
  flex-shrink: 0;
}

.doc-item-info {
  flex: 1 1;
  min-width: 0;
}

.doc-item-title {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.doc-item-meta {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.doc-item-actions {
  display: flex;
  gap: 6px;
}

.btn-doc-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-doc-action:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-doc-action.delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-doc-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Doc Form */
.doc-form {
  padding: 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-top: 16px;
}

.doc-form-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.doc-form-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.btn-cancel-form {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel-form:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

/* File Upload Zone */
.file-upload-zone {
  position: relative;
}

.file-upload-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px;
  background: var(--bg-primary);
  border: 2px dashed var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.file-upload-btn:hover {
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.05);
}

.file-upload-btn svg {
  font-size: 20px;
  color: var(--accent);
}

.file-upload-btn span {
  font-size: 12px;
  color: var(--text-secondary);
}

/* Form Actions */
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* Responsive */
@media (max-width: 600px) {
  .doc-modal {
    max-height: 100vh;
    border-radius: 0;
  }

  .doc-item {
    flex-wrap: wrap;
  }

  .doc-item-info {
    width: calc(100% - 52px);
  }

  .doc-item-actions {
    width: 100%;
    justify-content: flex-end;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
  }

  .form-row {
    flex-direction: column;
  }
}

/* src/screens/admin/AdminOutilsScreen.css */
.admin-outils {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}

.admin-outils-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-outils-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-outils-header h1 svg {
  color: var(--accent);
}

.admin-outils-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Search */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent);
}

.search-box svg {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 12px;
  width: 150px;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

/* Filter select */
.filter-select {
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 12px;
  outline: none;
  cursor: pointer;
}

.filter-select:focus {
  border-color: var(--accent);
}

/* Checkbox label */
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.checkbox-label:hover {
  border-color: var(--accent);
}

.checkbox-label input {
  accent-color: var(--accent);
}

/* Stats */
.admin-outils-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 100px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
}

/* Buttons */
.btn-primary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Grid */
.admin-outils-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  grid-gap: 16px;
  gap: 16px;
  flex: 1 1;
  overflow-y: auto;
  padding-bottom: 16px;
}

/* Outil Card */
.outil-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.2s;
  max-height: 450px !important;
}

.outil-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.outil-card.inactive {
  opacity: 0.6;
}

.outil-card.inactive:hover {
  opacity: 0.8;
}

/* Card Header */
.outil-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
}

.outil-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
}

.outil-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.outil-icon-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--accent);
}

.outil-header-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.status-badge {
  padding: 4px 8px;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

.status-badge.active {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}

.status-badge.inactive {
  background: rgba(102, 102, 102, 0.15);
  color: var(--text-muted);
}

.access-badge {
  padding: 4px 8px;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

.access-badge.public {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

/* Card Body */
.outil-card-body {
  padding: 16px;
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.outil-titre {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.outil-version {
  font-size: 11px;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 500;
}

.outil-description {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.outil-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
}

.meta-item svg {
  font-size: 14px;
  color: var(--accent);
}

.outil-file-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  background: var(--bg-tertiary);
  border-radius: 6px;
  font-family: monospace;
}

.file-name {
  font-size: 11px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

.file-size {
  font-size: 10px;
  color: var(--text-muted);
  white-space: nowrap;
}

.outil-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  padding: 3px 8px;
  font-size: 10px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
}

.tag.more {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.outil-access-info {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--text-muted);
  padding-top: 8px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.outil-access-info svg {
  color: var(--accent);
}

/* Card Footer */
.outil-card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--bg-tertiary);
}

.card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-action:hover {
  background: var(--bg-primary);
}

.btn-action.btn-view:hover {
  border-color: #3b82f6;
  color: #3b82f6;
}

.btn-action.btn-users:hover {
  border-color: #8b5cf6;
  color: #8b5cf6;
}

.btn-action.btn-edit:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-action.btn-delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-action.btn-toggle:hover {
  border-color: var(--warning);
  color: var(--warning);
}

.btn-action:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* No data */
.no-data {
  grid-column-start: 1; grid-column-end: -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 20px;
  color: var(--text-muted);
}

.no-data svg {
  font-size: 48px;
  opacity: 0.3;
}

.no-data p {
  font-size: 14px;
}

/* Loading / Error */
.admin-loading,
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 1 1;
  color: var(--text-muted);
  font-size: 14px;
}

.admin-error {
  color: var(--danger);
}

/* Responsive */
@media (max-width: 1024px) {
  .admin-outils-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-outils-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .admin-outils-stats {
    width: 100%;
  }

  .stat-card {
    flex: 1 1;
    min-width: 70px;
    padding: 10px 12px;
  }

  .stat-value {
    font-size: 18px;
  }

  .admin-outils-grid {
    grid-template-columns: 1fr;
  }

  .filter-select {
    flex: 1 1;
  }
}

@media (max-width: 480px) {
  .btn-primary span {
    display: none;
  }

  .admin-outils-actions {
    flex-wrap: wrap;
  }

  .checkbox-label span {
    display: none;
  }
}

/* ═══════════════════════════════════════════════════════
   UserDashboardScreen.css — Mobile-first dashboard cards
   Inspiré du style AdminDashboard existant
   ═══════════════════════════════════════════════════════ */

/* =============================================
   DASHBOARD CONTAINER
   ============================================= */
.user-dashboard {
  padding: 16px 20px;
  width: 100%;
  max-width: 100%;
  margin: 0;
}

/* =============================================
   HEADER
   ============================================= */
.ud-header {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.ud-header-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ud-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.ud-welcome {
  font-size: 17px;
  color: var(--text-muted);
  margin: 0;
}

.ud-welcome strong {
  color: var(--text-primary);
}

.ud-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ud-date {
  font-size: 11px;
  color: var(--text-secondary);
  text-transform: capitalize;
}

.ud-time {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-primary);
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  background: var(--bg-tertiary);
  padding: 6px 12px;
  border-radius: 6px;
  white-space: nowrap;
}

/* =============================================
   CARDS GRID — Mobile first: 2 colonnes
   ============================================= */
.ud-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 10px;
  gap: 10px;
}

/* =============================================
   CARD
   ============================================= */
.ud-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  color: var(--text-primary);
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
  min-height: 100px;
  overflow: hidden;
  opacity: 0;
  animation: fadeInUp 0.3s ease forwards;
}

.ud-card:active {
  transform: scale(0.97);
}

.ud-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
  border-color: var(--accent);
}

/* Staggered animation delays */
.ud-card:nth-child(1) { animation-delay: 0.03s; }
.ud-card:nth-child(2) { animation-delay: 0.06s; }
.ud-card:nth-child(3) { animation-delay: 0.09s; }
.ud-card:nth-child(4) { animation-delay: 0.12s; }
.ud-card:nth-child(5) { animation-delay: 0.15s; }
.ud-card:nth-child(6) { animation-delay: 0.18s; }
.ud-card:nth-child(7) { animation-delay: 0.21s; }
.ud-card:nth-child(8) { animation-delay: 0.24s; }
.ud-card:nth-child(9) { animation-delay: 0.27s; }
.ud-card:nth-child(10) { animation-delay: 0.30s; }
.ud-card:nth-child(11) { animation-delay: 0.33s; }
.ud-card:nth-child(12) { animation-delay: 0.36s; }
.ud-card:nth-child(13) { animation-delay: 0.39s; }
.ud-card:nth-child(14) { animation-delay: 0.42s; }
.ud-card:nth-child(15) { animation-delay: 0.45s; }
.ud-card:nth-child(16) { animation-delay: 0.48s; }

/* =============================================
   CARD ICON
   ============================================= */
.ud-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  font-size: 20px;
  flex-shrink: 0;
}

/* =============================================
   CARD LABEL
   ============================================= */
.ud-card-label {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  line-height: 1.3;
  color: var(--text-secondary);
}

/* =============================================
   CARD ARROW
   ============================================= */
.ud-card-arrow {
  position: absolute;
  top: 8px;
  right: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.ud-card:hover .ud-card-arrow {
  opacity: 1;
}

/* =============================================
   EMPTY STATE
   ============================================= */
.ud-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 20px;
  text-align: center;
  color: var(--text-muted);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.ud-empty svg {
  font-size: 48px;
  opacity: 0.3;
}

.ud-empty p {
  font-size: 14px;
  font-weight: 600;
  margin: 0;
  color: var(--text-primary);
}

.ud-empty span {
  font-size: 12px;
  color: var(--text-muted);
}

/* =============================================
   SECURITY NOTICE
   ============================================= */
.ud-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 20px;
  padding: 12px 16px;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 10px;
  animation: fadeInUp 0.3s ease forwards;
  animation-delay: 0.5s;
  opacity: 0;
}

.ud-notice-icon {
  font-size: 18px;
  color: #f59e0b;
  flex-shrink: 0;
  margin-top: 1px;
}

.ud-notice p {
  margin: 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--text-secondary);
}

.ud-notice p strong {
  color: var(--text-primary);
}

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =============================================
   RESPONSIVE — Tablette petite (>= 480px) : 3 col
   ============================================= */
@media (min-width: 480px) {
  .ud-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

  .ud-card {
    padding: 20px 14px;
    min-height: 110px;
  }

  .ud-card-icon {
    width: 44px;
    height: 44px;
  }
}

/* =============================================
   RESPONSIVE — Tablette (>= 640px) : header horizontal
   ============================================= */
@media (min-width: 640px) {
  .ud-header {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
  }

  .ud-header-right {
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
  }
}

/* =============================================
   RESPONSIVE — Desktop (>= 768px) : 4 col
   ============================================= */
@media (min-width: 768px) {
  .ud-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
  }

  .ud-card {
    padding: 24px 16px;
    min-height: 120px;
  }

  .ud-card-icon {
    width: 46px;
    height: 46px;
    font-size: 22px;
  }

  .ud-card-label {
    font-size: 12px;
  }
}

/* =============================================
   RESPONSIVE — Grand écran (>= 1200px) : 5 col
   ============================================= */
@media (min-width: 1200px) {
  .ud-grid {
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
  }

  .ud-card {
    padding: 28px 16px;
    min-height: 130px;
  }
}

/* =============================================
   RESPONSIVE — Très petit écran (< 360px) : liste
   ============================================= */
@media (max-width: 359px) {
  .user-dashboard {
    padding: 10px;
  }

  .ud-title {
    font-size: 18px;
  }

  .ud-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .ud-card {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 14px;
    min-height: auto;
  }

  .ud-card-label {
    text-align: left;
    font-size: 12px;
    flex: 1 1;
  }

  .ud-card-arrow {
    opacity: 1;
    position: static;
  }
}
/* src/components/admin/EntrepriseModal.css */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlide 0.2s ease;
}

.modal-entreprise {
  max-width: 560px;
}

@keyframes modalSlide {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 10;
}

.modal-header h2 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.btn-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.2s;
}

.btn-close:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Tabs */
.modal-tabs {
  display: flex;
  gap: 4px;
  padding: 12px 20px 0;
  border-bottom: 1px solid var(--border);
  background: var(--bg-secondary);
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s;
}

.tab-btn:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.tab-btn.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.tab-btn svg {
  font-size: 14px;
}

.tab-description {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 16px;
  padding: 10px 12px;
  background: var(--bg-tertiary);
  border-radius: 4px;
  line-height: 1.5;
}

.modal-form {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-error {
  padding: 10px 12px;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid var(--danger);
  border-radius: 4px;
  color: var(--danger);
  font-size: 12px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 12px;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-group label svg {
  font-size: 14px;
  color: var(--accent);
}

.form-group input,
.form-group textarea {
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 12px;
  outline: none;
  transition: border-color 0.2s;
  font-family: inherit;
}

.form-group textarea {
  resize: vertical;
  min-height: 60px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}

.input-hint {
  font-size: 10px;
  color: var(--text-muted);
  font-family: monospace;
  word-break: break-all;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-primary);
}

.checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
}

/* Footer */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  margin-top: 6px;
}

.btn-cancel,
.btn-submit {
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.btn-cancel:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn-submit {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #fff;
}

.btn-submit:hover {
  background: var(--accent-hover);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Responsive */
@media (max-width: 500px) {
  .modal {
    max-height: 100vh;
    border-radius: 0;
  }

  .modal-entreprise {
    max-width: 100%;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .modal-tabs {
    overflow-x: auto;
    padding: 12px 12px 0;
  }

  .tab-btn {
    padding: 8px 12px;
    white-space: nowrap;
  }
}

/* src/screens/admin/AdminEntreprises.css */
.admin-entreprises {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-entreprises-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-entreprises-header h1 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-entreprises-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Stats */
.admin-entreprises-stats {
  display: flex;
  gap: 12px;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 100px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
}

/* Search */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent);
}

.search-box svg {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 12px;
  width: 150px;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

/* Buttons */
.btn-primary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Grid */
.admin-entreprises-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  grid-gap: 16px;
  gap: 16px;
  padding-bottom: 16px;
}

/* Card */
.entreprise-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.2s;
}

.entreprise-card:hover {
  border-color: var(--accent);
}

.entreprise-card.inactive {
  opacity: 0.6;
}

.entreprise-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
}

.entreprise-trigramme {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
}

.status-badge {
  padding: 4px 8px;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

.status-badge.active {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}

.status-badge.inactive {
  background: rgba(102, 102, 102, 0.15);
  color: var(--text-muted);
}

.entreprise-card-body {
  padding: 16px;
  flex: 1 1;
}

.entreprise-nom {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.entreprise-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.info-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.info-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.info-value {
  font-size: 12px;
  color: var(--text-secondary);
}

.info-path {
  font-family: monospace;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.entreprise-card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
}

.card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  transition: all 0.2s;
}

.btn-action:hover {
  background: var(--bg-primary);
}

.btn-action.btn-edit:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-action.btn-delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-action.btn-toggle:hover {
  border-color: var(--warning);
  color: var(--warning);
}

.btn-action:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* No data */
.no-data {
  grid-column-start: 1; grid-column-end: -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 20px;
  color: var(--text-muted);
}

.no-data svg {
  font-size: 48px;
  opacity: 0.3;
}

.no-data p {
  font-size: 14px;
}

/* Loading / Error */
.admin-loading,
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 1 1;
  color: var(--text-muted);
  font-size: 14px;
}

.admin-error {
  color: var(--danger);
}

/* Responsive */
@media (max-width: 900px) {
  .admin-entreprises-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-entreprises-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }

  .admin-entreprises-stats {
    width: 100%;
    justify-content: space-between;
  }

  .stat-card {
    flex: 1 1;
    min-width: auto;
  }
}

@media (max-width: 600px) {
  .btn-primary span {
    display: none;
  }

  .admin-entreprises-grid {
    grid-template-columns: 1fr;
  }
}

/* src/components/Admin/ConcurrentModal.css */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
  overflow-y: auto;
}

.modal-content.concurrent-modal {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 12px;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg-primary);
  z-index: 10;
}

.modal-header h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.modal-header h2 svg {
  color: var(--accent);
}

.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.modal-close:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

.modal-error {
  margin: 12px 20px 0;
  padding: 10px 14px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid var(--danger);
  border-radius: 6px;
  color: var(--danger);
  font-size: 13px;
}

/* Form */
.concurrent-form {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-group label svg {
  font-size: 14px;
  color: var(--text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 10px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 14px;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group select {
  cursor: pointer;
}

.form-group textarea {
  resize: vertical;
  min-height: 70px;
}

/* Form row (multiple inputs on same line) */
.form-row {
  display: flex;
  gap: 12px;
}

.form-row .form-group {
  flex: 1 1;
}

.form-row .form-group.flex-2 {
  flex: 2 1;
}

/* Modal actions */
.modal-actions {
  display: flex;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  margin-top: 8px;
}

.btn-cancel,
.btn-confirm {
  flex: 1 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-cancel:hover:not(:disabled) {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.btn-confirm {
  background: var(--accent);
  color: #fff;
}

.btn-confirm:hover:not(:disabled) {
  background: var(--accent-hover);
}

.btn-cancel:disabled,
.btn-confirm:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Responsive */
@media (max-width: 600px) {
  .modal-overlay {
    padding: 10px;
  }

  .modal-content.concurrent-modal {
    max-width: 100%;
    max-height: 100%;
    border-radius: 10px;
  }

  .modal-header {
    padding: 12px 16px;
  }

  .modal-header h2 {
    font-size: 15px;
  }

  .concurrent-form {
    padding: 16px;
    gap: 14px;
  }

  .form-group input,
  .form-group select,
  .form-group textarea {
    font-size: 16px; /* Évite le zoom iOS */
    padding: 12px;
  }

  .form-row {
    flex-direction: column;
    gap: 14px;
  }

  .modal-actions {
    flex-direction: column;
  }

  .btn-cancel,
  .btn-confirm {
    padding: 14px;
  }
}

/* src/screens/admin/AdminConcurrentsScreen.css */
.admin-concurrents {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}

.admin-concurrents-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-concurrents-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-concurrents-header h1 svg {
  color: var(--accent);
}

.admin-concurrents-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Stats */
.admin-concurrents-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 100px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
  text-align: center;
}

/* Search & Filter */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent);
}

.search-box svg {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 12px;
  width: 150px;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.filter-select {
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 12px;
  cursor: pointer;
  outline: none;
}

.filter-select:focus {
  border-color: var(--accent);
}

/* Buttons */
.btn-primary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Table container */
.admin-concurrents-table-container {
  flex: 1 1;
  overflow: auto;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

/* Table */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.admin-table th,
.admin-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.admin-table th {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.admin-table tbody tr {
  transition: background 0.2s;
}

.admin-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.admin-table tbody tr:last-child td {
  border-bottom: none;
}

/* Concurrent info */
.concurrent-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.concurrent-avatar {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--accent), #6366f1);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  flex-shrink: 0;
}

.concurrent-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.concurrent-name {
  font-weight: 600;
  color: var(--text-primary);
}

.concurrent-phone {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--text-muted);
}

.concurrent-phone svg {
  font-size: 10px;
}

/* Address */
.concurrent-address {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.address-line {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-secondary);
}

.address-line svg {
  font-size: 12px;
  color: var(--text-muted);
}

.city-line {
  font-size: 10px;
  color: var(--text-muted);
  padding-left: 16px;
}

/* Type Badges */
.badge {
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  white-space: nowrap;
}

.type-grande-surface {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

.type-specialise {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

.type-grossiste {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
}

.type-en-ligne {
  background: rgba(139, 92, 246, 0.15);
  color: #8b5cf6;
}

.type-autre {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
}

/* Status */
.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.status.active {
  color: var(--success);
}

.status.active::before {
  background: var(--success);
}

.status.inactive {
  color: var(--text-muted);
}

.status.inactive::before {
  background: var(--text-muted);
}

/* Date cell */
.date-cell {
  color: var(--text-secondary);
  font-size: 11px;
}

/* Table actions */
.table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-action:hover {
  background: var(--bg-primary);
}

.btn-action.btn-edit:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-action.btn-delete:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-action.btn-toggle:hover {
  border-color: var(--warning);
  color: var(--warning);
}

.btn-action:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* No data */
.no-data {
  text-align: center;
  color: var(--text-muted);
  padding: 40px !important;
}

/* Loading / Error */
.admin-loading,
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 1 1;
  color: var(--text-muted);
  font-size: 14px;
}

.admin-error {
  color: var(--danger);
}

/* Responsive */
@media (max-width: 1024px) {
  .admin-concurrents-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .admin-concurrents-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-concurrents-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }

  .admin-concurrents-stats {
    width: 100%;
  }

  .stat-card {
    flex: 1 1;
    min-width: auto;
    padding: 10px 12px;
  }

  .stat-value {
    font-size: 20px;
  }

  .stat-label {
    font-size: 9px;
  }
}

@media (max-width: 768px) {
  .admin-table th:nth-child(2),
  .admin-table td:nth-child(2) {
    display: none;
  }

  .admin-table th:nth-child(5),
  .admin-table td:nth-child(5) {
    display: none;
  }
}

@media (max-width: 600px) {
  .btn-primary span {
    display: none;
  }

  .admin-concurrents-actions {
    flex-wrap: wrap;
  }

  .filter-select {
    flex: 1 1;
    min-width: 120px;
  }

  .admin-table th:nth-child(4),
  .admin-table td:nth-child(4) {
    display: none;
  }
}

/* ==========================================================================
   Admin Client Detail Screen
   Accent color: orange/cyan (#3b82f6)
   ========================================================================== */

.client-detail-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
  display: flex;
  flex-direction: column;
}

/* Loading / Error */
.client-detail-page .detail-loading,
.client-detail-page .detail-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
  color: var(--admin-text-muted);
}

.client-detail-page .detail-error {
  color: var(--admin-danger);
}

.client-detail-page .detail-error h2 {
  margin: 0;
  color: var(--admin-text);
}

.client-detail-page .error-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.client-detail-page .btn-retry,
.client-detail-page .btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.client-detail-page .btn-retry {
  background: var(--admin-primary);
  border: none;
  color: white;
}

.client-detail-page .btn-retry:hover {
  background: var(--admin-primary-dark);
}

.client-detail-page .btn-back {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-secondary);
}

.client-detail-page .btn-back:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

/* ========== TOP BAR ========== */
.client-detail-page .detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.client-detail-page .btn-back-list {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--admin-transition);
}

.client-detail-page .btn-back-list:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
  border-color: var(--admin-border-light);
}

.client-detail-page .topbar-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.client-detail-page .nav-current {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.9rem;
  color: #3b82f6;
}

.client-detail-page .nav-current svg {
  font-size: 1.1rem;
}

.client-detail-page .topbar-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.client-detail-page .query-time {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

/* ========== EXPORT BUTTONS ========== */
.btn-export-excel,
.btn-export-dat {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
  white-space: nowrap;
}

.btn-export-excel {
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border: 1px solid #3b82f6;
  color: #fff;
}

.btn-export-excel:hover:not(:disabled) {
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
  box-shadow: 0 4px 12px rgba(20, 184, 166, 0.3);
  transform: translateY(-1px);
}

.btn-export-dat {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: 1px solid #8b5cf6;
  color: #fff;
}

.btn-export-dat:hover:not(:disabled) {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
  transform: translateY(-1px);
}

.btn-export-excel:disabled,
.btn-export-dat:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-export-excel svg,
.btn-export-dat svg {
  font-size: 1rem;
}

/* ========== DAT PANEL ========== */
.dat-panel {
  background: var(--admin-bg-secondary);
  border-bottom: 2px solid #8b5cf6;
  padding: 0;
  animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
  from { max-height: 0; opacity: 0; }
  to { max-height: 200px; opacity: 1; }
}

.dat-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 1.5rem;
  background: rgba(139, 92, 246, 0.1);
  border-bottom: 1px solid var(--admin-border);
  font-size: 0.85rem;
  font-weight: 700;
  color: #a78bfa;
}

.btn-close-dat {
  background: transparent;
  border: none;
  color: var(--admin-text-muted);
  cursor: pointer;
  font-size: 1rem;
  transition: var(--admin-transition);
}

.btn-close-dat:hover {
  color: var(--admin-danger);
}

.dat-panel-body {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.5rem;
  flex-wrap: wrap;
}

.dat-filename-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1 1;
  min-width: 280px;
}

.dat-filename-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  white-space: nowrap;
}

.dat-filename-group input {
  flex: 1 1;
  padding: 0.5rem 0.75rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.85rem;
  outline: none;
  transition: var(--admin-transition);
}

.dat-filename-group input:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.btn-dat-reset-name {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-dat-reset-name:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

.dat-panel-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-dat-download,
.btn-dat-server {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
  white-space: nowrap;
}

.btn-dat-download {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: 1px solid #8b5cf6;
  color: #fff;
}

.btn-dat-download:hover:not(:disabled) {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
  transform: translateY(-1px);
}

.btn-dat-server {
  background: linear-gradient(135deg, #d97706, #f59e0b);
  border: 1px solid #f59e0b;
  color: #000;
}

.btn-dat-server:hover:not(:disabled) {
  background: linear-gradient(135deg, #b45309, #d97706);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transform: translateY(-1px);
}

.btn-dat-download:disabled,
.btn-dat-server:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-dat-download svg,
.btn-dat-server svg {
  font-size: 1rem;
}

/* ========== DAT MESSAGE BANNER ========== */
.dat-message {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.dat-message-success {
  background: rgba(16, 185, 129, 0.15);
  border-bottom: 2px solid var(--admin-success);
  color: var(--admin-success);
}

.dat-message-error {
  background: rgba(239, 68, 68, 0.15);
  border-bottom: 2px solid var(--admin-danger);
  color: var(--admin-danger);
}

.dat-message .dat-path {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  opacity: 0.8;
}

.dat-message button {
  margin-left: auto;
  background: transparent;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 1rem;
  opacity: 0.7;
  transition: var(--admin-transition);
}

.dat-message button:hover {
  opacity: 1;
}

/* ========== REFRESH BUTTON ========== */
.client-detail-page .btn-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  transition: var(--admin-transition);
}

.client-detail-page .btn-refresh:hover {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #000;
}

/* ========== CONTENT ========== */
.client-detail-page .detail-content {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

/* ========== HEADER CARD ========== */
.client-detail-page .detail-header-card {
  background: rgb(48, 47, 48);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.5rem;
  border-top: 3px solid #3b82f6;
}

.client-detail-page .header-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.client-detail-page .header-card-title {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.numfact-display {
  display: flex;
  flex-direction: column;
}

.numfact-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.numfact-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 2rem;
  font-weight: 800;
  color: #3b82f6;
  line-height: 1;
}

/* Info Grid */
.client-detail-page .header-info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.client-detail-page .info-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 1rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  border: 1px solid var(--admin-border);
}

.client-detail-page .info-card-icon {
  width: 40px;
  height: 40px;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: #3b82f6;
  flex-shrink: 0;
}

.client-detail-page .info-card-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.client-detail-page .info-card-content label {
  font-size: 0.65rem;
  color: #0d6b61;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 800;
}

.client-detail-page .info-card-content span {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--admin-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Observations */
.client-detail-page .header-observ {
  margin-top: 1.25rem;
  padding: 1rem;
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid #3b82f6;
  border-radius: var(--admin-radius-sm);
}

.client-detail-page .observ-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #3b82f6;
  text-transform: uppercase;
}

.client-detail-page .header-observ p {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--admin-text);
  line-height: 1.5;
}

/* ========== MONTANTS CARDS ========== */
.client-detail-page .montants-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.875rem;
  gap: 0.875rem;
}

.client-detail-page .montant-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 1rem;
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  text-align: center;
}

.client-detail-page .montant-card.main {
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.15), var(--admin-bg-secondary));
  border-color: #3b82f6;
}

.client-detail-page .montant-card.calculated {
  background: linear-gradient(135deg, var(--admin-info-light), var(--admin-bg-secondary));
  border-color: var(--admin-info);
}

.client-detail-page .montant-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.client-detail-page .montant-card .montant-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
}

.client-detail-page .montant-card.main .montant-value {
  color: #3b82f6;
  font-size: 1.5rem;
}

.client-detail-page .montant-card.calculated .montant-value {
  color: var(--admin-info);
}

/* ========== MAILING CARD ========== */
.mailing-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.mailing-card h3 {
  margin: 0 0 0.875rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.client-detail-page .mailing-lines {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.client-detail-page .mailing-line {
  margin: 0;
  font-size: 0.85rem;
  color: var(--admin-text-secondary);
  padding: 0.375rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-xs);
  line-height: 1.4;
}

/* ========== DETAIL LINES SECTION ========== */
.client-detail-page .detail-lines-section {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  overflow: hidden;
}

.client-detail-page .lines-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.client-detail-page .lines-header h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0;
  color: var(--admin-text);
}

.client-detail-page .lines-header h2 svg {
  color: #3b82f6;
  font-size: 1.25rem;
}

.client-detail-page .lines-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  background: var(--admin-bg);
  padding: 0.2rem 0.625rem;
  border-radius: 50px;
}

.client-detail-page .lines-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.client-detail-page .lines-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.client-detail-page .lines-search:focus-within {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.2);
}

.client-detail-page .lines-search svg {
  color: var(--admin-text-muted);
  font-size: 1rem;
  flex-shrink: 0;
}

.client-detail-page .lines-search input {
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.85rem;
  min-width: 200px;
  outline: none;
}

.client-detail-page .lines-search input::placeholder {
  color: var(--admin-text-muted);
}

.client-detail-page .btn-clear-search {
  background: transparent;
  border: none;
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0;
  display: flex;
  font-size: 0.875rem;
  transition: var(--admin-transition);
}

.client-detail-page .btn-clear-search:hover {
  color: var(--admin-danger);
}

.lines-filter-type {
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.85rem;
  cursor: pointer;
}

.lines-filter-type:focus {
  outline: none;
  border-color: #3b82f6;
}

/* Lines Summary */
.client-detail-page .lines-summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}

.client-detail-page .summary-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem 1rem;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-xs);
  min-width: 100px;
}

.client-detail-page .summary-item label {
  font-size: 0.6rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.client-detail-page .summary-item span {
  font-size: 0.95rem;
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.client-detail-page .summary-item span.highlight {
  color: #3b82f6;
}

/* Lines Table */
.client-detail-page .lines-table-container {
  overflow-x: auto;
}

.client-detail-page .lines-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.825rem;
}

.client-detail-page .lines-table thead {
  position: sticky;
  top: 0;
  z-index: 5;
}

.client-detail-page .lines-table th {
  padding: 0.75rem 0.875rem;
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  font-weight: 600;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
  border-bottom: 2px solid #3b82f6;
  white-space: nowrap;
}

.client-detail-page .lines-table th.text-right {
  text-align: right;
}

.client-detail-page .lines-table td {
  padding: 0.625rem 0.875rem;
  border-bottom: 1px solid var(--admin-border);
  vertical-align: middle;
}

.client-detail-page .lines-table tbody tr {
  transition: var(--admin-transition);
}

.client-detail-page .lines-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

.client-detail-page .lines-table tbody tr.row-comment {
  background: rgba(100, 100, 120, 0.08);
}

.client-detail-page .lines-table tbody tr.row-comment:hover {
  background: rgba(100, 100, 120, 0.15);
}

/* Type badge */
.type-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 0.75rem;
}

.type-badge.article {
  background: #3b82f6;
  color: #000;
}

.type-badge.comment {
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.nart-comment {
  color: var(--admin-text-muted);
  font-size: 0.8rem;
}

.comment-text {
  font-style: italic;
  color: var(--admin-text-muted) !important;
  max-width: none !important;
}

/* Cell styles */
.client-detail-page .nl-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

.client-detail-page .nart-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: var(--admin-primary-light);
  font-size: 0.8rem;
  text-decoration: none;
  padding: 0.2rem 0.375rem;
  margin: -0.2rem -0.375rem;
  border-radius: var(--admin-radius-xs);
  transition: var(--admin-transition);
}

.client-detail-page .nart-link:hover {
  background: var(--admin-primary);
  color: white;
}

.client-detail-page .nart-link .link-icon {
  font-size: 0.7rem;
  opacity: 0;
  transition: var(--admin-transition);
}

.client-detail-page .nart-link:hover .link-icon {
  opacity: 1;
}

.client-detail-page .design-text {
  color: var(--admin-text);
  font-size: 0.825rem;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

.client-detail-page .qte-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.remise-value {
  font-weight: 600;
  color: var(--admin-warning);
  font-size: 0.8rem;
}

.client-detail-page .montant-cell {
  font-weight: 700;
  color: var(--admin-text);
}

.numserie-text {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

.client-detail-page .btn-view-article {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-xs);
  color: var(--admin-text-secondary);
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.client-detail-page .btn-view-article:hover {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #000;
}

/* État badges */
.client-detail-page .typfact-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.client-detail-page .typfact-badge.large {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
}

.client-detail-page .typ-muted {
  background: rgba(100, 100, 120, 0.2);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.client-detail-page .typ-info {
  background: var(--admin-info-light);
  color: var(--admin-info);
  border: 1px solid var(--admin-info);
}

.client-detail-page .typ-primary {
  background: var(--admin-success-light);
  color: var(--admin-success);
  border: 1px solid var(--admin-success);
}

/* Table empty */
.client-detail-page .table-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  color: var(--admin-text-muted);
  text-align: center;
}

.client-detail-page .table-empty svg {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  opacity: 0.5;
}

.client-detail-page .table-empty h3 {
  margin: 0 0 0.5rem;
  color: var(--admin-text);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .client-detail-page .header-info-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .client-detail-page .lines-table .col-numserie,
  .client-detail-page .lines-table .col-dtva,
  .client-detail-page .lines-table .col-pourc {
    display: none;
  }
}

@media (max-width: 900px) {
  .client-detail-page .detail-content {
    padding: 1rem;
  }
  .client-detail-page .detail-topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  .client-detail-page .topbar-nav {
    justify-content: center;
  }
  .client-detail-page .topbar-meta {
    justify-content: center;
  }
  .client-detail-page .header-info-grid {
    grid-template-columns: 1fr;
  }
  .client-detail-page .montants-cards {
    grid-template-columns: 1fr;
  }
  .client-detail-page .lines-header {
    flex-direction: column;
    align-items: stretch;
  }
  .client-detail-page .lines-controls {
    flex-direction: column;
  }
  .client-detail-page .lines-search input {
    min-width: auto;
    width: 100%;
  }
  .client-detail-page .lines-table .col-pvttc,
  .client-detail-page .lines-table .col-pvte {
    display: none;
  }
  .btn-export-excel span,
  .btn-export-dat span {
    display: none;
  }
}

@media (max-width: 600px) {
  .numfact-value {
    font-size: 1.5rem;
  }
  .client-detail-page .lines-table .col-nl,
  .client-detail-page .lines-table .col-type,
  .client-detail-page .lines-table .col-actions {
    display: none;
  }
  .client-detail-page .lines-summary {
    gap: 0.375rem;
  }
  .client-detail-page .summary-item {
    min-width: 80px;
    padding: 0.375rem 0.625rem;
  }
}

/* ========== TYPFACT BADGES ========== */
.client-detail-page .typfact-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
}

.client-detail-page .typfact-badge.large {
  padding: 0.375rem 1rem;
  font-size: 0.85rem;
}

.client-detail-page .typ-primary {
  background: rgba(249, 115, 22, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(249, 115, 22, 0.3);
}

.client-detail-page .typ-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.client-detail-page .typ-warning {
  background: rgba(234, 179, 8, 0.15);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.client-detail-page .typ-info {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.client-detail-page .typ-muted {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
  border: 1px solid rgba(107, 114, 128, 0.3);
}

/* ========== CLIENT-SPECIFIC STYLES ========== */
.client-detail-page .tiers-badge-large {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
  font-family: "Monaco", "Consolas", monospace;
}

.client-detail-page .ridet-raw {
  display: block;
  font-size: 0.65rem;
  color: var(--admin-text-muted);
  font-style: italic;
  margin-top: 0.125rem;
}

.client-detail-page .section-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.client-detail-page .section-card h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: #3b82f6;
}

.client-detail-page .address-block p {
  font-size: 0.85rem;
  margin: 0.25rem 0;
  line-height: 1.5;
}

.client-detail-page .no-data {
  color: var(--admin-text-muted);
  font-style: italic;
  font-size: 0.8rem;
}

.client-detail-page .contact-grid,
.client-detail-page .suivi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.client-detail-page .contact-item,
.client-detail-page .suivi-item {
  padding: 0.625rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
}

.client-detail-page .contact-item label,
.client-detail-page .suivi-item label {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--admin-text-muted);
  margin-bottom: 0.25rem;
}

.client-detail-page .contact-item span,
.client-detail-page .suivi-item span {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
}

.client-detail-page .suivi-item small {
  display: block;
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  margin-top: 0.25rem;
}

.client-detail-page .suivi-item.blocage {
  border-color: rgba(239, 68, 68, 0.3);
  background: rgba(239, 68, 68, 0.05);
}

.client-detail-page .contacts-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.client-detail-page .contact-line {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  font-size: 0.85rem;
}

.client-detail-page .contact-num {
  font-weight: 800;
  color: #3b82f6;
  font-size: 0.75rem;
}

.client-detail-page .memo-lines p {
  font-size: 0.85rem;
  margin: 0.25rem 0;
  line-height: 1.5;
}

.client-detail-page .montant-value.debit {
  color: #ef4444;
}

.client-detail-page .montant-value.credit {
  color: #22c55e;
}

.client-detail-page .montant-card.solde-debiteur .montant-value {
  color: #ef4444;
}

.client-detail-page .montant-card.solde-crediteur .montant-value {
  color: #22c55e;
}

/* ========== CROSS-ENTREPRISE SECTION ========== */
.cross-entreprise-section {
  border: 2px solid rgba(59, 130, 246, 0.2) !important;
  background: rgba(59, 130, 246, 0.02) !important;
}

.cross-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.5rem;
  text-align: center;
  color: var(--admin-text-muted);
}

.cross-empty svg {
  font-size: 2rem;
  opacity: 0.4;
}

.cross-empty p {
  font-size: 0.85rem;
  margin: 0;
}

.cross-loading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  color: var(--admin-text-muted);
  font-size: 0.85rem;
}

.loading-spinner.small {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.cross-header-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.cross-ridet-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #3b82f6;
  font-family: "Monaco", "Consolas", monospace;
}

.cross-count {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
  font-weight: 600;
}

.cross-cards {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.cross-card {
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  overflow: hidden;
}

.cross-card-header {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.75rem 1rem;
  background: rgba(59, 130, 246, 0.08);
  border-bottom: 1px solid var(--admin-border);
}

.cross-card-header svg {
  font-size: 1.25rem;
  color: #3b82f6;
}

.cross-entreprise-name {
  font-size: 0.85rem;
  font-weight: 700;
}

.cross-card-body {
  padding: 0.5rem;
}

.cross-client-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.625rem 0.75rem;
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
  flex-wrap: wrap;
}

.cross-client-row:hover {
  background: var(--admin-bg-hover);
}

.cross-client-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1 1;
  min-width: 200px;
}

.cross-tiers {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.8rem;
  color: #3b82f6;
  background: rgba(59, 130, 246, 0.1);
  padding: 0.125rem 0.5rem;
  border-radius: var(--admin-radius-sm);
}

.cross-nom {
  font-size: 0.85rem;
  font-weight: 600;
}

.cross-client-meta {
  display: flex;
  gap: 1rem;
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

.cross-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.625rem;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border-radius: var(--admin-radius-sm);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
  transition: var(--admin-transition);
  white-space: nowrap;
}

.cross-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

@media (max-width: 768px) {
  .cross-client-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .cross-client-meta {
    flex-direction: column;
    gap: 0.25rem;
  }
}

/* ========== MATCH TYPE BADGES ========== */
.cross-nom-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #a855f7;
  font-family: "Monaco", "Consolas", monospace;
}

.cross-match-type {
  display: inline-flex;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.cross-match-type.match-ridet {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.cross-match-type.match-nom {
  background: rgba(168, 85, 247, 0.1);
  color: #a855f7;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.cross-match-badge {
  margin-left: auto;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-size: 0.6rem;
  font-weight: 800;
  text-transform: uppercase;
}

.cross-match-badge.match-ridet {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

.cross-match-badge.match-nom {
  background: rgba(168, 85, 247, 0.15);
  color: #a855f7;
}

.cross-ridet-small {
  font-size: 0.65rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
  background: var(--admin-bg-tertiary);
  padding: 0.1rem 0.375rem;
  border-radius: var(--admin-radius-sm);
}

/* ========== TIERS COMPTA SECTION (tiers.dbf) ========== */
.tiers-compta-section {
  border: 2px solid rgba(20, 184, 166, 0.2) !important;
  background: rgba(20, 184, 166, 0.02) !important;
}

.tiers-compta-desc {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
  margin: 0 0 1rem;
}

.tiers-compta-desc strong {
  color: #14b8a6;
}

.tiers-compta-cards {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.tiers-compta-card {
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  overflow: hidden;
}

.tiers-compta-card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(20, 184, 166, 0.08);
  border-bottom: 1px solid var(--admin-border);
}

.tiers-compta-compte-large {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 800;
  font-size: 0.95rem;
  color: #14b8a6;
  background: rgba(20, 184, 166, 0.15);
  padding: 0.25rem 0.625rem;
  border-radius: var(--admin-radius-sm);
  border: 1px solid rgba(20, 184, 166, 0.3);
}

.tiers-compta-nom-large {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--admin-text);
}

.tiers-compta-card-body {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.5rem;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
}

.tiers-compta-montant {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.tiers-compta-label {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.tiers-compta-val {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 1rem;
  font-weight: 800;
}

.tiers-compta-val.debit { color: #ef4444; }
.tiers-compta-val.credit { color: #22c55e; }

@media (max-width: 600px) {
  .tiers-compta-card-body { grid-template-columns: 1fr; }
}

.admin-article-infos-page {
  --aais-bg: #0a0a0f;
  --aais-bg-secondary: #12121a;
  --aais-bg-tertiary: #1a1a25;
  --aais-bg-hover: #22222e;
  --aais-border: #2a2a3a;
  --aais-text: #f0f0f5;
  --aais-text-secondary: #a0a0b0;
  --aais-text-muted: #606070;
  --aais-primary: #6366f1;
  --aais-primary-light: #818cf8;
  --aais-primary-dark: #4f46e5;
  --aais-primary-glow: rgba(99, 102, 241, 0.3);
  --aais-success: #10b981;
  --aais-success-light: rgba(16, 185, 129, 0.15);
  --aais-warning: #f59e0b;
  --aais-warning-light: rgba(245, 158, 11, 0.15);
  --aais-danger: #ef4444;
  --aais-danger-light: rgba(239, 68, 68, 0.15);
  --aais-info: #3b82f6;
  --aais-info-light: rgba(59, 130, 246, 0.15);
  --aais-promo: #ec4899;
  --aais-promo-light: rgba(236, 72, 153, 0.15);
  --aais-deprec: #f97316;
  --aais-deprec-light: rgba(249, 115, 22, 0.15);
  --aais-web: #06b6d4;
  --aais-web-light: rgba(6, 182, 212, 0.15);
  --aais-photo: #8b5cf6;
  --aais-photo-light: rgba(139, 92, 246, 0.15);
  --aais-renvoi: #eab308;
  --aais-renvoi-light: rgba(234, 179, 8, 0.15);
  --aais-encde: #3b82f6;
  --aais-encde-light: rgba(59, 130, 246, 0.15);
  --aais-radius: 12px;
  --aais-radius-sm: 8px;
  --aais-radius-xs: 4px;
  --aais-transition: all 0.2s ease;

  min-height: 100vh;
  background: var(--aais-bg);
  color: var(--aais-text);
  display: flex;
  flex-direction: column;
}


.admin-article-infos-page .loading-state,
.admin-article-infos-page .error-state,
.admin-article-infos-page .empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1 1;
  min-height: 60vh;
  gap: 1rem;
  text-align: center;
  padding: 2rem;
}

.admin-article-infos-page .loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--aais-border);
  border-top-color: var(--aais-primary);
  border-radius: 50%;
  animation: aais-spin 0.8s linear infinite;
}

.admin-article-infos-page .loading-spinner.small {
  width: 24px;
  height: 24px;
  border-width: 2px;
}

@keyframes aais-spin {
  to {
    transform: rotate(360deg);
  }
}
.admin-article-infos-page .spinning {
  animation: aais-spin 1s linear infinite;
}

.admin-article-infos-page .empty-icon,
.admin-article-infos-page .error-icon {
  font-size: 4rem;
  color: var(--aais-primary);
  opacity: 0.6;
}

.admin-article-infos-page .error-icon {
  color: var(--aais-danger);
}
.admin-article-infos-page .error-state h2,
.admin-article-infos-page .empty-state h2 {
  font-size: 1.5rem;
  margin: 0;
}
.admin-article-infos-page .error-state p,
.admin-article-infos-page .empty-state p {
  color: var(--aais-text-muted);
}

.admin-article-infos-page .error-state button {
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background: var(--aais-primary);
  border: none;
  border-radius: var(--aais-radius-sm);
  color: white;
  font-weight: 600;
  cursor: pointer;
}

/* ========== HEADER ========== */
.admin-article-infos-page .article-infos-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: var(--aais-bg-secondary);
  border-bottom: 1px solid var(--aais-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-article-infos-page .header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-article-infos-page .btn-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--aais-transition);
}

.admin-article-infos-page .btn-back:hover {
  background: var(--aais-primary);
  border-color: var(--aais-primary);
  color: white;
}

.admin-article-infos-page .header-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.admin-article-infos-page .header-title h1 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
}

.admin-article-infos-page .title-icon {
  color: var(--aais-primary);
}

.admin-article-infos-page .article-nart-badge {
  padding: 0.375rem 0.75rem;
  background: linear-gradient(
    135deg,
    var(--aais-primary),
    var(--aais-primary-dark)
  );
  border-radius: var(--aais-radius-sm);
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.9rem;
  font-weight: 700;
  color: white;
}

.admin-article-infos-page .header-center {
  flex: 1 1;
  display: flex;
  justify-content: center;
}

.admin-article-infos-page .entreprise-selector {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  padding: 0.625rem 1rem;
  min-width: 300px;
}

.admin-article-infos-page .entreprise-selector:focus-within {
  border-color: var(--aais-primary);
  box-shadow: 0 0 0 3px var(--aais-primary-glow);
}

.admin-article-infos-page .selector-icon {
  font-size: 1.25rem;
  color: var(--aais-primary);
  margin-right: 0.75rem;
}

.admin-article-infos-page .entreprise-selector select {
  appearance: none;
  background: transparent;
  border: none;
  color: var(--aais-text);
  font-size: 0.9rem;
  font-weight: 500;
  padding-right: 2rem;
  flex: 1 1;
  cursor: pointer;
}

.admin-article-infos-page .entreprise-selector select:focus {
  outline: none;
}

.admin-article-infos-page .selector-arrow {
  position: absolute;
  right: 1rem;
  color: var(--aais-text-muted);
  pointer-events: none;
}

.admin-article-infos-page .header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-article-infos-page .btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 1.125rem;
  cursor: pointer;
  transition: var(--aais-transition);
}

.admin-article-infos-page .btn-action:hover {
  background: var(--aais-primary);
  border-color: var(--aais-primary);
  color: white;
}

.admin-article-infos-page .btn-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ========== CONTENT ========== */
.admin-article-infos-page .article-infos-content {
  flex: 1 1;
  padding: 1.5rem;
  overflow-y: auto;
}

/* Alert Banners */
.admin-article-infos-page .alert-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-radius: var(--aais-radius);
  margin-bottom: 1rem;
  animation: aais-slideIn 0.3s ease;
}

@keyframes aais-slideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-article-infos-page .alert-banner.promo {
  background: linear-gradient(135deg, var(--aais-promo-light), transparent);
  border: 1px solid var(--aais-promo);
}

.admin-article-infos-page .alert-banner.renvoi {
  background: linear-gradient(135deg, var(--aais-renvoi-light), transparent);
  border: 1px solid var(--aais-renvoi);
}

.admin-article-infos-page .alert-banner.deprec {
  background: linear-gradient(135deg, var(--aais-deprec-light), transparent);
  border: 1px solid var(--aais-deprec);
}

.admin-article-infos-page .banner-icon {
  font-size: 1.5rem;
}
.admin-article-infos-page .alert-banner.promo .banner-icon {
  color: var(--aais-promo);
}
.admin-article-infos-page .alert-banner.renvoi .banner-icon {
  color: var(--aais-renvoi);
}
.admin-article-infos-page .alert-banner.deprec .banner-icon {
  color: var(--aais-deprec);
}

.admin-article-infos-page .banner-content {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .banner-content strong {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-article-infos-page .banner-content span {
  font-size: 0.85rem;
  color: var(--aais-text-secondary);
}

.admin-article-infos-page .promo-price {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--aais-promo);
}

.admin-article-infos-page .renvoi-chain {
  padding: 0.25rem 0.75rem;
  background: var(--aais-renvoi);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  color: black;
}

/* ========== RENVOI DETAILS SECTION ========== */
.admin-article-infos-page .renvoi-details-section {
  background: linear-gradient(
    135deg,
    var(--aais-renvoi-light) 0%,
    rgba(234, 179, 8, 0.05) 100%
  );
  padding: 1.25rem;
  border-radius: var(--aais-radius);
  border: 1px solid var(--aais-renvoi);
  margin-bottom: 1rem;
}

.admin-article-infos-page .renvoi-details {
  display: flex;
  align-items: stretch;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.admin-article-infos-page .renvoi-from,
.admin-article-infos-page .renvoi-to {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 1rem;
  border-radius: var(--aais-radius-sm);
  background: var(--aais-bg-secondary);
}

.admin-article-infos-page .renvoi-from {
  border: 2px solid var(--aais-danger);
  position: relative;
}

.admin-article-infos-page .renvoi-from::before {
  content: "❌";
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 1.25rem;
}

.admin-article-infos-page .renvoi-to {
  border: 2px solid var(--aais-success);
  position: relative;
}

.admin-article-infos-page .renvoi-to::before {
  content: "✅";
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 1.25rem;
}

.admin-article-infos-page .renvoi-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .renvoi-nart {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--aais-text);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .renvoi-design {
  font-size: 0.9rem;
  color: var(--aais-text-secondary);
  line-height: 1.3;
}

.admin-article-infos-page .renvoi-gencod {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8rem;
  color: var(--aais-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .renvoi-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--aais-renvoi);
  font-size: 2rem;
  flex-shrink: 0;
  padding: 0 0.5rem;
}

.admin-article-infos-page .renvoi-chain-warning {
  padding: 0.625rem 1rem;
  background: var(--aais-bg-secondary);
  border: 2px solid var(--aais-renvoi);
  border-radius: var(--aais-radius-sm);
  font-size: 0.9rem;
  color: var(--aais-renvoi);
  font-weight: 600;
  text-align: center;
}

/* ========== MAIN GRID ========== */
.admin-article-infos-page .article-main-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  grid-gap: 1.5rem;
  gap: 1.5rem;
}

.admin-article-infos-page .article-left-column {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Photo Card */
.admin-article-infos-page .photo-card {
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow: hidden;
}

.admin-article-infos-page .photo-wrapper {
  position: relative;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--aais-bg-tertiary), var(--aais-bg));
}

.admin-article-infos-page .photo-wrapper img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.admin-article-infos-page .photo-wrapper.loaded img {
  opacity: 1;
}

.admin-article-infos-page .photo-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-article-infos-page .photo-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.5rem 1rem;
  border-radius: var(--aais-radius-sm);
  font-weight: 800;
  font-size: 1.1rem;
}

.admin-article-infos-page .photo-badge.promo {
  background: var(--aais-promo);
  color: white;
  animation: aais-pulse 2s ease-in-out infinite;
}

@keyframes aais-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.admin-article-infos-page .no-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 4rem 2rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .no-photo svg {
  font-size: 3rem;
  opacity: 0.5;
}

/* Quick Badges */
.admin-article-infos-page .quick-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.admin-article-infos-page .quick-badge {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.75rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-secondary);
}

.admin-article-infos-page .quick-badge.web {
  background: var(--aais-web-light);
  border-color: var(--aais-web);
  color: var(--aais-web);
}
.admin-article-infos-page .quick-badge.photo {
  background: var(--aais-photo-light);
  border-color: var(--aais-photo);
  color: var(--aais-photo);
}
.admin-article-infos-page .quick-badge.sav {
  background: var(--aais-success-light);
  border-color: var(--aais-success);
  color: var(--aais-success);
}
.admin-article-infos-page .quick-badge.compose {
  background: var(--aais-info-light);
  border-color: var(--aais-info);
  color: var(--aais-info);
}
.admin-article-infos-page .quick-badge.renvoi {
  background: var(--aais-renvoi-light);
  border-color: var(--aais-renvoi);
  color: var(--aais-renvoi);
}

/* Quick Stats */
.admin-article-infos-page .quick-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.admin-article-infos-page .quick-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .quick-stat.full-width {
  grid-column: span 2;
}

.admin-article-infos-page .quick-stat .stat-label {
  font-size: 0.7rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.admin-article-infos-page .quick-stat .stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--aais-text);
}

.admin-article-infos-page .quick-stat .stat-value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .quick-stat .stat-value.zero {
  color: var(--aais-text-muted);
}
.admin-article-infos-page .quick-stat .stat-value.warning {
  color: var(--aais-warning);
}
.admin-article-infos-page .quick-stat .stat-value.encde {
  color: var(--aais-encde);
}

/* Linked Article Card */
.admin-article-infos-page .linked-article-card {
  padding: 1rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .linked-article-card.renvoi-card {
  border-color: var(--aais-renvoi);
  background: linear-gradient(
    135deg,
    var(--aais-renvoi-light),
    var(--aais-bg-secondary)
  );
}

.admin-article-infos-page .linked-article-card h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  margin: 0 0 0.75rem;
}

.admin-article-infos-page .linked-article-card.renvoi-card h4 {
  color: var(--aais-renvoi);
}

.admin-article-infos-page .linked-article-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-primary);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-primary-light);
  text-decoration: none;
  transition: var(--aais-transition);
}

.admin-article-infos-page
  .linked-article-card.renvoi-card
  .linked-article-link {
  border-color: var(--aais-renvoi);
  color: var(--aais-renvoi);
}

.admin-article-infos-page .linked-article-link:hover {
  background: var(--aais-primary);
  color: white;
}

.admin-article-infos-page
  .linked-article-card.renvoi-card
  .linked-article-link:hover {
  background: var(--aais-renvoi);
  color: black;
}

.admin-article-infos-page .linked-nart {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
}

.admin-article-infos-page .linked-article-hint {
  margin: 0.5rem 0 0;
  font-size: 0.75rem;
  color: var(--aais-text-muted);
}

/* ========== RIGHT COLUMN ========== */
.admin-article-infos-page .article-right-column {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

/* Tabs Navigation */
.admin-article-infos-page .tabs-nav {
  display: flex;
  gap: 0.5rem;
  padding: 0.5rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow-x: auto;
}

.admin-article-infos-page .tab-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--aais-transition);
  white-space: nowrap;
}

.admin-article-infos-page .tab-btn:hover {
  background: var(--aais-bg-tertiary);
  color: var(--aais-text);
}

.admin-article-infos-page .tab-btn.active {
  background: linear-gradient(
    135deg,
    var(--aais-primary),
    var(--aais-primary-dark)
  );
  color: white;
}

.admin-article-infos-page .tab-btn svg {
  font-size: 1rem;
}

.admin-article-infos-page .tab-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.125rem 0.5rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
}

.admin-article-infos-page .tab-btn.active .tab-badge {
  background: rgba(255, 255, 255, 0.3);
}

/* Tab Content */
.admin-article-infos-page .tab-content {
  flex: 1 1;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow: hidden;
}

.admin-article-infos-page .tab-panel {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  animation: aais-fadeIn 0.3s ease;
}

.admin-article-infos-page .tab-panel.filiales-tab {
  padding: 0;
}

@keyframes aais-fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Info Sections */
.admin-article-infos-page .info-section {
  padding: 1.25rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .info-section h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--aais-text);
  margin: 0 0 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .info-section h3 svg {
  color: var(--aais-primary);
}

/* Designation Section */
.admin-article-infos-page .designation-section {
  background: linear-gradient(
    135deg,
    var(--aais-bg-tertiary),
    var(--aais-bg-secondary)
  );
  border: 2px solid var(--aais-primary);
}

.admin-article-infos-page .article-design-main {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--aais-text);
  margin: 0 0 0.5rem;
  line-height: 1.3;
}

.admin-article-infos-page .article-design-sub {
  font-size: 1.1rem;
  color: var(--aais-text-secondary);
  margin: 0 0 0.5rem;
}

.admin-article-infos-page .article-design-frn {
  font-size: 0.9rem;
  color: var(--aais-text-muted);
  margin: 0;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--aais-border);
}

/* Info Grid */
.admin-article-infos-page .info-grid {
  display: grid;
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .info-grid.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}
.admin-article-infos-page .info-grid.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}
.admin-article-infos-page .info-grid.cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.admin-article-infos-page .info-item {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.admin-article-infos-page .info-item label {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .info-item .value {
  font-size: 0.95rem;
  color: var(--aais-text);
  font-weight: 500;
}

.admin-article-infos-page .info-item .value.highlight {
  color: var(--aais-primary-light);
  font-weight: 700;
}
.admin-article-infos-page .info-item .value.mono {
  font-family: "Monaco", "Consolas", monospace;
}
.admin-article-infos-page .info-item .value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .info-item .value.zero {
  color: var(--aais-text-muted);
}
.admin-article-infos-page .info-item .value.warning {
  color: var(--aais-warning);
}
.admin-article-infos-page .info-item .value.reserved {
  color: var(--aais-info);
}
.admin-article-infos-page .info-item .value.promo {
  color: var(--aais-promo);
  font-weight: 700;
}
.admin-article-infos-page .info-item .value.strikethrough {
  text-decoration: line-through;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .info-item .value.tag {
  display: inline-block;
  padding: 0.25rem 0.625rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-xs);
}

.admin-article-infos-page .info-item .value.link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--aais-primary-light);
  text-decoration: none;
}

.admin-article-infos-page .info-item .value.link:hover {
  color: var(--aais-primary);
}

.admin-article-infos-page .info-item .value.badge {
  display: inline-flex;
  padding: 0.25rem 0.625rem;
  background: var(--aais-bg);
  border-radius: var(--aais-radius-xs);
  font-size: 0.8rem;
}

.admin-article-infos-page .info-item .value.badge.success {
  background: var(--aais-success-light);
  color: var(--aais-success);
}
.admin-article-infos-page .info-item .value.badge.warning {
  background: var(--aais-warning-light);
  color: var(--aais-warning);
}
.admin-article-infos-page .info-item .value.badge.info {
  background: var(--aais-info-light);
  color: var(--aais-info);
}

.admin-article-infos-page .info-item.highlight-box {
  padding: 0.75rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-primary);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .info-item.highlight-box.success {
  border-color: var(--aais-success);
}
.admin-article-infos-page .info-item.highlight-box.warning {
  border-color: var(--aais-warning);
}

/* Observations */
.admin-article-infos-page .observations-section {
  background: var(--aais-warning-light);
  border-color: var(--aais-warning);
}

.admin-article-infos-page .observations-text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ========== STOCKS TAB ========== */
.admin-article-infos-page .stocks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .stock-card {
  padding: 1.25rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .stock-card.total {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-info-light), transparent);
  border: 2px solid var(--aais-info);
}

.admin-article-infos-page .stock-card.encde {
  background: linear-gradient(135deg, var(--aais-encde-light), transparent);
  border: 2px solid var(--aais-encde);
}

.admin-article-infos-page .stock-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.admin-article-infos-page .stock-card .stock-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .stock-card .stock-key {
  font-size: 0.65rem;
  padding: 0.125rem 0.375rem;
  background: var(--aais-bg-tertiary);
  border-radius: var(--aais-radius-xs);
  color: var(--aais-text-muted);
}

.admin-article-infos-page .stock-card .stock-icon {
  color: var(--aais-info);
  font-size: 1.25rem;
}
.admin-article-infos-page .stock-card.encde .stock-icon {
  color: var(--aais-encde);
}
.admin-article-infos-page .stock-card .stock-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-text);
}
.admin-article-infos-page .stock-card.total .stock-value {
  font-size: 2.25rem;
}
.admin-article-infos-page .stock-card .stock-value.encde {
  color: var(--aais-encde);
}

/* ========== PRICE TAB ========== */
.admin-article-infos-page .price-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .price-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .price-card.main {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-success-light), transparent);
  border: 2px solid var(--aais-success);
}

.admin-article-infos-page .price-card.main.has-promo {
  background: var(--aais-bg);
  border: 1px dashed var(--aais-border);
}

.admin-article-infos-page .price-card.promo {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-promo-light), transparent);
  border: 2px solid var(--aais-promo);
  position: relative;
}

.admin-article-infos-page .price-card .price-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.admin-article-infos-page .price-card .price-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--aais-text);
}
.admin-article-infos-page .price-card.main .price-value {
  font-size: 2rem;
  color: var(--aais-success);
}
.admin-article-infos-page .price-card.main.has-promo .price-value {
  color: var(--aais-text-muted);
  text-decoration: line-through;
  font-size: 1.25rem;
}
.admin-article-infos-page .price-card.promo .price-value {
  font-size: 2.25rem;
  color: var(--aais-promo);
}

.admin-article-infos-page .discount-badge {
  position: absolute;
  top: -10px;
  right: -10px;
  padding: 0.375rem 0.75rem;
  background: var(--aais-promo);
  color: white;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.85rem;
}

.admin-article-infos-page .promo-section {
  background: var(--aais-promo-light);
  border-color: var(--aais-promo);
}

/* ========== CHARTS ========== */
.admin-article-infos-page .chart-section {
  padding-bottom: 0;
}

.admin-article-infos-page .chart-stats {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}

.admin-article-infos-page .chart-stats.warning .chart-stat .stat-value {
  color: var(--aais-warning);
}

.admin-article-infos-page .chart-stat {
  display: flex;
  flex-direction: column;
}
.admin-article-infos-page .chart-stat .stat-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-primary-light);
}
.admin-article-infos-page .chart-stat .stat-label {
  font-size: 0.75rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .chart-container {
  margin: 0 -1.25rem -1.25rem;
  padding: 1rem;
  background: var(--aais-bg);
  border-top: 1px solid var(--aais-border);
  border-radius: 0 0 var(--aais-radius-sm) var(--aais-radius-sm);
}

.admin-article-infos-page .chart-container.large {
  padding: 1.5rem 1rem;
}

/* Sales Table */
.admin-article-infos-page .sales-table {
  overflow-x: auto;
}

.admin-article-infos-page .sales-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.admin-article-infos-page .sales-table th,
.admin-article-infos-page .sales-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .sales-table th {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  background: var(--aais-bg);
}

.admin-article-infos-page .sales-table th.text-right,
.admin-article-infos-page .sales-table td.text-right {
  text-align: right;
}
.admin-article-infos-page .sales-table tbody tr:hover {
  background: var(--aais-bg-hover);
}
.admin-article-infos-page .sales-table tfoot {
  background: var(--aais-bg);
}
.admin-article-infos-page .sales-table tfoot td {
  font-weight: 700;
  color: var(--aais-primary-light);
}
.admin-article-infos-page .sales-table .positive {
  color: var(--aais-success);
  font-weight: 600;
}
.admin-article-infos-page .sales-table .warning {
  color: var(--aais-warning);
  font-weight: 600;
}

/* ========== FILIALES TAB ========== */
.admin-article-infos-page .filiales-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  gap: 1rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiales-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
}

.admin-article-infos-page .filiales-empty-icon {
  font-size: 4rem;
  color: var(--aais-text-muted);
  margin-bottom: 1rem;
  opacity: 0.5;
}

.admin-article-infos-page .filiales-empty h3 {
  font-size: 1.25rem;
  color: var(--aais-text);
  margin: 0 0 0.5rem;
}

.admin-article-infos-page .filiales-empty p {
  color: var(--aais-text-muted);
  margin: 0;
}

.admin-article-infos-page .filiales-content {
  padding: 1.5rem;
}

/* Filiales Summary */
.admin-article-infos-page .filiales-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
  margin-bottom: 2rem;
}

.admin-article-infos-page .filiales-summary-card {
  background: linear-gradient(
    135deg,
    var(--aais-bg-tertiary),
    var(--aais-bg-secondary)
  );
  border-radius: var(--aais-radius);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  border: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-summary-card.total {
  background: linear-gradient(135deg, var(--aais-info-light), transparent);
  border-color: var(--aais-info);
}

.admin-article-infos-page .filiales-summary-card.available {
  background: linear-gradient(135deg, var(--aais-success-light), transparent);
  border-color: var(--aais-success);
}

.admin-article-infos-page .summary-icon {
  font-size: 2rem;
  opacity: 0.9;
  color: var(--aais-primary);
}

.admin-article-infos-page .filiales-summary-card.total .summary-icon {
  color: var(--aais-info);
}
.admin-article-infos-page .filiales-summary-card.available .summary-icon {
  color: var(--aais-success);
}

.admin-article-infos-page .summary-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .summary-label {
  font-size: 0.8rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-article-infos-page .summary-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-text);
}

.admin-article-infos-page .summary-value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .summary-value.zero {
  color: var(--aais-danger);
}

/* Filiales List */
.admin-article-infos-page .filiales-list {
  background: var(--aais-bg-tertiary);
  border-radius: var(--aais-radius);
  overflow: hidden;
  border: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-list-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--aais-text);
  background: var(--aais-bg-secondary);
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-list-title svg {
  font-size: 1.25rem;
  color: var(--aais-primary);
}

/* Filiales Cards */
.admin-article-infos-page .filiales-cards-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  grid-gap: 1rem;
  gap: 1rem;
  padding: 1rem;
}

.admin-article-infos-page .filiale-card {
  background: var(--aais-bg-secondary);
  border-radius: var(--aais-radius-sm);
  overflow: hidden;
  border: 1px solid var(--aais-border);
  transition: var(--aais-transition);
}

.admin-article-infos-page .filiale-card:hover {
  transform: translateY(-2px);
  border-color: var(--aais-primary);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.admin-article-infos-page .filiale-card.has-stock {
  border-color: rgba(16, 185, 129, 0.5);
}
.admin-article-infos-page .filiale-card.no-stock {
  opacity: 0.7;
  border-color: rgba(239, 68, 68, 0.3);
}

.admin-article-infos-page .filiale-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: var(--aais-bg);
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiale-card-entity {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .filiale-trigramme {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--aais-primary-light);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .filiale-nom {
  font-size: 0.85rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-status {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
}

.admin-article-infos-page .filiale-card-status.in-stock {
  background: var(--aais-success-light);
  color: var(--aais-success);
}

.admin-article-infos-page .filiale-card-status.out-of-stock {
  background: var(--aais-danger-light);
  color: var(--aais-danger);
}

.admin-article-infos-page .filiale-card-status svg {
  font-size: 1rem;
}

.admin-article-infos-page .filiale-card-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.admin-article-infos-page .filiale-card-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-article-infos-page .filiale-card-label {
  font-size: 0.8rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-nart {
  font-size: 0.9rem;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--aais-primary-light);
  background: var(--aais-bg);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.admin-article-infos-page .filiale-card-stock {
  font-size: 1.25rem;
  font-weight: 700;
}

.admin-article-infos-page .filiale-card-stock.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .filiale-card-stock.zero {
  color: var(--aais-danger);
}

.admin-article-infos-page .filiale-card-prix {
  font-size: 1rem;
  font-weight: 700;
  color: var(--aais-success);
}

.admin-article-infos-page .filiale-card-prix.muted {
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-prix-na {
  font-size: 0.85rem;
  color: var(--aais-text-muted);
  font-style: italic;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .admin-article-infos-page .article-main-grid {
    grid-template-columns: 280px 1fr;
  }
  .admin-article-infos-page .info-grid.cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .price-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .stocks-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .stock-card.total {
    grid-column: span 2;
  }
  .admin-article-infos-page .filiales-summary {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .admin-article-infos-page .article-infos-header {
    flex-direction: column;
  }
  .admin-article-infos-page .header-center {
    width: 100%;
  }
  .admin-article-infos-page .entreprise-selector {
    width: 100%;
  }
  .admin-article-infos-page .article-main-grid {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .article-left-column {
    order: -1;
  }
  .admin-article-infos-page .photo-wrapper {
    max-height: 300px;
    aspect-ratio: auto;
  }
  .admin-article-infos-page .quick-stats {
    grid-template-columns: repeat(4, 1fr);
  }
  .admin-article-infos-page .quick-stat.full-width {
    grid-column: span 4;
  }
  .admin-article-infos-page .info-grid.cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .renvoi-details {
    flex-direction: column;
  }
  .admin-article-infos-page .renvoi-arrow {
    transform: rotate(90deg);
    padding: 0.5rem 0;
  }
}

@media (max-width: 600px) {
  .admin-article-infos-page .article-infos-content {
    padding: 1rem;
  }
  .admin-article-infos-page .quick-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .quick-stat.full-width {
    grid-column: span 2;
  }
  .admin-article-infos-page .tab-btn {
    padding: 0.625rem 0.75rem;
    font-size: 0.8rem;
  }
  .admin-article-infos-page .tab-btn span {
    display: none;
  }
  .admin-article-infos-page .tab-btn svg {
    font-size: 1.25rem;
  }
  .admin-article-infos-page .tab-panel {
    padding: 1rem;
  }
  .admin-article-infos-page .info-section {
    padding: 1rem;
  }
  .admin-article-infos-page .info-grid.cols-2,
  .admin-article-infos-page .info-grid.cols-3,
  .admin-article-infos-page .info-grid.cols-4 {
    grid-template-columns: 1fr 1fr;
  }
  .admin-article-infos-page .price-cards {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .price-card.main,
  .admin-article-infos-page .price-card.promo {
    grid-column: span 1;
  }
  .admin-article-infos-page .stocks-grid {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .stock-card.total {
    grid-column: span 1;
  }
  .admin-article-infos-page .article-design-main {
    font-size: 1.25rem;
  }
  .admin-article-infos-page .chart-stats {
    flex-direction: column;
    gap: 0.5rem;
  }
  .admin-article-infos-page .filiales-content {
    padding: 1rem;
  }
  .admin-article-infos-page .filiales-cards-container {
    grid-template-columns: 1fr;
    padding: 0.75rem;
    gap: 0.75rem;
  }
  .admin-article-infos-page .renvoi-from::before,
  .admin-article-infos-page .renvoi-to::before {
    top: -8px;
    right: -8px;
    font-size: 1rem;
  }
}

/* Print Styles */
@media print {
  .admin-article-infos-page {
    background: white;
    color: black;
  }
  .admin-article-infos-page .article-infos-header,
  .admin-article-infos-page .tabs-nav,
  .admin-article-infos-page .btn-action,
  .admin-article-infos-page .btn-back {
    display: none;
  }
  .admin-article-infos-page .article-infos-content {
    padding: 0;
  }
  .admin-article-infos-page .article-main-grid {
    display: block;
  }
  .admin-article-infos-page .tab-content {
    border: none;
    background: none;
  }
}

/* =============================================
   STYLES POUR LA CARD RENVOI CLIQUABLE
   À ajouter dans AdminArticleInfosScreen.css
   ============================================= */

/* Card "Remplacé par" cliquable */
.renvoi-to-clickable {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  border-radius: 12px;
  padding: 1rem;
  margin: -1rem; /* Compenser le padding pour garder l'alignement */
}

.renvoi-to-clickable:hover {
  background: rgba(99, 102, 241, 0.1);
  border-color: #6366f1;
  transform: translateX(5px);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.2);
}

.renvoi-to-clickable:active {
  transform: translateX(3px);
  background: rgba(99, 102, 241, 0.15);
}

/* Icône de lien dans le label */
.renvoi-link-icon {
  margin-left: 6px;
  font-size: 0.85em;
  opacity: 0.7;
  transition: all 0.3s ease;
}

.renvoi-to-clickable:hover .renvoi-link-icon {
  opacity: 1;
  transform: translateX(3px);
}

/* Hint "Cliquer pour voir la fiche" */
.renvoi-click-hint {
  display: block;
  font-size: 0.75rem;
  color: #6366f1;
  margin-top: 0.5rem;
  opacity: 0;
  transform: translateY(-5px);
  transition: all 0.3s ease;
}

.renvoi-to-clickable:hover .renvoi-click-hint {
  opacity: 1;
  transform: translateY(0);
}

/* Animation du NART au hover */
.renvoi-to-clickable:hover .renvoi-nart {
  color: #6366f1;
}

/* Effet de brillance au hover */
.renvoi-to-clickable::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(99, 102, 241, 0.1),
    transparent
  );
  transition: left 0.5s ease;
  pointer-events: none;
}

.renvoi-to-clickable:hover::after {
  left: 100%;
}

/* Style spécifique pour la désignation au hover */
.renvoi-to-clickable:hover .renvoi-design {
  color: #e0e0e5;
}

/* Style du GENCOD au hover */
.renvoi-to-clickable:hover .renvoi-gencod {
  color: #a0a0b0;
}

/* =============================================
   STYLES POUR LA CONVERSION DE DEVISES
   ============================================= */

/* Badge devise à côté du label */
.devise-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
  padding: 2px 8px;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #a5b4fc;
  text-transform: uppercase;
}

.devise-badge svg {
  font-size: 0.8em;
}

/* Container pour les infos de conversion */
.conversion-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

/* Résultat de la conversion */
.conversion-result {
  font-size: 0.95rem;
  font-weight: 600;
  color: #10b981;
}

/* Taux de change */
.conversion-rate {
  font-size: 0.7rem;
  color: #6b7280;
  font-style: italic;
}

/* Warning pour taux approximatif */
.conversion-warning {
  font-size: 0.65rem;
  color: #f59e0b;
  display: flex;
  align-items: center;
  gap: 4px;
}

.conversion-warning::before {
  content: "⚠️";
  font-size: 0.8em;
}

/* Erreur de conversion */
.conversion-error {
  font-size: 0.75rem;
  color: #ef4444;
}

/* Info-item avec devise */
.info-item .value.small {
  font-size: 0.75rem;
  color: #9ca3af;
}

.info-item .value.small .warning {
  color: #f59e0b;
}

/* Style pour le highlight-box avec conversion */
.info-item.highlight-box .conversion-info {
  border-top-color: rgba(99, 102, 241, 0.2);
}

/* Animation de chargement pour les taux */
@keyframes pulse-opacity {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.info-item label:has(+ .loading) {
  animation: pulse-opacity 1.5s ease-in-out infinite;
}

/* =============================================
   STYLES POUR LA FORMULE DE MARGE
   ============================================= */

.marge-formula {
  display: block;
  font-size: 0.65rem;
  color: #6b7280;
  font-style: italic;
  margin-top: 4px;
  font-family: monospace;
}
*/


/* ==========================================================================
   Admin Article Infos Screen - Detailed Article View
   SCOPED STYLES - No global :root variables to avoid conflicts
   ========================================================================== */

/* Page Container with scoped CSS variables */
.admin-article-infos-page {
  --aais-bg: #0a0a0f;
  --aais-bg-secondary: #12121a;
  --aais-bg-tertiary: #1a1a25;
  --aais-bg-hover: #22222e;
  --aais-border: #2a2a3a;
  --aais-text: #f0f0f5;
  --aais-text-secondary: #a0a0b0;
  --aais-text-muted: #606070;
  --aais-primary: #6366f1;
  --aais-primary-light: #818cf8;
  --aais-primary-dark: #4f46e5;
  --aais-primary-glow: rgba(99, 102, 241, 0.3);
  --aais-success: #10b981;
  --aais-success-light: rgba(16, 185, 129, 0.15);
  --aais-warning: #f59e0b;
  --aais-warning-light: rgba(245, 158, 11, 0.15);
  --aais-danger: #ef4444;
  --aais-danger-light: rgba(239, 68, 68, 0.15);
  --aais-info: #3b82f6;
  --aais-info-light: rgba(59, 130, 246, 0.15);
  --aais-promo: #ec4899;
  --aais-promo-light: rgba(236, 72, 153, 0.15);
  --aais-deprec: #f97316;
  --aais-deprec-light: rgba(249, 115, 22, 0.15);
  --aais-web: #06b6d4;
  --aais-web-light: rgba(6, 182, 212, 0.15);
  --aais-photo: #8b5cf6;
  --aais-photo-light: rgba(139, 92, 246, 0.15);
  --aais-renvoi: #eab308;
  --aais-renvoi-light: rgba(234, 179, 8, 0.15);
  --aais-encde: #3b82f6;
  --aais-encde-light: rgba(59, 130, 246, 0.15);
  --aais-radius: 12px;
  --aais-radius-sm: 8px;
  --aais-radius-xs: 4px;
  --aais-transition: all 0.2s ease;

  min-height: 100vh;
  background: var(--aais-bg);
  color: var(--aais-text);
  display: flex;
  flex-direction: column;
}

/* Loading & Error States */
.admin-article-infos-page .loading-state,
.admin-article-infos-page .error-state,
.admin-article-infos-page .empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1 1;
  min-height: 60vh;
  gap: 1rem;
  text-align: center;
  padding: 2rem;
}

.admin-article-infos-page .loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--aais-border);
  border-top-color: var(--aais-primary);
  border-radius: 50%;
  animation: aais-spin 0.8s linear infinite;
}

.admin-article-infos-page .loading-spinner.small {
  width: 24px;
  height: 24px;
  border-width: 2px;
}

@keyframes aais-spin {
  to {
    transform: rotate(360deg);
  }
}
.admin-article-infos-page .spinning {
  animation: aais-spin 1s linear infinite;
}

.admin-article-infos-page .empty-icon,
.admin-article-infos-page .error-icon {
  font-size: 4rem;
  color: var(--aais-primary);
  opacity: 0.6;
}

.admin-article-infos-page .error-icon {
  color: var(--aais-danger);
}
.admin-article-infos-page .error-state h2,
.admin-article-infos-page .empty-state h2 {
  font-size: 1.5rem;
  margin: 0;
}
.admin-article-infos-page .error-state p,
.admin-article-infos-page .empty-state p {
  color: var(--aais-text-muted);
}

.admin-article-infos-page .error-state button {
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background: var(--aais-primary);
  border: none;
  border-radius: var(--aais-radius-sm);
  color: white;
  font-weight: 600;
  cursor: pointer;
}

/* ========== HEADER ========== */
.admin-article-infos-page .article-infos-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: var(--aais-bg-secondary);
  border-bottom: 1px solid var(--aais-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-article-infos-page .header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-article-infos-page .btn-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--aais-transition);
}

.admin-article-infos-page .btn-back:hover {
  background: var(--aais-primary);
  border-color: var(--aais-primary);
  color: white;
}

.admin-article-infos-page .header-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.admin-article-infos-page .header-title h1 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
}

.admin-article-infos-page .title-icon {
  color: var(--aais-primary);
}

.admin-article-infos-page .article-nart-badge {
  padding: 0.375rem 0.75rem;
  background: linear-gradient(
    135deg,
    var(--aais-primary),
    var(--aais-primary-dark)
  );
  border-radius: var(--aais-radius-sm);
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.9rem;
  font-weight: 700;
  color: white;
}

/* ========== NAVIGATION PREV/NEXT ========== */
.admin-article-infos-page .article-navigation {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-article-infos-page .btn-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--aais-transition);
  text-decoration: none;
}

.admin-article-infos-page .btn-nav:hover:not(:disabled) {
  background: var(--aais-primary);
  border-color: var(--aais-primary);
  color: white;
  transform: translateX(0);
}

.admin-article-infos-page .btn-nav.btn-prev:hover:not(:disabled) {
  transform: translateX(-2px);
}

.admin-article-infos-page .btn-nav.btn-next:hover:not(:disabled) {
  transform: translateX(2px);
}

.admin-article-infos-page .btn-nav:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: var(--aais-bg-tertiary);
}

.admin-article-infos-page .btn-nav svg {
  font-size: 1.1rem;
}

.admin-article-infos-page .btn-nav .nav-nart {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  opacity: 0.8;
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-article-infos-page .nav-divider {
  width: 1px;
  height: 24px;
  background: var(--aais-border);
  margin: 0 0.25rem;
}

/* ========== PROMO INDICATOR HEADER ========== */
.admin-article-infos-page .promo-indicator-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, var(--aais-promo), #db2777);
  border-radius: var(--aais-radius-sm);
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  animation: aais-promo-pulse 2s ease-in-out infinite;
  box-shadow: 0 0 20px rgba(236, 72, 153, 0.4);
}

.admin-article-infos-page .promo-indicator-header svg {
  font-size: 1.1rem;
  animation: aais-promo-bounce 1s ease-in-out infinite;
}

.admin-article-infos-page .promo-indicator-header .promo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.admin-article-infos-page .promo-indicator-header .promo-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.9;
}

.admin-article-infos-page .promo-indicator-header .promo-discount {
  font-size: 1rem;
  font-weight: 800;
}

@keyframes aais-promo-pulse {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(236, 72, 153, 0.4);
  }
  50% {
    box-shadow:
      0 0 30px rgba(236, 72, 153, 0.6),
      0 0 40px rgba(236, 72, 153, 0.3);
  }
}

@keyframes aais-promo-bounce {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.15);
  }
}

/* ========== PROMO MEGA BANNER ========== */
.admin-article-infos-page .promo-mega-banner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem 2rem;
  background: linear-gradient(135deg, #ec4899 0%, #db2777 50%, #be185d 100%);
  border-radius: var(--aais-radius);
  margin-bottom: 1.5rem;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(236, 72, 153, 0.3);
}

.admin-article-infos-page .promo-mega-banner::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 10px,
    rgba(255, 255, 255, 0.03) 10px,
    rgba(255, 255, 255, 0.03) 20px
  );
  animation: aais-stripe-move 20s linear infinite;
}

@keyframes aais-stripe-move {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(28px);
  }
}

.admin-article-infos-page .promo-mega-content {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex: 1 1;
}

.admin-article-infos-page .promo-mega-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 70px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 2.5rem;
  color: white;
  animation: aais-promo-icon-pulse 1.5s ease-in-out infinite;
}

@keyframes aais-promo-icon-pulse {
  0%,
  100% {
    transform: scale(1) rotate(0deg);
  }
  25% {
    transform: scale(1.1) rotate(-5deg);
  }
  75% {
    transform: scale(1.1) rotate(5deg);
  }
}

.admin-article-infos-page .promo-mega-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  color: white;
}

.admin-article-infos-page .promo-mega-title {
  font-size: 1.5rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.admin-article-infos-page .promo-mega-dates {
  font-size: 0.9rem;
  opacity: 0.9;
}

.admin-article-infos-page .promo-mega-dates strong {
  font-weight: 700;
}

.admin-article-infos-page .promo-mega-prices {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
}

.admin-article-infos-page .promo-old-price {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: line-through;
}

.admin-article-infos-page .promo-new-price {
  font-size: 2.5rem;
  font-weight: 900;
  color: white;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  line-height: 1;
}

.admin-article-infos-page .promo-discount-badge {
  position: absolute;
  top: -10px;
  right: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background: #fbbf24;
  border-radius: 50%;
  font-size: 1.1rem;
  font-weight: 900;
  color: #1a1a25;
  transform: rotate(15deg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  animation: aais-discount-wiggle 2s ease-in-out infinite;
}

@keyframes aais-discount-wiggle {
  0%,
  100% {
    transform: rotate(15deg) scale(1);
  }
  25% {
    transform: rotate(10deg) scale(1.05);
  }
  75% {
    transform: rotate(20deg) scale(1.05);
  }
}

.admin-article-infos-page .header-center {
  flex: 1 1;
  display: flex;
  justify-content: center;
}

.admin-article-infos-page .entreprise-selector {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  padding: 0.625rem 1rem;
  min-width: 300px;
}

.admin-article-infos-page .entreprise-selector:focus-within {
  border-color: var(--aais-primary);
  box-shadow: 0 0 0 3px var(--aais-primary-glow);
}

.admin-article-infos-page .selector-icon {
  font-size: 1.25rem;
  color: var(--aais-primary);
  margin-right: 0.75rem;
}

.admin-article-infos-page .entreprise-selector select {
  appearance: none;
  background: transparent;
  border: none;
  color: var(--aais-text);
  font-size: 0.9rem;
  font-weight: 500;
  padding-right: 2rem;
  flex: 1 1;
  cursor: pointer;
}

.admin-article-infos-page .entreprise-selector select:focus {
  outline: none;
}

.admin-article-infos-page .selector-arrow {
  position: absolute;
  right: 1rem;
  color: var(--aais-text-muted);
  pointer-events: none;
}

.admin-article-infos-page .header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-article-infos-page .btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 1.125rem;
  cursor: pointer;
  transition: var(--aais-transition);
}

.admin-article-infos-page .btn-action:hover {
  background: var(--aais-primary);
  border-color: var(--aais-primary);
  color: white;
}

.admin-article-infos-page .btn-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ========== CONTENT ========== */
.admin-article-infos-page .article-infos-content {
  flex: 1 1;
  padding: 1.5rem;
  overflow-y: auto;
}

/* Alert Banners */
.admin-article-infos-page .alert-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-radius: var(--aais-radius);
  margin-bottom: 1rem;
  animation: aais-slideIn 0.3s ease;
}

@keyframes aais-slideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-article-infos-page .alert-banner.promo {
  background: linear-gradient(135deg, var(--aais-promo-light), transparent);
  border: 1px solid var(--aais-promo);
}

.admin-article-infos-page .alert-banner.renvoi {
  background: linear-gradient(135deg, var(--aais-renvoi-light), transparent);
  border: 1px solid var(--aais-renvoi);
}

.admin-article-infos-page .alert-banner.deprec {
  background: linear-gradient(135deg, var(--aais-deprec-light), transparent);
  border: 1px solid var(--aais-deprec);
}

.admin-article-infos-page .banner-icon {
  font-size: 1.5rem;
}
.admin-article-infos-page .alert-banner.promo .banner-icon {
  color: var(--aais-promo);
}
.admin-article-infos-page .alert-banner.renvoi .banner-icon {
  color: var(--aais-renvoi);
}
.admin-article-infos-page .alert-banner.deprec .banner-icon {
  color: var(--aais-deprec);
}

.admin-article-infos-page .banner-content {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .banner-content strong {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-article-infos-page .banner-content span {
  font-size: 0.85rem;
  color: var(--aais-text-secondary);
}

.admin-article-infos-page .promo-price {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--aais-promo);
}

.admin-article-infos-page .renvoi-chain {
  padding: 0.25rem 0.75rem;
  background: var(--aais-renvoi);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  color: black;
}

/* ========== RENVOI DETAILS SECTION ========== */
.admin-article-infos-page .renvoi-details-section {
  background: linear-gradient(
    135deg,
    var(--aais-renvoi-light) 0%,
    rgba(234, 179, 8, 0.05) 100%
  );
  padding: 1.25rem;
  border-radius: var(--aais-radius);
  border: 1px solid var(--aais-renvoi);
  margin-bottom: 1rem;
}

.admin-article-infos-page .renvoi-details {
  display: flex;
  align-items: stretch;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.admin-article-infos-page .renvoi-from,
.admin-article-infos-page .renvoi-to {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 1rem;
  border-radius: var(--aais-radius-sm);
  background: var(--aais-bg-secondary);
}

.admin-article-infos-page .renvoi-from {
  border: 2px solid var(--aais-danger);
  position: relative;
}

.admin-article-infos-page .renvoi-from::before {
  content: "❌";
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 1.25rem;
}

.admin-article-infos-page .renvoi-to {
  border: 2px solid var(--aais-success);
  position: relative;
}

.admin-article-infos-page .renvoi-to::before {
  content: "✅";
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 1.25rem;
}

.admin-article-infos-page .renvoi-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .renvoi-nart {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--aais-text);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .renvoi-design {
  font-size: 0.9rem;
  color: var(--aais-text-secondary);
  line-height: 1.3;
}

.admin-article-infos-page .renvoi-gencod {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8rem;
  color: var(--aais-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .renvoi-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--aais-renvoi);
  font-size: 2rem;
  flex-shrink: 0;
  padding: 0 0.5rem;
}

.admin-article-infos-page .renvoi-chain-warning {
  padding: 0.625rem 1rem;
  background: var(--aais-bg-secondary);
  border: 2px solid var(--aais-renvoi);
  border-radius: var(--aais-radius-sm);
  font-size: 0.9rem;
  color: var(--aais-renvoi);
  font-weight: 600;
  text-align: center;
}

/* ========== MAIN GRID ========== */
.admin-article-infos-page .article-main-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  grid-gap: 1.5rem;
  gap: 1.5rem;
}

.admin-article-infos-page .article-left-column {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Photo Card */
.admin-article-infos-page .photo-card {
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow: hidden;
}

.admin-article-infos-page .photo-wrapper {
  position: relative;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--aais-bg-tertiary), var(--aais-bg));
}

.admin-article-infos-page .photo-wrapper img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.admin-article-infos-page .photo-wrapper.loaded img {
  opacity: 1;
}

.admin-article-infos-page .photo-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-article-infos-page .photo-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.5rem 1rem;
  border-radius: var(--aais-radius-sm);
  font-weight: 800;
  font-size: 1.1rem;
}

.admin-article-infos-page .photo-badge.promo {
  background: var(--aais-promo);
  color: white;
  animation: aais-pulse 2s ease-in-out infinite;
}

@keyframes aais-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.admin-article-infos-page .no-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 4rem 2rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .no-photo svg {
  font-size: 3rem;
  opacity: 0.5;
}

/* Quick Badges */
.admin-article-infos-page .quick-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.admin-article-infos-page .quick-badge {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.75rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-secondary);
}

.admin-article-infos-page .quick-badge.web {
  background: var(--aais-web-light);
  border-color: var(--aais-web);
  color: var(--aais-web);
}
.admin-article-infos-page .quick-badge.photo {
  background: var(--aais-photo-light);
  border-color: var(--aais-photo);
  color: var(--aais-photo);
}
.admin-article-infos-page .quick-badge.sav {
  background: var(--aais-success-light);
  border-color: var(--aais-success);
  color: var(--aais-success);
}
.admin-article-infos-page .quick-badge.compose {
  background: var(--aais-info-light);
  border-color: var(--aais-info);
  color: var(--aais-info);
}
.admin-article-infos-page .quick-badge.renvoi {
  background: var(--aais-renvoi-light);
  border-color: var(--aais-renvoi);
  color: var(--aais-renvoi);
}
.admin-article-infos-page .quick-badge.promo {
  background: var(--aais-promo-light);
  border-color: var(--aais-promo);
  color: var(--aais-promo);
  animation: aais-promo-badge-glow 2s ease-in-out infinite;
}

@keyframes aais-promo-badge-glow {
  0%,
  100% {
    box-shadow: 0 0 5px rgba(236, 72, 153, 0.3);
  }
  50% {
    box-shadow: 0 0 15px rgba(236, 72, 153, 0.5);
  }
}

/* Quick Stats */
.admin-article-infos-page .quick-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.admin-article-infos-page .quick-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .quick-stat.full-width {
  grid-column: span 2;
}

.admin-article-infos-page .quick-stat .stat-label {
  font-size: 0.7rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.admin-article-infos-page .quick-stat .stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--aais-text);
}

.admin-article-infos-page .quick-stat .stat-value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .quick-stat .stat-value.zero {
  color: var(--aais-text-muted);
}
.admin-article-infos-page .quick-stat .stat-value.warning {
  color: var(--aais-warning);
}
.admin-article-infos-page .quick-stat .stat-value.encde {
  color: var(--aais-encde);
}

/* Linked Article Card */
.admin-article-infos-page .linked-article-card {
  padding: 1rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .linked-article-card.renvoi-card {
  border-color: var(--aais-renvoi);
  background: linear-gradient(
    135deg,
    var(--aais-renvoi-light),
    var(--aais-bg-secondary)
  );
}

.admin-article-infos-page .linked-article-card h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  margin: 0 0 0.75rem;
}

.admin-article-infos-page .linked-article-card.renvoi-card h4 {
  color: var(--aais-renvoi);
}

.admin-article-infos-page .linked-article-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-primary);
  border-radius: var(--aais-radius-sm);
  color: var(--aais-primary-light);
  text-decoration: none;
  transition: var(--aais-transition);
}

.admin-article-infos-page
  .linked-article-card.renvoi-card
  .linked-article-link {
  border-color: var(--aais-renvoi);
  color: var(--aais-renvoi);
}

.admin-article-infos-page .linked-article-link:hover {
  background: var(--aais-primary);
  color: white;
}

.admin-article-infos-page
  .linked-article-card.renvoi-card
  .linked-article-link:hover {
  background: var(--aais-renvoi);
  color: black;
}

.admin-article-infos-page .linked-nart {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
}

.admin-article-infos-page .linked-article-hint {
  margin: 0.5rem 0 0;
  font-size: 0.75rem;
  color: var(--aais-text-muted);
}

/* ========== RIGHT COLUMN ========== */
.admin-article-infos-page .article-right-column {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

/* Tabs Navigation */
.admin-article-infos-page .tabs-nav {
  display: flex;
  gap: 0.5rem;
  padding: 0.5rem;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow-x: auto;
}

.admin-article-infos-page .tab-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--aais-radius-sm);
  color: var(--aais-text-secondary);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--aais-transition);
  white-space: nowrap;
}

.admin-article-infos-page .tab-btn:hover {
  background: var(--aais-bg-tertiary);
  color: var(--aais-text);
}

.admin-article-infos-page .tab-btn.active {
  background: linear-gradient(
    135deg,
    var(--aais-primary),
    var(--aais-primary-dark)
  );
  color: white;
}

.admin-article-infos-page .tab-btn svg {
  font-size: 1rem;
}

.admin-article-infos-page .tab-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.125rem 0.5rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
}

.admin-article-infos-page .tab-btn.active .tab-badge {
  background: rgba(255, 255, 255, 0.3);
}

/* Tab Content */
.admin-article-infos-page .tab-content {
  flex: 1 1;
  background: var(--aais-bg-secondary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius);
  overflow: hidden;
}

.admin-article-infos-page .tab-panel {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  animation: aais-fadeIn 0.3s ease;
}

.admin-article-infos-page .tab-panel.filiales-tab {
  padding: 0;
}

@keyframes aais-fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Info Sections */
.admin-article-infos-page .info-section {
  padding: 1.25rem;
  background: var(--aais-bg-tertiary);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .info-section h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--aais-text);
  margin: 0 0 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .info-section h3 svg {
  color: var(--aais-primary);
}

/* Designation Section */
.admin-article-infos-page .designation-section {
  background: linear-gradient(
    135deg,
    var(--aais-bg-tertiary),
    var(--aais-bg-secondary)
  );
  border: 2px solid var(--aais-primary);
}

.admin-article-infos-page .article-design-main {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--aais-text);
  margin: 0 0 0.5rem;
  line-height: 1.3;
}

.admin-article-infos-page .article-design-sub {
  font-size: 1.1rem;
  color: var(--aais-text-secondary);
  margin: 0 0 0.5rem;
}

.admin-article-infos-page .article-design-frn {
  font-size: 0.9rem;
  color: var(--aais-text-muted);
  margin: 0;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--aais-border);
}

/* Info Grid */
.admin-article-infos-page .info-grid {
  display: grid;
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .info-grid.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}
.admin-article-infos-page .info-grid.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}
.admin-article-infos-page .info-grid.cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.admin-article-infos-page .info-item {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.admin-article-infos-page .info-item label {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .info-item .value {
  font-size: 0.95rem;
  color: var(--aais-text);
  font-weight: 500;
}

.admin-article-infos-page .info-item .value.highlight {
  color: var(--aais-primary-light);
  font-weight: 700;
}
.admin-article-infos-page .info-item .value.mono {
  font-family: "Monaco", "Consolas", monospace;
}
.admin-article-infos-page .info-item .value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .info-item .value.zero {
  color: var(--aais-text-muted);
}
.admin-article-infos-page .info-item .value.warning {
  color: var(--aais-warning);
}
.admin-article-infos-page .info-item .value.reserved {
  color: var(--aais-info);
}
.admin-article-infos-page .info-item .value.promo {
  color: var(--aais-promo);
  font-weight: 700;
}
.admin-article-infos-page .info-item .value.strikethrough {
  text-decoration: line-through;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .info-item .value.tag {
  display: inline-block;
  padding: 0.25rem 0.625rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-xs);
}

.admin-article-infos-page .info-item .value.link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--aais-primary-light);
  text-decoration: none;
}

.admin-article-infos-page .info-item .value.link:hover {
  color: var(--aais-primary);
}

.admin-article-infos-page .info-item .value.badge {
  display: inline-flex;
  padding: 0.25rem 0.625rem;
  background: var(--aais-bg);
  border-radius: var(--aais-radius-xs);
  font-size: 0.8rem;
}

.admin-article-infos-page .info-item .value.badge.success {
  background: var(--aais-success-light);
  color: var(--aais-success);
}
.admin-article-infos-page .info-item .value.badge.warning {
  background: var(--aais-warning-light);
  color: var(--aais-warning);
}
.admin-article-infos-page .info-item .value.badge.info {
  background: var(--aais-info-light);
  color: var(--aais-info);
}

.admin-article-infos-page .info-item.highlight-box {
  padding: 0.75rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-primary);
  border-radius: var(--aais-radius-sm);
}

.admin-article-infos-page .info-item.highlight-box.success {
  border-color: var(--aais-success);
}
.admin-article-infos-page .info-item.highlight-box.warning {
  border-color: var(--aais-warning);
}

/* Observations */
.admin-article-infos-page .observations-section {
  background: var(--aais-warning-light);
  border-color: var(--aais-warning);
}

.admin-article-infos-page .observations-text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ========== STOCKS TAB ========== */
.admin-article-infos-page .stocks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .stock-card {
  padding: 1.25rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .stock-card.total {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-info-light), transparent);
  border: 2px solid var(--aais-info);
}

.admin-article-infos-page .stock-card.encde {
  background: linear-gradient(135deg, var(--aais-encde-light), transparent);
  border: 2px solid var(--aais-encde);
}

.admin-article-infos-page .stock-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.admin-article-infos-page .stock-card .stock-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .stock-card .stock-key {
  font-size: 0.65rem;
  padding: 0.125rem 0.375rem;
  background: var(--aais-bg-tertiary);
  border-radius: var(--aais-radius-xs);
  color: var(--aais-text-muted);
}

.admin-article-infos-page .stock-card .stock-icon {
  color: var(--aais-info);
  font-size: 1.25rem;
}
.admin-article-infos-page .stock-card.encde .stock-icon {
  color: var(--aais-encde);
}
.admin-article-infos-page .stock-card .stock-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-text);
}
.admin-article-infos-page .stock-card.total .stock-value {
  font-size: 2.25rem;
}
.admin-article-infos-page .stock-card .stock-value.encde {
  color: var(--aais-encde);
}

/* ========== PRICE TAB ========== */
.admin-article-infos-page .price-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.admin-article-infos-page .price-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem;
  background: var(--aais-bg);
  border: 1px solid var(--aais-border);
  border-radius: var(--aais-radius-sm);
  text-align: center;
}

.admin-article-infos-page .price-card.main {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-success-light), transparent);
  border: 2px solid var(--aais-success);
}

.admin-article-infos-page .price-card.main.has-promo {
  background: var(--aais-bg);
  border: 1px dashed var(--aais-border);
}

.admin-article-infos-page .price-card.promo {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--aais-promo-light), transparent);
  border: 2px solid var(--aais-promo);
  position: relative;
}

.admin-article-infos-page .price-card .price-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.admin-article-infos-page .price-card .price-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--aais-text);
}
.admin-article-infos-page .price-card.main .price-value {
  font-size: 2rem;
  color: var(--aais-success);
}
.admin-article-infos-page .price-card.main.has-promo .price-value {
  color: var(--aais-text-muted);
  text-decoration: line-through;
  font-size: 1.25rem;
}
.admin-article-infos-page .price-card.promo .price-value {
  font-size: 2.25rem;
  color: var(--aais-promo);
}

.admin-article-infos-page .discount-badge {
  position: absolute;
  top: -10px;
  right: -10px;
  padding: 0.375rem 0.75rem;
  background: var(--aais-promo);
  color: white;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.85rem;
}

.admin-article-infos-page .promo-section {
  background: var(--aais-promo-light);
  border-color: var(--aais-promo);
}

/* ========== CHARTS ========== */
.admin-article-infos-page .chart-section {
  padding-bottom: 0;
}

.admin-article-infos-page .chart-stats {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}

.admin-article-infos-page .chart-stats.warning .chart-stat .stat-value {
  color: var(--aais-warning);
}

.admin-article-infos-page .chart-stat {
  display: flex;
  flex-direction: column;
}
.admin-article-infos-page .chart-stat .stat-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-primary-light);
}
.admin-article-infos-page .chart-stat .stat-label {
  font-size: 0.75rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
}

.admin-article-infos-page .chart-container {
  margin: 0 -1.25rem -1.25rem;
  padding: 1rem;
  background: var(--aais-bg);
  border-top: 1px solid var(--aais-border);
  border-radius: 0 0 var(--aais-radius-sm) var(--aais-radius-sm);
}

.admin-article-infos-page .chart-container.large {
  padding: 1.5rem 1rem;
}

/* Sales Table */
.admin-article-infos-page .sales-table {
  overflow-x: auto;
}

.admin-article-infos-page .sales-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.admin-article-infos-page .sales-table th,
.admin-article-infos-page .sales-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .sales-table th {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  background: var(--aais-bg);
}

.admin-article-infos-page .sales-table th.text-right,
.admin-article-infos-page .sales-table td.text-right {
  text-align: right;
}
.admin-article-infos-page .sales-table tbody tr:hover {
  background: var(--aais-bg-hover);
}
.admin-article-infos-page .sales-table tfoot {
  background: var(--aais-bg);
}
.admin-article-infos-page .sales-table tfoot td {
  font-weight: 700;
  color: var(--aais-primary-light);
}
.admin-article-infos-page .sales-table .positive {
  color: var(--aais-success);
  font-weight: 600;
}
.admin-article-infos-page .sales-table .warning {
  color: var(--aais-warning);
  font-weight: 600;
}

/* ========== FILIALES TAB ========== */
.admin-article-infos-page .filiales-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  gap: 1rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiales-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
}

.admin-article-infos-page .filiales-empty-icon {
  font-size: 4rem;
  color: var(--aais-text-muted);
  margin-bottom: 1rem;
  opacity: 0.5;
}

.admin-article-infos-page .filiales-empty h3 {
  font-size: 1.25rem;
  color: var(--aais-text);
  margin: 0 0 0.5rem;
}

.admin-article-infos-page .filiales-empty p {
  color: var(--aais-text-muted);
  margin: 0;
}

.admin-article-infos-page .filiales-content {
  padding: 1.5rem;
}

/* Filiales Summary */
.admin-article-infos-page .filiales-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
  margin-bottom: 2rem;
}

.admin-article-infos-page .filiales-summary-card {
  background: linear-gradient(
    135deg,
    var(--aais-bg-tertiary),
    var(--aais-bg-secondary)
  );
  border-radius: var(--aais-radius);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  border: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-summary-card.total {
  background: linear-gradient(135deg, var(--aais-info-light), transparent);
  border-color: var(--aais-info);
}

.admin-article-infos-page .filiales-summary-card.available {
  background: linear-gradient(135deg, var(--aais-success-light), transparent);
  border-color: var(--aais-success);
}

.admin-article-infos-page .summary-icon {
  font-size: 2rem;
  opacity: 0.9;
  color: var(--aais-primary);
}

.admin-article-infos-page .filiales-summary-card.total .summary-icon {
  color: var(--aais-info);
}
.admin-article-infos-page .filiales-summary-card.available .summary-icon {
  color: var(--aais-success);
}

.admin-article-infos-page .summary-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .summary-label {
  font-size: 0.8rem;
  color: var(--aais-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-article-infos-page .summary-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--aais-text);
}

.admin-article-infos-page .summary-value.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .summary-value.zero {
  color: var(--aais-danger);
}

/* Filiales List */
.admin-article-infos-page .filiales-list {
  background: var(--aais-bg-tertiary);
  border-radius: var(--aais-radius);
  overflow: hidden;
  border: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-list-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--aais-text);
  background: var(--aais-bg-secondary);
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiales-list-title svg {
  font-size: 1.25rem;
  color: var(--aais-primary);
}

/* Filiales Cards */
.admin-article-infos-page .filiales-cards-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  grid-gap: 1rem;
  gap: 1rem;
  padding: 1rem;
}

.admin-article-infos-page .filiale-card {
  background: var(--aais-bg-secondary);
  border-radius: var(--aais-radius-sm);
  overflow: hidden;
  border: 1px solid var(--aais-border);
  transition: var(--aais-transition);
}

.admin-article-infos-page .filiale-card:hover {
  transform: translateY(-2px);
  border-color: var(--aais-primary);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.admin-article-infos-page .filiale-card.has-stock {
  border-color: rgba(16, 185, 129, 0.5);
}
.admin-article-infos-page .filiale-card.no-stock {
  opacity: 0.7;
  border-color: rgba(239, 68, 68, 0.3);
}

.admin-article-infos-page .filiale-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: var(--aais-bg);
  border-bottom: 1px solid var(--aais-border);
}

.admin-article-infos-page .filiale-card-entity {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-article-infos-page .filiale-trigramme {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--aais-primary-light);
  font-family: "Monaco", "Consolas", monospace;
}

.admin-article-infos-page .filiale-nom {
  font-size: 0.85rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-status {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
}

.admin-article-infos-page .filiale-card-status.in-stock {
  background: var(--aais-success-light);
  color: var(--aais-success);
}

.admin-article-infos-page .filiale-card-status.out-of-stock {
  background: var(--aais-danger-light);
  color: var(--aais-danger);
}

.admin-article-infos-page .filiale-card-status svg {
  font-size: 1rem;
}

.admin-article-infos-page .filiale-card-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.admin-article-infos-page .filiale-card-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-article-infos-page .filiale-card-label {
  font-size: 0.8rem;
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-nart {
  font-size: 0.9rem;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--aais-primary-light);
  background: var(--aais-bg);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.admin-article-infos-page .filiale-card-stock {
  font-size: 1.25rem;
  font-weight: 700;
}

.admin-article-infos-page .filiale-card-stock.positive {
  color: var(--aais-success);
}
.admin-article-infos-page .filiale-card-stock.zero {
  color: var(--aais-danger);
}

.admin-article-infos-page .filiale-card-prix {
  font-size: 1rem;
  font-weight: 700;
  color: var(--aais-success);
}

.admin-article-infos-page .filiale-card-prix.muted {
  color: var(--aais-text-muted);
}

.admin-article-infos-page .filiale-card-prix-na {
  font-size: 0.85rem;
  color: var(--aais-text-muted);
  font-style: italic;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .admin-article-infos-page .article-main-grid {
    grid-template-columns: 280px 1fr;
  }
  .admin-article-infos-page .info-grid.cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .price-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .stocks-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .stock-card.total {
    grid-column: span 2;
  }
  .admin-article-infos-page .filiales-summary {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .promo-mega-banner {
    flex-direction: column;
    text-align: center;
  }
  .admin-article-infos-page .promo-mega-content {
    flex-direction: column;
    text-align: center;
  }
  .admin-article-infos-page .promo-mega-prices {
    align-items: center;
  }
}
.btn-prev{
  width: auto !important
}
.btn-next{
  width: auto !important
}
.nav-nart{
  color: wheat;
  font-size: 1.2rem  !important;
}
@media (max-width: 900px) {
  .admin-article-infos-page .article-infos-header {
    flex-direction: column;
  }
  .admin-article-infos-page .header-left {
    width: 100%;
    justify-content: space-between;
  }
  .admin-article-infos-page .article-navigation {
    order: -1;
  }
  .admin-article-infos-page .header-center {
    width: 100%;
  }
  .admin-article-infos-page .entreprise-selector {
    width: 100%;
  }
  .admin-article-infos-page .article-main-grid {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .article-left-column {
    order: -1;
  }
  .admin-article-infos-page .photo-wrapper {
    max-height: 300px;
    aspect-ratio: auto;
  }
  .admin-article-infos-page .quick-stats {
    grid-template-columns: repeat(4, 1fr);
  }
  .admin-article-infos-page .quick-stat.full-width {
    grid-column: span 4;
  }
  .admin-article-infos-page .info-grid.cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .renvoi-details {
    flex-direction: column;
  }
  .admin-article-infos-page .renvoi-arrow {
    transform: rotate(90deg);
    padding: 0.5rem 0;
  }
  .admin-article-infos-page .btn-nav .nav-label {
    display: none;
  }
}

@media (max-width: 600px) {
  .admin-article-infos-page .article-infos-content {
    padding: 1rem;
  }
  .admin-article-infos-page .quick-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-article-infos-page .quick-stat.full-width {
    grid-column: span 2;
  }
  .admin-article-infos-page .tab-btn {
    padding: 0.625rem 0.75rem;
    font-size: 0.8rem;
  }
  .admin-article-infos-page .tab-btn span {
    display: none;
  }
  .admin-article-infos-page .tab-btn svg {
    font-size: 1.25rem;
  }
  .admin-article-infos-page .tab-panel {
    padding: 1rem;
  }
  .admin-article-infos-page .info-section {
    padding: 1rem;
  }
  .admin-article-infos-page .info-grid.cols-2,
  .admin-article-infos-page .info-grid.cols-3,
  .admin-article-infos-page .info-grid.cols-4 {
    grid-template-columns: 1fr 1fr;
  }
  .admin-article-infos-page .price-cards {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .price-card.main,
  .admin-article-infos-page .price-card.promo {
    grid-column: span 1;
  }
  .admin-article-infos-page .stocks-grid {
    grid-template-columns: 1fr;
  }
  .admin-article-infos-page .stock-card.total {
    grid-column: span 1;
  }
  .admin-article-infos-page .article-design-main {
    font-size: 1.25rem;
  }
  .admin-article-infos-page .chart-stats {
    flex-direction: column;
    gap: 0.5rem;
  }
  .admin-article-infos-page .filiales-content {
    padding: 1rem;
  }
  .admin-article-infos-page .filiales-cards-container {
    grid-template-columns: 1fr;
    padding: 0.75rem;
    gap: 0.75rem;
  }
  .admin-article-infos-page .renvoi-from::before,
  .admin-article-infos-page .renvoi-to::before {
    top: -8px;
    right: -8px;
    font-size: 1rem;
  }
  .admin-article-infos-page .btn-nav {
    padding: 0.5rem 0.75rem;
  }
  .admin-article-infos-page .btn-nav .nav-nart {
    display: none;
  }
  .admin-article-infos-page .promo-indicator-header {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
  }
  .admin-article-infos-page .promo-indicator-header .promo-text {
    display: none;
  }
  .admin-article-infos-page .promo-mega-banner {
    padding: 1rem;
  }
  .admin-article-infos-page .promo-mega-icon {
    width: 50px;
    height: 50px;
    font-size: 1.75rem;
  }
  .admin-article-infos-page .promo-mega-title {
    font-size: 1.1rem;
  }
  .admin-article-infos-page .promo-new-price {
    font-size: 1.75rem;
  }
  .admin-article-infos-page .promo-discount-badge {
    width: 45px;
    height: 45px;
    font-size: 0.9rem;
  }
}

/* Print Styles */
@media print {
  .admin-article-infos-page {
    background: white;
    color: black;
  }
  .admin-article-infos-page .article-infos-header,
  .admin-article-infos-page .tabs-nav,
  .admin-article-infos-page .btn-action,
  .admin-article-infos-page .btn-back,
  .admin-article-infos-page .article-navigation {
    display: none;
  }
  .admin-article-infos-page .article-infos-content {
    padding: 0;
  }
  .admin-article-infos-page .article-main-grid {
    display: block;
  }
  .admin-article-infos-page .tab-content {
    border: none;
    background: none;
  }
  .admin-article-infos-page .promo-mega-banner {
    background: #fff0f5;
    color: black;
    box-shadow: none;
  }
  .admin-article-infos-page .promo-mega-banner * {
    color: black !important;
    text-shadow: none !important;
  }
}

/* =============================================
   STYLES POUR LA CARD RENVOI CLIQUABLE
   ============================================= */

/* Card "Remplacé par" cliquable */
.renvoi-to-clickable {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  border-radius: 12px;
  padding: 1rem;
  margin: -1rem; /* Compenser le padding pour garder l'alignement */
}

.renvoi-to-clickable:hover {
  background: rgba(99, 102, 241, 0.1);
  border-color: #6366f1;
  transform: translateX(5px);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.2);
}

.renvoi-to-clickable:active {
  transform: translateX(3px);
  background: rgba(99, 102, 241, 0.15);
}

/* Icône de lien dans le label */
.renvoi-link-icon {
  margin-left: 6px;
  font-size: 0.85em;
  opacity: 0.7;
  transition: all 0.3s ease;
}

.renvoi-to-clickable:hover .renvoi-link-icon {
  opacity: 1;
  transform: translateX(3px);
}

/* Hint "Cliquer pour voir la fiche" */
.renvoi-click-hint {
  display: block;
  font-size: 0.75rem;
  color: #6366f1;
  margin-top: 0.5rem;
  opacity: 0;
  transform: translateY(-5px);
  transition: all 0.3s ease;
}

.renvoi-to-clickable:hover .renvoi-click-hint {
  opacity: 1;
  transform: translateY(0);
}

/* Animation du NART au hover */
.renvoi-to-clickable:hover .renvoi-nart {
  color: #6366f1;
}

/* Effet de brillance au hover */
.renvoi-to-clickable::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(99, 102, 241, 0.1),
    transparent
  );
  transition: left 0.5s ease;
  pointer-events: none;
}

.renvoi-to-clickable:hover::after {
  left: 100%;
}

/* Style spécifique pour la désignation au hover */
.renvoi-to-clickable:hover .renvoi-design {
  color: #e0e0e5;
}

/* Style du GENCOD au hover */
.renvoi-to-clickable:hover .renvoi-gencod {
  color: #a0a0b0;
}

/* =============================================
   STYLES POUR LA CONVERSION DE DEVISES
   ============================================= */

/* Badge devise à côté du label */
.devise-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
  padding: 2px 8px;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #a5b4fc;
  text-transform: uppercase;
}

.devise-badge svg {
  font-size: 0.8em;
}

/* Container pour les infos de conversion */
.conversion-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

/* Résultat de la conversion */
.conversion-result {
  font-size: 0.95rem;
  font-weight: 600;
  color: #10b981;
}

/* Taux de change */
.conversion-rate {
  font-size: 0.7rem;
  color: #6b7280;
  font-style: italic;
}

/* Warning pour taux approximatif */
.conversion-warning {
  font-size: 0.65rem;
  color: #f59e0b;
  display: flex;
  align-items: center;
  gap: 4px;
}

.conversion-warning::before {
  content: "⚠️";
  font-size: 0.8em;
}

/* Erreur de conversion */
.conversion-error {
  font-size: 0.75rem;
  color: #ef4444;
}

/* Info-item avec devise */
.info-item .value.small {
  font-size: 0.75rem;
  color: #9ca3af;
}

.info-item .value.small .warning {
  color: #f59e0b;
}

/* Style pour le highlight-box avec conversion */
.info-item.highlight-box .conversion-info {
  border-top-color: rgba(99, 102, 241, 0.2);
}

/* Animation de chargement pour les taux */
@keyframes pulse-opacity {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.info-item label:has(+ .loading) {
  animation: pulse-opacity 1.5s ease-in-out infinite;
}


/* =============================================
   STYLES POUR LA FORMULE DE MARGE
   ============================================= */

.marge-formula {
  display: block;
  font-size: 0.65rem;
  color: #6b7280;
  font-style: italic;
  margin-top: 4px;
  font-family: monospace;
}


/* ─────────────────────────────────────────────────────────────────────────────
   MEDIA CARD — Photo + Fiche technique PDF
   À ajouter dans AdminArticleInfosScreen.css
───────────────────────────────────────────────────────────────────────────── */

/* === Bandeau statut médias (TOUJOURS VISIBLE) === */

.media-status-bar {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  border-top: 1px solid #2a2a3a;
  background: #0e0e18;
}

.media-status-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 500;
  border: 1px solid transparent;
}

.pill--ok       { background: #0d2e1a; border-color: #166534; color: #4ade80; }
.pill--ko       { background: #1f1215; border-color: #7f1d1d; color: #f87171; }
.pill--checking { background: #1a1a2e; border-color: #3730a3; color: #818cf8; }

.pill-icon  { font-size: 1rem; flex-shrink: 0; }
.pill-label { flex: 1 1; }
.pill-check { color: #4ade80; font-size: 1rem; flex-shrink: 0; }
.pill-cross { color: #f87171; font-size: 1rem; flex-shrink: 0; }

.pill-spinner {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  border: 2px solid #3730a3;
  border-top-color: #818cf8;
  border-radius: 50%;
  animation: pill-spin 0.7s linear infinite;
}

@keyframes pill-spin {
  to { transform: rotate(360deg); }
}

/* === Zone photo sans photo mais avec PDF === */

.no-photo--has-pdf {
  border: 2px dashed #4f46e5 !important;
}

/* === Boutons PDF (Voir / Télécharger) === */

.pdf-actions {
  display: flex;
  gap: 8px;
  padding: 8px 12px;
  border-top: 1px solid #2a2a3a;
}

.btn-pdf {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: 1 1;
  padding: 7px 12px;
  border-radius: 6px;
  border: none;
  font-size: 0.8rem;
  cursor: pointer;
  font-weight: 500;
  text-decoration: none;
  transition: opacity 0.2s, transform 0.1s;
}

.btn-pdf:hover  { opacity: 0.85; }
.btn-pdf:active { transform: scale(0.97); }

.btn-pdf--view     { background: #6366f1; color: #fff; }
.btn-pdf--download { background: #2a2a3a; color: #c0c0d0; }

/* Variante compacte pour la modale */
.btn-pdf.small {
  flex: initial;
  padding: 5px 10px;
  font-size: 0.75rem;
}

/* === Modale PDF === */

.pdf-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  -webkit-backdrop-filter: blur(3px);
          backdrop-filter: blur(3px);
}

.pdf-modal {
  background: #12121c;
  border: 1px solid #2a2a3a;
  border-radius: 12px;
  width: 100%;
  max-width: 960px;
  height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}

.pdf-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid #2a2a3a;
  gap: 12px;
  flex-shrink: 0;
}

.pdf-modal-header h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #f0f0f5;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pdf-modal-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.pdf-modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: #f87171;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  padding: 2px;
  transition: color 0.15s;
}

.pdf-modal-close:hover { color: #fca5a5; }

.pdf-modal-body {
  flex: 1 1;
  overflow: hidden;
}

.pdf-modal-body iframe {
  display: block;
  border: none;
  width: 100%;
  height: 100%;
}

:root {
  --admin-bg: #0a0a0f;
  --admin-bg-secondary: #12121a;
  --admin-bg-tertiary: #1a1a25;
  --admin-bg-hover: #22222e;
  --admin-border: #2a2a3a;
  --admin-border-light: #3a3a4a;

  --admin-text: #f0f0f5;
  --admin-text-secondary: #a0a0b0;
  --admin-text-muted: #606070;

  --admin-primary: #6366f1;
  --admin-primary-light: #818cf8;
  --admin-primary-dark: #4f46e5;
  --admin-primary-glow: rgba(99, 102, 241, 0.3);

  --admin-success: #10b981;
  --admin-success-light: rgba(16, 185, 129, 0.15);
  --admin-warning: #f59e0b;
  --admin-warning-light: rgba(245, 158, 11, 0.15);
  --admin-danger: #ef4444;
  --admin-danger-light: rgba(239, 68, 68, 0.15);
  --admin-info: #3b82f6;
  --admin-info-light: rgba(59, 130, 246, 0.15);

  --admin-promo: #ec4899;
  --admin-promo-light: rgba(236, 72, 153, 0.15);
  --admin-deprec: #f97316;
  --admin-deprec-light: rgba(249, 115, 22, 0.15);
  --admin-web: #06b6d4;
  --admin-web-light: rgba(6, 182, 212, 0.15);
  --admin-photo: #8b5cf6;
  --admin-photo-light: rgba(139, 92, 246, 0.15);
  --admin-reappro: #eab308;
  --admin-reappro-light: rgba(234, 179, 8, 0.15);
  --admin-reappro-dark: #ca8a04;

  --admin-arrete: #ef4444;
  --admin-arrete-light: rgba(239, 68, 68, 0.1);
  --admin-deprec-stock: #f97316;
  --admin-deprec-stock-light: rgba(249, 115, 22, 0.12);

  --admin-actif: #10b981;
  --admin-actif-light: rgba(16, 185, 129, 0.12);

  --admin-radius: 12px;
  --admin-radius-sm: 8px;
  --admin-radius-xs: 4px;
  --admin-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  --admin-shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.4);
  --admin-transition: all 0.2s ease;
}

.admin-articles-page {
  min-height: 100vh;
  background: #0a0a0f;
  background: var(--admin-bg);
  color: #f0f0f5;
  color: var(--admin-text);
  display: flex;
  flex-direction: column;
}
.admin-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #2a2a3a;
  border: 3px solid var(--admin-border);
  border-top-color: #6366f1;
  border-top-color: var(--admin-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.loading-spinner.small {
  width: 24px;
  height: 24px;
  border-width: 2px;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.spinning {
  animation: spin 1s linear infinite;
}

/* ========== HEADER ========== */
.admin-articles-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: #12121a;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}
.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.header-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(
    135deg,
    #6366f1,
    #4f46e5
  );
  background: linear-gradient(
    135deg,
    var(--admin-primary),
    var(--admin-primary-dark)
  );
  border-radius: 12px;
  border-radius: var(--admin-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: white;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
  box-shadow: 0 4px 12px var(--admin-primary-glow);
}
.header-title h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
  background: linear-gradient(
    135deg,
    #f0f0f5,
    #818cf8
  );
  background: linear-gradient(
    135deg,
    var(--admin-text),
    var(--admin-primary-light)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.header-subtitle {
  font-size: 0.85rem;
  color: #606070;
  color: var(--admin-text-muted);
  margin: 0;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.entreprise-selector {
  position: relative;
  display: flex;
  align-items: center;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  padding: 0.75rem 1rem;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.entreprise-selector:focus-within {
  border-color: #6366f1;
  border-color: var(--admin-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3);
  box-shadow: 0 0 0 3px var(--admin-primary-glow);
}
.selector-icon {
  font-size: 1.25rem;
  color: #6366f1;
  color: var(--admin-primary);
  margin-right: 0.75rem;
}
.entreprise-selector select {
  appearance: none;
  background: transparent;
  border: none;
  color: #f0f0f5;
  color: var(--admin-text);
  font-size: 0.95rem;
  font-weight: 500;
  padding-right: 2rem;
  min-width: 280px;
  cursor: pointer;
}
.entreprise-selector select:focus {
  outline: none;
}
.selector-arrow {
  position: absolute;
  right: 1rem;
  color: #606070;
  color: var(--admin-text-muted);
  pointer-events: none;
}
.entreprise-selector option {
  background: #1a1a25;
}

/* Empty State */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1 1;
  min-height: 60vh;
  text-align: center;
  padding: 2rem;
}
.empty-icon {
  width: 100px;
  height: 100px;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: #6366f1;
  color: var(--admin-primary);
  margin-bottom: 1.5rem;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
}
.empty-state h2 {
  font-size: 1.5rem;
  margin: 0 0 0.5rem;
  color: #f0f0f5;
  color: var(--admin-text);
}
.empty-state p {
  color: #606070;
  color: var(--admin-text-muted);
  font-size: 1rem;
}

/* ========== LAYOUT ========== */
.admin-articles-content {
  display: flex;
  flex: 1 1;
  overflow: hidden;
}

/* ========== FILTERS SIDEBAR ========== */
.filters-sidebar {
  width: 320px;
  background: #12121a;
  background: var(--admin-bg-secondary);
  border-right: 1px solid #2a2a3a;
  border-right: 1px solid var(--admin-border);
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
  overflow: hidden;
}
.filters-sidebar:not(.open) {
  width: 0;
  border-right: none;
}
.filters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
}
.filters-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: #f0f0f5;
  color: var(--admin-text);
}
.filters-title svg {
  color: #6366f1;
  color: var(--admin-primary);
  font-size: 1.25rem;
}
.filters-badge {
  background: #6366f1;
  background: var(--admin-primary);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 50px;
}
.btn-toggle-filters {
  background: transparent;
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-toggle-filters:hover {
  background: #ef4444;
  background: var(--admin-danger);
  border-color: #ef4444;
  border-color: var(--admin-danger);
  color: white;
}
.filters-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 0.75rem;
}
.filter-section {
  margin-bottom: 0.5rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  overflow: hidden;
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
}
.section-header {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1rem;
  background: transparent;
  border: none;
  color: #f0f0f5;
  color: var(--admin-text);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.section-header:hover {
  background: #22222e;
  background: var(--admin-bg-hover);
}
.section-icon {
  font-size: 1rem;
}
.section-header svg:last-child {
  margin-left: auto;
  color: #606070;
  color: var(--admin-text-muted);
}
.section-content {
  padding: 0.75rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  border-top: 1px solid #2a2a3a;
  border-top: 1px solid var(--admin-border);
  background: rgba(0, 0, 0, 0.2);
}
.filter-group {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}
.filter-group label {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.filter-group label svg {
  font-size: 0.875rem;
  color: #818cf8;
  color: var(--admin-primary-light);
}
.filter-group input,
.filter-group select {
  padding: 0.625rem 0.875rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #f0f0f5;
  color: var(--admin-text);
  font-size: 0.875rem;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.filter-group input::placeholder {
  color: #606070;
  color: var(--admin-text-muted);
}
.filter-group input:focus,
.filter-group select:focus {
  outline: none;
  border-color: #6366f1;
  border-color: var(--admin-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3);
  box-shadow: 0 0 0 3px var(--admin-primary-glow);
}
.filter-group select {
  cursor: pointer;
}
.filter-hint {
  font-size: 0.7rem;
  color: #606070;
  color: var(--admin-text-muted);
  font-style: italic;
}
.filters-footer {
  padding: 1rem;
  border-top: 1px solid #2a2a3a;
  border-top: 1px solid var(--admin-border);
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
}
.btn-reset {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  background: transparent;
  border: 1px solid #ef4444;
  border: 1px solid var(--admin-danger);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #ef4444;
  color: var(--admin-danger);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-reset:hover {
  background: #ef4444;
  background: var(--admin-danger);
  color: white;
}

/* ========== MAIN AREA ========== */
.articles-main {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* ============================================================
   STATUT MINI-CARDS BAR
   ============================================================ */
.statut-cards-bar {
  display: flex;
  align-items: stretch;
  gap: 0.625rem;
  padding: 0.875rem 1.25rem;
  background: #12121a;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}
.statut-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border: 1.5px solid #2a2a3a;
  border: 1.5px solid var(--admin-border);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  min-width: 120px;
  overflow: hidden;
}
.statut-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
  border-radius: inherit;
}
.statut-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
.statut-card:active {
  transform: translateY(0);
}

/* Card inner */
.statut-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  background: #0a0a0f;
  background: var(--admin-bg);
  font-size: 1.15rem;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
  flex-shrink: 0;
}
.statut-card-info {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
}
.statut-card-count {
  font-size: 1.35rem;
  font-weight: 800;
  color: #f0f0f5;
  color: var(--admin-text);
  line-height: 1.1;
  letter-spacing: -0.02em;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.statut-card-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1.2;
}
.statut-card-hint {
  position: absolute;
  bottom: 0.25rem;
  right: 0.5rem;
  font-size: 0.55rem;
  color: #606070;
  color: var(--admin-text-muted);
  opacity: 0.6;
  font-weight: 500;
}
.statut-card-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
}

/* — Tous — */
.statut-card-tous .statut-card-icon {
  color: #818cf8;
  color: var(--admin-primary-light);
}
.statut-card-tous.active {
  border-color: #6366f1;
  border-color: var(--admin-primary);
  background: linear-gradient(
    135deg,
    rgba(99, 102, 241, 0.12),
    #1a1a25
  );
  background: linear-gradient(
    135deg,
    rgba(99, 102, 241, 0.12),
    var(--admin-bg-tertiary)
  );
  box-shadow:
    0 0 0 3px rgba(99, 102, 241, 0.15),
    0 4px 16px rgba(99, 102, 241, 0.1);
}
.statut-card-tous.active .statut-card-icon {
  background: #6366f1;
  background: var(--admin-primary);
  color: white;
}
.statut-card-tous.active .statut-card-count {
  color: #818cf8;
  color: var(--admin-primary-light);
}
.statut-card-tous .statut-card-indicator {
  background: #6366f1;
  background: var(--admin-primary);
}

/* — Actif — */
.statut-card-actif .statut-card-icon {
  color: #10b981;
  color: var(--admin-actif);
}
.statut-card-actif.active {
  border-color: #10b981;
  border-color: var(--admin-actif);
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.12),
    #1a1a25
  );
  background: linear-gradient(
    135deg,
    var(--admin-actif-light),
    var(--admin-bg-tertiary)
  );
  box-shadow:
    0 0 0 3px rgba(16, 185, 129, 0.15),
    0 4px 16px rgba(16, 185, 129, 0.1);
}
.statut-card-actif.active .statut-card-icon {
  background: #10b981;
  background: var(--admin-actif);
  color: white;
}
.statut-card-actif.active .statut-card-count {
  color: #10b981;
  color: var(--admin-actif);
}
.statut-card-actif .statut-card-indicator {
  background: #10b981;
  background: var(--admin-actif);
}

/* — Déprécié — */
.statut-card-deprecie .statut-card-icon {
  color: #f97316;
  color: var(--admin-deprec-stock);
}
.statut-card-deprecie.active {
  border-color: #f97316;
  border-color: var(--admin-deprec-stock);
  background: linear-gradient(
    135deg,
    rgba(249, 115, 22, 0.12),
    #1a1a25
  );
  background: linear-gradient(
    135deg,
    var(--admin-deprec-stock-light),
    var(--admin-bg-tertiary)
  );
  box-shadow:
    0 0 0 3px rgba(249, 115, 22, 0.15),
    0 4px 16px rgba(249, 115, 22, 0.1);
}
.statut-card-deprecie.active .statut-card-icon {
  background: #f97316;
  background: var(--admin-deprec-stock);
  color: white;
}
.statut-card-deprecie.active .statut-card-count {
  color: #f97316;
  color: var(--admin-deprec-stock);
}
.statut-card-deprecie .statut-card-indicator {
  background: #f97316;
  background: var(--admin-deprec-stock);
}

/* — Arrêté — */
.statut-card-arrete .statut-card-icon {
  color: #ef4444;
  color: var(--admin-arrete);
}
.statut-card-arrete.active {
  border-color: #ef4444;
  border-color: var(--admin-arrete);
  background: linear-gradient(
    135deg,
    rgba(239, 68, 68, 0.1),
    #1a1a25
  );
  background: linear-gradient(
    135deg,
    var(--admin-arrete-light),
    var(--admin-bg-tertiary)
  );
  box-shadow:
    0 0 0 3px rgba(239, 68, 68, 0.15),
    0 4px 16px rgba(239, 68, 68, 0.1);
}
.statut-card-arrete.active .statut-card-icon {
  background: #ef4444;
  background: var(--admin-arrete);
  color: white;
}
.statut-card-arrete.active .statut-card-count {
  color: #ef4444;
  color: var(--admin-arrete);
}
.statut-card-arrete .statut-card-indicator {
  background: #ef4444;
  background: var(--admin-arrete);
}

/* — À Réappro — */
.statut-card-reappro .statut-card-icon {
  color: #eab308;
  color: var(--admin-reappro);
}
.statut-card-reappro.active {
  border-color: #eab308;
  border-color: var(--admin-reappro);
  background: linear-gradient(
    135deg,
    rgba(234, 179, 8, 0.15),
    #1a1a25
  );
  background: linear-gradient(
    135deg,
    var(--admin-reappro-light),
    var(--admin-bg-tertiary)
  );
  box-shadow:
    0 0 0 3px rgba(234, 179, 8, 0.15),
    0 4px 16px rgba(234, 179, 8, 0.1);
}
.statut-card-reappro.active .statut-card-icon {
  background: #eab308;
  background: var(--admin-reappro);
  color: #000;
}
.statut-card-reappro.active .statut-card-count {
  color: #eab308;
  color: var(--admin-reappro);
}
.statut-card-reappro .statut-card-indicator {
  background: #eab308;
  background: var(--admin-reappro);
}

.statut-cards-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ============================================================
   BANDEAU D'ALERTE RÉAPPROVISIONNEMENT
   ============================================================ */
.reappro-alert-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1.25rem;
  background: linear-gradient(
    135deg,
    rgba(234, 179, 8, 0.18),
    rgba(234, 179, 8, 0.08)
  );
  border-bottom: 2px solid #eab308;
  border-bottom: 2px solid var(--admin-reappro);
  animation: reappro-banner-slide-in 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes reappro-banner-slide-in {
  from {
    opacity: 0;
    transform: translateY(-100%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.reappro-alert-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  background: #eab308;
  background: var(--admin-reappro);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #000;
  font-size: 1.35rem;
  flex-shrink: 0;
  animation: reappro-icon-pulse 2s ease-in-out infinite;
}
@keyframes reappro-icon-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(234, 179, 8, 0.5);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(234, 179, 8, 0);
  }
}
.reappro-alert-content {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  flex: 1 1;
  min-width: 0;
}
.reappro-alert-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #eab308;
  color: var(--admin-reappro);
  line-height: 1.3;
}
.reappro-alert-desc {
  font-size: 0.8rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  line-height: 1.4;
}
.reappro-alert-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: #eab308;
  background: var(--admin-reappro);
  border: none;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #000;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
  white-space: nowrap;
}
.reappro-alert-btn:hover {
  background: #ca8a04;
  background: var(--admin-reappro-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(234, 179, 8, 0.3);
}
.reappro-alert-btn svg {
  font-size: 0.9rem;
}

/* ============================================================
   BANDEAU RÉAPPRO DANS LA MODAL
   ============================================================ */
.reappro-modal-banner {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  background: linear-gradient(
    135deg,
    rgba(234, 179, 8, 0.15),
    rgba(234, 179, 8, 0.05)
  );
  border: 1px solid #eab308;
  border: 1px solid var(--admin-reappro);
  border-left: 4px solid #eab308;
  border-left: 4px solid var(--admin-reappro);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
}
.reappro-modal-banner svg {
  font-size: 1.5rem;
  color: #eab308;
  color: var(--admin-reappro);
  flex-shrink: 0;
  margin-top: 0.1rem;
}
.reappro-modal-banner strong {
  display: block;
  font-size: 0.9rem;
  color: #eab308;
  color: var(--admin-reappro);
  margin-bottom: 0.25rem;
}
.reappro-modal-banner span {
  font-size: 0.8rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  line-height: 1.5;
}
.reappro-modal-banner span strong {
  display: inline;
  font-size: inherit;
  color: #f0f0f5;
  color: var(--admin-text);
}
.modal-badge.reappro {
  background: #eab308;
  background: var(--admin-reappro);
  color: #000;
}

/* Tag réappro inline sous désignation */
.design-reappro-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.7rem;
  font-weight: 700;
  color: #eab308;
  color: var(--admin-reappro);
  background: rgba(234, 179, 8, 0.15);
  background: var(--admin-reappro-light);
  padding: 0.15rem 0.5rem;
  border-radius: 50px;
  border: 1px solid rgba(234, 179, 8, 0.3);
  margin-top: 0.25rem;
}
.design-reappro-tag svg {
  font-size: 0.7rem;
}

/* S1 alert icon */
.stock-value.reappro-zero {
  color: #eab308 !important;
  color: var(--admin-reappro) !important;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}
.s1-alert-icon {
  font-size: 0.85rem;
  color: #eab308;
  color: var(--admin-reappro);
  animation: s1-alert-pulse 1.5s ease-in-out infinite;
}
@keyframes s1-alert-pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.15);
  }
}

/* Stock item alert in modal */
.stock-item-alert {
  background: linear-gradient(
    135deg,
    rgba(234, 179, 8, 0.2),
    rgba(234, 179, 8, 0.05)
  ) !important;
  border: 1px solid #eab308 !important;
  border: 1px solid var(--admin-reappro) !important;
  position: relative;
}
.stock-item-alert::after {
  content: "";
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  background: #eab308;
  background: var(--admin-reappro);
  border-radius: 50%;
  animation: stock-alert-dot 2s ease-in-out infinite;
}
@keyframes stock-alert-dot {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.stock-alert-icon {
  font-size: 0.85rem;
  margin-left: 0.25rem;
}

/* ============================================================
   STATUT PILLS (table rows)
   ============================================================ */
.statut-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.625rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.statut-pill svg {
  font-size: 0.8rem;
}
.statut-pill-actif {
  background: rgba(16, 185, 129, 0.12);
  background: var(--admin-actif-light);
  color: #10b981;
  color: var(--admin-actif);
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.statut-pill-deprecie {
  background: rgba(249, 115, 22, 0.12);
  background: var(--admin-deprec-stock-light);
  color: #f97316;
  color: var(--admin-deprec-stock);
  border: 1px solid rgba(249, 115, 22, 0.3);
}
.statut-pill-arrete {
  background: rgba(239, 68, 68, 0.1);
  background: var(--admin-arrete-light);
  color: #ef4444;
  color: var(--admin-arrete);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ============================================================
   STATS BAR
   ============================================================ */
.stats-bar {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.625rem 1.25rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}
.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem 1rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  min-width: 80px;
}
.stat-item.stat-filtered {
  background: rgba(99, 102, 241, 0.3);
  background: var(--admin-primary-glow);
  border-color: #6366f1;
  border-color: var(--admin-primary);
}
.stat-item.stat-filtered .stat-value {
  color: #818cf8;
  color: var(--admin-primary-light);
}
.stat-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: #818cf8;
  color: var(--admin-primary-light);
}
.stat-label {
  font-size: 0.65rem;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-icon-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-icon-action:hover {
  background: #6366f1;
  background: var(--admin-primary);
  border-color: #6366f1;
  border-color: var(--admin-primary);
  color: white;
}
.btn-icon-action.active {
  background: #6366f1;
  background: var(--admin-primary);
  border-color: #6366f1;
  border-color: var(--admin-primary);
  color: white;
}
.btn-icon-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ========== TABLE ========== */
.articles-table-container {
  flex: 1 1;
  overflow: auto;
  padding: 1rem;
}
.table-loading,
.table-error,
.table-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  gap: 1rem;
  color: #606070;
  color: var(--admin-text-muted);
}
.table-error {
  color: #ef4444;
  color: var(--admin-danger);
}
.table-error button {
  padding: 0.5rem 1rem;
  background: #ef4444;
  background: var(--admin-danger);
  border: none;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: white;
  cursor: pointer;
}
.table-empty svg {
  font-size: 3rem;
  opacity: 0.5;
}
.table-empty h3 {
  font-size: 1.25rem;
  color: #f0f0f5;
  color: var(--admin-text);
  margin: 0;
}
.btn-reset-statut {
  margin-top: 0.5rem;
  padding: 0.625rem 1.25rem;
  background: #6366f1;
  background: var(--admin-primary);
  border: none;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: white;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-reset-statut:hover {
  background: #4f46e5;
  background: var(--admin-primary-dark);
}

.articles-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.875rem;
}
.articles-table thead {
  position: sticky;
  top: 0;
  z-index: 10;
}
.articles-table th {
  padding: 0.875rem 1rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  color: #606070;
  color: var(--admin-text-muted);
  font-weight: 600;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
  border-bottom: 2px solid #6366f1;
  border-bottom: 2px solid var(--admin-primary);
  white-space: nowrap;
}
.articles-table th.text-right {
  text-align: right;
}
.articles-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
  vertical-align: middle;
}
.articles-table tbody tr {
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.articles-table tbody tr:hover {
  background: #22222e;
  background: var(--admin-bg-hover);
}

/* Row variants */
.articles-table tbody tr.row-promo {
  background: rgba(236, 72, 153, 0.15);
  background: var(--admin-promo-light);
}
.articles-table tbody tr.row-promo:hover {
  background: rgba(236, 72, 153, 0.25);
}
.articles-table tbody tr.row-reappro {
  background: rgba(234, 179, 8, 0.15);
  background: var(--admin-reappro-light);
  border-left: 3px solid #eab308;
  border-left: 3px solid var(--admin-reappro);
}
.articles-table tbody tr.row-reappro:hover {
  background: rgba(234, 179, 8, 0.25);
}
.articles-table tbody tr.row-deprec-stock {
  background: rgba(249, 115, 22, 0.12);
  background: var(--admin-deprec-stock-light);
  border-left: 3px solid #f97316;
  border-left: 3px solid var(--admin-deprec-stock);
}
.articles-table tbody tr.row-deprec-stock:hover {
  background: rgba(249, 115, 22, 0.2);
}
.articles-table tbody tr.row-arrete {
  background: rgba(239, 68, 68, 0.1);
  background: var(--admin-arrete-light);
  border-left: 3px solid #ef4444;
  border-left: 3px solid var(--admin-arrete);
  opacity: 0.75;
}
.articles-table tbody tr.row-arrete:hover {
  opacity: 1;
  background: rgba(239, 68, 68, 0.18);
}

/* Table cells */
.article-nart-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: #818cf8;
  color: var(--admin-primary-light);
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  text-decoration: none;
  padding: 0.25rem 0.5rem;
  margin: -0.25rem -0.5rem;
  border-radius: 4px;
  border-radius: var(--admin-radius-xs);
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.article-nart-link:hover {
  background: #6366f1;
  background: var(--admin-primary);
  color: white;
}
.article-nart-link .link-icon {
  font-size: 0.75rem;
  opacity: 0;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.article-nart-link:hover .link-icon {
  opacity: 1;
}
.article-designation {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}
.design-main {
  font-weight: 500;
  color: #f0f0f5;
  color: var(--admin-text);
  line-height: 1.3;
}
.design-sub {
  font-size: 0.75rem;
  color: #606070;
  color: var(--admin-text-muted);
}
.gencod-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.8rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.groupe-tag {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 4px;
  border-radius: var(--admin-radius-xs);
  font-size: 0.75rem;
  font-weight: 600;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.fourn-value {
  font-size: 0.85rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.stock-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
}
.stock-value.positive {
  color: #10b981;
  color: var(--admin-success);
}
.stock-value.negative {
  color: #ef4444;
  color: var(--admin-danger);
}
.stock-value.zero {
  color: #606070;
  color: var(--admin-text-muted);
}
.price-cell {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.125rem;
}
.price-promo {
  font-weight: 700;
  color: #ec4899;
  color: var(--admin-promo);
  font-size: 0.95rem;
}
.price-value {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 600;
  color: #f0f0f5;
  color: var(--admin-text);
}
.price-value.strikethrough {
  text-decoration: line-through;
  color: #606070;
  color: var(--admin-text-muted);
  font-size: 0.8rem;
}

/* Badges */
.badges-container {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  flex-wrap: wrap;
}
.badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 0.75rem;
}
.badge-promo {
  background: #ec4899;
  background: var(--admin-promo);
  color: white;
}
.badge-deprec {
  background: #f97316;
  background: var(--admin-deprec);
  color: white;
}
.badge-web {
  background: #06b6d4;
  background: var(--admin-web);
  color: white;
}
.badge-photo {
  background: #8b5cf6;
  background: var(--admin-photo);
  color: white;
}
.badge-reappro {
  background: #eab308;
  background: var(--admin-reappro);
  color: black;
}
.badge-arrete {
  background: #ef4444;
  background: var(--admin-arrete);
  color: white;
}
.btn-view {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-view:hover {
  background: #6366f1;
  background: var(--admin-primary);
  border-color: #6366f1;
  border-color: var(--admin-primary);
  color: white;
}

/* ========== PAGINATION ========== */
.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: #12121a;
  background: var(--admin-bg-secondary);
  border-top: 1px solid #2a2a3a;
  border-top: 1px solid var(--admin-border);
  flex-wrap: wrap;
  gap: 1rem;
}
.pagination-info {
  font-size: 0.85rem;
  color: #606070;
  color: var(--admin-text-muted);
}
.pagination-info strong {
  color: #f0f0f5;
  color: var(--admin-text);
}
.pagination-filter-note {
  color: #818cf8;
  color: var(--admin-primary-light);
  font-weight: 600;
  font-size: 0.8rem;
}
.pagination-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.btn-page {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-page:hover:not(:disabled) {
  background: #6366f1;
  background: var(--admin-primary);
  border-color: #6366f1;
  border-color: var(--admin-primary);
  color: white;
}
.btn-page:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.page-indicator {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
}
.current-page {
  font-weight: 700;
  color: #818cf8;
  color: var(--admin-primary-light);
}
.page-separator {
  color: #606070;
  color: var(--admin-text-muted);
}
.total-pages {
  color: #606070;
  color: var(--admin-text-muted);
}

/* ========== MODAL ========== */
.article-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1.5rem;
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
}
.article-modal {
  background: #12121a;
  background: var(--admin-bg-secondary);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
  box-shadow: var(--admin-shadow-lg);
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
}
.modal-title {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.modal-title svg {
  font-size: 1.5rem;
  color: #6366f1;
  color: var(--admin-primary);
}
.modal-title h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
  color: #f0f0f5;
  color: var(--admin-text);
}
.modal-nart {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.85rem;
  color: #818cf8;
  color: var(--admin-primary-light);
  font-weight: 700;
}
.modal-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.btn-view-full {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  background: #6366f1;
  background: var(--admin-primary);
  border: none;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: white;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-view-full:hover {
  background: #4f46e5;
  background: var(--admin-primary-dark);
}
.btn-close-modal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: transparent;
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--admin-transition);
}
.btn-close-modal:hover {
  background: #ef4444;
  background: var(--admin-danger);
  border-color: #ef4444;
  border-color: var(--admin-danger);
  color: white;
}
.modal-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.5rem;
}
.modal-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  grid-gap: 1.5rem;
  gap: 1.5rem;
}
.modal-photo-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.photo-wrapper {
  position: relative;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  overflow: hidden;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.photo-wrapper img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.photo-wrapper.loaded img {
  opacity: 1;
}
.photo-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0a0a0f;
  background: var(--admin-bg);
}
.no-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 3rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  color: #606070;
  color: var(--admin-text-muted);
}
.no-photo svg {
  font-size: 3rem;
  opacity: 0.5;
}
.modal-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.modal-badge {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}
.modal-badge.actif {
  background: #10b981;
  background: var(--admin-actif);
  color: white;
}
.modal-badge.promo {
  background: #ec4899;
  background: var(--admin-promo);
  color: white;
}
.modal-badge.deprec {
  background: #f97316;
  background: var(--admin-deprec);
  color: white;
}
.modal-badge.deprec-stock {
  background: #f97316;
  background: var(--admin-deprec-stock);
  color: white;
}
.modal-badge.arrete {
  background: #ef4444;
  background: var(--admin-arrete);
  color: white;
}
.modal-badge.web {
  background: #06b6d4;
  background: var(--admin-web);
  color: white;
}
.arrete-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  background: rgba(239, 68, 68, 0.1);
  background: var(--admin-arrete-light);
  border: 1px solid #ef4444;
  border: 1px solid var(--admin-arrete);
  border-left: 4px solid #ef4444;
  border-left: 4px solid var(--admin-arrete);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
}
.arrete-banner svg {
  font-size: 1.5rem;
  color: #ef4444;
  color: var(--admin-arrete);
  flex-shrink: 0;
}
.arrete-banner strong {
  display: block;
  font-size: 0.9rem;
  color: #ef4444;
  color: var(--admin-arrete);
}
.arrete-banner span {
  font-size: 0.8rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.deprec-stock-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  background: rgba(249, 115, 22, 0.12);
  background: var(--admin-deprec-stock-light);
  border: 1px solid #f97316;
  border: 1px solid var(--admin-deprec-stock);
  border-left: 4px solid #f97316;
  border-left: 4px solid var(--admin-deprec-stock);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
}
.deprec-stock-banner svg {
  font-size: 1.5rem;
  color: #f97316;
  color: var(--admin-deprec-stock);
  flex-shrink: 0;
}
.deprec-stock-banner strong {
  display: block;
  font-size: 0.9rem;
  color: #f97316;
  color: var(--admin-deprec-stock);
}
.deprec-stock-banner span {
  font-size: 0.8rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
}
.modal-info-section {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.info-block {
  background: #1a1a25;
  background: var(--admin-bg-tertiary);
  border-radius: 12px;
  border-radius: var(--admin-radius);
  padding: 1rem 1.25rem;
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border);
}
.designation-block h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #f0f0f5;
  color: var(--admin-text);
  margin: 0 0 0.25rem;
  line-height: 1.3;
}
.designation-block p {
  font-size: 0.95rem;
  color: #a0a0b0;
  color: var(--admin-text-secondary);
  margin: 0;
}
.info-block h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: #606070;
  color: var(--admin-text-muted);
  margin: 0 0 0.875rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border);
}
.info-grid,
.codes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.875rem;
  gap: 0.875rem;
}
.info-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.info-item label {
  font-size: 0.7rem;
  font-weight: 600;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.info-item .value {
  font-size: 0.9rem;
  color: #f0f0f5;
  color: var(--admin-text);
  font-weight: 500;
}
.info-item .value.highlight {
  color: #818cf8;
  color: var(--admin-primary-light);
  font-weight: 700;
}
.info-item .value.mono {
  font-family: "Monaco", "Consolas", monospace;
}
.info-item .value.tag {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 4px;
  border-radius: var(--admin-radius-xs);
  font-size: 0.8rem;
}
.price-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}
.price-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.75rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  text-align: center;
}
.price-item.main {
  grid-column: span 2;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), transparent);
  background: linear-gradient(135deg, var(--admin-success-light), transparent);
  border: 1px solid #10b981;
  border: 1px solid var(--admin-success);
}
.price-item.promo {
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.15), transparent);
  background: linear-gradient(135deg, var(--admin-promo-light), transparent);
  border: 1px solid #ec4899;
  border: 1px solid var(--admin-promo);
}
.price-item.promo span:last-child {
  color: #ec4899;
  color: var(--admin-promo);
  font-size: 1.25rem;
  font-weight: 800;
}
.price-item label {
  font-size: 0.7rem;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}
.price-item span:last-child {
  font-size: 1rem;
  font-weight: 700;
  color: #f0f0f5;
  color: var(--admin-text);
}
.price-item span.strikethrough {
  text-decoration: line-through;
  color: #606070;
  color: var(--admin-text-muted);
}
.stock-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}
.stock-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.75rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
  text-align: center;
  position: relative;
}
.stock-item.total {
  grid-column: span 2;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), transparent);
  background: linear-gradient(135deg, var(--admin-info-light), transparent);
  border: 1px solid #3b82f6;
  border: 1px solid var(--admin-info);
}
.stock-item label {
  font-size: 0.7rem;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}
.stock-item span:last-child {
  font-size: 1.1rem;
  font-weight: 700;
  color: #f0f0f5;
  color: var(--admin-text);
}
.stock-item span.positive {
  color: #10b981;
  color: var(--admin-success);
}
.stock-item span.zero {
  color: #606070;
  color: var(--admin-text-muted);
}
.stock-item span.reserved {
  color: #f59e0b;
  color: var(--admin-warning);
}
.gisement-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}
.gisement-item {
  padding: 0.625rem;
  background: #0a0a0f;
  background: var(--admin-bg);
  border-radius: 8px;
  border-radius: var(--admin-radius-sm);
}
.gisement-item.main {
  grid-column: span 3;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), transparent);
  background: linear-gradient(135deg, var(--admin-primary-glow), transparent);
  border: 1px solid #6366f1;
  border: 1px solid var(--admin-primary);
}
.gisement-item label {
  display: block;
  font-size: 0.65rem;
  color: #606070;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}
.gisement-item span {
  font-weight: 600;
  color: #f0f0f5;
  color: var(--admin-text);
}
.observations-block {
  background: rgba(245, 158, 11, 0.15);
  background: var(--admin-warning-light);
  border-color: #f59e0b;
  border-color: var(--admin-warning);
}
.observations-text {
  margin: 0;
  font-size: 0.9rem;
  color: #f0f0f5;
  color: var(--admin-text);
  line-height: 1.5;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .filters-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 100;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
    box-shadow: var(--admin-shadow-lg);
  }
  .filters-sidebar:not(.open) {
    transform: translateX(-100%);
    width: 320px;
  }
}
@media (max-width: 900px) {
  .admin-articles-header {
    flex-direction: column;
    align-items: stretch;
  }
  .header-actions {
    flex-direction: column;
  }
  .entreprise-selector {
    width: 100%;
  }
  .entreprise-selector select {
    min-width: auto;
    width: 100%;
  }
  .statut-cards-bar {
    gap: 0.5rem;
    padding: 0.75rem 1rem;
  }
  .statut-card {
    min-width: 90px;
    padding: 0.625rem 0.875rem;
    gap: 0.5rem;
  }
  .statut-card-count {
    font-size: 1.1rem;
  }
  .statut-card-icon {
    width: 30px;
    height: 30px;
    font-size: 1rem;
  }
  .statut-card-hint {
    display: none;
  }
  .modal-grid {
    grid-template-columns: 1fr;
  }
  .modal-photo-section {
    order: -1;
  }
  .photo-wrapper {
    max-height: 200px;
    aspect-ratio: auto;
  }
  .info-grid,
  .codes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .price-grid,
  .stock-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gisement-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gisement-item.main {
    grid-column: span 2;
  }
  .col-statut {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
  }
  .statut-pill span {
    display: none;
  }
  .statut-pill {
    padding: 0.25rem 0.4rem;
  }
  .reappro-alert-banner {
    flex-wrap: wrap;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
  }
  .reappro-alert-content {
    flex: 1 1 200px;
  }
}
@media (max-width: 600px) {
  .statut-cards-bar {
    flex-wrap: wrap;
    gap: 0.375rem;
  }
  .statut-card {
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: calc(33% - 0.375rem);
    min-width: 0;
    padding: 0.5rem 0.625rem;
  }
  .statut-card-label {
    font-size: 0.6rem;
  }
  .statut-cards-actions {
    width: 100%;
    justify-content: flex-end;
    margin-left: 0;
    padding-top: 0.25rem;
  }
  .stat-item {
    min-width: 70px;
    padding: 0.375rem 0.625rem;
  }
  .stat-value {
    font-size: 0.95rem;
  }
  .articles-table th.col-gencod,
  .articles-table td.col-gencod,
  .articles-table th.col-groupe,
  .articles-table td.col-groupe,
  .articles-table th.col-fourn,
  .articles-table td.col-fourn {
    display: none;
  }
  .pagination-bar {
    flex-direction: column;
    text-align: center;
  }
  .btn-page span {
    display: none;
  }
  .info-grid,
  .codes-grid,
  .price-grid,
  .stock-grid,
  .gisement-grid {
    grid-template-columns: 1fr 1fr;
  }
  .price-item.main,
  .stock-item.total,
  .gisement-item.main {
    grid-column: span 2;
  }
  .reappro-alert-banner {
    flex-direction: column;
    align-items: flex-start;
  }
  .design-reappro-tag {
    display: none;
  }
}

/* src/screens/admin/AdminFournisseursScreen.css */

/* ========== PAGE ========== */
.admin-fourn-page {
  min-height: 100vh;
  background: #0a0a0f;
  background: var(--admin-bg, #0a0a0f);
  color: #f0f0f5;
  color: var(--admin-text, #f0f0f5);
}

.admin-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
}

/* ========== HEADER ========== */
.admin-fourn-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: #12121a;
  background: var(--admin-bg-secondary, #12121a);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border, #2a2a3a);
  flex-wrap: wrap;
  gap: 1rem;
}

.header-left { display: flex; align-items: center; gap: 1rem; }

.header-icon {
  width: 48px; height: 48px; border-radius: 10px;
  background: linear-gradient(135deg, #0891b2, #06b6d4);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; color: #fff; flex-shrink: 0;
}

.header-title h1 { font-size: 1.25rem; font-weight: 800; margin: 0; }
.header-subtitle { font-size: 0.8rem; color: #606070; color: var(--admin-text-muted, #606070); margin: 0.125rem 0 0; }
.header-actions { display: flex; align-items: center; gap: 0.75rem; }

.entreprise-selector {
  display: flex; align-items: center; position: relative;
  background: #1a1a25;
  background: var(--admin-bg-tertiary, #1a1a25);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a);
  border-radius: 8px; padding: 0 0.625rem;
}
.entreprise-selector select {
  background: transparent; border: none; color: #f0f0f5; color: var(--admin-text, #f0f0f5);
  font-size: 0.85rem; font-weight: 600; padding: 0.5rem 1.5rem 0.5rem 0.25rem;
  outline: none; cursor: pointer; appearance: none; min-width: 200px;
}
.selector-icon { color: #06b6d4; font-size: 1.1rem; }
.selector-arrow { position: absolute; right: 0.5rem; color: #606070; color: var(--admin-text-muted, #606070); pointer-events: none; }

/* ========== EMPTY ========== */
.empty-state {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 4rem 2rem; text-align: center;
}
.empty-state .empty-icon { font-size: 3rem; color: #606070; color: var(--admin-text-muted, #606070); opacity: 0.5; margin-bottom: 1rem; }
.empty-state h2 { font-size: 1.1rem; font-weight: 700; margin: 0 0 0.5rem; }

/* ========== LAYOUT ========== */
.admin-fourn-content { display: flex; gap: 0; min-height: calc(100vh - 100px); }

/* ========== SIDEBAR ========== */
.filters-sidebar {
  width: 280px; background: #12121a; background: var(--admin-bg-secondary, #12121a);
  border-right: 1px solid #2a2a3a;
  border-right: 1px solid var(--admin-border, #2a2a3a);
  display: flex; flex-direction: column; flex-shrink: 0;
  transition: width 0.2s ease; overflow: hidden;
}
.filters-sidebar:not(.open) { width: 0; min-width: 0; border-right: none; }

.filters-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1rem; border-bottom: 1px solid #2a2a3a; border-bottom: 1px solid var(--admin-border, #2a2a3a);
}
.filters-title {
  display: flex; align-items: center; gap: 0.5rem;
  font-weight: 700; font-size: 0.85rem; color: #06b6d4;
}
.btn-toggle-filters {
  background: transparent; border: 1px solid #2a2a3a; border: 1px solid var(--admin-border, #2a2a3a);
  color: #606070;
  color: var(--admin-text-muted, #606070); cursor: pointer; padding: 0.375rem;
  border-radius: 6px; transition: all 0.15s;
}
.btn-toggle-filters:hover { background: #2a2a3a; background: var(--admin-bg-hover, #2a2a3a); color: #f0f0f5; color: var(--admin-text, #f0f0f5); }

.filters-body { flex: 1 1; overflow-y: auto; padding: 0.75rem 1rem; }

.filter-group { margin-bottom: 0.75rem; }
.filter-group label {
  display: flex; align-items: center; gap: 0.375rem;
  font-size: 0.7rem; font-weight: 600; color: #606070; color: var(--admin-text-muted, #606070);
  margin-bottom: 0.25rem; text-transform: uppercase; letter-spacing: 0.03em;
}
.filter-group input, .filter-group select {
  width: 100%; padding: 0.5rem 0.625rem;
  background: #0a0a0f;
  background: var(--admin-bg, #0a0a0f);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a);
  border-radius: 6px; color: #f0f0f5; color: var(--admin-text, #f0f0f5);
  font-size: 0.8rem; outline: none; transition: border-color 0.2s;
}
.filter-group input:focus, .filter-group select:focus {
  border-color: #06b6d4; box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.15);
}
.filter-hint {
  display: block; margin-top: 0.3rem; font-size: 0.68rem;
  color: #606070;
  color: var(--admin-text-muted, #606070); font-style: italic;
}

/* ========== MAIN ========== */
.fourn-main { flex: 1 1; display: flex; flex-direction: column; overflow: hidden; }

/* ========== STATS BAR ========== */
.stats-bar {
  display: flex; align-items: center; gap: 1.25rem;
  padding: 0.75rem 1.25rem; background: #12121a; background: var(--admin-bg-secondary, #12121a);
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border, #2a2a3a); flex-wrap: wrap;
}
.stat-item { display: flex; flex-direction: column; gap: 0.125rem; }
.stat-item .stat-value { font-size: 1rem; font-weight: 800; color: #f0f0f5; color: var(--admin-text, #f0f0f5); }
.stat-item.primary .stat-value { color: #06b6d4; }
.stat-item .stat-label { font-size: 0.62rem; color: #606070; color: var(--admin-text-muted, #606070); text-transform: uppercase; letter-spacing: 0.05em; }
.stat-item.stat-actif-g .stat-value { color: #10b981; }
.stat-item.stat-deprecie-g .stat-value { color: #f59e0b; }
.stat-item.stat-arrete-g .stat-value { color: #ef4444; }
.stat-item.stat-reappro-g .stat-value { color: #a78bfa; }

.stats-actions { display: flex; gap: 0.375rem; margin-left: auto; }
.btn-icon-action {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; background: #1a1a25; background: var(--admin-bg-tertiary, #1a1a25);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a); border-radius: 6px;
  color: #606070;
  color: var(--admin-text-muted, #606070); cursor: pointer; transition: all 0.15s;
}
.btn-icon-action:hover, .btn-icon-action.active { background: #2a2a3a; background: var(--admin-bg-hover, #2a2a3a); color: #06b6d4; border-color: #06b6d4; }
.btn-icon-action:disabled { opacity: 0.5; cursor: not-allowed; }
.spinning { animation: spin 1s linear infinite; }
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ========== HEALTH FILTER BANNER ========== */
.health-filter-banner {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.5rem 1.25rem; background: rgba(6, 182, 212, 0.06);
  border-bottom: 1px solid rgba(6, 182, 212, 0.15); font-size: 0.8rem; color: #a0a0b0;
}
.health-filter-count { margin-left: auto; font-weight: 700; color: #06b6d4; font-size: 0.78rem; }
.health-filter-clear {
  display: inline-flex; align-items: center; gap: 0.25rem;
  padding: 0.2rem 0.6rem; background: #1a1a25; background: var(--admin-bg-tertiary, #1a1a25);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a); border-radius: 5px;
  color: #606070;
  color: var(--admin-text-muted, #606070); font-size: 0.72rem; cursor: pointer; transition: all 0.15s;
}
.health-filter-clear:hover { background: #2a2a3a; background: var(--admin-bg-hover, #2a2a3a); color: #f0f0f5; color: var(--admin-text, #f0f0f5); }

/* ========== TABLE ========== */
.fourn-table-container { flex: 1 1; overflow: auto; }

.table-loading, .table-error, .table-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 3rem 2rem; text-align: center; color: #606070; color: var(--admin-text-muted, #606070);
}
.table-empty svg { font-size: 2.5rem; opacity: 0.3; margin-bottom: 0.75rem; }
.table-empty h3 { margin: 0 0 0.25rem; font-size: 1rem; }
.table-empty p { font-size: 0.82rem; margin: 0; }

.fourn-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }

.fourn-table thead th {
  position: sticky; top: 0; background: #1a1a25; background: var(--admin-bg-tertiary, #1a1a25);
  border-bottom: 2px solid #2a2a3a;
  border-bottom: 2px solid var(--admin-border, #2a2a3a);
  padding: 0.6rem 0.5rem; text-align: left; font-size: 0.68rem;
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em;
  color: #606070;
  color: var(--admin-text-muted, #606070); white-space: nowrap; z-index: 1;
}

.fourn-table tbody tr {
  border-bottom: 1px solid #2a2a3a;
  border-bottom: 1px solid var(--admin-border, #2a2a3a);
  transition: background 0.15s;
}
.fourn-table tbody tr:hover { background: rgba(255,255,255,0.02); background: var(--admin-bg-hover, rgba(255,255,255,0.02)); }
.fourn-table td { padding: 0.5rem 0.5rem; white-space: nowrap; }

.fourn-code-link {
  font-family: monospace; font-weight: 700; font-size: 0.85rem;
  color: #06b6d4; text-decoration: none;
}
.fourn-code-link:hover { color: #22d3ee; }

.nom-cell { display: flex; align-items: center; gap: 0.5rem; }
.nom-cell strong { font-size: 0.82rem; }

.badge-all-stopped {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 1px 6px; border-radius: 4px; font-size: 0.62rem; font-weight: 700;
  background: rgba(239, 68, 68, 0.15); color: #f87171; white-space: nowrap;
}

.adr-line { display: block; font-size: 0.78rem; color: #a0a0b0; color: var(--admin-text-muted, #a0a0b0); max-width: 200px; overflow: hidden; text-overflow: ellipsis; }
.adr-line.city { font-size: 0.72rem; color: #606070; color: var(--admin-text-muted, #606070); }

.tel-link {
  display: inline-flex; align-items: center; gap: 0.25rem;
  color: #a0a0b0;
  color: var(--admin-text-muted, #a0a0b0); text-decoration: none; font-size: 0.78rem;
}
.tel-link:hover { color: #06b6d4; }

/* Sortable columns */
.col-sortable {
  cursor: pointer; -webkit-user-select: none; user-select: none; white-space: nowrap;
  transition: color 0.15s; text-align: center;
}
.col-sortable:hover { color: #06b6d4 !important; }
.col-reappro-head { font-size: 0.9rem; }
.sort-icon-active { color: #06b6d4; font-size: 0.85rem; vertical-align: middle; margin-left: 2px; }

/* Numeric columns */
.col-num { text-align: center; font-size: 0.78rem; padding: 0.5rem 0.3rem; }
.col-stats { padding: 0.5rem 0.5rem; min-width: 130px; }

.num-actif { color: #10b981; font-weight: 600; }
.num-deprecie { color: #505060; }
.num-deprecie.has { color: #f59e0b; font-weight: 600; }
.num-arrete { color: #505060; }
.num-arrete.has { color: #ef4444; font-weight: 600; }
.num-reappro { color: #505060; }
.num-reappro.has { color: #a78bfa; font-weight: 700; }
.num-value { color: #06b6d4; font-size: 0.73rem; font-weight: 600; white-space: nowrap; }
.no-articles { color: #404050; font-size: 0.73rem; }
.stats-loading { color: #404050; font-size: 0.73rem; }

/* Mini stacked bar */
.mini-stats-bar {
  display: flex; height: 10px; background: #1a1a25; border-radius: 5px;
  overflow: hidden; position: relative; min-width: 80px;
}
.mini-segment { height: 100%; transition: width 0.3s ease; min-width: 0; }
.seg-actif { background: #10b981; }
.seg-deprecie { background: #f59e0b; }
.seg-arrete { background: #ef4444; }
.mini-stats-total {
  position: absolute; right: -32px; top: 50%; transform: translateY(-50%);
  font-size: 0.66rem; color: #606070; font-weight: 700; width: 30px; text-align: left;
}
.col-stats { padding-right: 2.2rem; }

/* Row health colors */
.fourn-table tbody tr.row-all-stopped {
  background: rgba(239, 68, 68, 0.06);
  border-left: 3px solid #ef4444;
}
.fourn-table tbody tr.row-all-stopped:hover { background: rgba(239, 68, 68, 0.1); }
.fourn-table tbody tr.row-all-stopped td { color: #808090; }
.fourn-table tbody tr.row-all-stopped .fourn-code-link { color: #808090; }
.fourn-table tbody tr.row-all-stopped .num-actif { color: #505060; }

.fourn-table tbody tr.row-health-bad {
  background: rgba(239, 68, 68, 0.04);
  border-left: 3px solid rgba(239, 68, 68, 0.5);
}
.fourn-table tbody tr.row-health-bad:hover { background: rgba(239, 68, 68, 0.08); }

.fourn-table tbody tr.row-health-warn {
  background: rgba(245, 158, 11, 0.04);
  border-left: 3px solid rgba(245, 158, 11, 0.5);
}
.fourn-table tbody tr.row-health-warn:hover { background: rgba(245, 158, 11, 0.08); }

/* Actions */
.col-actions { width: 40px; text-align: center; }
.btn-view {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; background: #1a1a25; background: var(--admin-bg-tertiary, #1a1a25);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a); border-radius: 6px;
  color: #606070;
  color: var(--admin-text-muted, #606070); cursor: pointer; text-decoration: none;
  transition: all 0.15s;
}
.btn-view:hover { background: rgba(6, 182, 212, 0.15); color: #06b6d4; border-color: #06b6d4; }

/* ========== PAGINATION ========== */
.pagination-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1.25rem; background: #12121a; background: var(--admin-bg-secondary, #12121a);
  border-top: 1px solid #2a2a3a;
  border-top: 1px solid var(--admin-border, #2a2a3a); flex-wrap: wrap; gap: 0.75rem;
}
.pagination-info { font-size: 0.75rem; color: #606070; color: var(--admin-text-muted, #606070); }
.pagination-controls { display: flex; align-items: center; gap: 0.5rem; }
.btn-page {
  display: inline-flex; align-items: center; gap: 0.25rem;
  padding: 0.375rem 0.75rem; background: #1a1a25; background: var(--admin-bg-tertiary, #1a1a25);
  border: 1px solid #2a2a3a;
  border: 1px solid var(--admin-border, #2a2a3a); border-radius: 6px;
  color: #f0f0f5;
  color: var(--admin-text, #f0f0f5); font-size: 0.75rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s;
}
.btn-page:hover:not(:disabled) { background: #2a2a3a; background: var(--admin-bg-hover, #2a2a3a); border-color: #06b6d4; color: #06b6d4; }
.btn-page:disabled { opacity: 0.4; cursor: not-allowed; }

/* ========== LOADING ========== */
.loading-spinner {
  width: 36px; height: 36px; border: 3px solid #2a2a3a; border: 3px solid var(--admin-border, #2a2a3a);
  border-top: 3px solid #06b6d4; border-radius: 50%; animation: spin 0.8s linear infinite;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .col-adresse { display: none; }
  .col-tel { display: none; }
}

@media (max-width: 900px) {
  .col-stats { display: none; }
  .num-value { font-size: 0.68rem; }
  .admin-fourn-header { flex-direction: column; align-items: stretch; }
  .filters-sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; z-index: 100;
    box-shadow: 2px 0 20px rgba(0,0,0,0.3);
  }
  .filters-sidebar:not(.open) { display: none; }
}
/* src/components/DemandeReapproModal.css */

.demande-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center;
  z-index: 1100; padding: 1rem; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}

.demande-modal {
  background: #12121a; border: 1px solid #2a2a3a; border-radius: 12px;
  width: 100%; max-width: 780px; max-height: 90vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}

/* Header */
.demande-modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 1rem 1.25rem; border-bottom: 1px solid #2a2a3a; background: #0f0f17;
}
.demande-modal-title { display: flex; align-items: center; gap: 0.75rem; }
.demande-modal-title svg { font-size: 1.5rem; color: #a78bfa; }
.demande-modal-title h2 { font-size: 1rem; margin: 0; color: #f0f0f5; }
.demande-modal-sub { font-size: 0.78rem; color: #606070; }
.btn-close-modal {
  background: #1a1a25; border: 1px solid #2a2a3a; color: #a0a0b0;
  width: 32px; height: 32px; border-radius: 6px; display: flex;
  align-items: center; justify-content: center; cursor: pointer;
}
.btn-close-modal:hover { background: #ef4444; color: #fff; border-color: #ef4444; }

/* Body */
.demande-modal-body { flex: 1 1; overflow-y: auto; padding: 1.25rem; }

.demande-section { margin-bottom: 1.25rem; }
.demande-label { display: block; font-size: 0.75rem; font-weight: 700; color: #a0a0b0; text-transform: uppercase; margin-bottom: 0.4rem; letter-spacing: 0.03em; }

/* Priorité */
.priorite-selector { display: flex; gap: 0.5rem; }
.priorite-btn {
  flex: 1 1; padding: 0.5rem; background: #1a1a25; border: 2px solid #2a2a3a;
  border-radius: 8px; color: #a0a0b0; font-size: 0.82rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s; text-align: center;
}
.priorite-btn:hover { border-color: #404050; }
.priorite-btn.active.prio-normal { border-color: #06b6d4; background: rgba(6,182,212,0.1); color: #06b6d4; }
.priorite-btn.active.prio-urgent { border-color: #f59e0b; background: rgba(245,158,11,0.1); color: #f59e0b; }
.priorite-btn.active.prio-critique { border-color: #ef4444; background: rgba(239,68,68,0.1); color: #ef4444; }

/* Note */
.demande-textarea {
  width: 100%; padding: 0.6rem; background: #0a0a0f; border: 1px solid #2a2a3a;
  border-radius: 8px; color: #f0f0f5; font-size: 0.85rem; resize: vertical;
  outline: none; font-family: inherit;
}
.demande-textarea:focus { border-color: #a78bfa; }
.demande-textarea::placeholder { color: #505060; }

/* Articles header */
.demande-articles-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.btn-toggle-all {
  padding: 0.25rem 0.6rem; background: #1a1a25; border: 1px solid #2a2a3a;
  border-radius: 5px; color: #a0a0b0; font-size: 0.7rem; cursor: pointer;
}
.btn-toggle-all:hover { background: #2a2a3a; color: #f0f0f5; }

/* Articles list */
.demande-articles-list { max-height: 350px; overflow-y: auto; }

.demande-article-row {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.6rem; margin-bottom: 0.4rem; background: #0a0a0f;
  border: 1px solid #2a2a3a; border-radius: 8px; transition: all 0.15s;
}
.demande-article-row.selected { border-color: rgba(139,92,246,0.3); }
.demande-article-row.deselected { opacity: 0.4; }

.demande-checkbox { accent-color: #a78bfa; width: 16px; height: 16px; cursor: pointer; flex-shrink: 0; }

.demande-article-info { flex: 1 1; min-width: 0; }
.demande-article-top { display: flex; align-items: center; gap: 0.5rem; }
.demande-nart { font-family: monospace; font-size: 0.78rem; font-weight: 700; color: #06b6d4; flex-shrink: 0; }
.demande-design { font-size: 0.8rem; color: #a0a0b0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.demande-article-stocks { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.25rem; }
.demande-stock-chip {
  font-size: 0.65rem; padding: 1px 5px; background: rgba(16,185,129,0.1);
  color: #10b981; border-radius: 3px; font-weight: 600;
}
.demande-stock-total { font-size: 0.65rem; padding: 1px 5px; background: rgba(6,182,212,0.1); color: #06b6d4; border-radius: 3px; font-weight: 600; }

/* Quantité controls */
.demande-qte-control { display: flex; align-items: center; gap: 0; flex-shrink: 0; }
.qte-btn {
  width: 28px; height: 28px; background: #1a1a25; border: 1px solid #2a2a3a;
  color: #a0a0b0; display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 0.85rem;
}
.qte-btn:first-child { border-radius: 6px 0 0 6px; }
.qte-btn:last-child { border-radius: 0 6px 6px 0; }
.qte-btn:hover:not(:disabled) { background: #2a2a3a; color: #f0f0f5; }
.qte-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.qte-input {
  width: 42px; height: 28px; text-align: center; background: #0a0a0f;
  border: 1px solid #2a2a3a; border-left: 0; border-right: 0;
  color: #f0f0f5; font-size: 0.85rem; font-weight: 700; outline: none;
  -moz-appearance: textfield;
}
.qte-input::-webkit-outer-spin-button, .qte-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.btn-remove-ligne {
  background: none; border: none; color: #505060; cursor: pointer;
  padding: 4px; font-size: 0.9rem; flex-shrink: 0;
}
.btn-remove-ligne:hover { color: #ef4444; }

.demande-empty { padding: 2rem; text-align: center; color: #505060; font-size: 0.85rem; }

/* Footer */
.demande-modal-footer {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.75rem 1.25rem; border-top: 1px solid #2a2a3a; background: #0f0f17;
  flex-wrap: wrap; gap: 0.75rem;
}
.demande-summary { display: flex; align-items: center; gap: 0.5rem; font-size: 0.78rem; color: #606070; }
.demande-summary-sep { color: #2a2a3a; }
.demande-prio-badge { padding: 2px 8px; border-radius: 4px; font-weight: 700; font-size: 0.72rem; }
.demande-prio-badge.prio-normal { background: rgba(6,182,212,0.1); color: #06b6d4; }
.demande-prio-badge.prio-urgent { background: rgba(245,158,11,0.1); color: #f59e0b; }
.demande-prio-badge.prio-critique { background: rgba(239,68,68,0.1); color: #ef4444; }

.demande-footer-actions { display: flex; gap: 0.5rem; }
.btn-cancel-demande {
  padding: 0.45rem 1rem; background: #1a1a25; border: 1px solid #2a2a3a;
  border-radius: 6px; color: #a0a0b0; font-size: 0.82rem; cursor: pointer;
}
.btn-cancel-demande:hover { background: #2a2a3a; color: #f0f0f5; }
.btn-submit-demande {
  display: flex; align-items: center; gap: 0.4rem; padding: 0.45rem 1.2rem;
  background: linear-gradient(135deg, #7c3aed, #8b5cf6); border: none;
  border-radius: 6px; color: #fff; font-size: 0.82rem; font-weight: 600; cursor: pointer;
}
.btn-submit-demande:hover { background: linear-gradient(135deg, #6d28d9, #7c3aed); }
.btn-submit-demande:disabled { opacity: 0.4; cursor: not-allowed; }

/* Responsive */
@media (max-width: 600px) {
  .demande-modal { max-width: 100%; }
  .demande-article-row { flex-wrap: wrap; }
  .demande-article-info { flex: 1 1 100%; }
  .demande-qte-control { margin-left: auto; }
  .priorite-selector { flex-wrap: wrap; }
  .demande-modal-footer { flex-direction: column; align-items: stretch; }
  .demande-footer-actions { justify-content: flex-end; }
}
/* src/screens/admin/AdminFournisseurInfosScreen.css */

.fourn-infos-page {
  min-height: 100vh;
  background: #0a0a0f;
  color: #f0f0f5;
  display: flex;
  flex-direction: column;
}

/* HEADER */
.fourn-infos-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: #12121a;
  border-bottom: 1px solid #2a2a3a;
}
.header-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.btn-back {
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-back:hover {
  background: #2a2a3a;
}
.header-title {
  display: flex;
  align-items: center;
}
.header-icon.small {
  width: 40px;
  height: 40px;
  background: #0891b2;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-right: 0.75rem;
  flex-shrink: 0;
}
.header-title h1 {
  font-size: 1.3rem;
  margin: 0;
  color: #f0f0f5;
}
.header-subtitle {
  color: white !important;
  font-size: 1.2rem !important;
}
.header-actions {
  display: flex;
  gap: 0.5rem;
}
.btn-action {
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-action:hover {
  background: #2a2a3a;
}

/* CONTENT */
.fourn-infos-content {
  flex: 1 1;
  padding: 1.5rem;
  overflow-y: auto;
}

/* ============================================
   LAYOUT 3 COLONNES
   ============================================ */
.fourn-main-grid.three-cols {
  display: grid;
  grid-template-columns: 340px 1fr 380px;
  grid-gap: 1.25rem;
  gap: 1.25rem;
}

/* Fallback ancien layout 2 colonnes (ne pas casser si quelqu'un utilise encore l'ancienne classe) */
.fourn-main-grid:not(.three-cols) {
  display: grid;
  grid-template-columns: 380px 1fr;
  grid-gap: 1.5rem;
  gap: 1.5rem;
}

/* Colonnes */
.fourn-left-col {
  min-width: 0;
}
.fourn-middle-col {
  min-width: 0;
  overflow: hidden;
}
.fourn-right-col {
  min-width: 0;
}

/* CARDS */
.fourn-card {
  background: #12121a;
  border: 1px solid #2a2a3a;
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.fourn-card h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  color: #06b6d4;
  margin: 0 0 1rem 0;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #2a2a3a;
}

/* INFO */
.info-grid-2cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.75rem;
  gap: 0.75rem;
}
.mt-1 {
  margin-top: 1rem;
}
.info-item label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  color: #606070;
  margin-bottom: 0.2rem;
}
.label-icon {
  margin-right: 4px;
  opacity: 0.7;
}
.info-item span,
.info-item a {
  display: block;
  font-size: 0.9rem;
  color: #f0f0f5;
  text-decoration: none;
}
.info-item a:hover {
  color: #06b6d4;
}
.observations p {
  font-size: 0.9rem;
  line-height: 1.5;
  color: #a0a0b0;
  white-space: pre-wrap;
}

/* STATS */
.stats-overview-card {
  border-left: 4px solid #06b6d4;
}
.stats-trio {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-gap: 0.75rem;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.stat-block {
  text-align: center;
  padding: 0.75rem 0.5rem;
  border-radius: 8px;
  cursor: pointer;
  transition:
    background 0.2s,
    transform 0.15s;
  border: 1px solid transparent;
}
.stat-block:hover {
  transform: translateY(-2px);
}
.stat-block.stat-actif {
  background: rgba(16, 185, 129, 0.08);
  border-color: rgba(16, 185, 129, 0.2);
}
.stat-block.stat-actif:hover {
  background: rgba(16, 185, 129, 0.15);
}
.stat-block.stat-deprecie {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.2);
}
.stat-block.stat-deprecie:hover {
  background: rgba(245, 158, 11, 0.15);
}
.stat-block.stat-arrete {
  background: rgba(239, 68, 68, 0.08);
  border-color: rgba(239, 68, 68, 0.2);
}
.stat-block.stat-arrete:hover {
  background: rgba(239, 68, 68, 0.15);
}
.stat-number {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.25rem;
}
.stat-actif .stat-number {
  color: #10b981;
}
.stat-deprecie .stat-number {
  color: #f59e0b;
}
.stat-arrete .stat-number {
  color: #ef4444;
}
.stat-label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  font-weight: 600;
  color: #a0a0b0;
}
.stat-value-stock {
  font-size: 0.68rem;
  font-weight: 600;
  color: #06b6d4;
  margin-top: 4px;
  padding: 2px 6px;
  background: rgba(6, 182, 212, 0.1);
  border-radius: 4px;
  display: inline-block;
}
.stat-value-stock.risk {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.1);
}
.stat-value-stock.muted {
  color: #606070;
  background: rgba(255, 255, 255, 0.03);
}
.stat-bar {
  height: 4px;
  background: #1a1a25;
  border-radius: 2px;
  margin-top: 0.5rem;
  overflow: hidden;
}
.stat-bar-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.5s ease;
}
.stat-bar-fill.actif {
  background: #10b981;
}
.stat-bar-fill.deprecie {
  background: #f59e0b;
}
.stat-bar-fill.arrete {
  background: #ef4444;
}
.combined-bar {
  display: flex;
  height: 8px;
  background: #1a1a25;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 0.25rem;
}
.combined-segment {
  height: 100%;
  transition: width 0.5s ease;
}
.combined-segment.actif {
  background: #10b981;
}
.combined-segment.deprecie {
  background: #f59e0b;
}
.combined-segment.arrete {
  background: #ef4444;
}
.stats-total-line {
  margin-top: 0.6rem;
  font-size: 0.78rem;
  color: #606070;
  text-align: center;
  font-weight: 500;
}
.stats-total-line strong {
  color: #06b6d4;
}
.stock-value-alert {
  margin-top: 0.75rem;
  padding: 0.6rem 0.75rem;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.stock-value-alert-label {
  font-size: 0.75rem;
  color: #a0a0b0;
}
.stock-value-alert-amount {
  font-size: 0.9rem;
  font-weight: 700;
  color: #f59e0b;
}

/* Réappro alert dans stats */
.reappro-alert {
  margin-top: 0.6rem;
  padding: 0.5rem 0.75rem;
  background: rgba(139, 92, 246, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: background 0.15s;
  font-size: 0.8rem;
  color: #a78bfa;
}
.reappro-alert:hover {
  background: rgba(139, 92, 246, 0.15);
}
.reappro-alert strong {
  color: #c4b5fd;
}

/* ARTICLES */
.articles-section {
  display: flex;
  flex-direction: column;
}
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0;
}
.section-header h3 {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
  border-bottom: none !important;
}
.section-header-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.badge {
  background: #3d4344;
  color: #fff;
  padding: 0.2rem 0.8rem;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 800;
}

/* Export dropdown */
.export-dropdown {
  position: relative;
}
.btn-export {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 6px;
  color: #a0a0b0;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-export:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}
.export-menu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 280px;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  padding: 0.35rem;
  z-index: 100;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.export-dropdown:hover .export-menu,
.export-dropdown:focus-within .export-menu {
  display: block;
}
.export-menu button {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.75rem;
  background: none;
  border: none;
  color: #a0a0b0;
  font-size: 0.8rem;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.15s;
}
.export-menu button:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}
.export-sep {
  height: 1px;
  background: #2a2a3a;
  margin: 0.25rem 0;
}

/* TABS */
.articles-tabs {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
  padding: 0.3rem;
  background: #0a0a0f;
  border-radius: 10px;
  border: 1px solid #2a2a3a;
}
.tab-btn {
  flex: 1 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  padding: 0.5rem 0.5rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #606070;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.tab-btn:hover {
  color: #a0a0b0;
  background: rgba(255, 255, 255, 0.03);
}
.tab-btn .tab-icon {
  display: flex;
  align-items: center;
  font-size: 0.95rem;
}
.tab-btn .tab-count {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 10px;
  background: #1a1a25;
  color: #606070;
  min-width: 20px;
  text-align: center;
}
.tab-btn.active.tab-actif {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.3);
  color: #10b981;
}
.tab-btn.active.tab-actif .tab-count {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
}
.tab-btn.active.tab-deprecie {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
  color: #f59e0b;
}
.tab-btn.active.tab-deprecie .tab-count {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
}
.tab-btn.active.tab-arrete {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}
.tab-btn.active.tab-arrete .tab-count {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}
.tab-btn.active.tab-reappro {
  background: rgba(139, 92, 246, 0.12);
  border-color: rgba(139, 92, 246, 0.3);
  color: #a78bfa;
}
.tab-btn.active.tab-reappro .tab-count {
  background: rgba(139, 92, 246, 0.2);
  color: #a78bfa;
}

/* Réappro banner */
.reappro-info-banner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.75rem;
  margin-bottom: 0.75rem;
  background: rgba(139, 92, 246, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 8px;
  font-size: 0.8rem;
  color: #a78bfa;
}
.reappro-info-banner strong {
  color: #c4b5fd;
}

/* SEARCH */
.search-bar {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 0.75rem;
}
.search-bar .search-icon {
  position: absolute;
  left: 10px;
  color: #606070;
  font-size: 1rem;
  pointer-events: none;
}
.search-bar input {
  width: 100%;
  padding: 0.55rem 0.75rem 0.55rem 2.2rem;
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  color: #f0f0f5;
  font-size: 0.85rem;
  outline: none;
  transition: border-color 0.2s;
}
.search-bar input::placeholder {
  color: #505060;
}
.search-bar input:focus {
  border-color: #06b6d4;
}
.search-clear {
  position: absolute;
  right: 80px;
  background: none;
  border: none;
  color: #606070;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
}
.search-clear:hover {
  color: #f0f0f5;
}
.search-count {
  position: absolute;
  right: 10px;
  font-size: 0.72rem;
  color: #606070;
  white-space: nowrap;
}
.btn-clear-search {
  margin-top: 0.75rem;
  padding: 0.4rem 1rem;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 6px;
  color: #a0a0b0;
  font-size: 0.82rem;
  cursor: pointer;
}
.btn-clear-search:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}

/* CMD search bar — ajuster le bouton clear */
.cmd-search-bar .search-clear {
  right: 10px;
}

/* TABLE */
.linked-articles-table {
  width: 100%;
  border-collapse: collapse;
}
.linked-articles-table th {
  text-align: left;
  font-size: 0.68rem;
  text-transform: uppercase;
  color: #606070;
  padding: 0.45rem 0.35rem;
  border-bottom: 1px solid #2a2a3a;
  white-space: nowrap;
}
.linked-articles-table td {
  padding: 0.45rem 0.35rem;
  border-bottom: 1px solid #1a1a25;
  font-size: 0.8rem;
}
.text-right {
  text-align: right;
}
.text-center {
  text-align: center;
}

.link-nart {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  color: #06b6d4;
  font-family: monospace;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.76rem;
}
.link-nart svg {
  font-size: 0.65rem;
  opacity: 0;
  transition: opacity 0.2s;
}
.link-nart:hover svg {
  opacity: 1;
}

.cell-design {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.mini-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 4px;
  border-radius: 3px;
  font-size: 0.6rem;
}
.mini-badge.promo {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}
.mini-badge.reappro {
  background: rgba(139, 92, 246, 0.15);
  color: #a78bfa;
}

.stock-s1 {
  font-family: monospace;
  font-size: 0.8rem;
}
.stock-s1.positive {
  color: #10b981;
}
.stock-s1.zero {
  color: #606070;
}
.val-stock {
  font-size: 0.76rem;
  font-family: monospace;
  color: #a0a0b0;
}
.val-stock.zero {
  color: #404050;
}

/* Rows */
.linked-articles-table tbody tr.row-deprecie {
  background: rgba(245, 158, 11, 0.05);
}
.linked-articles-table tbody tr.row-deprecie:hover {
  background: rgba(245, 158, 11, 0.1);
}
.linked-articles-table tbody tr.row-arrete {
  background: rgba(239, 68, 68, 0.04);
}
.linked-articles-table tbody tr.row-arrete:hover {
  background: rgba(239, 68, 68, 0.08);
}
.linked-articles-table tbody tr.row-arrete td {
  color: #808090;
}
.linked-articles-table tbody tr.row-arrete .link-nart {
  color: #808090;
}
.linked-articles-table tbody tr.row-actif:hover {
  background: rgba(255, 255, 255, 0.02);
}
.linked-articles-table tbody tr.row-needs-reappro {
  border-left: 3px solid #8b5cf6;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 0.64rem;
  font-weight: 600;
  white-space: nowrap;
}
.status-badge.status-actif {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}
.status-badge.status-deprecie {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}
.status-badge.status-arrete {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.col-actions {
  width: 36px;
  text-align: center;
}
.btn-view-art {
  background: none;
  border: 1px solid #2a2a3a;
  color: #606070;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.85rem;
}
.btn-view-art:hover {
  background: #2a2a3a;
  color: #06b6d4;
  border-color: #06b6d4;
}

/* Stock tooltip */
.stock-cell {
  position: relative;
}
.stock-value-num {
  cursor: default;
}
.stock-tooltip {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  min-width: 200px;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  z-index: 50;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}
.stock-cell:hover .stock-tooltip {
  display: block;
}
.stock-tooltip-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  color: #606070;
  margin-bottom: 0.4rem;
  font-weight: 600;
}
.stock-tooltip-row {
  display: flex;
  justify-content: space-between;
  padding: 0.2rem 0;
  font-size: 0.8rem;
  color: #606070;
}
.stock-tooltip-row.has-stock {
  color: #f0f0f5;
}
.stock-tooltip-qty {
  font-weight: 600;
  font-family: monospace;
}
.stock-tooltip-total {
  display: flex;
  justify-content: space-between;
  padding-top: 0.35rem;
  margin-top: 0.35rem;
  border-top: 1px solid #2a2a3a;
  font-size: 0.8rem;
  font-weight: 700;
  color: #06b6d4;
}

/* PAGINATION */
.pagination-mini {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #2a2a3a;
}
.pagination-mini button {
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: background 0.2s;
}
.pagination-mini button:hover:not(:disabled) {
  background: #2a2a3a;
}
.pagination-mini button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}
.pagination-mini span {
  font-size: 0.85rem;
  color: #a0a0b0;
}
.pagination-total {
  margin-left: 0.4rem;
  color: #606070;
  font-size: 0.78rem;
}

/* LOADING */
.loading-inline {
  display: flex;
  justify-content: center;
  padding: 2rem;
}
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #2a2a3a;
  border-top-color: #06b6d4;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.loading-spinner.small {
  width: 24px;
  height: 24px;
  border-width: 2px;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.empty-state-mini {
  padding: 3rem 2rem;
  text-align: center;
  color: #606070;
}
.empty-icon {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  opacity: 0.4;
}
.empty-state-mini p {
  font-size: 0.9rem;
}
.error-state {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50vh;
  color: #f87171;
  font-size: 1.1rem;
}

/* NOTES */
.notes-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.note-item {
  font-size: 0.85rem;
  color: #a0a0b0;
  padding: 0.5rem;
  background: #0a0a0f;
  border-radius: 4px;
  border-left: 2px solid #2a2a3a;
}

/* ============================================
   COLONNE COMMANDES — LISTE CARTES
   ============================================ */

.commandes-section {
  display: flex;
  flex-direction: column;
}

.cmd-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: calc(100vh - 280px);
  overflow-y: auto;
  padding-right: 4px;
}

/* Scrollbar fine */
.cmd-list::-webkit-scrollbar {
  width: 4px;
}
.cmd-list::-webkit-scrollbar-track {
  background: transparent;
}
.cmd-list::-webkit-scrollbar-thumb {
  background: #2a2a3a;
  border-radius: 4px;
}
.cmd-list::-webkit-scrollbar-thumb:hover {
  background: #3a3a4a;
}

.cmd-card {
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
.cmd-card:hover {
  background: #141420;
  border-color: #06b6d4;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.1);
}
.cmd-card.cmd-verrouille {
  border-left: 3px solid #10b981;
}

.cmd-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.cmd-numcde {
  font-family: monospace;
  font-weight: 700;
  font-size: 0.88rem;
  color: #06b6d4;
}

.cmd-etat {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.64rem;
  font-weight: 700;
  border: 1px solid;
  white-space: nowrap;
}

.cmd-card-info {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  font-size: 0.76rem;
  color: #a0a0b0;
}

.cmd-date {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: #808090;
}
.cmd-date svg {
  font-size: 0.85rem;
}

.cmd-montant-badge {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  font-weight: 700;
  color: #06b6d4;
}
.cmd-montant-badge svg {
  font-size: 0.8rem;
}

.cmd-nb-lignes {
  font-size: 0.7rem;
  color: #606070;
  padding: 1px 5px;
  background: #1a1a25;
  border-radius: 4px;
}

.cmd-card-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.35rem;
  flex-wrap: wrap;
}

.cmd-meta-item {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.72rem;
  color: #707080;
}
.cmd-meta-item svg {
  font-size: 0.8rem;
}

.cmd-card-observ {
  margin-top: 0.35rem;
  font-size: 0.72rem;
  color: #505060;
  font-style: italic;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ============================================
   MODAL DÉTAIL COMMANDE
   ============================================ */

.commande-detail-modal {
  background: #12121a;
  border: 1px solid #2a2a3a;
  border-radius: 12px;
  width: 100%;
  max-width: 950px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.cmd-modal-resume {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.cmd-resume-item {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.cmd-resume-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  color: #606070;
  font-weight: 600;
}

.cmd-resume-value {
  font-size: 0.9rem;
  font-weight: 700;
  color: #f0f0f5;
}

.cmd-resume-value.highlight {
  color: #06b6d4;
  font-size: 1rem;
}

.cmd-modal-table-wrap {
  overflow-x: auto;
  overflow-y: auto;
  max-height: 55vh;
}

.cmd-modal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.cmd-modal-table thead th {
  position: sticky;
  top: 0;
  background: #1a1a25;
  padding: 0.5rem 0.4rem;
  text-align: left;
  font-size: 0.66rem;
  text-transform: uppercase;
  color: #606070;
  font-weight: 700;
  border-bottom: 1px solid #2a2a3a;
  white-space: nowrap;
}

.cmd-modal-table tbody td {
  padding: 0.4rem 0.4rem;
  border-bottom: 1px solid #1a1a25;
  color: #c0c0d0;
}

.cmd-modal-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.cmd-modal-table tbody tr.row-pointee {
  background: rgba(16, 185, 129, 0.04);
}

.col-nl {
  font-family: monospace;
  font-size: 0.7rem;
  color: #606070;
  font-weight: 600;
}

.col-design-cmd {
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cmd-montant {
  font-weight: 700;
  color: #06b6d4;
}

.from-art-badge {
  display: inline-block;
  margin-left: 4px;
  padding: 0 3px;
  font-size: 0.55rem;
  font-weight: 700;
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
  border-radius: 3px;
  vertical-align: middle;
}

.pointe-icon {
  font-size: 0.9rem;
}
.pointe-icon.yes {
  color: #10b981;
}
.pointe-icon.no {
  color: #404050;
  font-size: 0.8rem;
}

.cmd-modal-error {
  text-align: center;
  padding: 2rem;
  color: #f87171;
  font-size: 0.9rem;
}

.cmd-modal-empty {
  text-align: center;
  padding: 2rem;
  color: #606070;
  font-size: 0.85rem;
}

/* ============================================
   EXPORT MODAL
   ============================================ */
.export-modal {
  background: #12121a;
  border: 1px solid #2a2a3a;
  border-radius: 12px;
  width: 100%;
  max-width: 720px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}
.export-modal-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 1rem 1.25rem;
}
.export-scope-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.export-scope-label {
  font-size: 0.78rem;
  color: #606070;
  font-weight: 600;
  margin-right: 0.25rem;
}
.export-scope-btn {
  padding: 0.35rem 0.7rem;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 6px;
  color: #a0a0b0;
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.15s;
}
.export-scope-btn:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}
.export-scope-btn.active {
  background: #0891b2;
  border-color: #0891b2;
  color: #fff;
}
.export-actions-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #2a2a3a;
  flex-wrap: wrap;
}
.btn-select-all,
.btn-select-none,
.btn-select-default {
  padding: 0.3rem 0.6rem;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 5px;
  color: #a0a0b0;
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.15s;
}
.btn-select-all:hover,
.btn-select-none:hover,
.btn-select-default:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}
.export-field-count {
  margin-left: auto;
  font-size: 0.72rem;
  color: #606070;
}
.export-fields-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.75rem;
  gap: 0.75rem;
}
.export-field-group {
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  overflow: hidden;
}
.export-group-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.65rem;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid #1a1a25;
}
.export-group-header:hover {
  background: rgba(255, 255, 255, 0.02);
}
.group-checkbox {
  accent-color: #06b6d4;
  width: 14px;
  height: 14px;
  cursor: pointer;
}
.export-group-name {
  font-size: 0.76rem;
  font-weight: 700;
  color: #a0a0b0;
  flex: 1 1;
}
.export-group-count {
  font-size: 0.68rem;
  color: #606070;
  background: #1a1a25;
  padding: 1px 6px;
  border-radius: 8px;
}
.export-group-fields {
  padding: 0.35rem 0.5rem;
}
.export-field-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.22rem 0.35rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.1s;
  font-size: 0.76rem;
  color: #606070;
}
.export-field-item:hover {
  background: rgba(255, 255, 255, 0.03);
}
.export-field-item.selected {
  color: #f0f0f5;
}
.export-field-item input {
  accent-color: #06b6d4;
  width: 13px;
  height: 13px;
  cursor: pointer;
}
.field-label {
  -webkit-user-select: none;
          user-select: none;
  font-family: monospace;
  font-size: 0.74rem;
}
.export-modal-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  border-top: 1px solid #2a2a3a;
  background: #0f0f17;
}
.btn-cancel {
  padding: 0.45rem 1rem;
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  border-radius: 6px;
  color: #a0a0b0;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.15s;
}
.btn-cancel:hover {
  background: #2a2a3a;
  color: #f0f0f5;
}
.btn-do-export {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1.2rem;
  background: #0891b2;
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-do-export:hover {
  background: #06b6d4;
}
.btn-do-export:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ============================================
   ARTICLE DETAIL MODAL
   ============================================ */
.article-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
}
.article-modal {
  background: #12121a;
  border: 1px solid #2a2a3a;
  border-radius: 12px;
  width: 100%;
  max-width: 820px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #2a2a3a;
  background: #0f0f17;
}
.modal-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.modal-title svg {
  font-size: 1.5rem;
  color: #06b6d4;
}
.modal-title h2 {
  font-size: 1rem;
  margin: 0;
  color: #f0f0f5;
}
.modal-nart {
  font-size: 0.82rem;
  color: #606070;
  font-family: monospace;
}
.modal-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.btn-view-full {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.8rem;
  background: #0891b2;
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-view-full:hover {
  background: #06b6d4;
}
.btn-close-modal {
  background: #1a1a25;
  border: 1px solid #2a2a3a;
  color: #a0a0b0;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-close-modal:hover {
  background: #ef4444;
  color: #fff;
  border-color: #ef4444;
}
.modal-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.25rem;
}
.modal-grid {
  display: grid;
  grid-template-columns: 200px 1fr;
  grid-gap: 1.25rem;
  gap: 1.25rem;
}

.modal-photo-section {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.photo-wrapper {
  width: 100%;
  aspect-ratio: 1;
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.photo-wrapper img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.3s;
}
.photo-wrapper.loaded img {
  opacity: 1;
}
.photo-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.no-photo {
  width: 100%;
  aspect-ratio: 1;
  background: #0a0a0f;
  border: 1px solid #2a2a3a;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: #404050;
}
.no-photo svg {
  font-size: 2rem;
}
.no-photo span {
  font-size: 0.75rem;
}
.modal-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.modal-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 700;
}
.modal-badge.promo {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}
.modal-badge.deprec-stock {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}
.modal-badge.arrete {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}
.modal-badge.web {
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
}
.modal-badge.reappro-badge {
  background: rgba(139, 92, 246, 0.15);
  color: #a78bfa;
}

.modal-info-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.info-block {
  background: #0a0a0f;
  border-radius: 8px;
  padding: 0.75rem 1rem;
}
.info-block h3 {
  font-size: 1.1rem;
  margin: 0;
  color: #f0f0f5;
}
.info-block p {
  font-size: 0.85rem;
  color: #a0a0b0;
  margin: 0.25rem 0 0 0;
}
.info-block h4 {
  font-size: 0.82rem;
  margin: 0 0 0.6rem 0;
  color: #06b6d4;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.arrete-banner,
.deprec-stock-banner,
.reappro-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  border-radius: 8px;
  font-size: 0.82rem;
}
.arrete-banner {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
}
.deprec-stock-banner {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.25);
  color: #fbbf24;
}
.reappro-banner {
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.25);
  color: #a78bfa;
}
.arrete-banner svg,
.deprec-stock-banner svg,
.reappro-banner svg {
  font-size: 1.4rem;
  flex-shrink: 0;
}
.arrete-banner strong,
.deprec-stock-banner strong,
.reappro-banner strong {
  display: block;
  font-size: 0.85rem;
}
.arrete-banner span,
.deprec-stock-banner span,
.reappro-banner span {
  display: block;
  font-size: 0.75rem;
  opacity: 0.8;
}

.codes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.codes-grid .info-item {
  background: #12121a;
  padding: 0.5rem;
  border-radius: 6px;
}
.codes-grid .value.highlight {
  color: #06b6d4;
  font-weight: 700;
  font-family: monospace;
}
.codes-grid .value.mono {
  font-family: monospace;
  font-size: 0.82rem;
}
.codes-grid .value.tag {
  display: inline-block;
  padding: 1px 8px;
  background: rgba(6, 182, 212, 0.1);
  border-radius: 4px;
  color: #22d3ee;
  font-size: 0.82rem;
}

.price-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.price-item {
  text-align: center;
}
.price-item label {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  color: #606070;
  margin-bottom: 2px;
  font-family: monospace;
}
.price-item span {
  font-size: 0.9rem;
  color: #f0f0f5;
  font-weight: 600;
}
.price-item.main span {
  color: #06b6d4;
  font-size: 1rem;
}
.price-item.promo-price span {
  color: #10b981;
  font-size: 1rem;
}
.strikethrough {
  text-decoration: line-through;
  opacity: 0.5;
}

.stock-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.stock-item {
  text-align: center;
  padding: 0.35rem;
  background: #12121a;
  border-radius: 6px;
}
.stock-item label {
  display: block;
  font-size: 0.65rem;
  text-transform: uppercase;
  color: #606070;
  margin-bottom: 2px;
}
.stock-item span {
  font-size: 0.9rem;
  font-weight: 600;
  color: #a0a0b0;
}
.stock-item span.positive {
  color: #10b981;
}
.stock-item span.zero {
  color: #404050;
}
.stock-item span.reserved {
  color: #f59e0b;
}
.stock-item.total {
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.2);
}
.stock-item.total span {
  color: #06b6d4;
}
.stock-item.stock-item-alert {
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.3);
}
.stock-value-line {
  margin-top: 0.6rem;
  font-size: 0.78rem;
  color: #606070;
  text-align: right;
}
.stock-value-line strong {
  color: #06b6d4;
}

.gisement-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.gisement-item {
  padding: 0.35rem 0.5rem;
  background: #12121a;
  border-radius: 6px;
}
.gisement-item label {
  display: block;
  font-size: 0.65rem;
  text-transform: uppercase;
  color: #606070;
  font-family: monospace;
}
.gisement-item span {
  font-size: 0.85rem;
  color: #f0f0f5;
  font-family: monospace;
}
.gisement-item.main {
  grid-column: 1 / -1;
  border: 1px solid rgba(6, 182, 212, 0.2);
}

.info-block .info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
}
.observations-text {
  font-size: 0.85rem;
  line-height: 1.5;
  color: #a0a0b0;
  white-space: pre-wrap;
  margin: 0;
}

/* DEMANDE REAPPRO BUTTONS */
.btn-demande-reappro {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.8rem;
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}
.btn-demande-reappro:hover {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
}

.btn-demande-reappro-sm {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.3rem 0.6rem;
  background: #8b5cf6;
  border: none;
  border-radius: 5px;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}
.btn-demande-reappro-sm:hover {
  background: #7c3aed;
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Large screens : 3 colonnes */
@media (max-width: 1400px) {
  .fourn-main-grid.three-cols {
    grid-template-columns: 300px 1fr 340px;
  }
}

/* Medium : stack commandes sous articles */
@media (max-width: 1100px) {
  .fourn-main-grid.three-cols {
    grid-template-columns: 300px 1fr;
  }
  .fourn-right-col {
    grid-column: 2;
  }
}

/* Small : tout empilé */
@media (max-width: 900px) {
  .fourn-main-grid.three-cols {
    grid-template-columns: 1fr;
  }
  .fourn-right-col {
    grid-column: auto;
  }
  .info-grid-2cols {
    grid-template-columns: 1fr;
  }
  .stats-trio {
    grid-template-columns: 1fr;
  }
  .articles-tabs {
    flex-wrap: wrap;
  }
  .tab-btn {
    min-width: calc(50% - 0.35rem);
    justify-content: flex-start;
  }
  .fourn-infos-content {
    padding: 1rem;
  }
  .fourn-infos-header {
    padding: 0.75rem 1rem;
  }
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  .section-header-right {
    width: 100%;
    justify-content: flex-end;
  }
  .modal-grid {
    grid-template-columns: 1fr;
  }
  .modal-photo-section {
    flex-direction: row;
    align-items: flex-start;
  }
  .photo-wrapper,
  .no-photo {
    width: 120px;
    aspect-ratio: 1;
    flex-shrink: 0;
  }
  .codes-grid,
  .price-grid {
    grid-template-columns: 1fr 1fr;
  }
  .stock-grid {
    grid-template-columns: 1fr 1fr;
  }
  .info-block .info-grid {
    grid-template-columns: 1fr 1fr;
  }
  .article-modal,
  .export-modal,
  .commande-detail-modal {
    max-width: 100%;
  }
  .export-fields-grid {
    grid-template-columns: 1fr;
  }
  .cmd-list {
    max-height: 50vh;
  }
}

/* AdminClientsScreen.css */
/* Module Clients - Accent #3b82f6 */

/* ========== PAGE LAYOUT ========== */
.admin-clients-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
}

/* ========== HEADER ========== */
.admin-clients-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
  gap: 1rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-icon.clients-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--admin-radius);
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #fff;
  flex-shrink: 0;
}

.header-title h1 {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0;
}

.header-subtitle {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
  margin: 0.125rem 0 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.entreprise-selector {
  display: flex;
  align-items: center;
  position: relative;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  padding: 0 0.625rem;
}

.entreprise-selector select {
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.5rem 1.5rem 0.5rem 0.25rem;
  outline: none;
  cursor: pointer;
  appearance: none;
  min-width: 200px;
  background-color: #363636;
}

.selector-icon { color: #3b82f6; font-size: 1.1rem; }
.selector-arrow { position: absolute; right: 0.5rem; color: var(--admin-text-muted); pointer-events: none; }

/* ========== EMPTY STATE ========== */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
}

.empty-state .empty-icon { font-size: 3rem; color: var(--admin-text-muted); opacity: 0.5; margin-bottom: 1rem; }
.empty-state h2 { font-size: 1.1rem; font-weight: 700; margin: 0 0 0.5rem; }
.empty-state p { font-size: 0.85rem; color: var(--admin-text-muted); margin: 0; }

/* ========== CONTENT LAYOUT ========== */
.admin-clients-content {
  display: flex;
  gap: 0;
  min-height: calc(100vh - 100px);
}

/* ========== SIDEBAR FILTRES ========== */
.filters-sidebar {
  width: 280px;
  background: var(--admin-bg-secondary);
  border-right: 1px solid var(--admin-border);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: var(--admin-transition);
  overflow: hidden;
}

.filters-sidebar:not(.open) { width: 0; min-width: 0; border-right: none; }

.filters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--admin-border);
}

.filters-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.85rem;
  color: #3b82f6;
}

.filters-badge {
  background: #3b82f6;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  min-width: 18px;
  text-align: center;
}

.ridet-badge {
  background: #3b82f6;
  color: #a8dae0;
  font-size: 0.65rem;
  font-weight: bolder;
  padding: 0.6rem;
  border-radius: 999px;
  min-width: 18px;
  text-align: center;
}

.ridet-badge-none {
  background: #da360d;
  color: #a8dae0;
  font-size: 0.65rem;
  font-weight: bolder;
  padding: 0.6rem;
  border-radius: 999px;
  min-width: 18px;
  text-align: center;
}

.btn-toggle-filters {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0.375rem;
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.btn-toggle-filters:hover { background: var(--admin-bg-hover); color: var(--admin-text); }

.filters-error-banner {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.625rem 1rem;
  background: rgba(239, 68, 68, 0.1);
  border-bottom: 2px solid #ef4444;
  color: #ef4444;
  font-size: 0.8rem;
  font-weight: 700;
}

.filters-error-banner small {
  font-size: 0.7rem;
  font-weight: 400;
  opacity: 0.8;
}

.filters-loading-banner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(59, 130, 246, 0.05);
  border-bottom: 1px solid var(--admin-border);
  color: var(--admin-text-muted);
  font-size: 0.75rem;
}

.filters-body { flex: 1 1; overflow-y: auto; padding: 0.5rem 0; }

.filter-section { border-bottom: 1px solid var(--admin-border); }

.section-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.625rem 1rem;
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
}

.section-header:hover { background: var(--admin-bg-hover); }
.section-header svg:last-child { margin-left: auto; color: var(--admin-text-muted); }
.section-icon { font-size: 1rem; }
.section-content { padding: 0 1rem 0.75rem; }

.filter-group { margin-bottom: 0.625rem; }

.filter-group label {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.filter-group input,
.filter-group select {
  width: 100%;
  padding: 0.5rem 0.625rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.8rem;
  outline: none;
  transition: var(--admin-transition);
}

.filter-group input:focus,
.filter-group select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.filters-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--admin-border);
}

.btn-reset {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  width: 100%;
  padding: 0.5rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-reset:hover { background: var(--admin-bg-hover); color: var(--admin-text); }

/* ========== MAIN ========== */
.clients-main { flex: 1 1; display: flex; flex-direction: column; overflow: hidden; }

/* ========== STATS BAR ========== */
.stats-bar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.75rem 1.25rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}

.stat-item { display: flex; flex-direction: column; gap: 0.125rem; }
.stat-item .stat-value { font-size: 1rem; font-weight: 800; color: var(--admin-text); }
.stat-item.primary .stat-value { color: #3b82f6; }
.stat-item .stat-label { font-size: 0.65rem; color: var(--admin-text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.stats-actions { display: flex; gap: 0.375rem; margin-left: auto; }

.btn-icon-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-icon-action:hover, .btn-icon-action.active { background: var(--admin-bg-hover); color: #3b82f6; border-color: #3b82f6; }
.btn-icon-action:disabled { opacity: 0.5; cursor: not-allowed; }

.spinning { animation: spin 1s linear infinite; }
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ========== TABLE ========== */
.clients-table-container { flex: 1 1; overflow: auto; }

.table-loading, .table-error, .table-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  text-align: center;
  color: var(--admin-text-muted);
}

.table-error svg { font-size: 2rem; color: var(--admin-danger); margin-bottom: 0.75rem; }

.clients-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }

.clients-table thead th {
  position: sticky;
  top: 0;
  background: var(--admin-bg-tertiary);
  border-bottom: 2px solid var(--admin-border);
  padding: 0.625rem 0.75rem;
  text-align: left;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--admin-text-muted);
  white-space: nowrap;
  z-index: 1;
}

.clients-table tbody tr {
  border-bottom: 1px solid var(--admin-border);
  transition: var(--admin-transition);
}

.clients-table tbody tr:hover { background: var(--admin-bg-hover); }
.clients-table td { padding: 0.5rem 0.75rem; white-space: nowrap; }
.text-right { text-align: right !important; }

/* Client tiers link */
.client-tiers-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.85rem;
  color: #3b82f6;
  text-decoration: none;
  transition: var(--admin-transition);
}

.client-tiers-link:hover { color: #2563eb; }
.client-tiers-link .link-icon { font-size: 0.7rem; opacity: 0; transition: var(--admin-transition); }
.client-tiers-link:hover .link-icon { opacity: 1; }

.nom-text, .boncde-text { display: inline-block; max-width: 150px; overflow: hidden; text-overflow: ellipsis; font-size: 0.8rem; }
.ad-text { display: inline-block; max-width: 150px; overflow: hidden; text-overflow: ellipsis; font-size: 0.8rem; }

.montant-value { font-weight: 700; font-family: "Monaco", "Consolas", monospace; font-size: 0.8rem; }

/* Type badge in table cell */
.type-badge-cell {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.5rem;
  background: rgba(168, 85, 247, 0.12);
  color: #a855f7;
  border: 1px solid rgba(168, 85, 247, 0.25);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Categorie badge in table cell */
.categorie-badge-cell {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.5rem;
  background: rgba(234, 179, 8, 0.12);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.25);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Compte badge in table cell */
.compte-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.5rem;
  background: rgba(20, 184, 166, 0.12);
  color: #14b8a6;
  border: 1px solid rgba(20, 184, 166, 0.25);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  white-space: nowrap;
}

.no-data-cell { color: var(--admin-text-muted); font-size: 0.75rem; }

/* Actions */
.actions-group { display: flex; gap: 0.25rem; }

.btn-view {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
  text-decoration: none;
}

.btn-view:hover { background: rgba(59, 130, 246, 0.15); color: #3b82f6; border-color: #3b82f6; }

/* ========== PAGINATION ========== */
.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  background: var(--admin-bg-secondary);
  border-top: 1px solid var(--admin-border);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.pagination-info { font-size: 0.75rem; color: var(--admin-text-muted); }
.pagination-controls { display: flex; align-items: center; gap: 0.5rem; }

.btn-page {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.375rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-page:hover:not(:disabled) { background: var(--admin-bg-hover); border-color: #3b82f6; color: #3b82f6; }
.btn-page:disabled { opacity: 0.4; cursor: not-allowed; }

.page-indicator { display: flex; align-items: center; gap: 0.25rem; font-size: 0.8rem; font-weight: 700; }
.current-page { color: #3b82f6; }
.total-pages { color: var(--admin-text-muted); }

/* ========== MODAL ========== */
.client-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.client-modal {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-lg);
  width: 100%;
  max-width: 640px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--admin-border);
}

.modal-title { display: flex; align-items: center; gap: 0.75rem; }
.modal-title svg { font-size: 1.5rem; color: #3b82f6; }
.modal-title h2 { font-size: 1rem; font-weight: 800; margin: 0; }
.modal-tiers { font-size: 0.75rem; color: var(--admin-text-muted); font-family: "Monaco", "Consolas", monospace; }
.modal-header-actions { display: flex; align-items: center; gap: 0.5rem; }

.btn-view-full {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border: none;
  border-radius: var(--admin-radius-sm);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-view-full:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); }

.btn-close-modal {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0.375rem;
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.btn-close-modal:hover { background: var(--admin-bg-hover); color: var(--admin-danger); }

.modal-body { flex: 1 1; overflow-y: auto; padding: 1.25rem; }
.info-block { margin-bottom: 1.25rem; }
.info-block h4 { font-size: 0.8rem; font-weight: 700; margin: 0 0 0.625rem; color: #3b82f6; }
.info-grid { display: grid; grid-template-columns: repeat(2, 1fr); grid-gap: 0.625rem; gap: 0.625rem; }

.info-item label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 0.125rem;
}

.info-item .value { font-size: 0.85rem; font-weight: 600; }
.info-item .value.highlight { color: #3b82f6; font-family: "Monaco", "Consolas", monospace; }

.montants-grid { display: grid; grid-template-columns: repeat(2, 1fr); grid-gap: 0.75rem; gap: 0.75rem; }

.montant-item {
  padding: 0.75rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  text-align: center;
}

.montant-item label { display: block; font-size: 0.65rem; font-weight: 600; text-transform: uppercase; color: var(--admin-text-muted); margin-bottom: 0.25rem; }
.montant-item span { font-size: 1rem; font-weight: 800; font-family: "Monaco", "Consolas", monospace; }
.montant-item.main span { color: #3b82f6; }

/* Tiers compta rows in modal */
.tiers-compta-list { display: flex; flex-direction: column; gap: 0.5rem; }

.tiers-compta-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  flex-wrap: wrap;
}

.tiers-compta-compte {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 800;
  font-size: 0.85rem;
  color: #14b8a6;
  background: rgba(20, 184, 166, 0.1);
  padding: 0.15rem 0.5rem;
  border-radius: var(--admin-radius-sm);
}

.tiers-compta-nom { font-size: 0.8rem; font-weight: 600; color: var(--admin-text); flex: 1 1; min-width: 100px; }
.tiers-compta-debit { font-family: "Monaco", "Consolas", monospace; font-size: 0.8rem; font-weight: 700; color: #ef4444; }
.tiers-compta-credit { font-family: "Monaco", "Consolas", monospace; font-size: 0.8rem; font-weight: 700; color: #22c55e; }

/* ========== LOADING ========== */
.admin-loading-state { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 60vh; gap: 1rem; }

.loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--admin-border);
  border-top: 3px solid #3b82f6;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .clients-table .col-compte,
  .clients-table .col-type,
  .clients-table .col-categorie {
    display: none;
  }
}

@media (max-width: 768px) {
  .admin-clients-header { flex-direction: column; align-items: stretch; }
  .filters-sidebar { position: fixed; top: 0; left: 0; bottom: 0; z-index: 100; box-shadow: 2px 0 20px rgba(0, 0, 0, 0.3); }
  .filters-sidebar:not(.open) { display: none; }
  .clients-table { font-size: 0.75rem; }
  .col-boncde, .col-montaxes, .col-repres, .col-compte, .col-type, .col-categorie { display: none; }
  .info-grid { grid-template-columns: 1fr; }
  .pagination-bar { flex-direction: column; text-align: center; }
}
/* src/screens/admin/AdminReapprosScreen.css */
.admin-reappros {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}

.admin-reappros-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-reappros-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.admin-reappros-header h1 svg {
  color: #f59e0b;
}

.admin-reappros-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Stats */
.admin-reappros-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 90px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: #f59e0b;
}

.stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
  text-align: center;
}

/* Search & Filter */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: #f59e0b;
}

.search-box svg {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 12px;
  width: 150px;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.filter-select {
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 12px;
  cursor: pointer;
  outline: none;
  max-width: 200px;
}

.filter-select:focus {
  border-color: #f59e0b;
}

/* Buttons */
.btn-primary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: #f59e0b;
  border: none;
  border-radius: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: #d97706;
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-secondary {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Table container */
.admin-reappros-table-container {
  flex: 1 1;
  overflow: auto;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

/* Table */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.admin-table th,
.admin-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.admin-table th {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.admin-table tbody tr {
  transition: background 0.2s;
}

.admin-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.admin-table tbody tr:last-child td {
  border-bottom: none;
}

/* Reappro info */
.reappro-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.reappro-avatar {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  font-size: 16px;
  border-radius: 8px;
  flex-shrink: 0;
}

.reappro-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.reappro-name {
  font-weight: 600;
  color: var(--text-primary);
}

.reappro-user {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--text-muted);
}

.reappro-user svg {
  font-size: 10px;
}

/* Cells */
.entreprise-cell,
.articles-cell,
.quantite-total-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.entreprise-cell svg {
  color: var(--accent);
  font-size: 14px;
}

.articles-cell svg {
  color: #f59e0b;
  font-size: 14px;
}

.quantite-total-cell svg {
  color: #10b981;
  font-size: 14px;
}

.articles-count {
  font-weight: 700;
  color: var(--text-primary);
}

/* Badges */
.badge {
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  white-space: nowrap;
}

.status-termine {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
}

.status-en-cours {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

.status-autre {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
}

/* Date cell */
.date-cell {
  color: var(--text-secondary);
  font-size: 11px;
}

.date-info {
  display: flex;
  align-items: center;
  gap: 6px;
}

.date-info svg {
  color: var(--text-muted);
  font-size: 12px;
}

/* Table actions */
.table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-action:hover {
  background: var(--bg-primary);
}

.btn-action.btn-view:hover {
  border-color: #f59e0b;
  color: #f59e0b;
}

.btn-action.btn-download:hover {
  border-color: #10b981;
  color: #10b981;
}

.btn-action.btn-export:hover {
  border-color: #8b5cf6;
  color: #8b5cf6;
}

.btn-action:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* No data */
.no-data {
  text-align: center;
  color: var(--text-muted);
  padding: 40px !important;
}

/* Loading / Error */
.admin-loading,
.admin-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 1 1;
  color: var(--text-muted);
  font-size: 14px;
}

.admin-error {
  color: var(--danger);
}

/* ========================================
   MODALS
   ======================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-box {
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  background: var(--bg-primary);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalSlideIn 0.3s ease;
}

.modal-box.export-modal {
  max-width: 500px;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.modal-header h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.modal-header h2 svg {
  color: #f59e0b;
}

.btn-close-modal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-close-modal:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: white;
}

.modal-content {
  flex: 1 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 20px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
}

/* Details sections */
.details-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.details-section h3 {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  grid-gap: 12px;
  gap: 12px;
}

.detail-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  background: var(--bg-secondary);
  border-radius: 6px;
}

.detail-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}

.detail-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Stats grid */
.stats-grid-small {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 12px;
  gap: 12px;
}

.stat-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px;
  background: var(--bg-secondary);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.stat-box .stat-number {
  font-size: 28px;
  font-weight: 700;
  color: #f59e0b;
}

.stat-box .stat-text {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 4px;
}

/* Lignes table */
.lignes-table-container {
  max-height: 300px;
  overflow-y: auto;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.no-lignes-msg {
  padding: 40px;
  text-align: center;
  color: var(--text-muted);
}

.lignes-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.lignes-table th,
.lignes-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.lignes-table th {
  background: var(--bg-tertiary);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
}

.lignes-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.lignes-table tbody tr:last-child td {
  border-bottom: none;
}

.code-cell {
  font-family: monospace;
  font-weight: 600;
  color: #f59e0b;
}

.designation-cell {
  color: var(--text-secondary);
  max-width: 200px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stock-cell {
  color: var(--text-muted);
  text-align: center;
}

.quantite-cell {
  font-weight: 700;
  color: #10b981;
  text-align: center;
}

/* Export field */
.export-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.export-field label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.export-field input {
  padding: 12px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
}

.export-field input:focus {
  border-color: #f59e0b;
}

.export-field small {
  font-size: 11px;
  color: var(--text-muted);
}

/* Download/Export buttons */
.btn-download-modal {
  background: #10b981;
}

.btn-download-modal:hover {
  background: #059669;
}

.btn-export-modal {
  background: #8b5cf6;
}

.btn-export-modal:hover {
  background: #7c3aed;
}

/* Responsive */
@media (max-width: 1024px) {
  .admin-reappros-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .admin-reappros-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-reappros-actions {
    width: 100%;
  }

  .search-box {
    flex: 1 1;
  }

  .search-box input {
    width: 100%;
  }

  .filter-select {
    flex: 1 1;
    max-width: none;
  }

  .admin-reappros-stats {
    width: 100%;
    grid-template-columns: repeat(2, 1fr);
  }

  .stat-card {
    flex: 1 1;
    min-width: auto;
    padding: 10px 12px;
  }

  .stat-value {
    font-size: 20px;
  }
}

@media (max-width: 768px) {
  .admin-table th:nth-child(4),
  .admin-table td:nth-child(4) {
    display: none;
  }

  .admin-table th:nth-child(6),
  .admin-table td:nth-child(6) {
    display: none;
  }

  .modal-box {
    max-height: 95vh;
  }

  .details-grid {
    grid-template-columns: 1fr;
  }

  .lignes-table th:nth-child(3),
  .lignes-table td:nth-child(3) {
    display: none;
  }
}

@media (max-width: 600px) {
  .admin-reappros-actions {
    flex-wrap: wrap;
  }

  .admin-reappros-stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .admin-table th:nth-child(3),
  .admin-table td:nth-child(3) {
    display: none;
  }

  .admin-table th:nth-child(5),
  .admin-table td:nth-child(5) {
    display: none;
  }

  .modal-backdrop {
    padding: 10px;
  }

  .modal-content {
    padding: 16px;
  }

  .modal-footer {
    flex-direction: column;
  }

  .modal-footer button {
    width: 100%;
    justify-content: center;
  }
}

/* =====================================================
   USER ARTICLE SEARCH - Mobile-First Scanner Design
   ===================================================== */

/* Variables */
:root {
  --search-primary: #6366f1;
  --search-primary-dark: #4f46e5;
  --search-primary-light: #818cf8;
  --search-success: #10b981;
  --search-success-light: #d1fae5;
  --search-danger: #ef4444;
  --search-danger-light: #fee2e2;
  --search-warning: #f59e0b;
  --search-warning-light: #fef3c7;
  --search-promo: #dc2626;
  --search-promo-light: #fef2f2;
  --search-promo-dark: #b91c1c;
  --search-bg: #f8fafc;
  --search-card: #ffffff;
  --search-border: #e2e8f0;
  --search-text: #1e293b;
  --search-text-muted: #64748b;
  --search-text-light: #94a3b8;
  --search-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --search-shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
  --search-radius: 12px;
  --search-radius-sm: 8px;
  --search-transition: all 0.2s ease;
}

/* ===== PAGE CONTAINER ===== */
.article-search-page {
  background-color: #0f0f1a;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  width: 100%;
}

.article-search-page *,
.article-search-page *::before,
.article-search-page *::after {
  box-sizing: border-box;
  max-width: 100%;
}

/* ===== LOADING / EMPTY ===== */
.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
  color: #64748b;
  color: var(--search-text-muted);
}

.loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e2e8f0;
  border: 3px solid var(--search-border);
  border-top-color: #6366f1;
  border-top-color: var(--search-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.loading-spinner.small {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  text-align: center;
  padding: 2rem;
  color: #64748b;
  color: var(--search-text-muted);
}

.empty-icon {
  font-size: 3rem;
  color: #94a3b8;
  color: var(--search-text-light);
  margin-bottom: 1rem;
}

.empty-state h2 {
  font-size: 1.25rem;
  color: #1e293b;
  color: var(--search-text);
  margin-bottom: 0.5rem;
}

/* ===== HEADER - Compact mobile-first ===== */
.search-header {
  background-color: #0f0f1a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 100;
}

.header-content {
  padding: 0.625rem 0.75rem;
  display: flex;
  align-items: center;
  flex-direction: column;

  justify-content: space-between;
  gap: 0.5rem;
}

.header-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-icon {
  font-size: 1.25rem;
  color: #6366f1;
  color: var(--search-primary);
}

.header-title h1 {
  font-size: 1rem;
  font-weight: 700;
  color: #1e293b;
  color: var(--search-text);
  margin: 0;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  background: linear-gradient(135deg, var(--search-primary), #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Entreprise Select */
.entreprise-select-wrapper {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.375rem 0.625rem;
  
}


.select-icon {
  color: #818cf8;
  color: var(--search-primary-light);
  font-size: 1rem;
  flex-shrink: 0;
}

.entreprise-select {
  border: none;
  background: transparent;
  font-size: 0.8rem;
  color: #e2e8f0;
  font-weight: 500;
  cursor: pointer;
  min-width: 0;
  max-width: 160px;
}

.entreprise-select option {
  border: none;
  background: #262627;
  font-size: 0.8rem;
  color: #dadae2;
  font-weight: 500;
  cursor: pointer;
  min-width: 0;
  max-width: 160px;
}

.entreprise-select:focus {
  outline: none;
}

/* Entreprise Chip */
.entreprise-chip {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  background: linear-gradient(135deg, #6366f1, #7c3aed);
  background: linear-gradient(135deg, var(--search-primary), #7c3aed);
  color: white;
  padding: 0.375rem 0.75rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.75rem;
}

.entreprise-chip svg {
  font-size: 0.9rem;
}

.chip-separator {
  opacity: 0.6;
}

/* ===== MAIN CONTENT ===== */
.search-main {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  padding: 0.5rem;
}

/* ===== SEARCH FORM ===== */
.search-form {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.search-input-container {
  flex: 1 1;
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
  overflow: hidden;
}

.input-icon {
  position: absolute;
  left: 0.5rem;
  font-size: 1.1rem;
  color: #818cf8;
  color: var(--search-primary-light);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 0.625rem 2rem 0.625rem 2.25rem;
  font-size: 0.95rem;
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: #f0f0f5;
  transition: all 0.2s ease;
  transition: var(--search-transition);
}

.search-input::placeholder {
  color: rgba(255, 255, 255, 0.3);
  font-size: 0.85rem;
}

.search-input:focus {
  outline: none;
  border-color: #6366f1;
  border-color: var(--search-primary);
  background: rgba(99, 102, 241, 0.08);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.clear-btn {
  position: absolute;
  right: 0.5rem;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.4);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.clear-btn:active {
  background: rgba(255, 255, 255, 0.1);
}

.search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.75rem 1rem;
  background: #6366f1;
  background: var(--search-primary);
  color: white;
  border: none;
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  min-width: 44px;
  min-height: 44px;
}

.search-btn:active:not(:disabled) {
  transform: scale(0.97);
}

.search-btn:disabled {
  opacity: 0.4;
}

.search-btn span {
  display: none;
}

.search-btn svg {
  font-size: 1.25rem;
}

/* ===== RESULTS CONTAINER ===== */
.results-container {
  flex: 1 1;
  background: #13132a;
  color: white;
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  overflow: hidden;
  min-height: 200px;
}

.result-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  gap: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
}

.result-not-found {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
}

.not-found-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  color: var(--search-danger);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.result-not-found h3 {
  font-size: 1.1rem;
  color: white;
  margin-bottom: 0.375rem;
}

.result-not-found p {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
}

.searched-code {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.3);
  margin-top: 0.5rem;
  font-family: monospace;
}

.result-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: rgba(255, 255, 255, 0.6);
  justify-content: center;
  padding: 3rem 1.5rem;
  text-align: center;
}

.placeholder-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  color: var(--search-primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 1rem;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: 0.7; }
}

.result-placeholder h3 {
  font-size: 1.1rem;
  color: white;
  margin-bottom: 0.375rem;
}

.result-placeholder p {
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.9rem;
}

/* ===== ARTICLE RESULT ===== */
.article-result {
  display: flex;
  flex-direction: column;
}

.article-result.has-promo {
  border: 2px solid #dc2626;
  border: 2px solid var(--search-promo);
}

.article-result.has-renvoi {
  border: 2px solid #f59e0b;
}

.article-result.has-renvoi.has-promo {
  border: 2px solid #dc2626;
  border: 2px solid var(--search-promo);
}

/* ===== PROMO BANNER - Compact ===== */
.promo-banner {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  background: linear-gradient(135deg, var(--search-promo), var(--search-promo-dark));
  color: white;
  padding: 0.5rem 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.promo-banner-content {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.promo-icon {
  font-size: 1.1rem;
  animation: promo-shake 0.5s ease-in-out infinite;
}

@keyframes promo-shake {
  0%, 100% { transform: rotate(-10deg); }
  50% { transform: rotate(10deg); }
}

.promo-discount {
  background: white;
  color: #dc2626;
  color: var(--search-promo);
  padding: 0.125rem 0.5rem;
  border-radius: 50px;
  font-weight: 900;
  font-size: 0.85rem;
}

.promo-end-date {
  font-size: 0.75rem;
  opacity: 0.9;
}

/* ===== RENVOI BANNER - Compact ===== */
.renvoi-banner {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  padding: 0.5rem 0.75rem;
}

.renvoi-banner-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.renvoi-icon {
  font-size: 1.1rem;
  animation: pulse-rotate 2s ease-in-out infinite;
}

@keyframes pulse-rotate {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Renvoi Details */
.renvoi-details-section {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  padding: 0.75rem;
  border-bottom: 2px dashed #f59e0b;
}

.renvoi-details {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 0.5rem;
}

.renvoi-from,
.renvoi-to {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.625rem;
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
}

.renvoi-from {
  background: white;
  border: 1.5px solid #fca5a5;
}

.renvoi-from::before { content: none; }

.renvoi-to {
  background: white;
  border: 1.5px solid #6ee7b7;
}

.renvoi-to::before { content: none; }

.renvoi-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #6b7280;
}

.renvoi-nart {
  font-size: 1rem;
  font-weight: 800;
  color: #1f2937;
  font-family: monospace;
}

.renvoi-design {
  font-size: 0.8rem;
  color: #4b5563;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.renvoi-gencod {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.7rem;
  color: #6b7280;
  font-family: monospace;
}

.renvoi-gencod svg {
  font-size: 0.8rem;
}

.renvoi-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
  font-size: 1.25rem;
  padding: 0.25rem 0;
  transform: rotate(90deg);
}

.renvoi-chain-warning {
  padding: 0.5rem;
  background: white;
  border: 1.5px solid #f59e0b;
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  font-size: 0.8rem;
  color: #92400e;
  font-weight: 600;
  text-align: center;
}

/* ===== TABS - Gros boutons tactiles ===== */
.article-tabs {
  display: flex;
  background: #1a1a2e;
  border-bottom: 1px solid #2d2d44;
}

.tab-btn {
  flex: 1 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.75rem 0.5rem;
  background: transparent;
  border: none;
  color: #8b8ba7;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  transition: var(--search-transition);
  position: relative;
  min-height: 48px;
}

.tab-btn:active {
  background: rgba(99, 102, 241, 0.15);
}

.tab-btn.active {
  color: white;
  background: rgba(99, 102, 241, 0.2);
}

.tab-btn.active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #6366f1, #a855f7);
  background: linear-gradient(90deg, var(--search-primary), #a855f7);
}

.tab-btn svg {
  font-size: 1.1rem;
}

.tab-badge {
  background: #6366f1;
  background: var(--search-primary);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 50px;
}

/* ===== ARTICLE DETAILS - Mobile layout ===== */
.article-details-container {
  display: flex;
  flex-direction: column;
}

/* Photo Section - Compact on mobile */
.article-photo-section {
  background: linear-gradient(135deg, #1e293b, #334155);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 180px;
  position: relative;
  overflow: hidden;
}

.photo-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.article-photo {
  max-width: 100%;
  max-height: 180px;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.photo-container.loaded .article-photo {
  opacity: 1;
}

.photo-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: #64748b;
  padding: 1.5rem;
}

.no-photo svg {
  font-size: 2rem;
  opacity: 0.5;
}

.no-photo span {
  font-size: 0.8rem;
}

.photo-promo-badge {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 10;
  background: #dc2626;
  background: var(--search-promo);
  color: white;
  padding: 0.375rem 0.75rem;
  border-radius: 6px;
  font-weight: 800;
  font-size: 1rem;
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.4);
}

/* ===== INFO SECTION - Dense mobile layout ===== */
.article-info-section {
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Header: codes + stock */
.article-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.article-codes {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  min-width: 0;
}

.nart-badge {
  background: linear-gradient(135deg, #6366f1, #7c3aed);
  background: linear-gradient(135deg, var(--search-primary), #7c3aed);
  color: white;
  padding: 0.325rem 0.625rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: monospace;
  letter-spacing: 0.3px;
}

.nart-badge.renvoi {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.nart-badge .badge-icon {
  font-size: 0.85rem;
}

.gencod-label {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.7rem;
  font-family: monospace;
}

.gencod-label svg {
  font-size: 0.75rem;
}

.stock-indicator {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.325rem 0.625rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.stock-indicator.in-stock {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
}

.stock-indicator.out-of-stock {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
}

.stock-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  animation: blink 1.5s ease-in-out infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* Designation */
.article-designation h2 {
  font-size: 1.1rem;
  font-weight: 700;
  color: white;
  margin: 0 0 0.125rem;
  line-height: 1.25;
}

.designation-2 {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  margin: 0;
}

/* ===== ENTREPOTS GRID - Mobile 2 colonnes ===== */
.entrepots-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
}

.info-card {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.625rem;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.info-card .info-label {
  display: block;
  font-size: 0.6rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.info-card .info-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: white;
}

.info-card .info-value.highlight {
  color: #818cf8;
  color: var(--search-primary-light);
}

.info-card .info-value.positive {
  color: #6ee7b7;
}

.info-card .info-value.zero {
  color: #fca5a5;
}

.info-card.fourn {
  grid-column: span 1;
  background: rgba(245, 158, 11, 0.1);
  border-color: rgba(245, 158, 11, 0.3);
}

.info-card.fourn .info-value {
  font-size: 0.85rem;
}

.info-card.en-commande {
  grid-column: span 1;
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
  position: relative;
}

.info-card.en-commande .info-card-icon {
  position: absolute;
  top: 0.375rem;
  right: 0.375rem;
  font-size: 0.9rem;
  color: #818cf8;
  color: var(--search-primary-light);
  opacity: 0.5;
}

.info-card.stock-total {
  grid-column: span 2;
  background: rgba(59, 130, 246, 0.1);
  border: 2px solid rgba(59, 130, 246, 0.3);
  padding: 0.75rem;
}

.info-card.stock-total .info-label {
  font-size: 0.7rem;
  color: #93c5fd;
}

.info-card.stock-total .info-value {
  font-size: 1.5rem;
  font-weight: 800;
}

/* ===== EXTRA INFO ===== */
.article-extra-info {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.extra-info-item {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.extra-label {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
}

.extra-value {
  font-size: 0.75rem;
  font-weight: 600;
  color: white;
  background: rgba(255, 255, 255, 0.08);
  padding: 0.15rem 0.375rem;
  border-radius: 4px;
}

/* ===== PRICE SECTION ===== */
.price-section {
  background: rgba(16, 185, 129, 0.08);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.75rem;
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.price-section.has-promo {
  background: rgba(220, 38, 38, 0.08);
  border: 2px solid #dc2626;
  border: 2px solid var(--search-promo);
  position: relative;
  overflow: hidden;
}

.price-section.has-promo::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #dc2626, #f87171, #dc2626);
  background: linear-gradient(90deg, var(--search-promo), #f87171, var(--search-promo));
  background-size: 200% 100%;
  animation: promo-gradient 2s linear infinite;
}

@keyframes promo-gradient {
  0% { background-position: 0% 0%; }
  100% { background-position: 200% 0%; }
}

.price-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.625rem;
  padding-bottom: 0.625rem;
  border-bottom: 1px dashed rgba(16, 185, 129, 0.3);
}

.price-main.promo {
  flex-direction: column;
  align-items: stretch;
  gap: 0.625rem;
  border-bottom: 1px dashed rgba(220, 38, 38, 0.3);
}

.price-promo-container {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.price-with-badge {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex-wrap: wrap;
}

.price-main .price-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #6ee7b7;
}

.price-section.has-promo .price-label {
  color: #fca5a5;
}

.price-main .price-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: #6ee7b7;
}

.price-value.promo-price {
  font-size: 1.75rem;
  font-weight: 900;
  color: #dc2626;
  color: var(--search-promo);
}

.discount-badge {
  background: #dc2626;
  background: var(--search-promo);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.85rem;
  animation: discount-bounce 1s ease-in-out infinite;
}

@keyframes discount-bounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

.original-price-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.price-label-small {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
}

.price-value.original-price {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.5);
}

.price-value.strikethrough {
  text-decoration: line-through;
  text-decoration-color: #dc2626;
  text-decoration-color: var(--search-promo);
  text-decoration-thickness: 2px;
}

.promo-savings {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  background: rgba(220, 38, 38, 0.1);
  border: 1.5px dashed rgba(220, 38, 38, 0.4);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.5rem;
  margin-bottom: 0.625rem;
  color: #fca5a5;
  font-weight: 700;
  font-size: 0.85rem;
}

.promo-savings svg {
  font-size: 1rem;
}

.price-details {
  display: flex;
  justify-content: space-around;
}

.price-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.125rem;
}

.price-item span:first-child {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
}

.price-item span:last-child {
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.85rem;
}

/* ===== STOCK SECTION ===== */
.stock-section h3 {
  font-size: 0.85rem;
  font-weight: 600;
  color: white;
  margin: 0 0 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.stock-grid {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.stock-card {
  flex: 1 1;
  min-width: 100px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.625rem;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.stock-card.main {
  background: rgba(59, 130, 246, 0.1);
  border-color: rgba(59, 130, 246, 0.3);
}

.stock-card.reserved {
  background: rgba(245, 158, 11, 0.1);
  border-color: rgba(245, 158, 11, 0.3);
}

.stock-card .stock-label {
  display: block;
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 0.25rem;
}

.stock-card .stock-value {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
}

.stock-card .stock-value.positive {
  color: #6ee7b7;
}

.stock-card .stock-value.zero {
  color: #fca5a5;
}

.stock-card .stock-unit {
  display: block;
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.3);
  margin-top: 0.125rem;
}

/* ===== OBSERVATIONS ===== */
.observations-section {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.625rem;
}

.observations-section h3 {
  font-size: 0.8rem;
  font-weight: 600;
  color: #fbbf24;
  margin: 0 0 0.25rem;
}

.observations-section p {
  margin: 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.8rem;
  line-height: 1.4;
}

/* ===== SELECT ENTREPRISE PROMPT ===== */
.select-entreprise-prompt {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 50vh;
  text-align: center;
  padding: 2rem;
}

.prompt-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  color: var(--search-primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.select-entreprise-prompt h2 {
  font-size: 1.25rem;
  color: white;
  margin-bottom: 0.375rem;
}

.select-entreprise-prompt p {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
}

/* ===== FILIALES TAB ===== */
.filiales-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  gap: 0.75rem;
  color: #8b8ba7;
}

.filiales-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
}

.filiales-empty-icon {
  font-size: 3rem;
  color: #4b5563;
  margin-bottom: 0.75rem;
  opacity: 0.5;
}

.filiales-empty h3 {
  font-size: 1rem;
  color: white;
  margin-bottom: 0.375rem;
}

.filiales-empty p {
  color: #8b8ba7;
  font-size: 0.8rem;
}

.filiales-content {
  padding: 0.75rem;
}

/* Filiales Summary - Compact */
.filiales-summary {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-gap: 0.5rem;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.filiales-summary-card {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  padding: 0.625rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.filiales-summary-card.total {
  background: rgba(59, 130, 246, 0.15);
  border-color: rgba(59, 130, 246, 0.3);
}

.filiales-summary-card.available {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.3);
}

.summary-icon {
  font-size: 1.25rem;
  opacity: 0.8;
}

.summary-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.125rem;
}

.summary-label {
  font-size: 0.55rem;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.summary-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: white;
}

.summary-value.positive { color: #6ee7b7; }
.summary-value.zero { color: #fca5a5; }

/* Filiales List */
.filiales-list {
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.filiales-list-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.75rem;
  margin: 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.filiales-list-title svg {
  font-size: 1rem;
  color: #818cf8;
  color: var(--search-primary-light);
}

.filiales-cards-container {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.5rem;
}

.filiale-card {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border-radius: var(--search-radius-sm);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.filiale-card.has-stock {
  border-color: rgba(16, 185, 129, 0.3);
}

.filiale-card.no-stock {
  opacity: 0.6;
  border-color: rgba(239, 68, 68, 0.2);
}

.filiale-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.625rem 0.75rem;
  background: rgba(0, 0, 0, 0.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.filiale-card-entity {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.filiale-trigramme {
  font-size: 0.9rem;
  font-weight: 700;
  color: #818cf8;
  color: var(--search-primary-light);
  font-family: monospace;
}

.filiale-nom {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
}

.filiale-card-status {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.5rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 600;
}

.filiale-card-status.in-stock {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
}

.filiale-card-status.out-of-stock {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
}

.filiale-card-status svg {
  font-size: 0.8rem;
}

.filiale-card-body {
  padding: 0.625rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.filiale-card-info {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.filiale-card-label {
  font-size: 0.6rem;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
}

.filiale-card-nart {
  font-size: 0.75rem;
  font-family: monospace;
  color: #c7d2fe;
  background: rgba(99, 102, 241, 0.15);
  padding: 0.15rem 0.375rem;
  border-radius: 3px;
}

.filiale-card-stock {
  font-size: 1.1rem;
  font-weight: 700;
}

.filiale-card-stock.positive { color: #6ee7b7; }
.filiale-card-stock.zero { color: #fca5a5; }

.filiale-card-prix {
  font-size: 0.9rem;
  font-weight: 700;
  color: #6ee7b7;
}

.filiale-card-prix.muted {
  color: rgba(255, 255, 255, 0.3);
}

.filiale-card-prix-na {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.3);
  font-style: italic;
}

/* ==========================================================
   DESKTOP OVERRIDES (min-width: 768px)
   ========================================================== */
@media (min-width: 768px) {
  .header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
  }

  .header-icon {
    font-size: 1.5rem;
  }

  .header-title h1 {
    font-size: 1.35rem;
  }

  .entreprise-select {
    max-width: 280px;
    font-size: 0.9rem;
  }

  .entreprise-chip {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
  }

  .search-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem;
  }

  .search-form {
    gap: 0.75rem;
    margin-bottom: 1rem;
    position: relative;
  }

  .search-input {
    padding: 0.875rem 3rem 0.875rem 3.25rem;
    font-size: 1.05rem;
    border-radius: 12px;
    border-radius: var(--search-radius);
  }

  .input-icon {
    font-size: 1.4rem;
    left: 1rem;
  }

  .search-btn {
    padding: 0.875rem 1.5rem;
    border-radius: 12px;
    border-radius: var(--search-radius);
  }

  .search-btn span {
    display: inline;
  }

  .results-container {
    border-radius: 12px;
    border-radius: var(--search-radius);
  }

  /* Photo + Info side by side */
  .article-details-container {
    display: grid;
    grid-template-columns: 300px 1fr;
  }

  .article-photo-section {
    height: auto;
    min-height: 400px;
  }

  .article-photo {
    max-height: 400px;
  }

  .article-info-section {
    padding: 1.5rem 2rem;
    gap: 1.25rem;
  }

  .article-designation h2 {
    font-size: 1.5rem;
  }

  /* Grid 4 colonnes desktop */
  .entrepots-info-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
  }

  .info-card.fourn {
    grid-column: span 2;
  }

  .info-card.en-commande {
    grid-column: span 2;
  }

  .info-card.stock-total {
    grid-column: span 4;
  }

  .info-card {
    padding: 0.875rem;
  }

  .info-card .info-value {
    font-size: 1.25rem;
  }

  .info-card.stock-total .info-value {
    font-size: 1.75rem;
  }

  .price-main .price-value {
    font-size: 1.75rem;
  }

  .price-value.promo-price {
    font-size: 2.25rem;
  }

  /* Filiales grid on desktop */
  .filiales-summary {
    gap: 1rem;
    margin-bottom: 1.5rem;
  }

  .filiales-summary-card {
    flex-direction: row;
    padding: 1rem;
    gap: 0.75rem;
    text-align: left;
  }

  .summary-info {
    align-items: flex-start;
  }

  .summary-label {
    font-size: 0.7rem;
  }

  .summary-value {
    font-size: 1.5rem;
  }

  .filiales-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    grid-gap: 0.75rem;
    gap: 0.75rem;
    padding: 0.75rem;
  }

  .filiale-card-body {
    padding: 0.875rem 1rem;
  }

  /* Renvoi horizontal on desktop */
  .renvoi-details {
    flex-direction: row;
    gap: 0.75rem;
  }

  .renvoi-arrow {
    transform: none;
    font-size: 1.75rem;
    padding: 0 0.5rem;
  }

  .tab-btn {
    padding: 0.875rem 1.25rem;
    font-size: 0.9rem;
  }
}

/* ===== TRÈS GRAND ÉCRAN ===== */
@media (min-width: 1200px) {
  .entrepots-info-grid {
    grid-template-columns: repeat(5, 1fr);
  }

  .info-card.fourn {
    grid-column: span 2;
  }

  .info-card.en-commande {
    grid-column: span 3;
  }

  .info-card.stock-total {
    grid-column: span 5;
  }
}
/* src/components/Admin/DemandeReaproPanel.css */

.demandes-panel { display: flex; flex-direction: column; gap: 0; flex: 1 1; }

/* Header liste */
.drp-header { display: flex; align-items: center; padding: 12px 14px; background: linear-gradient(135deg, #2e1065, #4c1d95); border-radius: 10px 10px 0 0; border: 1px solid rgba(139,92,246,0.3); border-bottom: 0; }
.drp-header h3 { display: flex; align-items: center; gap: 6px; font-size: 14px; color: #c4b5fd; margin: 0; }

.drp-list { display: flex; flex-direction: column; gap: 8px; padding: 10px; background: var(--bg-secondary); border: 1px solid var(--border); border-top: 0; border-radius: 0 0 10px 10px; }

/* Empty */
.drp-empty-panel { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 20px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 12px; text-align: center; gap: 6px; }
.drp-empty-icon { font-size: 40px; color: #10b981; opacity: 0.4; }
.drp-empty-text { font-size: 14px; color: var(--text-primary); font-weight: 600; margin: 0; }
.drp-empty-sub { font-size: 12px; color: var(--text-muted); margin: 0; }

/* Messages */
.drp-msg { padding: 8px 12px; border-radius: 8px; font-size: 13px; font-weight: 600; text-align: center; margin: 4px 0; }
.drp-msg.success { background: rgba(16,185,129,0.15); color: #059669; border: 1px solid #10b981; }
.drp-msg.error { background: rgba(239,68,68,0.15); color: #dc2626; border: 1px solid #ef4444; }

/* ═══ CARDS ═══ */
.drp-card { background: var(--bg-primary); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.drp-card.prio-border-critique { border-left: 4px solid #ef4444; }
.drp-card.prio-border-urgent { border-left: 4px solid #f59e0b; }
.drp-card.prio-border-normal { border-left: 4px solid #06b6d4; }

.drp-card-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; cursor: pointer; gap: 8px; flex-wrap: wrap; }
.drp-card-header:hover { background: rgba(255,255,255,0.02); }
.drp-card-left { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.drp-card-right { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-muted); }

.drp-prio-badge { padding: 3px 10px; border-radius: 4px; font-size: 11px; font-weight: 800; }
.drp-prio-badge.prio-critique { background: rgba(239,68,68,0.15); color: #f87171; }
.drp-prio-badge.prio-urgent { background: rgba(245,158,11,0.15); color: #fbbf24; }
.drp-prio-badge.prio-normal { background: rgba(6,182,212,0.15); color: #22d3ee; }

.drp-ref { font-family: monospace; font-size: 12px; font-weight: 700; color: #a78bfa; }
.drp-fourn { font-size: 12px; color: var(--text-muted); }
.drp-count { font-size: 12px; font-weight: 700; background: var(--bg-secondary); padding: 2px 8px; border-radius: 4px; }
.drp-date { display: flex; align-items: center; gap: 3px; font-size: 11px; }
.drp-badge-encours { font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 4px; background: rgba(139,92,246,0.15); color: #a78bfa; }

.drp-card-body { padding: 0 14px 14px; }
.drp-note-admin { display: flex; align-items: flex-start; gap: 6px; padding: 10px 12px; margin-bottom: 10px; background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.2); border-radius: 8px; font-size: 13px; color: #fbbf24; }
.drp-note-admin svg { flex-shrink: 0; margin-top: 2px; }
.drp-meta { display: flex; gap: 12px; font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.drp-meta span { display: flex; align-items: center; gap: 4px; }

.drp-articles-preview { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.drp-article-row { display: flex; align-items: center; gap: 8px; padding: 6px 10px; background: var(--bg-secondary); border-radius: 6px; }
.drp-art-nart { font-family: monospace; font-size: 12px; font-weight: 700; color: #06b6d4; flex-shrink: 0; }
.drp-art-design { font-size: 12px; color: var(--text-secondary); flex: 1 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drp-art-qte { font-size: 13px; font-weight: 800; color: #10b981; flex-shrink: 0; }

.drp-btn-prendre { display: flex; align-items: center; gap: 8px; width: 100%; padding: 14px; background: linear-gradient(135deg, #059669, #10b981); border: none; border-radius: 10px; color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; justify-content: center; }
.drp-btn-prendre:hover { background: linear-gradient(135deg, #047857, #059669); }
.drp-btn-prendre:disabled { opacity: 0.5; }
.drp-btn-reprendre { display: flex; align-items: center; gap: 8px; width: 100%; padding: 12px; background: #8b5cf6; border: none; border-radius: 10px; color: #fff; font-size: 14px; font-weight: 700; cursor: pointer; justify-content: center; }
.drp-btn-reprendre:hover { background: #7c3aed; }

/* ═══════════════════════════════════════════
   MODE GUIDÉ
   ═══════════════════════════════════════════ */

/* Header compact */
.drp-active-header { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: linear-gradient(135deg, #1e3a5f, #2d5a87); border-radius: 10px; flex-wrap: wrap; }
.drp-active-title { display: flex; align-items: center; gap: 6px; flex: 1 1; min-width: 0; }
.drp-active-progress { display: flex; align-items: center; gap: 6px; }
.drp-progress-text { font-size: 12px; font-weight: 700; color: #93c5fd; white-space: nowrap; }
.drp-progress-bar { width: 60px; height: 5px; background: rgba(255,255,255,0.15); border-radius: 3px; overflow: hidden; }
.drp-progress-fill { height: 100%; background: #10b981; border-radius: 3px; transition: width 0.3s; }
.drp-btn-relacher { padding: 5px 10px; background: transparent; border: 1px solid rgba(255,255,255,0.2); border-radius: 6px; color: #93c5fd; font-size: 11px; cursor: pointer; white-space: nowrap; }
.drp-btn-relacher:hover { background: rgba(239,68,68,0.2); border-color: #ef4444; color: #fca5a5; }

/* ─── SCAN EN HAUT — reste visible quand le clavier s'ouvre ─── */
.drp-scan-top {
  padding: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-top: 6px;
}

.drp-scan-form { display: flex; flex-direction: column; gap: 6px; }
.drp-scan-row { display: flex; gap: 6px; }
.drp-scan-input-wrap { flex: 1 1; display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: var(--bg-primary); border: 2px solid var(--border); border-radius: 10px; }
.drp-scan-input-wrap:focus-within { border-color: #10b981; }
.drp-scan-input-wrap svg { color: #10b981; font-size: 20px; flex-shrink: 0; }
.drp-scan-input-wrap input { flex: 1 1; background: transparent; border: none; outline: none; color: var(--text-primary); font-size: 16px; }
.drp-scan-ok { padding: 10px 20px; background: #10b981; border: none; border-radius: 10px; color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; }
.drp-scan-ok:hover { background: #059669; }
.drp-scan-ok:disabled { opacity: 0.4; }

.drp-scan-qte-row { display: flex; align-items: center; gap: 6px; }
.drp-scan-qte-row > span { font-size: 12px; color: var(--text-muted); font-weight: 600; }
.qte-btn { width: 34px; height: 34px; background: var(--bg-tertiary); border: 1px solid var(--border); color: var(--text-primary); display: flex; align-items: center; justify-content: center; cursor: pointer; border-radius: 8px; font-size: 14px; }
.qte-btn:hover { background: #10b981; color: #fff; }
.drp-qte-input { width: 50px; height: 34px; text-align: center; background: var(--bg-primary); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); font-size: 16px; font-weight: 700; outline: none; -moz-appearance: textfield; }
.drp-qte-input::-webkit-outer-spin-button, .drp-qte-input::-webkit-inner-spin-button { -webkit-appearance: none; }
.drp-btn-skip { display: flex; align-items: center; gap: 3px; padding: 6px 12px; background: transparent; border: 1px solid var(--border); border-radius: 8px; color: var(--text-muted); cursor: pointer; font-size: 11px; font-weight: 600; margin-left: auto; }
.drp-btn-skip:hover { background: rgba(239,68,68,0.1); border-color: #ef4444; color: #f87171; }

/* ─── ARTICLE À CHERCHER — compact mais clair ─── */
.drp-current-article {
  padding: 12px;
  background: var(--bg-secondary);
  border: 2px solid #10b981;
  border-radius: 12px;
  margin-top: 6px;
}

.drp-current-label { display: flex; align-items: center; gap: 5px; font-size: 11px; color: #10b981; font-weight: 700; text-transform: uppercase; margin-bottom: 6px; }

.drp-current-main { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.drp-current-nart { font-family: monospace; font-size: 24px; font-weight: 800; color: #06b6d4; }
.drp-current-design { font-size: 15px; color: var(--text-primary); font-weight: 600; }

.drp-current-gencod { font-size: 12px; color: var(--text-muted); font-family: monospace; margin-bottom: 6px; }

.drp-current-bottom { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.drp-current-qte { font-size: 15px; color: var(--text-primary); }
.drp-current-qte strong { color: #10b981; font-size: 20px; }
.drp-current-stocks { display: flex; flex-wrap: wrap; gap: 4px; }
.drp-stock-chip { padding: 2px 8px; background: rgba(16,185,129,0.1); color: #10b981; border-radius: 4px; font-size: 11px; font-weight: 700; }

/* All done */
.drp-all-done { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 20px; background: rgba(16,185,129,0.1); border: 2px solid #10b981; border-radius: 12px; color: #10b981; font-size: 16px; font-weight: 700; margin: 8px 0; }

/* ─── CHECKLIST ─── */
.drp-checklist { margin-top: 8px; }
.drp-checklist-title { display: flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; margin-bottom: 4px; padding: 0 4px; }
.drp-checklist-list { display: flex; flex-direction: column; gap: 3px; }

.drp-check-item { display: flex; align-items: center; gap: 8px; padding: 7px 10px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; cursor: pointer; transition: all 0.15s; }
.drp-check-item.pending:hover { border-color: #10b981; background: rgba(16,185,129,0.03); }
.drp-check-item.selected { border-color: #10b981; background: rgba(16,185,129,0.08); box-shadow: inset 3px 0 0 #10b981; }
.drp-check-item.done { opacity: 0.45; cursor: default; }
.drp-check-item.ignored { opacity: 0.3; cursor: default; }

.drp-check-status { width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; border-radius: 50%; font-size: 13px; }
.drp-check-item.done .drp-check-status { background: rgba(16,185,129,0.2); color: #10b981; }
.drp-check-item.ignored .drp-check-status { background: rgba(239,68,68,0.2); color: #ef4444; }
.drp-check-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); }
.drp-check-item.selected .drp-check-dot { background: #10b981; box-shadow: 0 0 6px rgba(16,185,129,0.5); }

.drp-check-info { flex: 1 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.drp-check-nart { font-family: monospace; font-size: 11px; font-weight: 700; color: #06b6d4; flex-shrink: 0; }
.drp-check-design { font-size: 11px; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drp-check-qte { font-size: 11px; font-weight: 700; flex-shrink: 0; }
.done-qte { color: #10b981; }
.ignored-qte { color: #ef4444; font-size: 10px; }

/* ═══ RESPONSIVE MOBILE ═══ */
@media (max-width: 480px) {
  /* Le scan reste en haut et compact */
  .drp-scan-top { padding: 8px; }
  .drp-scan-input-wrap { padding: 8px 10px; }
  .drp-scan-input-wrap input { font-size: 15px; }
  .drp-scan-ok { padding: 10px 16px; font-size: 14px; }
  .drp-scan-row { flex-direction: column; }
  .drp-scan-ok { width: 100%; text-align: center; }
  .drp-scan-qte-row { flex-wrap: wrap; }

  /* Article compact pour que ça reste visible avec le clavier */
  .drp-current-article { padding: 10px; margin-top: 4px; }
  .drp-current-main { gap: 6px; }
  .drp-current-nart { font-size: 20px; }
  .drp-current-design { font-size: 13px; }
  .drp-current-qte { font-size: 13px; }
  .drp-current-qte strong { font-size: 16px; }
  .drp-current-label { font-size: 10px; margin-bottom: 4px; }

  /* Header compact */
  .drp-active-header { padding: 6px 10px; gap: 6px; }
  .drp-progress-bar { width: 50px; }

  /* Checklist plus serrée */
  .drp-check-item { padding: 6px 8px; }
  .drp-check-info { flex-direction: column; align-items: flex-start; gap: 1px; }
  .drp-check-design { white-space: normal; font-size: 10px; }

  /* Cards */
  .drp-card-header { flex-direction: column; align-items: flex-start; gap: 6px; }
  .drp-card-right { width: 100%; justify-content: flex-start; flex-wrap: wrap; }
}

/* ═══ TRÈS PETIT ÉCRAN ═══ */
@media (max-width: 360px) {
  .drp-current-nart { font-size: 18px; }
  .drp-current-design { font-size: 12px; }
  .drp-scan-input-wrap input { font-size: 14px; }
}
/* src/screens/user/UserReappro.css */

.reappro-screen {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 900px;
  margin: 0 auto;
  padding: 8px;
  height: 100%;
  width: 100%;
  box-sizing: border-box;
  overflow-x: hidden;
}

.reappro-screen * {
  box-sizing: border-box;
  max-width: 100%;
}

/* Header */
.reappro-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.reappro-header h1 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.reappro-header h1 svg {
  color: #10b981;
}

.reappro-screen .entreprise-selector {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  flex: 1 1;
  max-width: 300px;
}

.reappro-screen .entreprise-selector svg {
  color: #10b981;
  font-size: 18px;
}

.reappro-screen .entreprise-selector select {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 13px;
  width: 100%;
  cursor: pointer;
  background-color: #1a1a2e;
}

/* Message */
.reappro-message {
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 13px;
  text-align: center;
}

.reappro-message.success {
  background: rgba(16, 185, 129, 0.15);
  color: #059669;
  border: 1px solid #10b981;
}

.reappro-message.error {
  background: rgba(244, 67, 54, 0.15);
  color: #dc2626;
  border: 1px solid #dc2626;
}

.reappro-message.warning {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  color: #92400e;
  border-left: 4px solid #f59e0b;
}

/* Placeholder / Start */
.reappro-placeholder,
.reappro-empty,
.reappro-start,
.reappro-loading {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 40px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-align: center;
}

.reappro-placeholder svg,
.reappro-empty svg,
.reappro-start svg {
  font-size: 48px;
  color: var(--text-muted);
  opacity: 0.5;
}

.reappro-screen .btn-start {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: #10b981;
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.reappro-screen .btn-start:hover {
  background: #059669;
}

/* Content */
.reappro-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 1 1;
}

/* Scan Section */
.reappro-screen .scan-section {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 10px;
}

.reappro-screen .scan-section h2 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.reappro-screen .scan-form {
  display: flex;
  gap: 12px;
}

.reappro-screen .scan-input-wrapper {
  flex: 1 1;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--bg-primary);
  border: 2px solid var(--border);
  border-radius: 10px;
}

.reappro-screen .scan-input-wrapper:focus-within {
  border-color: #10b981;
}

.reappro-screen .scan-input-wrapper svg {
  color: #10b981;
  font-size: 22px;
}

.reappro-screen .scan-input-wrapper input {
  flex: 1 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 16px;
  width: 100%;
}

.reappro-screen .scan-form button {
  padding: 12px 20px;
  background: #10b981;
  border: none;
  border-radius: 10px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.reappro-screen .scan-form button:disabled {
  opacity: 0.5;
}

/* Article Scanned */
.reappro-screen .article-scanned {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.reappro-screen .article-info {
  padding: 14px 12px;
  background: var(--bg-primary);
  border: 2px solid #10b981;
  border-radius: 10px;
}

.reappro-screen .article-info.compact {
  padding: 10px;
  border-width: 1px;
}

.reappro-screen .article-info.unknown {
  border-color: #f59e0b;
}

.reappro-screen .article-info.renvoi {
  border-left: 5px solid #f59e0b;
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
}

.reappro-screen .article-code {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 20px;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 6px;
}

.reappro-screen .article-designation {
  font-size: 16px;
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 8px;
}

.reappro-screen .article-refer,
.reappro-screen .article-gencod {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.reappro-screen .article-warning {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #dc2626;
  margin-top: 12px;
  padding: 8px 12px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  font-weight: 600;
}

/* ===== STOCKS SECTION ===== */
.stocks-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 2px solid var(--border);
}

.stocks-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  text-transform: uppercase;
}

.stocks-title svg {
  color: #10b981;
  font-size: 18px;
}

.stocks-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-gap: 8px;
  gap: 8px;
}

.stock-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 6px;
  background: #f3f4f6;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  text-align: center;
}

.stock-item.stock-positive {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border-color: #10b981;
}

.stock-item.stock-positive .stock-label {
  color: #065f46;
}

.stock-item.stock-positive .stock-value {
  color: #047857;
}

.stock-item.stock-zero {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border-color: #fecaca;
}

.stock-item.stock-zero .stock-label {
  color: #991b1b;
}

.stock-item.stock-zero .stock-value {
  color: #dc2626;
}

.stock-label {
  font-size: 9px;
  font-weight: 700;
  color: #6b7280;
  text-transform: uppercase;
  line-height: 1.2;
}

.stock-value {
  font-size: 22px;
  font-weight: 800;
  color: #374151;
}

.stock-total {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 12px;
  padding: 12px 16px;
  background: linear-gradient(135deg, #1e3a5f, #2d5a87);
  border-radius: 10px;
}

.stock-total-label {
  font-size: 12px;
  font-weight: 700;
  color: #93c5fd;
  text-transform: uppercase;
}

.stock-total-value {
  font-size: 28px;
  font-weight: 800;
  color: #fff;
}

.stock-total-value.zero {
  color: #fca5a5;
}

/* ===== RENVOI STYLES ===== */
.reappro-screen .article-renvoi-banner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  padding: 8px 14px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 12px;
}

.reappro-screen .article-renvoi-banner svg {
  animation: spin 2s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.reappro-screen .renvoi-details {
  display: flex;
  align-items: stretch;
  gap: 10px;
  margin: 12px 0;
  padding: 12px;
  background: rgba(245, 158, 11, 0.1);
  border-radius: 8px;
  border: 2px dashed #f59e0b;
}

.reappro-screen .renvoi-from,
.reappro-screen .renvoi-to {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1;
  padding: 8px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 6px;
}

.reappro-screen .renvoi-label {
  font-size: 10px;
  color: #92400e;
  font-weight: 700;
  text-transform: uppercase;
}

.reappro-screen .renvoi-nart {
  font-weight: 700;
  color: #78350f;
  font-size: 14px;
  font-family: monospace;
}

.reappro-screen .renvoi-design {
  font-size: 11px;
  color: #a16207;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reappro-screen .renvoi-gencod {
  font-size: 10px;
  color: #b45309;
}

.reappro-screen .renvoi-arrow {
  display: flex;
  align-items: center;
  color: #f59e0b;
  font-size: 24px;
}

.reappro-screen .article-final-info {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 2px solid rgba(245, 158, 11, 0.3);
}

.reappro-screen .article-final-label {
  font-size: 11px;
  font-weight: 600;
  color: #065f46;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.reappro-screen .renvoi-chain-warning {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  padding: 8px 12px;
  background: #fef3c7;
  border-radius: 6px;
  font-size: 12px;
  color: #92400e;
  font-weight: 600;
}

/* Compact styles */
.compact-renvoi-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #92400e;
  background: #fef3c7;
  padding: 4px 8px;
  border-radius: 4px;
  margin-bottom: 6px;
  font-weight: 600;
}

.compact-stocks {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* ===== CONFIRMATION BOX ===== */
.confirmation-box {
  padding: 20px;
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border: 2px solid #3b82f6;
  border-radius: 12px;
  text-align: center;
}

.confirmation-question {
  font-size: 18px;
  font-weight: 700;
  color: #1e40af;
  margin-bottom: 20px;
}

.confirmation-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.btn-yes,
.btn-no {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.btn-yes {
  background: #10b981;
  color: #fff;
}

.btn-yes:hover {
  background: #059669;
}

.btn-no {
  background: #6b7280;
  color: #fff;
}

.btn-no:hover {
  background: #4b5563;
}

/* Quantité form */
.reappro-screen .quantite-form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.reappro-screen .quantite-form label {
  font-size: 14px;
  color: var(--text-secondary);
  width: 100%;
  margin-bottom: 8px;
  font-weight: 500;
}

.reappro-screen .quantite-input-wrapper {
  display: flex;
  align-items: center;
  background: var(--bg-primary);
  border: 2px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.reappro-screen .quantite-input {
  width: 70px;
  padding: 12px 8px;
  font-size: 20px;
  font-weight: 600;
  text-align: center;
  color: var(--text-primary);
  background: transparent;
  border: none;
  outline: none;
}

.reappro-screen .quantite-btn {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border: none;
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
}

.reappro-screen .quantite-btn:hover {
  background: #10b981;
  color: #fff;
}

.reappro-screen .quantite-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.reappro-screen .btn-confirm,
.reappro-screen .btn-cancel {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.reappro-screen .btn-confirm {
  background: #10b981;
  color: #fff;
}

.reappro-screen .btn-confirm:disabled {
  opacity: 0.5;
}

.reappro-screen .btn-cancel {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.reappro-screen .btn-cancel:hover {
  background: #dc2626;
  color: #fff;
}

/* Recap Section */
.reappro-screen .recap-section {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.reappro-screen .recap-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border-bottom: 1px solid #a7f3d0;
  flex-wrap: wrap;
  gap: 8px;
}

.reappro-screen .recap-header h2 {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
  color: #065f46;
}

.reappro-screen .recap-stats {
  display: flex;
  gap: 10px;
}

.reappro-screen .recap-stats span {
  font-size: 11px;
  padding: 4px 8px;
  background: #10b981;
  color: #fff;
  border-radius: 12px;
  font-weight: 600;
}

.reappro-screen .lignes-list {
  flex: 1 1;
  overflow-y: auto;
  padding: 10px;
  max-height: 280px;
}

.reappro-screen .no-lignes {
  text-align: center;
  color: var(--text-muted);
  padding: 30px 10px;
}

.reappro-screen .ligne-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-bottom: 8px;
  gap: 8px;
}

.reappro-screen .ligne-item.renvoi {
  border-left: 3px solid #f59e0b;
  background: #fffbeb;
}

.reappro-screen .ligne-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1;
  min-width: 0;
}

.reappro-screen .ligne-main {
  display: flex;
  align-items: center;
  gap: 6px;
}

.reappro-screen .ligne-renvoi-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  background: #f59e0b;
  color: white;
  border-radius: 50%;
  font-size: 10px;
}

.reappro-screen .ligne-code {
  font-family: monospace;
  font-size: 11px;
  font-weight: 600;
  color: #10b981;
}

.reappro-screen .ligne-design {
  font-size: 11px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reappro-screen .ligne-refer,
.reappro-screen .ligne-renvoi-info,
.reappro-screen .ligne-stocks {
  margin-top: 2px;
}

.reappro-screen .ligne-refer small,
.reappro-screen .ligne-renvoi-info small,
.reappro-screen .ligne-stocks small {
  font-size: 10px;
  color: var(--text-muted);
}

.reappro-screen .ligne-actions,
.reappro-screen .ligne-edit {
  display: flex;
  align-items: center;
  gap: 6px;
}

.reappro-screen .ligne-quantite {
  font-size: 14px;
  font-weight: 700;
  min-width: 35px;
  text-align: right;
}

.reappro-screen .ligne-actions button,
.reappro-screen .ligne-edit button {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-muted);
  cursor: pointer;
}

.reappro-screen .ligne-actions button:last-child:hover {
  background: #dc2626;
  border-color: #dc2626;
  color: #fff;
}

.reappro-screen .edit-btn {
  width: 28px;
  height: 28px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}

.reappro-screen .edit-input {
  width: 50px;
  padding: 4px;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  border: 1px solid #10b981;
  border-radius: 4px;
}

/* Actions */
.reappro-actions {
  display: flex;
  gap: 10px;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
}

.btn-export {
  flex: 1 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: #10b981;
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.btn-export:disabled {
  opacity: 0.5;
}

.btn-cancel-reappro {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: transparent;
  border: 1px solid #dc2626;
  border-radius: 8px;
  color: #dc2626;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.btn-cancel-reappro:hover {
  background: #dc2626;
  color: #fff;
}

/* ===== MODAL - STYLES AMÉLIORÉS POUR PETITS ÉCRANS ===== */
.reappro-screen .modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  z-index: 1000;
  padding: 10px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.reappro-screen .modal-content {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  width: 100%;
  max-width: 450px;
  margin: 10px 0;
  max-height: calc(100vh - 20px);
  overflow-y: auto;
}

.reappro-screen .modal-content h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  margin-bottom: 8px;
}

.reappro-screen .modal-stats {
  text-align: center;
  padding: 8px;
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border-radius: 6px;
  margin-bottom: 12px;
  font-size: 13px;
}

.reappro-screen .modal-info-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-bottom: 10px;
}

.reappro-screen .modal-info-row label {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.reappro-screen .modal-info-row .modal-value {
  flex: 1 1;
  font-size: 13px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
}

.reappro-screen .modal-value.mono {
  font-family: monospace;
  font-size: 11px;
  word-break: break-all;
}

.reappro-screen .btn-edit-small {
  width: 32px;
  height: 32px;
  min-width: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  flex-shrink: 0;
}

.reappro-screen .btn-edit-small:hover {
  background: #10b981;
  color: #fff;
}

.reappro-screen .export-mode-selector {
  margin: 12px 0;
}

.reappro-screen .export-mode-selector > label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 12px;
}

.reappro-screen .export-mode-options {
  display: flex;
  gap: 8px;
}

.reappro-screen .export-mode-btn {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 8px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: white;
  cursor: pointer;
  font-size: 12px;
}

.reappro-screen .export-mode-btn.active {
  border-color: #10b981;
  background: #d1fae5;
}

.reappro-screen .export-info {
  padding: 8px 10px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 6px;
  margin: 10px 0;
  font-size: 12px;
}

/* ===== MODAL ACTIONS - TOUJOURS VISIBLE ET ACCESSIBLE ===== */
.reappro-screen .modal-actions {
  display: flex;
  gap: 10px;
  padding-top: 12px;
  margin-top: 8px;
  border-top: 1px solid var(--border);
  position: sticky;
  bottom: 0;
  background: var(--bg-primary);
  padding-bottom: 4px;
}

.reappro-screen .modal-actions .btn-confirm,
.reappro-screen .modal-actions .btn-cancel {
  flex: 1 1;
  justify-content: center;
  padding: 14px 12px;
  font-size: 14px;
  min-height: 48px;
}

/* ===== RESPONSIVE - TABLETTE ===== */
@media (max-width: 768px) {
  .reappro-header {
    flex-direction: column;
    align-items: stretch;
  }

  .reappro-screen .entreprise-selector {
    max-width: 100%;
  }

  .reappro-screen .scan-form {
    flex-direction: column;
  }

  .stocks-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .confirmation-actions {
    flex-direction: column;
  }

  .btn-yes,
  .btn-no {
    width: 100%;
    justify-content: center;
  }

  .reappro-screen .quantite-form {
    flex-direction: column;
    align-items: stretch;
  }

  .reappro-screen .quantite-actions {
    margin-left: 0;
  }

  .reappro-actions {
    flex-direction: column;
  }

  .reappro-screen .renvoi-details {
    flex-direction: column;
  }

  .reappro-screen .renvoi-arrow {
    transform: rotate(90deg);
    justify-content: center;
    padding: 8px 0;
  }

  .reappro-screen .modal-content {
    margin: 5px 0;
    padding: 14px;
  }
}

/* ===== RESPONSIVE - MOBILE ===== */
@media (max-width: 480px) {
  .reappro-screen {
    padding: 6px;
    gap: 8px;
  }

  /* ===== HEADER MOBILE - Plus compact ===== */
  .reappro-header h1 {
    font-size: 15px;
    gap: 6px;
  }

  .reappro-screen .entreprise-selector {
    padding: 8px 10px;
  }

  .reappro-screen .entreprise-selector select {
    font-size: 12px;
  }

  /* ===== SCAN SECTION MOBILE - Plus aéré et tactile ===== */
  .reappro-screen .scan-section {
    padding: 10px 8px;
    border-radius: 8px;
  }

  .reappro-screen .scan-section h2 {
    font-size: 13px;
    margin-bottom: 10px;
  }

  .reappro-screen .scan-input-wrapper {
    padding: 10px;
    gap: 8px;
    border-radius: 8px;
  }

  .reappro-screen .scan-input-wrapper input {
    font-size: 15px;
  }

  .reappro-screen .scan-form button {
    padding: 14px 20px;
    font-size: 15px;
    border-radius: 8px;
    min-height: 48px;
  }

  /* ===== ARTICLE INFO MOBILE - Condensé mais lisible ===== */
  .reappro-screen .article-info {
    padding: 10px;
    border-radius: 8px;
  }

  .reappro-screen .article-code {
    font-size: 18px;
    margin-bottom: 4px;
  }

  .reappro-screen .article-designation {
    font-size: 14px;
    margin-bottom: 6px;
  }

  .reappro-screen .article-scanned {
    gap: 10px;
  }

  /* ===== RENVOI MOBILE - Simplifié verticalement ===== */
  .reappro-screen .article-renvoi-banner {
    font-size: 12px;
    padding: 6px 10px;
    margin-bottom: 8px;
  }

  .reappro-screen .renvoi-details {
    padding: 8px;
    gap: 0;
    margin: 8px 0;
  }

  .reappro-screen .renvoi-from,
  .reappro-screen .renvoi-to {
    padding: 6px;
  }

  .reappro-screen .renvoi-nart {
    font-size: 13px;
  }

  .reappro-screen .renvoi-design {
    font-size: 10px;
  }

  .reappro-screen .renvoi-arrow {
    font-size: 18px;
    padding: 4px 0;
  }

  /* ===== STOCKS MOBILE - Grille compacte 3+2 avec valeurs lisibles ===== */
  .stocks-section {
    margin-top: 10px;
    padding-top: 10px;
  }

  .stocks-title {
    font-size: 11px;
    margin-bottom: 8px;
    gap: 6px;
  }

  .stocks-title svg {
    font-size: 14px;
  }

  .stocks-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .stock-item {
    padding: 8px 4px;
    border-radius: 8px;
    gap: 2px;
    border-width: 1.5px;
  }

  .stock-label {
    font-size: 8px;
    letter-spacing: 0.3px;
  }

  .stock-value {
    font-size: 18px;
  }

  .stock-total {
    margin-top: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    gap: 8px;
  }

  .stock-total-label {
    font-size: 10px;
  }

  .stock-total-value {
    font-size: 22px;
  }

  /* ===== CONFIRMATION MOBILE - Boutons gros et tactiles ===== */
  .confirmation-box {
    padding: 14px 10px;
    border-radius: 10px;
    border-width: 1.5px;
  }

  .confirmation-question {
    font-size: 15px;
    margin-bottom: 14px;
  }

  .confirmation-actions {
    gap: 8px;
  }

  .btn-yes,
  .btn-no {
    padding: 14px 20px;
    font-size: 15px;
    border-radius: 10px;
    min-height: 50px;
    justify-content: center;
  }

  .btn-yes {
    order: 1;
  }

  .btn-no {
    order: 2;
  }

  /* ===== QUANTITÉ MOBILE - Contrôles tactiles agrandis ===== */
  .reappro-screen .quantite-form label {
    font-size: 13px;
    margin-bottom: 6px;
  }

  .reappro-screen .quantite-input-wrapper {
    width: 100%;
    border-radius: 10px;
  }

  .reappro-screen .quantite-btn {
    width: 56px;
    height: 56px;
    font-size: 26px;
  }

  .reappro-screen .quantite-btn:active {
    background: #10b981;
    color: #fff;
  }

  .reappro-screen .quantite-input {
    width: auto;
    flex: 1 1;
    font-size: 24px;
    padding: 14px 8px;
  }

  .reappro-screen .quantite-actions {
    display: flex;
    gap: 8px;
    width: 100%;
  }

  .reappro-screen .quantite-actions .btn-confirm {
    flex: 1 1;
    justify-content: center;
    padding: 14px;
    font-size: 15px;
    min-height: 50px;
    border-radius: 10px;
  }

  .reappro-screen .quantite-actions .btn-cancel {
    padding: 14px 18px;
    font-size: 15px;
    min-height: 50px;
    border-radius: 10px;
  }

  /* ===== RECAP MOBILE - Lignes plus lisibles, boutons plus gros ===== */
  .reappro-screen .recap-header {
    padding: 10px 12px;
  }

  .reappro-screen .recap-header h2 {
    font-size: 13px;
  }

  .reappro-screen .recap-stats span {
    font-size: 10px;
    padding: 3px 7px;
  }

  .reappro-screen .lignes-list {
    padding: 8px;
    max-height: 240px;
  }

  .reappro-screen .ligne-item {
    padding: 8px;
    border-radius: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
    gap: 6px;
  }

  .reappro-screen .ligne-info {
    flex: 1 1 100%;
    min-width: 0;
  }

  .reappro-screen .ligne-main {
    gap: 4px;
  }

  .reappro-screen .ligne-code {
    font-size: 12px;
  }

  .reappro-screen .ligne-design {
    font-size: 11px;
  }

  /* Actions de ligne : quantité + boutons alignés à droite, taille tactile */
  .reappro-screen .ligne-actions {
    margin-left: auto;
    gap: 8px;
    align-items: center;
  }

  .reappro-screen .ligne-quantite {
    font-size: 16px;
    min-width: 30px;
  }

  .reappro-screen .ligne-actions button {
    width: 36px;
    height: 36px;
    border-radius: 6px;
  }

  /* Édition en ligne : contrôles pleine largeur */
  .reappro-screen .ligne-edit {
    flex: 1 1 100%;
    justify-content: center;
    gap: 6px;
  }

  .reappro-screen .edit-btn {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    font-size: 18px;
  }

  .reappro-screen .edit-input {
    width: 60px;
    font-size: 16px;
    padding: 6px;
    border-radius: 6px;
  }

  .reappro-screen .ligne-edit button {
    width: 40px;
    height: 40px;
    border-radius: 6px;
  }

  /* ===== ACTIONS BAS DE PAGE MOBILE ===== */
  .reappro-actions {
    padding: 10px 12px;
    gap: 8px;
  }

  .btn-export {
    padding: 14px;
    font-size: 14px;
    min-height: 48px;
    border-radius: 10px;
  }

  .btn-cancel-reappro {
    padding: 14px;
    font-size: 14px;
    min-height: 48px;
    border-radius: 10px;
    justify-content: center;
  }

  /* ===== MODAL MOBILE - Plein écran avec scroll ===== */
  .reappro-screen .modal-overlay {
    padding: 0;
    align-items: stretch;
  }

  .reappro-screen .modal-content {
    border-radius: 0;
    padding: 16px 12px;
    margin: 0;
    max-height: 100vh;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
  }

  .reappro-screen .modal-content h2 {
    font-size: 15px;
    margin-bottom: 10px;
  }

  .reappro-screen .modal-stats {
    padding: 8px;
    font-size: 13px;
    margin-bottom: 14px;
  }

  .reappro-screen .modal-info-row {
    padding: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
  }

  .reappro-screen .modal-info-row label {
    font-size: 12px;
  }

  .reappro-screen .modal-info-row .modal-value {
    font-size: 13px;
  }

  .reappro-screen .modal-value.mono {
    font-size: 10px;
    max-width: calc(100% - 80px);
  }

  .reappro-screen .modal-info-row.chemin-row {
    flex-wrap: wrap;
  }

  .reappro-screen .modal-info-row.chemin-row .modal-value {
    order: 3;
    width: 100%;
    margin-top: 6px;
    padding: 8px;
    background: var(--bg-primary);
    border-radius: 6px;
    font-size: 11px;
  }

  .reappro-screen .export-mode-selector {
    margin: 14px 0;
  }

  .reappro-screen .export-mode-selector > label {
    font-size: 12px;
    margin-bottom: 8px;
  }

  .reappro-screen .export-mode-options {
    gap: 8px;
  }

  .reappro-screen .export-mode-btn {
    padding: 12px 8px;
    font-size: 13px;
    gap: 4px;
    border-radius: 10px;
    min-height: 60px;
  }

  .reappro-screen .export-mode-btn svg {
    font-size: 22px;
  }

  .reappro-screen .export-info {
    padding: 10px;
    font-size: 12px;
    margin: 10px 0;
  }

  /* Boutons modal : sticky en bas, gros et accessibles */
  .reappro-screen .modal-actions {
    flex-direction: column;
    gap: 8px;
    padding-top: 12px;
    margin-top: auto;
    position: sticky;
    bottom: 0;
    background: var(--bg-primary);
    z-index: 10;
    padding-bottom: 8px;
    border-top: 2px solid var(--border);
  }

  .reappro-screen .modal-actions .btn-confirm,
  .reappro-screen .modal-actions .btn-cancel {
    width: 100%;
    padding: 16px 12px;
    font-size: 15px;
    min-height: 52px;
    border-radius: 10px;
  }

  .reappro-screen .modal-actions .btn-confirm {
    order: 1;
    background: #10b981;
  }

  .reappro-screen .modal-actions .btn-cancel {
    order: 2;
    background: #6b7280;
    color: white;
  }

  /* ===== MESSAGES MOBILE ===== */
  .reappro-message {
    padding: 10px 12px;
    font-size: 12px;
    border-radius: 6px;
  }

  /* ===== PLACEHOLDER / START MOBILE ===== */
  .reappro-placeholder,
  .reappro-empty,
  .reappro-start {
    padding: 30px 16px;
    gap: 12px;
  }

  .reappro-placeholder svg,
  .reappro-empty svg,
  .reappro-start svg {
    font-size: 36px;
  }

  .reappro-screen .btn-start {
    padding: 14px 28px;
    font-size: 15px;
    min-height: 48px;
    border-radius: 10px;
  }
}

/* ===== TRÈS PETIT ÉCRAN (< 360px) ===== */
@media (max-width: 360px) {
  .reappro-screen {
    padding: 4px;
    gap: 6px;
  }

  .reappro-header h1 {
    font-size: 14px;
  }

  .stocks-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 5px;
  }

  .stock-item {
    padding: 6px 4px;
  }

  .stock-label {
    font-size: 7px;
  }

  .stock-value {
    font-size: 16px;
  }

  .stock-total {
    padding: 6px 10px;
  }

  .stock-total-label {
    font-size: 9px;
  }

  .stock-total-value {
    font-size: 20px;
  }

  .reappro-screen .article-code {
    font-size: 16px;
  }

  .reappro-screen .article-designation {
    font-size: 13px;
  }

  .confirmation-question {
    font-size: 14px;
  }

  .reappro-screen .quantite-btn {
    width: 50px;
    height: 50px;
  }

  .reappro-screen .quantite-input {
    font-size: 22px;
  }
}

/* ===== ÉCRANS TRÈS COURTS (paysage mobile) ===== */
@media (max-height: 500px) {
  .reappro-screen .modal-overlay {
    padding: 5px;
  }

  .reappro-screen .modal-content {
    padding: 10px;
    max-height: calc(100vh - 10px);
    min-height: auto;
    border-radius: 10px;
  }

  .reappro-screen .modal-stats {
    padding: 4px;
    margin-bottom: 8px;
  }

  .reappro-screen .modal-info-row {
    padding: 6px;
    margin-bottom: 6px;
  }

  .reappro-screen .export-mode-options {
    flex-direction: row;
  }

  .reappro-screen .export-mode-btn {
    flex-direction: row;
    gap: 6px;
    padding: 8px;
    min-height: auto;
  }

  .reappro-screen .modal-actions {
    flex-direction: row;
    gap: 8px;
    padding-top: 8px;
  }

  .reappro-screen .modal-actions .btn-confirm,
  .reappro-screen .modal-actions .btn-cancel {
    min-height: 44px;
    padding: 10px;
    font-size: 13px;
  }

  /* Confirmation plus compacte en paysage */
  .confirmation-box {
    padding: 10px;
  }

  .confirmation-question {
    font-size: 14px;
    margin-bottom: 10px;
  }

  .confirmation-actions {
    flex-direction: row;
  }

  .btn-yes, .btn-no {
    width: auto;
    flex: 1 1;
    padding: 10px 16px;
    min-height: 44px;
  }
}

/* ===== BOUTONS DELETE/EDIT GLOBAUX ===== */
.delete-btn {
  background: red !important;
  color: white !important;
  font-size: 2rem;
}

.edit-btn {
  background: rgb(235, 145, 43) !important;
  color: white !important;
  font-size: 2rem;
}

/* ===== BOUTONS DELETE/EDIT MOBILE - Taille tactile ===== */
@media (max-width: 480px) {
  .delete-btn,
  .edit-btn {
    font-size: 1.4rem;
    border-radius: 6px !important;
  }
}

/* ============================================================
   AJOUT à UserReappro.css — Onglets Scan / Demandes
   Coller à la fin du fichier existant
   ============================================================ */

/* Onglets */
.reappro-tabs {
  display: flex;
  gap: 6px;
  padding: 4px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.reappro-tab {
  flex: 1 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 12px;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 8px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}

.reappro-tab:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
}

.reappro-tab.active {
  background: rgba(16, 185, 129, 0.1);
  border-color: #10b981;
  color: #10b981;
}

/* Badge sur l'onglet demandes */
.tab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  background: #8b5cf6;
  color: #fff;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}

.tab-badge.critique {
  background: #ef4444;
  animation: pulse-badge 1.5s ease-in-out infinite;
}

@keyframes pulse-badge {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Responsive tabs */
@media (max-width: 480px) {
  .reappro-tabs {
    gap: 4px;
    padding: 3px;
  }

  .reappro-tab {
    padding: 8px 10px;
    font-size: 13px;
    gap: 4px;
  }

  .tab-badge {
    min-width: 18px;
    height: 18px;
    font-size: 10px;
    padding: 0 5px;
  }
}

/* ============================================================
   AJOUT à UserReappro.css — Titre, Partager, Partagés
   Coller à la fin du fichier existant
   ============================================================ */

/* Titre bar */
.reappro-titre-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.reappro-titre-text {
  flex: 1 1;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.reappro-titre-edit {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 28px; height: 28px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 14px;
}
.reappro-titre-edit:hover { background: #10b981; color: #fff; border-color: #10b981; }

/* Bouton Partager */
.btn-partager {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: transparent;
  border: 1px solid #8b5cf6;
  border-radius: 8px;
  color: #8b5cf6;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.btn-partager:hover { background: #8b5cf6; color: #fff; }
.btn-partager:disabled { opacity: 0.4; cursor: not-allowed; }

/* Tab badge partagé */
.tab-badge.partage { background: #8b5cf6; }

/* ═══ Onglet Partagés ═══ */
.reappro-partages { flex: 1 1; display: flex; flex-direction: column; }

.reappro-empty-tab {
  flex: 1 1;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 8px; padding: 40px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-align: center;
}
.reappro-empty-tab svg { font-size: 40px; color: var(--text-muted); opacity: 0.3; }
.reappro-empty-tab p { font-size: 14px; color: var(--text-primary); font-weight: 600; margin: 0; }
.reappro-empty-tab span { font-size: 12px; color: var(--text-muted); }

.partages-list { display: flex; flex-direction: column; gap: 8px; }

.partage-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-left: 4px solid #8b5cf6;
  border-radius: 10px;
}

.partage-info { flex: 1 1; min-width: 0; }

.partage-titre {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.partage-meta {
  display: flex; flex-wrap: wrap; gap: 10px;
  font-size: 12px; color: var(--text-muted);
  margin-bottom: 6px;
}
.partage-meta span { display: flex; align-items: center; gap: 3px; }

.partage-apercu { display: flex; flex-wrap: wrap; gap: 4px; }
.partage-art {
  font-size: 11px; font-family: monospace;
  padding: 2px 6px; background: rgba(6,182,212,0.08);
  color: #06b6d4; border-radius: 4px;
}
.partage-art small { color: #10b981; font-weight: 700; }
.partage-more { font-size: 11px; color: var(--text-muted); padding: 2px 6px; }

.btn-reprendre {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #059669, #10b981);
  border: none; border-radius: 8px;
  color: #fff; font-size: 14px; font-weight: 700;
  cursor: pointer; white-space: nowrap; flex-shrink: 0;
}
.btn-reprendre:hover { background: linear-gradient(135deg, #047857, #059669); }
.btn-reprendre:disabled { opacity: 0.4; cursor: not-allowed; }

/* Responsive */
@media (max-width: 480px) {
  .partage-card { flex-direction: column; align-items: stretch; }
  .btn-reprendre { width: 100%; justify-content: center; }
  .reappro-titre-bar { padding: 6px 10px; }
  .reappro-titre-text { font-size: 13px; }
  .btn-partager { padding: 10px 12px; font-size: 12px; }
  .reappro-actions { flex-wrap: wrap; }
}
/* ==========================================================================
   Admin Commandes Screen - Same design system as Articles
   ========================================================================== */

/* Page Container */
.admin-commandes-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
  display: flex;
  flex-direction: column;
}

/* ========== HEADER ========== */
.admin-commandes-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.commandes-icon {
  background: linear-gradient(135deg, #f59e0b, #d97706) !important;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3) !important;
}

/* ========== MAIN CONTENT LAYOUT ========== */
.admin-commandes-content {
  display: flex;
  flex: 1 1;
  overflow: hidden;
}

/* ========== MAIN AREA ========== */
.commandes-main {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* ========== TABLE ========== */
.commandes-table-container {
  flex: 1 1;
  overflow: auto;
  padding: 1rem;
}

.commandes-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.875rem;
}

.commandes-table thead {
  position: sticky;
  top: 0;
  z-index: 10;
}

.commandes-table th {
  padding: 0.875rem 1rem;
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  font-weight: 600;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
  border-bottom: 2px solid #f59e0b;
  white-space: nowrap;
}

.commandes-table th.text-right {
  text-align: right;
}

.commandes-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--admin-border);
  vertical-align: middle;
}

.commandes-table tbody tr {
  transition: var(--admin-transition);
}

.commandes-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

/* Row variants by état */
.commandes-table tbody tr.row-etat-info {
  border-left: 3px solid var(--admin-info);
}

.commandes-table tbody tr.row-etat-warning {
  border-left: 3px solid var(--admin-warning);
}

.commandes-table tbody tr.row-etat-success {
  border-left: 3px solid var(--admin-success);
}

.commandes-table tbody tr.row-etat-closed {
  border-left: 3px solid var(--admin-text-muted);
  opacity: 0.7;
}

/* Link style for NUMCDE */
.commande-numcde-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: #f59e0b;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  text-decoration: none;
  padding: 0.25rem 0.5rem;
  margin: -0.25rem -0.5rem;
  border-radius: var(--admin-radius-xs);
  transition: var(--admin-transition);
}

.commande-numcde-link:hover {
  background: #f59e0b;
  color: #000;
}

.commande-numcde-link .link-icon {
  font-size: 0.75rem;
  opacity: 0;
  transition: var(--admin-transition);
}

.commande-numcde-link:hover .link-icon {
  opacity: 1;
}

/* Fourn badge */
.fourn-badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-xs);
  font-size: 0.8rem;
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text-secondary);
}

/* Date value */
.date-value {
  font-size: 0.85rem;
  color: var(--admin-text-secondary);
}

/* Bateau */
.bateau-value {
  font-size: 0.85rem;
  color: var(--admin-text-secondary);
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

/* Observation */
.observ-text {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

/* État badge */
.etat-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.etat-badge.large {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
}

.etat-muted {
  background: rgba(100, 100, 120, 0.2);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.etat-info {
  background: var(--admin-info-light);
  color: var(--admin-info);
  border: 1px solid var(--admin-info);
}

.etat-warning {
  background: var(--admin-warning-light);
  color: var(--admin-warning);
  border: 1px solid var(--admin-warning);
}

.etat-success {
  background: var(--admin-success-light);
  color: var(--admin-success);
  border: 1px solid var(--admin-success);
}

.etat-closed {
  background: rgba(100, 100, 120, 0.15);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

/* Lignes count */
.lignes-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text-secondary);
}

/* Total value */
.total-value {
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

/* Badges commande */
.badge-verrou {
  background: var(--admin-danger);
  color: white;
}

.badge-facture {
  background: var(--admin-success);
  color: white;
}

.badge-groupage {
  background: var(--admin-info);
  color: white;
}

/* Actions group */
.actions-group {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.btn-detail {
  background: transparent;
  border: 1px solid #f59e0b !important;
  color: #f59e0b !important;
  text-decoration: none;
}

.btn-detail:hover {
  background: #f59e0b !important;
  color: #000 !important;
}

/* ========== MODAL ========== */
.commande-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1.5rem;
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
}

.commande-modal {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  width: 100%;
  max-width: 750px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--admin-shadow-lg);
}

.modal-numcde {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.85rem;
  color: #f59e0b;
  font-weight: 700;
}

.modal-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.modal-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.4rem 0.75rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.modal-badge.verrou {
  background: var(--admin-danger);
  color: white;
}

.modal-badge.groupage {
  background: var(--admin-info);
  color: white;
}

/* Montants grid in modal */
.montants-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.montant-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.75rem;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-sm);
  text-align: center;
}

.montant-item.main {
  grid-column: span 3;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), transparent);
  border: 1px solid #f59e0b;
}

.montant-item.main span:last-child {
  font-size: 1.5rem;
  font-weight: 800;
  color: #f59e0b;
}

.montant-item label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.montant-item span:last-child {
  font-size: 1rem;
  font-weight: 700;
  color: var(--admin-text);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .commandes-table .col-observ,
  .commandes-table .col-arrivee {
    display: none;
  }
}

@media (max-width: 900px) {
  .admin-commandes-header {
    flex-direction: column;
    align-items: stretch;
  }

  .commandes-table .col-bateau,
  .commandes-table .col-total,
  .commandes-table .col-statuts {
    display: none;
  }

  .montants-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .montant-item.main {
    grid-column: span 2;
  }
}

@media (max-width: 600px) {
  .commandes-table .col-lignes,
  .commandes-table .col-etat {
    display: none;
  }

  .pagination-bar {
    flex-direction: column;
    text-align: center;
  }

  .btn-page span {
    display: none;
  }
}
/* ==========================================================================
   Admin Commande Detail Screen
   ========================================================================== */

.commande-detail-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
  display: flex;
  flex-direction: column;
}

/* Loading / Error */
.detail-loading,
.detail-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
  color: var(--admin-text-muted);
}

.detail-error {
  color: var(--admin-danger);
}

.detail-error h2 {
  margin: 0;
  color: var(--admin-text);
}

.error-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.btn-retry,
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.btn-retry {
  background: var(--admin-primary);
  border: none;
  color: white;
}

.btn-retry:hover {
  background: var(--admin-primary-dark);
}

.btn-back {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-secondary);
}

.btn-back:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

/* ========== TOP BAR ========== */
.detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-back-list {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--admin-transition);
}

.btn-back-list:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
  border-color: var(--admin-border-light);
}

.topbar-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-nav:hover:not(:disabled) {
  background: #f59e0b;
  border-color: #f59e0b;
  color: #000;
}

.btn-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.nav-current {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.9rem;
  color: #f59e0b;
}

.nav-current svg {
  font-size: 1.1rem;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.query-time {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

.btn-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-refresh:hover {
  background: var(--admin-primary);
  border-color: var(--admin-primary);
  color: white;
}

/* ========== CONTENT ========== */
.detail-content {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

/* ========== HEADER CARD ========== */
.detail-header-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.5rem;
  background: rgb(48, 47, 48);
  border-top: 3px solid #f59e0b;
}

.header-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.header-card-title {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;

}

.numcde-display {
  display: flex;
  flex-direction: column;
}

.numcde-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.numcde-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 2rem;
  font-weight: 800;
  color: #f59e0b;
  line-height: 1;
}

.header-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.detail-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.4rem 0.75rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.detail-badge.verrou {
  background: var(--admin-danger);
  color: white;
  color: blue;
}

.detail-badge.unlocked {
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.detail-badge.groupage {
  background: var(--admin-info);
  color: white;
}

.detail-badge.facture {
  background: var(--admin-success);
  color: white;
}

/* Info Grid */
.header-info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.info-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 1rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  border: 1px solid var(--admin-border);
}

.info-card-icon {
  width: 40px;
  height: 40px;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: #f59e0b;
  flex-shrink: 0;
}

.info-card-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.info-card-content label {
  font-size: 0.95rem;
  color: var(--admin-text-muted);
  color:#8a5d0f;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 800;
 
}

.info-card-content span {
  font-size: 0.95rem;
  font-weight: 600;
  font-weight: bolder;
  color: var(--admin-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: rgb(228, 228, 228);
}

/* Observations */
.header-observ {
  margin-top: 1.25rem;
  padding: 1rem;
  background: var(--admin-warning-light);
  border: 1px solid var(--admin-warning);
  border-radius: var(--admin-radius-sm);
}

.observ-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--admin-warning);
  text-transform: uppercase;
}

.header-observ p {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--admin-text);
  line-height: 1.5;
}

/* ========== MONTANTS CARDS ========== */
.montants-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-gap: 0.875rem;
  gap: 0.875rem;
}

.montant-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 1rem;
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  text-align: center;
}

.montant-card.main {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), var(--admin-bg-secondary));
  border-color: #f59e0b;
}

.montant-card.calculated {
  background: linear-gradient(135deg, var(--admin-info-light), var(--admin-bg-secondary));
  border-color: var(--admin-info);
}

.montant-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.montant-card .montant-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
}

.montant-card.main .montant-value {
  color: #f59e0b;
  font-size: 1.5rem;
}

.montant-card.calculated .montant-value {
  color: var(--admin-info);
}

/* ========== FACTURE CARD ========== */
.facture-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-success);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.facture-card h3 {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.facture-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 1rem;
  gap: 1rem;
}

.facture-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.facture-item label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.facture-value {
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: var(--admin-success);
  font-size: 1rem;
}

/* ========== NOTES CARD ========== */
.notes-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.notes-card h3 {
  margin: 0 0 0.875rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.notes-list {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.note-line {
  margin: 0;
  font-size: 0.85rem;
  color: var(--admin-text-secondary);
  padding: 0.375rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-xs);
  line-height: 1.4;
}

/* ========== DETAIL LINES SECTION ========== */
.detail-lines-section {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  overflow: hidden;
}

.lines-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.lines-header h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0;
  color: var(--admin-text);
}

.lines-header h2 svg {
  color: #f59e0b;
  font-size: 1.25rem;
}

.lines-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  background: var(--admin-bg);
  padding: 0.2rem 0.625rem;
  border-radius: 50px;
}

.lines-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.lines-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.lines-search:focus-within {
  border-color: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.lines-search svg {
  color: var(--admin-text-muted);
  font-size: 1rem;
  flex-shrink: 0;
}

.lines-search input {
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.85rem;
  min-width: 200px;
  outline: none;
}

.lines-search input::placeholder {
  color: var(--admin-text-muted);
}

.btn-clear-search {
  background: transparent;
  border: none;
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0;
  display: flex;
  font-size: 0.875rem;
  transition: var(--admin-transition);
}

.btn-clear-search:hover {
  color: var(--admin-danger);
}

.lines-filter-pointe {
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.85rem;
  cursor: pointer;
}

.lines-filter-pointe:focus {
  outline: none;
  border-color: #f59e0b;
}

/* Lines Summary */
.lines-summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}

.summary-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem 1rem;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-xs);
  min-width: 100px;
}

.summary-item label {
  font-size: 0.6rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.summary-item span {
  font-size: 0.95rem;
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.summary-item span.highlight {
  color: #f59e0b;
}

/* Lines Table */
.lines-table-container {
  overflow-x: auto;
}

.lines-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.825rem;
}

.lines-table thead {
  position: sticky;
  top: 0;
  z-index: 5;
}

.lines-table th {
  padding: 0.75rem 0.875rem;
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  font-weight: 600;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
  border-bottom: 2px solid #f59e0b;
  white-space: nowrap;
}

.lines-table th.text-right {
  text-align: right;
}

.lines-table td {
  padding: 0.625rem 0.875rem;
  border-bottom: 1px solid var(--admin-border);
  vertical-align: middle;
}

.lines-table tbody tr {
  transition: var(--admin-transition);
}

.lines-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

/* Row variants */
.lines-table tbody tr.row-pointe {
  background: rgba(16, 185, 129, 0.05);
}

.lines-table tbody tr.row-complete {
  background: var(--admin-success-light);
}

.lines-table tbody tr.row-partielle {
  background: var(--admin-warning-light);
}

/* Cell styles */
.nl-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

.pointe-yes {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: var(--admin-success);
  color: white;
  border-radius: 50%;
  font-size: 0.75rem;
}

.pointe-no {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  border-radius: 50%;
  font-size: 0.75rem;
  border: 1px solid var(--admin-border);
}

.nart-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: var(--admin-primary-light);
  font-size: 0.8rem;
  text-decoration: none;
  padding: 0.2rem 0.375rem;
  margin: -0.2rem -0.375rem;
  border-radius: var(--admin-radius-xs);
  transition: var(--admin-transition);
}

.nart-link:hover {
  background: var(--admin-primary);
  color: white;
}

.nart-link .link-icon {
  font-size: 0.7rem;
  opacity: 0;
  transition: var(--admin-transition);
}

.nart-link:hover .link-icon {
  opacity: 1;
}

.design-text {
  color: var(--admin-text);
  font-size: 0.825rem;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

.refer-text {
  color: var(--admin-text-muted);
  font-size: 0.8rem;
  font-family: "Monaco", "Consolas", monospace;
}

.qte-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.rentre-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text-secondary);
}

.rentre-value.complete {
  color: var(--admin-success);
}

.rentre-value.partielle {
  color: var(--admin-warning);
}

.montant-cell {
  font-weight: 700;
  color: var(--admin-text);
}

.btn-view-article {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-xs);
  color: var(--admin-text-secondary);
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.btn-view-article:hover {
  background: var(--admin-primary);
  border-color: var(--admin-primary);
  color: white;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .header-info-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .montants-cards {
    grid-template-columns: repeat(3, 1fr);
  }

  .lines-table .col-fret,
  .lines-table .col-taxes,
  .lines-table .col-pcaf {
    display: none;
  }
}

@media (max-width: 900px) {
  .detail-content {
    padding: 1rem;
  }

  .detail-topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }

  .topbar-nav {
    justify-content: center;
  }

  .topbar-meta {
    justify-content: center;
  }

  .header-info-grid {
    grid-template-columns: 1fr;
  }

  .montants-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .lines-header {
    flex-direction: column;
    align-items: stretch;
  }

  .lines-controls {
    flex-direction: column;
  }

  .lines-search input {
    min-width: auto;
    width: 100%;
  }

  .lines-table .col-refer,
  .lines-table .col-pachat {
    display: none;
  }
}

@media (max-width: 600px) {
  .numcde-value {
    font-size: 1.5rem;
  }

  .montants-cards {
    grid-template-columns: 1fr 1fr;
  }

  .lines-table .col-nl,
  .lines-table .col-rentre,
  .lines-table .col-actions {
    display: none;
  }

  .lines-summary {
    gap: 0.375rem;
  }

  .summary-item {
    min-width: 80px;
    padding: 0.375rem 0.625rem;
  }
}


/* ==========================================================================
   CMDPLUS — Logistique & Transit Card
   ========================================================================== */

.cmdplus-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-info);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.cmdplus-card h3 {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.cmdplus-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.cmdplus-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.625rem 0.875rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  border: 1px solid var(--admin-border);
}

.cmdplus-item label {
  font-size: 0.65rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.cmdplus-item span {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--admin-text);
}

.cmdplus-item span.mono {
  font-family: "Monaco", "Consolas", monospace;
  letter-spacing: 0.5px;
}

.cmdplus-item span.highlight {
  color: #f59e0b;
  font-weight: 700;
}

/* ==========================================================================
   CMDPLUS — Frais, Douane & Taxes Card
   ========================================================================== */

.cmdplus-frais-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-warning);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.cmdplus-frais-card h3 {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.frais-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 0.625rem;
  gap: 0.625rem;
}

.frais-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.2rem;
  padding: 0.625rem 0.5rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  border: 1px solid var(--admin-border);
}

.frais-item label {
  font-size: 0.6rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.frais-item span {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
}

.frais-item.main-frais {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), var(--admin-bg-tertiary));
  border-color: rgba(245, 158, 11, 0.4);
}

.frais-item.main-frais span {
  color: #f59e0b;
  font-size: 1rem;
  font-weight: 800;
}

/* Separator line */
.frais-separator {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.25rem 0;
}

.frais-separator::before,
.frais-separator::after {
  content: "";
  flex: 1 1;
  height: 1px;
  background: var(--admin-border);
}

.frais-separator span {
  font-size: 0.65rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

/* ==========================================================================
   CMDPLUS — Responsive
   ========================================================================== */

@media (max-width: 1200px) {
  .cmdplus-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .frais-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .cmdplus-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .frais-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .cmdplus-grid {
    grid-template-columns: 1fr;
  }
  .frais-grid {
    grid-template-columns: 1fr 1fr;
  }
}
/* AdminFacturesScreen.css */
/* Module Factures - Accent orange #f97316 */

/* ========== PAGE LAYOUT ========== */
.admin-factures-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
}

/* ========== HEADER ========== */
.admin-factures-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
  gap: 1rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-icon.factures-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--admin-radius);
  background: linear-gradient(135deg, #ea580c, #f97316);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #fff;
  flex-shrink: 0;
}

.header-title h1 {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0;
}

.header-subtitle {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
  margin: 0.125rem 0 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.entreprise-selector {
  display: flex;
  align-items: center;
  position: relative;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  padding: 0 0.625rem;
}

.entreprise-selector select {
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.5rem 1.5rem 0.5rem 0.25rem;
  outline: none;
  cursor: pointer;
  appearance: none;
  min-width: 200px;
}

.selector-icon {
  color: #f97316;
  font-size: 1.1rem;
}

.selector-arrow {
  position: absolute;
  right: 0.5rem;
  color: var(--admin-text-muted);
  pointer-events: none;
}

/* ========== EMPTY STATE ========== */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
}

.empty-state .empty-icon {
  font-size: 3rem;
  color: var(--admin-text-muted);
  opacity: 0.5;
  margin-bottom: 1rem;
}

.empty-state h2 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.empty-state p {
  font-size: 0.85rem;
  color: var(--admin-text-muted);
  margin: 0;
}

/* ========== CONTENT LAYOUT ========== */
.admin-factures-content {
  display: flex;
  gap: 0;
  min-height: calc(100vh - 100px);
}

/* ========== SIDEBAR FILTRES ========== */
.filters-sidebar {
  width: 280px;
  background: var(--admin-bg-secondary);
  border-right: 1px solid var(--admin-border);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: var(--admin-transition);
  overflow: hidden;
}

.filters-sidebar:not(.open) {
  width: 0;
  min-width: 0;
  border-right: none;
}

.filters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--admin-border);
}

.filters-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.85rem;
  color: #f97316;
}

.filters-badge {
  background: #f97316;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  min-width: 18px;
  text-align: center;
}

.btn-toggle-filters {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0.375rem;
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.btn-toggle-filters:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

.filters-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 0.5rem 0;
}

.filter-section {
  border-bottom: 1px solid var(--admin-border);
}

.section-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.625rem 1rem;
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
}

.section-header:hover {
  background: var(--admin-bg-hover);
}

.section-header svg:last-child {
  margin-left: auto;
  color: var(--admin-text-muted);
}

.section-icon {
  font-size: 1rem;
}

.section-content {
  padding: 0 1rem 0.75rem;
}

.filter-group {
  margin-bottom: 0.625rem;
}

.filter-group label {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.filter-group input,
.filter-group select {
  width: 100%;
  padding: 0.5rem 0.625rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.8rem;
  outline: none;
  transition: var(--admin-transition);
}

.filter-group input:focus,
.filter-group select:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.15);
}

.filters-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--admin-border);
}

.btn-reset {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  width: 100%;
  padding: 0.5rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-reset:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

/* ========== MAIN ========== */
.factures-main {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ========== STATS BAR ========== */
.stats-bar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.75rem 1.25rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.stat-item .stat-value {
  font-size: 1rem;
  font-weight: 800;
  color: var(--admin-text);
}

.stat-item.primary .stat-value {
  color: #f97316;
}

.stat-item .stat-label {
  font-size: 0.65rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stats-actions {
  display: flex;
  gap: 0.375rem;
  margin-left: auto;
}

.btn-icon-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-icon-action:hover,
.btn-icon-action.active {
  background: var(--admin-bg-hover);
  color: #f97316;
  border-color: #f97316;
}

.btn-icon-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.spinning {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ========== TABLE ========== */
.factures-table-container {
  flex: 1 1;
  overflow: auto;
}

.table-loading,
.table-error,
.table-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  text-align: center;
  color: var(--admin-text-muted);
}

.table-error svg {
  font-size: 2rem;
  color: var(--admin-danger);
  margin-bottom: 0.75rem;
}

.factures-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.factures-table thead th {
  position: sticky;
  top: 0;
  background: var(--admin-bg-tertiary);
  border-bottom: 2px solid var(--admin-border);
  padding: 0.625rem 0.75rem;
  text-align: left;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--admin-text-muted);
  white-space: nowrap;
  z-index: 1;
}

.factures-table tbody tr {
  border-bottom: 1px solid var(--admin-border);
  transition: var(--admin-transition);
}

.factures-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

.factures-table td {
  padding: 0.5rem 0.75rem;
  white-space: nowrap;
}

.text-right {
  text-align: right !important;
}

/* Facture numfact link */
.facture-numfact-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.85rem;
  color: #f97316;
  text-decoration: none;
  transition: var(--admin-transition);
}

.facture-numfact-link:hover {
  color: #ea580c;
}

.facture-numfact-link .link-icon {
  font-size: 0.7rem;
  opacity: 0;
  transition: var(--admin-transition);
}

.facture-numfact-link:hover .link-icon {
  opacity: 1;
}

/* TYPFACT badges */
.typfact-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

.typfact-badge.large {
  padding: 0.375rem 0.75rem;
  font-size: 0.8rem;
}

.typ-primary {
  background: rgba(249, 115, 22, 0.15);
  color: #f97316;
  border: 1px solid rgba(249, 115, 22, 0.3);
}

.typ-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.typ-warning {
  background: rgba(234, 179, 8, 0.15);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.typ-info {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.typ-muted {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
  border: 1px solid rgba(107, 114, 128, 0.3);
}

/* Row color hints */
.row-typ-danger {
  border-left: 3px solid rgba(239, 68, 68, 0.5);
}

.row-typ-warning {
  border-left: 3px solid rgba(234, 179, 8, 0.5);
}

.row-typ-info {
  border-left: 3px solid rgba(59, 130, 246, 0.5);
}

/* Other cells */
.date-value {
  font-size: 0.8rem;
  color: var(--admin-text-muted);
}

.tiers-badge,
.repres-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  padding: 0.125rem 0.375rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
}

.nom-text,
.boncde-text {
  display: inline-block;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.8rem;
}

.montant-value {
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.8rem;
}

.montaxes-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

/* Actions */
.actions-group {
  display: flex;
  gap: 0.25rem;
}

.btn-view {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
  text-decoration: none;
}

.btn-view:hover {
  background: rgba(249, 115, 22, 0.15);
  color: #f97316;
  border-color: #f97316;
}

/* ========== PAGINATION ========== */
.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  background: var(--admin-bg-secondary);
  border-top: 1px solid var(--admin-border);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.pagination-info {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-page {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.375rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-page:hover:not(:disabled) {
  background: var(--admin-bg-hover);
  border-color: #f97316;
  color: #f97316;
}

.btn-page:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.page-indicator {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.8rem;
  font-weight: 700;
}

.current-page {
  color: #f97316;
}

.page-separator {
  color: var(--admin-text-muted);
}

.total-pages {
  color: var(--admin-text-muted);
}

/* ========== MODAL ========== */
.facture-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.facture-modal {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-lg);
  width: 100%;
  max-width: 640px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--admin-border);
}

.modal-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.modal-title svg {
  font-size: 1.5rem;
  color: #f97316;
}

.modal-title h2 {
  font-size: 1rem;
  font-weight: 800;
  margin: 0;
}

.modal-numfact {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

.modal-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-view-full {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: linear-gradient(135deg, #ea580c, #f97316);
  border: none;
  border-radius: var(--admin-radius-sm);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-view-full:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.btn-close-modal {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0.375rem;
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.btn-close-modal:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-danger);
}

.modal-body {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.25rem;
}

.modal-status-row {
  margin-bottom: 1rem;
}

.info-block {
  margin-bottom: 1.25rem;
}

.info-block h4 {
  font-size: 0.8rem;
  font-weight: 700;
  margin: 0 0 0.625rem;
  color: #f97316;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 0.625rem;
  gap: 0.625rem;
}

.info-item label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 0.125rem;
}

.info-item .value {
  font-size: 0.85rem;
  font-weight: 600;
}

.info-item .value.highlight {
  color: #f97316;
  font-family: "Monaco", "Consolas", monospace;
}

.montants-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 0.75rem;
  gap: 0.75rem;
}

.montant-item {
  padding: 0.75rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  text-align: center;
}

.montant-item label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--admin-text-muted);
  margin-bottom: 0.25rem;
}

.montant-item span {
  font-size: 1rem;
  font-weight: 800;
  font-family: "Monaco", "Consolas", monospace;
}

.montant-item.main span {
  color: #f97316;
}

.observations-block p {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--admin-text-muted);
}

/* ========== LOADING ========== */
.admin-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
}

.loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--admin-border);
  border-top: 3px solid #f97316;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .admin-factures-header {
    flex-direction: column;
    align-items: stretch;
  }

  .filters-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.3);
  }

  .filters-sidebar:not(.open) {
    display: none;
  }

  .factures-table {
    font-size: 0.75rem;
  }

  .col-boncde,
  .col-montaxes,
  .col-repres {
    display: none;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  .pagination-bar {
    flex-direction: column;
    text-align: center;
  }
}



/* ==========================================================================
   Admin Facture Detail Screen
   Accent color: orange/cyan (#f97316)
   ========================================================================== */

.facture-detail-page {
  min-height: 100vh;
  background: var(--admin-bg);
  color: var(--admin-text);
  display: flex;
  flex-direction: column;
}

/* Loading / Error */
.facture-detail-page .detail-loading,
.facture-detail-page .detail-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 1rem;
  color: var(--admin-text-muted);
}

.facture-detail-page .detail-error {
  color: var(--admin-danger);
}

.facture-detail-page .detail-error h2 {
  margin: 0;
  color: var(--admin-text);
}

.facture-detail-page .error-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.facture-detail-page .btn-retry,
.facture-detail-page .btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.facture-detail-page .btn-retry {
  background: var(--admin-primary);
  border: none;
  color: white;
}

.facture-detail-page .btn-retry:hover {
  background: var(--admin-primary-dark);
}

.facture-detail-page .btn-back {
  background: transparent;
  border: 1px solid var(--admin-border);
  color: var(--admin-text-secondary);
}

.facture-detail-page .btn-back:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

/* ========== TOP BAR ========== */
.facture-detail-page .detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-secondary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.facture-detail-page .btn-back-list {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--admin-transition);
}

.facture-detail-page .btn-back-list:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
  border-color: var(--admin-border-light);
}

.facture-detail-page .topbar-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.facture-detail-page .nav-current {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.9rem;
  color: #f97316;
}

.facture-detail-page .nav-current svg {
  font-size: 1.1rem;
}

.facture-detail-page .topbar-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.facture-detail-page .query-time {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
}

/* ========== EXPORT BUTTONS ========== */
.btn-export-excel,
.btn-export-dat {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
  white-space: nowrap;
}

.btn-export-excel {
  background: linear-gradient(135deg, #ea580c, #f97316);
  border: 1px solid #f97316;
  color: #fff;
}

.btn-export-excel:hover:not(:disabled) {
  background: linear-gradient(135deg, #c2410c, #ea580c);
  box-shadow: 0 4px 12px rgba(20, 184, 166, 0.3);
  transform: translateY(-1px);
}

.btn-export-dat {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: 1px solid #8b5cf6;
  color: #fff;
}

.btn-export-dat:hover:not(:disabled) {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
  transform: translateY(-1px);
}

.btn-export-excel:disabled,
.btn-export-dat:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-export-excel svg,
.btn-export-dat svg {
  font-size: 1rem;
}

/* ========== DAT PANEL ========== */
.dat-panel {
  background: var(--admin-bg-secondary);
  border-bottom: 2px solid #8b5cf6;
  padding: 0;
  animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
  from { max-height: 0; opacity: 0; }
  to { max-height: 200px; opacity: 1; }
}

.dat-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 1.5rem;
  background: rgba(139, 92, 246, 0.1);
  border-bottom: 1px solid var(--admin-border);
  font-size: 0.85rem;
  font-weight: 700;
  color: #a78bfa;
}

.btn-close-dat {
  background: transparent;
  border: none;
  color: var(--admin-text-muted);
  cursor: pointer;
  font-size: 1rem;
  transition: var(--admin-transition);
}

.btn-close-dat:hover {
  color: var(--admin-danger);
}

.dat-panel-body {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.5rem;
  flex-wrap: wrap;
}

.dat-filename-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1 1;
  min-width: 280px;
}

.dat-filename-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  white-space: nowrap;
}

.dat-filename-group input {
  flex: 1 1;
  padding: 0.5rem 0.75rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.85rem;
  outline: none;
  transition: var(--admin-transition);
}

.dat-filename-group input:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.btn-dat-reset-name {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-muted);
  cursor: pointer;
  transition: var(--admin-transition);
}

.btn-dat-reset-name:hover {
  background: var(--admin-bg-hover);
  color: var(--admin-text);
}

.dat-panel-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-dat-download,
.btn-dat-server {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  border-radius: var(--admin-radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--admin-transition);
  white-space: nowrap;
}

.btn-dat-download {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: 1px solid #8b5cf6;
  color: #fff;
}

.btn-dat-download:hover:not(:disabled) {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
  transform: translateY(-1px);
}

.btn-dat-server {
  background: linear-gradient(135deg, #d97706, #f59e0b);
  border: 1px solid #f59e0b;
  color: #000;
}

.btn-dat-server:hover:not(:disabled) {
  background: linear-gradient(135deg, #b45309, #d97706);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transform: translateY(-1px);
}

.btn-dat-download:disabled,
.btn-dat-server:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-dat-download svg,
.btn-dat-server svg {
  font-size: 1rem;
}

/* ========== DAT MESSAGE BANNER ========== */
.dat-message {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.dat-message-success {
  background: rgba(16, 185, 129, 0.15);
  border-bottom: 2px solid var(--admin-success);
  color: var(--admin-success);
}

.dat-message-error {
  background: rgba(239, 68, 68, 0.15);
  border-bottom: 2px solid var(--admin-danger);
  color: var(--admin-danger);
}

.dat-message .dat-path {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  opacity: 0.8;
}

.dat-message button {
  margin-left: auto;
  background: transparent;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 1rem;
  opacity: 0.7;
  transition: var(--admin-transition);
}

.dat-message button:hover {
  opacity: 1;
}

/* ========== REFRESH BUTTON ========== */
.facture-detail-page .btn-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--admin-bg-tertiary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  transition: var(--admin-transition);
}

.facture-detail-page .btn-refresh:hover {
  background: #f97316;
  border-color: #f97316;
  color: #000;
}

/* ========== CONTENT ========== */
.facture-detail-page .detail-content {
  flex: 1 1;
  overflow-y: auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

/* ========== HEADER CARD ========== */
.facture-detail-page .detail-header-card {
  background: rgb(48, 47, 48);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.5rem;
  border-top: 3px solid #f97316;
}

.facture-detail-page .header-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.facture-detail-page .header-card-title {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.numfact-display {
  display: flex;
  flex-direction: column;
}

.numfact-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.numfact-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 2rem;
  font-weight: 800;
  color: #f97316;
  line-height: 1;
}

/* Info Grid */
.facture-detail-page .header-info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 1rem;
  gap: 1rem;
}

.facture-detail-page .info-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 1rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-sm);
  border: 1px solid var(--admin-border);
}

.facture-detail-page .info-card-icon {
  width: 40px;
  height: 40px;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: #f97316;
  flex-shrink: 0;
}

.facture-detail-page .info-card-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.facture-detail-page .info-card-content label {
  font-size: 0.65rem;
  color: #0d6b61;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 800;
}

.facture-detail-page .info-card-content span {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--admin-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Observations */
.facture-detail-page .header-observ {
  margin-top: 1.25rem;
  padding: 1rem;
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid #f97316;
  border-radius: var(--admin-radius-sm);
}

.facture-detail-page .observ-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #f97316;
  text-transform: uppercase;
}

.facture-detail-page .header-observ p {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--admin-text);
  line-height: 1.5;
}

/* ========== MONTANTS CARDS ========== */
.facture-detail-page .montants-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 0.875rem;
  gap: 0.875rem;
}

.facture-detail-page .montant-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 1rem;
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  text-align: center;
}

.facture-detail-page .montant-card.main {
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.15), var(--admin-bg-secondary));
  border-color: #f97316;
}

.facture-detail-page .montant-card.calculated {
  background: linear-gradient(135deg, var(--admin-info-light), var(--admin-bg-secondary));
  border-color: var(--admin-info);
}

.facture-detail-page .montant-label {
  font-size: 0.7rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.facture-detail-page .montant-card .montant-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--admin-text);
  font-family: "Monaco", "Consolas", monospace;
}

.facture-detail-page .montant-card.main .montant-value {
  color: #f97316;
  font-size: 1.5rem;
}

.facture-detail-page .montant-card.calculated .montant-value {
  color: var(--admin-info);
}

/* ========== MAILING CARD ========== */
.mailing-card {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  padding: 1.25rem;
}

.mailing-card h3 {
  margin: 0 0 0.875rem;
  font-size: 0.95rem;
  color: var(--admin-text);
}

.facture-detail-page .mailing-lines {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.facture-detail-page .mailing-line {
  margin: 0;
  font-size: 0.85rem;
  color: var(--admin-text-secondary);
  padding: 0.375rem 0.75rem;
  background: var(--admin-bg-tertiary);
  border-radius: var(--admin-radius-xs);
  line-height: 1.4;
}

/* ========== DETAIL LINES SECTION ========== */
.facture-detail-page .detail-lines-section {
  background: var(--admin-bg-secondary);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius);
  overflow: hidden;
}

.facture-detail-page .lines-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  gap: 1rem;
  flex-wrap: wrap;
}

.facture-detail-page .lines-header h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0;
  color: var(--admin-text);
}

.facture-detail-page .lines-header h2 svg {
  color: #f97316;
  font-size: 1.25rem;
}

.facture-detail-page .lines-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--admin-text-muted);
  background: var(--admin-bg);
  padding: 0.2rem 0.625rem;
  border-radius: 50px;
}

.facture-detail-page .lines-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.facture-detail-page .lines-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  transition: var(--admin-transition);
}

.facture-detail-page .lines-search:focus-within {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.2);
}

.facture-detail-page .lines-search svg {
  color: var(--admin-text-muted);
  font-size: 1rem;
  flex-shrink: 0;
}

.facture-detail-page .lines-search input {
  background: transparent;
  border: none;
  color: var(--admin-text);
  font-size: 0.85rem;
  min-width: 200px;
  outline: none;
}

.facture-detail-page .lines-search input::placeholder {
  color: var(--admin-text-muted);
}

.facture-detail-page .btn-clear-search {
  background: transparent;
  border: none;
  color: var(--admin-text-muted);
  cursor: pointer;
  padding: 0;
  display: flex;
  font-size: 0.875rem;
  transition: var(--admin-transition);
}

.facture-detail-page .btn-clear-search:hover {
  color: var(--admin-danger);
}

.lines-filter-type {
  padding: 0.5rem 0.875rem;
  background: var(--admin-bg);
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-sm);
  color: var(--admin-text);
  font-size: 0.85rem;
  cursor: pointer;
}

.lines-filter-type:focus {
  outline: none;
  border-color: #f97316;
}

/* Lines Summary */
.facture-detail-page .lines-summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  background: var(--admin-bg-tertiary);
  border-bottom: 1px solid var(--admin-border);
  flex-wrap: wrap;
}

.facture-detail-page .summary-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem 1rem;
  background: var(--admin-bg);
  border-radius: var(--admin-radius-xs);
  min-width: 100px;
}

.facture-detail-page .summary-item label {
  font-size: 0.6rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.facture-detail-page .summary-item span {
  font-size: 0.95rem;
  font-weight: 700;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.facture-detail-page .summary-item span.highlight {
  color: #f97316;
}

/* Lines Table */
.facture-detail-page .lines-table-container {
  overflow-x: auto;
}

.facture-detail-page .lines-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.825rem;
}

.facture-detail-page .lines-table thead {
  position: sticky;
  top: 0;
  z-index: 5;
}

.facture-detail-page .lines-table th {
  padding: 0.75rem 0.875rem;
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  font-weight: 600;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
  border-bottom: 2px solid #f97316;
  white-space: nowrap;
}

.facture-detail-page .lines-table th.text-right {
  text-align: right;
}

.facture-detail-page .lines-table td {
  padding: 0.625rem 0.875rem;
  border-bottom: 1px solid var(--admin-border);
  vertical-align: middle;
}

.facture-detail-page .lines-table tbody tr {
  transition: var(--admin-transition);
}

.facture-detail-page .lines-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

.facture-detail-page .lines-table tbody tr.row-comment {
  background: rgba(100, 100, 120, 0.08);
}

.facture-detail-page .lines-table tbody tr.row-comment:hover {
  background: rgba(100, 100, 120, 0.15);
}

/* Type badge */
.type-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 0.75rem;
}

.type-badge.article {
  background: #f97316;
  color: #000;
}

.type-badge.comment {
  background: var(--admin-bg-tertiary);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.nart-comment {
  color: var(--admin-text-muted);
  font-size: 0.8rem;
}

.comment-text {
  font-style: italic;
  color: var(--admin-text-muted) !important;
  max-width: none !important;
}

/* Cell styles */
.facture-detail-page .nl-value {
  font-family: "Monaco", "Consolas", monospace;
  font-size: 0.75rem;
  color: var(--admin-text-muted);
}

.facture-detail-page .nart-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-family: "Monaco", "Consolas", monospace;
  font-weight: 700;
  color: var(--admin-primary-light);
  font-size: 0.8rem;
  text-decoration: none;
  padding: 0.2rem 0.375rem;
  margin: -0.2rem -0.375rem;
  border-radius: var(--admin-radius-xs);
  transition: var(--admin-transition);
}

.facture-detail-page .nart-link:hover {
  background: var(--admin-primary);
  color: white;
}

.facture-detail-page .nart-link .link-icon {
  font-size: 0.7rem;
  opacity: 0;
  transition: var(--admin-transition);
}

.facture-detail-page .nart-link:hover .link-icon {
  opacity: 1;
}

.facture-detail-page .design-text {
  color: var(--admin-text);
  font-size: 0.825rem;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

.facture-detail-page .qte-value {
  font-weight: 600;
  font-family: "Monaco", "Consolas", monospace;
  color: var(--admin-text);
}

.remise-value {
  font-weight: 600;
  color: var(--admin-warning);
  font-size: 0.8rem;
}

.facture-detail-page .montant-cell {
  font-weight: 700;
  color: var(--admin-text);
}

.numserie-text {
  font-size: 0.75rem;
  color: var(--admin-text-muted);
  font-family: "Monaco", "Consolas", monospace;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
}

.facture-detail-page .btn-view-article {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--admin-border);
  border-radius: var(--admin-radius-xs);
  color: var(--admin-text-secondary);
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  transition: var(--admin-transition);
}

.facture-detail-page .btn-view-article:hover {
  background: #f97316;
  border-color: #f97316;
  color: #000;
}

/* État badges */
.facture-detail-page .typfact-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.facture-detail-page .typfact-badge.large {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
}

.facture-detail-page .typ-muted {
  background: rgba(100, 100, 120, 0.2);
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-border);
}

.facture-detail-page .typ-info {
  background: var(--admin-info-light);
  color: var(--admin-info);
  border: 1px solid var(--admin-info);
}

.facture-detail-page .typ-primary {
  background: var(--admin-success-light);
  color: var(--admin-success);
  border: 1px solid var(--admin-success);
}

/* Table empty */
.facture-detail-page .table-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  color: var(--admin-text-muted);
  text-align: center;
}

.facture-detail-page .table-empty svg {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  opacity: 0.5;
}

.facture-detail-page .table-empty h3 {
  margin: 0 0 0.5rem;
  color: var(--admin-text);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .facture-detail-page .header-info-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .facture-detail-page .lines-table .col-numserie,
  .facture-detail-page .lines-table .col-dtva,
  .facture-detail-page .lines-table .col-pourc {
    display: none;
  }
}

@media (max-width: 900px) {
  .facture-detail-page .detail-content {
    padding: 1rem;
  }
  .facture-detail-page .detail-topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  .facture-detail-page .topbar-nav {
    justify-content: center;
  }
  .facture-detail-page .topbar-meta {
    justify-content: center;
  }
  .facture-detail-page .header-info-grid {
    grid-template-columns: 1fr;
  }
  .facture-detail-page .montants-cards {
    grid-template-columns: 1fr;
  }
  .facture-detail-page .lines-header {
    flex-direction: column;
    align-items: stretch;
  }
  .facture-detail-page .lines-controls {
    flex-direction: column;
  }
  .facture-detail-page .lines-search input {
    min-width: auto;
    width: 100%;
  }
  .facture-detail-page .lines-table .col-pvttc,
  .facture-detail-page .lines-table .col-pvte {
    display: none;
  }
  .btn-export-excel span,
  .btn-export-dat span {
    display: none;
  }
}

@media (max-width: 600px) {
  .numfact-value {
    font-size: 1.5rem;
  }
  .facture-detail-page .lines-table .col-nl,
  .facture-detail-page .lines-table .col-type,
  .facture-detail-page .lines-table .col-actions {
    display: none;
  }
  .facture-detail-page .lines-summary {
    gap: 0.375rem;
  }
  .facture-detail-page .summary-item {
    min-width: 80px;
    padding: 0.375rem 0.625rem;
  }
}

/* ========== TYPFACT BADGES ========== */
.facture-detail-page .typfact-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
}

.facture-detail-page .typfact-badge.large {
  padding: 0.375rem 1rem;
  font-size: 0.85rem;
}

.facture-detail-page .typ-primary {
  background: rgba(249, 115, 22, 0.15);
  color: #f97316;
  border: 1px solid rgba(249, 115, 22, 0.3);
}

.facture-detail-page .typ-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.facture-detail-page .typ-warning {
  background: rgba(234, 179, 8, 0.15);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.facture-detail-page .typ-info {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.facture-detail-page .typ-muted {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
  border: 1px solid rgba(107, 114, 128, 0.3);
}

/* ==========================================================================
   AVOIR STYLES — Append to AdminFactureDetailScreen.css
   ========================================================================== */

/* Header card avoir */
.detail-header-card.avoir-header {
  border-top-color: #ef4444;
  border-top-color: var(--admin-danger, #ef4444);
}

/* Warning banner avoir */
.avoir-warning {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 6px;
  border-radius: var(--admin-radius-sm, 6px);
  font-size: 0.75rem;
  font-weight: 600;
  color: #ef4444;
  color: var(--admin-danger, #ef4444);
  margin-top: 0.75rem;
}

.avoir-warning svg {
  font-size: 1rem;
  flex-shrink: 0;
}

/* Montant cards avoir */
.montant-card.avoir-montant .montant-value {
  color: #ef4444 !important;
  color: var(--admin-danger, #ef4444) !important;
}

.montant-card.avoir-montant.main {
  border-color: #ef4444;
  border-color: var(--admin-danger, #ef4444);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), var(--admin-bg-secondary));
}

/* Text avoir (negative values) */
.avoir-text {
  color: #ef4444 !important;
  color: var(--admin-danger, #ef4444) !important;
}

/* Row avoir in table */
.lines-table tbody tr.row-avoir {
  border-left: 3px solid #ef4444;
  border-left: 3px solid var(--admin-danger, #ef4444);
}

.lines-table tbody tr.row-avoir .montant-cell,
.lines-table tbody tr.row-avoir .qte-value {
  color: #ef4444;
  color: var(--admin-danger, #ef4444);
}
/* src/screens/admin/AdminDemandesReapproScreen.css */

.admin-demandes-page {
  min-height: 100vh;
  background: #0a0a0f;
  color: #f0f0f5;
  display: flex;
  flex-direction: column;
}

/* ═══ HEADER ═══ */
.adm-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  background: #12121a;
  border-bottom: 1px solid #2a2a3a;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.adm-header-left { display: flex; align-items: center; gap: 0.75rem; }
.adm-header-icon { font-size: 1.3rem; color: #a78bfa; }
.adm-header h1 { font-size: 1.1rem; margin: 0; }
.btn-back {
  background: #1a1a25; border: 1px solid #2a2a3a; color: #fff;
  width: 36px; height: 36px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.btn-back:hover { background: #2a2a3a; }
.adm-header-right { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.adm-entreprise-select {
  padding: 0.4rem 0.8rem; background: #1a1a25; border: 1px solid #2a2a3a;
  border-radius: 6px; color: #f0f0f5; font-size: 0.82rem; outline: none;
}
.btn-new-demande {
  display: flex; align-items: center; gap: 0.3rem;
  padding: 0.45rem 0.9rem; background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: none; border-radius: 6px; color: #fff; font-size: 0.82rem; font-weight: 600; cursor: pointer;
}
.btn-new-demande:hover { background: linear-gradient(135deg, #6d28d9, #7c3aed); }

.adm-placeholder {
  flex: 1 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 0.5rem; color: #606070;
}
.adm-placeholder svg { font-size: 2.5rem; opacity: 0.3; }

/* ═══ ONGLETS ═══ */
.adm-main-tabs {
  display: flex; gap: 4px;
  padding: 8px 1.25rem; background: #12121a; border-bottom: 1px solid #2a2a3a;
}
.adm-main-tab {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; background: transparent; border: 2px solid transparent;
  border-radius: 8px; color: #606070; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s;
}
.adm-main-tab:hover { color: #a0a0b0; background: rgba(255,255,255,0.02); }
.adm-main-tab.active { background: rgba(139,92,246,0.1); border-color: rgba(139,92,246,0.3); color: #a78bfa; }
.adm-tab-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 6px;
  background: #8b5cf6; color: #fff; border-radius: 10px; font-size: 0.7rem; font-weight: 800;
}

/* ═══ MESSAGE ═══ */
.adm-msg {
  padding: 10px 1.25rem; font-size: 0.82rem; font-weight: 600; text-align: center;
}
.adm-msg.success { background: rgba(16,185,129,0.1); color: #059669; }
.adm-msg.error { background: rgba(239,68,68,0.1); color: #dc2626; }

/* ═══ SOUS-FILTRES ═══ */
.adm-sub-filters {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 1.25rem; background: #0f0f17; border-bottom: 1px solid #1a1a25;
}
.adm-filter-btn {
  padding: 4px 12px; background: #1a1a25; border: 1px solid #2a2a3a;
  border-radius: 6px; color: #606070; font-size: 0.75rem; font-weight: 600; cursor: pointer;
}
.adm-filter-btn:hover { border-color: #505060; color: #a0a0b0; }
.adm-filter-btn.active { background: rgba(139,92,246,0.1); border-color: #8b5cf6; color: #a78bfa; }
.adm-btn-refresh {
  background: #1a1a25; border: 1px solid #2a2a3a; color: #606070;
  width: 28px; height: 28px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center; cursor: pointer; margin-left: auto;
}
.adm-btn-refresh:hover { background: #2a2a3a; color: #f0f0f5; }

.adm-loading, .adm-empty { padding: 3rem; text-align: center; color: #606070; font-size: 0.9rem; }

/* ═══ LISTE CARTES ═══ */
.adm-list {
  padding: 0.75rem 1.25rem; display: flex; flex-direction: column; gap: 0.5rem;
  overflow-y: auto; flex: 1 1;
}

.adm-card { background: #12121a; border: 1px solid #2a2a3a; border-radius: 10px; overflow: hidden; }
.adm-card.unread { border-color: rgba(16,185,129,0.4); }

.adm-card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.65rem 1rem; cursor: pointer; gap: 0.5rem; flex-wrap: wrap;
}
.adm-card-header:hover { background: rgba(255,255,255,0.015); }
.adm-card-left { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.adm-card-right { display: flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; color: #606070; }

.adm-prio { font-size: 0.85rem; }
.adm-ref { font-family: monospace; font-size: 0.76rem; font-weight: 700; color: #a78bfa; }
.adm-status-badge { padding: 2px 8px; border-radius: 4px; font-size: 0.65rem; font-weight: 700; }
.adm-badge-new {
  padding: 2px 6px; background: #10b981; color: #fff;
  border-radius: 4px; font-size: 0.6rem; font-weight: 800;
  animation: pulse-new 2s infinite;
}
@keyframes pulse-new { 0%,100% { opacity: 1; } 50% { opacity: 0.6; } }

.adm-fourn { font-size: 0.75rem; color: #808090; }
.adm-card-count { font-size: 0.72rem; font-weight: 700; background: #1a1a25; padding: 1px 6px; border-radius: 4px; }
.adm-card-date { display: flex; align-items: center; gap: 3px; font-size: 0.7rem; }

/* Card body */
.adm-card-body { padding: 0 1rem 1rem; }
.adm-card-meta {
  display: flex; gap: 0.75rem; font-size: 0.75rem; color: #606070;
  margin-bottom: 0.6rem; flex-wrap: wrap;
}
.adm-card-meta span { display: flex; align-items: center; gap: 3px; }
.adm-card-note {
  display: flex; align-items: flex-start; gap: 6px;
  padding: 0.4rem 0.65rem; background: rgba(245,158,11,0.08);
  border: 1px solid rgba(245,158,11,0.2); border-radius: 6px;
  font-size: 0.78rem; color: #fbbf24; margin-bottom: 0.6rem;
}

/* Table lignes */
.adm-card-lignes { overflow-x: auto; margin-bottom: 0.5rem; }
.adm-lignes-table { width: 100%; border-collapse: collapse; font-size: 0.78rem; }
.adm-lignes-table th {
  text-align: left; font-size: 0.65rem; text-transform: uppercase;
  color: #606070; padding: 0.35rem; border-bottom: 1px solid #2a2a3a; white-space: nowrap;
}
.adm-lignes-table th.text-center { text-align: center; }
.adm-lignes-table td { padding: 0.35rem; border-bottom: 1px solid #1a1a25; }
.adm-td-nart { font-family: monospace; font-weight: 700; color: #06b6d4; font-size: 0.75rem; }
.adm-td-design { color: #a0a0b0; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-td-stock { text-align: center; font-family: monospace; font-size: 0.75rem; color: #606070; }
.adm-td-num { text-align: center; font-weight: 700; }
.adm-ligne-row.traite { opacity: 0.6; }
.adm-ligne-row.ignore { opacity: 0.35; }
.adm-ligne-badge {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 6px; border-radius: 4px; font-size: 0.62rem; font-weight: 700;
}
.adm-ligne-badge.done { background: rgba(16,185,129,0.15); color: #10b981; }
.adm-ligne-badge.ignored { background: rgba(239,68,68,0.15); color: #ef4444; }
.adm-ligne-badge.pending { background: rgba(245,158,11,0.15); color: #f59e0b; }

/* ═══ ACTIONS CARTES ═══ */
.adm-card-actions {
  display: flex; gap: 0.5rem; padding-top: 0.65rem;
  border-top: 1px solid #2a2a3a; flex-wrap: wrap;
}
.adm-btn-edit {
  display: flex; align-items: center; gap: 0.3rem;
  padding: 0.4rem 0.75rem; background: rgba(139,92,246,0.1);
  border: 1px solid #8b5cf6; border-radius: 6px;
  color: #a78bfa; font-size: 0.75rem; font-weight: 600; cursor: pointer;
}
.adm-btn-edit:hover { background: #8b5cf6; color: #fff; }

.adm-btn-annuler {
  display: flex; align-items: center; gap: 0.3rem;
  padding: 0.4rem 0.75rem; background: transparent;
  border: 1px solid #f59e0b; border-radius: 6px;
  color: #f59e0b; font-size: 0.75rem; font-weight: 600; cursor: pointer;
}
.adm-btn-annuler:hover { background: #f59e0b; color: #fff; }

.adm-btn-delete {
  display: flex; align-items: center; gap: 0.3rem;
  padding: 0.4rem 0.75rem; background: transparent;
  border: 1px solid #dc2626; border-radius: 6px;
  color: #dc2626; font-size: 0.75rem; font-weight: 600; cursor: pointer;
  margin-left: auto;
}
.adm-btn-delete:hover { background: #dc2626; color: #fff; }

/* ═══ MODAL ═══ */
.adm-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center;
  z-index: 1100; padding: 1rem; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.adm-modal {
  background: #12121a; border: 1px solid #2a2a3a; border-radius: 12px;
  width: 100%; max-width: 750px; max-height: 90vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}
.adm-modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.75rem 1.25rem; border-bottom: 1px solid #2a2a3a; background: #0f0f17;
}
.adm-modal-header h2 { display: flex; align-items: center; gap: 0.5rem; font-size: 1rem; margin: 0; }
.btn-close {
  background: #1a1a25; border: 1px solid #2a2a3a; color: #a0a0b0;
  width: 32px; height: 32px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.btn-close:hover { background: #ef4444; color: #fff; border-color: #ef4444; }

.adm-modal-body { flex: 1 1; overflow-y: auto; padding: 1.25rem; }

.adm-modal-error {
  padding: 8px 12px; margin-bottom: 1rem; border-radius: 8px;
  background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3);
  color: #ef4444; font-size: 0.82rem; font-weight: 600;
}

.adm-modal-section { margin-bottom: 1.25rem; }
.adm-modal-section > label {
  display: block; font-size: 0.72rem; font-weight: 700;
  color: #a0a0b0; text-transform: uppercase; margin-bottom: 0.4rem; letter-spacing: 0.02em;
}
.adm-modal-section textarea {
  width: 100%; padding: 0.6rem; background: #0a0a0f; border: 1px solid #2a2a3a;
  border-radius: 8px; color: #f0f0f5; font-size: 0.85rem; resize: vertical;
  outline: none; font-family: inherit;
}
.adm-modal-section textarea:focus { border-color: #a78bfa; }
.adm-modal-section textarea::placeholder { color: #505060; }

/* Priorité */
.adm-prio-selector { display: flex; gap: 0.5rem; }
.adm-prio-btn {
  flex: 1 1; padding: 0.5rem; background: #1a1a25; border: 2px solid #2a2a3a;
  border-radius: 8px; color: #a0a0b0; font-size: 0.82rem; font-weight: 600;
  cursor: pointer; text-align: center; transition: all 0.15s;
}
.adm-prio-btn:hover { border-color: #404050; }
.adm-prio-btn.active.prio-normal { border-color: #06b6d4; background: rgba(6,182,212,0.1); color: #06b6d4; }
.adm-prio-btn.active.prio-urgent { border-color: #f59e0b; background: rgba(245,158,11,0.1); color: #f59e0b; }
.adm-prio-btn.active.prio-critique { border-color: #ef4444; background: rgba(239,68,68,0.1); color: #ef4444; }

/* Search */
.adm-search-wrap {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.55rem 0.75rem; background: #0a0a0f; border: 1px solid #2a2a3a; border-radius: 8px;
}
.adm-search-wrap:focus-within { border-color: #a78bfa; }
.adm-search-wrap svg { color: #606070; font-size: 1rem; flex-shrink: 0; }
.adm-search-wrap input { flex: 1 1; background: transparent; border: none; outline: none; color: #f0f0f5; font-size: 0.85rem; }
.adm-search-wrap input::placeholder { color: #505060; }
.adm-search-spinner {
  width: 16px; height: 16px; border: 2px solid #2a2a3a; border-top-color: #a78bfa;
  border-radius: 50%; animation: spin 0.6s linear infinite; flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Résultats recherche */
.adm-search-results {
  max-height: 250px; overflow-y: auto; margin-top: 0.5rem;
  border: 1px solid #2a2a3a; border-radius: 8px; background: #0a0a0f;
}
.adm-search-row {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 0.75rem; cursor: pointer;
  border-bottom: 1px solid #1a1a25; transition: background 0.1s;
}
.adm-search-row:last-child { border-bottom: none; }
.adm-search-row:hover { background: rgba(139,92,246,0.05); }
.adm-search-row.added { opacity: 0.3; cursor: default; }

.adm-sr-main { flex: 1 1; min-width: 0; }
.adm-sr-top { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 3px; flex-wrap: wrap; }
.adm-sr-nart { font-family: monospace; font-size: 0.78rem; font-weight: 700; color: #06b6d4; flex-shrink: 0; }
.adm-sr-reappro-badge {
  font-size: 0.58rem; font-weight: 800; padding: 1px 5px;
  background: rgba(139,92,246,0.15); color: #a78bfa; border-radius: 3px;
}
.adm-sr-design { font-size: 0.78rem; color: #a0a0b0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-sr-stocks { display: flex; flex-wrap: wrap; gap: 3px; }
.adm-sr-stock-chip {
  font-size: 0.62rem; padding: 1px 5px; border-radius: 3px; font-weight: 600; font-family: monospace;
}
.adm-sr-stock-chip.positive { background: rgba(16,185,129,0.1); color: #10b981; }
.adm-sr-stock-chip.zero { background: rgba(96,96,112,0.06); color: #404050; }
.adm-sr-add { color: #a78bfa; font-size: 1.1rem; flex-shrink: 0; }
.adm-sr-check { color: #10b981; font-size: 1.1rem; flex-shrink: 0; }

/* Articles sélectionnés */
.adm-selected-lignes { display: flex; flex-direction: column; gap: 5px; }
.adm-sel-ligne {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 0.65rem; background: #0a0a0f;
  border: 1px solid #2a2a3a; border-radius: 8px;
}
.adm-sel-info { flex: 1 1; min-width: 0; }
.adm-sel-top { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 3px; }
.adm-sel-nart { font-family: monospace; font-size: 0.78rem; font-weight: 700; color: #06b6d4; }
.adm-sel-design { font-size: 0.75rem; color: #a0a0b0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-sel-stocks { display: flex; flex-wrap: wrap; gap: 3px; }
.adm-sel-stock { font-size: 0.6rem; padding: 1px 5px; background: rgba(16,185,129,0.08); color: #10b981; border-radius: 3px; font-weight: 600; }
.adm-sel-total { font-size: 0.6rem; padding: 1px 5px; background: rgba(6,182,212,0.08); color: #06b6d4; border-radius: 3px; font-weight: 600; }

.adm-sel-qte { display: flex; flex-direction: column; align-items: center; gap: 2px; flex-shrink: 0; }
.adm-sel-qte label { font-size: 0.58rem; color: #606070; text-transform: uppercase; }
.adm-qte-input {
  width: 55px; height: 34px; text-align: center; background: #12121a;
  border: 1px solid #2a2a3a; border-radius: 6px; color: #f0f0f5;
  font-size: 0.95rem; font-weight: 700; outline: none;
  -moz-appearance: textfield;
}
.adm-qte-input::-webkit-outer-spin-button,
.adm-qte-input::-webkit-inner-spin-button { -webkit-appearance: none; }
.adm-qte-input:focus { border-color: #a78bfa; }

.adm-sel-remove { background: none; border: none; color: #505060; cursor: pointer; padding: 4px; font-size: 0.95rem; flex-shrink: 0; }
.adm-sel-remove:hover { color: #ef4444; }

/* Modal footer */
.adm-modal-footer {
  display: flex; justify-content: flex-end; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.25rem; border-top: 1px solid #2a2a3a; background: #0f0f17;
}
.btn-cancel {
  padding: 0.5rem 1rem; background: #1a1a25; border: 1px solid #2a2a3a;
  border-radius: 6px; color: #a0a0b0; font-size: 0.82rem; cursor: pointer;
}
.btn-cancel:hover { background: #2a2a3a; color: #f0f0f5; }
.btn-create {
  display: flex; align-items: center; gap: 0.4rem;
  padding: 0.5rem 1.2rem; background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  border: none; border-radius: 6px; color: #fff; font-size: 0.82rem; font-weight: 600; cursor: pointer;
}
.btn-create:hover { background: linear-gradient(135deg, #6d28d9, #7c3aed); }
.btn-create:disabled { opacity: 0.4; cursor: not-allowed; }

/* ═══ RESPONSIVE ═══ */
@media (max-width: 768px) {
  .adm-header { flex-direction: column; align-items: stretch; }
  .adm-header-right { justify-content: flex-end; }
  .adm-list { padding: 0.5rem; }
  .adm-card-header { flex-direction: column; align-items: flex-start; gap: 0.3rem; }
  .adm-card-right { width: 100%; justify-content: flex-start; flex-wrap: wrap; }
  .adm-card-meta { flex-direction: column; gap: 0.2rem; }
  .adm-card-actions { flex-wrap: wrap; }
  .adm-modal { max-width: 100%; max-height: 100vh; border-radius: 0; }
  .adm-td-design { max-width: 100px; }
  .adm-main-tabs { padding: 6px 0.75rem; }
  .adm-sub-filters { padding: 4px 0.75rem; }
  .adm-sel-ligne { flex-wrap: wrap; }
  .adm-sel-info { flex: 1 1 100%; }
  .adm-sel-qte { flex-direction: row; gap: 6px; align-items: center; }
  .adm-msg { padding: 8px 0.75rem; font-size: 0.78rem; }
}

/*# sourceMappingURL=main.d2873484.css.map*/