/* style.css */
:root { --bleu: #0b4f8a; --bg: #f4f6f8; --bordure: #e1e5ea; --rouge:#980808; }
* { box-sizing: border-box; }
body { font-family: system-ui, -apple-system, "Segoe UI", sans-serif; margin: 0; background: var(--bg); color: #1c2733; 
        display: flex;
        flex-direction: column;
        min-height: 100vh;
    }
header { background: var(--bleu); color: #fff; padding: 10px 32px; display: flex; align-items: center; justify-content: space-between; }
header h1 { margin: 0; font-size: 20px; font-weight: 600; }

/* Menu de navigation */
nav { background: #fff; border-bottom: 1px solid var(--bordure); padding: 0 32px; display: flex; gap: 20px; }
nav a { padding: 12px 0; text-decoration: none; color: var(--bleu); font-weight: 600; font-size: 14px; border-bottom: 2px solid transparent; }
nav a:hover, nav a.active { border-bottom: 2px solid var(--bleu); }

main {flex: 1; max-width: 100%; margin: 24px auto; padding: 0 16px; }

.toolbar { display: flex; gap: 12px; margin-bottom: 16px; align-items: center; }
select, button { padding: 8px 12px; border-radius: 6px; border: 1px solid var(--bordure); font-size: 14px; }

.logout { background: var(--rouge); color: #fff; border: none; cursor:pointer; text-decoration: none; border-radius: 6px; padding: 5px 12px; }
button { background: var(--bleu); color: #fff; border: none; cursor: pointer; }
button:hover { background: #093c6b; }

table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }
th, td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--bordure); font-size: 14px; }
th { background: #eef2f6; font-weight: 600; }
  tr:hover td { background: #f9fbfd; }
  
  .statut { padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 600; }
  .statut-DEPOSEE, .statut-EMISE { background: #e8f0fe; color: #1a56b0; }
  .statut-REJETEE, .statut-ABANDONNEE, .statut-REFUSEE_MOE,.statut-REJET_TECHNIQUE { background: #b3261e; color: white; }
  /* .statut-ERREUR_DE_MOE,.statut-ERREUR_DE_MOA { background: #ff8a7d;  color: white; } */
  [class*="ERREUR"] {
    background: #ff8a7d;
    color: white;
}
  .statut-MISE_A_DISPOSITION,.statut-A_ASSOCIER_MOE,.statut-MISE_A_DISPOSITION_MOE,.statut-ASSOCIEE,.statut-A_TRAITER{ background: orangered;color: white; }
  
  .statut-VALIDEE,.statut-VALIDER { background: #1e7a34; color: white; }
  
  .statut-SUSPENDUE {background: #b07d00;  color: white;}
  #info { color: #667; font-size: 13px; margin-top: 12px; }
  /* Boutons d'action dans le tableau */
/* Conteneur des actions : alignement horizontal forcé */
.actions-cell { 
    display: flex; 
    flex-direction: row; 
    gap: 6px; 
    align-items: center; 
    white-space: nowrap;
}

/* Style des boutons carrés avec les symboles */
.actions-cell { 
    display: flex; 
    flex-direction: row; 
    gap: 4px; 
    align-items: center; 
}

.btn-action { 
    width: 32px;
    height: 32px;
    padding: 6px; /* Espace autour du logo */
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px; 
    cursor: pointer; 
    border: none; 
    transition: background 0.2s;
}

/* Force les images SVG à prendre toute la place disponible */
.btn-action img {
    width: 100%;
    height: 100%;
    pointer-events: none; /* Empêche l'image de bloquer le clic du bouton */
}

.btn-valider { background: #1e7a34; }
.btn-valider:hover { background: #155724; }

.btn-rejeter { background: #b3261e; }
.btn-rejeter:hover { background: #8a1c17; }

.btn-suspendre { background: #b07d00; }
.btn-suspendre:hover { background: #855e00; }

.btn-download { background: #0b4f8a; }
.btn-download:hover { background: #093c6b; }
.btn-nodownload { background: red; }

.btn-paiement { background: #8a0b88; }
.btn-paiement:hover { background: #6b0e69; }

.btn-decompte { background: #8a0b88; }
.btn-decompte:hover { background: #6b0e69; }

/* Design du pied de page */
footer {
    background-color: #f8f9fa;
    border-top: 1px solid #e9ecef;
    padding: 20px 40px;
    margin-top: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 0.9rem;
    color: #6c757d;
}

/* Bloc de gauche */
.footer-left {
    flex: 1;
    display: flex;
    align-items: center;
}
.footer-left img {
    height: 50px;     /* Vous pouvez ajuster cette valeur (ex: 25px ou 35px) */
    max-width: 120px; /* Empêche un logo trop large de casser la mise en page */
    width: auto;      /* Conserve les proportions d'origine */
    object-fit: contain;
    margin-right: 10px;
}
/* Bloc du centre (Logo) */
.footer-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-center img {
    height: 50px; 
    max-width: 150px;
    width: auto;
    object-fit: contain;
}

/* Bloc de droite */
.footer-right {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
}

.footer-right a {
    color: #0056b3;
    text-decoration: none;
}

.footer-right a:hover {
    text-decoration: underline;
}

.badge-version {
    background: #e2e8f0;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
    color: #4a5568;
}
