/**
 * Global styles for the "tools" application.
 *
 * - .error: bold red text for boolean errors or NIC mismatch
 * - Expiration background classes: exp-green / exp-orange / exp-red / exp-expired
 * - Multi-level dropdown helper
 */

.logo { font-weight: 700; }

/* Error emphasis */
.error {
  background-color: #ff0000;
  color: #ffffff;
  font-weight: 700;
}

/* Contrôles DataTable */
.top-controls,
.bottom-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Cellules trop larges */
table.dataTable td.tiny {
  width: 1%;
}

/* Cellules multi-ligne */
table.dataTable td.multiline {
  white-space: pre-line;
}

table.dataTable td,
table.dataTable th {
  border-right: 1px solid #dee2e6;
}

/* Titres centrés */
table.dataTable th {
    text-align: center !important;
}

table.dataTable th:last-child,
table.dataTable td:last-child {
  border-right: none;
}

.datatable-small thead th,
.datatable-small tfoot th,
.datatable-small tbody td {
    font-size: 0.7rem;
}

.datatable-selected-count {
  font-weight: bold;
}

/* Pastel-ish row backgrounds */
.exp-green { background-color: rgba(25, 135, 84, 0.20) !important; }
.exp-orange { background-color: rgba(255, 193, 7, 0.40) !important; }
.exp-red { background-color: rgba(220, 53, 69, 0.20) !important; }
.exp-expired { background-color: rgba(0, 0, 0, 0.40) !important; }

/* Legend boxes */
.legend-box {
  display: inline-block;
  width: 18px;
  height: 12px;
  border-radius: 3px;
  vertical-align: middle;
  margin-right: 6px;
  border: 1px solid rgba(0,0,0,0.15);
}

/* Sous-menus en décalé à droite */
.dropdown-menu .dropend {
  position: relative;
}

.dropdown-menu .dropend > .dropdown-menu {
  top: 0;
  left: 100%;
  margin-left: 0.1rem;
  margin-top: -0.25rem;
  display: none;
}

.dropdown-menu .dropend > .dropdown-menu.show {
  display: block;
}

.dropdown-menu .dropdown-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dropdown-menu .dropdown-toggle::after {
  margin-left: 0.5rem;
  float: none;      /* désactive le float Bootstrap */
}

/* Monospace */
.pre {
  white-space: pre;
  font-family: monospace;
  font-size: 0.8rem;
}

/* filtres par colonne */
thead input.form-control {
    font-size: 0.85rem;
}

/* Message "processing" toujours visible */
div.dataTables_processing,
div.dt-processing {
    position: fixed !important;
    top: 6rem !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    z-index: 2000 !important;

    width: auto !important;
    min-width: 12rem;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
}
