/* ====== Vue Liste/Kanban pour chaque tableau ====== */
#ronin-table-content-cee.list-view > table,
#ronin-table-content-mpr.list-view > table { display: table; }

#ronin-table-content-cee.list-view .ronin-kanban-container,
#ronin-table-content-mpr.list-view .ronin-kanban-container { display: none; }

#ronin-table-content-cee.kanban-view > table,
#ronin-table-content-mpr.kanban-view > table { display: none; }

#ronin-table-content-cee.kanban-view .ronin-kanban-container,
#ronin-table-content-mpr.kanban-view .ronin-kanban-container {
  display: flex; gap: 16px; overflow-x: auto;
}

/* ====== Contrôles/boutons ====== */
#ronin-controls-cee, #ronin-controls-mpr {
  margin: 20px 0;
  text-align: center;
  display: flex;
  justify-content: center;
  gap: 10px;
}
#ronin-controls-cee button, #ronin-controls-mpr button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border: 2px solid #e1e5e9;
  background: #ffffff;
  color: #495057;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  text-decoration: none;
  outline: none;
  position: relative;
  overflow: hidden;
}
#ronin-controls-cee button:hover, #ronin-controls-mpr button:hover {
  background: #f8f9fa;
  border-color: #7EBA27;
  color: #7EBA27;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}
#ronin-controls-cee button.active, #ronin-controls-mpr button.active {
  background: #7EBA27;
  border-color: #7EBA27;
  color: #ffffff;
  box-shadow: 0 4px 8px rgba(126,186,39,0.3);
}
#ronin-controls-cee button:active, #ronin-controls-mpr button:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
#ronin-controls-cee button::before,
#ronin-controls-mpr button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}
#ronin-controls-cee button:hover::before,
#ronin-controls-mpr button:hover::before {
  left: 100%;
}

@media (max-width: 768px) {
  #ronin-controls-cee, #ronin-controls-mpr {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }  
  #ronin-controls-cee button, #ronin-controls-mpr button {
    width: 200px;
    padding: 10px 16px;
    font-size: 13px;
  }
}

/* ====== Kanban columns/cards ====== */
.ronin-kanban-column { min-width:220px; padding:8px; border:1px solid #ddd; background:#fafafa; border-radius:4px; }
.ronin-kanban-column h4 { text-align:center; margin-bottom:8px; font-weight:bold; }
.ronin-kanban-card { background:#fff; margin:4px 0; padding:8px; border-radius:4px; box-shadow:0 1px 3px rgba(0,0,0,0.1); word-wrap:break-word; text-align:center; }

/* ====== Datatables/search/pagination ====== */
.search-container { display:flex!important; justify-content:flex-end; margin-bottom:8px; }
.bottom-container { display:flex!important; justify-content:center; align-items:center; margin-top:8px; width:100%; }
.bottom-container .dataTables_length { margin-right:auto; }
.bottom-container .dataTables_paginate { margin:0 auto; }

/* ====== Background colors étapes ====== */
/* ====== CEE ====== */
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-étude-éligibilité td:first-child { background-color: #FEFEFE !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-signature-rai-acc td:first-child { background-color: #F59590 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-signature-chantier td:first-child { background-color: #F59590 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-chantier-en-cours td:first-child { background-color: #6495ED !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-facture-finale td:first-child { background-color: #BBA993 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-signatures-ah td:first-child { background-color: #F59590 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-complet-contrôle td:first-child { background-color: #568203 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-paiement td:first-child { background-color: #7EBA27 !important; }
#ronin-table-content-cee.list-view table#airtable-table tbody tr.etape-termine td:first-child { background-color: #AEBCB9 !important; }

/* ====== MPR ====== */
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-étude-éligibilité td:first-child { background-color: #FEFEFE !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-signature-proposition td:first-child { background-color: #F59590 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-enquête-socio-éco td:first-child { background-color: #F59590 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-dépôt-att-anah td:first-child { background-color: #6495ED !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-chantier-en-cours td:first-child { background-color: #BBA993 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-facture-finale td:first-child { background-color: #F59590 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-dépôt-contrôle td:first-child { background-color: #568203 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-paiement td:first-child { background-color: #7EBA27 !important; }
#ronin-table-content-mpr.list-view table#airtable-table tbody tr.etape-termine td:first-child { background-color: #AEBCB9 !important; }

/* Fallback : blanc si aucune étape */
#ronin-table-content-cee.list-view table#airtable-table tbody tr:not([class*="etape-"]) td:first-child,
#ronin-table-content-mpr.list-view table#airtable-table tbody tr:not([class*="etape-"]) td:first-child {
  background-color: #FFFFFF !important;
}
#ronin-table-content-cee.list-view table#airtable-table tbody tr:not([class*="etape-"]),
#ronin-table-content-mpr.list-view table#airtable-table tbody tr:not([class*="etape-"]) {
  background-color: #fff!important;
}

/* ====== DataTables centré ====== */
#airtable-table-cee th {
  text-align: center !important;
  vertical-align: middle !important;
}
#airtable-table-cee th,
#airtable-table-cee td {
    text-align: center !important;
    vertical-align: middle !important;
}

#airtable-table-mprth {
  text-align: center !important;
  vertical-align: middle !important;
}
#airtable-table-mpr th,
#airtable-table-mpr td {
    text-align: center !important;
    vertical-align: middle !important;
}